Revision: 45891
          http://brlcad.svn.sourceforge.net/brlcad/?rev=45891&view=rev
Author:   brlcad
Date:     2011-08-10 13:30:00 +0000 (Wed, 10 Aug 2011)

Log Message:
-----------
only attempt to override tk behavior if tk is loaded

Modified Paths:
--------------
    brlcad/trunk/src/tclscripts/mged/openw.tcl

Modified: brlcad/trunk/src/tclscripts/mged/openw.tcl
===================================================================
--- brlcad/trunk/src/tclscripts/mged/openw.tcl  2011-08-10 13:06:17 UTC (rev 
45890)
+++ brlcad/trunk/src/tclscripts/mged/openw.tcl  2011-08-10 13:30:00 UTC (rev 
45891)
@@ -253,12 +253,14 @@
 bind Listbox <ButtonPress-3><ButtonRelease-3> "hoc_callback %W %X %Y"
 bind Scale <ButtonPress-3><ButtonRelease-3> "hoc_callback %W %X %Y"
 
-# This causes cad_dialog to use mged_wait instead of tkwait
-set ::tk::Priv(wait_cmd) mged_wait
+if {[namespace exists ::tk]} {
+    # This causes cad_dialog to use mged_wait instead of tkwait
+    set ::tk::Priv(wait_cmd) mged_wait
 
-# Used throughout the GUI as the dialog window name.
-# This helps prevent window clutter.
-set ::tk::Priv(cad_dialog) .mged_dialog
+    # Used throughout the GUI as the dialog window name.
+    # This helps prevent window clutter.
+    set ::tk::Priv(cad_dialog) .mged_dialog
+}
 
 proc gui { args } {
     global tmp_hoc


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
uberSVN's rich system and user administration capabilities and model 
configuration take the hassle out of deploying and managing Subversion and 
the tools developers use with it. Learn more about uberSVN and get a free 
download at:  http://p.sf.net/sfu/wandisco-dev2dev
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits

Reply via email to