mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-10 08:36:32 +01:00
use track colour to set comment button background rather than use active button state, mut and solo right-click action is now consistent with the rest of the ui, reorder sfdb dialog buttons
git-svn-id: svn://localhost/ardour2/trunk@1096 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
1c9d8ed39d
commit
20cf901da9
4 changed files with 14 additions and 20 deletions
|
|
@ -232,8 +232,6 @@ MixerStrip::MixerStrip (Mixer_UI& mx, Session& sess, boost::shared_ptr<Route> rt
|
||||||
_route->comment());
|
_route->comment());
|
||||||
|
|
||||||
comment_button.signal_clicked().connect (mem_fun(*this, &MixerStrip::comment_button_clicked));
|
comment_button.signal_clicked().connect (mem_fun(*this, &MixerStrip::comment_button_clicked));
|
||||||
comment_button.signal_enter().connect (mem_fun(*this, &MixerStrip::comment_button_refresh));
|
|
||||||
comment_button.signal_leave().connect (mem_fun(*this, &MixerStrip::comment_button_refresh));
|
|
||||||
|
|
||||||
global_vpacker.set_border_width (0);
|
global_vpacker.set_border_width (0);
|
||||||
global_vpacker.set_spacing (0);
|
global_vpacker.set_spacing (0);
|
||||||
|
|
@ -420,8 +418,10 @@ MixerStrip::set_width (Width w)
|
||||||
solo_button->set_label (_("solo"));
|
solo_button->set_label (_("solo"));
|
||||||
|
|
||||||
if (_route->comment() == "") {
|
if (_route->comment() == "") {
|
||||||
|
comment_button.unset_bg (STATE_NORMAL);
|
||||||
comment_button.set_label (_("comments"));
|
comment_button.set_label (_("comments"));
|
||||||
} else {
|
} else {
|
||||||
|
comment_button.modify_bg (STATE_NORMAL, color());
|
||||||
comment_button.set_label (_("*comments*"));
|
comment_button.set_label (_("*comments*"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -443,8 +443,10 @@ MixerStrip::set_width (Width w)
|
||||||
solo_button->set_label (_("S"));
|
solo_button->set_label (_("S"));
|
||||||
|
|
||||||
if (_route->comment() == "") {
|
if (_route->comment() == "") {
|
||||||
|
comment_button.unset_bg (STATE_NORMAL);
|
||||||
comment_button.set_label (_("Cmt"));
|
comment_button.set_label (_("Cmt"));
|
||||||
} else {
|
} else {
|
||||||
|
comment_button.modify_bg (STATE_NORMAL, color());
|
||||||
comment_button.set_label (_("*Cmt*"));
|
comment_button.set_label (_("*Cmt*"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -761,12 +763,6 @@ MixerStrip::output_changed (IOChange change, void *src)
|
||||||
Gtkmm2ext::UI::instance()->call_slot (mem_fun(*this, &MixerStrip::update_output_display));
|
Gtkmm2ext::UI::instance()->call_slot (mem_fun(*this, &MixerStrip::update_output_display));
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
MixerStrip::comment_button_refresh() {
|
|
||||||
if (! _route->comment().empty()) {
|
|
||||||
comment_button.set_state (Gtk::STATE_ACTIVE);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
void
|
||||||
MixerStrip::comment_editor_done_editing() {
|
MixerStrip::comment_editor_done_editing() {
|
||||||
|
|
@ -778,16 +774,20 @@ MixerStrip::comment_editor_done_editing() {
|
||||||
|
|
||||||
case Wide:
|
case Wide:
|
||||||
if (! str.empty()) {
|
if (! str.empty()) {
|
||||||
|
comment_button.modify_bg (STATE_NORMAL, color());
|
||||||
comment_button.set_label (_("*Comments*"));
|
comment_button.set_label (_("*Comments*"));
|
||||||
} else {
|
} else {
|
||||||
|
comment_button.unset_bg (STATE_NORMAL);
|
||||||
comment_button.set_label (_("Comments"));
|
comment_button.set_label (_("Comments"));
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case Narrow:
|
case Narrow:
|
||||||
if (! str.empty()) {
|
if (! str.empty()) {
|
||||||
|
comment_button.modify_bg (STATE_NORMAL, color());
|
||||||
comment_button.set_label (_("*Cmt*"));
|
comment_button.set_label (_("*Cmt*"));
|
||||||
} else {
|
} else {
|
||||||
|
comment_button.unset_bg (STATE_NORMAL);
|
||||||
comment_button.set_label (_("Cmt"));
|
comment_button.set_label (_("Cmt"));
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
@ -797,11 +797,6 @@ MixerStrip::comment_editor_done_editing() {
|
||||||
str.empty() ? _("Click to Add/Edit Comments") : str);
|
str.empty() ? _("Click to Add/Edit Comments") : str);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! _route->comment().empty()) {
|
|
||||||
comment_button.set_state (Gtk::STATE_ACTIVE);
|
|
||||||
} else {
|
|
||||||
comment_button.set_state (Gtk::STATE_NORMAL);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
||||||
|
|
@ -153,7 +153,6 @@ class MixerStrip : public RouteUI, public Gtk::EventBox
|
||||||
Gtk::TextView* comment_area;
|
Gtk::TextView* comment_area;
|
||||||
Gtk::Button comment_button;
|
Gtk::Button comment_button;
|
||||||
|
|
||||||
void comment_button_refresh();
|
|
||||||
void comment_editor_done_editing();
|
void comment_editor_done_editing();
|
||||||
void setup_comment_editor ();
|
void setup_comment_editor ();
|
||||||
void comment_button_clicked ();
|
void comment_button_clicked ();
|
||||||
|
|
|
||||||
|
|
@ -119,7 +119,7 @@ RouteUI::mute_press(GdkEventButton* ev)
|
||||||
build_mute_menu();
|
build_mute_menu();
|
||||||
}
|
}
|
||||||
|
|
||||||
mute_menu->popup(0,0);
|
mute_menu->popup(0,ev->time);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
|
@ -194,7 +194,7 @@ RouteUI::solo_press(GdkEventButton* ev)
|
||||||
build_solo_menu ();
|
build_solo_menu ();
|
||||||
}
|
}
|
||||||
|
|
||||||
solo_menu->popup (1, 0);
|
solo_menu->popup (1, ev->time);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
|
@ -494,7 +494,7 @@ RouteUI::build_solo_menu (void)
|
||||||
items.push_back (CheckMenuElem(*check));
|
items.push_back (CheckMenuElem(*check));
|
||||||
check->show_all();
|
check->show_all();
|
||||||
|
|
||||||
items.push_back (SeparatorElem());
|
//items.push_back (SeparatorElem());
|
||||||
// items.push_back (MenuElem (_("MIDI Bind"), mem_fun (*mute_button, &BindableToggleButton::midi_learn)));
|
// items.push_back (MenuElem (_("MIDI Bind"), mem_fun (*mute_button, &BindableToggleButton::midi_learn)));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -537,7 +537,7 @@ RouteUI::build_mute_menu(void)
|
||||||
items.push_back (CheckMenuElem(*check));
|
items.push_back (CheckMenuElem(*check));
|
||||||
check->show_all();
|
check->show_all();
|
||||||
|
|
||||||
items.push_back (SeparatorElem());
|
//items.push_back (SeparatorElem());
|
||||||
// items.push_back (MenuElem (_("MIDI Bind"), mem_fun (*mute_button, &BindableToggleButton::midi_learn)));
|
// items.push_back (MenuElem (_("MIDI Bind"), mem_fun (*mute_button, &BindableToggleButton::midi_learn)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -377,12 +377,12 @@ SoundFileOmega::SoundFileOmega (string title, ARDOUR::Session* s)
|
||||||
ARDOUR_UI::instance()->tooltips().set_tip(*btn,
|
ARDOUR_UI::instance()->tooltips().set_tip(*btn,
|
||||||
_("Link to an external file"));
|
_("Link to an external file"));
|
||||||
|
|
||||||
|
add_button (Gtk::Stock::CLOSE, Gtk::RESPONSE_CLOSE);
|
||||||
|
|
||||||
btn = add_button (_("Import"), ResponseImport);
|
btn = add_button (_("Import"), ResponseImport);
|
||||||
ARDOUR_UI::instance()->tooltips().set_tip(*btn,
|
ARDOUR_UI::instance()->tooltips().set_tip(*btn,
|
||||||
_("Copy a file to the session folder"));
|
_("Copy a file to the session folder"));
|
||||||
|
|
||||||
add_button (Gtk::Stock::CLOSE, Gtk::RESPONSE_CLOSE);
|
|
||||||
|
|
||||||
Gtk::HBox *box = manage (new Gtk::HBox());
|
Gtk::HBox *box = manage (new Gtk::HBox());
|
||||||
|
|
||||||
Gtkmm2ext::set_popdown_strings (mode_combo, mode_strings);
|
Gtkmm2ext::set_popdown_strings (mode_combo, mode_strings);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue