diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | library/menu.tcl | 6 |
2 files changed, 9 insertions, 2 deletions
@@ -1,3 +1,8 @@ +2001-11-27 D. Richard Hipp <drh@hwaci.com> + + * library/menu.tcl: Do not allow keyboard traversal of torn-off + menus to visit the (invisible) tearoff bar. + 2001-11-26 D. Richard Hipp <drh@hwaci.com> * win/tkWinMenu.c: disabled menu items show the activebackground diff --git a/library/menu.tcl b/library/menu.tcl index 567a306..5f7352b 100644 --- a/library/menu.tcl +++ b/library/menu.tcl @@ -4,7 +4,7 @@ # It also implements keyboard traversal of menus and implements a few # other utility procedures related to menus. # -# RCS: @(#) $Id: menu.tcl,v 1.14 2001/11/16 22:54:22 hobbs Exp $ +# RCS: @(#) $Id: menu.tcl,v 1.15 2001/11/27 14:08:04 drh Exp $ # # Copyright (c) 1992-1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. @@ -870,7 +870,9 @@ proc ::tk::MenuNextEntry {menu count} { incr i -$length } if {[catch {$menu entrycget $i -state} state] == 0} { - if {[string compare $state "disabled"]} { + if {$state!="disabled" && + ($i!=0 || [$menu cget -type]!="tearoff" + || [$menu type 0]!="tearoff")} { break } } |