Tk Source Code

View Ticket
Login
Ticket UUID: 109865fa0161c4a6e1e5873454e22e7a1e0b4d31
Title: Mac OS X: ttk::menubutton has an unprotected winfo
Type: Bug Version: 8.6.4
Submitter: anonymous Created on: 2016-05-22 18:33:14
Subsystem: 88. Themed Tk Assigned To: fvogel
Priority: 5 Medium Severity: Minor
Status: Closed Last Modified: 2016-05-25 19:37:23
Resolution: Fixed Closed By: fvogel
    Closed on: 2016-05-25 19:37:23
Description:
After the toplevel frame is destroyed, the Mac gets an error:

invalid command name ".b.mb"
invalid command name ".b.mb"
    while executing
".b.mb state !pressed "


package require Tk

proc doexit { } {
  destroy .b
  raise .f
  focus .f
}

frame .f -width 100 -height 100
pack .f

toplevel .b
ttk::menubutton .b.mb -text Button -style TLabel
bind .b.mb <ButtonRelease-1> doexit
pack .b.mb -in .b
raise .b .f
User Comments: fvogel added on 2016-05-25 19:37:23:
Fix merged to core-8-6-branch and trunk.

anonymous (claiming to be [email protected]) added on 2016-05-24 00:30:25:
In case someone else runs into this, the workaround is:
   after 10 destroy .mywindow
(or after 10 somewhere in the call sequence).

fvogel added on 2016-05-22 20:56:38:

Non-regression testcase added in [265212e3], also in branch bug-109865fa01


fvogel added on 2016-05-22 19:57:41:
Fix proposed: [6545d24edd]

fvogel added on 2016-05-22 19:46:52:

Happens on Win also.

Very similar to [011706ec42].