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)
commit656c3e9322cd07ef47c82de88d51080c09adab60 (patch)
tree3f1e840096ac0d77625039354876bfd635dadf5b /generic/tkPanedWindow.c
parent29f9a26ab63583f320e15f62cf93033cd448cffb (diff)
downloadtk-656c3e9322cd07ef47c82de88d51080c09adab60.zip
tk-656c3e9322cd07ef47c82de88d51080c09adab60.tar.gz
tk-656c3e9322cd07ef47c82de88d51080c09adab60.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;