summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKrzysztof Kosi??ski <tweenk.pl@gmail.com>2016-04-13 14:55:31 +0000
committerKrzysztof KosiƄski <tweenk.pl@gmail.com>2016-04-13 14:55:31 +0000
commit4530a577992a0289d74885d5135ed44d3365a572 (patch)
treeb1c93ecc5afc7000df2c7bbf44c4d355897a03ce /src
parentRemove unused variable in sp-canvas.cpp (diff)
downloadinkscape-4530a577992a0289d74885d5135ed44d3365a572.tar.gz
inkscape-4530a577992a0289d74885d5135ed44d3365a572.zip
Fix a few more pick calls not preceded by update
(bzr r14834)
Diffstat (limited to 'src')
-rw-r--r--src/document.cpp13
-rw-r--r--src/trace/trace.cpp1
2 files changed, 10 insertions, 4 deletions
diff --git a/src/document.cpp b/src/document.cpp
index ae03b1ba1..7086fc0be 100644
--- a/src/document.cpp
+++ b/src/document.cpp
@@ -46,6 +46,7 @@
#include "widgets/desktop-widget.h"
#include "desktop.h"
#include "dir-util.h"
+#include "display/drawing.h"
#include "display/drawing-item.h"
#include "document-private.h"
#include "document-undo.h"
@@ -1316,6 +1317,7 @@ SPItem *SPDocument::getItemFromListAtPointBottom(unsigned int dkey, SPGroup *gro
if ( SP_IS_ITEM(o) ) {
SPItem *item = SP_ITEM(o);
Inkscape::DrawingItem *arenaitem = item->get_arenaitem(dkey);
+ arenaitem->drawing().update();
if (arenaitem && arenaitem->pick(p, delta, 1) != NULL
&& (take_insensitive || item->isVisibleAndUnlocked(dkey))) {
if (find(list.begin(),list.end(),item)!=list.end() ) {
@@ -1380,10 +1382,12 @@ static SPItem *find_item_at_point(std::deque<SPItem*> *nodes, unsigned int dkey,
continue;
}
Inkscape::DrawingItem *arenaitem = child->get_arenaitem(dkey);
-
- if (arenaitem && arenaitem->pick(p, delta, 1) != NULL) {
- seen = child;
- break;
+ if (arenaitem) {
+ arenaitem->drawing().update();
+ if (arenaitem->pick(p, delta, 1) != NULL) {
+ seen = child;
+ break;
+ }
}
}
@@ -1413,6 +1417,7 @@ static SPItem *find_group_at_point(unsigned int dkey, SPGroup *group, Geom::Poin
if (SP_IS_GROUP(o) && SP_GROUP(o)->effectiveLayerMode(dkey) != SPGroup::LAYER ) {
SPItem *child = SP_ITEM(o);
Inkscape::DrawingItem *arenaitem = child->get_arenaitem(dkey);
+ arenaitem->drawing().update();
// seen remembers the last (topmost) of groups pickable at this point
if (arenaitem && arenaitem->pick(p, delta, 1) != NULL) {
diff --git a/src/trace/trace.cpp b/src/trace/trace.cpp
index 18f03aa1b..379682668 100644
--- a/src/trace/trace.cpp
+++ b/src/trace/trace.cpp
@@ -274,6 +274,7 @@ Glib::RefPtr<Gdk::Pixbuf> Tracer::sioxProcessImage(SPImage *img, Glib::RefPtr<Gd
for (aIter = arenaItems.begin() ; aIter!=arenaItems.end() ; ++aIter)
{
Inkscape::DrawingItem *arenaItem = *aIter;
+ arenaItem->drawing().update();
if (arenaItem->pick(point, 1.0f, 1))
{
weHaveAHit = true;