Method: Win::Gui::Window#shut_window
- Defined in:
- lib/win/gui/window.rb
#shut_window(win_handle) ⇒ Object
Shuts down the window created by different thread by posting WM_SYSCOMMAND, SC_CLOSE message to it. This closely emulates user clicking on X button of the target window. As it would be expected, this actually gives the target window chance to close gracefully (it may ask user to save data and stuff). I have not found so far how to REALLY destroy window in different thread without it asking user anything.
838 839 840 |
# File 'lib/win/gui/window.rb', line 838 def shut_window( win_handle ) (win_handle, Win::Gui::Message::WM_SYSCOMMAND, Win::Gui::Message::SC_CLOSE, nil) end |