add AudioBackendNativeThread to serve the same role as jack_native_thread_t
[ardour.git] / gtk2_ardour / editor_selection.cc
index 41652196f1943ea5c3b04c5d912dae906eaa74e0..e19afe375cea48a7057770538922d3f63be12892 100644 (file)
@@ -880,7 +880,7 @@ Editor::set_selected_regionview_from_region_list (boost::shared_ptr<Region> regi
 {
        vector<RegionView*> all_equivalent_regions;
 
-       get_regions_corresponding_to (region, all_equivalent_regions);
+       get_regions_corresponding_to (region, all_equivalent_regions, region->whole_file());
 
        if (all_equivalent_regions.empty()) {
                return;
@@ -1047,6 +1047,8 @@ Editor::sensitize_the_right_region_actions ()
        bool have_midi = false;
        bool have_locked = false;
        bool have_unlocked = false;
+       bool have_video_locked = false;
+       bool have_video_unlocked = false;
        bool have_position_lock_style_audio = false;
        bool have_position_lock_style_music = false;
        bool have_muted = false;
@@ -1089,6 +1091,12 @@ Editor::sensitize_the_right_region_actions ()
                        have_unlocked = true;
                }
 
+               if (r->video_locked()) {
+                       have_video_locked = true;
+               } else {
+                       have_video_unlocked = true;
+               }
+
                if (r->position_lock_style() == MusicTime) {
                        have_position_lock_style_music = true;
                } else {
@@ -1212,6 +1220,12 @@ Editor::sensitize_the_right_region_actions ()
                // a->set_inconsistent ();
        }
 
+       a = Glib::RefPtr<ToggleAction>::cast_dynamic (_region_actions->get_action("toggle-region-video-lock"));
+       a->set_active (have_video_locked && !have_video_unlocked);
+       if (have_video_locked && have_video_unlocked) {
+               // a->set_inconsistent ();
+       }
+
        a = Glib::RefPtr<ToggleAction>::cast_dynamic (_region_actions->get_action("toggle-region-lock-style"));
        a->set_active (have_position_lock_style_music && !have_position_lock_style_audio);