diff options
author | fvogel <fvogelnew1@free.fr> | 2016-11-05 11:17:06 (GMT) |
---|---|---|
committer | fvogel <fvogelnew1@free.fr> | 2016-11-05 11:17:06 (GMT) |
commit | ea566f2ac0714ef7f7a6e3207a62b30cb3099ca4 (patch) | |
tree | 2d32e594163821c18575fd8c6721052be44a91ff | |
parent | 8b3bdb14237db2879a76fd0596cef927625aa470 (diff) | |
parent | d05dd6d6060c5b4b565d5d1dfd771ad2242d7810 (diff) | |
download | tk-ea566f2ac0714ef7f7a6e3207a62b30cb3099ca4.zip tk-ea566f2ac0714ef7f7a6e3207a62b30cb3099ca4.tar.gz tk-ea566f2ac0714ef7f7a6e3207a62b30cb3099ca4.tar.bz2 |
Fixed [6aea69fccb] - grid configure -in problem. Patch by Koen Danckaert.
-rw-r--r-- | generic/tkGrid.c | 3 | ||||
-rw-r--r-- | tests/grid.test | 19 |
2 files changed, 22 insertions, 0 deletions
diff --git a/generic/tkGrid.c b/generic/tkGrid.c index 2a88b76..62c9c59 100644 --- a/generic/tkGrid.c +++ b/generic/tkGrid.c @@ -3314,6 +3314,9 @@ ConfigureSlaves( } if (slavePtr->masterPtr != NULL && slavePtr->masterPtr != masterPtr) { + if (slavePtr->masterPtr->tkwin != Tk_Parent(slavePtr->tkwin)) { + Tk_UnmaintainGeometry(slavePtr->tkwin, slavePtr->masterPtr->tkwin); + } Unlink(slavePtr); slavePtr->masterPtr = NULL; } diff --git a/tests/grid.test b/tests/grid.test index c1d9d06..cba69db 100644 --- a/tests/grid.test +++ b/tests/grid.test @@ -1998,6 +1998,25 @@ test grid-22.5 {remove} { grid info .c } {-in . -column 0 -row 0 -columnspan 2 -rowspan 2 -ipadx 0 -ipady 0 -padx {3 5} -pady {4 7} -sticky ns} grid_reset 22.5 + +test grid-23 {grid configure -in leaked from previous master - bug + 6aea69fccbb266b7f0437686379fbe5b55442958} { + frame .f + frame .g + pack .f .g + text .t + grid .t -in .f + pack forget .f + update + grid .t -in .g + # .t is now managed by .g; following lines must have no effect on .t + pack .f + update + pack forget .f + update + winfo ismapped .t ; # must return 1 +} {1} +grid_reset 23 # cleanup cleanupTests |