diff options
| author | Krzysztof Kosi??ski <tweenk.pl@gmail.com> | 2013-10-01 12:31:34 +0000 |
|---|---|---|
| committer | Krzysztof KosiĆski <tweenk.pl@gmail.com> | 2013-10-01 12:31:34 +0000 |
| commit | 56791e9c202001bf29b089f1f52ad128e548f198 (patch) | |
| tree | 8c6e688e69bc41cbdc73c1cba72f39f2df406da6 /src/display/drawing-item.cpp | |
| parent | Revert render svg:patern segment for fill and stroke (diff) | |
| download | inkscape-56791e9c202001bf29b089f1f52ad128e548f198.tar.gz inkscape-56791e9c202001bf29b089f1f52ad128e548f198.zip | |
Fix possible bug in DrawingItem code
(bzr r12647)
Diffstat (limited to 'src/display/drawing-item.cpp')
| -rw-r--r-- | src/display/drawing-item.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/display/drawing-item.cpp b/src/display/drawing-item.cpp index 526fc3000..b2b3e68a2 100644 --- a/src/display/drawing-item.cpp +++ b/src/display/drawing-item.cpp @@ -141,6 +141,9 @@ DrawingItem::appendChild(DrawingItem *item) assert(item->_child_type == CHILD_ORPHAN); item->_child_type = CHILD_NORMAL; _children.push_back(*item); + + // This ensures that _markForUpdate() called on the child will recurse to this item + item->_state = STATE_ALL; // Because _markForUpdate recurses through ancestors, we can simply call it // on the just-added child. This has the additional benefit that we do not // rely on the appended child being in the default non-updated state. @@ -156,6 +159,7 @@ DrawingItem::prependChild(DrawingItem *item) item->_child_type = CHILD_NORMAL; _children.push_front(*item); // See appendChild for explanation + item->_state = STATE_ALL; item->_markForUpdate(STATE_ALL, true); } |
