mp4chaps Lua script: don't clutter global environment
[ardour.git] / gtk2_ardour / editor_snapshots.cc
index f79a442481a75f15a49d6c910cb3acf87d87d9c5..355e4a3d8888a10a003a7c3a8705885fd5e70dac 100644 (file)
 
 #include <gtkmm/liststore.h>
 
-#include "gtkmm2ext/choice.h"
-
 #include "ardour/filename_extensions.h"
 #include "ardour/session.h"
 #include "ardour/session_state_utils.h"
 #include "ardour/session_directory.h"
 
+#include "widgets/choice.h"
+#include "widgets/prompter.h"
+
 #include "editor_snapshots.h"
 #include "ardour_ui.h"
-#include "i18n.h"
+#include "pbd/i18n.h"
 #include "utils.h"
-#include "prompter.h"
 
 using namespace std;
 using namespace PBD;
@@ -89,7 +89,9 @@ EditorSnapshots::selection_changed ()
                        return;
                }
 
+               _display.set_sensitive (false);
                ARDOUR_UI::instance()->load_session (_session->path(), string (snap_name));
+               _display.set_sensitive (true);
        }
 }
 
@@ -141,7 +143,7 @@ EditorSnapshots::popup_context_menu (int button, int32_t time, std::string snaps
 void
 EditorSnapshots::rename (std::string old_name)
 {
-       ArdourPrompter prompter(true);
+       ArdourWidgets::Prompter prompter(true);
 
        string new_name;
 
@@ -171,7 +173,7 @@ EditorSnapshots::remove (std::string name)
        choices.push_back (_("No, do nothing."));
        choices.push_back (_("Yes, remove it."));
 
-       Gtkmm2ext::Choice prompter (_("Remove snapshot"), prompt, choices);
+       ArdourWidgets::Choice prompter (_("Remove snapshot"), prompt, choices);
 
        if (prompter.run () == 1) {
                _session->remove_state (name);
@@ -189,7 +191,7 @@ EditorSnapshots::redisplay ()
        vector<std::string> state_file_paths;
 
        get_state_files_in_directory (_session->session_directory().root_path(),
-                                     state_file_paths);
+                                     state_file_paths);
 
        if (state_file_paths.empty()) {
                return;