search for: confirm_closur

Displaying 1 result from an estimated 1 matches for "confirm_closur".

Did you mean: confirm_closure
2009 Nov 28
1
'Are you sure?' custom dialog not exiting cleanly
...============================================ require ''wx'' require ''sample1.rb'' class DIA_Frame < DiaFrame def on_init set_affirmative_id(Wx::ID_YES) set_escape_id(Wx::ID_NO) end end class Main_Frame < MainFrame def on_init evt_close { confirm_closure } evt_button(@m_butexit) {self.close} end def confirm_closure dlg = DIA_Frame.new if(dlg.show_modal==Wx::ID_YES) then dlg.end_modal(Wx::ID_YES) self.destroy end end end class MyApp < Wx::App def on_init main_frame = Main_Frame.new() set_top_window...