142 UI::instance()->set_tip (
mute_button,
_(
"Mute this track"),
"");
146 UI::instance()->set_tip (
solo_button,
_(
"Mute other (non-soloed) tracks"),
"");
161 UI::instance()->set_tip (
show_sends_button,
_(
"make mixer strips show sends to this bus"),
"");
337 if (ev->type == GDK_2BUTTON_PRESS || ev->type == GDK_3BUTTON_PRESS ) {
347 if (Keyboard::is_context_menu_event (ev)) {
359 if (Keyboard::is_button2_event (ev)) {
365 if (ev->button == 1 || Keyboard::is_button2_event (ev)) {
367 if (Keyboard::modifier_state_equals (ev->state,
Keyboard::ModifierMask (Keyboard::PrimaryModifier|Keyboard::TertiaryModifier))) {
381 for (RouteList::iterator i = copy->begin(); i != copy->end(); ) {
382 if ((*i)->is_master() || (*i)->is_monitor()) {
396 }
else if (Keyboard::modifier_state_equals (ev->state, Keyboard::PrimaryModifier)) {
404 if (ev->button == 1) {
464 if (!boost::dynamic_pointer_cast<InternalSend>(send)) {
506 if (ev->type == GDK_2BUTTON_PRESS || ev->type == GDK_3BUTTON_PRESS ) {
516 if (Keyboard::is_context_menu_event (ev)) {
530 if (Keyboard::is_button2_event (ev)) {
536 if (ev->button == 1 || Keyboard::is_button2_event (ev)) {
538 if (Keyboard::modifier_state_equals (ev->state,
Keyboard::ModifierMask (Keyboard::PrimaryModifier|Keyboard::TertiaryModifier))) {
547 if (
Config->get_solo_control_is_listen_control()) {
553 }
else if (Keyboard::modifier_state_contains (ev->state,
Keyboard::ModifierMask (Keyboard::PrimaryModifier|Keyboard::SecondaryModifier))) {
562 for (RouteList::iterator i = routes->begin(); i != routes->end(); ++i) {
563 if ((*i)->soloed ()) {
571 if (
Config->get_solo_control_is_listen_control()) {
578 }
else if (Keyboard::modifier_state_equals (ev->state, Keyboard::TertiaryModifier)) {
586 }
else if (Keyboard::modifier_state_equals (ev->state, Keyboard::PrimaryModifier)) {
598 if (ev->button == 1) {
613 if (
Config->get_solo_control_is_listen_control()) {
625 rl->push_back (
route());
632 if (
Config->get_solo_control_is_listen_control()) {
653 if (
Config->get_solo_control_is_listen_control()) {
670 if (ev->type == GDK_2BUTTON_PRESS || ev->type == GDK_3BUTTON_PRESS ) {
679 MessageDialog msg (
_(
"Not connected to AudioEngine - cannot engage record"));
696 if (Keyboard::is_button2_event (ev)) {
701 }
else if (Keyboard::modifier_state_equals (ev->state,
Keyboard::ModifierMask (Keyboard::PrimaryModifier|Keyboard::TertiaryModifier))) {
706 }
else if (Keyboard::modifier_state_equals (ev->state, Keyboard::PrimaryModifier)) {
712 if (ev->button == 1) {
729 }
else if (Keyboard::is_context_menu_event (ev)) {
736 rl->push_back (
route());
814 if (ev->button != 1) {
840 if (Keyboard::modifier_state_equals (ev->state,
Keyboard::ModifierMask (Keyboard::PrimaryModifier|Keyboard::TertiaryModifier))) {
843 }
else if (Keyboard::modifier_state_equals (ev->state, Keyboard::PrimaryModifier)) {
848 rl->push_back (
route());
852 rl->push_back (
route());
875 using namespace Menu_Helpers;
879 step_edit_item =
dynamic_cast<Gtk::CheckMenuItem*
> (&items.back());
930 if (Keyboard::is_context_menu_event (ev)) {
944 using namespace Menu_Helpers;
999 for (TrackSelection::iterator i = selected_tracks.begin(); i != selected_tracks.end(); ++i) {
1002 if ((rtv = dynamic_cast<RouteTimeAxisView*>(*i)) != 0) {
1003 if ((rui = dynamic_cast<RouteUI*>(rtv)) != 0) {
1004 if (include_buses || boost::dynamic_pointer_cast<AudioTrack>(rui->
route())) {
1005 rlist->push_back (rui->
route());
1035 if (ev->type == GDK_2BUTTON_PRESS || ev->type == GDK_3BUTTON_PRESS ) {
1041 if (Keyboard::is_button2_event (ev) && Keyboard::modifier_state_equals (ev->state, Keyboard::PrimaryModifier)) {
1046 }
else if (Keyboard::is_context_menu_event (ev)) {
1089 Gtkmm2ext::ActiveState
1096 if (
Config->get_solo_control_is_listen_control()) {
1117 Gtkmm2ext::ActiveState
1131 Gtkmm2ext::ActiveState
1196 return ActiveState(0);
1200 if (
Config->get_show_solo_mutes() && !
Config->get_solo_control_is_listen_control ()) {
1224 return ActiveState(0);
1263 case Session::Recording:
1267 case Session::Disabled:
1268 case Session::Enabled:
1296 using namespace Menu_Helpers;
1299 solo_menu->set_name (
"ArdourContextMenu");
1301 Gtk::CheckMenuItem* check;
1303 check =
new Gtk::CheckMenuItem(
_(
"Solo Isolate"));
1306 items.push_back (CheckMenuElem(*check));
1310 check =
new Gtk::CheckMenuItem(
_(
"Solo Safe"));
1313 items.push_back (CheckMenuElem(*check));
1325 using namespace Menu_Helpers;
1328 mute_menu->set_name (
"ArdourContextMenu");
1371 if (check->get_active()) {
1398 yn = (current & MuteMaster::Listen);
1404 yn = (current & MuteMaster::Main);
1414 if (ev->type == GDK_2BUTTON_PRESS || ev->type == GDK_3BUTTON_PRESS) {
1423 if (ev->button == 1) {
1424 if (Keyboard::modifier_state_equals (ev->state,
Keyboard::ModifierMask (Keyboard::PrimaryModifier|Keyboard::TertiaryModifier))) {
1433 if (model == view) {
1451 if (ev->button == 1) {
1460 bool view = check->get_active();
1465 if (model != view) {
1501 snprintf (buf,
sizeof (buf),
"%d:%d:%d", c.get_red(), c.get_green(), c.get_blue());
1529 sscanf (str.c_str(),
"%d:%d:%d", &r, &g, &b);
1542 if (name.find (
':') == string::npos) {
1546 MessageDialog colon_msg (
1547 _(
"The use of colons (':') is discouraged in track and bus names.\nDo you want to use this new name?"),
1548 false, MESSAGE_QUESTION, BUTTONS_NONE
1551 colon_msg.add_button (
_(
"Use the new name"), Gtk::RESPONSE_ACCEPT);
1552 colon_msg.add_button (
_(
"Re-edit the name"), Gtk::RESPONSE_CANCEL);
1554 return (colon_msg.run () == Gtk::RESPONSE_ACCEPT);
1565 name_prompter.set_title (
_(
"Rename Track"));
1567 name_prompter.set_title (
_(
"Rename Bus"));
1571 name_prompter.add_button (
_(
"Rename"), Gtk::RESPONSE_ACCEPT);
1572 name_prompter.set_response_sensitive (Gtk::RESPONSE_ACCEPT,
false);
1573 name_prompter.show_all ();
1576 switch (name_prompter.run ()) {
1577 case Gtk::RESPONSE_ACCEPT:
1579 name_prompter.hide ();
1580 if (result.length()) {
1635 title +=
_(
": comment editor");
1678 string const str =
comment_area->get_buffer()->get_text();
1689 if (apply_to_selection) {
1788 case AudioTrack::Frozen:
1808 std::string safe_name;
1813 if (g_mkdir_with_parents (path.c_str(), 0755)) {
1820 p.set_title (
_(
"Save As Template"));
1822 p.add_button (Gtk::Stock::SAVE, Gtk::RESPONSE_ACCEPT);
1824 case RESPONSE_ACCEPT:
1836 path = Glib::build_filename (path, safe_name);
1858 if (p ==
"disable-disarm-during-roll") {
1860 }
else if (p ==
"use-monitor-bus" || p ==
"solo-control-is-listen-control" || p ==
"listen-position") {
1862 }
else if (p ==
"auto-input") {
1864 }
else if (p ==
"blink-rec-arm") {
1903 SpinButton* spin = 0;
1905 dialog.get_vbox()->set_border_width (18);
1910 HBox* hbox = manage (
new HBox);
1911 hbox->set_spacing (6);
1912 hbox->pack_start (*manage (
new Label (
_(
"Remote control ID:"))));
1913 spin = manage (
new SpinButton);
1914 spin->set_digits (0);
1915 spin->set_increments (1, 10);
1916 spin->set_range (0, limit);
1918 hbox->pack_start (*spin);
1919 dialog.get_vbox()->pack_start (*hbox);
1921 dialog.add_button (Stock::CANCEL, RESPONSE_CANCEL);
1922 dialog.add_button (Stock::APPLY, RESPONSE_ACCEPT);
1924 Label* l = manage (
new Label());
1926 l->set_markup (
string_compose (
_(
"The remote control ID of %1 is: %2\n\n\n"
1927 "The remote control ID of %3 cannot be changed."),
1932 l->set_markup (
string_compose (
_(
"The remote control ID of %5 is: %2\n\n\n"
1933 "Remote Control IDs are currently determined by track/bus ordering in %6.\n\n"
1934 "%3Use the User Interaction tab of the Preferences window if you want to change this%4"),
1937 "<span size=\"small\" style=\"italic\">",
1942 dialog.get_vbox()->pack_start (*l);
1943 dialog.add_button (Stock::OK, RESPONSE_CANCEL);
1947 int const r = dialog.run ();
1949 if (r == RESPONSE_ACCEPT && spin) {
1968 uint32_t
const N =
_route->
input()->n_ports().n_audio ();
1972 for (uint32_t i = 0; i < to_add; ++i) {
1975 b->signal_button_release_event().connect (sigc::bind (sigc::mem_fun (*
this, &
RouteUI::invert_release), i),
false);
1977 b->set_name (
X_(
"invert button"));
1989 UI::instance()->set_tip (*b,
string_compose (
_(
"Left-click to invert (phase reverse) channel %1 of this track. Right-click to show menu."), i + 1));
1991 UI::instance()->set_tip (*b,
_(
"Click to show a menu of channels for inversion (phase reverse)"));
2005 uint32_t
const N =
_route->
input()->n_ports().n_audio();
2038 uint32_t
const N =
_route->
input()->n_ports().n_audio ();
2052 using namespace Menu_Helpers;
2054 uint32_t
const N =
_route->
input()->n_ports().n_audio();
2055 if (N <= _max_invert_buttons && ev->button != 3) {
2068 for (uint32_t i = 0; i <
N; ++i) {
2070 Gtk::CheckMenuItem* e =
dynamic_cast<Gtk::CheckMenuItem*
> (&items.back ());
2095 (*b)->set_sensitive (yn);
2111 if (what_changed ==
"color") {
2122 switch (
track()->mode()) {
void set_route_active(bool, bool)
bool transport_rolling() const
void open_comment_editor()
bool rec_enable_press(GdkEventButton *)
void track_mode_changed()
Gtk::CheckMenuItem * pre_fader_mute_check
virtual void denormal_protection_changed()
virtual void start_step_editing()
static uint32_t _max_invert_buttons
void set_listen(boost::shared_ptr< RouteList >, bool, SessionEvent::RTeventCallback after=rt_cleanup, bool group_override=false)
void update_mute_display()
boost::shared_ptr< ARDOUR::MidiTrack > midi_track() const
virtual void route_color_changed()
void open_remote_control_id_dialog()
PBD::Signal0< void > TransportStateChange
std::string get_string(const std::string &id, const std::string &prop_name, bool *empty=0)
PBD::Signal0< void > DropReferences
ArdourButton * show_sends_button
PBD::Signal0< void > TrackModeChanged
void add_internal_sends(boost::shared_ptr< Route > dest, Placement p, boost::shared_ptr< RouteList > senders)
void set_solo(boost::shared_ptr< RouteList >, bool, SessionEvent::RTeventCallback after=rt_cleanup, bool group_override=false)
void toggle_mute_menu(ARDOUR::MuteMaster::MutePoint, Gtk::CheckMenuItem *)
PBD::Signal1< void, const PropertyChange & > PropertyChanged
void set_mute_points(MuteMaster::MutePoint)
bool is_midi_track() const
sigc::connection rec_blink_connection
void set_sends_gain_from_track()
Gtk::HBox _invert_button_box
void globally_set_send_gains_to_unity(boost::shared_ptr< Route > dest)
boost::shared_ptr< ARDOUR::RouteList > routes
bool is_audio_track() const
void monitoring_changed()
void build_mute_menu(void)
LIBARDOUR_API std::string legalize_for_path(const std::string &str)
bool has_audio_outputs() const
void edit_input_configuration()
shared_ptr< T > dynamic_pointer_cast(shared_ptr< U > const &r)
static ARDOUR_UI * instance()
void set_gain(gain_t val, void *src)
LIBARDOUR_API PBD::PropertyDescriptor< std::string > name
void update_monitoring_display()
PBD::Signal0< void > SoloChanged
void setup_comment_editor()
Gtk::CheckMenuItem * solo_safe_check
PBD::Signal1< void, void * > comment_changed
void globally_set_send_gains_from_track(boost::shared_ptr< Route > dest)
static Gdk::Color unique_random_color()
boost::shared_ptr< AutomationControl > gain_control() const
boost::shared_ptr< ARDOUR::RouteList > routes_on
PBD::Signal0< void > io_changed
void set_record_enabled(boost::shared_ptr< RouteList >, bool, SessionEvent::RTeventCallback after=rt_cleanup, bool group_override=false)
virtual void set_route(boost::shared_ptr< ARDOUR::Route >)
bool monitor_disk_press(GdkEventButton *)
LIBPBD_API Transmitter error
void set_solo_isolated(bool yn, void *src)
IOSelectorWindow * input_selector
bool set_name(const std::string &str)
void set_solo_safe(bool yn, void *src)
PublicEditor & the_editor()
int save_as_template(const std::string &path, const std::string &name)
std::ostream & endmsg(std::ostream &ostr)
SessionConfiguration config
RecordState record_status() const
void set_sends_gain_to_unity()
Gtk::CheckMenuItem * step_edit_item
PBD::Signal1< void, void * > solo_isolated_changed
boost::shared_ptr< AutomationControl > rec_enable_control()
framecnt_t frame_rate() const
void set_invert_sensitive(bool)
#define ENSURE_GUI_THREAD(obj, method,...)
Gtk::CheckMenuItem * post_fader_mute_check
static void set_showing_sends_to(boost::shared_ptr< ARDOUR::Route >)
void set_initial_text(std::string txt)
static float accurate_coefficient_to_dB(float coeff)
ArdourWindow * comment_window
virtual void set_color(const Gdk::Color &c)
void set_remote_control_id(uint32_t id, bool notify_class_listeners=true)
virtual void step_edit_changed(bool)
void session_rec_enable_changed()
virtual void route_active_changed()
Gtk::CheckMenuItem * listen_mute_check
PBD::Signal1< void, bool > StepEditStatusChange
void set_denormal_protection(bool yn)
bool monitor_input_release(GdkEventButton *)
ArdourButton * rec_enable_button
void route_rec_enable_changed()
MuteMaster::MutePoint mute_points() const
boost::shared_ptr< ARDOUR::Route > _route
void set_invert_button_state()
bool phase_invert(uint32_t) const
PBD::Signal1< void, void * > solo_safe_changed
virtual bool record_enabled() const
bool show_sends_release(GdkEventButton *)
LIBARDOUR_API std::string user_route_template_directory()
IOSelectorWindow * output_selector
bool denormal_protection() const
ArdourButton * solo_button
static Gtkmm2ext::ActiveState solo_isolate_active_state(boost::shared_ptr< ARDOUR::Route >)
PBD::Signal2< void, std::string, void * > gui_changed
LIBARDOUR_API RCConfiguration * Config
SoloMuteRelease * _solo_release
void comment_changed(void *src)
void set_color_from_rgba(Gdk::Color &, uint32_t)
bool listening_via_monitor() const
void set_prompt(std::string prompt)
virtual void blink_rec_display(bool onoff)
bool monitor_disk_release(GdkEventButton *)
ArdourButton * monitor_input_button
Gdk::Color get_color(const std::string &prompt, bool &picked, const Gdk::Color *initial=0)
bool solo_press(GdkEventButton *)
void toggle_comment_editor()
void set_phase_invert(uint32_t, bool yn)
const PBD::ID & id() const
static bool is_bind_action(GdkEventButton *)
void set_just_one_solo(boost::shared_ptr< Route >, bool, SessionEvent::RTeventCallback after=rt_cleanup)
void parameter_changed(std::string const &)
void remove_node(const std::string &id)
boost::shared_ptr< ARDOUR::Track > track() const
ChanCount n_outputs() const
PBD::Signal0< void > active_changed
static Gtkmm2ext::ActiveState mute_active_state(ARDOUR::Session *, boost::shared_ptr< ARDOUR::Route >)
boost::shared_ptr< ARDOUR::Delivery > _current_delivery
PBD::Signal1< void, void * > listen_changed
virtual void map_frozen()
void setup_invert_buttons()
boost::shared_ptr< RouteList > get_routes() const
static Gtkmm2ext::ActiveState solo_active_state(boost::shared_ptr< ARDOUR::Route >)
virtual Selection & get_selection() const =0
static Gtkmm2ext::ActiveState solo_safe_active_state(boost::shared_ptr< ARDOUR::Route >)
ARDOUR::RouteGroup * route_group() const
PBD::ScopedConnectionList _session_connections
static GUIObjectState & gui_object_state()
bool multiple_mute_change
PBD::Signal1< void, std::string > ParameterChanged
void check_rec_enable_sensitivity()
PBD::Signal0< void > RecordStateChanged
sigc::connection blink_connect(const sigc::slot< void, bool > &slot)
void get_result(std::string &str, bool strip=true)
PBD::Signal0< void > mute_points_changed
void set_step_editing(bool yn)
PBD::Signal2< void, bool, void * > solo_changed
void globally_set_send_gains_to_zero(boost::shared_ptr< Route > dest)
bool solo_isolate_button_release(GdkEventButton *)
void create_selected_sends(ARDOUR::Placement, bool)
LIBARDOUR_API const char *const template_suffix
bool is_monitoring() const
MonitorState monitoring_state() const
static uint32_t group_color(ARDOUR::RouteGroup *)
void toggle_denormal_protection()
void foreach_route_ui(Function f)
bool show_sends_press(GdkEventButton *)
MonitorChoice monitoring_choice() const
void set_active(bool yn, void *)
void toggle_solo_isolated(Gtk::CheckMenuItem *)
void create_sends(ARDOUR::Placement, bool)
PBD::Signal1< void, void * > mute_changed
virtual void property_changed(const PBD::PropertyChange &)
ArdourButton * mute_button
boost::shared_ptr< SoloControllable > solo_control() const
bool multiple_solo_change
void set_comment(std::string str, void *src)
void init_mute_menu(ARDOUR::MuteMaster::MutePoint, Gtk::CheckMenuItem *)
RouteGroup * route_group() const
boost::shared_ptr< IO > output()
boost::shared_ptr< RouteList > route_list()
static UIConfiguration * config()
Gtk::CheckMenuItem * solo_isolated_check
Gtk::CheckMenuItem * main_mute_check
PBD::Signal0< void > MonitoringChanged
bool invert_press(GdkEventButton *)
void set_monitoring(boost::shared_ptr< RouteList >, MonitorChoice, SessionEvent::RTeventCallback after=rt_cleanup, bool group_override=false)
boost::shared_ptr< MuteControllable > mute_control() const
static boost::weak_ptr< ARDOUR::Route > _showing_sends_to
bool solo_release(GdkEventButton *)
std::vector< ArdourButton * > _invert_buttons
boost::shared_ptr< IO > input() const
void solo_changed_so_update_mute()
bool rec_enable_release(GdkEventButton *)
virtual void set_button_names()=0
PBD::Signal0< void > RecordEnableChanged
virtual void stop_step_editing()
static float dB_to_coefficient(float dB)
void edit_output_configuration()
bool invert_release(GdkEventButton *, uint32_t i)
FreezeState freeze_state() const
bool contains(PropertyDescriptor< T > p) const
SoloMuteRelease * _mute_release
void set_property(const std::string &id, const std::string &prop_name, const T &val)
bool monitor_input_press(GdkEventButton *)
Gtk::TextView * comment_area
boost::shared_ptr< IO > output() const
uint32_t remote_control_id() const
bool mute_press(GdkEventButton *)
bool solo_safe_button_release(GdkEventButton *)
boost::shared_ptr< ARDOUR::AudioTrack > audio_track() const
bool mute_release(GdkEventButton *)
void set_solo_isolated(boost::shared_ptr< RouteList >, bool, SessionEvent::RTeventCallback after=rt_cleanup, bool group_override=false)
void invert_menu_toggled(uint32_t)
void comment_editor_done_editing()
void route_gui_changed(std::string)
ArdourButton * solo_isolated_led
std::list< boost::shared_ptr< Route > > RouteList
std::string route_state_id() const
PBD::Signal0< void > phase_invert_changed
void toggle_solo_safe(Gtk::CheckMenuItem *)
PBD::ScopedConnectionList route_connections
bool solo_isolated() const
ARDOUR::Session * _session
boost::shared_ptr< ARDOUR::Route > route() const
ArdourButton * solo_safe_led
void set_sends_gain_to_zero()
static PBD::Signal1< void, boost::shared_ptr< ARDOUR::Route > > BusSendDisplayChanged
Gtk::CheckMenuItem * denormal_menu_item
int set_color_from_route()
sigc::connection send_blink_connection
std::string string_compose(const std::string &fmt, const T1 &o1)
void set_mute(boost::shared_ptr< RouteList >, bool, SessionEvent::RTeventCallback after=rt_cleanup, bool group_override=false)
void update_solo_display()
bool monitor_release(GdkEventButton *, ARDOUR::MonitorChoice)
ArdourButton * monitor_disk_button
RouteUI(ARDOUR::Session *)
virtual void polarity_changed()
virtual void bus_send_display_changed(boost::shared_ptr< ARDOUR::Route >)
boost::shared_ptr< ARDOUR::RouteList > routes_off
void globally_add_internal_sends(boost::shared_ptr< Route > dest, Placement p, bool)
bool verify_new_route_name(const std::string &name)