X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=gtk2_ardour%2Fmixer_ui.h;h=4ab48ffd3135c708bf00021cf66c7e4b325736aa;hb=c912bd61ae49cc79158f3322439c29b27ef51de8;hp=2c5081dbcc408b726ba13277ab9e2ef8b261dbd3;hpb=da8eec7a8311295ee91308eca9fae2146385c512;p=ardour.git diff --git a/gtk2_ardour/mixer_ui.h b/gtk2_ardour/mixer_ui.h index 2c5081dbcc..4ab48ffd31 100644 --- a/gtk2_ardour/mixer_ui.h +++ b/gtk2_ardour/mixer_ui.h @@ -37,10 +37,13 @@ #include "pbd/signals.h" #include "ardour/ardour.h" +#include "ardour/types.h" #include "ardour/session_handle.h" -#include "route_processor_selection.h" +#include "gtkmm2ext/visibility_tracker.h" + #include "enums.h" +#include "mixer_actor.h" namespace ARDOUR { class Route; @@ -52,17 +55,18 @@ class PluginSelector; class MixerGroupTabs; class MonitorSection; -class Mixer_UI : public Gtk::Window, public PBD::ScopedConnectionList, public ARDOUR::SessionHandlePtr +class Mixer_UI : public Gtk::Window, public PBD::ScopedConnectionList, public ARDOUR::SessionHandlePtr, public MixerActor, public Gtkmm2ext::VisibilityTracker { public: - Mixer_UI (); + static Mixer_UI* instance(); ~Mixer_UI(); void set_session (ARDOUR::Session *); + void track_editor_selection (); PluginSelector* plugin_selector(); - void set_strip_width (Width); + void set_strip_width (Width, bool save = false); Width get_strip_width () const { return _strip_width; } void unselect_strip_in_display (MixerStrip*); @@ -76,14 +80,25 @@ class Mixer_UI : public Gtk::Window, public PBD::ScopedConnectionList, public AR void show_strip (MixerStrip *); void hide_strip (MixerStrip *); + void maximise_mixer_space(); + void restore_mixer_space(); + void ensure_float (Gtk::Window&); - void toggle_auto_rebinding (); - void set_auto_rebinding(bool); - RouteRedirectSelection& selection() { return _selection; } MonitorSection* monitor_section() const { return _monitor_section; } + void deselect_all_strip_processors(); + void delete_processors(); + + void select_none (); + + protected: + void set_route_targets_for_operation (); + private: + Mixer_UI (); + static Mixer_UI* _instance; + bool _visible; Gtk::HBox global_hpacker; @@ -124,10 +139,13 @@ class Mixer_UI : public Gtk::Window, public PBD::ScopedConnectionList, public AR bool strip_scroller_button_release (GdkEventButton*); void scroll_left (); void scroll_right (); + void toggle_midi_input_active (bool flip_others); - void add_strip (ARDOUR::RouteList&); + void add_strips (ARDOUR::RouteList&); void remove_strip (MixerStrip *); + MixerStrip* strip_by_route (boost::shared_ptr); + void hide_all_strips (bool with_select); void unselect_all_strips(); void select_all_strips (); @@ -136,14 +154,9 @@ class Mixer_UI : public Gtk::Window, public PBD::ScopedConnectionList, public AR void unselect_all_audiobus_strips (); void select_all_audiobus_strips (); - void auto_rebind_midi_controls (); - bool auto_rebinding; - void strip_select_op (bool audiotrack, bool select); void select_strip_op (MixerStrip*, bool select); - void follow_strip_selection (); - gint start_updating (); gint stop_updating (); @@ -159,15 +172,16 @@ class Mixer_UI : public Gtk::Window, public PBD::ScopedConnectionList, public AR bool track_display_button_press (GdkEventButton*); void strip_width_changed (); - void track_list_change (const Gtk::TreeModel::Path&,const Gtk::TreeModel::iterator&); void track_list_delete (const Gtk::TreeModel::Path&); void track_list_reorder (const Gtk::TreeModel::Path& path, const Gtk::TreeModel::iterator& iter, int* new_order); void initial_track_display (); void show_track_list_menu (); - + void set_all_strips_visibility (bool yn); void set_all_audio_visibility (int tracks, bool yn); + void track_visibility_changed (std::string const & path); + void update_track_visibility (); void hide_all_routes (); void show_all_routes (); @@ -189,6 +203,7 @@ class Mixer_UI : public Gtk::Window, public PBD::ScopedConnectionList, public AR void route_groups_changed (); void route_group_name_edit (const std::string&, const std::string&); void route_group_row_change (const Gtk::TreeModel::Path& path,const Gtk::TreeModel::iterator& iter); + void route_group_row_deleted (Gtk::TreeModel::Path const &); Gtk::Menu *track_menu; void track_column_click (gint); @@ -240,22 +255,42 @@ class Mixer_UI : public Gtk::Window, public PBD::ScopedConnectionList, public AR bool strip_button_release_event (GdkEventButton*, MixerStrip*); - RouteRedirectSelection _selection; - Width _strip_width; - void sync_order_keys (std::string const &); - bool strip_redisplay_does_not_reset_order_keys; - bool strip_redisplay_does_not_sync_order_keys; - bool ignore_sync; + void sync_order_keys_from_treeview (); + void sync_treeview_from_order_keys (); + void reset_remote_control_ids (); + void reset_order_keys (); + + bool ignore_reorder; void parameter_changed (std::string const &); void set_route_group_activation (ARDOUR::RouteGroup *, bool); + void setup_track_display (); + void new_track_or_bus (); + static const int32_t default_width = 478; static const int32_t default_height = 765; + /** true if we are rebuilding the route group list, or clearing + it during a session teardown. + */ + bool _in_group_rebuild_or_clear; + bool _route_deletion_in_progress; + + void update_title (); + MixerStrip* strip_by_x (int x); + friend class MixerGroupTabs; + + void follow_editor_selection (); + bool _following_editor_selection; + + void monitor_section_going_away (); + + /// true if we are in fullscreen mode + bool _maximised; }; #endif /* __ardour_mixer_ui_h__ */