[Aptitude-svn-commit] r3757 - in branches/aptitude-0.3/aptitude: .
src/vscreen
Daniel Burrows
dburrows at costa.debian.org
Mon Aug 8 21:49:27 UTC 2005
Author: dburrows
Date: Mon Aug 8 21:48:23 2005
New Revision: 3757
Modified:
branches/aptitude-0.3/aptitude/ChangeLog
branches/aptitude-0.3/aptitude/src/vscreen/vscreen_widget.cc
Log:
Don't call virtual functions from destructors. (doh)
Modified: branches/aptitude-0.3/aptitude/ChangeLog
==============================================================================
--- branches/aptitude-0.3/aptitude/ChangeLog (original)
+++ branches/aptitude-0.3/aptitude/ChangeLog Mon Aug 8 21:48:23 2005
@@ -1,5 +1,18 @@
2005-08-08 Daniel Burrows <dburrows at debian.org>
+ * src/vscreen/vscreen_widget.cc:
+
+ Don't call destroy() from the destructor, and don't bother
+ clearing out the signals in destroy() (the latter change could
+ be reversed if I made it a requirement for ALL derived classes
+ to clear ALL signal lists in destroy(), but I think that for the
+ time being, I'll settle for requiring the widget to be
+ disconnected from all events after destroy().
+
+ Incidentally, calling destroy() from the destructor was a truly
+ awful idea -- not only is it a complex member function, it's
+ virtual!
+
* src/vscreen/vs_radiogroup.cc:
Handle the case of removing the last button in a radio group.
Modified: branches/aptitude-0.3/aptitude/src/vscreen/vscreen_widget.cc
==============================================================================
--- branches/aptitude-0.3/aptitude/src/vscreen/vscreen_widget.cc (original)
+++ branches/aptitude-0.3/aptitude/src/vscreen/vscreen_widget.cc Mon Aug 8 21:48:23 2005
@@ -116,7 +116,6 @@
void vscreen_widget::cleanup()
{
- destroy();
assert(is_destroyed);
delete this;
}
@@ -137,15 +136,6 @@
}
destroyed();
-
- // Disconnect all signals:
-
- shown_sig.clear();
- hidden_sig.clear();
- destroyed.clear();
- do_layout.clear();
- focussed.clear();
- unfocussed.clear();
}
void vscreen_widget::show()
More information about the Aptitude-svn-commit
mailing list