mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-14 10:36:34 +01:00
various tweaks to get 80% Of the way to proper use of TimeAxisView::name_label and TimeAxisView::name_entry. Not done yet, since the entry sometimes loses focus and cannot be hidden.
git-svn-id: svn://localhost/ardour2/branches/3.0@13836 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
e40a8b384b
commit
f269d7c56e
5 changed files with 59 additions and 41 deletions
|
|
@ -148,17 +148,13 @@ VisualTimeAxis::set_height(uint32_t h)
|
|||
{
|
||||
TimeAxisView::set_height(h);
|
||||
|
||||
show_name_label ();
|
||||
|
||||
if (h >= hNormal) {
|
||||
hide_name_label ();
|
||||
show_name_entry ();
|
||||
other_button_hbox.show_all() ;
|
||||
} else if (h >= hSmaller) {
|
||||
hide_name_label ();
|
||||
show_name_entry ();
|
||||
other_button_hbox.hide_all() ;
|
||||
} else if (h >= hSmall) {
|
||||
hide_name_entry ();
|
||||
show_name_label ();
|
||||
other_button_hbox.hide_all() ;
|
||||
}
|
||||
}
|
||||
|
|
@ -339,9 +335,9 @@ VisualTimeAxis::start_time_axis_rename()
|
|||
void
|
||||
VisualTimeAxis::label_view()
|
||||
{
|
||||
name_label.set_text(time_axis_name) ;
|
||||
name_entry.set_text(time_axis_name) ;
|
||||
ARDOUR_UI::instance()->set_tip(name_entry, time_axis_name) ;
|
||||
name_label.set_text (time_axis_name);
|
||||
name_entry.set_text (time_axis_name);
|
||||
ARDOUR_UI::instance()->set_tip (name_entry, Glib::Markup::escape_text (time_axis_name));
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -351,6 +347,8 @@ VisualTimeAxis::label_view()
|
|||
void
|
||||
VisualTimeAxis::name_entry_changed()
|
||||
{
|
||||
TimeAxisView::name_entry_changed ();
|
||||
|
||||
string x = name_entry.get_text ();
|
||||
|
||||
if (x == time_axis_name) {
|
||||
|
|
@ -365,7 +363,7 @@ VisualTimeAxis::name_entry_changed()
|
|||
}
|
||||
|
||||
if (!editor.get_named_time_axis(x)) {
|
||||
set_time_axis_name(x, this);
|
||||
set_time_axis_name (x, this);
|
||||
} else {
|
||||
ARDOUR_UI::instance()->popup_error (_("A track already exists with that name"));
|
||||
name_entry.set_text(time_axis_name);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue