X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=gtk2_ardour%2Fmixer_ui.cc;h=85c5ebce1817f77c0e94afff8322e524abae66f5;hb=74eded425a5244831c80968c1781c3f81f90e996;hp=5bf480d4f9056dd52ec8375ef0473c285e5b485e;hpb=7e0e458f747748b020ee3b999657da84fa397eaa;p=ardour.git diff --git a/gtk2_ardour/mixer_ui.cc b/gtk2_ardour/mixer_ui.cc index 5bf480d4f9..85c5ebce18 100644 --- a/gtk2_ardour/mixer_ui.cc +++ b/gtk2_ardour/mixer_ui.cc @@ -28,6 +28,7 @@ #include #include #include +#include #include #include @@ -201,7 +202,11 @@ Mixer_UI::Mixer_UI () add (global_vpacker); set_name ("MixerWindow"); - set_title (_("ardour: mixer")); + + WindowTitle title(Glib::get_application_name()); + title += _("Mixer"); + set_title (title.get_string()); + set_wmclass (X_("ardour_mixer"), "Ardour"); add_accel_group (ActionManager::ui_manager->get_accel_group()); @@ -214,6 +219,31 @@ Mixer_UI::Mixer_UI () signal_configure_event().connect (mem_fun (*ARDOUR_UI::instance(), &ARDOUR_UI::configure_handler)); _selection.RoutesChanged.connect (mem_fun(*this, &Mixer_UI::follow_strip_selection)); + + mix_group_display_button_box->show(); + mix_group_add_button->show(); + mix_group_remove_button->show(); + + global_hpacker.show(); + global_vpacker.show(); + scroller.show(); + scroller_base.show(); + scroller_hpacker.show(); + mixer_scroller_vpacker.show(); + list_vpacker.show(); + group_display_button_label.show(); + group_display_button.show(); + track_display_scroller.show(); + group_display_scroller.show(); + group_display_vbox.show(); + track_display_frame.show(); + group_display_frame.show(); + rhs_pane1.show(); + strip_packer.show(); + out_packer.show(); + list_hpane.show(); + track_display.show(); + group_display.show(); } Mixer_UI::~Mixer_UI () @@ -229,7 +259,7 @@ Mixer_UI::ensure_float (Window& win) void Mixer_UI::show_window () { - show_all (); + present (); /* now reset each strips width so the right widgets are shown */ MixerStrip* ms; @@ -239,7 +269,7 @@ Mixer_UI::show_window () for (ri = rows.begin(); ri != rows.end(); ++ri) { ms = (*ri)[track_columns.strip]; - ms->set_width (ms->get_width()); + ms->set_width (ms->get_width(), ms->width_owner()); } _visible = true; } @@ -262,14 +292,17 @@ Mixer_UI::add_strip (Session::RouteList& routes) for (Session::RouteList::iterator x = routes.begin(); x != routes.end(); ++x) { boost::shared_ptr route = (*x); - if (route->hidden()) { + if (route->is_hidden()) { return; } strip = new MixerStrip (*this, *session, route); strips.push_back (strip); - strip->set_width (_strip_width); + if (strip->width_owner() != strip) { + strip->set_width (_strip_width, this); + } + show_strip (strip); no_track_list_redisplay = true; @@ -284,7 +317,7 @@ Mixer_UI::add_strip (Session::RouteList& routes) no_track_list_redisplay = false; redisplay_track_list (); - route->name_changed.connect (bind (mem_fun(*this, &Mixer_UI::strip_name_changed), strip)); + route->NameChanged.connect (bind (mem_fun(*this, &Mixer_UI::strip_name_changed), strip)); strip->GoingAway.connect (bind (mem_fun(*this, &Mixer_UI::remove_strip), strip)); strip->signal_button_release_event().connect (bind (mem_fun(*this, &Mixer_UI::strip_button_release_event), strip)); @@ -353,9 +386,11 @@ Mixer_UI::connect_to_session (Session* sess) XMLNode* node = ARDOUR_UI::instance()->mixer_settings(); set_state (*node); - string wintitle = _("ardour: mixer: "); - wintitle += session->name(); - set_title (wintitle); + WindowTitle title(session->name()); + title += _("Mixer"); + title += Glib::get_application_name(); + + set_title (title.get_string()); initial_track_display (); @@ -381,7 +416,12 @@ Mixer_UI::disconnect_from_session () ENSURE_GUI_THREAD(mem_fun(*this, &Mixer_UI::disconnect_from_session)); group_model->clear (); - set_title (_("ardour: mixer")); + _selection.clear (); + + WindowTitle title(Glib::get_application_name()); + title += _("Mixer"); + set_title (title.get_string()); + stop_updating (); } @@ -458,7 +498,7 @@ Mixer_UI::set_all_strips_visibility (bool yn) continue; } - if (strip->route()->master() || strip->route()->control()) { + if (strip->route()->is_master() || strip->route()->is_control()) { continue; } @@ -486,11 +526,11 @@ Mixer_UI::set_all_audio_visibility (int tracks, bool yn) continue; } - if (strip->route()->master() || strip->route()->control()) { + if (strip->route()->is_master() || strip->route()->is_control()) { continue; } - AudioTrack* at = strip->audio_track(); + boost::shared_ptr at = strip->audio_track(); switch (tracks) { case 0: @@ -590,7 +630,7 @@ Mixer_UI::redisplay_track_list () if (strip->packed()) { - if (strip->route()->master() || strip->route()->control()) { + if (strip->route()->is_master() || strip->route()->is_control()) { out_packer.reorder_child (*strip, -1); } else { strip_packer.reorder_child (*strip, -1); /* put at end */ @@ -598,18 +638,18 @@ Mixer_UI::redisplay_track_list () } else { - if (strip->route()->master() || strip->route()->control()) { + if (strip->route()->is_master() || strip->route()->is_control()) { out_packer.pack_start (*strip, false, false); } else { strip_packer.pack_start (*strip, false, false); } strip->set_packed (true); - strip->show_all (); + //strip->show(); } } else { - if (strip->route()->master() || strip->route()->control()) { + if (strip->route()->is_master() || strip->route()->is_control()) { /* do nothing, these cannot be hidden */ } else { if (strip->packed()) { @@ -687,7 +727,7 @@ Mixer_UI::track_display_button_press (GdkEventButton* ev) MixerStrip* strip = (*iter)[track_columns.strip]; if (strip) { - if (!strip->route()->master() && !strip->route()->control()) { + if (!strip->route()->is_master() && !strip->route()->is_control()) { bool visible = (*iter)[track_columns.visible]; (*iter)[track_columns.visible] = !visible; } @@ -723,9 +763,9 @@ Mixer_UI::build_track_menu () } void -Mixer_UI::strip_name_changed (void* src, MixerStrip* mx) +Mixer_UI::strip_name_changed (MixerStrip* mx) { - ENSURE_GUI_THREAD(bind (mem_fun(*this, &Mixer_UI::strip_name_changed), src, mx)); + ENSURE_GUI_THREAD(bind (mem_fun(*this, &Mixer_UI::strip_name_changed), mx)); TreeModel::Children rows = track_model->children(); TreeModel::Children::iterator i; @@ -1028,7 +1068,7 @@ Mixer_UI::set_strip_width (Width w) _strip_width = w; for (list::iterator i = strips.begin(); i != strips.end(); ++i) { - (*i)->set_width (w); + (*i)->set_width (w, this); } }