first compilable version of tabbable design.
[ardour.git] / gtk2_ardour / editor_mixer.cc
index 2154da5d70a007340a50745c7d3cf2a19a95cfe2..0651d30c1ebe7a7233fae968d56bf47ec647a847 100644 (file)
@@ -42,6 +42,7 @@
 #include "mixer_strip.h"
 #include "mixer_ui.h"
 #include "selection.h"
+#include "ui_config.h"
 
 #include "i18n.h"
 
@@ -77,9 +78,9 @@ Editor::show_editor_mixer (bool yn)
        show_editor_mixer_when_tracks_arrive = false;
 
        if (yn) {
-               Glib::RefPtr<Gdk::Window> win = get_window ();
+               Glib::RefPtr<Gdk::Window> win = current_toplevel()->get_window ();
                Glib::RefPtr<Gdk::Screen> screen;
-               
+
                if (win) {
                         screen = win->get_screen();
                } else {
@@ -183,28 +184,7 @@ Editor::create_editor_mixer ()
        current_mixer_strip->WidthChanged.connect (sigc::mem_fun(*this, &Editor::ensure_all_elements_drawn));
 #endif
        current_mixer_strip->set_embedded (true);
-       
-       current_mixer_strip->signal_enter_notify_event().connect (sigc::mem_fun(*this, &Editor::mixer_strip_enter_event ));
-       current_mixer_strip->signal_leave_notify_event().connect (sigc::mem_fun(*this, &Editor::mixer_strip_leave_event ));
-
-}
-
-bool
-Editor::mixer_strip_enter_event (GdkEventCrossing *ev)
-{
-       current_mixer_strip->set_selected(true);
-       return false;
-}
 
-bool
-Editor::mixer_strip_leave_event (GdkEventCrossing *ev)
-{
-       //if we have moved outside our strip, but not into a child view, then deselect ourselves
-       if ( !(ev->detail == GDK_NOTIFY_INFERIOR) ) {
-               current_mixer_strip->set_selected(false);
-       }
-       
-       return false;
 }
 
 void
@@ -304,7 +284,7 @@ Editor::track_mixer_selection ()
 void
 Editor::follow_mixer_selection ()
 {
-       if (!ARDOUR::Config->get_link_editor_and_mixer_selection() || _following_mixer_selection) {
+       if (_following_mixer_selection) {
                return;
        }