summaryrefslogtreecommitdiffstats
path: root/generic/tkPanedWindow.c
diff options
context:
space:
mode:
authorhobbs <hobbs>2004-05-03 19:16:10 (GMT)
committerhobbs <hobbs>2004-05-03 19:16:10 (GMT)
commit6c72f2eedb5564cb9b4a911d92ab6784afc9a5e9 (patch)
tree3f1e840096ac0d77625039354876bfd635dadf5b /generic/tkPanedWindow.c
parent61e4eb0e2ea76121b2ea96bbaee80192ecad7c9b (diff)
downloadtk-6c72f2eedb5564cb9b4a911d92ab6784afc9a5e9.zip
tk-6c72f2eedb5564cb9b4a911d92ab6784afc9a5e9.tar.gz
tk-6c72f2eedb5564cb9b4a911d92ab6784afc9a5e9.tar.bz2
* tests/panedwindow.test: panedwindow-25.1
* generic/tkPanedWindow.c (Unlink): clean up -before/-after refs to a slave when removing it. [Bug #928413] (griffin)
Diffstat (limited to 'generic/tkPanedWindow.c')
-rw-r--r--generic/tkPanedWindow.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/generic/tkPanedWindow.c b/generic/tkPanedWindow.c
index 80e2cb8..c154b48 100644
--- a/generic/tkPanedWindow.c
+++ b/generic/tkPanedWindow.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkPanedWindow.c,v 1.18 2003/09/29 23:15:19 dkf Exp $
+ * RCS: @(#) $Id: tkPanedWindow.c,v 1.19 2004/05/03 19:16:10 hobbs Exp $
*/
#include "tkPort.h"
@@ -1748,6 +1748,18 @@ Unlink(slavePtr)
}
}
+ /*
+ * Clean out any -after or -before references to this slave
+ */
+ for (i = 0; i < masterPtr->numSlaves; i++) {
+ if (masterPtr->slaves[i]->before == slavePtr->tkwin) {
+ masterPtr->slaves[i]->before = None;
+ }
+ if (masterPtr->slaves[i]->after == slavePtr->tkwin) {
+ masterPtr->slaves[i]->after = None;
+ }
+ }
+
masterPtr->flags |= REQUESTED_RELAYOUT;
if (!(masterPtr->flags & REDRAW_PENDING)) {
masterPtr->flags |= REDRAW_PENDING;