X-Git-Url: http://git.tdb.fi/?p=libs%2Fgltk.git;a=blobdiff_plain;f=source%2Fdialog.cpp;fp=source%2Fdialog.cpp;h=5e5e390e7cadadf91d3e5af4e978d4e3f333dc33;hp=9f9fc20d15388f69ece201db0105265ddae7c74e;hb=b4d0a86b77fb5146f5a4f6c76690c16204210f1a;hpb=394e5c9969a30b604bfaf78fc05a8c2d5c98ab5b diff --git a/source/dialog.cpp b/source/dialog.cpp index 9f9fc20..5e5e390 100644 --- a/source/dialog.cpp +++ b/source/dialog.cpp @@ -24,37 +24,11 @@ void Dialog::set_modal(bool m) signal_ungrab_pointer.emit(); } -void Dialog::button_release(int x, int y, unsigned button) -{ - Panel::button_release(x, y, button); - check_stale(); -} - -bool Dialog::key_release(unsigned key, unsigned mod) -{ - bool result = Panel::key_release(key, mod); - check_stale(); - return result; -} - -bool Dialog::navigate(Navigation nav) -{ - bool result = Panel::navigate(nav); - check_stale(); - return result; -} - void Dialog::response(int code) { on_response(code); signal_response.emit(code); - stale = true; -} - -void Dialog::check_stale() -{ - if(stale) - delete this; + set_visible(false); }