mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-06 06:44:57 +01:00
more work on actions and general compilability
git-svn-id: svn://localhost/trunk/ardour2@56 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
a495630a43
commit
2d32c7da36
29 changed files with 494 additions and 633 deletions
|
|
@ -49,6 +49,7 @@ if gtkardour['VST']:
|
|||
|
||||
gtkardour_files=Split("""
|
||||
about.cc
|
||||
actions.cc
|
||||
add_route_dialog.cc
|
||||
ardour_dialog.cc
|
||||
ardour_message.cc
|
||||
|
|
@ -65,7 +66,7 @@ automation_line.cc
|
|||
automation_pan_line.cc
|
||||
automation_time_axis.cc
|
||||
axis_view.cc
|
||||
canvas-imageframe.cc
|
||||
canvas-imageframe.c
|
||||
canvas-ruler.c
|
||||
canvas-simpleline.c
|
||||
canvas-simplerect.c
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@
|
|||
|
||||
#include <gtkmm.h>
|
||||
#include <pbd/error.h>
|
||||
#include <pbd/string_compose.h>
|
||||
#include <pbd/compose.h>
|
||||
#include <pbd/basename.h>
|
||||
#include <pbd/pathscanner.h>
|
||||
#include <pbd/failed_constructor.h>
|
||||
|
|
|
|||
|
|
@ -38,6 +38,20 @@
|
|||
#include <libgnomecanvasmm/canvas.h>
|
||||
|
||||
#include <pbd/xml++.h>
|
||||
#include <gtkmm/box.h>
|
||||
#include <gtkmm/frame.h>
|
||||
#include <gtkmm/label.h>
|
||||
#include <gtkmm/table.h>
|
||||
#include <gtkmm/fixed.h>
|
||||
#include <gtkmm/drawingarea.h>
|
||||
#include <gtkmm/eventbox.h>
|
||||
#include <gtkmm/menu.h>
|
||||
#include <gtkmm/menuitem.h>
|
||||
#include <gtkmm/button.h>
|
||||
#include <gtkmm/togglebutton.h>
|
||||
#include <gtkmm/treeview.h>
|
||||
#include <gtkmm/menubar.h>
|
||||
#include <gtkmm/adjustment.h>
|
||||
#include <gtkmm2ext/gtk_ui.h>
|
||||
#include <gtkmm2ext/pix.h>
|
||||
#include <gtkmm2ext/click_box.h>
|
||||
|
|
@ -324,18 +338,9 @@ class ARDOUR_UI : public Gtkmm2ext::UI
|
|||
void start_clocking ();
|
||||
void stop_clocking ();
|
||||
|
||||
class BigClockWindow : public ArdourDialog
|
||||
{
|
||||
public:
|
||||
BigClockWindow () : ArdourDialog ("big clock window") {};
|
||||
};
|
||||
|
||||
AudioClock big_clock;
|
||||
Gtk::Frame big_clock_frame;
|
||||
BigClockWindow* big_clock_window;
|
||||
|
||||
void big_clock_size_event (GtkAllocation *alloc);
|
||||
void big_clock_realize ();
|
||||
ArdourDialog* big_clock_window;
|
||||
|
||||
/* Transport Control */
|
||||
|
||||
|
|
@ -681,6 +686,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI
|
|||
/* Keymap handling */
|
||||
|
||||
void install_keybindings ();
|
||||
void install_actions ();
|
||||
void test_binding_action (const char *);
|
||||
void start_keyboard_prefix();
|
||||
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@
|
|||
#include <iostream>
|
||||
#include <cmath>
|
||||
|
||||
#include <gtkmm.h>
|
||||
#include <sigc++/bind.h>
|
||||
#include <pbd/error.h>
|
||||
#include <pbd/basename.h>
|
||||
#include <pbd/fastlog.h>
|
||||
|
|
@ -41,6 +41,7 @@
|
|||
#include "ardour_ui.h"
|
||||
#include "public_editor.h"
|
||||
#include "audio_clock.h"
|
||||
#include "utils.h"
|
||||
|
||||
#include "i18n.h"
|
||||
|
||||
|
|
@ -424,31 +425,18 @@ ARDOUR_UI::setup_clock ()
|
|||
{
|
||||
ARDOUR_UI::Clock.connect (bind (mem_fun (big_clock, &AudioClock::set), false));
|
||||
|
||||
big_clock_window = new BigClockWindow;
|
||||
big_clock_window = new ArdourDialog ("big clock window");
|
||||
|
||||
big_clock_window->set_border_width (0);
|
||||
big_clock_window->add (big_clock);
|
||||
big_clock_window->set_title (_("ardour: clock"));
|
||||
|
||||
big_clock_window->set_type_hint (Gdk::WINDOW_TYPE_HINT_MENU);
|
||||
|
||||
big_clock_window->signal_delete_event().connect (bind (sigc::ptr_fun (just_hide_it), static_cast<Gtk::Window*>(big_clock_window)));
|
||||
big_clock_window->signal_realize().connect (mem_fun(*this, &ARDOUR_UI::big_clock_realize));
|
||||
big_clock_window->size_allocate.connect (mem_fun(*this, &ARDOUR_UI::big_clock_size_event));
|
||||
|
||||
big_clock_window->Hiding.connect (mem_fun(*this, &ARDOUR_UI::big_clock_hiding));
|
||||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::big_clock_size_event (GtkAllocation *alloc)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::big_clock_realize ()
|
||||
{
|
||||
big_clock_window->get_window()->set_decorations (Gdk::WMDecoration (Gdk::DECOR_BORDER|Gdk::DECOR_RESIZEH|Gdk::DECOR_MAXIMIZE|Gdk::DECOR_MINIMIZE));
|
||||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::detach_tearoff (Gtk::Box* b, Gtk::Widget* w)
|
||||
{
|
||||
|
|
@ -550,7 +538,7 @@ ARDOUR_UI::shuttle_box_button_press (GdkEventButton* ev)
|
|||
|
||||
switch (ev->button) {
|
||||
case 1:
|
||||
Gtk::Main::grab_add (shuttle_box);
|
||||
shuttle_box.add_modal_grab ();
|
||||
shuttle_grabbed = true;
|
||||
mouse_shuttle (ev->x, true);
|
||||
break;
|
||||
|
|
@ -580,7 +568,7 @@ ARDOUR_UI::shuttle_box_button_release (GdkEventButton* ev)
|
|||
case 1:
|
||||
mouse_shuttle (ev->x, true);
|
||||
shuttle_grabbed = false;
|
||||
Gtk::Main::grab_remove (shuttle_box);
|
||||
shuttle_box.remove_modal_grab ();
|
||||
if (shuttle_behaviour == Sprung) {
|
||||
shuttle_fract = SHUTTLE_FRACT_SPEED1;
|
||||
session->request_transport_speed (1.0);
|
||||
|
|
@ -676,38 +664,38 @@ gint
|
|||
ARDOUR_UI::shuttle_box_expose (GdkEventExpose* event)
|
||||
{
|
||||
gint x;
|
||||
Gdk::Window win (shuttle_box.get_window());
|
||||
Glib::RefPtr<Gdk::Window> win (shuttle_box.get_window());
|
||||
|
||||
/* redraw the background */
|
||||
|
||||
win.draw_rectangle (shuttle_box.get_style()->get_bg_gc (shuttle_box.get_state()),
|
||||
true,
|
||||
event->area.x, event->area.y,
|
||||
event->area.width, event->area.height);
|
||||
win->draw_rectangle (shuttle_box.get_style()->get_bg_gc (shuttle_box.get_state()),
|
||||
true,
|
||||
event->area.x, event->area.y,
|
||||
event->area.width, event->area.height);
|
||||
|
||||
|
||||
x = (gint) floor ((shuttle_box.get_width() / 2.0) + (0.5 * (shuttle_box.get_width() * shuttle_fract)));
|
||||
|
||||
/* draw line */
|
||||
|
||||
win.draw_line (shuttle_box.get_style()->get_fg_gc (shuttle_box.get_state()),
|
||||
x,
|
||||
0,
|
||||
x,
|
||||
shuttle_box.get_height());
|
||||
win->draw_line (shuttle_box.get_style()->get_fg_gc (shuttle_box.get_state()),
|
||||
x,
|
||||
0,
|
||||
x,
|
||||
shuttle_box.get_height());
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::shuttle_style_clicked ()
|
||||
{
|
||||
shuttle_style_menu.popup (1, 0);
|
||||
shuttle_style_menu->popup (1, 0);
|
||||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::shuttle_unit_clicked ()
|
||||
{
|
||||
shuttle_unit_menu.popup (1, 0);
|
||||
shuttle_unit_menu->popup (1, 0);
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
|||
|
|
@ -141,7 +141,7 @@ ARDOUR_UI::connect_to_session (Session *s)
|
|||
start_blinking ();
|
||||
|
||||
if (editor) {
|
||||
editor->window().realize();
|
||||
editor->window().present();
|
||||
}
|
||||
|
||||
transport_stopped ();
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@
|
|||
#include "public_editor.h"
|
||||
#include "audio_clock.h"
|
||||
#include "editor.h"
|
||||
#include "actions.h"
|
||||
|
||||
#include <ardour/session.h>
|
||||
|
||||
|
|
@ -38,6 +39,7 @@
|
|||
using namespace ARDOUR;
|
||||
using namespace Gtk;
|
||||
using namespace Gtkmm2ext;
|
||||
using namespace ActionManager;
|
||||
|
||||
int
|
||||
ARDOUR_UI::create_editor ()
|
||||
|
|
@ -57,212 +59,226 @@ ARDOUR_UI::create_editor ()
|
|||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::build_menu_bar ()
|
||||
|
||||
ARDOUR_UI::install_actions ()
|
||||
{
|
||||
using namespace Menu_Helpers;
|
||||
Glib::RefPtr<ActionGroup> main_actions = ActionGroup::create (X_("Main"));
|
||||
Glib::RefPtr<Action> act;
|
||||
|
||||
menu_bar->set_name ("MainMenuBar");
|
||||
register_action (main_actions, X_("New"), _("New"), bind (mem_fun(*this, &ARDOUR_UI::new_session), false, string ()));
|
||||
register_action (main_actions, X_("Open"), _("Open"), mem_fun(*this, &ARDOUR_UI::open_session));
|
||||
register_action (main_actions, X_("Recent"), _("Recent"), mem_fun(*this, &ARDOUR_UI::open_recent_session));
|
||||
act = register_action (main_actions, X_("Close"), _("Close"), mem_fun(*this, &ARDOUR_UI::close_session));
|
||||
session_sensitive_actions.push_back (act);
|
||||
|
||||
MenuList& items = menu_bar->items();
|
||||
act = register_action (main_actions, X_("AddTrackBus"), _("Add Track/Bus"), mem_fun(*this, &ARDOUR_UI::add_route));
|
||||
session_sensitive_actions.push_back (act);
|
||||
|
||||
/* file menu */
|
||||
|
||||
Menu *session_menu = manage (new Menu);
|
||||
MenuList& session_items = session_menu->items();
|
||||
session_menu->set_name ("ArdourContextMenu");
|
||||
|
||||
session_items.push_back (MenuElem (_("New"), bind (mem_fun(*this, &ARDOUR_UI::new_session), false, string ())));
|
||||
session_items.push_back (MenuElem (_("Open"), mem_fun(*this, &ARDOUR_UI::open_session)));
|
||||
session_items.push_back (MenuElem (_("Recent"), mem_fun(*this, &ARDOUR_UI::open_recent_session)));
|
||||
session_items.push_back (MenuElem (_("Close"), mem_fun(*this, &ARDOUR_UI::close_session)));
|
||||
close_item = &session_items.back();
|
||||
close_item->set_sensitive (false);
|
||||
|
||||
session_items.push_back (SeparatorElem());
|
||||
|
||||
session_items.push_back (MenuElem (_("Add Track/Bus"), mem_fun(*this, &ARDOUR_UI::add_route)));
|
||||
add_track_item = &session_items.back ();
|
||||
add_track_item->set_sensitive (false);
|
||||
|
||||
session_items.push_back (SeparatorElem());
|
||||
|
||||
/* <CMT Additions> */
|
||||
|
||||
PathScanner scanner;
|
||||
vector<string*>* results = scanner (getenv ("PATH"), "AniComp", false, false);
|
||||
|
||||
if (results && !results->empty()) {
|
||||
Menu* image_compositor_menu = manage(new Menu());
|
||||
MenuList& image_compositor_items = image_compositor_menu->items();
|
||||
image_compositor_menu->set_name ("ArdourContextMenu");
|
||||
image_compositor_items.push_back(MenuElem (_("Connect"), (mem_fun (editor, &PublicEditor::connect_to_image_compositor)))) ;
|
||||
session_items.push_back(MenuElem (_("Image Compositor"), *image_compositor_menu)) ;
|
||||
image_compositor_item = &session_items.back() ;
|
||||
image_compositor_item->set_sensitive(false) ;
|
||||
session_items.push_back (SeparatorElem());
|
||||
} else {
|
||||
image_compositor_item = 0;
|
||||
}
|
||||
|
||||
if (results) {
|
||||
if (!results->empty()) {
|
||||
act = register_action (main_actions, X_("aniConnect"), _("Connect"), (mem_fun (*editor, &PublicEditor::connect_to_image_compositor)));
|
||||
session_sensitive_actions.push_back (act);
|
||||
}
|
||||
delete results;
|
||||
}
|
||||
|
||||
/* </CMT Additions> */
|
||||
|
||||
session_items.push_back (MenuElem (_("Save"), bind (mem_fun(*this, &ARDOUR_UI::save_state), string(""))));
|
||||
save_item = &session_items.back();
|
||||
save_item->set_sensitive (false);
|
||||
act = register_action (main_actions, X_("Snapshot"), _("Snapshot"), mem_fun(*this, &ARDOUR_UI::snapshot_session));
|
||||
session_sensitive_actions.push_back (act);
|
||||
|
||||
session_items.push_back (MenuElem (_("Snapshot"), mem_fun(*this, &ARDOUR_UI::snapshot_session)));
|
||||
snapshot_item = &session_items.back();
|
||||
snapshot_item->set_sensitive (false);
|
||||
/*
|
||||
session_items.push_back (MenuElem (_("Save as...")));
|
||||
save_as_item = session_items.back();
|
||||
save_as_item->set_sensitive (false);
|
||||
*/
|
||||
session_items.push_back (MenuElem (_("Save Template..."), mem_fun(*this, &ARDOUR_UI::save_template)));
|
||||
save_template_item = &session_items.back();
|
||||
save_template_item->set_sensitive (false);
|
||||
act = register_action (main_actions, X_("Save Template..."), _("Save Template..."), mem_fun(*this, &ARDOUR_UI::save_template));
|
||||
session_sensitive_actions.push_back (act);
|
||||
|
||||
Menu *export_menu = manage (new Menu);
|
||||
MenuList& export_items = export_menu->items();
|
||||
export_menu->set_name ("ArdourContextMenu");
|
||||
export_items.push_back (MenuElem (_("Export session to audiofile..."), mem_fun (*editor, &PublicEditor::export_session)));
|
||||
export_items.push_back (MenuElem (_("Export range to audiofile..."), mem_fun (*editor, &PublicEditor::export_selection)));
|
||||
// export_items.back()->set_sensitive (false);
|
||||
act = register_action (main_actions, X_("ExportSession"), _("Export session to audiofile..."), mem_fun (*editor, &PublicEditor::export_session));
|
||||
session_sensitive_actions.push_back (act);
|
||||
|
||||
session_items.push_back (MenuElem (_("Export"), *export_menu));
|
||||
export_item = &session_items.back();
|
||||
export_item->set_sensitive (false);
|
||||
act = register_action (main_actions, X_("ExportRange"), _("Export range to audiofile..."), mem_fun (*editor, &PublicEditor::export_selection));
|
||||
session_sensitive_actions.push_back (act);
|
||||
|
||||
session_items.push_back (SeparatorElem());
|
||||
act = register_action (main_actions, X_("Export"), _("Export"));
|
||||
session_sensitive_actions.push_back (act);
|
||||
|
||||
Menu *cleanup_menu = manage (new Menu);
|
||||
MenuList& cleanup_items = cleanup_menu->items();
|
||||
cleanup_menu->set_name ("ArdourContextMenu");
|
||||
cleanup_items.push_back (MenuElem (_("Cleanup unused sources"), mem_fun (*(ARDOUR_UI::instance()), &ARDOUR_UI::cleanup)));
|
||||
cleanup_items.push_back (MenuElem (_("Flush wastebasket"), mem_fun (*(ARDOUR_UI::instance()), &ARDOUR_UI::flush_trash)));
|
||||
|
||||
session_items.push_back (MenuElem (_("Cleanup"), *cleanup_menu));
|
||||
cleanup_item = &session_items.back ();
|
||||
cleanup_item->set_sensitive (false);
|
||||
|
||||
session_items.push_back (SeparatorElem());
|
||||
|
||||
session_items.push_back (MenuElem (_("Quit"), mem_fun (*(ARDOUR_UI::instance()), &ARDOUR_UI::finish)));
|
||||
|
||||
items.push_back (MenuElem (_("Session"), *session_menu));
|
||||
|
||||
/* edit menu; the editor is responsible for the contents */
|
||||
|
||||
Menu *edit_menu = manage (new Menu);
|
||||
editor->set_edit_menu (*edit_menu);
|
||||
items.push_back (MenuElem (_("Edit"), *edit_menu));
|
||||
edit_menu->set_name ("ArdourContextMenu");
|
||||
act = register_action (main_actions, X_("CleanupUnused"), _("Cleanup unused sources"), mem_fun (*(ARDOUR_UI::instance()), &ARDOUR_UI::cleanup));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (main_actions, X_("FlushWastebasket"), _("Flush wastebasket"), mem_fun (*(ARDOUR_UI::instance()), &ARDOUR_UI::flush_trash));
|
||||
session_sensitive_actions.push_back (act);
|
||||
|
||||
/* JACK menu for controlling ... JACK */
|
||||
/* JACK actions for controlling ... JACK */
|
||||
|
||||
Menu* jack_menu = manage (new Menu);
|
||||
MenuList& jack_items = jack_menu->items();
|
||||
jack_menu->set_name ("ArdourContextMenu");
|
||||
Glib::RefPtr<ActionGroup> jack_actions = ActionGroup::create (X_("JACK"));
|
||||
|
||||
act = register_action (jack_actions, X_("JACKDisconnect"), _("Disconnect"), mem_fun (*(ARDOUR_UI::instance()), &ARDOUR_UI::disconnect_from_jack));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
act = register_action (jack_actions, X_("JACKReconnect"), _("Reconnect"), mem_fun (*(ARDOUR_UI::instance()), &ARDOUR_UI::reconnect_to_jack));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
|
||||
jack_items.push_back (MenuElem (_("Disconnect"), mem_fun (*(ARDOUR_UI::instance()), &ARDOUR_UI::disconnect_from_jack)));
|
||||
jack_disconnect_item = &jack_items.back();
|
||||
jack_disconnect_item->set_sensitive (false);
|
||||
jack_items.push_back (MenuElem (_("Reconnect"), mem_fun (*(ARDOUR_UI::instance()), &ARDOUR_UI::reconnect_to_jack)));
|
||||
jack_reconnect_item = &jack_items.back();
|
||||
jack_reconnect_item->set_sensitive (false);
|
||||
|
||||
jack_bufsize_menu = manage (new Menu);
|
||||
MenuList& jack_bufsize_items = jack_bufsize_menu->items();
|
||||
jack_bufsize_menu->set_name ("ArdourContextMenu");
|
||||
|
||||
jack_bufsize_items.push_back (MenuElem (X_("32"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 32)));
|
||||
jack_bufsize_items.push_back (MenuElem (X_("64"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 64)));
|
||||
jack_bufsize_items.push_back (MenuElem (X_("128"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 128)));
|
||||
jack_bufsize_items.push_back (MenuElem (X_("256"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 256)));
|
||||
jack_bufsize_items.push_back (MenuElem (X_("512"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 512)));
|
||||
jack_bufsize_items.push_back (MenuElem (X_("1024"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 1024)));
|
||||
jack_bufsize_items.push_back (MenuElem (X_("2048"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 2048)));
|
||||
jack_bufsize_items.push_back (MenuElem (X_("4096"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 4096)));
|
||||
jack_bufsize_items.push_back (MenuElem (X_("8192"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 8192)));
|
||||
|
||||
jack_items.push_back (MenuElem (_("Latency"), *jack_bufsize_menu));
|
||||
jack_bufsize_menu->set_sensitive (false);
|
||||
|
||||
items.push_back (MenuElem (_("JACK"), *jack_menu));
|
||||
RadioAction::Group jack_latency_group;
|
||||
|
||||
/* windows menu */
|
||||
|
||||
Menu *window_menu = new Menu();
|
||||
MenuList& window_items = window_menu->items();
|
||||
window_menu->set_name ("ArdourContextMenu");
|
||||
act = register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency32"), X_("32"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 32));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
act = register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency64"), X_("64"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 64));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
act = register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency128"), X_("128"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 128));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
act = register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency256"), X_("256"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 256));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
act = register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency512"), X_("512"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 512));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
act = register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency1024"), X_("1024"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 1024));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
act = register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency2048"), X_("2048"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 2048));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
act = register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency4096"), X_("4096"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 4096));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
act = register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency8192"), X_("8192"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 8192));
|
||||
jack_sensitive_actions.push_back (act);
|
||||
|
||||
window_items.push_back (TearoffMenuElem());
|
||||
Glib::RefPtr<ActionGroup> common_actions = ActionGroup::create (X_("Common"));
|
||||
|
||||
window_items.push_back (MenuElem (_("Editor"), mem_fun(*this, &ARDOUR_UI::goto_editor_window)));
|
||||
window_items.push_back (MenuElem (_("Mixer"), mem_fun(*this, &ARDOUR_UI::goto_mixer_window)));
|
||||
register_action (common_actions, X_("Start-Prefix"), _("start prefix"), mem_fun(*this, &ARDOUR_UI::start_keyboard_prefix));
|
||||
register_action (common_actions, X_("Quit"), _("quit"), (mem_fun(*this, &ARDOUR_UI::finish)));
|
||||
|
||||
window_items.push_back (SeparatorElem());
|
||||
/* windows visibility actions */
|
||||
|
||||
window_items.push_back
|
||||
(CheckMenuElem
|
||||
(_("Options Editor"),
|
||||
mem_fun(*this, &ARDOUR_UI::toggle_options_window)));
|
||||
options_window_check = dynamic_cast<CheckMenuItem*>(&window_items.back());
|
||||
// options_window_check->set_sensitive (false);
|
||||
|
||||
window_items.push_back
|
||||
(CheckMenuElem
|
||||
(_("Audio Library"),
|
||||
mem_fun(*this, &ARDOUR_UI::toggle_sfdb_window)));
|
||||
sfdb_check = dynamic_cast<CheckMenuItem*>(&window_items.back());
|
||||
|
||||
window_items.push_back
|
||||
(CheckMenuElem
|
||||
(_("Track/Bus Inspector"),
|
||||
mem_fun(*this, &ARDOUR_UI::toggle_route_params_window)));
|
||||
route_params_check = dynamic_cast<CheckMenuItem*>(&window_items.back());
|
||||
route_params_check->set_sensitive (false);
|
||||
|
||||
window_items.push_back
|
||||
(CheckMenuElem
|
||||
(_("Connections"),
|
||||
mem_fun(*this, &ARDOUR_UI::toggle_connection_editor)));
|
||||
connection_editor_check = dynamic_cast<CheckMenuItem*>(&window_items.back());
|
||||
connection_editor_check->set_sensitive (false);
|
||||
|
||||
#if 0
|
||||
window_items.push_back
|
||||
(CheckMenuElem
|
||||
(_("Meter Bridge"),
|
||||
mem_fun(*this, &ARDOUR_UI::toggle_meter_bridge_window)));
|
||||
meter_bridge_dialog_check = dynamic_cast<CheckMenuItem*>(&window_items.back());
|
||||
meter_bridge_dialog_check->set_sensitive (false);
|
||||
#endif
|
||||
|
||||
window_items.push_back
|
||||
(CheckMenuElem
|
||||
(_("Locations"),
|
||||
mem_fun(*this, &ARDOUR_UI::toggle_location_window)));
|
||||
locations_dialog_check = dynamic_cast<CheckMenuItem*>(&window_items.back());
|
||||
locations_dialog_check->set_sensitive (false);
|
||||
|
||||
window_items.push_back
|
||||
(CheckMenuElem
|
||||
(_("Big Clock"),
|
||||
mem_fun(*this, &ARDOUR_UI::toggle_big_clock_window)));
|
||||
big_clock_check = dynamic_cast<CheckMenuItem*>(&window_items.back());
|
||||
|
||||
window_items.push_back (SeparatorElem());
|
||||
|
||||
window_items.push_back (MenuElem (_("About"), mem_fun(*this, &ARDOUR_UI::show_splash)));
|
||||
register_action (common_actions, X_("GotoEditor"), _("Editor"), mem_fun(*this, &ARDOUR_UI::goto_editor_window));
|
||||
register_action (common_actions, X_("GotoMixer"), _("Mixer"), mem_fun(*this, &ARDOUR_UI::goto_mixer_window));
|
||||
register_toggle_action (common_actions, X_("ToggleOptionsEditor"), _("Options Editor"), mem_fun(*this, &ARDOUR_UI::toggle_options_window));
|
||||
register_toggle_action (common_actions, X_("ToggleAudioLibrary"), _("Audio Library"), mem_fun(*this, &ARDOUR_UI::toggle_sfdb_window));
|
||||
act = register_toggle_action (common_actions, X_("ToggleInspector"), _("Track/Bus Inspector"), mem_fun(*this, &ARDOUR_UI::toggle_route_params_window));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_toggle_action (common_actions, X_("ToggleConnections"), _("Connections"), mem_fun(*this, &ARDOUR_UI::toggle_connection_editor));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_toggle_action (common_actions, X_("ToggleLocations"), _("Locations"), mem_fun(*this, &ARDOUR_UI::toggle_location_window));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_toggle_action (common_actions, X_("ToggleBigClock"), _("Big Clock"), mem_fun(*this, &ARDOUR_UI::toggle_big_clock_window));
|
||||
session_sensitive_actions.push_back (act);
|
||||
register_action (common_actions, X_("About"), _("About"), mem_fun(*this, &ARDOUR_UI::show_splash));
|
||||
|
||||
act = register_action (common_actions, X_("ToggleAutoLoop"), _("toggle auto loop"), mem_fun(*this, &ARDOUR_UI::toggle_session_auto_loop));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TogglePunchIn"), _("toggle punch in"), mem_fun(*this, &ARDOUR_UI::toggle_session_punch_in));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("NewSession"), _("new session"), bind (mem_fun(*this, &ARDOUR_UI::new_session), false, string()));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("AddAudioTrack"), _("add audio track"), bind (mem_fun(*this, &ARDOUR_UI::session_add_audio_track), 1, 1));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("AddAudioBus"), _("add audio bus"), bind (mem_fun(*this, &ARDOUR_UI::session_add_audio_bus), 1, 1));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("Save"), _("Save"), bind (mem_fun(*this, &ARDOUR_UI::save_state), string("")));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("RemoveLastCapture"), _("remove last capture"), mem_fun(*this, &ARDOUR_UI::remove_last_capture));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportStop"), _("transport stop"), mem_fun(*this, &ARDOUR_UI::transport_stop));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportStopAndForgetCapture"), _("transport stop and forget capture"), mem_fun(*this, &ARDOUR_UI::transport_stop_and_forget_capture));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportRoll"), _("transport roll"), mem_fun(*this, &ARDOUR_UI::transport_roll));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportLoop"), _("transport loop"), mem_fun(*this, &ARDOUR_UI::transport_loop));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportRecord"), _("transport record"), mem_fun(*this, &ARDOUR_UI::transport_record));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportRewind"), _("transport rewind"), bind (mem_fun(*this, &ARDOUR_UI::transport_rewind), 0));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportRewindSlow"), _("transport rewind slow"), bind (mem_fun(*this, &ARDOUR_UI::transport_rewind), -1));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportRewindFast"), _("transport rewind fast"), bind (mem_fun(*this, &ARDOUR_UI::transport_rewind), 1));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportForward"), _("transport forward"), bind (mem_fun(*this, &ARDOUR_UI::transport_forward), 0));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportForwardSlow"), _("transport forward slow"), bind (mem_fun(*this, &ARDOUR_UI::transport_forward), -1));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportForwardFast"), _("transport forward fast"), bind (mem_fun(*this, &ARDOUR_UI::transport_forward), 1));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportGotoStart"), _("transport goto start"), mem_fun(*this, &ARDOUR_UI::transport_goto_start));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("TransportGotoEnd"), _("transport goto end"), mem_fun(*this, &ARDOUR_UI::transport_goto_end));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("SendAllMidiFeedback"), _("send all midi feedback"), mem_fun(*this, &ARDOUR_UI::send_all_midi_feedback));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack1"), _("toggle record enable track1"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 0U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack2"), _("toggle record enable track2"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 1U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack3"), _("toggle record enable track3"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 2U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack4"), _("toggle record enable track4"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 3U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack5"), _("toggle record enable track5"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 4U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack6"), _("toggle record enable track6"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 5U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack7"), _("toggle record enable track7"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 6U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack8"), _("toggle record enable track8"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 7U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack9"), _("toggle record enable track9"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 8U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack10"), _("toggle record enable track10"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 9U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack11"), _("toggle record enable track11"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 10U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack12"), _("toggle record enable track12"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 11U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack13"), _("toggle record enable track13"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 12U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack14"), _("toggle record enable track14"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 13U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack15"), _("toggle record enable track15"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 14U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack16"), _("toggle record enable track16"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 15U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack17"), _("toggle record enable track17"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 16U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack18"), _("toggle record enable track18"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 17U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack19"), _("toggle record enable track19"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 18U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack20"), _("toggle record enable track20"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 19U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack21"), _("toggle record enable track21"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 20U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack22"), _("toggle record enable track22"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 21U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack23"), _("toggle record enable track23"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 22U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack24"), _("toggle record enable track24"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 23U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack25"), _("toggle record enable track25"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 24U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack26"), _("toggle record enable track26"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 25U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack27"), _("toggle record enable track27"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 26U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack28"), _("toggle record enable track28"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 27U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack29"), _("toggle record enable track29"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 28U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack30"), _("toggle record enable track30"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 29U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack31"), _("toggle record enable track31"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 30U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
act = register_action (common_actions, X_("ToggleRecordEnableTrack32"), _("toggle record enable track32"), bind (mem_fun(*this, &ARDOUR_UI::toggle_record_enable), 31U));
|
||||
session_sensitive_actions.push_back (act);
|
||||
|
||||
items.push_back (MenuElem (_("Windows"), *window_menu));
|
||||
ui_manager->insert_action_group (jack_actions);
|
||||
ui_manager->insert_action_group (main_actions);
|
||||
ui_manager->insert_action_group (common_actions);
|
||||
|
||||
register_ui_manager (ui_manager);
|
||||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::build_menu_bar ()
|
||||
{
|
||||
menu_bar = dynamic_cast<MenuBar*> (ui_manager->get_widget (X_("/Main")));
|
||||
menu_bar->set_name ("MainMenuBar");
|
||||
|
||||
wall_clock_box.add (wall_clock_label);
|
||||
wall_clock_box.set_name ("WallClock");
|
||||
|
|
@ -300,7 +316,6 @@ ARDOUR_UI::build_menu_bar ()
|
|||
menu_bar_base.add (menu_hbox);
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
ARDOUR_UI::editor_display_control_changed (Editing::DisplayControl c)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -221,7 +221,6 @@ AudioTimeAxisView::AudioTimeAxisView (PublicEditor& ed, Session& sess, Route& rt
|
|||
mute_changed(0);
|
||||
redirects_changed (0);
|
||||
reset_redirect_automation_curves ();
|
||||
edit_group_menu_radio_group = 0;
|
||||
y_position = -1;
|
||||
|
||||
ensure_xml_node ();
|
||||
|
|
@ -831,6 +830,7 @@ void
|
|||
AudioTimeAxisView::rename_current_playlist ()
|
||||
{
|
||||
ArdourPrompter prompter (true);
|
||||
string name;
|
||||
|
||||
AudioPlaylist *pl;
|
||||
DiskStream *ds;
|
||||
|
|
@ -841,15 +841,15 @@ AudioTimeAxisView::rename_current_playlist ()
|
|||
|
||||
prompter.set_prompt (_("Name for playlist"));
|
||||
prompter.set_initial_text (pl->name());
|
||||
prompter.done.connect (Main::quit.slot());
|
||||
prompter.show_all ();
|
||||
|
||||
Main::run ();
|
||||
|
||||
if (prompter.status == Gtkmm2ext::Prompter::entered) {
|
||||
string name;
|
||||
switch (prompter.run ()) {
|
||||
case GTK_RESPONSE_ACCEPT:
|
||||
prompter.get_result (name);
|
||||
pl->set_name (name);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -868,29 +868,29 @@ AudioTimeAxisView::use_copy_playlist ()
|
|||
{
|
||||
AudioPlaylist *pl;
|
||||
DiskStream *ds;
|
||||
string name;
|
||||
|
||||
if (((ds = get_diskstream()) == 0) || ((pl = ds->playlist()) == 0)) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
ArdourPrompter prompter (true);
|
||||
string new_name = Playlist::bump_name (pl->name(), _session);
|
||||
|
||||
|
||||
prompter.set_prompt (_("Name for playlist"));
|
||||
prompter.set_initial_text (new_name);
|
||||
prompter.done.connect (Main::quit.slot());
|
||||
prompter.show_all ();
|
||||
|
||||
Main::run ();
|
||||
|
||||
if (prompter.status == Gtkmm2ext::Prompter::entered) {
|
||||
string name;
|
||||
switch (prompter.run ()) {
|
||||
case GTK_RESPONSE_ACCEPT:
|
||||
prompter.get_result (name);
|
||||
|
||||
ds->use_copy_playlist ();
|
||||
|
||||
pl = ds->playlist();
|
||||
pl->set_name (name);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -899,6 +899,7 @@ AudioTimeAxisView::use_new_playlist ()
|
|||
{
|
||||
AudioPlaylist *pl;
|
||||
DiskStream *ds;
|
||||
string name;
|
||||
|
||||
if (((ds = get_diskstream()) == 0) || ((pl = ds->playlist()) == 0)) {
|
||||
return;
|
||||
|
|
@ -909,19 +910,17 @@ AudioTimeAxisView::use_new_playlist ()
|
|||
|
||||
prompter.set_prompt (_("Name for playlist"));
|
||||
prompter.set_initial_text (new_name);
|
||||
prompter.done.connect (Main::quit.slot());
|
||||
prompter.show_all ();
|
||||
|
||||
Main::run ();
|
||||
|
||||
if (prompter.status == Gtkmm2ext::Prompter::entered) {
|
||||
string name;
|
||||
|
||||
switch (prompter.run ()) {
|
||||
case GTK_RESPONSE_ACCEPT:
|
||||
prompter.get_result (name);
|
||||
|
||||
ds->use_new_playlist ();
|
||||
|
||||
pl = ds->playlist();
|
||||
pl->set_name (name);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -942,7 +941,7 @@ void
|
|||
AudioTimeAxisView::toggle_waveforms ()
|
||||
{
|
||||
if (view && waveform_item && !ignore_toggle) {
|
||||
view->set_show_waveforms (waveform_item->is_active());
|
||||
view->set_show_waveforms (waveform_item->get_active());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -18,7 +18,8 @@
|
|||
#include "libart_lgpl/art_rgb_pixbuf_affine.h"
|
||||
#include "canvas-imageframe.h"
|
||||
#include <libgnomecanvas/gnome-canvas-util.h>
|
||||
#include <libgnomecanvas/gnome-canvastypebuiltins.h>
|
||||
//GTK2FIX
|
||||
//#include <libgnomecanvas/gnome-canvastypebuiltins.h>
|
||||
|
||||
|
||||
enum {
|
||||
|
|
@ -44,7 +45,6 @@ static void gnome_canvas_imageframe_realize(GnomeCanvasItem *item) ;
|
|||
static void gnome_canvas_imageframe_unrealize(GnomeCanvasItem *item) ;
|
||||
static void gnome_canvas_imageframe_draw(GnomeCanvasItem *item, GdkDrawable *drawable, int x, int y, int width, int height) ;
|
||||
static double gnome_canvas_imageframe_point(GnomeCanvasItem *item, double x, double y, int cx, int cy, GnomeCanvasItem **actual_item) ;
|
||||
static void gnome_canvas_imageframe_translate(GnomeCanvasItem *item, double dx, double dy) ;
|
||||
static void gnome_canvas_imageframe_bounds(GnomeCanvasItem *item, double *x1, double *y1, double *x2, double *y2) ;
|
||||
static void gnome_canvas_imageframe_render(GnomeCanvasItem *item, GnomeCanvasBuf *buf) ;
|
||||
|
||||
|
|
@ -102,7 +102,6 @@ gnome_canvas_imageframe_class_init (GnomeCanvasImageFrameClass *class)
|
|||
item_class->unrealize = gnome_canvas_imageframe_unrealize;
|
||||
item_class->draw = gnome_canvas_imageframe_draw;
|
||||
item_class->point = gnome_canvas_imageframe_point;
|
||||
item_class->translate = gnome_canvas_imageframe_translate;
|
||||
item_class->bounds = gnome_canvas_imageframe_bounds;
|
||||
item_class->render = gnome_canvas_imageframe_render;
|
||||
}
|
||||
|
|
@ -116,7 +115,8 @@ gnome_canvas_imageframe_init (GnomeCanvasImageFrame *image)
|
|||
image->height = 0.0;
|
||||
image->drawwidth = 0.0;
|
||||
image->anchor = GTK_ANCHOR_CENTER;
|
||||
GNOME_CANVAS_ITEM(image)->object.flags |= GNOME_CANVAS_ITEM_NO_AUTO_REDRAW;
|
||||
// GTK2FIX
|
||||
// GNOME_CANVAS_ITEM(image)->object.flags |= GNOME_CANVAS_ITEM_NO_AUTO_REDRAW;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
@ -206,45 +206,6 @@ get_bounds_item_relative (GnomeCanvasImageFrame *image, double *px1, double *py1
|
|||
*py2 = y + image->height;
|
||||
}
|
||||
|
||||
static void
|
||||
get_bounds (GnomeCanvasImageFrame *image, double *px1, double *py1, double *px2, double *py2)
|
||||
{
|
||||
GnomeCanvasItem *item;
|
||||
double i2c[6];
|
||||
ArtDRect i_bbox, c_bbox;
|
||||
|
||||
item = GNOME_CANVAS_ITEM (image);
|
||||
|
||||
gnome_canvas_item_i2c_affine (item, i2c);
|
||||
|
||||
get_bounds_item_relative (image, &i_bbox.x0, &i_bbox.y0, &i_bbox.x1, &i_bbox.y1);
|
||||
art_drect_affine_transform (&c_bbox, &i_bbox, i2c);
|
||||
|
||||
/* add a fudge factor */
|
||||
*px1 = c_bbox.x0 - 1;
|
||||
*py1 = c_bbox.y0 - 1;
|
||||
*px2 = c_bbox.x1 + 1;
|
||||
*py2 = c_bbox.y1 + 1;
|
||||
}
|
||||
|
||||
/* deprecated */
|
||||
static void
|
||||
recalc_bounds (GnomeCanvasImageFrame *image)
|
||||
{
|
||||
GnomeCanvasItem *item;
|
||||
|
||||
item = GNOME_CANVAS_ITEM (image);
|
||||
|
||||
get_bounds (image, &item->x1, &item->y1, &item->x2, &item->y2);
|
||||
|
||||
item->x1 = image->cx;
|
||||
item->y1 = image->cy;
|
||||
item->x2 = image->cx + image->cwidth;
|
||||
item->y2 = image->cy + image->cheight;
|
||||
|
||||
gnome_canvas_group_child_bounds (GNOME_CANVAS_GROUP (item->parent), item);
|
||||
}
|
||||
|
||||
static void
|
||||
gnome_canvas_imageframe_set_arg (GtkObject *object, GtkArg *arg, guint arg_id)
|
||||
{
|
||||
|
|
@ -303,16 +264,8 @@ gnome_canvas_imageframe_set_arg (GtkObject *object, GtkArg *arg, guint arg_id)
|
|||
break;
|
||||
}
|
||||
|
||||
#ifdef OLD_XFORM
|
||||
if (update)
|
||||
(* GNOME_CANVAS_ITEM_CLASS (item->object.klass)->update) (item, NULL, NULL, 0);
|
||||
|
||||
if (calc_bounds)
|
||||
recalc_bounds (image);
|
||||
#else
|
||||
if (update)
|
||||
gnome_canvas_item_request_update (item);
|
||||
#endif
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
@ -375,9 +328,6 @@ gnome_canvas_imageframe_update (GnomeCanvasItem *item, double *affine, ArtSVP *c
|
|||
image->need_recalc = TRUE ;
|
||||
}
|
||||
|
||||
#ifdef OLD_XFORM
|
||||
recalc_bounds (image);
|
||||
#else
|
||||
get_bounds_item_relative (image, &i_bbox.x0, &i_bbox.y0, &i_bbox.x1, &i_bbox.y1);
|
||||
art_drect_affine_transform (&c_bbox, &i_bbox, affine);
|
||||
|
||||
|
|
@ -404,8 +354,6 @@ gnome_canvas_imageframe_update (GnomeCanvasItem *item, double *affine, ArtSVP *c
|
|||
image->affine[3] = (affine[3] * image->height) / h;
|
||||
image->affine[4] = i_bbox.x0 * affine[0] + i_bbox.y0 * affine[2] + affine[4];
|
||||
image->affine[5] = i_bbox.x0 * affine[1] + i_bbox.y0 * affine[3] + affine[5];
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
@ -491,21 +439,6 @@ gnome_canvas_imageframe_point (GnomeCanvasItem *item, double x, double y,
|
|||
return sqrt (dx * dx + dy * dy) / item->canvas->pixels_per_unit;
|
||||
}
|
||||
|
||||
static void
|
||||
gnome_canvas_imageframe_translate (GnomeCanvasItem *item, double dx, double dy)
|
||||
{
|
||||
#ifdef OLD_XFORM
|
||||
GnomeCanvasImageFrame *image;
|
||||
|
||||
image = GNOME_CANVAS_IMAGEFRAME (item);
|
||||
|
||||
image->x += dx;
|
||||
image->y += dy;
|
||||
|
||||
recalc_bounds (image);
|
||||
#endif
|
||||
}
|
||||
|
||||
static void
|
||||
gnome_canvas_imageframe_bounds (GnomeCanvasItem *item, double *x1, double *y1, double *x2, double *y2)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -91,7 +91,8 @@ gnome_canvas_simpleline_init (GnomeCanvasSimpleLine *simpleline)
|
|||
simpleline->y2 = 0.0;
|
||||
simpleline->color = RGBA_TO_UINT(98,123,174,241);
|
||||
simpleline->horizontal = TRUE; /* reset in the _update() method */
|
||||
GNOME_CANVAS_ITEM(simpleline)->object.flags |= GNOME_CANVAS_ITEM_NO_AUTO_REDRAW;
|
||||
// GTK2FIX
|
||||
// GNOME_CANVAS_ITEM(simpleline)->object.flags |= GNOME_CANVAS_ITEM_NO_AUTO_REDRAW;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
|
|
@ -50,8 +50,8 @@ struct _GnomeCanvasSimpleLine
|
|||
/* cached values set during update/used during render */
|
||||
|
||||
unsigned char r, b, g, a;
|
||||
guint32 bbox_ulx, bbox_uly;
|
||||
guint32 bbox_lrx, bbox_lry;
|
||||
gint32 bbox_ulx, bbox_uly;
|
||||
gint32 bbox_lrx, bbox_lry;
|
||||
};
|
||||
|
||||
struct _GnomeCanvasSimpleLineClass {
|
||||
|
|
|
|||
|
|
@ -108,7 +108,8 @@ gnome_canvas_simplerect_init (GnomeCanvasSimpleRect *simplerect)
|
|||
simplerect->outline_pixels = 1;
|
||||
simplerect->outline_what = 0xf;
|
||||
|
||||
GNOME_CANVAS_ITEM(simplerect)->object.flags |= GNOME_CANVAS_ITEM_NO_AUTO_REDRAW;
|
||||
// GTK2FIX
|
||||
// GNOME_CANVAS_ITEM(simplerect)->object.flags |= GNOME_CANVAS_ITEM_NO_AUTO_REDRAW;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
|
|
@ -56,8 +56,8 @@ struct _GnomeCanvasSimpleRect
|
|||
unsigned char fill_r, fill_b, fill_g, fill_a;
|
||||
unsigned char outline_r, outline_b, outline_g;
|
||||
unsigned char outline_what;
|
||||
guint32 bbox_ulx, bbox_uly;
|
||||
guint32 bbox_lrx, bbox_lry;
|
||||
gint32 bbox_ulx, bbox_uly;
|
||||
gint32 bbox_lrx, bbox_lry;
|
||||
};
|
||||
|
||||
struct _GnomeCanvasSimpleRectClass {
|
||||
|
|
|
|||
|
|
@ -182,7 +182,8 @@ gnome_canvas_waveview_init (GnomeCanvasWaveView *waveview)
|
|||
|
||||
waveview->wave_color = RGBA_TO_UINT(44,35,126,255);
|
||||
|
||||
GNOME_CANVAS_ITEM(waveview)->object.flags |= GNOME_CANVAS_ITEM_NO_AUTO_REDRAW;
|
||||
// GTK2FIX
|
||||
// GNOME_CANVAS_ITEM(waveview)->object.flags |= GNOME_CANVAS_ITEM_NO_AUTO_REDRAW;
|
||||
}
|
||||
|
||||
#define DEBUG_CACHE 0
|
||||
|
|
@ -197,8 +198,6 @@ gnome_canvas_waveview_ensure_cache (GnomeCanvasWaveView *waveview, gulong start_
|
|||
gulong npeaks;
|
||||
gulong offset;
|
||||
gulong ostart;
|
||||
gulong present_frames;
|
||||
gulong present_entries;
|
||||
gulong copied;
|
||||
GnomeCanvasWaveViewCache *cache;
|
||||
float* gain;
|
||||
|
|
|
|||
|
|
@ -45,8 +45,6 @@ using namespace sigc;
|
|||
|
||||
ConnectionEditor::ConnectionEditor ()
|
||||
: ArdourDialog ("connection editor"),
|
||||
input_connection_display (1),
|
||||
output_connection_display (1),
|
||||
input_frame (_("Input Connections")),
|
||||
output_frame (_("Output Connections")),
|
||||
new_input_connection_button (_("New Input")),
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ using __gnu_cxx::slist;
|
|||
#include <gtkmm/button.h>
|
||||
#include <gtkmm/frame.h>
|
||||
#include <gtkmm/notebook.h>
|
||||
#include <gtkmm/clist.h>
|
||||
#include <gtkmm/treeview.h>
|
||||
|
||||
#include "ardour_dialog.h"
|
||||
|
||||
|
|
@ -60,8 +60,8 @@ class ConnectionEditor : public ArdourDialog {
|
|||
int selected_port;
|
||||
bool push_at_front;
|
||||
|
||||
Gtk::CList input_connection_display;
|
||||
Gtk::CList output_connection_display;
|
||||
Gtk::TreeView input_connection_display;
|
||||
Gtk::TreeView output_connection_display;
|
||||
Gtk::ScrolledWindow input_scroller;
|
||||
Gtk::ScrolledWindow output_scroller;
|
||||
|
||||
|
|
@ -128,14 +128,14 @@ class ConnectionEditor : public ArdourDialog {
|
|||
void cancel ();
|
||||
void accept ();
|
||||
|
||||
void port_selection_handler (gint row, gint col, GdkEvent *ev, Gtk::CList *);
|
||||
void port_selection_handler (gint row, gint col, GdkEvent*, Gtk::TreeView*);
|
||||
|
||||
void add_port ();
|
||||
void remove_port (int which_port);
|
||||
|
||||
void port_column_click (gint col, Gtk::CList *clist);
|
||||
gint port_button_event (GdkEventButton *, Gtk::CList *clist);
|
||||
gint connection_click (GdkEventButton *ev, Gtk::CList *clist);
|
||||
void port_column_click (gint col, Gtk::TreeView* );
|
||||
gint port_button_event (GdkEventButton *, Gtk::TreeView*);
|
||||
gint connection_click (GdkEventButton *ev, Gtk::TreeView*);
|
||||
void connection_selected (gint, gint, GdkEvent *, bool);
|
||||
|
||||
sigc::connection config_connection;
|
||||
|
|
|
|||
|
|
@ -1829,8 +1829,6 @@ class Editor : public PublicEditor
|
|||
/* GTK2 stuff */
|
||||
|
||||
Glib::RefPtr<Gtk::UIManager> ui_manager;
|
||||
vector<Glib::RefPtr<Gtk::Action> > session_requiring_actions;
|
||||
vector<Glib::RefPtr<Gtk::Action> > region_list_selection_requiring_actions;
|
||||
};
|
||||
|
||||
#endif /* __ardour_editor_h__ */
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ using namespace std;
|
|||
using namespace sigc;
|
||||
using namespace ARDOUR;
|
||||
using namespace Editing;
|
||||
using namespace ActionManager;
|
||||
|
||||
void
|
||||
Editor::register_actions ()
|
||||
|
|
@ -19,147 +20,147 @@ Editor::register_actions ()
|
|||
|
||||
Glib::RefPtr<ActionGroup> editor_actions = ActionGroup::create (X_("Editor"));
|
||||
|
||||
register_action (editor_actions, "toggle-xfades-active", "toggle-xfades-active", mem_fun(*this, &Editor::toggle_xfades_active));
|
||||
register_action (editor_actions, "toggle-xfades-active", _("toggle xfades active"), mem_fun(*this, &Editor::toggle_xfades_active));
|
||||
|
||||
register_action (editor_actions, "playhead-to-next-region-start", "playhead-to-next-region-start", bind (mem_fun(*this, &Editor::cursor_to_next_region_point), playhead_cursor, RegionPoint (Start)));
|
||||
register_action (editor_actions, "playhead-to-next-region-end", "playhead-to-next-region-end", bind (mem_fun(*this, &Editor::cursor_to_next_region_point), playhead_cursor, RegionPoint (End)));
|
||||
register_action (editor_actions, "playhead-to-next-region-sync", "playhead-to-next-region-sync", bind (mem_fun(*this, &Editor::cursor_to_next_region_point), playhead_cursor, RegionPoint (SyncPoint)));
|
||||
register_action (editor_actions, "playhead-to-next-region-start", _("playhead to next region start"), bind (mem_fun(*this, &Editor::cursor_to_next_region_point), playhead_cursor, RegionPoint (Start)));
|
||||
register_action (editor_actions, "playhead-to-next-region-end", _("playhead to next region end"), bind (mem_fun(*this, &Editor::cursor_to_next_region_point), playhead_cursor, RegionPoint (End)));
|
||||
register_action (editor_actions, "playhead-to-next-region-sync", _("playhead to next region sync"), bind (mem_fun(*this, &Editor::cursor_to_next_region_point), playhead_cursor, RegionPoint (SyncPoint)));
|
||||
|
||||
register_action (editor_actions, "playhead-to-previous-region-start", "playhead-to-previous-region-start", bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), playhead_cursor, RegionPoint (Start)));
|
||||
register_action (editor_actions, "playhead-to-previous-region-end", "playhead-to-previous-region-end", bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), playhead_cursor, RegionPoint (End)));
|
||||
register_action (editor_actions, "playhead-to-previous-region-sync", "playhead-to-previous-region-sync", bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), playhead_cursor, RegionPoint (SyncPoint)));
|
||||
register_action (editor_actions, "playhead-to-previous-region-start", _("playhead to previous region start"), bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), playhead_cursor, RegionPoint (Start)));
|
||||
register_action (editor_actions, "playhead-to-previous-region-end", _("playhead to previous region end"), bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), playhead_cursor, RegionPoint (End)));
|
||||
register_action (editor_actions, "playhead-to-previous-region-sync", _("playhead to previous region sync"), bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), playhead_cursor, RegionPoint (SyncPoint)));
|
||||
|
||||
register_action (editor_actions, "edit-cursor-to-next-region-start", "edit-cursor-to-next-region-start", bind (mem_fun(*this, &Editor::cursor_to_next_region_point), edit_cursor, RegionPoint (Start)));
|
||||
register_action (editor_actions, "edit-cursor-to-next-region-end", "edit-cursor-to-next-region-end", bind (mem_fun(*this, &Editor::cursor_to_next_region_point), edit_cursor, RegionPoint (End)));
|
||||
register_action (editor_actions, "edit-cursor-to-next-region-sync", "edit-cursor-to-next-region-sync", bind (mem_fun(*this, &Editor::cursor_to_next_region_point), edit_cursor, RegionPoint (SyncPoint)));
|
||||
register_action (editor_actions, "edit-cursor-to-next-region-start", _("edit cursor to next region start"), bind (mem_fun(*this, &Editor::cursor_to_next_region_point), edit_cursor, RegionPoint (Start)));
|
||||
register_action (editor_actions, "edit-cursor-to-next-region-end", _("edit cursor to next region end"), bind (mem_fun(*this, &Editor::cursor_to_next_region_point), edit_cursor, RegionPoint (End)));
|
||||
register_action (editor_actions, "edit-cursor-to-next-region-sync", _("edit cursor to next region sync"), bind (mem_fun(*this, &Editor::cursor_to_next_region_point), edit_cursor, RegionPoint (SyncPoint)));
|
||||
|
||||
register_action (editor_actions, "edit-cursor-to-previous-region-start", "edit-cursor-to-previous-region-start", bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), edit_cursor, RegionPoint (Start)));
|
||||
register_action (editor_actions, "edit-cursor-to-previous-region-end", "edit-cursor-to-previous-region-end", bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), edit_cursor, RegionPoint (End)));
|
||||
register_action (editor_actions, "edit-cursor-to-previous-region-sync", "edit-cursor-to-previous-region-sync", bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), edit_cursor, RegionPoint (SyncPoint)));
|
||||
register_action (editor_actions, "edit-cursor-to-previous-region-start", _("edit cursor to previous region start"), bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), edit_cursor, RegionPoint (Start)));
|
||||
register_action (editor_actions, "edit-cursor-to-previous-region-end", _("edit cursor to previous region end"), bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), edit_cursor, RegionPoint (End)));
|
||||
register_action (editor_actions, "edit-cursor-to-previous-region-sync", _("edit cursor to previous region sync"), bind (mem_fun(*this, &Editor::cursor_to_previous_region_point), edit_cursor, RegionPoint (SyncPoint)));
|
||||
|
||||
register_action (editor_actions, "playhead-to-range-start", "playhead-to-range-start", bind (mem_fun(*this, &Editor::cursor_to_selection_start), playhead_cursor));
|
||||
register_action (editor_actions, "playhead-to-range-end", "playhead-to-range-end", bind (mem_fun(*this, &Editor::cursor_to_selection_end), playhead_cursor));
|
||||
register_action (editor_actions, "playhead-to-range-start", _("playhead to range start"), bind (mem_fun(*this, &Editor::cursor_to_selection_start), playhead_cursor));
|
||||
register_action (editor_actions, "playhead-to-range-end", _("playhead to range end"), bind (mem_fun(*this, &Editor::cursor_to_selection_end), playhead_cursor));
|
||||
|
||||
register_action (editor_actions, "edit-cursor-to-range-start", "edit-cursor-to-range-start", bind (mem_fun(*this, &Editor::cursor_to_selection_start), edit_cursor));
|
||||
register_action (editor_actions, "edit-cursor-to-range-end", "edit-cursor-to-range-end", bind (mem_fun(*this, &Editor::cursor_to_selection_end), edit_cursor));
|
||||
register_action (editor_actions, "edit-cursor-to-range-start", _("edit cursor to range start"), bind (mem_fun(*this, &Editor::cursor_to_selection_start), edit_cursor));
|
||||
register_action (editor_actions, "edit-cursor-to-range-end", _("edit cursor to range end"), bind (mem_fun(*this, &Editor::cursor_to_selection_end), edit_cursor));
|
||||
|
||||
register_action (editor_actions, "jump-forward-to-mark", "jump-forward-to-mark", mem_fun(*this, &Editor::jump_forward_to_mark));
|
||||
register_action (editor_actions, "jump-backward-to-mark", "jump-backward-to-mark", mem_fun(*this, &Editor::jump_backward_to_mark));
|
||||
register_action (editor_actions, "add-location-from-playhead", "add-location-from-playhead", mem_fun(*this, &Editor::add_location_from_playhead_cursor));
|
||||
register_action (editor_actions, "jump-forward-to-mark", _("jump forward to mark"), mem_fun(*this, &Editor::jump_forward_to_mark));
|
||||
register_action (editor_actions, "jump-backward-to-mark", _("jump backward to mark"), mem_fun(*this, &Editor::jump_backward_to_mark));
|
||||
register_action (editor_actions, "add-location-from-playhead", _("add location from playhead"), mem_fun(*this, &Editor::add_location_from_playhead_cursor));
|
||||
|
||||
register_action (editor_actions, "nudge-forward", "nudge-forward", bind (mem_fun(*this, &Editor::nudge_forward), false));
|
||||
register_action (editor_actions, "nudge-next-forward", "nudge-next-forward", bind (mem_fun(*this, &Editor::nudge_forward), true));
|
||||
register_action (editor_actions, "nudge-backward", "nudge-backward", bind (mem_fun(*this, &Editor::nudge_backward), false));
|
||||
register_action (editor_actions, "nudge-next-backward", "nudge-next-backward", bind (mem_fun(*this, &Editor::nudge_backward), true));
|
||||
register_action (editor_actions, "nudge-forward", _("nudge forward"), bind (mem_fun(*this, &Editor::nudge_forward), false));
|
||||
register_action (editor_actions, "nudge-next-forward", _("nudge next forward"), bind (mem_fun(*this, &Editor::nudge_forward), true));
|
||||
register_action (editor_actions, "nudge-backward", _("nudge backward"), bind (mem_fun(*this, &Editor::nudge_backward), false));
|
||||
register_action (editor_actions, "nudge-next-backward", _("nudge next backward"), bind (mem_fun(*this, &Editor::nudge_backward), true));
|
||||
|
||||
register_action (editor_actions, "toggle-playback", "toggle-playback", bind (mem_fun(*this, &Editor::toggle_playback), false));
|
||||
register_action (editor_actions, "toggle-playback-forget-capture", "toggle-playback-forget-capture", bind (mem_fun(*this, &Editor::toggle_playback), true));
|
||||
register_action (editor_actions, "toggle-playback", _("toggle playback"), bind (mem_fun(*this, &Editor::toggle_playback), false));
|
||||
register_action (editor_actions, "toggle-playback-forget-capture", _("toggle playback forget capture"), bind (mem_fun(*this, &Editor::toggle_playback), true));
|
||||
|
||||
register_action (editor_actions, "toggle-loop-playback", "toggle-loop-playback", mem_fun(*this, &Editor::toggle_loop_playback));
|
||||
register_action (editor_actions, "toggle-loop-playback", _("toggle loop playback"), mem_fun(*this, &Editor::toggle_loop_playback));
|
||||
|
||||
register_action (editor_actions, "temporal-zoom-out", "temporal-zoom-out", bind (mem_fun(*this, &Editor::temporal_zoom_step), true));
|
||||
register_action (editor_actions, "temporal-zoom-in", "temporal-zoom-in", bind (mem_fun(*this, &Editor::temporal_zoom_step), false));
|
||||
register_action (editor_actions, "zoom-to-session", "zoom-to-session", mem_fun(*this, &Editor::temporal_zoom_session));
|
||||
register_action (editor_actions, "temporal-zoom-out", _("temporal zoom out"), bind (mem_fun(*this, &Editor::temporal_zoom_step), true));
|
||||
register_action (editor_actions, "temporal-zoom-in", _("temporal zoom in"), bind (mem_fun(*this, &Editor::temporal_zoom_step), false));
|
||||
register_action (editor_actions, "zoom-to-session", _("zoom to session"), mem_fun(*this, &Editor::temporal_zoom_session));
|
||||
|
||||
register_action (editor_actions, "scroll-tracks-up", "scroll-tracks-up", mem_fun(*this, &Editor::scroll_tracks_up));
|
||||
register_action (editor_actions, "scroll-tracks-down", "scroll-tracks-down", mem_fun(*this, &Editor::scroll_tracks_down));
|
||||
register_action (editor_actions, "step-tracks-up", "step-tracks-up", mem_fun(*this, &Editor::scroll_tracks_up_line));
|
||||
register_action (editor_actions, "step-tracks-down", "step-tracks-down", mem_fun(*this, &Editor::scroll_tracks_down_line));
|
||||
register_action (editor_actions, "scroll-tracks-up", _("scroll tracks up"), mem_fun(*this, &Editor::scroll_tracks_up));
|
||||
register_action (editor_actions, "scroll-tracks-down", _("scroll tracks down"), mem_fun(*this, &Editor::scroll_tracks_down));
|
||||
register_action (editor_actions, "step-tracks-up", _("step tracks up"), mem_fun(*this, &Editor::scroll_tracks_up_line));
|
||||
register_action (editor_actions, "step-tracks-down", _("step tracks down"), mem_fun(*this, &Editor::scroll_tracks_down_line));
|
||||
|
||||
register_action (editor_actions, "scroll-backward", "scroll-backward", bind (mem_fun(*this, &Editor::scroll_backward), 0.8f));
|
||||
register_action (editor_actions, "scroll-forward", "scroll-forward", bind (mem_fun(*this, &Editor::scroll_forward), 0.8f));
|
||||
register_action (editor_actions, "goto", "goto", mem_fun(*this, &Editor::goto_frame));
|
||||
register_action (editor_actions, "center-playhead", "center-playhead", mem_fun(*this, &Editor::center_playhead));
|
||||
register_action (editor_actions, "center-edit_cursor", "center-edit_cursor", mem_fun(*this, &Editor::center_edit_cursor));
|
||||
register_action (editor_actions, "playhead-forward", "playhead-forward", mem_fun(*this, &Editor::playhead_forward));
|
||||
register_action (editor_actions, "playhead-backward", "playhead-backward", mem_fun(*this, &Editor::playhead_backward));
|
||||
register_action (editor_actions, "playhead-to-edit", "playhead-to-edit", bind (mem_fun(*this, &Editor::cursor_align), true));
|
||||
register_action (editor_actions, "edit-to-playhead", "edit-to-playhead", bind (mem_fun(*this, &Editor::cursor_align), false));
|
||||
register_action (editor_actions, "scroll-backward", _("scroll backward"), bind (mem_fun(*this, &Editor::scroll_backward), 0.8f));
|
||||
register_action (editor_actions, "scroll-forward", _("scroll forward"), bind (mem_fun(*this, &Editor::scroll_forward), 0.8f));
|
||||
register_action (editor_actions, "goto", _("goto"), mem_fun(*this, &Editor::goto_frame));
|
||||
register_action (editor_actions, "center-playhead", _("center playhead"), mem_fun(*this, &Editor::center_playhead));
|
||||
register_action (editor_actions, "center-edit_cursor", _("center edit_cursor"), mem_fun(*this, &Editor::center_edit_cursor));
|
||||
register_action (editor_actions, "playhead-forward", _("playhead forward"), mem_fun(*this, &Editor::playhead_forward));
|
||||
register_action (editor_actions, "playhead-backward", _("playhead backward"), mem_fun(*this, &Editor::playhead_backward));
|
||||
register_action (editor_actions, "playhead-to-edit", _("playhead to edit"), bind (mem_fun(*this, &Editor::cursor_align), true));
|
||||
register_action (editor_actions, "edit-to-playhead", _("edit to playhead"), bind (mem_fun(*this, &Editor::cursor_align), false));
|
||||
|
||||
register_action (editor_actions, "align-regions-start", "align-regions-start", bind (mem_fun(*this, &Editor::align), ARDOUR::Start));
|
||||
register_action (editor_actions, "align-regions-start-relative", "align-regions-start-relative", bind (mem_fun(*this, &Editor::align_relative), ARDOUR::Start));
|
||||
register_action (editor_actions, "align-regions-end", "align-regions-end", bind (mem_fun(*this, &Editor::align), ARDOUR::End));
|
||||
register_action (editor_actions, "align-regions-end-relative", "align-regions-end-relative", bind (mem_fun(*this, &Editor::align_relative), ARDOUR::End));
|
||||
register_action (editor_actions, "align-regions-sync", "align-regions-sync", bind (mem_fun(*this, &Editor::align), ARDOUR::SyncPoint));
|
||||
register_action (editor_actions, "align-regions-sync-relative", "align-regions-sync-relative", bind (mem_fun(*this, &Editor::align_relative), ARDOUR::SyncPoint));
|
||||
register_action (editor_actions, "align-regions-start", _("align regions start"), bind (mem_fun(*this, &Editor::align), ARDOUR::Start));
|
||||
register_action (editor_actions, "align-regions-start-relative", _("align regions start relative"), bind (mem_fun(*this, &Editor::align_relative), ARDOUR::Start));
|
||||
register_action (editor_actions, "align-regions-end", _("align regions end"), bind (mem_fun(*this, &Editor::align), ARDOUR::End));
|
||||
register_action (editor_actions, "align-regions-end-relative", _("align regions end relative"), bind (mem_fun(*this, &Editor::align_relative), ARDOUR::End));
|
||||
register_action (editor_actions, "align-regions-sync", _("align regions sync"), bind (mem_fun(*this, &Editor::align), ARDOUR::SyncPoint));
|
||||
register_action (editor_actions, "align-regions-sync-relative", _("align regions sync relative"), bind (mem_fun(*this, &Editor::align_relative), ARDOUR::SyncPoint));
|
||||
|
||||
register_action (editor_actions, "set-playhead", "set-playhead", mem_fun(*this, &Editor::kbd_set_playhead_cursor));
|
||||
register_action (editor_actions, "set-edit-cursor", "set-edit-cursor", mem_fun(*this, &Editor::kbd_set_edit_cursor));
|
||||
register_action (editor_actions, "set-playhead", _("set playhead"), mem_fun(*this, &Editor::kbd_set_playhead_cursor));
|
||||
register_action (editor_actions, "set-edit-cursor", _("set edit cursor"), mem_fun(*this, &Editor::kbd_set_edit_cursor));
|
||||
|
||||
register_action (editor_actions, "set-undo", "set-undo", bind (mem_fun(*this, &Editor::undo), 1U));
|
||||
register_action (editor_actions, "set-redo", "set-redo", bind (mem_fun(*this, &Editor::redo), 1U));
|
||||
register_action (editor_actions, "set-undo", _("set undo"), bind (mem_fun(*this, &Editor::undo), 1U));
|
||||
register_action (editor_actions, "set-redo", _("set redo"), bind (mem_fun(*this, &Editor::redo), 1U));
|
||||
|
||||
register_action (editor_actions, "export-session", "export-session", mem_fun(*this, &Editor::export_session));
|
||||
register_action (editor_actions, "export-range", "export-range", mem_fun(*this, &Editor::export_selection));
|
||||
register_action (editor_actions, "export-session", _("export session"), mem_fun(*this, &Editor::export_session));
|
||||
register_action (editor_actions, "export-range", _("export range"), mem_fun(*this, &Editor::export_selection));
|
||||
|
||||
register_action (editor_actions, "editor-cut", "editor-cut", mem_fun(*this, &Editor::cut));
|
||||
register_action (editor_actions, "editor-copy", "editor-copy", mem_fun(*this, &Editor::copy));
|
||||
register_action (editor_actions, "editor-paste", "editor-paste", mem_fun(*this, &Editor::keyboard_paste));
|
||||
register_action (editor_actions, "duplicate-region", "duplicate-region", mem_fun(*this, &Editor::keyboard_duplicate_region));
|
||||
register_action (editor_actions, "duplicate-range", "duplicate-range", mem_fun(*this, &Editor::keyboard_duplicate_selection));
|
||||
register_action (editor_actions, "insert-region", "insert-region", mem_fun(*this, &Editor::keyboard_insert_region_list_selection));
|
||||
register_action (editor_actions, "reverse-region", "reverse-region", mem_fun(*this, &Editor::reverse_region));
|
||||
register_action (editor_actions, "normalize-region", "normalize-region", mem_fun(*this, &Editor::normalize_region));
|
||||
register_action (editor_actions, "editor-crop", "editor-crop", mem_fun(*this, &Editor::crop_region_to_selection));
|
||||
register_action (editor_actions, "insert-chunk", "insert-chunk", bind (mem_fun(*this, &Editor::paste_named_selection), 1.0f));
|
||||
register_action (editor_actions, "editor-cut", _("editor cut"), mem_fun(*this, &Editor::cut));
|
||||
register_action (editor_actions, "editor-copy", _("editor copy"), mem_fun(*this, &Editor::copy));
|
||||
register_action (editor_actions, "editor-paste", _("editor paste"), mem_fun(*this, &Editor::keyboard_paste));
|
||||
register_action (editor_actions, "duplicate-region", _("duplicate region"), mem_fun(*this, &Editor::keyboard_duplicate_region));
|
||||
register_action (editor_actions, "duplicate-range", _("duplicate range"), mem_fun(*this, &Editor::keyboard_duplicate_selection));
|
||||
register_action (editor_actions, "insert-region", _("insert region"), mem_fun(*this, &Editor::keyboard_insert_region_list_selection));
|
||||
register_action (editor_actions, "reverse-region", _("reverse region"), mem_fun(*this, &Editor::reverse_region));
|
||||
register_action (editor_actions, "normalize-region", _("normalize region"), mem_fun(*this, &Editor::normalize_region));
|
||||
register_action (editor_actions, "editor-crop", _("editor crop"), mem_fun(*this, &Editor::crop_region_to_selection));
|
||||
register_action (editor_actions, "insert-chunk", _("insert chunk"), bind (mem_fun(*this, &Editor::paste_named_selection), 1.0f));
|
||||
|
||||
register_action (editor_actions, "split-at-edit-cursor", "split-at-edit-cursor", mem_fun(*this, &Editor::split_region));
|
||||
register_action (editor_actions, "split-at-mouse", "split-at-mouse", mem_fun(*this, &Editor::kbd_split));
|
||||
register_action (editor_actions, "split-at-edit-cursor", _("split at edit cursor"), mem_fun(*this, &Editor::split_region));
|
||||
register_action (editor_actions, "split-at-mouse", _("split at mouse"), mem_fun(*this, &Editor::kbd_split));
|
||||
|
||||
register_action (editor_actions, "brush-at-mouse", "brush-at-mouse", mem_fun(*this, &Editor::kbd_brush));
|
||||
register_action (editor_actions, "audition-at-mouse", "audition-at-mouse", mem_fun(*this, &Editor::kbd_audition));
|
||||
register_action (editor_actions, "brush-at-mouse", _("brush at mouse"), mem_fun(*this, &Editor::kbd_brush));
|
||||
register_action (editor_actions, "audition-at-mouse", _("audition at mouse"), mem_fun(*this, &Editor::kbd_audition));
|
||||
|
||||
register_action (editor_actions, "start-range", "start-range", mem_fun(*this, &Editor::keyboard_selection_begin));
|
||||
register_action (editor_actions, "finish-range", "finish-range", bind (mem_fun(*this, &Editor::keyboard_selection_finish), false));
|
||||
register_action (editor_actions, "finish-add-range", "finish-add-range", bind (mem_fun(*this, &Editor::keyboard_selection_finish), true));
|
||||
register_action (editor_actions, "start-range", _("start range"), mem_fun(*this, &Editor::keyboard_selection_begin));
|
||||
register_action (editor_actions, "finish-range", _("finish range"), bind (mem_fun(*this, &Editor::keyboard_selection_finish), false));
|
||||
register_action (editor_actions, "finish-add-range", _("finish add range"), bind (mem_fun(*this, &Editor::keyboard_selection_finish), true));
|
||||
|
||||
register_action (editor_actions, "extend-range-to-end-of-region", "extend-range-to-end-of-region", bind (mem_fun(*this, &Editor::extend_selection_to_end_of_region), false));
|
||||
register_action (editor_actions, "extend-range-to-start-of-region", "extend-range-to-start-of-region", bind (mem_fun(*this, &Editor::extend_selection_to_start_of_region), false));
|
||||
register_action (editor_actions, "extend-range-to-end-of-region", _("extend range to end of region"), bind (mem_fun(*this, &Editor::extend_selection_to_end_of_region), false));
|
||||
register_action (editor_actions, "extend-range-to-start-of-region", _("extend range to start of region"), bind (mem_fun(*this, &Editor::extend_selection_to_start_of_region), false));
|
||||
|
||||
register_action (editor_actions, "toggle-follow-playhead", "toggle-follow-playhead", (mem_fun(*this, &Editor::toggle_follow_playhead)));
|
||||
register_action (editor_actions, "remove-last-capture", "remove-last-capture", (mem_fun(*this, &Editor::remove_last_capture)));
|
||||
register_action (editor_actions, "toggle-follow-playhead", _("toggle follow playhead"), (mem_fun(*this, &Editor::toggle_follow_playhead)));
|
||||
register_action (editor_actions, "remove-last-capture", _("remove last capture"), (mem_fun(*this, &Editor::remove_last_capture)));
|
||||
|
||||
Glib::RefPtr<ActionGroup> zoom_actions = ActionGroup::create (X_("Zoom"));
|
||||
RadioAction::Group zoom_group;
|
||||
|
||||
register_radio_action (zoom_actions, zoom_group, "zoom-focus-left", "zoom-focus-left", bind (mem_fun(*this, &Editor::set_zoom_focus), Editing::ZoomFocusLeft));
|
||||
register_radio_action (zoom_actions, zoom_group, "zoom-focus-right", "zoom-focus-right", bind (mem_fun(*this, &Editor::set_zoom_focus), Editing::ZoomFocusRight));
|
||||
register_radio_action (zoom_actions, zoom_group, "zoom-focus-center", "zoom-focus-center", bind (mem_fun(*this, &Editor::set_zoom_focus), Editing::ZoomFocusCenter));
|
||||
register_radio_action (zoom_actions, zoom_group, "zoom-focus-playhead", "zoom-focus-playhead", bind (mem_fun(*this, &Editor::set_zoom_focus), Editing::ZoomFocusPlayhead));
|
||||
register_radio_action (zoom_actions, zoom_group, "zoom-focus-edit", "zoom-focus-edit", bind (mem_fun(*this, &Editor::set_zoom_focus), Editing::ZoomFocusEdit));
|
||||
register_radio_action (zoom_actions, zoom_group, "zoom-focus-left", _("zoom focus left"), bind (mem_fun(*this, &Editor::set_zoom_focus), Editing::ZoomFocusLeft));
|
||||
register_radio_action (zoom_actions, zoom_group, "zoom-focus-right", _("zoom focus right"), bind (mem_fun(*this, &Editor::set_zoom_focus), Editing::ZoomFocusRight));
|
||||
register_radio_action (zoom_actions, zoom_group, "zoom-focus-center", _("zoom focus center"), bind (mem_fun(*this, &Editor::set_zoom_focus), Editing::ZoomFocusCenter));
|
||||
register_radio_action (zoom_actions, zoom_group, "zoom-focus-playhead", _("zoom focus playhead"), bind (mem_fun(*this, &Editor::set_zoom_focus), Editing::ZoomFocusPlayhead));
|
||||
register_radio_action (zoom_actions, zoom_group, "zoom-focus-edit", _("zoom focus edit"), bind (mem_fun(*this, &Editor::set_zoom_focus), Editing::ZoomFocusEdit));
|
||||
|
||||
Glib::RefPtr<ActionGroup> mouse_mode_actions = ActionGroup::create (X_("MouseMode"));
|
||||
RadioAction::Group mouse_mode_group;
|
||||
|
||||
register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-object", "set-mouse-mode-object", bind (mem_fun(*this, &Editor::set_mouse_mode), Editing::MouseObject, false));
|
||||
register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-range", "set-mouse-mode-range", bind (mem_fun(*this, &Editor::set_mouse_mode), Editing::MouseRange, false));
|
||||
register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-gain", "set-mouse-mode-gain", bind (mem_fun(*this, &Editor::set_mouse_mode), Editing::MouseGain, false));
|
||||
register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-zoom", "set-mouse-mode-zoom", bind (mem_fun(*this, &Editor::set_mouse_mode), Editing::MouseZoom, false));
|
||||
register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-timefx", "set-mouse-mode-timefx", bind (mem_fun(*this, &Editor::set_mouse_mode), Editing::MouseTimeFX, false));
|
||||
register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-object", _("set mouse mode object"), bind (mem_fun(*this, &Editor::set_mouse_mode), Editing::MouseObject, false));
|
||||
register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-range", _("set mouse mode range"), bind (mem_fun(*this, &Editor::set_mouse_mode), Editing::MouseRange, false));
|
||||
register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-gain", _("set mouse mode gain"), bind (mem_fun(*this, &Editor::set_mouse_mode), Editing::MouseGain, false));
|
||||
register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-zoom", _("set mouse mode zoom"), bind (mem_fun(*this, &Editor::set_mouse_mode), Editing::MouseZoom, false));
|
||||
register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-timefx", _("set mouse mode timefx"), bind (mem_fun(*this, &Editor::set_mouse_mode), Editing::MouseTimeFX, false));
|
||||
|
||||
Glib::RefPtr<ActionGroup> snap_actions = ActionGroup::create (X_("Snap"));
|
||||
RadioAction::Group snap_choice_group;
|
||||
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-frame"), _("snap-to-frame"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToFrame)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-cd-frame"), _("snap-to-cd-frame"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToCDFrame)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-smpte-frame"), _("snap-to-smpte-frame"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToSMPTEFrame)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-smpte-seconds"), _("snap-to-smpte-seconds"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToSMPTESeconds)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-smpte-minutes"), _("snap-to-smpte-minutes"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToSMPTEMinutes)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-seconds"), _("snap-to-seconds"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToSeconds)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-minutes"), _("snap-to-minutes"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToMinutes)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-thirtyseconds"), _("snap-to-thirtyseconds"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToAThirtysecondBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-asixteenthbeat"), _("snap-to-asixteenthbeat"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToASixteenthBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-eighths"), _("snap-to-eighths"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToAEighthBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-quarters"), _("snap-to-quarters"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToAQuarterBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-thirds"), _("snap-to-thirds"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToAThirdBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-beat"), _("snap-to-beat"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-bar"), _("snap-to-bar"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToBar)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-mark"), _("snap-to-mark"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToMark)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-edit-cursor"), _("snap-to-edit-cursor"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToEditCursor)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-region-start"), _("snap-to-region-start"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToRegionStart)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-region-end"), _("snap-to-region-end"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToRegionEnd)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-region-sync"), _("snap-to-region-sync"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToRegionSync)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-region-boundary"), _("snap-to-region-boundary"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToRegionBoundary)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-frame"), _("snap to frame"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToFrame)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-cd-frame"), _("snap to cd frame"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToCDFrame)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-smpte-frame"), _("snap to smpte frame"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToSMPTEFrame)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-smpte-seconds"), _("snap to smpte seconds"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToSMPTESeconds)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-smpte-minutes"), _("snap to smpte minutes"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToSMPTEMinutes)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-seconds"), _("snap to seconds"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToSeconds)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-minutes"), _("snap to minutes"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToMinutes)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-thirtyseconds"), _("snap to thirtyseconds"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToAThirtysecondBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-asixteenthbeat"), _("snap to asixteenthbeat"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToASixteenthBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-eighths"), _("snap to eighths"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToAEighthBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-quarters"), _("snap to quarters"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToAQuarterBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-thirds"), _("snap to thirds"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToAThirdBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-beat"), _("snap to beat"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToBeat)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-bar"), _("snap to bar"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToBar)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-mark"), _("snap to mark"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToMark)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-edit-cursor"), _("snap to edit cursor"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToEditCursor)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-region-start"), _("snap to region start"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToRegionStart)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-region-end"), _("snap to region end"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToRegionEnd)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-region-sync"), _("snap to region sync"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToRegionSync)));
|
||||
register_radio_action (snap_actions, snap_choice_group, X_("snap-to-region-boundary"), _("snap to region boundary"), (bind (mem_fun(*this, &Editor::set_snap_to), Editing::SnapToRegionBoundary)));
|
||||
|
||||
/* REGION LIST */
|
||||
|
||||
|
|
@ -207,4 +208,8 @@ Editor::register_actions ()
|
|||
ui_manager->insert_action_group (mouse_mode_actions);
|
||||
ui_manager->insert_action_group (snap_actions);
|
||||
ui_manager->insert_action_group (editor_actions);
|
||||
|
||||
/* and tell the world about us */
|
||||
|
||||
register_ui_manager (ui_manager);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -70,8 +70,8 @@ Editor::hscroll_slider_expose (GdkEventExpose *ev)
|
|||
|
||||
gtk_paint_box (edit_hscroll_slider.get_style()->gobj(),
|
||||
edit_hscroll_slider.get_window()->gobj(),
|
||||
Gtk::STATE_ACTIVE,
|
||||
Gtk::SHADOW_IN,
|
||||
GTK_STATE_ACTIVE,
|
||||
GTK_SHADOW_IN,
|
||||
&ev->area,
|
||||
GTK_WIDGET(edit_hscroll_slider.gobj()),
|
||||
"trough",
|
||||
|
|
@ -79,8 +79,8 @@ Editor::hscroll_slider_expose (GdkEventExpose *ev)
|
|||
|
||||
gtk_paint_box (edit_hscroll_slider.get_style()->gobj(),
|
||||
edit_hscroll_slider.get_window()->gobj(),
|
||||
Gtk::STATE_NORMAL,
|
||||
Gtk::SHADOW_OUT,
|
||||
GTK_STATE_NORMAL,
|
||||
GTK_SHADOW_OUT,
|
||||
&draw_rect,
|
||||
GTK_WIDGET(edit_hscroll_slider.gobj()),
|
||||
"hscale",
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@
|
|||
#include "editing.h"
|
||||
#include "ardour_ui.h"
|
||||
#include "gui_thread.h"
|
||||
#include "actions.h"
|
||||
|
||||
#include "i18n.h"
|
||||
|
||||
|
|
@ -41,6 +42,7 @@ using namespace sigc;
|
|||
using namespace ARDOUR;
|
||||
using namespace Gtk;
|
||||
using namespace Editing;
|
||||
using namespace ActionManager;
|
||||
|
||||
#define wave_cursor_width 43
|
||||
#define wave_cursor_height 61
|
||||
|
|
@ -302,7 +304,7 @@ Editor::region_list_selection_changed()
|
|||
sensitive = false;
|
||||
}
|
||||
|
||||
for (vector<Glib::RefPtr<Gtk::Action> >::iterator i = region_list_selection_requiring_actions.begin(); i != region_list_selection_requiring_actions.end(); ++i) {
|
||||
for (vector<Glib::RefPtr<Gtk::Action> >::iterator i = region_list_selection_sensitive_actions.begin(); i != region_list_selection_sensitive_actions.end(); ++i) {
|
||||
(*i)->set_sensitive (sensitive);
|
||||
}
|
||||
|
||||
|
|
@ -361,12 +363,12 @@ Editor::build_region_list_menu ()
|
|||
|
||||
toggle_full_region_list_action = ui_manager->get_action ("<Actions>/RegionList/rlShowAll");
|
||||
|
||||
region_list_selection_requiring_actions.push_back (ui_manager->get_action ("<Actions>/RegionList/rlHide"));
|
||||
region_list_selection_requiring_actions.push_back (ui_manager->get_action ("<Actions>/RegionList/rlAudition"));
|
||||
region_list_selection_requiring_actions.push_back (ui_manager->get_action ("<Actions>/RegionList/rlRemove"));
|
||||
region_list_selection_sensitive_actions.push_back (ui_manager->get_action ("<Actions>/RegionList/rlHide"));
|
||||
region_list_selection_sensitive_actions.push_back (ui_manager->get_action ("<Actions>/RegionList/rlAudition"));
|
||||
region_list_selection_sensitive_actions.push_back (ui_manager->get_action ("<Actions>/RegionList/rlRemove"));
|
||||
|
||||
session_requiring_actions.push_back (ui_manager->get_action ("<Actions>/RegionList/rlEmbedAudio"));
|
||||
session_requiring_actions.push_back (ui_manager->get_action ("<Actions>/RegionList/rlImportAudio"));
|
||||
session_sensitive_actions.push_back (ui_manager->get_action ("<Actions>/RegionList/rlEmbedAudio"));
|
||||
session_sensitive_actions.push_back (ui_manager->get_action ("<Actions>/RegionList/rlImportAudio"));
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
|||
|
|
@ -27,7 +27,16 @@
|
|||
#include <sys/types.h>
|
||||
|
||||
#include <sigc++/signal.h>
|
||||
#include <gtkmm.h>
|
||||
#include <gtkmm/label.h>
|
||||
#include <gtkmm/entry.h>
|
||||
#include <gtkmm/box.h>
|
||||
#include <gtkmm/button.h>
|
||||
#include <gtkmm/radiobutton.h>
|
||||
#include <gtkmm/checkbutton.h>
|
||||
#include <gtkmm/treeview.h>
|
||||
#include <gtkmm/scrolledwindow.h>
|
||||
#include <gtkmm/fileselection.h>
|
||||
#include <gtkmm/notebook.h>
|
||||
#include <gtkmm2ext/selector.h>
|
||||
|
||||
#include <ardour/region.h>
|
||||
|
|
@ -87,8 +96,8 @@ class SoundFileBox : public Gtk::VBox
|
|||
Gtk::Button add_field_btn;
|
||||
Gtk::Button remove_field_btn;
|
||||
|
||||
static void _fields_refiller (Gtk::CList &list, void* arg);
|
||||
void fields_refiller (Gtk::CList &clist);
|
||||
static void _fields_refiller (Gtk::TreeView &list, void* arg);
|
||||
void fields_refiller (Gtk::TreeView);
|
||||
int setup_labels (string uri);
|
||||
void setup_fields ();
|
||||
|
||||
|
|
@ -98,9 +107,9 @@ class SoundFileBox : public Gtk::VBox
|
|||
void remove_field_clicked ();
|
||||
|
||||
void field_selected (Gtkmm2ext::Selector *selector,
|
||||
Gtkmm2ext::SelectionResult *re);
|
||||
Gtkmm2ext::Selector::Result *re);
|
||||
void field_chosen (Gtkmm2ext::Selector *selector,
|
||||
Gtkmm2ext::SelectionResult *re);
|
||||
Gtkmm2ext::Selector::Result *re);
|
||||
void audition_status_changed (bool state);
|
||||
};
|
||||
|
||||
|
|
@ -125,12 +134,12 @@ class SearchSounds : public ArdourDialog
|
|||
Gtk::HBox rbtn_box;
|
||||
Gtk::HBox bottom_box;
|
||||
|
||||
static void _fields_refiller (Gtk::CList &list, void* arg);
|
||||
void fields_refiller (Gtk::CList &clist);
|
||||
static void _fields_refiller (Gtk::TreeView&, void* arg);
|
||||
void fields_refiller (Gtk::TreeView&);
|
||||
void setup_fields ();
|
||||
|
||||
|
||||
void field_selected (Gtkmm2ext::Selector *selector,
|
||||
Gtkmm2ext::SelectionResult *re);
|
||||
Gtkmm2ext::Selector::Result *re);
|
||||
|
||||
void find_btn_clicked ();
|
||||
|
||||
|
|
@ -140,15 +149,15 @@ class SearchSounds : public ArdourDialog
|
|||
class SearchResults : public ArdourDialog
|
||||
{
|
||||
public:
|
||||
SearchResults (map<string,string> field_values, bool and_search);
|
||||
SearchResults (std::map<std::string,std::string> field_values, bool and_search);
|
||||
~SearchResults ();
|
||||
|
||||
sigc::signal<void, string, bool> file_chosen;
|
||||
sigc::signal<void, std::string, bool> file_chosen;
|
||||
|
||||
private:
|
||||
std::map<string,string> search_info;
|
||||
std::map<std::string,std::string> search_info;
|
||||
bool search_and;
|
||||
string selection;
|
||||
std::string selection;
|
||||
|
||||
Gtk::VBox main_box;
|
||||
Gtk::HBox hbox;
|
||||
|
|
@ -160,13 +169,13 @@ class SearchResults : public ArdourDialog
|
|||
SoundFileBox* info_box;
|
||||
|
||||
Gtkmm2ext::Selector results;
|
||||
static void _results_refiller (Gtk::CList &list, void* arg);
|
||||
void results_refiller (Gtk::CList &clist);
|
||||
static void _results_refiller (Gtk::TreeView &list, void* arg);
|
||||
void results_refiller (Gtk::TreeView&);
|
||||
|
||||
void import_clicked ();
|
||||
|
||||
void result_chosen (Gtkmm2ext::Selector *selector,
|
||||
Gtkmm2ext::SelectionResult *re);
|
||||
Gtkmm2ext::Selector::Result *re);
|
||||
};
|
||||
|
||||
class LibraryTree : public Gtk::VBox
|
||||
|
|
@ -175,21 +184,21 @@ class LibraryTree : public Gtk::VBox
|
|||
LibraryTree ();
|
||||
~LibraryTree ();
|
||||
|
||||
sigc::signal<void, string, bool> file_chosen;
|
||||
sigc::signal<void, std::string, bool> file_chosen;
|
||||
sigc::signal<void> group_selected;
|
||||
sigc::signal<void, string> member_selected;
|
||||
sigc::signal<void, std::string> member_selected;
|
||||
sigc::signal<void> member_deselected;
|
||||
sigc::signal<void> deselected;
|
||||
|
||||
list<string> selection;
|
||||
std::list<std::string> selection;
|
||||
void clear_selection ();
|
||||
|
||||
private:
|
||||
std::map<string, Gtk::TreeItem*> uri_mapping;
|
||||
std::map<string, string> uri_parent; // this ugly, but necessary
|
||||
std::map<std::string, Gtk::TreeViewColumn> uri_mapping;
|
||||
std::map<std::string, std::string> uri_parent; // this ugly, but necessary
|
||||
|
||||
string current_member;
|
||||
string current_group;
|
||||
std::string current_member;
|
||||
std::string current_group;
|
||||
|
||||
Gtk::HBox hbox;
|
||||
Gtk::VBox framed_box;
|
||||
|
|
@ -197,7 +206,7 @@ class LibraryTree : public Gtk::VBox
|
|||
Gtk::HBox btn_box_bottom;
|
||||
|
||||
Gtk::ScrolledWindow scroll;
|
||||
Gtk::Tree tree;
|
||||
Gtk::TreeView tree;
|
||||
|
||||
Gtk::Button add_btn;
|
||||
Gtk::Button remove_btn;
|
||||
|
|
@ -214,19 +223,19 @@ class LibraryTree : public Gtk::VBox
|
|||
void remove_btn_clicked ();
|
||||
void find_btn_clicked ();
|
||||
|
||||
void file_found (string uri, bool multi);
|
||||
void file_found (std::string uri, bool multi);
|
||||
|
||||
void cb_group_select (Gtk::TreeItem* item, string uri);
|
||||
void cb_member_select (Gtk::TreeItem* item, string uri);
|
||||
void cb_member_deselect (Gtk::TreeItem* item, string uri);
|
||||
void cb_group_select (Gtk::TreeViewColumn&, std::string uri);
|
||||
void cb_member_select (Gtk::TreeViewColumn&, std::string uri);
|
||||
void cb_member_deselect (Gtk::TreeViewColumn&, std::string uri);
|
||||
|
||||
void populate ();
|
||||
void subpopulate (Gtk::Tree*, string group);
|
||||
void subpopulate (Gtk::TreeView&, std::string group);
|
||||
|
||||
void added_group (string, string);
|
||||
void removed_group (string);
|
||||
void added_member (string, string);
|
||||
void removed_member (string);
|
||||
void added_group (std::string, std::string);
|
||||
void removed_group (std::string);
|
||||
void added_member (std::string, std::string);
|
||||
void removed_member (std::string);
|
||||
|
||||
void cancel_import_clicked ();
|
||||
};
|
||||
|
|
@ -237,7 +246,7 @@ class SoundFileBrowser : public Gtk::VBox {
|
|||
~SoundFileBrowser ();
|
||||
|
||||
sigc::signal<void> group_selected;
|
||||
sigc::signal<void, string> member_selected;
|
||||
sigc::signal<void, std::string> member_selected;
|
||||
sigc::signal<void> member_deselected;
|
||||
sigc::signal<void> deselected;
|
||||
|
||||
|
|
@ -245,16 +254,16 @@ class SoundFileBrowser : public Gtk::VBox {
|
|||
void clear_selection ();
|
||||
|
||||
private:
|
||||
string current_member;
|
||||
string current_group;
|
||||
std::string current_member;
|
||||
std::string current_group;
|
||||
Gtk::FileSelection fs_selector;
|
||||
Gtk::CList* file_list;
|
||||
Gtk::TreeView* file_list;
|
||||
|
||||
void dir_list_selected(gint row, gint col, GdkEvent* ev);
|
||||
void file_list_selected(gint row, gint col, GdkEvent* ev);
|
||||
void file_list_deselected(gint row, gint col, GdkEvent* ev);
|
||||
|
||||
string safety_check_file(string file);
|
||||
std::string safety_check_file(std::string file);
|
||||
};
|
||||
|
||||
class SoundFileSelector : public ArdourDialog {
|
||||
|
|
@ -268,11 +277,11 @@ class SoundFileSelector : public ArdourDialog {
|
|||
SoundFileSelector ();
|
||||
~SoundFileSelector ();
|
||||
|
||||
void run (string action, bool split_makes_sense, bool hide_after_action = false);
|
||||
void get_result (vector<string>& paths, bool& split);
|
||||
void run (std::string action, bool split_makes_sense, bool hide_after_action = false);
|
||||
void get_result (vector<std::string>& paths, bool& split);
|
||||
void hide_import_stuff();
|
||||
|
||||
sigc::signal<void,vector<string>,bool> Action;
|
||||
sigc::signal<void,vector<std::string>,bool> Action;
|
||||
|
||||
private:
|
||||
bool multiable;
|
||||
|
|
@ -282,7 +291,7 @@ class SoundFileSelector : public ArdourDialog {
|
|||
void import_btn_clicked ();
|
||||
void sfdb_group_selected();
|
||||
void browser_group_selected();
|
||||
void member_selected(string member, bool sfdb);
|
||||
void member_selected(std::string member, bool sfdb);
|
||||
void member_deselected(bool sfdb);
|
||||
void sfdb_deselected();
|
||||
void page_switched(Gtk::Notebook_Helpers::Page* page, guint page_num);
|
||||
|
|
|
|||
|
|
@ -77,16 +77,16 @@ LocationEditRow::LocationEditRow(Session * sess, Location * loc, int32_t num)
|
|||
preemph_check_button.set_name ("LocationEditCdButton");
|
||||
performer_label.set_name ("LocationEditNumberLabel");
|
||||
performer_entry.set_name ("LocationEditNameEntry");
|
||||
string_composer_label.set_name ("LocationEditNumberLabel");
|
||||
string_composer_entry.set_name ("LocationEditNameEntry");
|
||||
composer_label.set_name ("LocationEditNumberLabel");
|
||||
composer_entry.set_name ("LocationEditNameEntry");
|
||||
|
||||
|
||||
isrc_label.set_text ("ISRC: ");
|
||||
isrc_label.set_size_request (30, -1);
|
||||
performer_label.set_text ("Performer: ");
|
||||
performer_label.set_size_request (60, -1);
|
||||
string_composer_label.set_text ("Composer: ");
|
||||
string_composer_label.set_size_request (60, -1);
|
||||
composer_label.set_text ("Composer: ");
|
||||
composer_label.set_size_request (60, -1);
|
||||
|
||||
isrc_entry.set_size_request (112, -1);
|
||||
isrc_entry.set_max_length(12);
|
||||
|
|
@ -95,8 +95,8 @@ LocationEditRow::LocationEditRow(Session * sess, Location * loc, int32_t num)
|
|||
performer_entry.set_size_request (100, -1);
|
||||
performer_entry.set_editable (true);
|
||||
|
||||
string_composer_entry.set_size_request (100, -1);
|
||||
string_composer_entry.set_editable (true);
|
||||
composer_entry.set_size_request (100, -1);
|
||||
composer_entry.set_editable (true);
|
||||
|
||||
cd_track_details_hbox.pack_start (isrc_label, false, false);
|
||||
cd_track_details_hbox.pack_start (isrc_entry, false, false);
|
||||
|
|
@ -104,8 +104,8 @@ LocationEditRow::LocationEditRow(Session * sess, Location * loc, int32_t num)
|
|||
cd_track_details_hbox.pack_start (preemph_check_button, false, false);
|
||||
cd_track_details_hbox.pack_start (performer_label, false, false);
|
||||
cd_track_details_hbox.pack_start (performer_entry, true, true);
|
||||
cd_track_details_hbox.pack_start (string_composer_label, false, false);
|
||||
cd_track_details_hbox.pack_start (string_composer_entry, true, true);
|
||||
cd_track_details_hbox.pack_start (composer_label, false, false);
|
||||
cd_track_details_hbox.pack_start (composer_entry, true, true);
|
||||
|
||||
isrc_entry.signal_changed().connect (mem_fun(*this, &LocationEditRow::isrc_entry_changed));
|
||||
isrc_entry.signal_focus_in_event().connect (mem_fun(*this, &LocationEditRow::entry_focus_event));
|
||||
|
|
@ -115,9 +115,9 @@ LocationEditRow::LocationEditRow(Session * sess, Location * loc, int32_t num)
|
|||
performer_entry.signal_focus_in_event().connect (mem_fun(*this, &LocationEditRow::entry_focus_event));
|
||||
performer_entry.signal_focus_out_event().connect (mem_fun(*this, &LocationEditRow::entry_focus_event));
|
||||
|
||||
string_composer_entry.signal_changed().connect (mem_fun(*this, &LocationEditRow::composer_entry_changed));
|
||||
string_composer_entry.signal_focus_in_event().connect (mem_fun(*this, &LocationEditRow::entry_focus_event));
|
||||
string_composer_entry.signal_focus_out_event().connect (mem_fun(*this, &LocationEditRow::entry_focus_event));
|
||||
composer_entry.signal_changed().connect (mem_fun(*this, &LocationEditRow::composer_entry_changed));
|
||||
composer_entry.signal_focus_in_event().connect (mem_fun(*this, &LocationEditRow::entry_focus_event));
|
||||
composer_entry.signal_focus_out_event().connect (mem_fun(*this, &LocationEditRow::entry_focus_event));
|
||||
|
||||
scms_check_button.signal_toggled().connect(mem_fun(*this, &LocationEditRow::scms_toggled));
|
||||
preemph_check_button.signal_toggled().connect(mem_fun(*this, &LocationEditRow::preemph_toggled));
|
||||
|
|
@ -361,10 +361,10 @@ LocationEditRow::composer_entry_changed ()
|
|||
|
||||
if (i_am_the_modifier || !location) return;
|
||||
|
||||
if (string_composer_entry.get_text() != "") {
|
||||
location->cd_info["string_composer"] = string_composer_entry.get_text();
|
||||
if (composer_entry.get_text() != "") {
|
||||
location->cd_info["composer"] = composer_entry.get_text();
|
||||
} else {
|
||||
location->cd_info.erase("string_composer");
|
||||
location->cd_info.erase("composer");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -438,8 +438,8 @@ LocationEditRow::cd_toggled ()
|
|||
if (location->cd_info.find("performer") != location->cd_info.end()) {
|
||||
performer_entry.set_text(location->cd_info["performer"]);
|
||||
}
|
||||
if (location->cd_info.find("string_composer") != location->cd_info.end()) {
|
||||
string_composer_entry.set_text(location->cd_info["string_composer"]);
|
||||
if (location->cd_info.find("composer") != location->cd_info.end()) {
|
||||
composer_entry.set_text(location->cd_info["composer"]);
|
||||
}
|
||||
if (location->cd_info.find("scms") != location->cd_info.end()) {
|
||||
scms_check_button.set_active(true);
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
#include <gtkmm/box.h>
|
||||
#include <gtkmm/label.h>
|
||||
#include <gtkmm/adjustment.h>
|
||||
#include <gtkmm/hscale.h>
|
||||
#include <gtkmm/scale.h>
|
||||
#include <gtkmm/spinbutton.h>
|
||||
#include <gtkmm/radiobutton.h>
|
||||
#include <gtkmm/comboboxtext.h>
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
namespace ARDOUR {
|
||||
class Session;
|
||||
class AudioExportSpecification;
|
||||
class AudioRegion;
|
||||
class Region;
|
||||
class Playlist;
|
||||
class RouteGroup;
|
||||
}
|
||||
|
|
@ -59,7 +59,7 @@ class PublicEditor : public Gtk::Window, public Stateful, public KeyboardTarget
|
|||
virtual void connect_to_image_compositor() = 0;
|
||||
virtual void scroll_timeaxis_to_imageframe_item(const TimeAxisViewItem* item) = 0;
|
||||
virtual TimeAxisView* get_named_time_axis(std::string name) = 0;
|
||||
virtual bool consider_auditioning (ARDOUR::AudioRegion*) = 0;
|
||||
virtual void consider_auditioning (ARDOUR::Region&) = 0;
|
||||
virtual void set_show_waveforms (bool yn) = 0;
|
||||
virtual bool show_waveforms() const = 0;
|
||||
virtual void set_show_waveforms_recording (bool yn) = 0;
|
||||
|
|
|
|||
|
|
@ -37,8 +37,7 @@
|
|||
#include <ardour/diskstream.h>
|
||||
|
||||
#include "i18n.h"
|
||||
/* there is a string_compose() here.. */
|
||||
//using namespace sigc;
|
||||
using namespace sigc;
|
||||
using namespace Gtk;
|
||||
using namespace Gtkmm2ext;
|
||||
using namespace ARDOUR;
|
||||
|
|
@ -566,14 +565,14 @@ RouteUI::choose_color()
|
|||
{
|
||||
bool picked;
|
||||
Gdk::Color color;
|
||||
gdouble current[4];
|
||||
Gdk::Color current;
|
||||
|
||||
current[0] = _color.get_red() / 65535.0;
|
||||
current[1] = _color.get_green() / 65535.0;
|
||||
current[2] = _color.get_blue() / 65535.0;
|
||||
current[3] = 1.0;
|
||||
current.set_red ( _color.get_red() / 65535.0);
|
||||
current.set_green (_color.get_green() / 65535.0);
|
||||
current.set_blue (_color.get_blue() / 65535.0);
|
||||
//current[3] = 1.0;
|
||||
|
||||
color = Gtkmm2ext::UI::instance()->get_color (_("ardour: color selection"), picked, current);
|
||||
color = Gtkmm2ext::UI::instance()->get_color (_("ardour: color selection"), picked, ¤t);
|
||||
|
||||
if (picked) {
|
||||
set_color (color);
|
||||
|
|
@ -665,7 +664,7 @@ RouteUI::remove_this_route ()
|
|||
Gtk::Main::run ();
|
||||
|
||||
if (prompter.get_choice() == 0) {
|
||||
Glib::signal_idle().connect (bind (mem_fun (&RouteUI::idle_remove_this_route), this));
|
||||
Glib::signal_idle().connect (bind (sigc::ptr_fun (&RouteUI::idle_remove_this_route), this));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -607,7 +607,7 @@ TimeAxisViewItem::get_name_text()
|
|||
* @param color the base color of the item
|
||||
*/
|
||||
void
|
||||
TimeAxisViewItem::compute_colors(GdkColor& base_color)
|
||||
TimeAxisViewItem::compute_colors(Gdk::Color& base_color)
|
||||
{
|
||||
unsigned char radius ;
|
||||
char minor_shift ;
|
||||
|
|
@ -615,9 +615,9 @@ TimeAxisViewItem::compute_colors(GdkColor& base_color)
|
|||
unsigned char r,g,b ;
|
||||
|
||||
/* FILL: this is simple */
|
||||
r = base_color.red/256 ;
|
||||
g = base_color.green/256 ;
|
||||
b = base_color.blue/256 ;
|
||||
r = base_color.get_red()/256 ;
|
||||
g = base_color.get_green()/256 ;
|
||||
b = base_color.get_blue()/256 ;
|
||||
fill_color = RGBA_TO_UINT(r,g,b,255) ;
|
||||
|
||||
/* for minor colors:
|
||||
|
|
@ -633,9 +633,9 @@ TimeAxisViewItem::compute_colors(GdkColor& base_color)
|
|||
|
||||
/* LABEL: rotate around color wheel by 120 degrees anti-clockwise */
|
||||
|
||||
r = base_color.red/256;
|
||||
g = base_color.green/256;
|
||||
b = base_color.blue/256;
|
||||
r = base_color.get_red()/256;
|
||||
g = base_color.get_green()/256;
|
||||
b = base_color.get_blue()/256;
|
||||
|
||||
if (r > b)
|
||||
{
|
||||
|
|
@ -669,9 +669,9 @@ TimeAxisViewItem::compute_colors(GdkColor& base_color)
|
|||
g += minor_shift;
|
||||
|
||||
label_color = RGBA_TO_UINT(r,g,b,255);
|
||||
r = (base_color.red/256) + 127 ;
|
||||
g = (base_color.green/256) + 127 ;
|
||||
b = (base_color.blue/256) + 127 ;
|
||||
r = (base_color.get_red()/256) + 127 ;
|
||||
g = (base_color.get_green()/256) + 127 ;
|
||||
b = (base_color.get_blue()/256) + 127 ;
|
||||
|
||||
label_color = RGBA_TO_UINT(r,g,b,255);
|
||||
|
||||
|
|
|
|||
|
|
@ -25,10 +25,6 @@
|
|||
#include <gtkmm/combo.h>
|
||||
#include <gtkmm/label.h>
|
||||
#include <gtkmm/paned.h>
|
||||
#include <gtkmm/action.h>
|
||||
#include <gtkmm/actiongroup.h>
|
||||
#include <gtkmm/accelgroup.h>
|
||||
#include <gtkmm/accelmap.h>
|
||||
#include <gtk/gtkpaned.h>
|
||||
|
||||
#include <gtkmm2ext/utils.h>
|
||||
|
|
@ -517,74 +513,3 @@ decorate (Gtk::Window& w, Gdk::WMDecoration d)
|
|||
{
|
||||
w.get_window()->set_decorations (d);
|
||||
}
|
||||
|
||||
Glib::RefPtr<Action>
|
||||
register_action (Glib::RefPtr<ActionGroup> group, string name, string label, slot<void> sl, guint key, Gdk::ModifierType mods)
|
||||
{
|
||||
Glib::RefPtr<Action> act = register_action (group, name, label, sl);
|
||||
AccelMap::add_entry (act->get_accel_path(), key, mods);
|
||||
|
||||
return act;
|
||||
}
|
||||
|
||||
Glib::RefPtr<Action>
|
||||
register_action (Glib::RefPtr<ActionGroup> group, string name, string label, slot<void> sl)
|
||||
{
|
||||
Glib::RefPtr<Action> act = register_action (group, name, label);
|
||||
group->add (act, sl);
|
||||
|
||||
return act;
|
||||
}
|
||||
|
||||
|
||||
Glib::RefPtr<Action>
|
||||
register_radio_action (Glib::RefPtr<ActionGroup> group, RadioAction::Group rgroup, string name, string label, slot<void> sl, guint key, Gdk::ModifierType mods)
|
||||
{
|
||||
Glib::RefPtr<Action> act = register_radio_action (group, rgroup, name, label, sl);
|
||||
AccelMap::add_entry (act->get_accel_path(), key, mods);
|
||||
|
||||
return act;
|
||||
}
|
||||
|
||||
Glib::RefPtr<Action>
|
||||
register_radio_action (Glib::RefPtr<ActionGroup> group, RadioAction::Group rgroup, string name, string label, slot<void> sl)
|
||||
{
|
||||
Glib::RefPtr<Action> act;
|
||||
|
||||
act = RadioAction::create (rgroup, name, label);
|
||||
group->add (act, sl);
|
||||
|
||||
return act;
|
||||
}
|
||||
|
||||
|
||||
Glib::RefPtr<Action>
|
||||
register_toggle_action (Glib::RefPtr<ActionGroup> group, string name, string label, slot<void> sl, guint key, Gdk::ModifierType mods)
|
||||
{
|
||||
Glib::RefPtr<Action> act = register_toggle_action (group,name, label, sl);
|
||||
AccelMap::add_entry (act->get_accel_path(), key, mods);
|
||||
|
||||
return act;
|
||||
}
|
||||
|
||||
Glib::RefPtr<Action>
|
||||
register_toggle_action (Glib::RefPtr<ActionGroup> group, string name, string label, slot<void> sl)
|
||||
{
|
||||
Glib::RefPtr<Action> act;
|
||||
|
||||
act = ToggleAction::create (name, label);
|
||||
group->add (act, sl);
|
||||
|
||||
return act;
|
||||
}
|
||||
|
||||
Glib::RefPtr<Action>
|
||||
register_action (Glib::RefPtr<ActionGroup> group, string name, string label)
|
||||
{
|
||||
Glib::RefPtr<Action> act;
|
||||
|
||||
act = Action::create (name, label);
|
||||
group->add (act);
|
||||
|
||||
return act;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,10 +26,6 @@
|
|||
#include <cmath>
|
||||
#include <ardour/types.h>
|
||||
#include <libgnomecanvasmm/line.h>
|
||||
#include <gtkmm/action.h>
|
||||
#include <gtkmm/radioaction.h>
|
||||
#include <gtkmm/toggleaction.h>
|
||||
#include <gtkmm/actiongroup.h>
|
||||
#include <gdkmm/types.h>
|
||||
|
||||
namespace Gtk {
|
||||
|
|
@ -75,24 +71,6 @@ Pango::FontDescription get_font_for_style (std::string widgetname);
|
|||
gint pane_handler (GdkEventButton*, Gtk::Paned*);
|
||||
uint32_t rgba_from_style (std::string style, uint32_t, uint32_t, uint32_t, uint32_t);
|
||||
|
||||
Glib::RefPtr<Gtk::Action> register_action (Glib::RefPtr<Gtk::ActionGroup> group,
|
||||
std::string name, std::string label);
|
||||
Glib::RefPtr<Gtk::Action> register_action (Glib::RefPtr<Gtk::ActionGroup> group,
|
||||
std::string name, std::string label, sigc::slot<void> sl,
|
||||
guint key, Gdk::ModifierType mods);
|
||||
Glib::RefPtr<Gtk::Action> register_action (Glib::RefPtr<Gtk::ActionGroup> group,
|
||||
std::string name, std::string label, sigc::slot<void> sl);
|
||||
|
||||
Glib::RefPtr<Gtk::Action> register_radio_action (Glib::RefPtr<Gtk::ActionGroup> group, Gtk::RadioAction::Group,
|
||||
std::string name, std::string label, sigc::slot<void> sl,
|
||||
guint key, Gdk::ModifierType mods);
|
||||
Glib::RefPtr<Gtk::Action> register_radio_action (Glib::RefPtr<Gtk::ActionGroup> group, Gtk::RadioAction::Group,
|
||||
std::string name, std::string label, sigc::slot<void> sl);
|
||||
|
||||
Glib::RefPtr<Gtk::Action> register_toggle_action (Glib::RefPtr<Gtk::ActionGroup> group,
|
||||
std::string name, std::string label, sigc::slot<void> sl,
|
||||
guint key, Gdk::ModifierType mods);
|
||||
Glib::RefPtr<Gtk::Action> register_toggle_action (Glib::RefPtr<Gtk::ActionGroup> group,
|
||||
std::string name, std::string label, sigc::slot<void> sl);
|
||||
void decorate (Gtk::Window& w, Gdk::WMDecoration d);
|
||||
|
||||
#endif /* __ardour_gtk_utils_h__ */
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
Copyright (C) 1999-2002 Paul Barton-Davis
|
||||
Copyright (C) 1999-2005 Paul Barton-Davis
|
||||
|
||||
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
|
||||
|
|
|
|||
|
|
@ -26,7 +26,11 @@
|
|||
#include <map>
|
||||
|
||||
#include <pthread.h>
|
||||
#include <gtkmm.h>
|
||||
#include <gtkmm/widget.h>
|
||||
#include <gtkmm/style.h>
|
||||
#include <gtkmm/main.h>
|
||||
#include <gtkmm/tooltips.h>
|
||||
#include <gdkmm/color.h>
|
||||
#include <pbd/abstract_ui.h>
|
||||
#include <pbd/ringbufferNPT.h>
|
||||
#include <pbd/atomic.h>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue