wxEuphoria wxEVT_CLOSE_WINDOW

new topic     » topic index » view thread      » older message » newer message

I'm trying to trap the close window event when the user clicks the upper-right
'X' on the title bar. I can't seem to do it! Here's my procedure:

procedure byebye( atom this, atom event_type, atom id, atom event )
   save_plan()
   exit_main()
end procedure
set_event_handler( frame_Main, wxID_EXIT, wxEVT_COMMAND_MENU_SELECTED,
routine_id("byebye"))
set_event_handler( frame_Main, -1, wxEVT_CLOSE_WINDOW, routine_id("byebye"))

The menu one works fine, but not the wxEVT_CLOSE_WINDOW one. I've researched
this in the forum history and in the docs/demos, but I can't find an example.

-=ck
"Programming in a state of Euphoria."
http://www.cklester.com/euphoria/

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu