mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-06 06:44:57 +01:00
Dialog default to cancel (#7915)
There are various ways to cancel a dialog. Only checking for RESPONSE_CANCEL is not sufficient. e.g. Esc causes a delete-event. * Gtk::RESPONSE_CLOSE * Gtk::RESPONSE_REJECT * Gtk::RESPONSE_DELETE_EVENT * Gtk::RESPONSE_CANCEL * Gtk::RESPONSE_NO Among others this fixes "Clicking session > open, then hitting ESC opens the currently selected folder and session"
This commit is contained in:
parent
e5c819956a
commit
8710a2d943
10 changed files with 70 additions and 58 deletions
|
|
@ -857,10 +857,10 @@ If you still wish to proceed, please use the\n\n\
|
|||
save_as_dialog->hide ();
|
||||
|
||||
switch (response) {
|
||||
case Gtk::RESPONSE_OK:
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
case Gtk::RESPONSE_OK:
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -1055,8 +1055,11 @@ ARDOUR_UI::open_session ()
|
|||
int response = open_session_selector.run();
|
||||
open_session_selector.hide ();
|
||||
|
||||
if (response == Gtk::RESPONSE_CANCEL) {
|
||||
return;
|
||||
switch (response) {
|
||||
case Gtk::RESPONSE_ACCEPT:
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
}
|
||||
|
||||
string session_path = open_session_selector.get_filename();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue