summaryrefslogtreecommitdiffstats
path: root/library/demos/toolbar.tcl
diff options
context:
space:
mode:
Diffstat (limited to 'library/demos/toolbar.tcl')
-rw-r--r--library/demos/toolbar.tcl9
1 files changed, 4 insertions, 5 deletions
diff --git a/library/demos/toolbar.tcl b/library/demos/toolbar.tcl
index 74a490f..d5f1159 100644
--- a/library/demos/toolbar.tcl
+++ b/library/demos/toolbar.tcl
@@ -2,14 +2,13 @@
#
# This demonstration script creates a toolbar that can be torn off.
#
-# RCS: @(#) $Id: toolbar.tcl,v 1.3 2007/12/13 15:27:07 dgp Exp $
+# RCS: @(#) $Id: toolbar.tcl,v 1.4 2008/12/11 18:13:08 jenglish Exp $
if {![info exists widgetDemo]} {
error "This script should be run from the \"widget\" demo."
}
package require Tk
-package require Ttk
set w .toolbar
destroy $w
@@ -18,7 +17,7 @@ wm title $w "Toolbar Demonstration"
wm iconname $w "toolbar"
positionWindow $w
-if {[tk windowingsystem] ne "aqua"} {
+if {[tk windowingsystem] ne {}} {
ttk::label $w.msg -wraplength 4i -text "This is a demonstration of how to do\
a toolbar that is styled correctly and which can be torn off. The\
buttons are configured to be \u201Ctoolbar style\u201D buttons by\
@@ -39,7 +38,7 @@ ttk::label $w.msg -wraplength 4i -text "This is a demonstration of how to do\
set t [frame $w.toolbar] ;# Must be a frame!
ttk::separator $w.sep
ttk::frame $t.tearoff -cursor fleur
-if {[tk windowingsystem] ne "aqua"} {
+if {[tk windowingsystem] ne {}} {
ttk::separator $t.tearoff.to -orient vertical
ttk::separator $t.tearoff.to2 -orient vertical
pack $t.tearoff.to -fill y -expand 1 -padx 2 -side left
@@ -50,7 +49,7 @@ grid $t.tearoff $t.contents -sticky nsew
grid columnconfigure $t $t.contents -weight 1
grid columnconfigure $t.contents 1000 -weight 1
-if {[tk windowingsystem] ne "aqua"} {
+if {[tk windowingsystem] ne {}} {
## Bindings so that the toolbar can be torn off and reattached
bind $t.tearoff <B1-Motion> [list tearoff $t %X %Y]
bind $t.tearoff.to <B1-Motion> [list tearoff $t %X %Y]