OSDN Git Service

2000-04-18 James Ingham <jingham@leda.cygnus.com>
authorjingham <jingham>
Wed, 19 Apr 2000 00:08:14 +0000 (00:08 +0000)
committerjingham <jingham>
Wed, 19 Apr 2000 00:08:14 +0000 (00:08 +0000)
        * library/toolbar.tcl (TOOLBAR_button_up): If the pointer is still
        in the button, reraise the button after a press.

libgui/ChangeLog
libgui/library/toolbar.tcl

index 2a16f91..4f270f6 100644 (file)
@@ -1,3 +1,13 @@
+2000-04-18  James Ingham  <jingham@leda.cygnus.com>
+
+       * library/toolbar.tcl (TOOLBAR_button_up): If the pointer is still 
+       in the button, reraise the button after a press.
+
+2000-04-03  James Ingham  <jingham@leda.cygnus.com>
+
+       * src/paths.c: Follow links in determining the location of the
+       executable.
+
 Fri Sep 17 19:14:15 1999  Andrew Cagney  <cagney@b1.cygnus.com>
 
        * src/guitcl.h (cyg_create_warp_pointer_command): Add declaration.
index daa49d6..12a67e8 100644 (file)
@@ -71,25 +71,33 @@ proc TOOLBAR_button_up {w} {
     set TOOLBAR_state(button) ""
     
     #restore original relief
-    $w configure -relief $TOOLBAR_state(relief)
+      $w configure -relief $TOOLBAR_state(relief)      
     
     if {$TOOLBAR_state(window) == $w
        && [$w cget -state] != "disabled"} then {
-       
-#SN does the toolbar bindings using "+" so that older
-#bindings don't disapear. So no need to invoke the command.
-#other applications should do the same so that we can delete
-#this hack
-global sn_options
-if {! [array exists sn_options]} {
-      #invoke the binding
-      uplevel \#0 [list $w invoke]
-}
+
+      #SN does the toolbar bindings using "+" so that older
+      #bindings don't disapear. So no need to invoke the command.
+      #other applications should do the same so that we can delete
+      #this hack
+      global sn_options
+      if {! [array exists sn_options]} {
+       #invoke the binding
+       uplevel \#0 [list $w invoke]
+      }
       if {[winfo exists $w]} then {
        if {[$w cget -state] != "disabled"} then {
          $w configure -state normal
        }
       }
+      # HOWEVER, if the pointer is still over the button, and it
+      # is enabled, then raise it again.
+
+      if {[string compare [winfo containing \
+                            [winfo pointerx $w] \
+                            [winfo pointery $w]] $w] == 0} { 
+       $w configure -relief raised
+      }        
     }
   }
 }