Try for yourself (tab over to cancel, hit enter).
Tk::messageBox
Tk::MsgBoxperl -MTk -e"print tkinit->messageBox(qw, -default ok -type okcancel , +)" Cancel
Tk::DialogBox (expected cancel, returns ok)perl -MTk -e"print tkinit->MsgBox(qw, -default ok -type okcancel ,)->S +how" Assuming 'require Tk::MsgBox;' at -e line 1 cancel
Changing the default to cancel, then tabbing over selecting ok, and hitting enter, produces cancel, its a bugperl -MTk -e"print tkinit->DialogBox(qw, -buttons , , [qw, ok cancel , +])->Show" Assuming 'require Tk::DialogBox;' at -e line 1 ok perl -MTk -e"print tkinit->DialogBox(qw, -default_button ok -buttons , + , [qw, ok cancel ,])->Show" Assuming 'require Tk::DialogBox;' at -e line 1 ok
Wx (wxYES is 2, wxNO is 8, and it returns 8 as expected).perl -MTk -e"print tkinit->DialogBox(qw, -default_button cancel -butto +ns , , [qw, ok cancel ,])->Show"
perl -MWx=wxYES,wxNO -e"warn wxYES;warn wxNO; die Wx::MessageBox( 1 , +2, wxYES|wxNO )" 2 at -e line 1. 8 at -e line 1. 8 at -e line 1.
In reply to Re^4: Dialog box Binding issue
by Anonymous Monk
in thread Dialog box Binding issue
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |