Item::~Item ()
{
- if (_canvas) {
- _canvas->item_going_away (this, _bounding_box);
- }
-
if (_parent) {
_parent->remove (this);
}
+
+ if (_canvas) {
+ _canvas->item_going_away (this, _bounding_box);
+ }
}
ArdourCanvas::Rect
void
Item::unparent ()
{
- _canvas = 0;
_parent = 0;
}
void
Item::reparent (Group* new_parent)
{
+ assert (_canvas == _parent->canvas());
+
if (_parent) {
_parent->remove (this);
}
{
boost::optional<ArdourCanvas::Rect> bb = bounding_box();
- o << _canvas->indent() << whatami() << ' ' << this;
+ o << _canvas->indent() << whatami() << ' ' << this << " Visible ? " << _visible;
o << " @ " << position();
#ifdef CANVAS_DEBUG