diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2013-04-16 20:38:10 -0400 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2013-04-16 20:38:10 -0400 |
commit | c1df3295c179b040a1d703d610e0f5a8b8dedb37 (patch) | |
tree | bd1277d26dd2a0343121813e42c15b198bcb1656 /libs/canvas/item.cc | |
parent | 81eed21ddef4b5c0e2d90e00d5c817f452b377fa (diff) |
virtual Fill:: and Outline:: methods so that Canvas::Items that cache image renderings of themselves can invalidate those caches when colors etc. change; add Item::{begin,end}_visual_change() so that we can notify the canvas more efficiently when *only* visual properties have changed and not the bounding box (probably needs to be used more widely)
Diffstat (limited to 'libs/canvas/item.cc')
-rw-r--r-- | libs/canvas/item.cc | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/libs/canvas/item.cc b/libs/canvas/item.cc index 7991b3aaaf..da551fade6 100644 --- a/libs/canvas/item.cc +++ b/libs/canvas/item.cc @@ -295,7 +295,6 @@ Item::width () const return 0; } -/* XXX may be called even if bbox is not changing ... bit grotty */ void Item::begin_change () { @@ -313,6 +312,17 @@ Item::end_change () } void +Item::begin_visual_change () +{ +} + +void +Item::end_visual_change () +{ + _canvas->item_visual_property_changed (this); +} + +void Item::move (Duple movement) { set_position (position() + movement); |