diff options
author | ericm <ericm> | 2000-04-18 02:18:32 (GMT) |
---|---|---|
committer | ericm <ericm> | 2000-04-18 02:18:32 (GMT) |
commit | 3b8d97bbddc028359dd7f579f7f4e2fdaf887752 (patch) | |
tree | 1a5b1bcdfcedcc57a982da47be2f49a3aba66103 /tests | |
parent | 642a893448534c32d814fa625c78d6ab695cad1b (diff) | |
download | tk-3b8d97bbddc028359dd7f579f7f4e2fdaf887752.zip tk-3b8d97bbddc028359dd7f579f7f4e2fdaf887752.tar.gz tk-3b8d97bbddc028359dd7f579f7f4e2fdaf887752.tar.bz2 |
* win/tkWinDialog.c: Added checks for visibility of parent window
before creating MessageBox and ChooseColor dialogs; this prevents
the application from locking when the parent is withdrawn and the
message box is created. In these cases, the window will be
created without a parent.
* unix/mkLinks: Added WinViewable.3.
* tests/msgbox.test: Added tests for patch from [Bug: 4997].
* library/msgbox.tcl:
* library/dialog.tcl: Applied patch from [Bug: 4997]; detaches
dialog window from parent if parent is not viewable.
* library/bgerror.tcl: Removed workaround from [Bug: 4370]; this
is superceeded by patches to dialog.tcl.
* generic/tkCmds.c: Changed WinfoObjCmd to use Tk_IsViewable
function to determine visibility of windows instead of inlining
the code.
* generic/tkStubInit.c:
* generic/tkDecls.h:
* generic/tk.decls: Added Tk_IsViewable declaration.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/msgbox.test | 32 |
1 files changed, 18 insertions, 14 deletions
diff --git a/tests/msgbox.test b/tests/msgbox.test index e9a16d4..78adb81 100644 --- a/tests/msgbox.test +++ b/tests/msgbox.test @@ -5,7 +5,7 @@ # Copyright (c) 1998-1999 by Scriptics Corporation. # All rights reserved. # -# RCS: @(#) $Id: msgbox.test,v 1.3 1999/04/16 01:51:39 stanton Exp $ +# RCS: @(#) $Id: msgbox.test,v 1.4 2000/04/18 02:18:34 ericm Exp $ # if {[lsearch [namespace children] ::tcltest] == -1} { @@ -165,19 +165,23 @@ foreach spec $specs { } } +# These tests will hang your test suite if they fail. +test msgbox-3.1 {tk_messageBox handles withdrawn parent} {nonUnixUserInteraction} { + wm withdraw . + ChooseMsg . "ok" + tk_messageBox -title Hi -message "Please press ok" \ + -type ok -default ok +} "ok" +wm deiconify . + +test msgbox-3.2 {tk_messageBox handles iconified parent} {nonUnixUserInteraction} { + wm iconify . + ChooseMsg . "ok" + tk_messageBox -title Hi -message "Please press ok" \ + -type ok -default ok +} "ok" +wm deiconify . + # cleanup ::tcltest::cleanupTests return - - - - - - - - - - - - - |