mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-06 13:45:43 +01:00
[Summary] Rearranging transport toolbar and other tools in editor window
[git-p4: depot-paths = "//Abdaw/dev_main/tracks/": change = 461983]
This commit is contained in:
parent
534f82e0e9
commit
0089053814
9 changed files with 187 additions and 166 deletions
|
|
@ -245,36 +245,17 @@ ARDOUR_UI::ARDOUR_UI (int *argcp, char **argvp[], const char* localedir)
|
|||
session_loaded = false;
|
||||
ignore_dual_punch = false;
|
||||
|
||||
const XMLTree* layout = WavesUI::load_layout("tracks_tools.xml");
|
||||
if (layout == NULL) {
|
||||
return;
|
||||
}
|
||||
|
||||
XMLNode* root = layout->root();
|
||||
if ((root == NULL) || strcasecmp(root->name().c_str(), "layout")) {
|
||||
return;
|
||||
}
|
||||
|
||||
WavesUI::create_ui(layout, tracks_tools_packer, _tools);
|
||||
|
||||
roll_button.set_controllable (roll_controllable);
|
||||
_tools.get_waves_button ("transport_play_button").set_controllable (roll_controllable);
|
||||
|
||||
stop_button.set_controllable (stop_controllable);
|
||||
_tools.get_waves_button ("transport_stop_button").set_controllable (stop_controllable);
|
||||
|
||||
goto_start_button.set_controllable (goto_start_controllable);
|
||||
_tools.get_waves_button ("transport_start_button").set_controllable (goto_start_controllable);
|
||||
|
||||
goto_end_button.set_controllable (goto_end_controllable);
|
||||
_tools.get_waves_button ("transport_end_button").set_controllable (goto_end_controllable);
|
||||
|
||||
auto_loop_button.set_controllable (auto_loop_controllable);
|
||||
_tools.get_waves_button ("transport_loop_button").set_controllable (auto_loop_controllable);
|
||||
|
||||
play_selection_button.set_controllable (play_selection_controllable);
|
||||
rec_button.set_controllable (rec_controllable);
|
||||
_tools.get_waves_button ("transport_record_button").set_controllable (rec_controllable);
|
||||
|
||||
roll_button.set_name ("transport button");
|
||||
stop_button.set_name ("transport button");
|
||||
|
|
@ -2143,12 +2124,12 @@ ARDOUR_UI::map_transport_state ()
|
|||
{
|
||||
if (!_session) {
|
||||
auto_loop_button.unset_active_state ();
|
||||
_tools.get_waves_button ("transport_loop_button").set_active (false);
|
||||
editor->get_waves_button ("transport_loop_button").set_active (false);
|
||||
play_selection_button.unset_active_state ();
|
||||
roll_button.unset_active_state ();
|
||||
_tools.get_waves_button ("transport_play_button").set_active (false);
|
||||
editor->get_waves_button ("transport_play_button").set_active (false);
|
||||
stop_button.set_active_state (Gtkmm2ext::ExplicitActive);
|
||||
_tools.get_waves_button ("transport_stop_button").set_active (true);
|
||||
editor->get_waves_button ("transport_stop_button").set_active (true);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -2164,29 +2145,29 @@ ARDOUR_UI::map_transport_state ()
|
|||
|
||||
play_selection_button.set_active_state (Gtkmm2ext::ExplicitActive);
|
||||
roll_button.unset_active_state ();
|
||||
_tools.get_waves_button ("transport_play_button").set_active (true);
|
||||
editor->get_waves_button ("transport_play_button").set_active (true);
|
||||
auto_loop_button.unset_active_state ();
|
||||
_tools.get_waves_button ("transport_loop_button").set_active (false);
|
||||
editor->get_waves_button ("transport_loop_button").set_active (false);
|
||||
} else if (_session->get_play_loop ()) {
|
||||
|
||||
auto_loop_button.set_active (true);
|
||||
_tools.get_waves_button ("transport_loop_button").set_active (true);
|
||||
editor->get_waves_button ("transport_loop_button").set_active (true);
|
||||
play_selection_button.set_active (false);
|
||||
if (Config->get_loop_is_mode()) {
|
||||
roll_button.set_active (true);
|
||||
_tools.get_waves_button ("transport_play_button").set_active (true);
|
||||
editor->get_waves_button ("transport_play_button").set_active (true);
|
||||
} else {
|
||||
roll_button.set_active (false);
|
||||
_tools.get_waves_button ("transport_play_button").set_active (false);
|
||||
editor->get_waves_button ("transport_play_button").set_active (false);
|
||||
}
|
||||
|
||||
} else {
|
||||
|
||||
roll_button.set_active (true);
|
||||
_tools.get_waves_button ("transport_play_button").set_active (true);
|
||||
editor->get_waves_button ("transport_play_button").set_active (true);
|
||||
play_selection_button.set_active (false);
|
||||
auto_loop_button.set_active (false);
|
||||
_tools.get_waves_button ("transport_loop_button").set_active (false);
|
||||
editor->get_waves_button ("transport_loop_button").set_active (false);
|
||||
}
|
||||
|
||||
if (Config->get_always_play_range()) {
|
||||
|
|
@ -2196,22 +2177,22 @@ ARDOUR_UI::map_transport_state ()
|
|||
}
|
||||
|
||||
stop_button.set_active (false);
|
||||
_tools.get_waves_button ("transport_stop_button").set_active (false);
|
||||
editor->get_waves_button ("transport_stop_button").set_active (false);
|
||||
|
||||
} else {
|
||||
|
||||
stop_button.set_active (true);
|
||||
_tools.get_waves_button ("transport_stop_button").set_active (true);
|
||||
editor->get_waves_button ("transport_stop_button").set_active (true);
|
||||
roll_button.set_active (false);
|
||||
_tools.get_waves_button ("transport_play_button").set_active (false);
|
||||
editor->get_waves_button ("transport_play_button").set_active (false);
|
||||
|
||||
play_selection_button.set_active (false);
|
||||
if (Config->get_loop_is_mode ()) {
|
||||
auto_loop_button.set_active (_session->get_play_loop());
|
||||
_tools.get_waves_button ("transport_loop_button").set_active (_session->get_play_loop());
|
||||
editor->get_waves_button ("transport_loop_button").set_active (_session->get_play_loop());
|
||||
} else {
|
||||
auto_loop_button.set_active (false);
|
||||
_tools.get_waves_button ("transport_loop_button").set_active (false);
|
||||
editor->get_waves_button ("transport_loop_button").set_active (false);
|
||||
}
|
||||
update_disk_space ();
|
||||
}
|
||||
|
|
@ -2490,17 +2471,17 @@ ARDOUR_UI::transport_rec_enable_blink (bool onoff)
|
|||
if (r == Session::Enabled || (r == Session::Recording && !h)) {
|
||||
if (onoff) {
|
||||
rec_button.set_active_state (Gtkmm2ext::ExplicitActive);
|
||||
_tools.get_waves_button ("transport_record_button").set_active (true);
|
||||
editor->get_waves_button ("transport_record_button").set_active (true);
|
||||
} else {
|
||||
rec_button.set_active_state (Gtkmm2ext::ImplicitActive);
|
||||
_tools.get_waves_button ("transport_record_button").set_active (false);
|
||||
editor->get_waves_button ("transport_record_button").set_active (false);
|
||||
}
|
||||
} else if (r == Session::Recording && h) {
|
||||
rec_button.set_active_state (Gtkmm2ext::ExplicitActive);
|
||||
_tools.get_waves_button ("transport_record_button").set_active (true);
|
||||
editor->get_waves_button ("transport_record_button").set_active (true);
|
||||
} else {
|
||||
rec_button.unset_active_state ();
|
||||
_tools.get_waves_button ("transport_record_button").set_active (false);
|
||||
editor->get_waves_button ("transport_record_button").set_active (false);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -4172,14 +4153,14 @@ ARDOUR_UI::step_edit_status_change (bool yn)
|
|||
|
||||
if (yn) {
|
||||
rec_button.set_active_state (Gtkmm2ext::ImplicitActive);
|
||||
_tools.get_waves_button ("transport_record_button").set_active (true);
|
||||
editor->get_waves_button ("transport_record_button").set_active (true);
|
||||
rec_button.set_sensitive (false);
|
||||
_tools.get_waves_button ("transport_record_button").set_sensitive (false);
|
||||
editor->get_waves_button ("transport_record_button").set_sensitive (false);
|
||||
} else {
|
||||
rec_button.unset_active_state ();
|
||||
_tools.get_waves_button ("transport_record_button").set_active (false);
|
||||
editor->get_waves_button ("transport_record_button").set_active (false);
|
||||
rec_button.set_sensitive (true);
|
||||
_tools.get_waves_button ("transport_record_button").set_sensitive (true);
|
||||
editor->get_waves_button ("transport_record_button").set_sensitive (true);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -442,8 +442,6 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
|
|||
ArdourButton play_selection_button;
|
||||
ArdourButton rec_button;
|
||||
|
||||
WavesUI::WidgetMap _tools;
|
||||
|
||||
void toggle_external_sync ();
|
||||
void toggle_time_master ();
|
||||
void toggle_video_sync ();
|
||||
|
|
@ -720,7 +718,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
|
|||
Glib::RefPtr<Gtk::TextBuffer::Tag> ptag, Glib::RefPtr<Gtk::TextBuffer::Tag> mtag,
|
||||
const char *msg);
|
||||
Gtk::Label status_bar_label;
|
||||
bool status_bar_button_press (GdkEventButton*);
|
||||
bool status_bar_button_press (GdkEventButton*);
|
||||
Gtk::ToggleButton error_log_button;
|
||||
|
||||
void loading_message (const std::string& msg);
|
||||
|
|
|
|||
|
|
@ -108,7 +108,7 @@ ARDOUR_UI::setup_windows ()
|
|||
editor->get_status_bar_packer().pack_start (*status_bar_packer, true, true);
|
||||
editor->get_status_bar_packer().pack_start (menu_bar_base, false, false, 6);
|
||||
#else
|
||||
top_packer.pack_start (menu_bar_base, false, false);
|
||||
editor->get_hbox ("menu_bar_base").pack_start (menu_bar_base, false, false);
|
||||
#endif
|
||||
if (ARDOUR::Profile->get_trx()) {
|
||||
top_packer.pack_start (tracks_tools_packer, false, false);
|
||||
|
|
@ -218,6 +218,13 @@ ARDOUR_UI::setup_transport_trx ()
|
|||
{
|
||||
RefPtr<Action> act;
|
||||
|
||||
editor->get_waves_button ("transport_play_button").set_controllable (roll_controllable);
|
||||
editor->get_waves_button ("transport_stop_button").set_controllable (stop_controllable);
|
||||
editor->get_waves_button ("transport_start_button").set_controllable (goto_start_controllable);
|
||||
editor->get_waves_button ("transport_end_button").set_controllable (goto_end_controllable);
|
||||
editor->get_waves_button ("transport_loop_button").set_controllable (auto_loop_controllable);
|
||||
editor->get_waves_button ("transport_record_button").set_controllable (rec_controllable);
|
||||
|
||||
transport_tearoff_hbox.set_border_width (3);
|
||||
transport_tearoff_hbox.set_spacing (3);
|
||||
|
||||
|
|
@ -262,7 +269,7 @@ ARDOUR_UI::setup_transport_trx ()
|
|||
click_button.set_name ("transport button");
|
||||
|
||||
stop_button.set_active (true);
|
||||
_tools.get_waves_button ("transport_stop_button").set_active (true);
|
||||
editor->get_waves_button ("transport_stop_button").set_active (true);
|
||||
|
||||
goto_start_button.set_image (get_icon (X_("transport_start")));
|
||||
goto_end_button.set_image (get_icon (X_("transport_end")));
|
||||
|
|
@ -278,27 +285,27 @@ ARDOUR_UI::setup_transport_trx ()
|
|||
|
||||
act = ActionManager::get_action (X_("Transport"), X_("Stop"));
|
||||
stop_button.set_related_action (act);
|
||||
_tools.get_waves_button ("transport_stop_button").set_related_action (act);
|
||||
editor->get_waves_button ("transport_stop_button").set_related_action (act);
|
||||
|
||||
act = ActionManager::get_action (X_("Transport"), X_("Roll"));
|
||||
roll_button.set_related_action (act);
|
||||
_tools.get_waves_button ("transport_play_button").set_related_action (act);
|
||||
editor->get_waves_button ("transport_play_button").set_related_action (act);
|
||||
|
||||
act = ActionManager::get_action (X_("Transport"), X_("Record"));
|
||||
rec_button.set_related_action (act);
|
||||
_tools.get_waves_button ("transport_record_button").set_related_action (act);
|
||||
editor->get_waves_button ("transport_record_button").set_related_action (act);
|
||||
|
||||
act = ActionManager::get_action (X_("Transport"), X_("GotoStart"));
|
||||
goto_start_button.set_related_action (act);
|
||||
_tools.get_waves_button ("transport_start_button").set_related_action (act);
|
||||
editor->get_waves_button ("transport_start_button").set_related_action (act);
|
||||
|
||||
act = ActionManager::get_action (X_("Transport"), X_("GotoEnd"));
|
||||
goto_end_button.set_related_action (act);
|
||||
_tools.get_waves_button ("transport_end_button").set_related_action (act);
|
||||
editor->get_waves_button ("transport_end_button").set_related_action (act);
|
||||
|
||||
act = ActionManager::get_action (X_("Transport"), X_("Loop"));
|
||||
auto_loop_button.set_related_action (act);
|
||||
_tools.get_waves_button ("transport_loop_button").set_related_action (act);
|
||||
editor->get_waves_button ("transport_loop_button").set_related_action (act);
|
||||
act = ActionManager::get_action (X_("Transport"), X_("PlaySelection"));
|
||||
play_selection_button.set_related_action (act);
|
||||
act = ActionManager::get_action (X_("MIDI"), X_("panic"));
|
||||
|
|
|
|||
|
|
@ -246,7 +246,18 @@ Editor::Editor ()
|
|||
, cd_mark_label (_("CD Markers"))
|
||||
, videotl_label (_("Video Timeline"))
|
||||
, edit_packer (4, 4, true)
|
||||
, vpacker (named_children ().get_vbox ("vpacker"))
|
||||
, vpacker (get_vbox ("vpacker"))
|
||||
, _tool_marker_button (get_waves_button ("tool_marker_button"))
|
||||
, _tool_zoom_button (get_waves_button ("tool_zoom_button"))
|
||||
, _tool_arrow_button (get_waves_button ("tool_arrow_button"))
|
||||
#ifdef TOP_MENUBAR
|
||||
/*
|
||||
* This is needed for OS X primarily
|
||||
* but also any other OS that uses a single
|
||||
* top menubar instead of per window menus
|
||||
*/
|
||||
, _status_bar_hpacker (get_hbox ("menu_bar_base"))
|
||||
#endif
|
||||
|
||||
/* the values here don't matter: layout widgets
|
||||
reset them as needed.
|
||||
|
|
@ -636,9 +647,6 @@ Editor::Editor ()
|
|||
set_name ("EditorWindow");
|
||||
add_accel_group (ActionManager::ui_manager->get_accel_group());
|
||||
|
||||
status_bar_hpacker.show ();
|
||||
|
||||
vpacker.pack_end (status_bar_hpacker, false, false);
|
||||
vpacker.pack_end (global_hpacker, true, true);
|
||||
|
||||
/* register actions now so that set_state() can find them and set toggles/checks etc */
|
||||
|
|
@ -709,7 +717,6 @@ Editor::Editor ()
|
|||
set_title (title.get_string());
|
||||
set_wmclass (X_("ardour_editor"), PROGRAM_NAME);
|
||||
|
||||
//add (vpacker);
|
||||
add_events (Gdk::KEY_PRESS_MASK|Gdk::KEY_RELEASE_MASK);
|
||||
|
||||
signal_configure_event().connect (sigc::mem_fun (*ARDOUR_UI::instance(), &ARDOUR_UI::configure_handler));
|
||||
|
|
@ -2858,18 +2865,13 @@ Editor::setup_toolbar ()
|
|||
Alignment* mouse_mode_align = manage (new Alignment);
|
||||
|
||||
Glib::RefPtr<SizeGroup> mouse_mode_size_group = SizeGroup::create (SIZE_GROUP_BOTH);
|
||||
// mouse_mode_size_group->add_widget (smart_mode_button);
|
||||
mouse_mode_size_group->add_widget (mouse_move_button);
|
||||
mouse_mode_size_group->add_widget (mouse_select_button);
|
||||
mouse_mode_size_group->add_widget (mouse_zoom_button);
|
||||
mouse_mode_size_group->add_widget (mouse_gain_button);
|
||||
mouse_mode_size_group->add_widget (mouse_timefx_button);
|
||||
mouse_mode_size_group->add_widget (mouse_audition_button);
|
||||
mouse_mode_size_group->add_widget (mouse_draw_button);
|
||||
mouse_mode_size_group->add_widget (internal_edit_button);
|
||||
|
||||
/* make them just a bit bigger */
|
||||
mouse_move_button.set_size_request (-1, 30);
|
||||
internal_edit_button.set_size_request (-1, 30);
|
||||
|
||||
mouse_mode_hbox->set_spacing (2);
|
||||
|
||||
|
|
@ -2877,10 +2879,6 @@ Editor::setup_toolbar ()
|
|||
mouse_mode_hbox->pack_start (smart_mode_button, false, false);
|
||||
}
|
||||
|
||||
mouse_mode_hbox->pack_start (mouse_move_button, false, false);
|
||||
mouse_mode_hbox->pack_start (mouse_select_button, false, false);
|
||||
mouse_mode_hbox->pack_start (mouse_zoom_button, false, false);
|
||||
|
||||
if (!ARDOUR::Profile->get_trx()) {
|
||||
mouse_mode_hbox->pack_start (mouse_gain_button, false, false);
|
||||
mouse_mode_hbox->pack_start (mouse_timefx_button, false, false);
|
||||
|
|
@ -3180,11 +3178,8 @@ void
|
|||
Editor::setup_tooltips ()
|
||||
{
|
||||
ARDOUR_UI::instance()->set_tip (smart_mode_button, _("Smart Mode (add Range functions to Object mode)"));
|
||||
ARDOUR_UI::instance()->set_tip (mouse_move_button, _("Object Mode (select/move Objects)"));
|
||||
ARDOUR_UI::instance()->set_tip (mouse_select_button, _("Range Mode (select/move Ranges)"));
|
||||
ARDOUR_UI::instance()->set_tip (mouse_draw_button, _("Draw/Edit MIDI Notes"));
|
||||
ARDOUR_UI::instance()->set_tip (mouse_gain_button, _("Draw Region Gain"));
|
||||
ARDOUR_UI::instance()->set_tip (mouse_zoom_button, _("Select Zoom Range"));
|
||||
ARDOUR_UI::instance()->set_tip (mouse_timefx_button, _("Stretch/Shrink Regions and MIDI Notes"));
|
||||
ARDOUR_UI::instance()->set_tip (mouse_audition_button, _("Listen to Specific Regions"));
|
||||
ARDOUR_UI::instance()->set_tip (internal_edit_button, _("Note Level Editing"));
|
||||
|
|
|
|||
|
|
@ -275,7 +275,14 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
|
|||
void export_region ();
|
||||
|
||||
void add_toplevel_controls (Gtk::Container&);
|
||||
Gtk::HBox& get_status_bar_packer() { return status_bar_hpacker; }
|
||||
#ifdef TOP_MENUBAR
|
||||
/*
|
||||
* This is needed for OS X primarily
|
||||
* but also any other OS that uses a single
|
||||
* top menubar instead of per window menus
|
||||
*/
|
||||
Gtk::HBox& get_status_bar_packer() { return _status_bar_hpacker; }
|
||||
#endif
|
||||
|
||||
void set_zoom_focus (Editing::ZoomFocus);
|
||||
Editing::ZoomFocus get_zoom_focus () const { return zoom_focus; }
|
||||
|
|
@ -1584,11 +1591,11 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
|
|||
Gtk::Label toolbar_selection_cursor_label;
|
||||
|
||||
Gtkmm2ext::TearOff* _mouse_mode_tearoff;
|
||||
ArdourButton mouse_select_button;
|
||||
WavesButton& _tool_marker_button;
|
||||
ArdourButton mouse_draw_button;
|
||||
ArdourButton mouse_move_button;
|
||||
WavesButton& _tool_arrow_button;
|
||||
ArdourButton mouse_gain_button;
|
||||
ArdourButton mouse_zoom_button;
|
||||
WavesButton& _tool_zoom_button;
|
||||
ArdourButton mouse_timefx_button;
|
||||
ArdourButton mouse_audition_button;
|
||||
|
||||
|
|
@ -1958,7 +1965,14 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
|
|||
|
||||
void history_changed ();
|
||||
|
||||
Gtk::HBox status_bar_hpacker;
|
||||
#ifdef TOP_MENUBAR
|
||||
/*
|
||||
* This is needed for OS X primarily
|
||||
* but also any other OS that uses a single
|
||||
* top menubar instead of per window menus
|
||||
*/
|
||||
Gtk::HBox& _status_bar_hpacker;
|
||||
#endif
|
||||
|
||||
Editing::EditPoint _edit_point;
|
||||
|
||||
|
|
|
|||
|
|
@ -418,16 +418,10 @@ Editor::register_actions ()
|
|||
smart_mode_button.set_name ("mouse mode button");
|
||||
|
||||
act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-object", _("Object Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseObject));
|
||||
mouse_move_button.set_related_action (act);
|
||||
mouse_move_button.set_image (::get_icon("tool_object"));
|
||||
mouse_move_button.add_elements ( ArdourButton::Inset );
|
||||
mouse_move_button.set_name ("mouse mode button");
|
||||
_tool_arrow_button.set_related_action (act);
|
||||
|
||||
act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-range", _("Range Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseRange));
|
||||
mouse_select_button.set_related_action (act);
|
||||
mouse_select_button.set_image (::get_icon("tool_range"));
|
||||
mouse_select_button.add_elements ( ArdourButton::Inset );
|
||||
mouse_select_button.set_name ("mouse mode button");
|
||||
_tool_marker_button.set_related_action (act);
|
||||
|
||||
act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-draw", _("Note Drawing Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseDraw));
|
||||
mouse_draw_button.set_related_action (act);
|
||||
|
|
@ -442,10 +436,7 @@ Editor::register_actions ()
|
|||
mouse_gain_button.set_name ("mouse mode button");
|
||||
|
||||
act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-zoom", _("Zoom Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseZoom));
|
||||
mouse_zoom_button.set_related_action (act);
|
||||
mouse_zoom_button.set_image (::get_icon("tool_zoom_ardour"));
|
||||
mouse_zoom_button.add_elements ( ArdourButton::Inset );
|
||||
mouse_zoom_button.set_name ("mouse mode button");
|
||||
_tool_zoom_button.set_related_action (act);
|
||||
|
||||
act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-audition", _("Audition Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseAudition));
|
||||
mouse_audition_button.set_related_action (act);
|
||||
|
|
|
|||
|
|
@ -2,5 +2,95 @@
|
|||
|
||||
<Window>
|
||||
<VBox id="vpacker">
|
||||
<HBox id="menu_bar_base">
|
||||
<!--Layout bgnormal="#ffff00" width="100" height="30"/-->
|
||||
</HBox>
|
||||
<HBox>
|
||||
<iconbutton id="tracks_button"
|
||||
width="52" height="51"
|
||||
normalicon="tracks"
|
||||
activeicon="tracks_active"
|
||||
prelighticon="tracks_prelight"/>
|
||||
</HBox>
|
||||
<HBox spacing="1">
|
||||
<iconbutton id="inspector_on_button"
|
||||
width="48" height="26"
|
||||
normalicon="inspector_on"
|
||||
activeicon="inspector_on_active"
|
||||
prelighticon="inspector_on_prelight"/>
|
||||
<iconbutton id="mixer_on_button"
|
||||
width="48" height="26"
|
||||
normalicon="mixer_on"
|
||||
activeicon="mixer_on_active"
|
||||
prelighticon="mixer_on_prelight"/>
|
||||
<iconbutton id="meter_bridge_on_button"
|
||||
width="48" height="26"
|
||||
normalicon="meter_bridge_on"
|
||||
activeicon="meter_bridge_on_active"
|
||||
prelighticon="meter_bridge_on_prelight"/>
|
||||
<layout width="54" height="26" bgnormal=""/>
|
||||
<iconbutton id="transport_start_button"
|
||||
tooltip="Go to start of session"
|
||||
width="34" height="26"
|
||||
normalicon="transport_start"
|
||||
activeicon="transport_start_active"
|
||||
prelighticon="transport_start_prelight"/>
|
||||
<iconbutton id="transport_end_button"
|
||||
tooltip="Go to end of session"
|
||||
width="34" height="26"
|
||||
normalicon="transport_end"
|
||||
activeicon="transport_end_active"
|
||||
prelighticon="transport_end_prelight"/>
|
||||
<iconbutton id="transport_play_button"
|
||||
tooltip="Play from playhead"
|
||||
width="34" height="26"
|
||||
normalicon="transport_play"
|
||||
activeicon="transport_play_active"
|
||||
prelighticon="transport_play_prelight"/>
|
||||
<iconbutton id="transport_record_button"
|
||||
width="34" height="26"
|
||||
normalicon="transport_record"
|
||||
activeicon="transport_record_active"
|
||||
prelighticon="transport_record_prelight"/>
|
||||
<iconbutton id="transport_stop_button"
|
||||
width="34" height="26"
|
||||
normalicon="transport_stop"
|
||||
activeicon="transport_stop_active"
|
||||
prelighticon="transport_stop_prelight"/>
|
||||
<iconbutton id="transport_loop_button"
|
||||
width="34" height="26"
|
||||
normalicon="transport_loop"
|
||||
activeicon="transport_loop_active"
|
||||
prelighticon="transport_loop_prelight"/>
|
||||
<iconbutton id="lock_session_button"
|
||||
width="34" height="26"
|
||||
normalicon="lock_session"
|
||||
activeicon="lock_session_active"
|
||||
prelighticon="lock_session_prelight"/>
|
||||
<layout width="60" height="26" bgnormal=""/>
|
||||
<iconbutton id="tool_marker_button"
|
||||
width="34" height="26"
|
||||
normalicon="tool_marker"
|
||||
activeicon="tool_marker_active"
|
||||
prelighticon="tool_marker_prelight"/>
|
||||
<iconbutton id="tool_arrow_button"
|
||||
tooltip="Object Mode (select/move Objects)"
|
||||
width="34" height="26"
|
||||
normalicon="tool_arrow"
|
||||
activeicon="tool_arrow_active"
|
||||
prelighticon="tool_arrow_prelight"/>
|
||||
<iconbutton id="tool_cut_button"
|
||||
width="34" height="26"
|
||||
normalicon="tool_cut"
|
||||
activeicon="tool_cut_active"
|
||||
prelighticon="tool_cut_prelight"/>
|
||||
<iconbutton id="tool_zoom_button"
|
||||
tooltip="Select Zoom Range"
|
||||
width="34" height="26"
|
||||
normalicon="tool_zoom"
|
||||
activeicon="tool_zoom_active"
|
||||
prelighticon="tool_zoom_prelight"/>
|
||||
<layout width="68" height="26" bgnormal=""/>
|
||||
</HBox>
|
||||
</VBox>
|
||||
</Window>
|
||||
|
|
|
|||
|
|
@ -1,42 +1,9 @@
|
|||
/*
|
||||
Copyright (C) 2014 Waves Audio Ltd.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
|
||||
*/
|
||||
|
||||
#include "waves_window.h"
|
||||
#include "dbg_msg.h"
|
||||
|
||||
|
||||
WavesWindow::WavesWindow (Gtk::WindowType window_type)
|
||||
: Gtk::Window (window_type)
|
||||
{
|
||||
}
|
||||
|
||||
WavesWindow::WavesWindow (Gtk::WindowType window_type, std::string layout_script) : Gtk::Window (window_type)
|
||||
{
|
||||
const XMLTree* layout = WavesUI::load_layout(layout_script);
|
||||
if (layout == NULL) {
|
||||
return;
|
||||
}
|
||||
|
||||
XMLNode* root = layout->root();
|
||||
if ((root == NULL) || strcasecmp(root->name().c_str(), "Window")) {
|
||||
return;
|
||||
}
|
||||
|
||||
WavesUI::create_ui(layout, *this, _children);
|
||||
}
|
||||
/*
Copyright (C) 2014 Waves Audio Ltd.
|
||||
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
|
||||
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
|
||||
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
|
||||
#include "waves_window.h"
#include "dbg_msg.h"
|
||||
WavesWindow::WavesWindow (Gtk::WindowType window_type)
: Gtk::Window (window_type)
{
}
|
||||
WavesWindow::WavesWindow (Gtk::WindowType window_type, std::string layout_script) : Gtk::Window (window_type)
{
const XMLTree* layout = WavesUI::load_layout(layout_script);
if (layout == NULL) {
return;
}
|
||||
XMLNode* root = layout->root();
if ((root == NULL) || strcasecmp(root->name().c_str(), "Window")) {
return;
}
|
||||
WavesUI::create_ui(layout, *this, _children);
}
|
||||
|
|
@ -1,39 +1,17 @@
|
|||
/*
|
||||
Copyright (C) 2014 Waves Audio Ltd.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
|
||||
*/
|
||||
#ifndef __waves_window_h__
|
||||
#define __waves_window_h__
|
||||
|
||||
#include <string>
|
||||
/*
Copyright (C) 2014 Waves Audio Ltd.
|
||||
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
|
||||
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
|
||||
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
|
||||
#ifndef __waves_window_h__
#define __waves_window_h__
#include <string>
|
||||
#include <gtkmm.h>
|
||||
#include "waves_ui.h"
|
||||
|
||||
|
||||
class WavesWindow : public Gtk::Window {
|
||||
public:
|
||||
WavesWindow (Gtk::WindowType window_type);
|
||||
WavesWindow (Gtk::WindowType window_type, std::string layout_script);
|
||||
|
||||
protected:
|
||||
WavesUI::WidgetMap& named_children() { return _children; }
|
||||
|
||||
private:
|
||||
WavesUI::WidgetMap _children;
|
||||
};
|
||||
|
||||
|
||||
class WavesWindow : public Gtk::Window {
public:
WavesWindow (Gtk::WindowType window_type);
WavesWindow (Gtk::WindowType window_type, std::string layout_script);
Gtk::VBox& get_vbox (char* id) { return _children.get_vbox (id); }
|
||||
Gtk::HBox& get_hbox (char* id) { return _children.get_hbox (id); }
|
||||
Gtk::Layout& get_layout (char* id) { return _children.get_layout (id); }
|
||||
Gtk::Label& get_label (char* id) { return _children.get_label (id); }
|
||||
Gtk::ComboBoxText& get_combo_box_text (char* id) { return _children.get_combo_box_text (id); }
|
||||
WavesButton& get_waves_button (char* id) { return _children.get_waves_button (id); }
|
||||
|
||||
private:
WavesUI::WidgetMap _children;
};
|
||||
#endif // __waves_window_h__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue