Setting default button for rename dialog, fixes #5266

Bug fixes:
- No event is now raised when user presses OK button or ENTER key
without changing spot name
- Some code cleanup
This commit is contained in:
Pandagrapher
2019-04-12 09:26:42 +02:00
parent 5a58d32073
commit 152d8c3879
2 changed files with 29 additions and 16 deletions

View File

@@ -294,11 +294,16 @@ private:
public Gtk::Dialog
{
public:
enum DialogButton {
OkButton = 1,
CancelButton = 2
};
RenameDialog(const Glib::ustring &actualname, Gtk::Window &parent);
Glib::ustring get_new_name();
private:
Gtk::Entry newname_;
Gtk::Entry* const newname_;
};
ControlSpots spots_;