summaryrefslogtreecommitdiff
path: root/gdb/gdbtk
diff options
context:
space:
mode:
authorKeith Seitz <keiths@redhat.com>2001-05-22 15:46:03 +0000
committerKeith Seitz <keiths@redhat.com>2001-05-22 15:46:03 +0000
commitb1f6cb770dda88419e5c808d167cbfb75a9c5d15 (patch)
tree87a6e1e12d5a5bee556f04d06b250faf21c8cfec /gdb/gdbtk
parent72066403e8c052d2c933e1f19befe499508912d7 (diff)
downloadgdb-b1f6cb770dda88419e5c808d167cbfb75a9c5d15.tar.gz
* library/variables.tcl (postMenu): Add mysterious workaround
for popup menu bug in Tk for windows. Highlight the selection, too.
Diffstat (limited to 'gdb/gdbtk')
-rw-r--r--gdb/gdbtk/ChangeLog12
-rw-r--r--gdb/gdbtk/library/variables.tcl13
2 files changed, 25 insertions, 0 deletions
diff --git a/gdb/gdbtk/ChangeLog b/gdb/gdbtk/ChangeLog
index 066fa32cf68..cf0eee7fac3 100644
--- a/gdb/gdbtk/ChangeLog
+++ b/gdb/gdbtk/ChangeLog
@@ -1,3 +1,15 @@
+2001-05-22 Keith Seitz <keiths@cygnus.com>
+
+ * library/variables.tcl (postMenu): Add mysterious workaround
+ for popup menu bug in Tk for windows.
+ Highlight the selection, too.
+
+2001-05-21 Keith Seitz <keiths@cygnus.com>
+
+ * library/managedwin.itb (_create): Check the geometry of
+ any window we create. Don't create a window that is
+ bigger than the screen.
+
2001-05-18 Keith Seitz <keiths@cygnus.com>
* library/managedwin.ith (_geometry): Use a protected variable
diff --git a/gdb/gdbtk/library/variables.tcl b/gdb/gdbtk/library/variables.tcl
index 72d09dd4408..fd66491ba45 100644
--- a/gdb/gdbtk/library/variables.tcl
+++ b/gdb/gdbtk/library/variables.tcl
@@ -340,6 +340,9 @@ class VariableWin {
set variable [getEntry $X $Y]
if {[string length $variable] > 0} {
+ # First things first: highlight the variable we just selected
+ $Hlist selection set $variable
+
# Configure menu items
# the title is always first..
#set labelIndex [$Popup index "dummy"]
@@ -376,6 +379,16 @@ class VariableWin {
-command "$this setDisplay \{$variable\} $fmt"
}
+ if {$::tcl_platform(platform) == "windows"} {
+ # Don't ask me why this works, but it does work around
+ # a Win98/2000 Tcl bug with deleting entries from popups...
+ set no [$Popup index end]
+ for { set k 1 } { $k < $no } { incr k } {
+ $Popup insert 1 command
+ }
+ $Popup delete 1 [expr {$no - 1}]
+ }
+
tk_popup $Popup $X $Y
}
}