summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordgp@users.sourceforge.net <dgp>2012-08-25 01:52:21 (GMT)
committerdgp@users.sourceforge.net <dgp>2012-08-25 01:52:21 (GMT)
commit068850eef4688ee93422b7debf84824502fb91e0 (patch)
treedb193cb50ffc1f5727e928ab2c3468b776432bda
parent3e84a653ed7faed7a14ea2557d23deb447b26607 (diff)
downloadtk-068850eef4688ee93422b7debf84824502fb91e0.zip
tk-068850eef4688ee93422b7debf84824502fb91e0.tar.gz
tk-068850eef4688ee93422b7debf84824502fb91e0.tar.bz2
3554026 3561016 Better fix from Emiliano Gavilan.
-rw-r--r--unix/tkUnixWm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/unix/tkUnixWm.c b/unix/tkUnixWm.c
index fa130a1..1fe1174 100644
--- a/unix/tkUnixWm.c
+++ b/unix/tkUnixWm.c
@@ -6274,14 +6274,14 @@ TkSetTransientFor(tkwin, parent)
if (parent == None) {
parent = Tk_Parent(tkwin);
while (!Tk_IsTopLevel(parent))
- parent = Tk_Parent(tkwin);
+ parent = Tk_Parent(parent);
}
/*
* Prevent crash due to incomplete initialization, or other problems.
* [Bugs 3554026, 3561016]
*/
if (((TkWindow *)parent)->wmInfoPtr->wrapperPtr == NULL) {
- return;
+ CreateWrapper(((TkWindow *)parent)->wmInfoPtr);
}
XSetTransientForHint(Tk_Display(tkwin),
((TkWindow *)tkwin)->wmInfoPtr->wrapperPtr->window,