summaryrefslogtreecommitdiff
path: root/gtk2_ardour
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2015-10-05 16:17:49 +0200
committerRobin Gareus <robin@gareus.org>2015-10-05 16:17:49 +0200
commit22b07e0233a29d9633ffa825a79503befaf2e16e (patch)
tree1d8b06056f8e12197158f5d906319767d3dedda5 /gtk2_ardour
parente11ba7b79d68bc1070b170236c22123966d7bcc3 (diff)
NOOP, remove trailing tabs/whitespace.
Diffstat (limited to 'gtk2_ardour')
-rw-r--r--gtk2_ardour/add_route_dialog.cc4
-rw-r--r--gtk2_ardour/add_route_dialog.h2
-rw-r--r--gtk2_ardour/ardour_button.cc2
-rw-r--r--gtk2_ardour/ardour_button.h2
-rw-r--r--gtk2_ardour/ardour_display.cc6
-rw-r--r--gtk2_ardour/ardour_dropdown.cc2
-rw-r--r--gtk2_ardour/ardour_knob.cc46
-rw-r--r--gtk2_ardour/ardour_knob.h2
-rw-r--r--gtk2_ardour/ardour_ui.cc4
-rw-r--r--gtk2_ardour/ardour_ui.h12
-rw-r--r--gtk2_ardour/ardour_ui2.cc4
-rw-r--r--gtk2_ardour/ardour_ui_dialogs.cc4
-rw-r--r--gtk2_ardour/ardour_ui_ed.cc2
-rw-r--r--gtk2_ardour/ardour_window.cc2
-rw-r--r--gtk2_ardour/audio_clock.cc16
-rw-r--r--gtk2_ardour/audio_clock.h4
-rw-r--r--gtk2_ardour/audio_region_view.cc42
-rw-r--r--gtk2_ardour/audio_region_view.h2
-rw-r--r--gtk2_ardour/audio_streamview.cc2
-rw-r--r--gtk2_ardour/audio_time_axis.cc6
-rw-r--r--gtk2_ardour/automation_line.cc36
-rw-r--r--gtk2_ardour/automation_line.h2
-rw-r--r--gtk2_ardour/automation_time_axis.cc18
-rw-r--r--gtk2_ardour/axis_view.h6
-rw-r--r--gtk2_ardour/big_clock_window.h4
-rw-r--r--gtk2_ardour/bundle_env_cocoa.cc4
-rw-r--r--gtk2_ardour/bundle_env_msvc.cc10
-rw-r--r--gtk2_ardour/button_joiner.cc22
-rw-r--r--gtk2_ardour/button_joiner.h2
-rw-r--r--gtk2_ardour/canvas-waveview.c4
-rw-r--r--gtk2_ardour/control_point.cc2
-rw-r--r--gtk2_ardour/control_point.h2
-rw-r--r--gtk2_ardour/edit_note_dialog.cc6
-rw-r--r--gtk2_ardour/editor.cc88
-rw-r--r--gtk2_ardour/editor.h12
-rw-r--r--gtk2_ardour/editor_actions.cc22
-rw-r--r--gtk2_ardour/editor_canvas.cc62
-rw-r--r--gtk2_ardour/editor_canvas_events.cc32
-rw-r--r--gtk2_ardour/editor_cursors.cc4
-rw-r--r--gtk2_ardour/editor_cursors.h2
-rw-r--r--gtk2_ardour/editor_drag.cc2
-rw-r--r--gtk2_ardour/editor_drag.h12
-rw-r--r--gtk2_ardour/editor_export_audio.cc14
-rw-r--r--gtk2_ardour/editor_group_tabs.cc2
-rw-r--r--gtk2_ardour/editor_keys.cc12
-rw-r--r--gtk2_ardour/editor_markers.cc16
-rw-r--r--gtk2_ardour/editor_mixer.cc4
-rw-r--r--gtk2_ardour/editor_mouse.cc28
-rw-r--r--gtk2_ardour/editor_ops.cc248
-rw-r--r--gtk2_ardour/editor_regions.cc6
-rw-r--r--gtk2_ardour/editor_route_groups.cc16
-rw-r--r--gtk2_ardour/editor_routes.cc12
-rw-r--r--gtk2_ardour/editor_rulers.cc10
-rw-r--r--gtk2_ardour/editor_selection.cc16
-rw-r--r--gtk2_ardour/editor_summary.cc20
-rw-r--r--gtk2_ardour/editor_tempodisplay.cc4
-rw-r--r--gtk2_ardour/editor_timefx.cc2
-rw-r--r--gtk2_ardour/engine_dialog.cc8
-rw-r--r--gtk2_ardour/export_dialog.cc4
-rw-r--r--gtk2_ardour/export_file_notebook.cc2
-rw-r--r--gtk2_ardour/export_filename_selector.cc4
-rw-r--r--gtk2_ardour/export_format_dialog.h2
-rw-r--r--gtk2_ardour/export_timespan_selector.cc2
-rw-r--r--gtk2_ardour/floating_text_entry.cc2
-rw-r--r--gtk2_ardour/gain_meter.cc6
-rw-r--r--gtk2_ardour/generic_pluginui.cc32
-rw-r--r--gtk2_ardour/ghostregion.h2
-rw-r--r--gtk2_ardour/group_tabs.cc36
-rw-r--r--gtk2_ardour/group_tabs.h2
-rw-r--r--gtk2_ardour/gui_object.cc2
-rw-r--r--gtk2_ardour/gui_object.h2
-rw-r--r--gtk2_ardour/io_selector.cc2
-rw-r--r--gtk2_ardour/keyeditor.cc4
-rw-r--r--gtk2_ardour/linux_vst_gui_support.cc264
-rw-r--r--gtk2_ardour/location_ui.cc6
-rw-r--r--gtk2_ardour/lxvst_plugin_ui.cc38
-rw-r--r--gtk2_ardour/lxvst_plugin_ui.h2
-rw-r--r--gtk2_ardour/main.cc2
-rw-r--r--gtk2_ardour/main_clock.h2
-rw-r--r--gtk2_ardour/marker.cc12
-rw-r--r--gtk2_ardour/meter_strip.h2
-rw-r--r--gtk2_ardour/midi_channel_selector.cc34
-rw-r--r--gtk2_ardour/midi_export_dialog.cc2
-rw-r--r--gtk2_ardour/midi_list_editor.cc54
-rw-r--r--gtk2_ardour/midi_region_view.cc56
-rw-r--r--gtk2_ardour/midi_region_view.h8
-rw-r--r--gtk2_ardour/midi_streamview.cc6
-rw-r--r--gtk2_ardour/midi_time_axis.cc20
-rw-r--r--gtk2_ardour/midi_tracer.cc4
-rw-r--r--gtk2_ardour/midi_tracer.h2
-rw-r--r--gtk2_ardour/midi_velocity_dialog.cc2
-rw-r--r--gtk2_ardour/mixer_actor.cc2
-rw-r--r--gtk2_ardour/mixer_group_tabs.cc6
-rw-r--r--gtk2_ardour/mixer_strip.cc58
-rw-r--r--gtk2_ardour/mixer_ui.cc110
-rw-r--r--gtk2_ardour/monitor_selector.cc2
-rw-r--r--gtk2_ardour/mono_panner.cc2
-rw-r--r--gtk2_ardour/mono_panner.h2
-rw-r--r--gtk2_ardour/mono_panner_editor.cc8
-rw-r--r--gtk2_ardour/mono_panner_editor.h2
-rw-r--r--gtk2_ardour/mouse_cursors.cc2
-rw-r--r--gtk2_ardour/mouse_cursors.h2
-rw-r--r--gtk2_ardour/msvc/winmain.cc2
-rw-r--r--gtk2_ardour/option_editor.cc10
-rw-r--r--gtk2_ardour/option_editor.h8
-rw-r--r--gtk2_ardour/panner_interface.h4
-rw-r--r--gtk2_ardour/patch_change.cc16
-rw-r--r--gtk2_ardour/patch_change_dialog.cc12
-rw-r--r--gtk2_ardour/piano_roll_header.cc12
-rw-r--r--gtk2_ardour/pingback.cc4
-rw-r--r--gtk2_ardour/playlist_selector.cc2
-rw-r--r--gtk2_ardour/plugin_eq_gui.cc2
-rw-r--r--gtk2_ardour/plugin_selector.cc4
-rw-r--r--gtk2_ardour/plugin_ui.cc6
-rw-r--r--gtk2_ardour/plugin_ui.h2
-rw-r--r--gtk2_ardour/port_matrix.cc20
-rw-r--r--gtk2_ardour/port_matrix_column_labels.cc4
-rw-r--r--gtk2_ardour/port_matrix_grid.cc4
-rw-r--r--gtk2_ardour/port_matrix_row_labels.cc4
-rw-r--r--gtk2_ardour/processor_box.cc52
-rw-r--r--gtk2_ardour/processor_box.h6
-rw-r--r--gtk2_ardour/public_editor.h4
-rw-r--r--gtk2_ardour/rc_option_editor.cc24
-rw-r--r--gtk2_ardour/rc_option_editor.h2
-rw-r--r--gtk2_ardour/region_layering_order_editor.cc10
-rw-r--r--gtk2_ardour/region_view.cc8
-rw-r--r--gtk2_ardour/route_group_dialog.cc8
-rw-r--r--gtk2_ardour/route_processor_selection.cc4
-rw-r--r--gtk2_ardour/route_sorter.h2
-rw-r--r--gtk2_ardour/route_time_axis.cc62
-rw-r--r--gtk2_ardour/route_ui.cc64
-rw-r--r--gtk2_ardour/route_ui.h2
-rw-r--r--gtk2_ardour/save_as_dialog.cc10
-rw-r--r--gtk2_ardour/save_as_dialog.h4
-rw-r--r--gtk2_ardour/session_dialog.cc60
-rw-r--r--gtk2_ardour/session_option_editor.cc2
-rw-r--r--gtk2_ardour/sfdb_freesound_mootcher.cc24
-rw-r--r--gtk2_ardour/sfdb_ui.cc76
-rw-r--r--gtk2_ardour/sfdb_ui.h4
-rw-r--r--gtk2_ardour/shuttle_control.cc4
-rw-r--r--gtk2_ardour/soundcloud_export_selector.h2
-rw-r--r--gtk2_ardour/splash.cc8
-rw-r--r--gtk2_ardour/startup.cc14
-rw-r--r--gtk2_ardour/stereo_panner.cc22
-rw-r--r--gtk2_ardour/stereo_panner.h2
-rw-r--r--gtk2_ardour/stereo_panner_editor.cc10
-rw-r--r--gtk2_ardour/stereo_panner_editor.h2
-rw-r--r--gtk2_ardour/streamview.cc10
-rw-r--r--gtk2_ardour/streamview.h2
-rw-r--r--gtk2_ardour/sys_ex.cc2
-rw-r--r--gtk2_ardour/sys_ex.h2
-rw-r--r--gtk2_ardour/tempo_dialog.cc8
-rw-r--r--gtk2_ardour/theme_manager.cc60
-rw-r--r--gtk2_ardour/theme_manager.h22
-rw-r--r--gtk2_ardour/time_axis_view.cc54
-rw-r--r--gtk2_ardour/time_axis_view_item.cc32
-rw-r--r--gtk2_ardour/time_fx_dialog.cc2
-rw-r--r--gtk2_ardour/time_fx_dialog.h2
-rw-r--r--gtk2_ardour/time_info_box.cc12
-rw-r--r--gtk2_ardour/ui_config.cc34
-rw-r--r--gtk2_ardour/ui_config.h8
-rw-r--r--gtk2_ardour/utils.cc14
-rw-r--r--gtk2_ardour/verbose_cursor.h2
-rw-r--r--gtk2_ardour/visibility_group.cc10
-rw-r--r--gtk2_ardour/visibility_group.h6
-rw-r--r--gtk2_ardour/volume_controller.cc4
-rw-r--r--gtk2_ardour/vst_plugin_ui.cc2
-rw-r--r--gtk2_ardour/vst_plugin_ui.h4
-rw-r--r--gtk2_ardour/window_manager.cc10
-rw-r--r--gtk2_ardour/window_manager.h16
-rw-r--r--gtk2_ardour/windows_vst_plugin_ui.cc8
-rw-r--r--gtk2_ardour/windows_vst_plugin_ui.h4
172 files changed, 1346 insertions, 1346 deletions
diff --git a/gtk2_ardour/add_route_dialog.cc b/gtk2_ardour/add_route_dialog.cc
index 2e58c646ea..0a14647002 100644
--- a/gtk2_ardour/add_route_dialog.cc
+++ b/gtk2_ardour/add_route_dialog.cc
@@ -323,7 +323,7 @@ void
AddRouteDialog::refill_track_modes ()
{
vector<string> s;
-
+
s.push_back (_("Normal"));
if (!ARDOUR::Profile->get_sae ()) {
@@ -392,7 +392,7 @@ AddRouteDialog::channels ()
ret.set (DataType::MIDI, 1);
break;
}
-
+
return ret;
}
diff --git a/gtk2_ardour/add_route_dialog.h b/gtk2_ardour/add_route_dialog.h
index d0fbeae3d4..eb38338f1f 100644
--- a/gtk2_ardour/add_route_dialog.h
+++ b/gtk2_ardour/add_route_dialog.h
@@ -64,7 +64,7 @@ class AddRouteDialog : public ArdourDialog
bool name_template_is_default () const;
std::string track_template ();
ARDOUR::PluginInfoPtr requested_instrument ();
-
+
ARDOUR::TrackMode mode();
ARDOUR::RouteGroup* route_group ();
enum InsertAt {
diff --git a/gtk2_ardour/ardour_button.cc b/gtk2_ardour/ardour_button.cc
index b2c2c83d70..7eaa960980 100644
--- a/gtk2_ardour/ardour_button.cc
+++ b/gtk2_ardour/ardour_button.cc
@@ -627,7 +627,7 @@ ArdourButton::set_colors ()
/* The inactive color for the LED is just a fairly dark version of the
* active color.
*/
-
+
ArdourCanvas::HSV inactive (led_active_color);
inactive.v = 0.35;
diff --git a/gtk2_ardour/ardour_button.h b/gtk2_ardour/ardour_button.h
index 9df1089246..27b4078950 100644
--- a/gtk2_ardour/ardour_button.h
+++ b/gtk2_ardour/ardour_button.h
@@ -89,7 +89,7 @@ class ArdourButton : public CairoWidget , public Gtkmm2ext::Activatable
void set_layout_ellipsize_width (int w);
void set_layout_font (const Pango::FontDescription&);
void set_text_ellipsize (Pango::EllipsizeMode);
-
+
sigc::signal<void> signal_led_clicked;
sigc::signal<void> signal_clicked;
diff --git a/gtk2_ardour/ardour_display.cc b/gtk2_ardour/ardour_display.cc
index 4cfffbcbd4..17f3dc5dde 100644
--- a/gtk2_ardour/ardour_display.cc
+++ b/gtk2_ardour/ardour_display.cc
@@ -63,7 +63,7 @@ ArdourDisplay::~ArdourDisplay ()
bool
ArdourDisplay::on_button_press_event (GdkEventButton*)
{
- _menu.popup (1, gtk_get_current_event_time());
+ _menu.popup (1, gtk_get_current_event_time());
return true;
}
@@ -84,12 +84,12 @@ ArdourDisplay::on_scroll_event (GdkEventScroll* ev)
boost::shared_ptr<PBD::Controllable> c = binding_proxy.get_controllable();
if (c) {
float val = c->get_interface();
-
+
if ( ev->direction == GDK_SCROLL_UP )
val += 0.05 * scale; //by default, we step in 1/20ths of the knob travel
else
val -= 0.05 * scale;
-
+
c->set_interface(val);
}
diff --git a/gtk2_ardour/ardour_dropdown.cc b/gtk2_ardour/ardour_dropdown.cc
index 221fe672d9..78100aa952 100644
--- a/gtk2_ardour/ardour_dropdown.cc
+++ b/gtk2_ardour/ardour_dropdown.cc
@@ -138,7 +138,7 @@ ArdourDropdown::AddMenuElem (Menu_Helpers::Element e)
using namespace Menu_Helpers;
MenuList& items = _menu.items ();
-
+
items.push_back (e);
}
diff --git a/gtk2_ardour/ardour_knob.cc b/gtk2_ardour/ardour_knob.cc
index 99890ad2e7..f7e4a939f2 100644
--- a/gtk2_ardour/ardour_knob.cc
+++ b/gtk2_ardour/ardour_knob.cc
@@ -80,13 +80,13 @@ void
ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
{
cairo_pattern_t* shade_pattern;
-
+
float width = get_width();
float height = get_height();
-
+
const float scale = min(width, height);
const float pointer_thickness = 3.0 * (scale/80); //(if the knob is 80 pixels wide, we want a 3-pix line on it)
-
+
const float start_angle = ((180 - 65) * G_PI) / 180;
const float end_angle = ((360 + 65) * G_PI) / 180;
@@ -97,13 +97,13 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
const float value_angle = start_angle + (_val * (end_angle - start_angle));
const float zero_angle = start_angle + (zero * (end_angle - start_angle));
-
+
float value_x = cos (value_angle);
float value_y = sin (value_angle);
float xc = 0.5 + width/ 2.0;
float yc = 0.5 + height/ 2.0;
-
+
cairo_translate (cr, xc, yc); //after this, everything is based on the center of the knob
//get the knob color from the theme
@@ -111,11 +111,11 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
float center_radius = 0.48*scale;
float border_width = 0.8;
-
+
bool arc = (_elements & Arc)==Arc;
bool bevel = (_elements & Bevel)==Bevel;
bool flat = _flat_buttons;
-
+
if ( arc ) {
center_radius = scale*0.33;
@@ -123,7 +123,7 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
float outer_progress_radius = scale*0.48;
float progress_width = (outer_progress_radius-inner_progress_radius);
float progress_radius = inner_progress_radius + progress_width/2.0;
-
+
//dark arc background
cairo_set_source_rgb (cr, 0.3, 0.3, 0.3 );
cairo_set_line_width (cr, progress_width);
@@ -185,7 +185,7 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
cairo_stroke (cr);
#endif
}
-
+
if (!flat) {
//knob shadow
cairo_save(cr);
@@ -199,8 +199,8 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
ArdourCanvas::set_source_rgba(cr, knob_color);
cairo_arc (cr, 0, 0, center_radius, 0, 2.0*G_PI);
cairo_fill (cr);
-
- //gradient
+
+ //gradient
if (bevel) {
//knob gradient
shade_pattern = cairo_pattern_create_linear (0.0, -yc, 0.0, yc); //note we have to offset the gradient from our centerpoint
@@ -217,7 +217,7 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
ArdourCanvas::set_source_rgb_a (cr, knob_color, 0.5 );
cairo_arc (cr, 0, 0, center_radius-pointer_thickness, 0, 2.0*G_PI);
cairo_fill (cr);
- } else {
+ } else {
//radial gradient
shade_pattern = cairo_pattern_create_radial ( -center_radius, -center_radius, 1, -center_radius, -center_radius, center_radius*2.5 ); //note we have to offset the gradient from our centerpoint
cairo_pattern_add_color_stop_rgba (shade_pattern, 0.0, 1,1,1, 0.2);
@@ -227,21 +227,21 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
cairo_fill (cr);
cairo_pattern_destroy (shade_pattern);
}
-
+
} else {
//inner circle
ArdourCanvas::set_source_rgba(cr, knob_color);
cairo_arc (cr, 0, 0, center_radius, 0, 2.0*G_PI);
cairo_fill (cr);
}
-
+
//black knob border
cairo_set_line_width (cr, border_width);
cairo_set_source_rgba (cr, 0,0,0, 1 );
cairo_arc (cr, 0, 0, center_radius, 0, 2.0*G_PI);
cairo_stroke (cr);
-
+
//line shadow
if (!flat) {
cairo_save(cr);
@@ -254,7 +254,7 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
cairo_stroke (cr);
cairo_restore(cr);
}
-
+
//line
cairo_set_source_rgba (cr, 1,1,1, 1 );
cairo_set_line_cap (cr, CAIRO_LINE_CAP_ROUND);
@@ -269,8 +269,8 @@ ArdourKnob::render (cairo_t* cr, cairo_rectangle_t *)
cairo_arc (cr, 0, 0, center_radius, 0, 2.0*G_PI);
cairo_fill (cr);
}
-
- cairo_identity_matrix(cr);
+
+ cairo_identity_matrix(cr);
}
void
@@ -305,11 +305,11 @@ ArdourKnob::on_scroll_event (GdkEventScroll* ev)
boost::shared_ptr<PBD::Controllable> c = binding_proxy.get_controllable();
if (c) {
float val = c->get_interface();
-
+
if ( ev->direction == GDK_SCROLL_UP )
val += scale;
else
- val -= scale;
+ val -= scale;
c->set_interface(val);
}
@@ -408,7 +408,7 @@ ArdourKnob::on_button_press_event (GdkEventButton *ev)
if (ev->button != 1 && ev->button != 2) {
return false;
}
-
+
set_active_state (Gtkmm2ext::ExplicitActive);
_tooltip.start_drag();
add_modal_grab();
@@ -506,14 +506,14 @@ ArdourKnob::set_active_state (Gtkmm2ext::ActiveState s)
if (_active_state != s)
CairoWidget::set_active_state (s);
}
-
+
void
ArdourKnob::set_visual_state (Gtkmm2ext::VisualState s)
{
if (_visual_state != s)
CairoWidget::set_visual_state (s);
}
-
+
bool
ArdourKnob::on_focus_in_event (GdkEventFocus* ev)
diff --git a/gtk2_ardour/ardour_knob.h b/gtk2_ardour/ardour_knob.h
index 29cfb5e4f4..d9a9c94209 100644
--- a/gtk2_ardour/ardour_knob.h
+++ b/gtk2_ardour/ardour_knob.h
@@ -113,7 +113,7 @@ public:
float _val; // current value [0..1]
float _normal; // default value, arc
float _dead_zone_delta;
-
+
Flags _flags;
void action_sensitivity_changed ();
diff --git a/gtk2_ardour/ardour_ui.cc b/gtk2_ardour/ardour_ui.cc
index bc1587b7cc..500acd6332 100644
--- a/gtk2_ardour/ardour_ui.cc
+++ b/gtk2_ardour/ardour_ui.cc
@@ -305,7 +305,7 @@ ARDOUR_UI::ARDOUR_UI (int *argcp, char **argvp[], const char* localedir)
xmlSetGenericErrorFunc (this, libxml_generic_error_func);
xmlSetStructuredErrorFunc (this, libxml_structured_error_func);
-
+
UIConfiguration::instance().ParameterChanged.connect (sigc::mem_fun (*this, &ARDOUR_UI::parameter_changed));
boost::function<void (string)> pc (boost::bind (&ARDOUR_UI::parameter_changed, this, _1));
UIConfiguration::instance().map_parameters (pc);
@@ -441,7 +441,7 @@ ARDOUR_UI::ARDOUR_UI (int *argcp, char **argvp[], const char* localedir)
/* Trigger setting up the color scheme and loading the GTK RC file */
UIConfiguration::instance().load_rc_file (false);
-
+
_process_thread = new ProcessThread ();
_process_thread->init ();
diff --git a/gtk2_ardour/ardour_ui.h b/gtk2_ardour/ardour_ui.h
index 7ad154f0d4..ce6c74c8c1 100644
--- a/gtk2_ardour/ardour_ui.h
+++ b/gtk2_ardour/ardour_ui.h
@@ -180,7 +180,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
ARDOUR::Session* the_session() { return _session; }
bool get_smart_mode () const;
-
+
int get_session_parameters (bool quit_on_cancel, bool should_be_new = false, std::string load_template = "");
int build_session_from_dialog (SessionDialog&, const std::string& session_name, const std::string& session_path);
bool ask_about_loading_existing_session (const std::string& session_path);
@@ -193,7 +193,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
void save_state (const std::string & state_name = "", bool switch_to_it = false);
static ARDOUR_UI *instance () { return theArdourUI; }
-
+
PublicEditor& the_editor() { return *editor;}
Mixer_UI* the_mixer() { return mixer; }
@@ -227,7 +227,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
void create_xrun_marker (framepos_t);
GUIObjectState* gui_object_state;
-
+
MainClock* primary_clock;
MainClock* secondary_clock;
void focus_on_clock ();
@@ -486,13 +486,13 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
void audition_blink (bool);
void feedback_blink (bool);
void error_blink (bool);
-
+
void set_flat_buttons();
void soloing_changed (bool);
void auditioning_changed (bool);
void _auditioning_changed (bool);
-
+
bool solo_alert_press (GdkEventButton* ev);
bool audition_alert_press (GdkEventButton* ev);
bool feedback_alert_press (GdkEventButton *);
@@ -543,7 +543,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
Gtk::Label format_label;
void update_format ();
-
+
void every_second ();
void every_point_one_seconds ();
void every_point_zero_something_seconds ();
diff --git a/gtk2_ardour/ardour_ui2.cc b/gtk2_ardour/ardour_ui2.cc
index 4322c7e0ff..d8a1f218ec 100644
--- a/gtk2_ardour/ardour_ui2.cc
+++ b/gtk2_ardour/ardour_ui2.cc
@@ -412,7 +412,7 @@ ARDOUR_UI::setup_transport ()
shuttle_box = manage (new ShuttleControl);
shuttle_box->show ();
-
+
VBox* transport_vbox = manage (new VBox);
transport_vbox->set_name ("TransportBase");
transport_vbox->set_border_width (0);
@@ -734,4 +734,4 @@ ARDOUR_UI::toggle_follow_edits ()
UIConfiguration::instance().set_follow_edits (tact->get_active ());
}
-
+
diff --git a/gtk2_ardour/ardour_ui_dialogs.cc b/gtk2_ardour/ardour_ui_dialogs.cc
index 00a16684e1..f41c06a9a1 100644
--- a/gtk2_ardour/ardour_ui_dialogs.cc
+++ b/gtk2_ardour/ardour_ui_dialogs.cc
@@ -348,7 +348,7 @@ ARDOUR_UI::goto_mixer_window ()
{
Glib::RefPtr<Gdk::Window> win;
Glib::RefPtr<Gdk::Screen> screen;
-
+
if (editor) {
win = editor->get_window ();
}
@@ -358,7 +358,7 @@ ARDOUR_UI::goto_mixer_window ()
} else {
screen = Gdk::Screen::get_default();
}
-
+
if (g_getenv ("ARDOUR_LOVES_STUPID_TINY_SCREENS") == 0 && screen && screen->get_height() < 700) {
Gtk::MessageDialog msg (_("This screen is not tall enough to display the mixer window"));
msg.run ();
diff --git a/gtk2_ardour/ardour_ui_ed.cc b/gtk2_ardour/ardour_ui_ed.cc
index fb077e49af..e4379fe432 100644
--- a/gtk2_ardour/ardour_ui_ed.cc
+++ b/gtk2_ardour/ardour_ui_ed.cc
@@ -137,7 +137,7 @@ ARDOUR_UI::install_actions ()
ActionManager::session_sensitive_actions.push_back (act);
ActionManager::write_sensitive_actions.push_back (act);
-
+
act = ActionManager::register_action (main_actions, X_("OpenVideo"), _("Open Video"),
sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::add_video), (Gtk::Window*) 0));
ActionManager::session_sensitive_actions.push_back (act);
diff --git a/gtk2_ardour/ardour_window.cc b/gtk2_ardour/ardour_window.cc
index 22e32731c0..1cb4202080 100644
--- a/gtk2_ardour/ardour_window.cc
+++ b/gtk2_ardour/ardour_window.cc
@@ -126,7 +126,7 @@ ArdourWindow::init ()
if (parent) {
set_transient_for (*parent);
}
-
+
ARDOUR_UI::CloseAllDialogs.connect (sigc::mem_fun (*this, &ArdourWindow::hide));
proxy = new WM::ProxyTemporary (get_title(), this);
diff --git a/gtk2_ardour/audio_clock.cc b/gtk2_ardour/audio_clock.cc
index 54f17725eb..cf55f63c6e 100644
--- a/gtk2_ardour/audio_clock.cc
+++ b/gtk2_ardour/audio_clock.cc
@@ -151,7 +151,7 @@ AudioClock::on_realize ()
Gtk::Requisition req;
CairoWidget::on_realize ();
-
+
set_clock_dimensions (req);
first_width = req.width;
@@ -318,7 +318,7 @@ AudioClock::render (cairo_t* cr, cairo_rectangle_t*)
cairo_save (cr);
cairo_scale (cr, xscale, yscale);
}
-
+
pango_cairo_show_layout (cr, _layout->gobj());
if (xscale != 1.0 || yscale != 1.0) {
@@ -507,15 +507,15 @@ AudioClock::on_size_request (Gtk::Requisition* req)
Glib::RefPtr<Gtk::Style> style = get_style ();
Pango::FontDescription font;
int w;
-
+
tmp = Pango::Layout::create (get_pango_context());
-
+
if (!is_realized()) {
font = get_font_for_style (get_name());
} else {
font = style->get_font();
}
-
+
tmp->set_font_description (font);
font.set_size (INFO_FONT_SIZE);
@@ -561,17 +561,17 @@ AudioClock::start_edit (Field f)
edit_string.clear ();
_layout->set_text ("");
}
-
+
input_string.clear ();
editing = true;
edit_is_negative = false;
-
+
if (f) {
input_string = get_field (f);
show_edit_status (merge_input_and_edit_string ());
_layout->set_text (edit_string);
}
-
+
queue_draw ();
Keyboard::magic_widget_grab_focus ();
diff --git a/gtk2_ardour/audio_clock.h b/gtk2_ardour/audio_clock.h
index 40e9644d92..3790fa88ef 100644
--- a/gtk2_ardour/audio_clock.h
+++ b/gtk2_ardour/audio_clock.h
@@ -87,7 +87,7 @@ class AudioClock : public CairoWidget, public ARDOUR::SessionHandlePtr
* to font distortion.
*/
void set_scale (double x, double y);
-
+
static void print_minsec (framepos_t, char* buf, size_t bufsize, float frame_rate);
sigc::signal<void> ValueChanged;
@@ -242,7 +242,7 @@ class AudioClock : public CairoWidget, public ARDOUR::SessionHandlePtr
ARDOUR::framecnt_t parse_as_minsec_distance (const std::string&);
ARDOUR::framecnt_t parse_as_bbt_distance (const std::string&);
ARDOUR::framecnt_t parse_as_frames_distance (const std::string&);
-
+
void set_font (Pango::FontDescription);
void set_colors ();
void show_edit_status (int length);
diff --git a/gtk2_ardour/audio_region_view.cc b/gtk2_ardour/audio_region_view.cc
index 73122a269d..706611a81d 100644
--- a/gtk2_ardour/audio_region_view.cc
+++ b/gtk2_ardour/audio_region_view.cc
@@ -235,7 +235,7 @@ AudioRegionView::init (bool wfd)
if (!Profile->get_sae()) {
gain_line.reset (new AudioRegionGainLine (line_name, *this, *group, audio_region()->envelope()));
}
-
+
update_envelope_visibility ();
gain_line->reset ();
@@ -375,7 +375,7 @@ AudioRegionView::fade_out_active_changed ()
if (end_xfade_rect) {
if (audio_region()->fade_out_active()) {
end_xfade_rect->set_fill (false);
- } else {
+ } else {
end_xfade_rect->set_fill_color (UIConfiguration::instance().color_mod ("inactive crossfade", "inactive crossfade"));
end_xfade_rect->set_fill (true);
}
@@ -420,7 +420,7 @@ AudioRegionView::region_resized (const PropertyChange& what_changed)
interesting_stuff.add (ARDOUR::Properties::length);
if (what_changed.contains (interesting_stuff)) {
-
+
for (uint32_t n = 0; n < waves.size(); ++n) {
waves[n]->region_resized ();
}
@@ -531,17 +531,17 @@ AudioRegionView::set_height (gdouble height)
if (wcnt > 0) {
gdouble ht;
-
+
if (!UIConfiguration::instance().get_show_name_highlight() || (height < NAME_HIGHLIGHT_THRESH)) {
ht = height / (double) wcnt;
} else {
ht = (height - NAME_HIGHLIGHT_SIZE) / (double) wcnt;
}
-
+
for (uint32_t n = 0; n < wcnt; ++n) {
-
+
gdouble yoff = floor (ht * n);
-
+
waves[n]->set_height (ht);
waves[n]->set_y_position (yoff);
}
@@ -635,7 +635,7 @@ AudioRegionView::reset_fade_in_shape_width (boost::shared_ptr<AudioRegion> ar, f
hide_start_xfade ();
return;
}
-
+
double effective_height;
if (_height >= NAME_HIGHLIGHT_THRESH) {
@@ -689,7 +689,7 @@ AudioRegionView::reset_fade_out_shape_width (boost::shared_ptr<AudioRegion> ar,
double const pwidth = floor(trackview.editor().sample_to_pixel (width));
-
+
/* the right edge should be right on the region frame is the pixel
* width is zero. Hence the additional + 1.0 at the end.
*/
@@ -731,7 +731,7 @@ AudioRegionView::reset_fade_out_shape_width (boost::shared_ptr<AudioRegion> ar,
}
/* points *MUST* be in anti-clockwise order */
-
+
Points points;
Points::size_type pi;
boost::shared_ptr<const Evoral::ControlList> list (audio_region()->fade_out());
@@ -739,7 +739,7 @@ AudioRegionView::reset_fade_out_shape_width (boost::shared_ptr<AudioRegion> ar,
double length = list->length();
points.assign (list->size(), Duple());
-
+
for (x = list->begin(), pi = 0; x != list->end(); ++x, ++pi) {
points[pi].x = _pixel_width - pwidth + (pwidth * ((*x)->when/length));
points[pi].y = effective_height - ((*x)->value * (effective_height - 1.));
@@ -839,7 +839,7 @@ AudioRegionView::redraw_start_xfade_to (boost::shared_ptr<AudioRegion> ar, frame
npoints = inverse->size();
ipoints.assign (npoints, Duple());
-
+
Evoral::ControlList::const_iterator x;
Points::size_type pi;
double length = inverse->length();
@@ -866,7 +866,7 @@ AudioRegionView::redraw_end_xfade ()
}
show_end_xfade();
-
+
reset_fade_out_shape_width (ar, ar->fade_out()->back()->when);
}
@@ -930,9 +930,9 @@ AudioRegionView::redraw_end_xfade_to (boost::shared_ptr<AudioRegion> ar, framecn
npoints = inverse->size();
ipoints.assign (npoints, Duple());
-
+
const double rend = trackview.editor().sample_to_pixel (_region->length() - width);
-
+
Evoral::ControlList::const_iterator x;
Points::size_type pi;
double length = inverse->length();
@@ -1218,12 +1218,12 @@ AudioRegionView::create_one_wave (uint32_t which, bool /*direct*/)
/* first waveview starts at 1.0, not 0.0 since that will overlap the
* frame
*/
-
+
gdouble yoff = which * ht;
WaveView *wave = new WaveView (group, audio_region ());
CANVAS_DEBUG_NAME (wave, string_compose ("wave view for chn %1 of %2", which, get_item_name()));
-
+
wave->set_channel (which);
wave->set_y_position (yoff);
wave->set_height (ht);
@@ -1231,9 +1231,9 @@ AudioRegionView::create_one_wave (uint32_t which, bool /*direct*/)
wave->set_show_zero_line (true);
wave->set_clip_level (UIConfiguration::instance().get_waveform_clip_level ());
wave->set_start_shift (1.0);
-
+
wave->Event.connect (sigc::bind (sigc::mem_fun (PublicEditor::instance(), &PublicEditor::canvas_wave_view_event), wave, this));
-
+
switch (UIConfiguration::instance().get_waveform_shape()) {
case Rectified:
wave->set_shape (WaveView::Rectified);
@@ -1241,7 +1241,7 @@ AudioRegionView::create_one_wave (uint32_t which, bool /*direct*/)
default:
wave->set_shape (WaveView::Normal);
}
-
+
wave->set_logscaled (UIConfiguration::instance().get_waveform_scale() == Logarithmic);
vector<ArdourCanvas::WaveView*> v;
@@ -1523,7 +1523,7 @@ AudioRegionView::set_some_waveform_colors (vector<ArdourCanvas::WaveView*>& wave
} else {
if (_region->muted()) {
/* hide outline with zero alpha */
- outline = UINT_RGBA_CHANGE_A(UIConfiguration::instance().color ("waveform outline"), 0);
+ outline = UINT_RGBA_CHANGE_A(UIConfiguration::instance().color ("waveform outline"), 0);
fill = UINT_RGBA_CHANGE_A(UIConfiguration::instance().color ("waveform fill"), MUTED_ALPHA);
} else {
outline = UIConfiguration::instance().color ("waveform outline");
diff --git a/gtk2_ardour/audio_region_view.h b/gtk2_ardour/audio_region_view.h
index e82b5fc5ed..646d044c07 100644
--- a/gtk2_ardour/audio_region_view.h
+++ b/gtk2_ardour/audio_region_view.h
@@ -122,7 +122,7 @@ class AudioRegionView : public RegionView
void redraw_end_xfade_to (boost::shared_ptr<ARDOUR::AudioRegion>, framecnt_t, ArdourCanvas::Points&, double, double, double);
void redraw_start_xfade ();
void redraw_end_xfade ();
-
+
void hide_xfades ();
void hide_start_xfade ();
void hide_end_xfade ();
diff --git a/gtk2_ardour/audio_streamview.cc b/gtk2_ardour/audio_streamview.cc
index 91a9ee4cf6..d078de7a27 100644
--- a/gtk2_ardour/audio_streamview.cc
+++ b/gtk2_ardour/audio_streamview.cc
@@ -432,7 +432,7 @@ AudioStreamView::hide_xfades_with (boost::shared_ptr<AudioRegion> ar)
{
list<AudioRegionView*> start_hidden;
list<AudioRegionView*> end_hidden;
-
+
for (list<RegionView*>::iterator i = region_views.begin(); i != region_views.end(); ++i) {
AudioRegionView* const arv = dynamic_cast<AudioRegionView*>(*i);
if (arv) {
diff --git a/gtk2_ardour/audio_time_axis.cc b/gtk2_ardour/audio_time_axis.cc
index 6110673985..f59c4bc809 100644
--- a/gtk2_ardour/audio_time_axis.cc
+++ b/gtk2_ardour/audio_time_axis.cc
@@ -183,14 +183,14 @@ AudioTimeAxisView::create_automation_child (const Evoral::Parameter& param, bool
AutomationTracks::iterator existing = _automation_tracks.find (param);
if (existing != _automation_tracks.end()) {
-
+
/* automation track created because we had existing data for
* the processor, but visibility may need to be controlled
* since it will have been set visible by default.
*/
existing->second->set_marked_for_display (show);
-
+
if (!no_redraw) {
request_redraw ();
}
@@ -219,7 +219,7 @@ AudioTimeAxisView::create_automation_child (const Evoral::Parameter& param, bool
} else if (param.type() == MuteAutomation) {
create_mute_automation_child (param, show);
-
+
} else {
error << "AudioTimeAxisView: unknown automation child " << EventTypeMap::instance().to_symbol(param) << endmsg;
diff --git a/gtk2_ardour/automation_line.cc b/gtk2_ardour/automation_line.cc
index 8137fc4b19..d2a66a1027 100644
--- a/gtk2_ardour/automation_line.cc
+++ b/gtk2_ardour/automation_line.cc
@@ -94,7 +94,7 @@ AutomationLine::AutomationLine (const string& name,
} else {
_our_time_converter = true;
}
-
+
_visible = Line;
update_pending = false;
@@ -203,7 +203,7 @@ AutomationLine::hide ()
/* leave control points setting unchanged, we are just hiding the
overall line
*/
-
+
set_visibility (AutomationLine::VisibleAspects (_visible & ~Line));
}
@@ -582,10 +582,10 @@ AutomationLine::ContiguousControlPoints::clamp_dx (double dx)
/* get the maximum distance we can move any of these points along the x-axis
*/
-
+
double tx; /* possible position a point would move to, given dx */
ControlPoint* cp;
-
+
if (dx > 0) {
/* check the last point, since we're moving later in time */
cp = back();
@@ -649,15 +649,15 @@ AutomationLine::drag_motion (double const x, float fraction, bool ignore_x, bool
no motion ever took place, but need to do before we handle
motion.
*/
-
+
/* partition the points we are dragging into (potentially several)
* set(s) of contiguous points. this will not happen with a normal
* drag, but if the user does a discontiguous selection, it can.
*/
-
+
uint32_t expected_view_index = 0;
CCP contig;
-
+
for (list<ControlPoint*>::iterator i = _drag_points.begin(); i != _drag_points.end(); ++i) {
if (i == _drag_points.begin() || (*i)->view_index() != expected_view_index) {
contig.reset (new ContiguousControlPoints (*this));
@@ -675,7 +675,7 @@ AutomationLine::drag_motion (double const x, float fraction, bool ignore_x, bool
(*ccp)->compute_x_bounds (trackview.editor());
}
_drag_had_movement = true;
- }
+ }
/* OK, now on to the stuff related to *this* motion event. First, for
* each contiguous range, figure out the maximum x-axis motion we are
@@ -695,7 +695,7 @@ AutomationLine::drag_motion (double const x, float fraction, bool ignore_x, bool
}
/* clamp y */
-
+
for (list<ControlPoint*>::iterator i = _drag_points.begin(); i != _drag_points.end(); ++i) {
double const y = ((_height - (*i)->get_y()) / _height) + dy;
if (y < 0) {
@@ -709,7 +709,7 @@ AutomationLine::drag_motion (double const x, float fraction, bool ignore_x, bool
if (dx || dy) {
/* and now move each section */
-
+
for (vector<CCP>::iterator ccp = contiguous_points.begin(); ccp != contiguous_points.end(); ++ccp) {
(*ccp)->move (dx, dy);
}
@@ -731,7 +731,7 @@ AutomationLine::drag_motion (double const x, float fraction, bool ignore_x, bool
line->set_steps (line_points, is_stepped());
}
}
-
+
_drag_distance += dx;
_drag_x += dx;
_last_drag_fraction = fraction;
@@ -884,7 +884,7 @@ AutomationLine::remove_point (ControlPoint& cp)
XMLNode &before = alist->get_state();
alist->erase (cp.model());
-
+
trackview.editor().session()->add_command(
new MementoCommand<AutomationList> (memento_command_binder (), &before, &alist->get_state()));
@@ -912,7 +912,7 @@ AutomationLine::get_selectables (framepos_t start, framepos_t end, double botfra
/* model_when is relative to the start of the source, so we just need to add on the origin_b here
(as it is the session frame position of the start of the source)
*/
-
+
framepos_t const session_frames_when = _time_converter->to (model_when) + _time_converter->origin_b ();
if (session_frames_when >= start && session_frames_when <= end && (*i)->get_y() >= bot_track && (*i)->get_y() <= top_track) {
@@ -993,7 +993,7 @@ AutomationLine::reset_callback (const Evoral::ControlList& events)
np = events.size();
Evoral::ControlList& e = const_cast<Evoral::ControlList&> (events);
-
+
for (AutomationList::iterator ai = e.begin(); ai != e.end(); ++ai, ++pi) {
double tx = (*ai)->when;
@@ -1008,17 +1008,17 @@ AutomationLine::reset_callback (const Evoral::ControlList& events)
_name) << endmsg;
continue;
}
-
+
if (tx >= max_framepos || tx < 0 || tx >= _maximum_time) {
continue;
}
-
+
/* convert x-coordinate to a canvas unit coordinate (this takes
* zoom and scroll into account).
*/
-
+
tx = trackview.editor().sample_to_pixel_unrounded (tx);
-
+
/* convert from canonical view height (0..1.0) to actual
* height coordinates (using X11's top-left rooted system)
*/
diff --git a/gtk2_ardour/automation_line.h b/gtk2_ardour/automation_line.h
index 19399ec435..816cefedef 100644
--- a/gtk2_ardour/automation_line.h
+++ b/gtk2_ardour/automation_line.h
@@ -60,7 +60,7 @@ public:
ControlPoints = 0x2,
SelectedControlPoints = 0x4
};
-
+
AutomationLine (const std::string& name,
TimeAxisView& tv,
ArdourCanvas::Item& parent,
diff --git a/gtk2_ardour/automation_time_axis.cc b/gtk2_ardour/automation_time_axis.cc
index 41ef49e9be..1c79593b34 100644
--- a/gtk2_ardour/automation_time_axis.cc
+++ b/gtk2_ardour/automation_time_axis.cc
@@ -110,7 +110,7 @@ AutomationTimeAxisView::AutomationTimeAxisView (
}
tipname += nom;
_name = tipname;
-
+
CANVAS_DEBUG_NAME (_canvas_display, string_compose ("main for auto %2/%1", _name, r->name()));
CANVAS_DEBUG_NAME (selection_group, string_compose ("selections for auto %2/%1", _name, r->name()));
CANVAS_DEBUG_NAME (_ghost_group, string_compose ("ghosts for auto %2/%1", _name, r->name()));
@@ -178,7 +178,7 @@ AutomationTimeAxisView::AutomationTimeAxisView (
if (name_label.get_parent()) {
name_label.get_parent()->remove (name_label);
}
-
+
name_label.set_text (_name);
name_label.set_alignment (Gtk::ALIGN_LEFT, Gtk::ALIGN_CENTER);
name_label.set_name (X_("TrackParameterName"));
@@ -618,7 +618,7 @@ AutomationTimeAxisView::add_automation_event (GdkEvent* event, framepos_t when,
}
boost::shared_ptr<AutomationList> list = _line->the_list ();
-
+
if (list->in_write_pass()) {
/* do not allow the GUI to add automation events during an
automation write pass.
@@ -781,11 +781,11 @@ AutomationTimeAxisView::add_line (boost::shared_ptr<AutomationLine> line)
{
if (_control && line) {
assert(line->the_list() == _control->list());
-
+
_control->alist()->automation_state_changed.connect (
_list_connections, invalidator (*this), boost::bind (&AutomationTimeAxisView::automation_state_changed, this), gui_context()
);
-
+
_control->alist()->InterpolationChanged.connect (
_list_connections, invalidator (*this), boost::bind (&AutomationTimeAxisView::interpolation_changed, this, _1), gui_context()
);
@@ -860,15 +860,15 @@ AutomationTimeAxisView::what_has_visible_automation (const boost::shared_ptr<Aut
assert (automatable);
Automatable::Controls& controls (automatable->controls());
-
+
for (Automatable::Controls::iterator i = controls.begin(); i != controls.end(); ++i) {
-
+
boost::shared_ptr<AutomationControl> ac = boost::dynamic_pointer_cast<AutomationControl> (i->second);
if (ac && ac->alist()) {
-
+
const XMLNode* gui_node = ac->extra_xml ("GUI");
-
+
if (gui_node) {
const XMLProperty* prop = gui_node->property ("shown");
if (prop) {
diff --git a/gtk2_ardour/axis_view.h b/gtk2_ardour/axis_view.h
index 5ff8f62292..b47ca98163 100644
--- a/gtk2_ardour/axis_view.h
+++ b/gtk2_ardour/axis_view.h
@@ -54,7 +54,7 @@ class AxisView : public virtual Selectable, public PBD::ScopedConnectionList, pu
virtual std::string name() const = 0;
sigc::signal<void> Hiding;
-
+
void set_old_order_key (uint32_t ok) { _old_order_key = ok; }
uint32_t old_order_key() const { return _old_order_key; }
@@ -62,7 +62,7 @@ class AxisView : public virtual Selectable, public PBD::ScopedConnectionList, pu
/* for now, we always return properties in string form.
*/
std::string gui_property (const std::string& property_name) const;
-
+
template<typename T> void set_gui_property (const std::string& property_name, const T& value) {
std::stringstream s;
s << value;
@@ -82,7 +82,7 @@ class AxisView : public virtual Selectable, public PBD::ScopedConnectionList, pu
static GUIObjectState& gui_object_state();
void clear_property_cache() { property_hashtable.clear(); }
-
+
protected:
AxisView (ARDOUR::Session* sess);
diff --git a/gtk2_ardour/big_clock_window.h b/gtk2_ardour/big_clock_window.h
index 1f723d1b59..a073bcc099 100644
--- a/gtk2_ardour/big_clock_window.h
+++ b/gtk2_ardour/big_clock_window.h
@@ -28,11 +28,11 @@ class BigClockWindow : public ArdourWindow
{
public:
BigClockWindow (AudioClock&);
-
+
private:
AudioClock& clock;
Gtk::Requisition default_size;
-
+
void clock_size_reallocated (Gtk::Allocation&);
void on_realize ();
void on_unmap ();
diff --git a/gtk2_ardour/bundle_env_cocoa.cc b/gtk2_ardour/bundle_env_cocoa.cc
index 17d8075d38..418ca3636d 100644
--- a/gtk2_ardour/bundle_env_cocoa.cc
+++ b/gtk2_ardour/bundle_env_cocoa.cc
@@ -79,7 +79,7 @@ fixup_bundle_environment (int, char* [], string & localedir)
localedir = "/this/cannot/exist";
} else {
/* force localedir into the bundle */
-
+
vector<string> lpath;
lpath.push_back (bundle_dir);
lpath.push_back ("Resources");
@@ -87,7 +87,7 @@ fixup_bundle_environment (int, char* [], string & localedir)
localedir = Glib::build_filename (lpath).c_str();
}
#endif
-
+
export_search_path (bundle_dir, "ARDOUR_DLL_PATH", "/lib");
/* inside an OS X .app bundle, there is no difference
diff --git a/gtk2_ardour/bundle_env_msvc.cc b/gtk2_ardour/bundle_env_msvc.cc
index c119eb29bf..981553c179 100644
--- a/gtk2_ardour/bundle_env_msvc.cc
+++ b/gtk2_ardour/bundle_env_msvc.cc
@@ -86,7 +86,7 @@ std::string ret;
if (0 == pExeRoot) {
pExeRoot = g_build_filename("C:\\", "Program Files", PROGRAM_NAME, 0);
}
-
+
if (pExeRoot) {
gchar tmp[PATH_MAX+1];
gchar* p;
@@ -232,7 +232,7 @@ string fonts_conf_file;
#ifdef DEBUG
fonts_conf_file = get_module_folder();
-
+
if (!fonts_conf_file.empty()) {
fonts_conf_file += "\\";
fonts_conf_file += PROGRAM_NAME;
@@ -257,7 +257,7 @@ string pango_modules_file;
#if defined(DEBUG) || defined(RDC_BUILD)
// Make sure we pick up the debuggable DLLs !!!
pango_modules_file = get_module_folder();
-
+
if (!pango_modules_file.empty()) {
pango_modules_file += "\\";
pango_modules_file += PROGRAM_NAME;
@@ -295,7 +295,7 @@ string gdk_pixbuf_loaders_file;
#if defined(DEBUG) || defined(RDC_BUILD)
// Make sure we pick up the debuggable DLLs !!!
gdk_pixbuf_loaders_file = get_module_folder();
-
+
if (!gdk_pixbuf_loaders_file.empty()) {
gdk_pixbuf_loaders_file += "\\";
gdk_pixbuf_loaders_file += PROGRAM_NAME;
@@ -321,7 +321,7 @@ string clearlooks_la_file;
#if defined(DEBUG) || defined(RDC_BUILD)
// Make sure we pick up the debuggable DLLs !!!
clearlooks_la_file = get_module_folder();
-
+
if (!clearlooks_la_file.empty()) {
clearlooks_la_file += "\\";
clearlooks_la_file += PROGRAM_NAME;
diff --git a/gtk2_ardour/button_joiner.cc b/gtk2_ardour/button_joiner.cc
index bc2a0ae2f2..a3ef36ac80 100644
--- a/gtk2_ardour/button_joiner.cc
+++ b/gtk2_ardour/button_joiner.cc
@@ -78,7 +78,7 @@ ButtonJoiner::ButtonJoiner (const std::string& str, Gtk::Widget& lw, Gtk::Widget
border_color = UIConfiguration::instance().color (string_compose ("%1: border end", name));
UINT_TO_RGBA (border_color, &r, &g, &b, &a);
-
+
border_r = r/255.0;
border_g = g/255.0;
border_b = b/255.0;
@@ -104,7 +104,7 @@ void
ButtonJoiner::render (cairo_t* cr, cairo_rectangle_t*)
{
double h = get_height();
-
+
if (!get_active()) {
cairo_set_source (cr, inactive_fill_pattern);
} else {
@@ -113,25 +113,25 @@ ButtonJoiner::render (cairo_t* cr, cairo_rectangle_t*)
if (!central_link) {
/* outer rect */
-
+
Gtkmm2ext::rounded_top_rectangle (cr, 0, 0, get_width(), h, 8);
cairo_fill_preserve (cr);
-
+
/* outer edge */
-
+
cairo_set_line_width (cr, 1.5);
cairo_set_source_rgb (cr, border_r, border_g, border_b);
cairo_stroke (cr);
-
+
/* inner "edge" */
-
+
Gtkmm2ext::rounded_top_rectangle (cr, 8, 8, get_width() - 16, h - 8, 6);
cairo_stroke (cr);
} else {
if (get_active()) {
Gtkmm2ext::rounded_top_rectangle (cr, 0, 0, (get_width() - 20.0)/2.0 , h, 8);
cairo_fill_preserve (cr);
-
+
Gtkmm2ext::rounded_top_rectangle (cr, (get_width() - 20.)/2.0 + 20.0, 0.0,
(get_width() - 20.0)/2.0 , h, 8);
cairo_fill_preserve (cr);
@@ -146,7 +146,7 @@ ButtonJoiner::render (cairo_t* cr, cairo_rectangle_t*)
cairo_set_line_width (cr, 1.5);
cairo_fill_preserve (cr);
cairo_set_source_rgb (cr, border_r, border_g, border_b);
- cairo_stroke (cr);
+ cairo_stroke (cr);
}
}
}
@@ -203,7 +203,7 @@ ButtonJoiner::action_sensitivity_changed ()
} else {
set_visual_state (Gtkmm2ext::VisualState (visual_state() | Gtkmm2ext::Insensitive));
}
-
+
}
void
@@ -231,7 +231,7 @@ ButtonJoiner::action_toggled ()
if (tact) {
set_active (tact->get_active());
}
-}
+}
void
ButtonJoiner::set_active_state (Gtkmm2ext::ActiveState s)
diff --git a/gtk2_ardour/button_joiner.h b/gtk2_ardour/button_joiner.h
index 4716f7fda1..41e5f745c0 100644
--- a/gtk2_ardour/button_joiner.h
+++ b/gtk2_ardour/button_joiner.h
@@ -32,7 +32,7 @@ class ButtonJoiner : public CairoWidget, public Gtkmm2ext::Activatable {
ButtonJoiner (const std::string&, Gtk::Widget&, Gtk::Widget&, bool central_link = false);
~ButtonJoiner ();
- void set_related_action (Glib::RefPtr<Gtk::Action>);
+ void set_related_action (Glib::RefPtr<Gtk::Action>);
void set_active_state (Gtkmm2ext::ActiveState);
protected:
diff --git a/gtk2_ardour/canvas-waveview.c b/gtk2_ardour/canvas-waveview.c
index e9bdb4f1eb..bf7dad0429 100644
--- a/gtk2_ardour/canvas-waveview.c
+++ b/gtk2_ardour/canvas-waveview.c
@@ -1361,7 +1361,7 @@ gnome_canvas_waveview_gradient_render (GnomeCanvasItem *item,
} else {
PAINT_VERTA_GR(buf, waveview->wave_r, waveview->wave_g, waveview->wave_b, waveview->wave_a, x, pymax, fill_max, wave_middle, wave_top);
}
-
+
}
if((prev_pymin > pymin && next_pymin > pymin) ||
@@ -1559,7 +1559,7 @@ gnome_canvas_waveview_gradient_render (GnomeCanvasItem *item,
PAINT_VERTA(buf, waveview->clip_r, waveview->clip_g, waveview->clip_b, waveview->clip_a >> 1, x - 1, pymax, pymax + (clip_length - 1));
}
- if (clip_min) {
+ if (clip_min) {
PAINT_VERTA(buf, waveview->clip_r, waveview->clip_g, waveview->clip_b, waveview->clip_a , x, pymin - clip_length, pymin);
PAINT_VERTA(buf, waveview->clip_r, waveview->clip_g, waveview->clip_b, waveview->clip_a >> 1, x + 1, pymin - (clip_length - 1), pymin);
PAINT_VERTA(buf, waveview->clip_r, waveview->clip_g, waveview->clip_b, waveview->clip_a >> 1, x - 1, pymin - (clip_length - 1), pymin);
diff --git a/gtk2_ardour/control_point.cc b/gtk2_ardour/control_point.cc
index a044ccfb8f..b906e639d5 100644
--- a/gtk2_ardour/control_point.cc
+++ b/gtk2_ardour/control_point.cc
@@ -80,7 +80,7 @@ ControlPoint::ControlPoint (const ControlPoint& other, bool /*dummy_arg_to_force
ControlPoint::~ControlPoint ()
{
CatchDeletion (this); /* EMIT SIGNAL */
-
+
delete _item;
}
diff --git a/gtk2_ardour/control_point.h b/gtk2_ardour/control_point.h
index 045f1241ed..c9aab3af64 100644
--- a/gtk2_ardour/control_point.h
+++ b/gtk2_ardour/control_point.h
@@ -81,7 +81,7 @@ class ControlPoint : public Selectable
AutomationLine& line() const { return _line; }
static PBD::Signal1<void, ControlPoint *> CatchDeletion;
-
+
private:
ArdourCanvas::Rectangle* _item;
AutomationLine& _line;
diff --git a/gtk2_ardour/edit_note_dialog.cc b/gtk2_ardour/edit_note_dialog.cc
index 0568468d63..ae154807a2 100644
--- a/gtk2_ardour/edit_note_dialog.cc
+++ b/gtk2_ardour/edit_note_dialog.cc
@@ -112,13 +112,13 @@ EditNoteDialog::EditNoteDialog (MidiRegionView* rv, set<NoteBase*> n)
_velocity_all.set_sensitive (false);
_time_all.set_sensitive (false);
_length_all.set_sensitive (false);
-
+
int test_channel = (*_events.begin())->note()->channel ();
int test_pitch = (*_events.begin())->note()->note ();
int test_velocity = (*_events.begin())->note()->velocity ();
Evoral::Beats test_time = (*_events.begin())->note()->time ();
Evoral::Beats test_length = (*_events.begin())->note()->length ();
-
+
for (set<NoteBase*>::iterator i = _events.begin(); i != _events.end(); ++i) {
if ((*i)->note()->channel() != test_channel) {
_channel_all.set_sensitive (true);
@@ -140,7 +140,7 @@ EditNoteDialog::EditNoteDialog (MidiRegionView* rv, set<NoteBase*> n)
_length_all.set_sensitive (true);
}
}
-
+
get_vbox()->pack_start (*table);
add_button (Gtk::Stock::CANCEL, Gtk::RESPONSE_CANCEL);
diff --git a/gtk2_ardour/editor.cc b/gtk2_ardour/editor.cc
index 102b986e39..b5d6a55dd8 100644
--- a/gtk2_ardour/editor.cc
+++ b/gtk2_ardour/editor.cc
@@ -235,7 +235,7 @@ pane_size_watcher (Paned* pane)
X: hard to access
Quartz: impossible to access
-
+
so stop that by preventing it from ever getting too narrow. 35
pixels is basically a rough guess at the tab width.
@@ -313,7 +313,7 @@ Editor::Editor ()
PublicEditor::_instance = this;
_have_idled = false;
-
+
selection = new Selection (this);
cut_buffer = new Selection (this);
_selection_memento = new SelectionMemento ();
@@ -742,7 +742,7 @@ Editor::Editor ()
signal_delete_event().connect (sigc::mem_fun (*ARDOUR_UI::instance(), &ARDOUR_UI::exit_on_main_window_close));
Gtkmm2ext::Keyboard::the_keyboard().ZoomVerticalModifierReleased.connect (sigc::mem_fun (*this, &Editor::zoom_vertical_modifier_released));
-
+
/* allow external control surfaces/protocols to do various things */
ControlProtocol::ZoomToSession.connect (*this, invalidator (*this), boost::bind (&Editor::temporal_zoom_session, this), gui_context());
@@ -1019,7 +1019,7 @@ Editor::control_select (uint32_t rid, Selection::Operation op)
/* handles the (static) signal from the ControlProtocol class that
* requests setting the selected track to a given RID
*/
-
+
if (!_session) {
return;
}
@@ -1464,18 +1464,18 @@ Editor::fill_xfade_menu (Menu_Helpers::MenuList& items, bool start)
sigc::bind (sigc::mem_fun (*this, emf), FadeLinear)
)
);
-
+
dynamic_cast<ImageMenuItem*>(&items.back())->set_always_show_image ();
-
+
items.push_back (
ImageMenuElem (
_("Constant power"),
*(*images)[FadeConstantPower],
sigc::bind (sigc::mem_fun (*this, emf), FadeConstantPower)
));
-
+
dynamic_cast<ImageMenuItem*>(&items.back())->set_always_show_image ();
-
+
items.push_back (
ImageMenuElem (
_("Symmetric"),
@@ -1483,25 +1483,25 @@ Editor::fill_xfade_menu (Menu_Helpers::MenuList& items, bool start)
sigc::bind (sigc::mem_fun (*this, emf), FadeSymmetric)
)
);
-
+
dynamic_cast<ImageMenuItem*>(&items.back())->set_always_show_image ();
-
+
items.push_back (
ImageMenuElem (
_("Slow"),
*(*images)[FadeSlow],
sigc::bind (sigc::mem_fun (*this, emf), FadeSlow)
));
-
+
dynamic_cast<ImageMenuItem*>(&items.back())->set_always_show_image ();
-
+
items.push_back (
ImageMenuElem (
_("Fast"),
*(*images)[FadeFast],
sigc::bind (sigc::mem_fun (*this, emf), FadeFast)
));
-
+
dynamic_cast<ImageMenuItem*>(&items.back())->set_always_show_image ();
}
@@ -2101,7 +2101,7 @@ Editor::set_snap_to (SnapType st)
case SnapToBeatDiv2: {
ARDOUR::TempoMap::BBTPointList::const_iterator current_bbt_points_begin;
ARDOUR::TempoMap::BBTPointList::const_iterator current_bbt_points_end;
-
+
compute_current_bbt_points (leftmost_frame, leftmost_frame + current_page_samples(),
current_bbt_points_begin, current_bbt_points_end);
compute_bbt_ruler_scale (leftmost_frame, leftmost_frame + current_page_samples(),
@@ -2587,9 +2587,9 @@ Editor::trackview_by_y_position (double y, bool trackview_relative_offset) const
}
for (TrackViewList::const_iterator iter = track_views.begin(); iter != track_views.end(); ++iter) {
-
+
std::pair<TimeAxisView*, double> const r = (*iter)->covers_y_position (y);
-
+
if (r.first) {
return r;
}
@@ -2948,7 +2948,7 @@ Editor::setup_toolbar ()
if (!ARDOUR::Profile->get_mixbus()) {
mouse_mode_hbox->pack_start (mouse_cut_button, false, false);
}
-
+
if (!ARDOUR::Profile->get_trx()) {
mouse_mode_hbox->pack_start (mouse_timefx_button, false, false);
mouse_mode_hbox->pack_start (mouse_audition_button, false, false);
@@ -3059,7 +3059,7 @@ Editor::setup_toolbar ()
if (!ARDOUR::Profile->get_trx()) {
_zoom_tearoff = manage (new TearOff (_zoom_box));
-
+
_zoom_tearoff->Detach.connect (sigc::bind (sigc::mem_fun(*this, &Editor::detach_tearoff), static_cast<Box*>(&toolbar_hbox),
&_zoom_tearoff->tearoff_window()));
_zoom_tearoff->Attach.connect (sigc::bind (sigc::mem_fun(*this, &Editor::reattach_tearoff), static_cast<Box*> (&toolbar_hbox),
@@ -3169,7 +3169,7 @@ void
Editor::build_edit_mode_menu ()
{
using namespace Menu_Helpers;
-
+
edit_mode_selector.AddMenuElem (MenuElem ( edit_mode_strings[(int)Slide], sigc::bind (sigc::mem_fun(*this, &Editor::edit_mode_selection_done), (EditMode) Slide)));
// edit_mode_selector.AddMenuElem (MenuElem ( edit_mode_strings[(int)Splice], sigc::bind (sigc::mem_fun(*this, &Editor::edit_mode_selection_done), (EditMode) Splice)));
edit_mode_selector.AddMenuElem (MenuElem ( edit_mode_strings[(int)Ripple], sigc::bind (sigc::mem_fun(*this, &Editor::edit_mode_selection_done), (EditMode) Ripple)));
@@ -3400,11 +3400,11 @@ Editor::commit_reversible_selection_op ()
The user has undone some selection ops and then made a new one,
making anything earlier in the list invalid.
*/
-
+
list<XMLNode *>::iterator it = selection_op_history.begin();
list<XMLNode *>::iterator e_it = it;
advance (e_it, selection_op_history_it);
-
+
for ( ; it != e_it; ++it) {
delete *it;
}
@@ -3764,7 +3764,7 @@ Editor::set_zoom_preset (int64_t ms)
temporal_zoom_session();
return;
}
-
+
ARDOUR::framecnt_t const sample_rate = ARDOUR::AudioEngine::instance()->sample_rate();
temporal_zoom( (sample_rate * ms / 1000) / _visible_canvas_width );
}
@@ -3779,7 +3779,7 @@ Editor::set_visible_track_count (int32_t n)
allocation happens, we will get called again and then we can do the
real work.
*/
-
+
if (_visible_canvas_height <= 1) {
return;
}
@@ -3787,7 +3787,7 @@ Editor::set_visible_track_count (int32_t n)
int h;
string str;
DisplaySuspender ds;
-
+
if (_visible_track_count > 0) {
h = trackviews_height() / _visible_track_count;
std::ostringstream s;
@@ -3813,7 +3813,7 @@ Editor::set_visible_track_count (int32_t n)
for (TrackViewList::iterator i = track_views.begin(); i != track_views.end(); ++i) {
(*i)->set_height (h, TimeAxisView::HeightPerLane);
}
-
+
if (str != visible_tracks_selector.get_text()) {
visible_tracks_selector.set_text (str);
}
@@ -3995,7 +3995,7 @@ Editor::set_show_measures (bool yn)
ARDOUR::TempoMap::BBTPointList::const_iterator begin;
ARDOUR::TempoMap::BBTPointList::const_iterator end;
-
+
compute_current_bbt_points (leftmost_frame, leftmost_frame + current_page_samples(), begin, end);
draw_measures (begin, end);
}
@@ -4329,7 +4329,7 @@ Editor::copy_playlists (TimeAxisView* v)
void
Editor::clear_playlists (TimeAxisView* v)
{
- begin_reversible_command (_("clear playlists"));
+ begin_reversible_command (_("clear playlists"));
vector<boost::shared_ptr<ARDOUR::Playlist> > playlists;
_session->playlists->get (playlists);
mapover_tracks (sigc::mem_fun (*this, &Editor::mapped_clear_playlist), v, ARDOUR::Properties::select.property_id);
@@ -4434,7 +4434,7 @@ Editor::current_visual_state (bool with_tracks)
vs->leftmost_frame = leftmost_frame;
vs->zoom_focus = zoom_focus;
- if (with_tracks) {
+ if (with_tracks) {
*vs->gui_state = *ARDOUR_UI::instance()->gui_object_state;
}
@@ -4498,11 +4498,11 @@ Editor::use_visual_state (VisualState& vs)
set_zoom_focus (vs.zoom_focus);
reposition_and_zoom (vs.leftmost_frame, vs.samples_per_pixel);
-
+
if (vs.gui_state) {
*ARDOUR_UI::instance()->gui_object_state = *vs.gui_state;
-
- for (TrackViewList::iterator i = track_views.begin(); i != track_views.end(); ++i) {
+
+ for (TrackViewList::iterator i = track_views.begin(); i != track_views.end(); ++i) {
(*i)->clear_property_cache();
(*i)->reset_visual_state ();
}
@@ -4612,7 +4612,7 @@ Editor::idle_visual_changer ()
pending_visual_change.idle_handler_id = -1;
pending_visual_change.being_handled = true;
-
+
VisualChange vc = pending_visual_change;
pending_visual_change.pending = (VisualChange::Type) 0;
@@ -4636,7 +4636,7 @@ Editor::visual_changer (const VisualChange& vc)
ARDOUR::TempoMap::BBTPointList::const_iterator current_bbt_points_begin;
ARDOUR::TempoMap::BBTPointList::const_iterator current_bbt_points_end;
-
+
compute_current_bbt_points (vc.time_origin, pending_visual_change.time_origin + current_page_samples(),
current_bbt_points_begin, current_bbt_points_end);
compute_bbt_ruler_scale (vc.time_origin, pending_visual_change.time_origin + current_page_samples(),
@@ -4978,17 +4978,17 @@ Editor::get_regionviews_by_id (PBD::ID const id, RegionSelection & regions) cons
{
for (TrackViewList::const_iterator i = track_views.begin(); i != track_views.end(); ++i) {
RouteTimeAxisView* rtav;
-
+
if ((rtav = dynamic_cast<RouteTimeAxisView*> (*i)) != 0) {
boost::shared_ptr<Playlist> pl;
std::vector<boost::shared_ptr<Region> > results;
boost::shared_ptr<Track> tr;
-
+
if ((tr = rtav->track()) == 0) {
/* bus */
continue;
}
-
+
if ((pl = (tr->playlist())) != 0) {
boost::shared_ptr<Region> r = pl->region_by_id (id);
if (r) {
@@ -5014,7 +5014,7 @@ Editor::get_per_region_note_selection (list<pair<PBD::ID, set<boost::shared_ptr<
mtav->get_per_region_note_selection (selection);
}
}
-
+
}
void
@@ -5070,7 +5070,7 @@ void
Editor::first_idle ()
{
MessageDialog* dialog = 0;
-
+
if (track_views.size() > 1) {
dialog = new MessageDialog (
*this,
@@ -5606,7 +5606,7 @@ Editor::reset_x_origin_to_follow_playhead ()
} else {
framepos_t l = 0;
-
+
if (frame < leftmost_frame) {
/* moving left */
if (_session->transport_rolling()) {
@@ -5630,7 +5630,7 @@ Editor::reset_x_origin_to_follow_playhead ()
if (l < 0) {
l = 0;
}
-
+
center_screen_internal (l + (current_page_samples() / 2), current_page_samples ());
}
}
@@ -5775,7 +5775,7 @@ Editor::session_going_away ()
clear_marker_display ();
stop_step_editing ();
-
+
/* get rid of any existing editor mixer strip */
WindowTitle title(Glib::get_application_name());
@@ -5851,7 +5851,7 @@ Editor::setup_fade_images ()
_fade_out_images[FadeFast] = new Gtk::Image (get_icon_path (X_("fadeout-fast-cut")));
_fade_out_images[FadeSlow] = new Gtk::Image (get_icon_path (X_("fadeout-slow-cut")));
_fade_out_images[FadeConstantPower] = new Gtk::Image (get_icon_path (X_("fadeout-constant-power")));
-
+
_xfade_in_images[FadeLinear] = new Gtk::Image (get_icon_path (X_("fadein-linear")));
_xfade_in_images[FadeSymmetric] = new Gtk::Image (get_icon_path (X_("fadein-symmetric")));
_xfade_in_images[FadeFast] = new Gtk::Image (get_icon_path (X_("fadein-fast-cut")));
@@ -5922,10 +5922,10 @@ void
Editor::popup_control_point_context_menu (ArdourCanvas::Item* item, GdkEvent* event)
{
using namespace Menu_Helpers;
-
+
MenuList& items = _control_point_context_menu.items ();
items.clear ();
-
+
items.push_back (MenuElem (_("Edit..."), sigc::bind (sigc::mem_fun (*this, &Editor::edit_control_point), item)));
items.push_back (MenuElem (_("Delete"), sigc::bind (sigc::mem_fun (*this, &Editor::remove_control_point), item)));
if (!can_remove_control_point (item)) {
diff --git a/gtk2_ardour/editor.h b/gtk2_ardour/editor.h
index c1e9fc3218..013f82d8b2 100644
--- a/gtk2_ardour/editor.h
+++ b/gtk2_ardour/editor.h
@@ -263,7 +263,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
void set_selected_regionview_from_region_list (boost::shared_ptr<ARDOUR::Region> region, Selection::Operation op = Selection::Set);
void remove_tracks ();
-
+
/* tempo */
void set_show_measures (bool yn);
@@ -366,7 +366,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
void scroll_tracks_down_line ();
void scroll_tracks_up_line ();
-
+
bool scroll_up_one_track (bool skip_child_views = false);
bool scroll_down_one_track (bool skip_child_views = false);
@@ -503,7 +503,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
TimeAxisView* stepping_axis_view () {
return _stepping_axis_view;
}
-
+
void set_stepping_axis_view (TimeAxisView* v) {
_stepping_axis_view = v;
}
@@ -530,7 +530,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
void split_regions_at (framepos_t, RegionSelection&);
void split_region_at_points (boost::shared_ptr<ARDOUR::Region>, ARDOUR::AnalysisFeatureList&, bool can_ferret, bool select_new = false);
RegionSelection get_regions_from_selection_and_mouse (framepos_t);
-
+
void mouse_add_new_tempo_event (framepos_t where);
void mouse_add_new_meter_event (framepos_t where);
void edit_tempo_section (ARDOUR::TempoSection*);
@@ -719,7 +719,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
void mapped_use_new_playlist (RouteTimeAxisView&, uint32_t, std::vector<boost::shared_ptr<ARDOUR::Playlist> > const &);
void mapped_use_copy_playlist (RouteTimeAxisView&, uint32_t, std::vector<boost::shared_ptr<ARDOUR::Playlist> > const &);
void mapped_clear_playlist (RouteTimeAxisView&, uint32_t);
-
+
void button_selection (ArdourCanvas::Item* item, GdkEvent* event, ItemType item_type);
bool button_release_can_deselect;
bool _mouse_changed_selection;
@@ -2258,7 +2258,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
QuantizeDialog* quantize_dialog;
MainMenuDisabler* _main_menu_disabler;
-
+
friend class Drag;
friend class RegionDrag;
friend class RegionMoveDrag;
diff --git a/gtk2_ardour/editor_actions.cc b/gtk2_ardour/editor_actions.cc
index 5ac93a3339..388d4fd34d 100644
--- a/gtk2_ardour/editor_actions.cc
+++ b/gtk2_ardour/editor_actions.cc
@@ -460,7 +460,7 @@ Editor::register_actions ()
Glib::RefPtr<ActionGroup> mouse_mode_actions = ActionGroup::create (X_("MouseMode"));
RadioAction::Group mouse_mode_group;
- act = ActionManager::register_toggle_action (mouse_mode_actions, "set-mouse-mode-object-range", _("Smart Object Mode"), sigc::mem_fun (*this, &Editor::mouse_mode_object_range_toggled));
+ act = ActionManager::register_toggle_action (mouse_mode_actions, "set-mouse-mode-object-range", _("Smart Object Mode"), sigc::mem_fun (*this, &Editor::mouse_mode_object_range_toggled));
smart_mode_action = Glib::RefPtr<ToggleAction>::cast_static (act);
smart_mode_button.set_related_action (smart_mode_action);
smart_mode_button.set_text (_("Smart"));
@@ -471,27 +471,27 @@ Editor::register_actions ()
mouse_move_button.set_icon (Gtkmm2ext::ArdourIcon::ToolGrab);
mouse_move_button.set_name ("mouse mode button");
- act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-range", _("Range Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseRange));
+ act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-range", _("Range Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseRange));
mouse_select_button.set_related_action (act);
mouse_select_button.set_icon (Gtkmm2ext::ArdourIcon::ToolRange);
mouse_select_button.set_name ("mouse mode button");
- act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-draw", _("Note Drawing Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseDraw));
+ act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-draw", _("Note Drawing Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseDraw));
mouse_draw_button.set_related_action (act);
mouse_draw_button.set_icon (Gtkmm2ext::ArdourIcon::ToolDraw);
mouse_draw_button.set_name ("mouse mode button");
- act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-audition", _("Audition Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseAudition));
+ act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-audition", _("Audition Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseAudition));
mouse_audition_button.set_related_action (act);
mouse_audition_button.set_icon (Gtkmm2ext::ArdourIcon::ToolAudition);
mouse_audition_button.set_name ("mouse mode button");
- act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-timefx", _("Time FX Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseTimeFX));
+ act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-timefx", _("Time FX Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseTimeFX));
mouse_timefx_button.set_related_action (act);
mouse_timefx_button.set_icon (Gtkmm2ext::ArdourIcon::ToolStretch);
mouse_timefx_button.set_name ("mouse mode button");
- act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-content", _("Content Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseContent));
+ act = ActionManager::register_radio_action (mouse_mode_actions, mouse_mode_group, "set-mouse-mode-content", _("Content Tool"), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseContent));
mouse_content_button.set_related_action (act);
mouse_content_button.set_icon (Gtkmm2ext::ArdourIcon::ToolContent);
mouse_content_button.set_name ("mouse mode button");
@@ -502,7 +502,7 @@ Editor::register_actions ()
mouse_cut_button.set_icon (Gtkmm2ext::ArdourIcon::ToolCut);
mouse_cut_button.set_name ("mouse mode button");
}
-
+
ActionManager::register_action (editor_actions, "step-mouse-mode", _("Step Mouse Mode"), sigc::bind (sigc::mem_fun(*this, &Editor::step_mouse_mode), true));
RadioAction::Group edit_point_group;
@@ -601,7 +601,7 @@ Editor::register_actions ()
/* set defaults here */
no_ruler_shown_update = true;
-
+
if (Profile->get_trx()) {
ruler_marker_action->set_active (true);
ruler_meter_action->set_active (false);
@@ -613,7 +613,7 @@ Editor::register_actions ()
ruler_cd_marker_action->set_active (false);
ruler_timecode_action->set_active (false);
ruler_minsec_action->set_active (true);
- } else {
+ } else {
ruler_marker_action->set_active (true);
ruler_meter_action->set_active (true);
ruler_tempo_action->set_active (true);
@@ -741,7 +741,7 @@ void
Editor::load_bindings ()
{
/* XXX move this to a better place */
-
+
key_bindings.set_action_map (editor_action_map);
std::string binding_file;
@@ -1632,7 +1632,7 @@ void
Editor::toggle_sound_midi_notes ()
{
Glib::RefPtr<Action> act = ActionManager::get_action (X_("Editor"), X_("sound-midi-notes"));
-
+
if (act) {
bool s = UIConfiguration::instance().get_sound_midi_notes();
Glib::RefPtr<ToggleAction> tact = Glib::RefPtr<ToggleAction>::cast_dynamic (act);
diff --git a/gtk2_ardour/editor_canvas.cc b/gtk2_ardour/editor_canvas.cc
index 13fd6fe8b9..36c9e34102 100644
--- a/gtk2_ardour/editor_canvas.cc
+++ b/gtk2_ardour/editor_canvas.cc
@@ -128,7 +128,7 @@ Editor::initialize_canvas ()
_trackview_group = new ArdourCanvas::Container (hv_scroll_group);
CANVAS_DEBUG_NAME (_trackview_group, "Canvas TrackViews");
-
+
// used as rubberband rect
rubberband_rect = new ArdourCanvas::Rectangle (hv_scroll_group, ArdourCanvas::Rect (0.0, 0.0, 0.0, 0.0));
rubberband_rect->hide();
@@ -140,7 +140,7 @@ Editor::initialize_canvas ()
CANVAS_DEBUG_NAME (_drag_motion_group, "Canvas Drag Motion");
/* TIME BAR CANVAS */
-
+
_time_markers_group = new ArdourCanvas::Container (h_scroll_group);
CANVAS_DEBUG_NAME (_time_markers_group, "time bars");
@@ -187,7 +187,7 @@ Editor::initialize_canvas ()
cd_marker_bar->set_outline_what (ArdourCanvas::Rectangle::BOTTOM);
ARDOUR_UI::instance()->video_timeline = new VideoTimeLine(this, videotl_group, (timebar_height * videotl_bar_height));
-
+
cd_marker_bar_drag_rect = new ArdourCanvas::Rectangle (cd_marker_group, ArdourCanvas::Rect (0.0, 0.0, 100, timebar_height));
CANVAS_DEBUG_NAME (cd_marker_bar_drag_rect, "cd marker drag");
cd_marker_bar_drag_rect->set_outline (false);
@@ -401,7 +401,7 @@ void
Editor::drop_paths_part_two (const vector<string>& paths, framepos_t frame, double ypos, bool copy)
{
RouteTimeAxisView* tv;
-
+
/* MIDI files must always be imported, because we consider them
* writable. So split paths into two vectors, and follow the import
* path on the MIDI part.
@@ -427,7 +427,7 @@ Editor::drop_paths_part_two (const vector<string>& paths, framepos_t frame, doub
frame = 0;
InstrumentSelector is; // instantiation builds instrument-list and sets default.
do_import (midi_paths, Editing::ImportDistinctFiles, ImportAsTrack, SrcBest, frame, is.selected_instrument());
-
+
if (Profile->get_sae() || UIConfiguration::instance().get_only_copy_imported_files() || copy) {
do_import (audio_paths, Editing::ImportDistinctFiles, Editing::ImportAsTrack, SrcBest, frame);
} else {
@@ -520,13 +520,13 @@ Editor::maybe_autoscroll (bool allow_horiz, bool allow_vert, bool from_headers)
if (from_headers) {
alloc = controls_layout.get_allocation ();
- } else {
+ } else {
alloc = _track_canvas_viewport->get_allocation ();
/* reduce height by the height of the timebars, which happens
to correspond to the position of the hv_scroll_group.
*/
-
+
alloc.set_height (alloc.get_height() - hv_scroll_group->position().y);
alloc.set_y (alloc.get_y() + hv_scroll_group->position().y);
@@ -539,21 +539,21 @@ Editor::maybe_autoscroll (bool allow_horiz, bool allow_vert, bool from_headers)
/* the effective width of the autoscroll boundary so
that we start scrolling before we hit the edge.
-
+
this helps when the window is slammed up against the
right edge of the screen, making it hard to scroll
effectively.
*/
-
+
if (alloc.get_width() > 20) {
alloc.set_width (alloc.get_width() - 20);
alloc.set_x (alloc.get_x() + 10);
}
}
-
+
scrolling_boundary = ArdourCanvas::Rect (alloc.get_x(), alloc.get_y(), alloc.get_x() + alloc.get_width(), alloc.get_y() + alloc.get_height());
-
+
int x, y;
Gdk::ModifierType mask;
@@ -607,7 +607,7 @@ Editor::autoscroll_canvas ()
no_stop = true;
} else if (x < autoscroll_boundary.x0) {
-
+
dx = autoscroll_boundary.x0 - x;
dx += 10 + (2 * (autoscroll_cnt/2));
@@ -621,7 +621,7 @@ Editor::autoscroll_canvas ()
no_stop = true;
}
-
+
if (new_frame != leftmost_frame) {
vc.time_origin = new_frame;
vc.add (VisualChange::TimeOrigin);
@@ -629,12 +629,12 @@ Editor::autoscroll_canvas ()
}
if (autoscroll_vertical_allowed) {
-
+
// const double vertical_pos = vertical_adjustment.get_value();
const int speed_factor = 10;
/* vertical */
-
+
if (y < autoscroll_boundary.y0) {
/* scroll to make higher tracks visible */
@@ -671,7 +671,7 @@ Editor::autoscroll_canvas ()
ev.type = GDK_MOTION_NOTIFY;
ev.state = Gdk::BUTTON1_MASK;
-
+
/* the motion handler expects events in canvas coordinate space */
/* we asked for the mouse position above (::get_pointer()) via
@@ -700,7 +700,7 @@ Editor::autoscroll_canvas ()
ev.y = d.y;
motion_handler (0, (GdkEvent*) &ev, true);
-
+
} else if (no_stop) {
/* not changing visual state but pointer is outside the scrolling boundary
@@ -711,7 +711,7 @@ Editor::autoscroll_canvas ()
ev.type = GDK_MOTION_NOTIFY;
ev.state = Gdk::BUTTON1_MASK;
-
+
/* the motion handler expects events in canvas coordinate space */
/* first convert from Editor window coordinates to canvas
@@ -740,7 +740,7 @@ Editor::autoscroll_canvas ()
ev.y = d.y;
motion_handler (0, (GdkEvent*) &ev, true);
-
+
} else {
stop_canvas_autoscroll ();
return false;
@@ -749,7 +749,7 @@ Editor::autoscroll_canvas ()
autoscroll_cnt++;
return true; /* call me again */
-}
+}
void
Editor::start_canvas_autoscroll (bool allow_horiz, bool allow_vert, const ArdourCanvas::Rect& boundary)
@@ -895,7 +895,7 @@ Editor::color_handler()
samples_ruler->set_outline_color (text);
bbt_ruler->set_fill_color (base);
bbt_ruler->set_outline_color (text);
-
+
playhead_cursor->set_color (UIConfiguration::instance().color ("play head"));
meter_bar->set_fill_color (UIConfiguration::instance().color_mod ("meter bar", "marker bar"));
@@ -1082,9 +1082,9 @@ Editor::which_trim_cursor (bool left) const
}
Trimmable::CanTrim ct = entered_regionview->region()->can_trim ();
-
+
if (left) {
-
+
if (ct & Trimmable::FrontTrimEarlier) {
return _cursors->left_side_trim;
} else {
@@ -1112,7 +1112,7 @@ Editor::which_mode_cursor () const
case MouseCut:
mode_cursor = _cursors->scissors;
break;
-
+
case MouseObject:
case MouseContent:
/* don't use mode cursor, pick a grabber cursor based on the item */
@@ -1138,20 +1138,20 @@ Editor::which_mode_cursor () const
get_pointer_position (x, y);
if (x >= 0 && y >= 0) {
-
+
vector<ArdourCanvas::Item const *> items;
/* Note how we choose a specific scroll group to get
* items from. This could be problematic.
*/
-
+
hv_scroll_group->add_items_at_point (ArdourCanvas::Duple (x,y), items);
-
+
// first item will be the upper most
-
+
if (!items.empty()) {
const ArdourCanvas::Item* i = items.front();
-
+
if (i && i->parent() && i->parent()->get_data (X_("timeselection"))) {
pair<TimeAxisView*, int> tvp = trackview_by_y_position (_last_motion_y);
if (dynamic_cast<AutomationTimeAxisView*> (tvp.first)) {
@@ -1200,7 +1200,7 @@ Editor::which_canvas_cursor(ItemType type) const
break;
}
}
-
+
if ((mouse_mode == MouseObject || get_smart_mode ()) ||
mouse_mode == MouseContent) {
@@ -1296,7 +1296,7 @@ Editor::which_canvas_cursor(ItemType type) const
}
} else if (mouse_mode == MouseDraw) {
-
+
/* ControlPointItem is not really specific to region gain mode
but it is the same cursor so don't worry about this for now.
The result is that we'll see the fader cursor if we enter
diff --git a/gtk2_ardour/editor_canvas_events.cc b/gtk2_ardour/editor_canvas_events.cc
index 2527a1597c..5a8abad6f1 100644
--- a/gtk2_ardour/editor_canvas_events.cc
+++ b/gtk2_ardour/editor_canvas_events.cc
@@ -67,7 +67,7 @@ Editor::track_canvas_scroll (GdkEventScroll* ev)
if (Keyboard::some_magic_widget_has_focus()) {
return false;
}
-
+
framepos_t xdelta;
int direction = ev->direction;
@@ -329,7 +329,7 @@ Editor::canvas_wave_view_event (GdkEvent *event, ArdourCanvas::Item* item, Regio
}
return ret;
-}
+}
bool
@@ -1036,7 +1036,7 @@ Editor::canvas_ruler_event (GdkEvent *event, ArdourCanvas::Item* item, ItemType
bool handled = false;
if (event->type == GDK_SCROLL) {
-
+
/* scroll events in the rulers are handled a little differently from
scrolling elsewhere in the canvas.
*/
@@ -1055,7 +1055,7 @@ Editor::canvas_ruler_event (GdkEvent *event, ArdourCanvas::Item* item, ItemType
}
handled = true;
break;
-
+
case GDK_SCROLL_DOWN:
if (Profile->get_mixbus()) {
//for mouse-wheel zoom, force zoom-focus to mouse
@@ -1068,7 +1068,7 @@ Editor::canvas_ruler_event (GdkEvent *event, ArdourCanvas::Item* item, ItemType
}
handled = true;
break;
-
+
case GDK_SCROLL_LEFT:
xdelta = (current_page_samples() / 2);
if (leftmost_frame > xdelta) {
@@ -1078,7 +1078,7 @@ Editor::canvas_ruler_event (GdkEvent *event, ArdourCanvas::Item* item, ItemType
}
handled = true;
break;
-
+
case GDK_SCROLL_RIGHT:
xdelta = (current_page_samples() / 2);
if (max_framepos - xdelta > leftmost_frame) {
@@ -1088,7 +1088,7 @@ Editor::canvas_ruler_event (GdkEvent *event, ArdourCanvas::Item* item, ItemType
}
handled = true;
break;
-
+
default:
/* what? */
break;
@@ -1130,9 +1130,9 @@ Editor::canvas_note_event (GdkEvent *event, ArdourCanvas::Item* item)
bool
Editor::canvas_drop_zone_event (GdkEvent* event)
{
- GdkEventScroll scroll;
+ GdkEventScroll scroll;
ArdourCanvas::Duple winpos;
-
+
switch (event->type) {
case GDK_BUTTON_RELEASE:
if (event->button.button == 1) {
@@ -1193,18 +1193,18 @@ Editor::track_canvas_drag_motion (Glib::RefPtr<Gdk::DragContext> const& context,
std::pair<TimeAxisView*, int> const tv = trackview_by_y_position (py, false);
bool can_drop = false;
-
+
if (tv.first != 0) {
/* over a time axis view of some kind */
rtav = dynamic_cast<RouteTimeAxisView*> (tv.first);
-
+
if (rtav != 0 && rtav->is_track ()) {
/* over a track, not a bus */
can_drop = true;
}
-
+
} else {
/* not over a time axis view, so drop is possible */
@@ -1213,7 +1213,7 @@ Editor::track_canvas_drag_motion (Glib::RefPtr<Gdk::DragContext> const& context,
if (can_drop) {
region = _regions->get_dragged_region ();
-
+
if (region) {
if (tv.first == 0
@@ -1227,17 +1227,17 @@ Editor::track_canvas_drag_motion (Glib::RefPtr<Gdk::DragContext> const& context,
context->drag_status (context->get_suggested_action(), time);
return true;
}
-
+
if ((boost::dynamic_pointer_cast<AudioRegion> (region) != 0 &&
dynamic_cast<AudioTimeAxisView*> (tv.first) != 0) ||
(boost::dynamic_pointer_cast<MidiRegion> (region) != 0 &&
dynamic_cast<MidiTimeAxisView*> (tv.first) != 0)) {
-
+
/* audio to audio
OR
midi to midi
*/
-
+
context->drag_status (context->get_suggested_action(), time);
return true;
}
diff --git a/gtk2_ardour/editor_cursors.cc b/gtk2_ardour/editor_cursors.cc
index 9cabbce56b..40245778d5 100644
--- a/gtk2_ardour/editor_cursors.cc
+++ b/gtk2_ardour/editor_cursors.cc
@@ -49,7 +49,7 @@ EditorCursor::EditorCursor (Editor& ed, bool (Editor::*callbck)(GdkEvent*,Ardour
_track_canvas_item->set_y1 (ArdourCanvas::COORD_MAX);
_track_canvas_item->set_x (0);
-
+
_current_frame = 1; /* force redraw at 0 */
}
@@ -63,7 +63,7 @@ EditorCursor::EditorCursor (Editor& ed)
_track_canvas_item->set_show_head (1, false);
_track_canvas_item->set_y1 (ArdourCanvas::COORD_MAX);
_track_canvas_item->set_ignore_events (true);
-
+
_track_canvas_item->set_x (0);
_current_frame = 1; /* force redraw at 0 */
diff --git a/gtk2_ardour/editor_cursors.h b/gtk2_ardour/editor_cursors.h
index d7e856c9e5..f841f0c778 100644
--- a/gtk2_ardour/editor_cursors.h
+++ b/gtk2_ardour/editor_cursors.h
@@ -50,7 +50,7 @@ class EditorCursor {
PBD::Signal1<void, framepos_t> PositionChanged;
- private:
+ private:
Editor& _editor;
ArdourCanvas::Arrow* _track_canvas_item;
framepos_t _current_frame;
diff --git a/gtk2_ardour/editor_drag.cc b/gtk2_ardour/editor_drag.cc
index 376cebfd49..d5466a1ed5 100644
--- a/gtk2_ardour/editor_drag.cc
+++ b/gtk2_ardour/editor_drag.cc
@@ -4969,7 +4969,7 @@ SelectionDrag::finished (GdkEvent* event, bool movement_occurred)
s->clear_range_selection ();
}
}
-
+
} else {
/* just a click, no pointer movement.
*/
diff --git a/gtk2_ardour/editor_drag.h b/gtk2_ardour/editor_drag.h
index b4d5994a63..2d4ad30668 100644
--- a/gtk2_ardour/editor_drag.h
+++ b/gtk2_ardour/editor_drag.h
@@ -202,7 +202,7 @@ public:
bool initially_vertical() const {
return _initially_vertical;
}
-
+
/** Set up the _pointer_frame_offset */
virtual void setup_pointer_frame_offset () {
_pointer_frame_offset = 0;
@@ -582,7 +582,7 @@ public:
private:
double y_to_region (double) const;
ARDOUR::framecnt_t grid_frames (framepos_t) const;
-
+
MidiRegionView* _region_view;
ArdourCanvas::Rectangle* _drag_rect;
framepos_t _note[2];
@@ -675,7 +675,7 @@ public:
private:
Operation _operation;
-
+
bool _preserve_fade_anchor;
bool _jump_position_when_done;
};
@@ -932,7 +932,7 @@ public:
* @param drag_in_progress true if the drag is currently happening.
*/
virtual void select_things (int button_state, framepos_t x1, framepos_t x2, double y1, double y2, bool drag_in_progress) = 0;
-
+
virtual void deselect_things () = 0;
protected:
@@ -1042,7 +1042,7 @@ public:
RangeMarkerBarDrag (Editor *, ArdourCanvas::Item *, Operation);
~RangeMarkerBarDrag ();
-
+
void start_grab (GdkEvent *, Gdk::Cursor* c = 0);
void motion (GdkEvent *, bool);
void finished (GdkEvent *, bool);
@@ -1134,7 +1134,7 @@ class CrossfadeEdgeDrag : public Drag
void motion (GdkEvent*, bool);
void finished (GdkEvent*, bool);
void aborted (bool);
-
+
bool y_movement_matters () const {
return false;
}
diff --git a/gtk2_ardour/editor_export_audio.cc b/gtk2_ardour/editor_export_audio.cc
index 0d1f055c80..15592035e5 100644
--- a/gtk2_ardour/editor_export_audio.cc
+++ b/gtk2_ardour/editor_export_audio.cc
@@ -114,16 +114,16 @@ Editor::export_region ()
boost::shared_ptr<Region> r = selection->regions.front()->region();
boost::shared_ptr<AudioRegion> audio_region = boost::dynamic_pointer_cast<AudioRegion>(r);
boost::shared_ptr<MidiRegion> midi_region = boost::dynamic_pointer_cast<MidiRegion>(r);
-
+
if (audio_region) {
-
+
RouteTimeAxisView & rtv (dynamic_cast<RouteTimeAxisView &> (selection->regions.front()->get_time_axis_view()));
AudioTrack & track (dynamic_cast<AudioTrack &> (*rtv.route()));
-
+
ExportRegionDialog dialog (*this, *(audio_region.get()), track);
dialog.set_session (_session);
dialog.run ();
-
+
} else if (midi_region) {
MidiExportDialog dialog (*this, midi_region);
@@ -146,13 +146,13 @@ Editor::export_region ()
true,
Gtk::MESSAGE_WARNING,
Gtk::BUTTONS_NONE);
-
+
checker.set_title (_("File Exists!"));
checker.add_button (Stock::CANCEL, RESPONSE_CANCEL);
checker.add_button (_("Overwrite Existing File"), RESPONSE_ACCEPT);
checker.set_default_response (RESPONSE_CANCEL);
-
+
checker.set_wmclass (X_("midi_export_file_exists"), PROGRAM_NAME);
checker.set_position (Gtk::WIN_POS_MOUSE);
@@ -169,7 +169,7 @@ Editor::export_region ()
default:
return;
}
-
+
}
(void) midi_region->clone (path);
diff --git a/gtk2_ardour/editor_group_tabs.cc b/gtk2_ardour/editor_group_tabs.cc
index a4043b7a19..48fe9e231d 100644
--- a/gtk2_ardour/editor_group_tabs.cc
+++ b/gtk2_ardour/editor_group_tabs.cc
@@ -91,7 +91,7 @@ EditorGroupTabs::draw_tab (cairo_t* cr, Tab const & tab) const
{
double const arc_radius = get_width();
double r, g, b, a;
-
+
if (tab.group && tab.group->is_active()) {
ArdourCanvas::color_to_rgba (tab.color, r, g, b, a);
} else {
diff --git a/gtk2_ardour/editor_keys.cc b/gtk2_ardour/editor_keys.cc
index 2548a68ab4..a2ee357436 100644
--- a/gtk2_ardour/editor_keys.cc
+++ b/gtk2_ardour/editor_keys.cc
@@ -45,7 +45,7 @@ Editor::keyboard_selection_finish (bool /*add*/)
framepos_t start = selection->time.start();
framepos_t end;
-
+
if ((_edit_point == EditAtPlayhead) && _session->transport_rolling()) {
end = _session->audible_frame();
} else {
@@ -54,7 +54,7 @@ Editor::keyboard_selection_finish (bool /*add*/)
//snap the selection start/end
snap_to(start);
-
+
//if no tracks are selected and we're working from the keyboard, enable all tracks (_something_ has to be selected for any range selection)
if ( (_edit_point == EditAtPlayhead) && selection->tracks.empty() )
select_all_tracks();
@@ -81,19 +81,19 @@ Editor::keyboard_selection_begin ()
} else {
start = get_preferred_edit_position();
}
-
+
//snap the selection start/end
snap_to(start);
-
+
//if there's not already a sensible selection endpoint, go "forever"
if ( start > end ) {
end = max_framepos;
}
-
+
//if no tracks are selected and we're working from the keyboard, enable all tracks (_something_ has to be selected for any range selection)
if ( selection->tracks.empty() )
select_all_tracks();
-
+
selection->set (start, end);
//if session is playing a range, cancel that
diff --git a/gtk2_ardour/editor_markers.cc b/gtk2_ardour/editor_markers.cc
index a8663edf6f..201631e8c5 100644
--- a/gtk2_ardour/editor_markers.cc
+++ b/gtk2_ardour/editor_markers.cc
@@ -68,7 +68,7 @@ Editor::add_new_location (Location *location)
/* Do a full update of the markers in this group */
update_marker_labels (group);
-
+
if (location->is_auto_punch()) {
update_punch_range_view ();
}
@@ -965,7 +965,7 @@ Editor::build_range_marker_menu (bool loop_or_punch, bool session)
if (!loop_or_punch_or_session || !session) {
items.push_back (SeparatorElem());
}
-
+
items.push_back (MenuElem (_("Separate Regions in Range"), sigc::mem_fun(*this, &Editor::marker_menu_separate_regions_using_location)));
items.push_back (MenuElem (_("Select All in Range"), sigc::mem_fun(*this, &Editor::marker_menu_select_all_selectables_using_range)));
if (!Profile->get_sae()) {
@@ -1216,7 +1216,7 @@ Editor::marker_menu_set_from_selection (bool /*force_regions*/)
// nothing for now
} else {
-
+
if (!selection->time.empty()) {
l->set (selection->time.start(), selection->time.end_frame());
} else if (!selection->regions.empty()) {
@@ -1295,7 +1295,7 @@ Editor::marker_menu_zoom_to_range ()
if (a >= extra) {
a -= extra;
}
-
+
framepos_t b = l->end ();
if (b < (max_framepos - extra)) {
b += extra;
@@ -1480,7 +1480,7 @@ Editor::update_loop_range_view ()
transport_loop_range_rect->set_x1 (x2);
transport_loop_range_rect->show();
-
+
} else {
transport_loop_range_rect->hide();
}
@@ -1499,7 +1499,7 @@ Editor::update_punch_range_view ()
double pixel_start;
double pixel_end;
-
+
if (_session->config.get_punch_in()) {
pixel_start = sample_to_pixel (tpl->start());
} else {
@@ -1510,9 +1510,9 @@ Editor::update_punch_range_view ()
} else {
pixel_end = sample_to_pixel (max_framepos);
}
-
+
transport_punch_range_rect->set_x0 (pixel_start);
- transport_punch_range_rect->set_x1 (pixel_end);
+ transport_punch_range_rect->set_x1 (pixel_end);
transport_punch_range_rect->show();
} else {
diff --git a/gtk2_ardour/editor_mixer.cc b/gtk2_ardour/editor_mixer.cc
index 5871b5709a..9769d616fe 100644
--- a/gtk2_ardour/editor_mixer.cc
+++ b/gtk2_ardour/editor_mixer.cc
@@ -80,7 +80,7 @@ Editor::show_editor_mixer (bool yn)
if (yn) {
Glib::RefPtr<Gdk::Window> win = get_window ();
Glib::RefPtr<Gdk::Screen> screen;
-
+
if (win) {
screen = win->get_screen();
} else {
@@ -184,7 +184,7 @@ Editor::create_editor_mixer ()
current_mixer_strip->WidthChanged.connect (sigc::mem_fun(*this, &Editor::ensure_all_elements_drawn));
#endif
current_mixer_strip->set_embedded (true);
-
+
}
void
diff --git a/gtk2_ardour/editor_mouse.cc b/gtk2_ardour/editor_mouse.cc
index 18478cdaac..094afc2692 100644
--- a/gtk2_ardour/editor_mouse.cc
+++ b/gtk2_ardour/editor_mouse.cc
@@ -207,7 +207,7 @@ void
Editor::mouse_mode_object_range_toggled()
{
MouseMode m = mouse_mode;
-
+
Glib::RefPtr<Action> act = ActionManager::get_action (X_("MouseMode"), X_("set-mouse-mode-range"));
assert (act);
Glib::RefPtr<ToggleAction> tact = Glib::RefPtr<ToggleAction>::cast_dynamic (act);
@@ -313,7 +313,7 @@ Editor::mouse_mode_toggled (MouseMode m)
}
set_gain_envelope_visibility ();
-
+
update_time_selection_display ();
update_all_enter_cursors ();
@@ -1229,17 +1229,17 @@ Editor::button_release_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemT
case TempoMarkerItem: {
ArdourMarker* marker;
TempoMarker* tempo_marker;
-
+
if ((marker = reinterpret_cast<ArdourMarker *> (item->get_data ("marker"))) == 0) {
fatal << _("programming error: tempo marker canvas item has no marker object pointer!") << endmsg;
abort(); /*NOTREACHED*/
}
-
+
if ((tempo_marker = dynamic_cast<TempoMarker*> (marker)) == 0) {
fatal << _("programming error: marker for tempo is not a tempo marker!") << endmsg;
abort(); /*NOTREACHED*/
}
-
+
edit_tempo_marker (*tempo_marker);
break;
}
@@ -1247,12 +1247,12 @@ Editor::button_release_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemT
case MeterMarkerItem: {
ArdourMarker* marker;
MeterMarker* meter_marker;
-
+
if ((marker = reinterpret_cast<ArdourMarker *> (item->get_data ("marker"))) == 0) {
fatal << _("programming error: tempo marker canvas item has no marker object pointer!") << endmsg;
abort(); /*NOTREACHED*/
}
-
+
if ((meter_marker = dynamic_cast<MeterMarker*> (marker)) == 0) {
fatal << _("programming error: marker for meter is not a meter marker!") << endmsg;
abort(); /*NOTREACHED*/
@@ -1320,7 +1320,7 @@ Editor::button_release_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemT
case SelectionItem:
popup_track_context_menu (1, event->button.time, item_type, true);
break;
-
+
case AutomationTrackItem:
popup_track_context_menu (1, event->button.time, item_type, false);
break;
@@ -1549,7 +1549,7 @@ Editor::button_release_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemT
case MouseDraw:
return true;
-
+
case MouseRange:
// x_style_paste (where, 1.0);
return true;
@@ -1880,14 +1880,14 @@ Editor::motion_handler (ArdourCanvas::Item* /*item*/, GdkEvent* event, bool from
current_stepping_trackview = 0;
step_timeout.disconnect ();
}
-
+
if (_session && _session->actively_recording()) {
/* Sorry. no dragging stuff around while we record */
return true;
}
-
+
update_join_object_range_location (event->motion.y);
-
+
if (_drags->active ()) {
return _drags->motion_handler (event, from_autoscroll);
}
@@ -2064,7 +2064,7 @@ Editor::cancel_time_selection ()
}
selection->time.clear ();
clicked_selection = 0;
-}
+}
void
Editor::point_trim (GdkEvent* event, framepos_t new_bound)
@@ -2386,7 +2386,7 @@ Editor::update_join_object_range_location (double y)
} else if (entered_track) {
RouteTimeAxisView* entered_route_view = dynamic_cast<RouteTimeAxisView*> (entered_track);
-
+
if (entered_route_view) {
double cx = 0;
diff --git a/gtk2_ardour/editor_ops.cc b/gtk2_ardour/editor_ops.cc
index 1ce3915131..e8174ce9e6 100644
--- a/gtk2_ardour/editor_ops.cc
+++ b/gtk2_ardour/editor_ops.cc
@@ -119,7 +119,7 @@ Editor::undo (uint32_t n)
if (_drags->active ()) {
_drags->abort ();
}
-
+
if (_session) {
_session->undo (n);
if (_session->undo_depth() == 0) {
@@ -136,7 +136,7 @@ Editor::redo (uint32_t n)
if (_drags->active ()) {
_drags->abort ();
}
-
+
if (_session) {
_session->redo (n);
if (_session->redo_depth() == 0) {
@@ -237,7 +237,7 @@ Editor::split_regions_at (framepos_t where, RegionSelection& regions)
for (list<RouteTimeAxisView*>::iterator i = used_trackviews.begin(); i != used_trackviews.end(); ++i) {
region_added_connections.push_back ((*i)->view()->RegionViewAdded.connect (sigc::mem_fun(*this, &Editor::collect_new_region_view)));
}
-
+
while (used_playlists.size() > 0) {
list <boost::shared_ptr<Playlist > >::iterator i = used_playlists.begin();
(*i)->thaw();
@@ -713,7 +713,7 @@ Editor::build_region_boundary_cache ()
TimeAxisView *ontrack = 0;
TrackViewList tlist;
-
+
if (!selection->tracks.empty()) {
tlist = selection->tracks.filter_to_unique_playlists ();
} else {
@@ -1487,21 +1487,21 @@ Editor::scroll_down_one_track (bool skip_child_views)
}
/* move to the track below the first one that covers the */
-
+
if (next != track_views.rend()) {
ensure_time_axis_view_is_visible (**next, true);
return true;
}
return false;
-}
+}
bool
Editor::scroll_up_one_track (bool skip_child_views)
{
TrackViewList::iterator prev = track_views.end();
double top_of_trackviews = vertical_adjustment.get_value ();
-
+
for (TrackViewList::iterator t = track_views.begin(); t != track_views.end(); ++t) {
if ((*t)->hidden()) {
@@ -1513,7 +1513,7 @@ Editor::scroll_up_one_track (bool skip_child_views)
* Note that covers_y_position() is recursive and includes child views
*/
std::pair<TimeAxisView*,double> res = (*t)->covers_y_position (top_of_trackviews);
-
+
if (res.first) {
if (skip_child_views) {
break;
@@ -1562,7 +1562,7 @@ Editor::scroll_up_one_track (bool skip_child_views)
prev = t;
}
-
+
if (prev != track_views.end()) {
// move to bottom-most automation-lane of the previous track
TimeAxisView::Children kids = (*prev)->get_child_list();
@@ -1601,7 +1601,7 @@ Editor::tav_zoom_step (bool coarser)
} else {
ts = &selection->tracks;
}
-
+
for (TrackViewList::iterator i = ts->begin(); i != ts->end(); ++i) {
TimeAxisView *tv = (static_cast<TimeAxisView*>(*i));
tv->step_height (coarser);
@@ -1620,7 +1620,7 @@ Editor::tav_zoom_smooth (bool coarser, bool force_all)
} else {
ts = &selection->tracks;
}
-
+
for (TrackViewList::iterator i = ts->begin(); i != ts->end(); ++i) {
TimeAxisView *tv = (static_cast<TimeAxisView*>(*i));
uint32_t h = tv->current_height ();
@@ -1825,7 +1825,7 @@ Editor::temporal_zoom_region (bool both_axes)
if ( !get_selection_extents(start, end) )
return;
-
+
calc_extra_zoom_edges (start, end);
/* if we're zooming on both axes we need to save track heights etc.
@@ -1836,7 +1836,7 @@ Editor::temporal_zoom_region (bool both_axes)
PBD::Unwinder<bool> nsv (no_save_visual, true);
temporal_zoom_by_frame (start, end);
-
+
if (both_axes) {
uint32_t per_track_height = (uint32_t) floor ((_visible_canvas_height - 10.0) / tracks.size());
@@ -1869,7 +1869,7 @@ Editor::get_selection_extents ( framepos_t &start, framepos_t &end )
start = max_framepos;
end = 0;
bool ret = true;
-
+
//ToDo: if notes are selected, set extents to that selection
//ToDo: if control points are selected, set extents to that selection
@@ -1898,8 +1898,8 @@ Editor::get_selection_extents ( framepos_t &start, framepos_t &end )
if ((start == 0 && end == 0) || end < start) {
ret = false;
}
-
- return ret;
+
+ return ret;
}
@@ -1924,7 +1924,7 @@ Editor::temporal_zoom_selection (bool both_axes)
calc_extra_zoom_edges(start, end);
temporal_zoom_by_frame (start, end);
}
-
+
if (both_axes)
fit_selection();
}
@@ -1974,7 +1974,7 @@ Editor::temporal_zoom_by_frame (framepos_t start, framepos_t end)
framepos_t range = end - start;
const framecnt_t new_fpp = (framecnt_t) ceil ((double) range / (double) _visible_canvas_width);
-
+
framepos_t new_page = range;
framepos_t middle = (framepos_t) floor ((double) start + ((double) range / 2.0f));
framepos_t new_leftmost = (framepos_t) floor ((double) middle - ((double) new_page / 2.0f));
@@ -2027,7 +2027,7 @@ Editor::temporal_zoom_to_frame (bool coarser, framepos_t frame)
/* zoom focus is automatically taken as @param frame when this
method is used.
*/
-
+
framepos_t new_leftmost = frame - (framepos_t)range_before;
if (new_leftmost > frame) {
@@ -2098,12 +2098,12 @@ Editor::add_location_from_selection ()
Location *location = new Location (*_session, start, end, rangename, Location::IsRangeMarker);
begin_reversible_command (_("add marker"));
-
+
XMLNode &before = _session->locations()->get_state();
_session->locations()->add (location, true);
XMLNode &after = _session->locations()->get_state();
_session->add_command(new MementoCommand<Locations>(*(_session->locations()), &before, &after));
-
+
commit_reversible_command ();
}
@@ -2120,12 +2120,12 @@ Editor::add_location_mark (framepos_t where)
}
Location *location = new Location (*_session, where, where, markername, Location::IsMark);
begin_reversible_command (_("add marker"));
-
+
XMLNode &before = _session->locations()->get_state();
_session->locations()->add (location, true);
XMLNode &after = _session->locations()->get_state();
_session->add_command(new MementoCommand<Locations>(*(_session->locations()), &before, &after));
-
+
commit_reversible_command ();
}
@@ -2134,7 +2134,7 @@ Editor::set_session_start_from_playhead ()
{
if (!_session)
return;
-
+
Location* loc;
if ((loc = _session->locations()->session_range_location()) == 0) { //should never happen
_session->set_session_extents ( _session->audible_frame(), _session->audible_frame() );
@@ -2146,7 +2146,7 @@ Editor::set_session_start_from_playhead ()
XMLNode &after = loc->get_state();
begin_reversible_command (_("Set session start"));
-
+
_session->add_command (new MementoCommand<Location>(*loc, &before, &after));
commit_reversible_command ();
@@ -2158,7 +2158,7 @@ Editor::set_session_end_from_playhead ()
{
if (!_session)
return;
-
+
Location* loc;
if ((loc = _session->locations()->session_range_location()) == 0) { //should never happen
_session->set_session_extents ( _session->audible_frame(), _session->audible_frame() );
@@ -2200,7 +2200,7 @@ Editor::remove_location_at_playhead_cursor ()
removed = true;
}
}
-
+
//store undo
if (removed) {
begin_reversible_command (_("remove marker"));
@@ -2221,7 +2221,7 @@ Editor::add_locations_from_region ()
return;
}
bool commit = false;
-
+
XMLNode &before = _session->locations()->get_state();
for (RegionSelection::iterator i = rs.begin (); i != rs.end (); ++i) {
@@ -2292,7 +2292,7 @@ Editor::jump_forward_to_mark ()
if (pos < 0) {
return;
}
-
+
_session->request_locate (pos, _session->transport_rolling());
}
@@ -2332,12 +2332,12 @@ Editor::clear_markers ()
{
if (_session) {
begin_reversible_command (_("clear markers"));
-
+
XMLNode &before = _session->locations()->get_state();
_session->locations()->clear_markers ();
XMLNode &after = _session->locations()->get_state();
_session->add_command(new MementoCommand<Locations>(*(_session->locations()), &before, &after));
-
+
commit_reversible_command ();
}
}
@@ -2347,14 +2347,14 @@ Editor::clear_ranges ()
{
if (_session) {
begin_reversible_command (_("clear ranges"));
-
+
XMLNode &before = _session->locations()->get_state();
_session->locations()->clear_ranges ();
XMLNode &after = _session->locations()->get_state();
_session->add_command(new MementoCommand<Locations>(*(_session->locations()), &before, &after));
-
+
commit_reversible_command ();
}
}
@@ -2363,12 +2363,12 @@ void
Editor::clear_locations ()
{
begin_reversible_command (_("clear locations"));
-
+
XMLNode &before = _session->locations()->get_state();
_session->locations()->clear ();
XMLNode &after = _session->locations()->get_state();
_session->add_command(new MementoCommand<Locations>(*(_session->locations()), &before, &after));
-
+
commit_reversible_command ();
}
@@ -2541,11 +2541,11 @@ Editor::maybe_locate_with_edit_preroll ( framepos_t location )
return;
location -= get_preroll();
-
+
//don't try to locate before the beginning of time
if ( location < 0 )
location = 0;
-
+
//if follow_playhead is on, keep the playhead on the screen
if ( _follow_playhead )
if ( location < leftmost_frame )
@@ -2559,16 +2559,16 @@ Editor::play_with_preroll ()
{
{
framepos_t preroll = get_preroll();
-
+
framepos_t start, end;
if (!get_selection_extents ( start, end))
return;
if (start > preroll)
start = start - preroll;
-
+
end = end + preroll; //"post-roll"
-
+
AudioRange ar (start, end, 0);
list<AudioRange> lar;
lar.push_back (ar);
@@ -2629,7 +2629,7 @@ Editor::do_layer_operation (LayerOperation op)
begin_reversible_command (_("raise region to top"));
}
break;
-
+
case Lower:
if (multiple) {
begin_reversible_command (_("lower regions"));
@@ -2637,7 +2637,7 @@ Editor::do_layer_operation (LayerOperation op)
begin_reversible_command (_("lower region"));
}
break;
-
+
case LowerToBottom:
if (multiple) {
begin_reversible_command (_("lower regions to bottom"));
@@ -2651,7 +2651,7 @@ Editor::do_layer_operation (LayerOperation op)
for (set<boost::shared_ptr<Playlist> >::iterator i = playlists.begin(); i != playlists.end(); ++i) {
(*i)->clear_owned_changes ();
}
-
+
for (RegionSelection::iterator i = selection->regions.begin(); i != selection->regions.end(); ++i) {
boost::shared_ptr<Region> r = (*i)->region ();
switch (op) {
@@ -2674,7 +2674,7 @@ Editor::do_layer_operation (LayerOperation op)
(*i)->rdiff (cmds);
_session->add_commands (cmds);
}
-
+
commit_reversible_command ();
}
@@ -3870,7 +3870,7 @@ Editor::freeze_route ()
/* stop transport before we start. this is important */
_session->request_transport_speed (0.0);
-
+
/* wait for just a little while, because the above call is asynchronous */
Glib::usleep (250000);
@@ -4125,15 +4125,15 @@ Editor::cut_copy (CutCopyOp op)
if (!selection->regions.empty()) {
cut_copy_regions (op, selection->regions);
-
+
if (op == Cut || op == Delete) {
selection->clear_regions ();
}
}
-
+
if (!selection->points.empty()) {
cut_copy_points (op);
-
+
if (op == Cut || op == Delete) {
selection->clear_points ();
}
@@ -4151,19 +4151,19 @@ Editor::cut_copy (CutCopyOp op)
did_edit = true;
cut_copy_ranges (op);
-
+
if (op == Cut || op == Delete) {
selection->clear_time ();
}
}
-
+
if (did_edit) {
/* reset repeated paste state */
paste_count = 0;
last_paste_pos = 0;
- commit_reversible_command ();
+ commit_reversible_command ();
}
-
+
if (op == Delete || op == Cut || op == Clear) {
_drags->abort ();
}
@@ -4172,7 +4172,7 @@ Editor::cut_copy (CutCopyOp op)
struct AutomationRecord {
AutomationRecord () : state (0) , line(NULL) {}
AutomationRecord (XMLNode* s, const AutomationLine* l) : state (s) , line (l) {}
-
+
XMLNode* state; ///< state before any operation
const AutomationLine* line; ///< line this came from
boost::shared_ptr<Evoral::ControlList> copy; ///< copied events for the cut buffer
@@ -4258,10 +4258,10 @@ Editor::cut_copy_points (Editing::CutCopyOp op, Evoral::Beats earliest, bool mid
cut_buffer->add (i->second.copy);
}
}
-
+
if (op == Delete || op == Cut) {
/* This operation needs to remove things from the main AutomationList, so do that now */
-
+
for (Lists::iterator i = lists.begin(); i != lists.end(); ++i) {
i->first->freeze ();
}
@@ -4346,7 +4346,7 @@ Editor::remove_clicked_region ()
vector<Command*> cmds;
playlist->rdiff (cmds);
_session->add_commands (cmds);
-
+
_session->add_command(new StatefulDiffCommand (playlist));
commit_reversible_command ();
}
@@ -4421,7 +4421,7 @@ Editor::remove_selected_regions ()
vector<Command*> cmds;
(*pl)->rdiff (cmds);
_session->add_commands (cmds);
-
+
_session->add_command(new StatefulDiffCommand (*pl));
}
@@ -4513,15 +4513,15 @@ Editor::cut_copy_regions (CutCopyOp op, RegionSelection& rs)
if (op != Delete) {
vector<PlaylistMapping>::iterator z;
-
+
for (z = pmap.begin(); z != pmap.end(); ++z) {
if ((*z).tv == &tv) {
break;
}
}
-
+
assert (z != pmap.end());
-
+
if (!(*z).pl) {
npl = PlaylistFactory::create (pl->data_type(), *_session, "cutlist", true);
npl->freeze();
@@ -4542,7 +4542,7 @@ Editor::cut_copy_regions (CutCopyOp op, RegionSelection& rs)
if (Config->get_edit_mode() == Ripple)
pl->ripple (r->position(), -r->length(), boost::shared_ptr<Region>());
break;
-
+
case Cut:
_xx = RegionFactory::create (r);
npl->add_region (_xx, r->position() - first_position);
@@ -4569,20 +4569,20 @@ Editor::cut_copy_regions (CutCopyOp op, RegionSelection& rs)
if (op != Delete) {
list<boost::shared_ptr<Playlist> > foo;
-
+
/* the pmap is in the same order as the tracks in which selected regions occured */
-
+
for (vector<PlaylistMapping>::iterator i = pmap.begin(); i != pmap.end(); ++i) {
if ((*i).pl) {
(*i).pl->thaw();
foo.push_back ((*i).pl);
}
}
-
+
if (!foo.empty()) {
cut_buffer->set (foo);
}
-
+
if (pmap.empty()) {
_last_cut_copy_source_track = 0;
} else {
@@ -4599,7 +4599,7 @@ Editor::cut_copy_regions (CutCopyOp op, RegionSelection& rs)
vector<Command*> cmds;
(*pl)->rdiff (cmds);
_session->add_commands (cmds);
-
+
_session->add_command (new StatefulDiffCommand (*pl));
}
}
@@ -5452,7 +5452,7 @@ Editor::apply_filter (Filter& filter, string command, ProgressReporter* progress
vector<Command*> cmds;
playlist->rdiff (cmds);
_session->add_commands (cmds);
-
+
_session->add_command(new StatefulDiffCommand (playlist));
}
@@ -5486,7 +5486,7 @@ Editor::reset_region_gain_envelopes ()
}
bool in_command = false;
-
+
for (RegionSelection::iterator i = rs.begin(); i != rs.end(); ++i) {
AudioRegionView* const arv = dynamic_cast<AudioRegionView*>(*i);
if (arv) {
@@ -5580,13 +5580,13 @@ Editor::toggle_region_lock ()
}
begin_reversible_command (_("toggle region lock"));
-
+
for (RegionSelection::iterator i = rs.begin(); i != rs.end(); ++i) {
(*i)->region()->clear_changes ();
(*i)->region()->set_locked (!(*i)->region()->locked());
_session->add_command (new StatefulDiffCommand ((*i)->region()));
}
-
+
commit_reversible_command ();
}
@@ -5604,13 +5604,13 @@ Editor::toggle_region_video_lock ()
}
begin_reversible_command (_("Toggle Video Lock"));
-
+
for (RegionSelection::iterator i = rs.begin(); i != rs.end(); ++i) {
(*i)->region()->clear_changes ();
(*i)->region()->set_video_locked (!(*i)->region()->video_locked());
_session->add_command (new StatefulDiffCommand ((*i)->region()));
}
-
+
commit_reversible_command ();
}
@@ -5628,14 +5628,14 @@ Editor::toggle_region_lock_style ()
}
begin_reversible_command (_("region lock style"));
-
+
for (RegionSelection::iterator i = rs.begin(); i != rs.end(); ++i) {
(*i)->region()->clear_changes ();
PositionLockStyle const ns = (*i)->region()->position_lock_style() == AudioTime ? MusicTime : AudioTime;
(*i)->region()->set_position_lock_style (ns);
_session->add_command (new StatefulDiffCommand ((*i)->region()));
}
-
+
commit_reversible_command ();
}
@@ -5653,13 +5653,13 @@ Editor::toggle_opaque_region ()
}
begin_reversible_command (_("change region opacity"));
-
+
for (RegionSelection::iterator i = rs.begin(); i != rs.end(); ++i) {
(*i)->region()->clear_changes ();
(*i)->region()->set_opaque (!(*i)->region()->opaque());
_session->add_command (new StatefulDiffCommand ((*i)->region()));
}
-
+
commit_reversible_command ();
}
@@ -5977,7 +5977,7 @@ Editor::toggle_region_fades (int dir)
if (_ignore_region_action) {
return;
}
-
+
boost::shared_ptr<AudioRegion> ar;
bool yn = false;
@@ -6117,7 +6117,7 @@ Editor::split_region ()
//if no range was selected, try to find some regions to split
if (current_mouse_mode() == MouseObject) { //don't try this for Internal Edit, Stretch, Draw, etc.
-
+
RegionSelection rs = get_regions_from_selection_and_edit_point ();
framepos_t where = get_preferred_edit_position ();
@@ -6252,7 +6252,7 @@ Editor::set_session_extents_from_selection ()
if (_session == 0) {
return;
}
-
+
framepos_t start, end;
if (!get_selection_extents ( start, end))
return;
@@ -6282,27 +6282,27 @@ Editor::set_punch_start_from_edit_point ()
framepos_t start = 0;
framepos_t end = max_framepos;
-
+
//use the existing punch end, if any
Location* tpl = transport_punch_location();
if (tpl) {
end = tpl->end();
}
-
+
if ((_edit_point == EditAtPlayhead) && _session->transport_rolling()) {
start = _session->audible_frame();
} else {
start = get_preferred_edit_position();
}
-
+
//snap the selection start/end
snap_to(start);
-
+
//if there's not already a sensible selection endpoint, go "forever"
if ( start > end ) {
end = max_framepos;
}
-
+
set_punch_range (start, end, _("set punch start from EP"));
}
@@ -6315,13 +6315,13 @@ Editor::set_punch_end_from_edit_point ()
framepos_t start = 0;
framepos_t end = max_framepos;
-
+
//use the existing punch start, if any
Location* tpl = transport_punch_location();
if (tpl) {
start = tpl->start();
}
-
+
if ((_edit_point == EditAtPlayhead) && _session->transport_rolling()) {
end = _session->audible_frame();
} else {
@@ -6330,7 +6330,7 @@ Editor::set_punch_end_from_edit_point ()
//snap the selection start/end
snap_to(end);
-
+
set_punch_range (start, end, _("set punch end from EP"));
}
@@ -6343,22 +6343,22 @@ Editor::set_loop_start_from_edit_point ()
framepos_t start = 0;
framepos_t end = max_framepos;
-
+
//use the existing loop end, if any
Location* tpl = transport_loop_location();
if (tpl) {
end = tpl->end();
}
-
+
if ((_edit_point == EditAtPlayhead) && _session->transport_rolling()) {
start = _session->audible_frame();
} else {
start = get_preferred_edit_position();
}
-
+
//snap the selection start/end
snap_to(start);
-
+
//if there's not already a sensible selection endpoint, go "forever"
if ( start > end ) {
end = max_framepos;
@@ -6376,13 +6376,13 @@ Editor::set_loop_end_from_edit_point ()
framepos_t start = 0;
framepos_t end = max_framepos;
-
+
//use the existing loop start, if any
Location* tpl = transport_loop_location();
if (tpl) {
start = tpl->start();
}
-
+
if ((_edit_point == EditAtPlayhead) && _session->transport_rolling()) {
end = _session->audible_frame();
} else {
@@ -6391,7 +6391,7 @@ Editor::set_loop_end_from_edit_point ()
//snap the selection start/end
snap_to(end);
-
+
set_loop_range (start, end, _("set loop end from EP"));
}
}
@@ -6574,7 +6574,7 @@ Editor::split_region_at_transients ()
}
begin_reversible_command (_("split regions"));
-
+
for (RegionSelection::iterator i = rs.begin(); i != rs.end(); ) {
RegionSelection::iterator tmp;
@@ -6591,7 +6591,7 @@ Editor::split_region_at_transients ()
i = tmp;
}
-
+
commit_reversible_command ();
}
@@ -6754,7 +6754,7 @@ Editor::split_region_at_points (boost::shared_ptr<Region> r, AnalysisFeatureList
vector<Command*> cmds;
pl->rdiff (cmds);
_session->add_commands (cmds);
-
+
_session->add_command (new StatefulDiffCommand (pl));
if (select_new) {
@@ -6781,12 +6781,12 @@ Editor::place_transient()
framepos_t where = get_preferred_edit_position();
begin_reversible_command (_("place transient"));
-
+
for (RegionSelection::iterator r = rs.begin(); r != rs.end(); ++r) {
framepos_t position = (*r)->region()->position();
(*r)->region()->add_transient(where - position);
}
-
+
commit_reversible_command ();
}
@@ -6816,7 +6816,7 @@ Editor::snap_regions_to_grid ()
}
begin_reversible_command (_("snap regions to grid"));
-
+
for (RegionSelection::iterator r = rs.begin(); r != rs.end(); ++r) {
boost::shared_ptr<Playlist> pl = (*r)->region()->playlist();
@@ -6839,7 +6839,7 @@ Editor::snap_regions_to_grid ()
(*i)->thaw();
used_playlists.pop_front();
}
-
+
commit_reversible_command ();
}
@@ -6899,7 +6899,7 @@ Editor::close_region_gaps ()
/* Iterate over the region list and make adjacent regions overlap by crossfade_len_ms */
begin_reversible_command (_("close region gaps"));
-
+
int idx = 0;
boost::shared_ptr<Region> last_region;
@@ -6938,7 +6938,7 @@ Editor::close_region_gaps ()
(*i)->thaw();
used_playlists.pop_front();
}
-
+
commit_reversible_command ();
}
@@ -7028,7 +7028,7 @@ Editor::playhead_forward_to_grid ()
if (!_session) {
return;
}
-
+
framepos_t pos = playhead_cursor->current_frame ();
if (pos < max_framepos - 1) {
pos += 2;
@@ -7044,7 +7044,7 @@ Editor::playhead_backward_to_grid ()
if (!_session) {
return;
}
-
+
framepos_t pos = playhead_cursor->current_frame ();
if (pos > 2) {
pos -= 2;
@@ -7163,7 +7163,7 @@ edit your ardour.rc file to set the\n\
trackstr = P_("track", "tracks", ntracks);
busstr = P_("bus", "busses", nbusses);
-
+
if (ntracks) {
if (nbusses) {
prompt = string_compose (_("Do you really want to remove %1 %2 and %3 %4?\n"
@@ -7282,7 +7282,7 @@ Editor::insert_time (
pl.insert ((*x)->playlist ());
}
}
-
+
for (set<boost::shared_ptr<Playlist> >::iterator i = pl.begin(); i != pl.end(); ++i) {
(*i)->clear_changes ();
@@ -7388,7 +7388,7 @@ Editor::do_remove_time ()
if (response != RESPONSE_OK) {
return;
}
-
+
framecnt_t distance = d.distance();
if (distance == 0) {
@@ -7420,26 +7420,26 @@ Editor::remove_time (framepos_t pos, framecnt_t frames, InsertTimeOption opt,
for (TrackSelection::iterator x = selection->tracks.begin(); x != selection->tracks.end(); ++x) {
/* regions */
boost::shared_ptr<Playlist> pl = (*x)->playlist();
-
+
if (pl) {
XMLNode &before = pl->get_state();
-
+
std::list<AudioRange> rl;
AudioRange ar(pos, pos+frames, 0);
rl.push_back(ar);
pl->cut (rl);
pl->shift (pos, -frames, true, ignore_music_glue);
-
+
if (!in_command) {
begin_reversible_command (_("cut time"));
in_command = true;
}
XMLNode &after = pl->get_state();
-
+
_session->add_command (new MementoCommand<Playlist> (*pl, &before, &after));
}
-
+
/* automation */
RouteTimeAxisView* rtav = dynamic_cast<RouteTimeAxisView*> (*x);
if (rtav) {
@@ -7452,7 +7452,7 @@ Editor::remove_time (framepos_t pos, framecnt_t frames, InsertTimeOption opt,
}
std::list<Location*> loc_kill_list;
-
+
/* markers */
if (markers_too) {
bool moved = false;
@@ -7514,7 +7514,7 @@ Editor::remove_time (framepos_t pos, framecnt_t frames, InsertTimeOption opt,
for (list<Location*>::iterator i = loc_kill_list.begin(); i != loc_kill_list.end(); ++i) {
_session->locations()->remove( *i );
}
-
+
if (moved) {
if (!in_command) {
begin_reversible_command (_("cut time"));
@@ -7524,7 +7524,7 @@ Editor::remove_time (framepos_t pos, framecnt_t frames, InsertTimeOption opt,
_session->add_command (new MementoCommand<Locations>(*_session->locations(), &before, &after));
}
}
-
+
if (tempo_too) {
XMLNode& before (_session->tempo_map().get_state());
@@ -7537,7 +7537,7 @@ Editor::remove_time (framepos_t pos, framecnt_t frames, InsertTimeOption opt,
_session->add_command (new MementoCommand<TempoMap>(_session->tempo_map(), &before, &after));
}
}
-
+
if (in_command) {
commit_reversible_command ();
}
@@ -7701,7 +7701,7 @@ void
Editor::start_visual_state_op (uint32_t n)
{
save_visual_state (n);
-
+
PopUp* pup = new PopUp (WIN_POS_MOUSE, 1000, true);
char buf[32];
snprintf (buf, sizeof (buf), _("Saved view %u"), n+1);
@@ -7835,7 +7835,7 @@ Editor::toggle_midi_input_active (bool flip_others)
onoff = !mt->input_active();
}
}
-
+
_session->set_exclusive_input_active (rl, onoff, flip_others);
}
@@ -7853,14 +7853,14 @@ Editor::lock ()
b->set_text (_("Click to unlock"));
b->signal_clicked.connect (sigc::mem_fun (*this, &Editor::unlock));
lock_dialog->get_vbox()->pack_start (*b);
-
+
lock_dialog->get_vbox()->show_all ();
lock_dialog->set_size_request (200, 200);
}
delete _main_menu_disabler;
_main_menu_disabler = new MainMenuDisabler;
-
+
lock_dialog->present ();
}
@@ -7868,7 +7868,7 @@ void
Editor::unlock ()
{
lock_dialog->hide ();
-
+
delete _main_menu_disabler;
if (UIConfiguration::instance().get_lock_gui_after_seconds()) {
@@ -7900,11 +7900,11 @@ Editor::bring_all_sources_into_session ()
ArdourDialog w (_("Moving embedded files into session folder"));
w.get_vbox()->pack_start (msg);
w.present ();
-
+
/* flush all pending GUI events because we're about to start copying
* files
*/
-
+
Gtkmm2ext::UI::instance()->flush_pending ();
cerr << " Do it\n";
diff --git a/gtk2_ardour/editor_regions.cc b/gtk2_ardour/editor_regions.cc
index 5b143acc75..31e7bf1309 100644
--- a/gtk2_ardour/editor_regions.cc
+++ b/gtk2_ardour/editor_regions.cc
@@ -124,7 +124,7 @@ EditorRegions::EditorRegions (Editor* e)
{ 10, S_("Opaque|O"), _("Region opaque (blocks regions below it from being heard)?") },
{ -1, 0, 0 }
};
-
+
for (int i = 0; ci[i].index >= 0; ++i) {
col = _display.get_column (ci[i].index);
l = manage (new Label (ci[i].label));
@@ -433,7 +433,7 @@ EditorRegions::add_region (boost::shared_ptr<Region> region)
*/
row = *(_model->insert (subrows.end()));
-
+
} else {
row = *(_model->append());
}
@@ -569,7 +569,7 @@ EditorRegions::selection_changed ()
_change_connection.block (false);
}
}
-
+
}
} else {
_editor->get_selection().clear_regions ();
diff --git a/gtk2_ardour/editor_route_groups.cc b/gtk2_ardour/editor_route_groups.cc
index d66c6b6794..041cef8892 100644
--- a/gtk2_ardour/editor_route_groups.cc
+++ b/gtk2_ardour/editor_route_groups.cc
@@ -75,7 +75,7 @@ EditorRouteGroups::EditorRouteGroups (Editor* e)
TreeViewColumn* color_column = manage (new TreeViewColumn ("", *color_renderer));
color_column->add_attribute (color_renderer->property_color(), _columns.gdkcolor);
-
+
_display.append_column (*color_column);
_display.append_column ("", _columns.text);
@@ -138,7 +138,7 @@ EditorRouteGroups::EditorRouteGroups (Editor* e)
CellRendererText* name_cell = dynamic_cast<CellRendererText*>(_display.get_column_cell_renderer (1));
name_cell->property_editable() = true;
name_cell->signal_edited().connect (sigc::mem_fun (*this, &EditorRouteGroups::name_edit));
-
+
for (int i = 1; ci[i].index >= 0; ++i) {
CellRendererToggle* active_cell = dynamic_cast <CellRendererToggle*> (_display.get_column_cell_renderer (i));
@@ -274,10 +274,10 @@ EditorRouteGroups::button_press_event (GdkEventButton* ev)
c = color_dialog.get_colorsel()->get_current_color();
GroupTabs::set_group_color (group, gdk_color_to_rgba (c));
break;
-
+
default:
break;
-
+
}
color_dialog.hide ();
@@ -301,7 +301,7 @@ EditorRouteGroups::button_press_event (GdkEventButton* ev)
ret = true;
break;
-
+
case 3:
val = (*iter)[_columns.active_state];
group->set_active (!val, this);
@@ -423,11 +423,11 @@ EditorRouteGroups::add (RouteGroup* group)
row[_columns.active_shared] = group->is_route_active ();
row[_columns.active_state] = group->is_active ();
row[_columns.is_visible] = !group->is_hidden();
-
+
Gdk::Color c;
set_color_from_rgba (c, GroupTabs::group_color (group));
row[_columns.gdkcolor] = c;
-
+
_in_row_change = true;
row[_columns.routegroup] = group;
@@ -505,7 +505,7 @@ EditorRouteGroups::property_changed (RouteGroup* group, const PropertyChange&)
break;
}
}
-
+
_in_row_change = false;
for (TrackViewList::const_iterator i = _editor->get_track_views().begin(); i != _editor->get_track_views().end(); ++i) {
diff --git a/gtk2_ardour/editor_routes.cc b/gtk2_ardour/editor_routes.cc
index d79039db09..a10f523800 100644
--- a/gtk2_ardour/editor_routes.cc
+++ b/gtk2_ardour/editor_routes.cc
@@ -525,7 +525,7 @@ EditorRoutes::redisplay_real ()
}
bool visible = tv->marked_for_display ();
-
+
/* show or hide the TimeAxisView */
if (visible) {
position += tv->show_at (position, n, &_editor->edit_controls_vbox);
@@ -886,11 +886,11 @@ EditorRoutes::reset_remote_control_ids ()
for (ri = rows.begin(); ri != rows.end(); ++ri) {
/* skip two special values */
-
+
if (rid == Route::MasterBusRemoteControlID) {
rid++;
}
-
+
if (rid == Route::MonitorBusRemoteControlID) {
rid++;
}
@@ -1414,7 +1414,7 @@ EditorRoutes::initial_display ()
}
RouteList r (*_session->get_routes());
-
+
r.sort (EditorOrderRouteSorter ());
_editor->add_routes (r);
}
@@ -1602,7 +1602,7 @@ EditorRoutes::idle_update_mute_rec_solo_etc()
(*i)[_columns.active] = route->active ();
if (boost::dynamic_pointer_cast<Track> (route)) {
boost::shared_ptr<MidiTrack> mt = boost::dynamic_pointer_cast<MidiTrack> (route);
-
+
if (route->record_enabled()) {
if (_session->record_status() == Session::Recording) {
(*i)[_columns.rec_state] = 1;
@@ -1614,7 +1614,7 @@ EditorRoutes::idle_update_mute_rec_solo_etc()
} else {
(*i)[_columns.rec_state] = 0;
}
-
+
(*i)[_columns.name_editable] = !route->record_enabled ();
}
}
diff --git a/gtk2_ardour/editor_rulers.cc b/gtk2_ardour/editor_rulers.cc
index f4ce487654..ccd03995ff 100644
--- a/gtk2_ardour/editor_rulers.cc
+++ b/gtk2_ardour/editor_rulers.cc
@@ -130,7 +130,7 @@ Editor::initialize_rulers ()
_bbt_metric = new BBTMetric (this);
_minsec_metric = new MinsecMetric (this);
_samples_metric = new SamplesMetric (this);
-
+
timecode_ruler = new ArdourCanvas::Ruler (_time_markers_group, *_timecode_metric,
ArdourCanvas::Rect (0, 0, ArdourCanvas::COORD_MAX, timebar_height));
timecode_ruler->set_font_description (font);
@@ -175,7 +175,7 @@ Editor::initialize_rulers ()
minsec_ruler->Event.connect (sigc::bind (sigc::mem_fun (*this, &Editor::canvas_ruler_event), minsec_ruler, MinsecRulerItem));
bbt_ruler->Event.connect (sigc::bind (sigc::mem_fun (*this, &Editor::canvas_ruler_event), bbt_ruler, BBTRulerItem));
samples_ruler->Event.connect (sigc::bind (sigc::mem_fun (*this, &Editor::canvas_ruler_event), samples_ruler, SamplesRulerItem));
-
+
visible_timebars = 0; /*this will be changed below */
}
@@ -1141,7 +1141,7 @@ Editor::compute_bbt_ruler_scale (framepos_t lower, framepos_t upper,
} else {
bbt_ruler_scale = bbt_show_ticks_detail;
}
-
+
if ((bbt_ruler_scale == bbt_show_ticks_detail) && (lower_beat.beats == upper_beat.beats) && (upper_beat.ticks - lower_beat.ticks <= Timecode::BBT_Time::ticks_per_beat / 4)) {
bbt_ruler_scale = bbt_show_ticks_super_detail;
}
@@ -1154,7 +1154,7 @@ edit_last_mark_label (std::vector<ArdourCanvas::Ruler::Mark>& marks, const std::
copy.label = newlabel;
marks.pop_back ();
marks.push_back (copy);
-}
+}
void
Editor::metric_get_bbt (std::vector<ArdourCanvas::Ruler::Mark>& marks, gdouble lower, gdouble upper, gint /*maxchars*/)
@@ -1234,7 +1234,7 @@ Editor::metric_get_bbt (std::vector<ArdourCanvas::Ruler::Mark>& marks, gdouble l
bbt_nmarks = (beats + 2) * bbt_beat_subdivision;
bbt_position_of_helper = lower + (30 * Editor::get_current_zoom ());
-
+
// could do marks.assign() here to preallocate
mark.label = "";
diff --git a/gtk2_ardour/editor_selection.cc b/gtk2_ardour/editor_selection.cc
index 41de4f38f2..5a59b48a90 100644
--- a/gtk2_ardour/editor_selection.cc
+++ b/gtk2_ardour/editor_selection.cc
@@ -461,7 +461,7 @@ Editor::mapover_tracks_with_unique_playlists (sigc::slot<void, RouteTimeAxisView
RouteTimeAxisView* v = dynamic_cast<RouteTimeAxisView*> (*i);
if (v && v->route()->route_group() == group) {
-
+
boost::shared_ptr<Track> t = v->track();
if (t) {
if (playlists.insert (t->playlist()).second) {
@@ -1005,7 +1005,7 @@ Editor::track_selection_changed ()
ActionManager::set_sensitive (ActionManager::track_selection_sensitive_actions, !selection->tracks.empty());
/* notify control protocols */
-
+
ControlProtocol::TrackSelectionChanged (routes);
if (sfbrowser && _session && !_session->deletion_in_progress()) {
@@ -1341,7 +1341,7 @@ Editor::sensitize_the_right_region_actions ()
if (have_active_fade_out && have_inactive_fade_out) {
// a->set_inconsistent ();
}
-
+
bool const have_active_fade = have_active_fade_in || have_active_fade_out;
bool const have_inactive_fade = have_inactive_fade_in || have_inactive_fade_out;
@@ -1351,7 +1351,7 @@ Editor::sensitize_the_right_region_actions ()
if (have_active_fade && have_inactive_fade) {
// a->set_inconsistent ();
}
-
+
_ignore_region_action = false;
_all_region_actions_sensitized = false;
@@ -1610,7 +1610,7 @@ Editor::set_selection_from_region ()
/* find all the tracks that have selected regions */
set<TimeAxisView*> tracks;
-
+
for (RegionSelection::const_iterator r = selection->regions.begin(); r != selection->regions.end(); ++r) {
tracks.insert (&(*r)->get_time_axis_view());
}
@@ -1623,9 +1623,9 @@ Editor::set_selection_from_region ()
selection->set (selection->regions.start(), selection->regions.end_frame());
/* and select the tracks */
-
+
selection->set (tvl);
-
+
if (!Profile->get_sae()) {
set_mouse_mode (Editing::MouseRange, false);
}
@@ -1946,7 +1946,7 @@ Editor::get_edit_op_range (framepos_t& start, framepos_t& end) const
end = 0;
return false;
}
-
+
// if (!mouse_frame (m, ignored)) {
// /* mouse is not in a canvas, try playhead+selected marker.
// this is probably most true when using menus.
diff --git a/gtk2_ardour/editor_summary.cc b/gtk2_ardour/editor_summary.cc
index a516c80c9f..baf1e4970a 100644
--- a/gtk2_ardour/editor_summary.cc
+++ b/gtk2_ardour/editor_summary.cc
@@ -223,7 +223,7 @@ EditorSummary::render (cairo_t* cr, cairo_rectangle_t*)
}
cairo_push_group (cr);
-
+
/* Fill with the background image */
cairo_rectangle (cr, 0, 0, get_width(), get_height());
@@ -408,7 +408,7 @@ bool
EditorSummary::on_button_press_event (GdkEventButton* ev)
{
_old_follow_playhead = _editor->follow_playhead ();
-
+
if (ev->button == 1) {
pair<double, double> xr;
@@ -436,7 +436,7 @@ EditorSummary::on_button_press_event (GdkEventButton* ev)
get_editor (&_pending_editor_x, &_pending_editor_y);
_pending_editor_changed = false;
}
-
+
} else if (Keyboard::modifier_state_equals (ev->state, Keyboard::SecondaryModifier)) {
/* secondary-modifier-click: locate playhead */
@@ -489,7 +489,7 @@ EditorSummary::get_editor (pair<double, double>* x, pair<double, double>* y) con
/* We are dragging, and configured not to update the editor window during drags,
so just return where the editor will be when the drag finishes.
*/
-
+
*x = _pending_editor_x;
*y = _pending_editor_y;
@@ -499,7 +499,7 @@ EditorSummary::get_editor (pair<double, double>* x, pair<double, double>* y) con
x->first = (_editor->leftmost_sample () - _start) * _x_scale;
x->second = x->first + _editor->current_page_samples() * _x_scale;
-
+
y->first = editor_y_to_summary (_editor->vertical_adjustment.get_value ());
y->second = editor_y_to_summary (_editor->vertical_adjustment.get_value () + _editor->visible_canvas_height() - _editor->get_trackview_group()->canvas_origin().y);
}
@@ -668,7 +668,7 @@ bool
EditorSummary::on_button_release_event (GdkEventButton*)
{
bool const was_suspended = suspending_editor_updates ();
-
+
_move_dragging = false;
_zoom_dragging = false;
_editor->_dragging_playhead = false;
@@ -677,7 +677,7 @@ EditorSummary::on_button_release_event (GdkEventButton*)
if (was_suspended && _pending_editor_changed) {
set_editor (_pending_editor_x, _pending_editor_y);
}
-
+
return true;
}
@@ -767,7 +767,7 @@ EditorSummary::set_editor (double const x, double const y)
as it also means that we won't change these variables if an idle handler
is merely pending but not executing. But c'est la vie.
*/
-
+
return;
}
@@ -854,12 +854,12 @@ EditorSummary::set_editor_x (pair<double, double> x)
set_dirty ();
} else {
_editor->reset_x_origin (x.first / _x_scale + _start);
-
+
double const nx = (
((x.second - x.first) / _x_scale) /
_editor->sample_to_pixel (_editor->current_page_samples())
);
-
+
if (nx != _editor->get_current_zoom ()) {
_editor->reset_zoom (nx);
}
diff --git a/gtk2_ardour/editor_tempodisplay.cc b/gtk2_ardour/editor_tempodisplay.cc
index 90c64d2b1b..38685e5dd6 100644
--- a/gtk2_ardour/editor_tempodisplay.cc
+++ b/gtk2_ardour/editor_tempodisplay.cc
@@ -133,12 +133,12 @@ Editor::redisplay_tempo (bool immediate_redraw)
if (immediate_redraw) {
ARDOUR::TempoMap::BBTPointList::const_iterator current_bbt_points_begin;
ARDOUR::TempoMap::BBTPointList::const_iterator current_bbt_points_end;
-
+
compute_current_bbt_points (leftmost_frame, leftmost_frame + current_page_samples(),
current_bbt_points_begin, current_bbt_points_end);
draw_measures (current_bbt_points_begin, current_bbt_points_end);
update_tempo_based_rulers (current_bbt_points_begin, current_bbt_points_end); // redraw rulers and measures
-
+
} else {
Glib::signal_idle().connect (sigc::bind_return (sigc::bind (sigc::mem_fun (*this, &Editor::redisplay_tempo), true), false));
}
diff --git a/gtk2_ardour/editor_timefx.cc b/gtk2_ardour/editor_timefx.cc
index 5908e50249..d78340df65 100644
--- a/gtk2_ardour/editor_timefx.cc
+++ b/gtk2_ardour/editor_timefx.cc
@@ -161,7 +161,7 @@ Editor::time_fx (RegionList& regions, float val, bool pitching)
do_timefx ();
return 0;
}
-
+
switch (current_timefx->run ()) {
case RESPONSE_ACCEPT:
break;
diff --git a/gtk2_ardour/engine_dialog.cc b/gtk2_ardour/engine_dialog.cc
index 654f63a8cd..61dbe22a78 100644
--- a/gtk2_ardour/engine_dialog.cc
+++ b/gtk2_ardour/engine_dialog.cc
@@ -566,7 +566,7 @@ EngineControl::build_full_control_notebook ()
basic_packer.attach (input_channels, 1, 2, row, row+1, xopt, (AttachOptions) 0);
++row;
}
-
+
output_channels.set_name ("OutputChannels");
output_channels.set_flags (Gtk::CAN_FOCUS);
output_channels.set_digits (0);
@@ -579,7 +579,7 @@ EngineControl::build_full_control_notebook ()
basic_packer.attach (output_channels, 1, 2, row, row+1, xopt, (AttachOptions) 0);
++row;
}
-
+
input_latency.set_name ("InputLatency");
input_latency.set_flags (Gtk::CAN_FOCUS);
input_latency.set_digits (0);
@@ -1023,7 +1023,7 @@ EngineControl::print_channel_count (Gtk::SpinButton* sb)
if (ARDOUR::Profile->get_mixbus()) {
return true;
}
-
+
uint32_t cnt = (uint32_t) sb->get_value();
if (cnt == 0) {
sb->set_text (_("all available channels"));
@@ -1433,7 +1433,7 @@ EngineControl::device_changed ()
queue_device_changed = true;
}
}
-
+
//the device name must be set FIRST so ASIO can populate buffersizes and the control panel button
if (backend->use_separate_input_and_output_devices()) {
backend->set_input_device_name (device_name_in);
diff --git a/gtk2_ardour/export_dialog.cc b/gtk2_ardour/export_dialog.cc
index 10b0ea8851..8d9c6ff24b 100644
--- a/gtk2_ardour/export_dialog.cc
+++ b/gtk2_ardour/export_dialog.cc
@@ -158,7 +158,7 @@ ExportDialog::init_gui ()
export_notebook.append_page (*file_format_selector, _("File format"));
export_notebook.append_page (*timespan_selector, _("Time Span"));
export_notebook.append_page (*channel_selector, _("Channels"));
-
+
get_vbox()->pack_start (export_notebook, true, true, 0);
get_vbox()->pack_end (warning_widget, false, false, 0);
get_vbox()->pack_end (progress_widget, false, false, 0);
@@ -325,7 +325,7 @@ ExportDialog::show_progress ()
if (!status->aborted()) {
NagScreen* ns = NagScreen::maybe_nag (_("export"));
-
+
if (ns) {
ns->nag ();
delete ns;
diff --git a/gtk2_ardour/export_file_notebook.cc b/gtk2_ardour/export_file_notebook.cc
index ae924c10e3..2469e4f6cc 100644
--- a/gtk2_ardour/export_file_notebook.cc
+++ b/gtk2_ardour/export_file_notebook.cc
@@ -301,7 +301,7 @@ ExportFileNotebook::FilePage::update_example_filename()
example = profile_manager->get_sample_filename_for_format (
filename_state->filename, format_state->format);
}
-
+
if (example != "") {
filename_selector.set_example_filename(Glib::path_get_basename (example));
} else {
diff --git a/gtk2_ardour/export_filename_selector.cc b/gtk2_ardour/export_filename_selector.cc
index 93f7daf832..831b75ef02 100644
--- a/gtk2_ardour/export_filename_selector.cc
+++ b/gtk2_ardour/export_filename_selector.cc
@@ -328,10 +328,10 @@ ExportFilenameSelector::open_browse_dialog ()
while (true) {
int result = dialog.run();
-
+
if (result == Gtk::RESPONSE_OK) {
std::string filename = dialog.get_filename();
-
+
if (!Glib::file_test (filename, Glib::FILE_TEST_IS_DIR|Glib::FILE_TEST_EXISTS)) {
Gtk::MessageDialog msg (string_compose (_("%1: this is only the directory/folder name, not the filename.\n\
The filename will be chosen from the information just above the folder selector."), filename));
diff --git a/gtk2_ardour/export_format_dialog.h b/gtk2_ardour/export_format_dialog.h
index 6a25d707bf..6197d0d7be 100644
--- a/gtk2_ardour/export_format_dialog.h
+++ b/gtk2_ardour/export_format_dialog.h
@@ -180,7 +180,7 @@ class ExportFormatDialog : public ArdourDialog, public PBD::ScopedConnectionList
AudioClock silence_end_clock;
/* Post-export hook */
-
+
Gtk::Label command_label;
Gtk::Entry command_entry;
diff --git a/gtk2_ardour/export_timespan_selector.cc b/gtk2_ardour/export_timespan_selector.cc
index 0c6ff08cf9..83f8a8f4aa 100644
--- a/gtk2_ardour/export_timespan_selector.cc
+++ b/gtk2_ardour/export_timespan_selector.cc
@@ -55,7 +55,7 @@ ExportTimespanSelector::ExportTimespanSelector (ARDOUR::Session * session, Profi
)
);
option_hbox.pack_start (*b, false, false, 6);
-
+
b = Gtk::manage (new Gtk::Button (_("Deselect All")));
b->signal_clicked().connect (
sigc::bind (
diff --git a/gtk2_ardour/floating_text_entry.cc b/gtk2_ardour/floating_text_entry.cc
index 9907360c01..d264ee930b 100644
--- a/gtk2_ardour/floating_text_entry.cc
+++ b/gtk2_ardour/floating_text_entry.cc
@@ -34,7 +34,7 @@ FloatingTextEntry::FloatingTextEntry (const std::string& initial_contents)
set_name (X_("FloatingTextEntry"));
set_position (Gtk::WIN_POS_MOUSE);
set_border_width (0);
-
+
if (!initial_contents.empty()) {
entry.set_text (initial_contents);
}
diff --git a/gtk2_ardour/gain_meter.cc b/gtk2_ardour/gain_meter.cc
index 9e1edbb520..4a7e75fcf7 100644
--- a/gtk2_ardour/gain_meter.cc
+++ b/gtk2_ardour/gain_meter.cc
@@ -133,7 +133,7 @@ GainMeterBase::GainMeterBase (Session* s, bool horizontal, int fader_length, int
max_peak = minus_infinity();
peak_display.set_text (_("-inf"));
peak_display.set_alignment(0.5);
-
+
/* stuff related to the fact that the peak display is not, in
fact, supposed to be a text entry.
*/
@@ -282,7 +282,7 @@ GainMeterBase::setup_gain_adjustment ()
ignore_toggle = false;
effective_gain_display ();
-
+
_previous_amp_output_streams = _amp->output_streams ();
}
@@ -529,7 +529,7 @@ GainMeterBase::gain_adjusted ()
} else {
value = gain_adjustment.get_value();
}
-
+
if (!ignore_toggle) {
if (_route && _route->amp() == _amp) {
_route->set_gain (value, this);
diff --git a/gtk2_ardour/generic_pluginui.cc b/gtk2_ardour/generic_pluginui.cc
index d081f62225..47b5f93a98 100644
--- a/gtk2_ardour/generic_pluginui.cc
+++ b/gtk2_ardour/generic_pluginui.cc
@@ -96,7 +96,7 @@ GenericPluginUI::GenericPluginUI (boost::shared_ptr<PluginInsert> pi, bool scrol
smaller_hbox->pack_start (delete_button, false, false);
smaller_hbox->pack_start (reset_button, false, false, 4);
smaller_hbox->pack_start (bypass_button, false, true, 4);
-
+
automation_manual_all_button.set_text(_("Manual"));
automation_manual_all_button.set_name (X_("generic button"));
automation_play_all_button.set_text(_("Play"));
@@ -105,7 +105,7 @@ GenericPluginUI::GenericPluginUI (boost::shared_ptr<PluginInsert> pi, bool scrol
automation_write_all_button.set_name (X_("generic button"));
automation_touch_all_button.set_text(_("Touch"));
automation_touch_all_button.set_name (X_("generic button"));
-
+
Label* l = manage (new Label (_("All Automation")));
l->set_alignment (1.0, 0.5);
automation_hbox->pack_start (*l, true, true);
@@ -183,7 +183,7 @@ int value = -1;
static int match_or_digit(char c1, char c2) {
return c1 == c2 || (isdigit(c1) && isdigit(c2));
-}
+}
static std::size_t matching_chars_at_head(const string s1, const string s2) {
std::size_t length, n = 0;
@@ -374,13 +374,13 @@ GenericPluginUI::build ()
// Iterate over the list of controls to find which adjacent controls
// are similar enough to be grouped together.
-
+
string label, previous_label = "";
std::vector<int> numbers_in_labels(cui_controls_list.size());
-
+
std::vector<float> similarity_scores(cui_controls_list.size());
float most_similar = 0.0, least_similar = 1.0;
-
+
i = 0;
for (vector<ControlUI*>::iterator cuip = cui_controls_list.begin(); cuip != cui_controls_list.end(); ++cuip, ++i) {
label = (*cuip)->label.get_text();
@@ -406,32 +406,32 @@ GenericPluginUI::build ()
}
// cerr << "label: " << label << " sim: " << fixed << setprecision(3) << similarity_scores[i] << " num: " << numbers_in_labels[i] << endl;
- previous_label = label;
+ previous_label = label;
}
-
+
// cerr << "most similar: " << most_similar << ", least similar: " << least_similar << endl;
float similarity_threshold;
-
+
if (most_similar > 1.0) {
similarity_threshold = default_similarity_threshold;
} else {
similarity_threshold = most_similar - (1 - default_similarity_threshold);
}
-
+
// Now iterate over the list of controls to display them, placing an
// HSeparator between controls of less than a certain similarity, and
// starting a new column when necessary.
-
+
i = 0;
for (vector<ControlUI*>::iterator cuip = cui_controls_list.begin(); cuip != cui_controls_list.end(); ++cuip, ++i) {
ControlUI* cui = *cuip;
-
+
if (!is_scrollable) {
x++;
}
-
+
if (x > max_controls_per_column || similarity_scores[i] <= similarity_threshold) {
if (x > min_controls_per_column) {
frame = manage (new Frame);
@@ -477,7 +477,7 @@ GenericPluginUI::build ()
output_table.show_all ();
button_table.show_all ();
-
+
automation_manual_all_button.signal_clicked.connect(sigc::bind (sigc::mem_fun (*this, &GenericPluginUI::set_all_automation), ARDOUR::Off));
automation_play_all_button.signal_clicked.connect(sigc::bind (sigc::mem_fun (*this, &GenericPluginUI::set_all_automation), ARDOUR::Play));
automation_write_all_button.signal_clicked.connect(sigc::bind (sigc::mem_fun (*this, &GenericPluginUI::set_all_automation), ARDOUR::Write));
@@ -601,7 +601,7 @@ GenericPluginUI::build_control_ui (const Evoral::Parameter& param,
int const steps = desc.integer_step ? (desc.upper - desc.lower + 1) / desc.step : 0;
if (control_ui->scale_points && ((steps && int (control_ui->scale_points->size()) == steps) || desc.enumeration)) {
-
+
/* Either:
* a) There is a label for each possible value of this input, or
* b) This port is marked as being an enumeration.
@@ -612,7 +612,7 @@ GenericPluginUI::build_control_ui (const Evoral::Parameter& param,
ARDOUR::ScalePoints::const_iterator i = control_ui->scale_points->begin();
i != control_ui->scale_points->end();
++i) {
-
+
labels.push_back(i->first);
}
diff --git a/gtk2_ardour/ghostregion.h b/gtk2_ardour/ghostregion.h
index 4d7e0c95ff..a62d8d5b25 100644
--- a/gtk2_ardour/ghostregion.h
+++ b/gtk2_ardour/ghostregion.h
@@ -75,7 +75,7 @@ public:
public:
GhostEvent(::NoteBase *, ArdourCanvas::Container *);
virtual ~GhostEvent ();
-
+
NoteBase* event;
ArdourCanvas::Item* item;
};
diff --git a/gtk2_ardour/group_tabs.cc b/gtk2_ardour/group_tabs.cc
index 7fb62ae973..be505b8c0d 100644
--- a/gtk2_ardour/group_tabs.cc
+++ b/gtk2_ardour/group_tabs.cc
@@ -69,7 +69,7 @@ GroupTabs::set_session (Session* s)
_session->RouteRemovedFromRouteGroup.connect (
_session_connections, invalidator (*this), boost::bind (&GroupTabs::route_removed_from_route_group, this, _1, _2), gui_context()
);
-
+
_session->route_group_removed.connect (_session_connections, invalidator (*this), boost::bind (&GroupTabs::set_dirty, this), gui_context());
}
}
@@ -138,7 +138,7 @@ GroupTabs::on_button_press_event (GdkEventButton* ev)
} else if (ev->button == 3) {
RouteGroup* g = t ? t->group : 0;
-
+
if (Keyboard::modifier_state_equals (ev->state, Keyboard::PrimaryModifier) && g) {
/* edit */
RouteGroupDialog d (g, false);
@@ -191,18 +191,18 @@ GroupTabs::on_button_release_event (GdkEventButton*)
if (_dragging == 0) {
return false;
}
-
+
if (!_drag_moved) {
-
+
if (_dragging->group) {
/* toggle active state */
_dragging->group->set_active (!_dragging->group->is_active (), this);
}
-
+
} else {
/* finish drag */
RouteList routes = routes_for_tab (_dragging);
-
+
if (!routes.empty()) {
if (_dragging_new_tab) {
RouteGroup* g = create_and_add_group ();
@@ -214,13 +214,13 @@ GroupTabs::on_button_release_event (GdkEventButton*)
} else {
boost::shared_ptr<RouteList> r = _session->get_routes ();
for (RouteList::iterator i = r->begin(); i != r->end(); ++i) {
-
+
bool const was_in_tab = find (
_initial_dragging_routes.begin(), _initial_dragging_routes.end(), *i
) != _initial_dragging_routes.end ();
-
+
bool const now_in_tab = find (routes.begin(), routes.end(), *i) != routes.end();
-
+
if (was_in_tab && !now_in_tab) {
_dragging->group->remove (*i);
} else if (!was_in_tab && now_in_tab) {
@@ -229,11 +229,11 @@ GroupTabs::on_button_release_event (GdkEventButton*)
}
}
}
-
+
set_dirty ();
queue_draw ();
}
-
+
_dragging = 0;
_initial_dragging_routes.clear ();
@@ -254,7 +254,7 @@ GroupTabs::render (cairo_t* cr, cairo_rectangle_t*)
cairo_set_source_rgb (cr, c.get_red_p(), c.get_green_p(), c.get_blue_p());
cairo_rectangle (cr, 0, 0, get_width(), get_height());
cairo_fill (cr);
-
+
/* tabs */
for (list<Tab>::const_iterator i = _tabs.begin(); i != _tabs.end(); ++i) {
@@ -551,20 +551,20 @@ GroupTabs::set_group_color (RouteGroup* group, uint32_t color)
g = 25;
b = 25;
}
-
+
GUIObjectState& gui_state = *ARDOUR_UI::instance()->gui_object_state;
char buf[64];
-
+
/* for historical reasons the colors must be stored as 16 bit color
* values. Ugh.
*/
snprintf (buf, sizeof (buf), "%d:%d:%d", (r<<8), (g<<8), (b<<8));
gui_state.set_property (group_gui_id (group), "color", buf);
-
+
/* the group color change notification */
-
+
PBD::PropertyChange change;
change.add (Properties::color);
group->PropertyChanged (change);
@@ -594,7 +594,7 @@ uint32_t
GroupTabs::group_color (RouteGroup* group)
{
assert (group);
-
+
GUIObjectState& gui_state = *ARDOUR_UI::instance()->gui_object_state;
string const gui_id = group_gui_id (group);
bool empty;
@@ -630,7 +630,7 @@ GroupTabs::route_group_property_changed (RouteGroup* rg)
*/
emit_gui_changed_for_members (rg);
-
+
set_dirty ();
}
diff --git a/gtk2_ardour/group_tabs.h b/gtk2_ardour/group_tabs.h
index 16d6a85b31..e31ad9643e 100644
--- a/gtk2_ardour/group_tabs.h
+++ b/gtk2_ardour/group_tabs.h
@@ -67,7 +67,7 @@ protected:
private:
static void emit_gui_changed_for_members (ARDOUR::RouteGroup *);
-
+
/** Compute all the tabs for this widget.
* @return Tabs.
*/
diff --git a/gtk2_ardour/gui_object.cc b/gtk2_ardour/gui_object.cc
index ca196613f0..3128e61f3a 100644
--- a/gtk2_ardour/gui_object.cc
+++ b/gtk2_ardour/gui_object.cc
@@ -157,4 +157,4 @@ GUIObjectState::all_ids () const
return ids;
}
-
+
diff --git a/gtk2_ardour/gui_object.h b/gtk2_ardour/gui_object.h
index b452e0cc44..39cf579fb5 100644
--- a/gtk2_ardour/gui_object.h
+++ b/gtk2_ardour/gui_object.h
@@ -55,7 +55,7 @@ public:
static XMLNode* get_or_add_node (XMLNode *, const std::string &);
void remove_node (const std::string& id);
-
+
private:
XMLNode _state;
};
diff --git a/gtk2_ardour/io_selector.cc b/gtk2_ardour/io_selector.cc
index 270ed8ce32..574b3cd0ca 100644
--- a/gtk2_ardour/io_selector.cc
+++ b/gtk2_ardour/io_selector.cc
@@ -259,7 +259,7 @@ void
IOSelectorWindow::io_name_changed (void*)
{
ENSURE_GUI_THREAD (*this, &IOSelectorWindow::io_name_changed, src)
-
+
std::string title;
if (!_selector.find_inputs_for_io_outputs()) {
diff --git a/gtk2_ardour/keyeditor.cc b/gtk2_ardour/keyeditor.cc
index 28cd8b8508..cbbbfafc73 100644
--- a/gtk2_ardour/keyeditor.cc
+++ b/gtk2_ardour/keyeditor.cc
@@ -93,10 +93,10 @@ KeyEditor::KeyEditor ()
unbind_button.show ();
}
-
+
reset_button.add (reset_label);
reset_label.set_markup (string_compose ("<span size=\"large\" weight=\"bold\">%1</span>", _("Reset Bindings to Defaults")));
-
+
reset_box.pack_start (reset_button, true, false);
reset_box.show ();
reset_button.show ();
diff --git a/gtk2_ardour/linux_vst_gui_support.cc b/gtk2_ardour/linux_vst_gui_support.cc
index 4bae45c71e..e5722b2be0 100644
--- a/gtk2_ardour/linux_vst_gui_support.cc
+++ b/gtk2_ardour/linux_vst_gui_support.cc
@@ -74,7 +74,7 @@ bool LXVST_xerror;
int TempErrorHandler(Display *display, XErrorEvent *e)
{
LXVST_xerror = true;
-
+
return 0;
}
@@ -89,14 +89,14 @@ int getXWindowProperty(Window window, Atom atom)
unsigned char *data;
Atom userType;
LXVST_xerror = false;
-
+
/*Use our own Xerror handler while we're in here - in an
attempt to stop the brain dead default Xerror behaviour of
qutting the entire application because of e.g. an invalid
window ID*/
-
+
XErrorHandler olderrorhandler = XSetErrorHandler(TempErrorHandler);
-
+
XGetWindowProperty( LXVST_XDisplay, //The display
window, //The Window
atom, //The property
@@ -109,14 +109,14 @@ int getXWindowProperty(Window window, Atom atom)
&userCount, //Actual number of items stored in the returned data
&bytes, //Number of bytes remaining if a partial read
&data); //The actual data read
-
+
if(LXVST_xerror == false && userCount == 1)
result = *(int*)data;
-
+
XSetErrorHandler(olderrorhandler);
-
+
/*Hopefully this will return zero if the property is not set*/
-
+
return result;
}
@@ -138,14 +138,14 @@ long getXWindowProperty(Window window, Atom atom)
unsigned char *data;
Atom userType;
LXVST_xerror = false;
-
+
/*Use our own Xerror handler while we're in here - in an
attempt to stop the brain dead default Xerror behaviour of
qutting the entire application because of e.g. an invalid
window ID*/
-
+
XErrorHandler olderrorhandler = XSetErrorHandler(TempErrorHandler);
-
+
XGetWindowProperty( LXVST_XDisplay,
window,
atom,
@@ -158,14 +158,14 @@ long getXWindowProperty(Window window, Atom atom)
&userCount,
&bytes,
&data);
-
+
if(LXVST_xerror == false && userCount == 1)
result = *(long*)data;
-
+
XSetErrorHandler(olderrorhandler);
-
+
/*Hopefully this will return zero if the property is not set*/
-
+
return result;
}
@@ -178,70 +178,70 @@ static void
dispatch_x_events (XEvent* event, VSTState* vstfx)
{
/*Handle some of the Events we might be interested in*/
-
+
switch(event->type)
{
/*Configure event - when the window is resized or first drawn*/
-
+
case ConfigureNotify:
{
Window window = event->xconfigure.event;
-
+
int width = event->xconfigure.width;
int height = event->xconfigure.height;
-
+
/*If we get a config notify on the parent window XID then we need to see
if the size has been changed - some plugins re-size their UI window e.g.
when opening a preset manager (you might think that should be spawned as a new window...) */
-
+
/*if the size has changed, we flag this so that in lxvst_pluginui.cc we can make the
change to the GTK parent window in ardour, from its UI thread*/
-
+
if (window == (Window) (vstfx->linux_window)) {
if (width != vstfx->width || height!=vstfx->height) {
vstfx->width = width;
vstfx->height = height;
vstfx->want_resize = 1;
-
+
/*QUIRK : Loomer plugins not only resize the UI but throw it into some random
position at the same time. We need to re-position the window at the origin of
the parent window*/
-
+
if (vstfx->linux_plugin_ui_window) {
XMoveWindow (LXVST_XDisplay, vstfx->linux_plugin_ui_window, 0, 0);
}
}
}
-
+
break;
-
+
}
-
+
/*Reparent Notify - when the plugin UI is reparented into
our Host Window we will get an event here... probably... */
-
+
case ReparentNotify:
{
Window ParentWindow = event->xreparent.parent;
-
+
/*If the ParentWindow matches the window for the vstfx instance then
the Child window must be the XID of the pluginUI window created by the
plugin, so we need to see if it has a callback stuck to it, and if so
set that up in the vstfx */
-
+
/***********************************************************/
/* 64Bit --- This mechanism is not 64Bit compatible at the */
/* present time */
/***********************************************************/
-
+
if (ParentWindow == (Window) (vstfx->linux_window)) {
Window PluginUIWindowID = event->xreparent.window;
-
+
vstfx->linux_plugin_ui_window = PluginUIWindowID;
#ifdef LXVST_32BIT
int result = getXWindowProperty(PluginUIWindowID, XInternAtom(LXVST_XDisplay, "_XEventProc", false));
-
+
if (result == 0) {
vstfx->eventProc = NULL;
} else {
@@ -250,7 +250,7 @@ dispatch_x_events (XEvent* event, VSTState* vstfx)
#endif
#ifdef LXVST_64BIT
long result = getXWindowProperty(PluginUIWindowID, XInternAtom(LXVST_XDisplay, "_XEventProc", false));
-
+
if(result == 0)
vstfx->eventProc = NULL;
else
@@ -259,47 +259,47 @@ dispatch_x_events (XEvent* event, VSTState* vstfx)
}
break;
}
-
+
case ClientMessage:
{
Window window = event->xany.window;
Atom message_type = event->xclient.message_type;
-
+
/*The only client message we are interested in is to signal
that the plugin parent window is now valid and can be passed
to effEditOpen when the editor is launched*/
-
+
if (window == (Window) (vstfx->linux_window)) {
char* message = XGetAtomName(LXVST_XDisplay, message_type);
-
+
if (strcmp(message,"LaunchEditor") == 0) {
if (event->xclient.data.l[0] == 0x0FEEDBAC) {
vstfx_launch_editor (vstfx);
}
}
-
+
XFree(message);
}
break;
}
-
+
default:
break;
}
-
+
/* Some VSTs built with toolkits e.g. JUCE will manager their own UI
autonomously in the plugin, running the UI in its own thread, so once
we have created a parent window for the plugin, its UI takes care of
itself.*/
-
+
/*Other types register a callback as an Xwindow property on the plugin
UI window after they create it. If that is the case, we need to call it
here, passing the XEvent into it*/
-
+
if (vstfx->eventProc == NULL) {
return;
}
-
+
vstfx->eventProc((void*)event);
}
@@ -312,11 +312,11 @@ maybe_set_program (VSTState* vstfx)
}
vstfx->plugin->dispatcher (vstfx->plugin, effSetProgram, 0, vstfx->want_program, NULL, 0);
-
+
if (vstfx->vst_version >= 2) {
vstfx->plugin->dispatcher (vstfx->plugin, 68 /* effEndSetProgram */, 0, 0, NULL, 0);
}
-
+
vstfx->want_program = -1;
}
@@ -336,10 +336,10 @@ void* gui_event_loop (void* ptr)
int LXVST_sched_timer_interval = 40; //ms, 25fps
XEvent event;
uint64_t clock1, clock2;
-
+
clock1 = g_get_monotonic_time();
/*The 'Forever' loop - runs the plugin UIs etc - based on the FST gui event loop*/
-
+
while (!gui_quit)
{
/* handle window creation requests, destroy requests,
@@ -347,37 +347,37 @@ void* gui_event_loop (void* ptr)
/*Look at the XEvent queue - if there are any XEvents we need to handle them,
including passing them to all the plugin (eventProcs) we are currently managing*/
-
+
bool may_sleep = true;
if(LXVST_XDisplay)
{
/*See if there are any events in the queue*/
-
+
int num_events = XPending(LXVST_XDisplay);
if (num_events > 0) {
// keep dispatching events as fast as possible
may_sleep = false;
}
-
+
/*process them if there are any*/
-
+
while(num_events)
{
XNextEvent(LXVST_XDisplay, &event);
-
+
/*Call dispatch events, with the event, for each plugin in the linked list*/
-
+
for (vstfx = vstfx_first; vstfx; vstfx = vstfx->next)
- {
+ {
pthread_mutex_lock(&vstfx->lock);
-
+
dispatch_x_events(&event, vstfx);
-
+
pthread_mutex_unlock(&vstfx->lock);
}
-
+
num_events--;
}
}
@@ -385,7 +385,7 @@ void* gui_event_loop (void* ptr)
/*We don't want to use all the CPU.. */
Glib::usleep(1000);
-
+
/*See if its time for us to do a scheduled event pass on all the plugins*/
clock2 = g_get_monotonic_time();
@@ -395,34 +395,34 @@ void* gui_event_loop (void* ptr)
{
//printf("elapsed %d ms ^= %.2f Hz\n", elapsed_time_ms, 1000.0/(double)elapsed_time_ms); // DEBUG
pthread_mutex_lock (&plugin_mutex);
-
+
again:
/*Parse through the linked list of plugins*/
-
+
for (vstfx = vstfx_first; vstfx; vstfx = vstfx->next)
- {
+ {
pthread_mutex_lock (&vstfx->lock);
/*Window scheduled for destruction*/
-
+
if (vstfx->destroy) {
if (vstfx->linux_window) {
vstfx->plugin->dispatcher (vstfx->plugin, effEditClose, 0, 0, NULL, 0.0);
-
+
XDestroyWindow (LXVST_XDisplay, vstfx->linux_window);
/* FIXME - probably safe to assume we never have an XID of 0 but not explicitly true */
vstfx->linux_window = 0;
vstfx->destroy = FALSE;
}
-
+
vstfx_event_loop_remove_plugin (vstfx);
vstfx->been_activated = FALSE;
pthread_cond_signal (&vstfx->window_status_change);
pthread_mutex_unlock (&vstfx->lock);
-
+
goto again;
}
-
+
/*Window does not yet exist - scheduled for creation*/
/* FIXME - probably safe to assume 0 is not a valid XID but not explicitly true */
@@ -441,9 +441,9 @@ again:
maybe_set_program (vstfx);
vstfx->want_program = -1;
vstfx->want_chunk = 0;
-
+
/*scheduled call to dispatcher*/
-
+
if (vstfx->dispatcher_wantcall) {
vstfx->dispatcher_retval = vstfx->plugin->dispatcher (
vstfx->plugin,
@@ -453,18 +453,18 @@ again:
vstfx->dispatcher_ptr,
vstfx->dispatcher_opt
);
-
+
vstfx->dispatcher_wantcall = 0;
pthread_cond_signal (&vstfx->plugin_dispatcher_called);
}
-
+
/*Call the editor Idle function in the plugin*/
-
+
vstfx->plugin->dispatcher (vstfx->plugin, effEditIdle, 0, 0, NULL, 0);
if(vstfx->wantIdle)
vstfx->plugin->dispatcher (vstfx->plugin, 53, 0, 0, NULL, 0);
-
+
pthread_mutex_unlock (&vstfx->lock);
}
pthread_mutex_unlock (&plugin_mutex);
@@ -490,54 +490,54 @@ int vstfx_init (void* ptr)
{
int thread_create_result;
-
+
pthread_attr_t thread_attributes;
-
+
/*Init the attribs to defaults*/
-
+
pthread_attr_init(&thread_attributes);
-
+
/*Make sure the thread is joinable - this should be the default anyway -
so we can join to it on vstfx_exit*/
-
+
pthread_attr_setdetachstate(&thread_attributes, PTHREAD_CREATE_JOINABLE);
-
+
/*This is where we need to open a connection to X, and start the GUI thread*/
-
+
/*Open our connection to X - all linuxVST plugin UIs handled by the LXVST engine
will talk to X down this connection - X cannot handle multi-threaded access via
the same Display* */
-
+
if(LXVST_XDisplay==NULL)
LXVST_XDisplay = XOpenDisplay(NULL); //We might be able to make this open a specific screen etc
/*Drop out and report the error if we fail to connect to X */
-
+
if(LXVST_XDisplay==NULL)
{
vstfx_error ("** ERROR ** VSTFX: Failed opening connection to X");
-
+
return -1;
}
-
+
/*We have a connection to X - so start the gui event loop*/
-
+
/*Create the thread - use default attrs for now, don't think we need anything special*/
-
+
thread_create_result = pthread_create(&LXVST_gui_event_thread, NULL, gui_event_loop, NULL);
-
+
if(thread_create_result!=0)
{
/*There was a problem starting the GUI event thread*/
-
+
vstfx_error ("** ERROR ** VSTFX: Failed starting GUI event thread");
-
+
XCloseDisplay(LXVST_XDisplay);
-
+
return -1;
}
-
+
return 0;
}
@@ -546,10 +546,10 @@ int vstfx_init (void* ptr)
void vstfx_exit()
{
gui_quit = 1;
-
+
/*We need to pthread_join the gui_thread here so
we know when it has stopped*/
-
+
pthread_join(LXVST_gui_event_thread, NULL);
}
@@ -565,14 +565,14 @@ int vstfx_run_editor (VSTState* vstfx)
vstfx_first = vstfx;
} else {
VSTState* p = vstfx_first;
-
+
while (p->next) {
p = p->next;
}
p->next = vstfx;
-
+
/* Mark the new end of the list */
-
+
vstfx->next = NULL;
}
@@ -581,11 +581,11 @@ int vstfx_run_editor (VSTState* vstfx)
/* wait for the plugin editor window to be created (or not) */
pthread_mutex_lock (&vstfx->lock);
-
+
if (!vstfx->linux_window) {
pthread_cond_wait (&vstfx->window_status_change, &vstfx->lock);
}
-
+
pthread_mutex_unlock (&vstfx->lock);
if (!vstfx->linux_window) {
@@ -602,7 +602,7 @@ after run_editor has added the plugin (editor) to the linked list*/
int vstfx_create_editor (VSTState* vstfx)
{
Window parent_window;
-
+
int x_size = 1;
int y_size = 1;
@@ -613,10 +613,10 @@ int vstfx_create_editor (VSTState* vstfx)
vstfx_error ("** ERROR ** VSTFX: Plugin \"%s\" has no editor", vstfx->handle->name);
return -1;
}
-
-
+
+
/*Create an XWindow for the plugin to inhabit*/
-
+
parent_window = XCreateSimpleWindow (
LXVST_XDisplay,
DefaultRootWindow(LXVST_XDisplay),
@@ -628,35 +628,35 @@ int vstfx_create_editor (VSTState* vstfx)
0,
0
);
-
+
/*Select the events we are interested in receiving - we need Substructure notify so that
if the plugin resizes its window - e.g. Loomer Manifold then we get a message*/
-
+
XSelectInput(LXVST_XDisplay,
parent_window,
SubstructureNotifyMask | ButtonPressMask | ButtonReleaseMask | ButtonMotionMask | ExposureMask);
-
+
vstfx->linux_window = parent_window;
-
+
vstfx->xid = parent_window; //vstfx->xid will be referenced to connect to GTK UI in ardour later
-
+
/*Because the plugin may be operating on a different Display* to us, and therefore
the two event queues can be asynchronous, although we have created the window on
our display, we can't guarantee it exists in the server yet, which will
cause BadWindow crashes if the plugin tries to use it.
-
+
It would be nice to use CreateNotify events here, but they don't get
through on all window managers, so instead we pass a client message
into out queue, after the XCreateWindow. When this message pops out
in our event handler, it will trigger the second stage of plugin
Editor instantiation, and by then the Window should be valid...*/
-
+
XClientMessageEvent event;
-
+
/*Create an atom to identify our message (only if it doesn't already exist)*/
-
+
Atom WindowActiveAtom = XInternAtom(LXVST_XDisplay, "LaunchEditor", false);
-
+
event.type = ClientMessage;
event.send_event = true;
event.window = parent_window;
@@ -664,9 +664,9 @@ int vstfx_create_editor (VSTState* vstfx)
event.format = 32; //Data format
event.data.l[0] = 0x0FEEDBAC; //Something we can recognize later
-
+
/*Push the event into the queue on our Display*/
-
+
XSendEvent(LXVST_XDisplay, parent_window, FALSE, NoEventMask, (XEvent*)&event);
return 0;
@@ -681,22 +681,22 @@ vstfx_launch_editor (VSTState* vstfx)
is now valid in the XServer and can be passed to the plugin in effEditOpen
without generating BadWindow errors when the plugin reparents itself into our
parent window*/
-
+
if(vstfx->been_activated)
return 0;
-
+
Window parent_window;
struct ERect* er;
-
+
int x_size = 1;
int y_size = 1;
-
+
parent_window = vstfx->linux_window;
-
+
/*Open the editor - Bah! we have to pass the int windowID as a void pointer - yuck
it gets cast back to an int as the parent window XID in the plugin - and we have to pass the
Display* as a long */
-
+
/**************************************************************/
/* 64Bit --- parent window is an int passed as a void* so */
/* that should be ok for 64Bit machines */
@@ -709,36 +709,36 @@ vstfx_launch_editor (VSTState* vstfx)
/* */
/* linuxDSP VSTs don't use the host Display* at all */
/**************************************************************/
-
+
vstfx->plugin->dispatcher (vstfx->plugin, effEditOpen, 0, (long)LXVST_XDisplay, (void*)(parent_window), 0 );
-
+
/*QUIRK - some plugins need a slight delay after opening the editor before you can
ask the window size or they might return zero - specifically discoDSP */
-
+
Glib::usleep(100000);
-
+
/*Now we can find out how big the parent window should be (and try) to resize it*/
-
+
vstfx->plugin->dispatcher (vstfx->plugin, effEditGetRect, 0, 0, &er, 0 );
x_size = er->right - er->left;
y_size = er->bottom - er->top;
-
+
vstfx->width = x_size;
vstfx->height = y_size;
-
+
XResizeWindow(LXVST_XDisplay, parent_window, x_size, y_size);
-
+
XFlush (LXVST_XDisplay);
-
+
/*Not sure if we need to map the window or if the plugin will do it for us
it should be ok because XReparentWindow generates a Map event*/
-
+
/*mark the editor as activated - mainly so that vstfx_get_XID
will know it is valid*/
vstfx->been_activated = TRUE;
-
+
pthread_cond_signal (&vstfx->window_status_change);
return 0;
}
@@ -765,10 +765,10 @@ vstfx_event_loop_remove_plugin (VSTState* vstfx)
so we don't need to lock here - if we did there would be
a deadlock anyway
*/
-
+
VSTState* p;
VSTState* prev;
-
+
for (p = vstfx_first, prev = NULL; p; prev = p, p = p->next) {
if (p == vstfx) {
if (prev) {
diff --git a/gtk2_ardour/location_ui.cc b/gtk2_ardour/location_ui.cc
index 1e5334298b..4a2fc45a47 100644
--- a/gtk2_ardour/location_ui.cc
+++ b/gtk2_ardour/location_ui.cc
@@ -323,7 +323,7 @@ LocationEditRow::set_location (Location *loc)
set_tooltip (start_to_playhead_button, _("Set range start from playhead location"));
set_tooltip (end_to_playhead_button, _("Set range end from playhead location"));
-
+
} else {
set_tooltip (remove_button, _("Remove this marker"));
@@ -903,7 +903,7 @@ LocationUI::location_added (Location* location)
loc.sort (LocationSortByStart ());
LocationEditRow* erow = manage (new LocationEditRow (_session, location));
-
+
erow->set_clock_group (*_clock_group);
erow->remove_requested.connect (sigc::mem_fun (*this, &LocationUI::location_remove_requested));
@@ -1132,7 +1132,7 @@ LocationUI::clock_mode_from_session_instant_xml () const
if (!p) {
return ARDOUR_UI::instance()->secondary_clock->mode();
}
-
+
return (AudioClock::Mode) string_2_enum (p->value (), AudioClock::Mode);
}
diff --git a/gtk2_ardour/lxvst_plugin_ui.cc b/gtk2_ardour/lxvst_plugin_ui.cc
index d2f6e757ed..ad8bc0175a 100644
--- a/gtk2_ardour/lxvst_plugin_ui.cc
+++ b/gtk2_ardour/lxvst_plugin_ui.cc
@@ -38,8 +38,8 @@ LXVSTPluginUI::LXVSTPluginUI (boost::shared_ptr<PluginInsert> pi, boost::shared_
LXVSTPluginUI::~LXVSTPluginUI ()
{
- _screen_update_connection.disconnect();
-
+ _screen_update_connection.disconnect();
+
// plugin destructor destroys the custom GUI, via the vstfx engine,
// and then our PluginUIWindow does the rest
}
@@ -67,35 +67,35 @@ LXVSTPluginUI::resize_callback ()
/* We could maybe use this to resize the plugin GTK parent window
if required
*/
-
+
if (!_vst->state()->want_resize) {
return;
}
int new_height = _vst->state()->height;
int new_width = _vst->state()->width;
-
+
void* gtk_parent_window = _vst->state()->extra_data;
-
+
if (gtk_parent_window) {
((Gtk::Window*) gtk_parent_window)->resize (new_width, new_height + LXVST_H_FIDDLE);
}
-
+
_vst->state()->want_resize = 0;
}
int
LXVSTPluginUI::get_preferred_height ()
-{
+{
/* XXX: FIXME */
-
+
/* We have to return the required height of the plugin UI window + a fiddle factor
because we can't know how big the preset menu bar is until the window is realised
and we can't realise it until we have told it how big we would like it to be
which we can't do until it is realised etc
*/
- // May not be 40 for all screen res etc
+ // May not be 40 for all screen res etc
return VSTPluginUI::get_preferred_height () + LXVST_H_FIDDLE;
}
@@ -103,9 +103,9 @@ int
LXVSTPluginUI::package (Gtk::Window& win)
{
VSTPluginUI::package (win);
-
+
/* Map the UI start and stop updating events to 'Map' events on the Window */
-
+
win.signal_map_event().connect (mem_fun (*this, &LXVSTPluginUI::start_updating));
win.signal_unmap_event().connect (mem_fun (*this, &LXVSTPluginUI::stop_updating));
@@ -129,9 +129,9 @@ LXVSTPluginUI::get_XID ()
created and we get bad Window errors when trying
to embed it in the GTK UI
*/
-
+
pthread_mutex_lock (&(_vst->state()->lock));
-
+
/* The Window may be scheduled for creation
but not actually created by the gui_event_loop yet -
spin here until it has been activated. Possible
@@ -139,21 +139,21 @@ LXVSTPluginUI::get_XID ()
should not be called here if the window doesn't
exist or will never exist
*/
-
+
while (!(_vst->state()->been_activated)) {
Glib::usleep (1000);
}
-
+
int const id = _vst->state()->xid;
-
+
pthread_mutex_unlock (&(_vst->state()->lock));
-
+
/* Finally it might be safe to return the ID -
problems will arise if we return either a zero ID
and GTK tries to socket it or if we return an ID
which hasn't yet become real to the server
*/
-
+
return id;
}
@@ -166,7 +166,7 @@ static int
gtk_xerror_handler (Display*, XErrorEvent*)
{
std::cerr << "** ERROR ** LXVSTPluginUI : Trapped an X Window System Error" << std::endl;
-
+
return 0;
}
diff --git a/gtk2_ardour/lxvst_plugin_ui.h b/gtk2_ardour/lxvst_plugin_ui.h
index 7342102bd7..14440c3b38 100644
--- a/gtk2_ardour/lxvst_plugin_ui.h
+++ b/gtk2_ardour/lxvst_plugin_ui.h
@@ -37,7 +37,7 @@ class LXVSTPluginUI : public VSTPluginUI
~LXVSTPluginUI ();
int get_preferred_height ();
-
+
bool start_updating (GdkEventAny *);
bool stop_updating (GdkEventAny *);
diff --git a/gtk2_ardour/main.cc b/gtk2_ardour/main.cc
index e8aee1cdbe..b40490daa1 100644
--- a/gtk2_ardour/main.cc
+++ b/gtk2_ardour/main.cc
@@ -372,7 +372,7 @@ int main (int argc, char *argv[])
error << _("Could not complete pre-GUI initialization") << endmsg;
exit (1);
}
-
+
try {
ui = new ARDOUR_UI (&argc, &argv, localedir.c_str());
} catch (failed_constructor& err) {
diff --git a/gtk2_ardour/main_clock.h b/gtk2_ardour/main_clock.h
index 696b7e21e6..bf0712686a 100644
--- a/gtk2_ardour/main_clock.h
+++ b/gtk2_ardour/main_clock.h
@@ -28,7 +28,7 @@ public:
MainClock (const std::string& clock_name, const std::string& widget_name, bool primary);
private:
-
+
// Editor *_editor;
void build_ops_menu ();
diff --git a/gtk2_ardour/marker.cc b/gtk2_ardour/marker.cc
index 30be8fd786..2d9da96b0f 100644
--- a/gtk2_ardour/marker.cc
+++ b/gtk2_ardour/marker.cc
@@ -261,12 +261,12 @@ ArdourMarker::ArdourMarker (PublicEditor& ed, ArdourCanvas::Container& parent, g
group = new ArdourCanvas::Container (&parent, ArdourCanvas::Duple (unit_position, 0));
#ifdef CANVAS_DEBUG
group->name = string_compose ("Marker::group for %1", annotation);
-#endif
+#endif
_name_background = new ArdourCanvas::Rectangle (group);
#ifdef CANVAS_DEBUG
_name_background->name = string_compose ("Marker::_name_background for %1", annotation);
-#endif
+#endif
/* adjust to properly locate the tip */
@@ -286,7 +286,7 @@ ArdourMarker::ArdourMarker (PublicEditor& ed, ArdourCanvas::Container& parent, g
layout->set_font_description (name_font);
Gtkmm2ext::get_ink_pixel_size (layout, width, name_height);
-
+
_name_item = new ArdourCanvas::Text (group);
CANVAS_DEBUG_NAME (_name_item, string_compose ("ArdourMarker::_name_item for %1", annotation));
_name_item->set_font_description (name_font);
@@ -303,7 +303,7 @@ ArdourMarker::ArdourMarker (PublicEditor& ed, ArdourCanvas::Container& parent, g
group->set_data ("marker", this);
mark->set_data ("marker", this);
-
+
if (handle_events) {
group->Event.connect (sigc::bind (sigc::mem_fun (editor, &PublicEditor::canvas_marker_event), group, this));
}
@@ -420,10 +420,10 @@ ArdourMarker::setup_name_display ()
if (label_on_left ()) {
_name_item->set_x_position (-name_width);
}
-
+
_name_item->clamp_width (name_width);
_name_item->set (_name);
-
+
if (label_on_left ()) {
/* adjust right edge of background to fit text */
_name_background->set_x0 (_name_item->position().x - padding);
diff --git a/gtk2_ardour/meter_strip.h b/gtk2_ardour/meter_strip.h
index 825bd6923d..dfeb406976 100644
--- a/gtk2_ardour/meter_strip.h
+++ b/gtk2_ardour/meter_strip.h
@@ -142,7 +142,7 @@ class MeterStrip : public Gtk::VBox, public RouteUI
void update_button_box ();
void update_name_box ();
void name_changed ();
-
+
void route_color_changed ();
bool _suspend_menu_callbacks;
diff --git a/gtk2_ardour/midi_channel_selector.cc b/gtk2_ardour/midi_channel_selector.cc
index 9502a6879b..40ab968358 100644
--- a/gtk2_ardour/midi_channel_selector.cc
+++ b/gtk2_ardour/midi_channel_selector.cc
@@ -380,15 +380,15 @@ MidiChannelSelectorWindow::build ()
vpacker->pack_start (capture_all_button);
capture_all_button.signal_toggled().connect (sigc::bind (sigc::mem_fun (*this, &MidiChannelSelectorWindow::capture_mode_toggled), AllChannels));
-
+
vpacker->pack_start (capture_filter_button);
capture_filter_button.signal_toggled().connect (sigc::bind (sigc::mem_fun (*this, &MidiChannelSelectorWindow::capture_mode_toggled), FilterChannels));
-
+
vpacker->pack_start (capture_force_button);
capture_force_button.signal_toggled().connect (sigc::bind (sigc::mem_fun (*this, &MidiChannelSelectorWindow::capture_mode_toggled), ForceChannel));
vpacker->pack_start (capture_mask_box);
-
+
capture_controls = manage (new HBox);
capture_controls->set_spacing (6);
@@ -416,10 +416,10 @@ MidiChannelSelectorWindow::build ()
vpacker->pack_start (playback_all_button);
playback_all_button.signal_toggled().connect (sigc::bind (sigc::mem_fun (*this, &MidiChannelSelectorWindow::playback_mode_toggled), AllChannels));
-
+
vpacker->pack_start (playback_filter_button);
playback_filter_button.signal_toggled().connect (sigc::bind (sigc::mem_fun (*this, &MidiChannelSelectorWindow::playback_mode_toggled), FilterChannels));
-
+
vpacker->pack_start (playback_force_button);
playback_force_button.signal_toggled().connect (sigc::bind (sigc::mem_fun (*this, &MidiChannelSelectorWindow::playback_mode_toggled), ForceChannel));
@@ -496,7 +496,7 @@ MidiChannelSelectorWindow::invert_capture_mask ()
track->set_capture_channel_mask (~track->get_capture_channel_mask());
}
}
-
+
void
MidiChannelSelectorWindow::set_playback_selected_channels (uint16_t mask)
{
@@ -510,7 +510,7 @@ MidiChannelSelectorWindow::set_playback_selected_channels (uint16_t mask)
playback_buttons[i]->set_active ((1<<i) & mask);
}
break;
-
+
case ForceChannel:
/* only set the lowest set channel in the mask as active */
for (uint16_t i = 0; i < 16; i++) {
@@ -533,7 +533,7 @@ MidiChannelSelectorWindow::set_capture_selected_channels (uint16_t mask)
capture_buttons[i]->set_active ((1<<i) & mask);
}
break;
-
+
case ForceChannel:
/* only set the lowest set channel in the mask as active */
for (uint16_t i = 0; i < 16; i++) {
@@ -605,10 +605,10 @@ MidiChannelSelectorWindow::playback_mode_changed ()
if (playback_buttons.empty()) {
Gtkmm2ext::container_clear (playback_mask_box);
-
+
ToggleButton* tb;
RadioButtonGroup group;
-
+
for (uint32_t n = 0; n < 16; ++n) {
char buf[3];
snprintf (buf, sizeof (buf), "%d", n+1);
@@ -638,7 +638,7 @@ MidiChannelSelectorWindow::playback_mode_changed ()
tb->set_sensitive (false);
}
}
-
+
if (mode != ForceChannel) {
set_playback_selected_channels (track->get_playback_channel_mask());
}
@@ -703,10 +703,10 @@ MidiChannelSelectorWindow::capture_mode_changed ()
if (capture_buttons.empty()) {
Gtkmm2ext::container_clear (capture_mask_box);
-
+
ToggleButton* tb;
RadioButtonGroup group;
-
+
for (uint32_t n = 0; n < 16; ++n) {
char buf[3];
snprintf (buf, sizeof (buf), "%d", n+1);
@@ -736,7 +736,7 @@ MidiChannelSelectorWindow::capture_mode_changed ()
tb->set_sensitive (false);
}
}
-
+
if (mode != ForceChannel) {
set_capture_selected_channels (track->get_capture_channel_mask());
}
@@ -803,7 +803,7 @@ MidiChannelSelectorWindow::capture_mode_toggled (ChannelMode mode)
so we take action only if the button is active (i.e it is the one
just clicked on)
*/
-
+
switch (mode) {
case AllChannels:
if (capture_all_button.get_active()) {
@@ -833,7 +833,7 @@ MidiChannelSelectorWindow::playback_mode_toggled (ChannelMode mode)
so we take action only if the button is active (i.e it is the one
just clicked on)
*/
-
+
switch (mode) {
case AllChannels:
if (playback_all_button.get_active()) {
@@ -860,7 +860,7 @@ MidiChannelSelectorWindow::set_channel_colors (const uint32_t new_channel_colors
char color_normal[8];
char color_active[8];
-
+
snprintf(color_normal, 8, "#%x", UINT_INTERPOLATE(new_channel_colors[n], 0x000000ff, 0.6));
snprintf(color_active, 8, "#%x", new_channel_colors[n]);
diff --git a/gtk2_ardour/midi_export_dialog.cc b/gtk2_ardour/midi_export_dialog.cc
index dc15668dbd..34469adc39 100644
--- a/gtk2_ardour/midi_export_dialog.cc
+++ b/gtk2_ardour/midi_export_dialog.cc
@@ -67,5 +67,5 @@ std::string
MidiExportDialog::get_path () const
{
return file_chooser.get_filename ();
-
+
}
diff --git a/gtk2_ardour/midi_list_editor.cc b/gtk2_ardour/midi_list_editor.cc
index 29f81bdf5b..6334c38dcc 100644
--- a/gtk2_ardour/midi_list_editor.cc
+++ b/gtk2_ardour/midi_list_editor.cc
@@ -72,7 +72,7 @@ MidiListEditor::MidiListEditor (Session* s, boost::shared_ptr<MidiRegion> r, boo
if (note_length_map.empty()) {
fill_note_length_map ();
}
-
+
/* We do not handle nested sources/regions. Caller should have tackled this */
if (r->max_source_level() > 0) {
@@ -90,7 +90,7 @@ MidiListEditor::MidiListEditor (Session* s, boost::shared_ptr<MidiRegion> r, boo
note_length_model = ListStore::create (note_length_columns);
TreeModel::Row row;
-
+
for (std::map<int,string>::iterator i = note_length_map.begin(); i != note_length_map.end(); ++i) {
row = *(note_length_model->append());
row[note_length_columns.ticks] = i->first;
@@ -152,7 +152,7 @@ MidiListEditor::MidiListEditor (Session* s, boost::shared_ptr<MidiRegion> r, boo
buttons.attach (sound_notes_button, 0, 1, 0, 1);
Glib::RefPtr<Gtk::Action> act = ActionManager::get_action ("Editor", "sound-midi-notes");
if (act) {
- gtk_activatable_set_related_action (GTK_ACTIVATABLE (sound_notes_button.gobj()), act->gobj());
+ gtk_activatable_set_related_action (GTK_ACTIVATABLE (sound_notes_button.gobj()), act->gobj());
}
view.show ();
@@ -191,7 +191,7 @@ MidiListEditor::scroll_event (GdkEventScroll* ev)
if (!view.get_path_at_pos (ev->x, ev->y, path, col, cellx, celly)) {
return false;
}
-
+
if (view.get_selection()->count_selected_rows() == 0) {
was_selected = false;
} else if (view.get_selection()->is_selected (path)) {
@@ -199,7 +199,7 @@ MidiListEditor::scroll_event (GdkEventScroll* ev)
} else {
was_selected = false;
}
-
+
int colnum = GPOINTER_TO_UINT (col->get_data (X_("colnum")));
switch (colnum) {
@@ -274,19 +274,19 @@ MidiListEditor::scroll_event (GdkEventScroll* ev)
if (was_selected) {
/* use selection */
-
+
TreeView::Selection::ListHandle_Path rows = view.get_selection()->get_selected_rows ();
TreeModel::iterator iter;
boost::shared_ptr<NoteType> note;
-
+
for (TreeView::Selection::ListHandle_Path::iterator i = rows.begin(); i != rows.end(); ++i) {
previous_selection.push_back (*i);
if ((iter = model->get_iter (*i))) {
-
- note = (*iter)[columns._note];
-
+
+ note = (*iter)[columns._note];
+
switch (prop) {
case MidiModel::NoteDiffCommand::StartTime:
if (note->time() + fdelta >= 0) {
@@ -321,7 +321,7 @@ MidiListEditor::scroll_event (GdkEventScroll* ev)
} else {
/* just this row */
-
+
TreeModel::iterator iter;
iter = model->get_iter (path);
@@ -329,7 +329,7 @@ MidiListEditor::scroll_event (GdkEventScroll* ev)
if (iter) {
boost::shared_ptr<NoteType> note = (*iter)[columns._note];
-
+
switch (prop) {
case MidiModel::NoteDiffCommand::StartTime:
if (note->time() + fdelta >= 0) {
@@ -364,7 +364,7 @@ MidiListEditor::scroll_event (GdkEventScroll* ev)
m->apply_command (*_session, cmd);
/* reset selection to be as it was before we rebuilt */
-
+
for (vector<TreeModel::Path>::iterator i = previous_selection.begin(); i != previous_selection.end(); ++i) {
view.get_selection()->select (*i);
}
@@ -401,7 +401,7 @@ MidiListEditor::key_press (GdkEventKey* ev)
ret = true;
}
break;
-
+
case GDK_Up:
case GDK_uparrow:
if (edit_column > 0) {
@@ -435,7 +435,7 @@ MidiListEditor::key_press (GdkEventKey* ev)
case GDK_Escape:
stop_editing (true);
break;
-
+
}
return ret;
@@ -486,7 +486,7 @@ MidiListEditor::key_release (GdkEventKey* ev)
ret = true;
}
break;
-
+
case GDK_r:
if (_session && Gtkmm2ext::Keyboard::modifier_state_contains (ev->state, Gtkmm2ext::Keyboard::PrimaryModifier)) {
_session->redo (1);
@@ -626,7 +626,7 @@ MidiListEditor::edited (const std::string& path, const std::string& text)
if (sscanf (text.c_str(), "%lf", &fval) == 1) {
/* numeric value entered */
-
+
if (text.find ('.') == string::npos && text.find (',') == string::npos) {
/* integral => units are ticks */
fval = fval / BBT_Time::ticks_per_beat;
@@ -649,13 +649,13 @@ MidiListEditor::edited (const std::string& path, const std::string& text)
* displaying numeric value ... use new value
* from note length map, and convert to beats.
*/
-
+
for (x = note_length_map.begin(); x != note_length_map.end(); ++x) {
if (x->second == text) {
break;
}
}
-
+
if (x != note_length_map.end()) {
fval = x->first / BBT_Time::ticks_per_beat;
}
@@ -665,7 +665,7 @@ MidiListEditor::edited (const std::string& path, const std::string& text)
fval = -1.0;
if (text != x->second) {
-
+
/* get ticks for the newly selected
* note length
*/
@@ -675,7 +675,7 @@ MidiListEditor::edited (const std::string& path, const std::string& text)
break;
}
}
-
+
if (x != note_length_map.end()) {
/* convert to beats */
fval = (double) x->first / BBT_Time::ticks_per_beat;
@@ -702,12 +702,12 @@ MidiListEditor::edited (const std::string& path, const std::string& text)
MidiModel::NoteDiffCommand* cmd = m->new_note_diff_command (opname);
TreeView::Selection::ListHandle_Path rows = view.get_selection()->get_selected_rows ();
-
+
for (TreeView::Selection::ListHandle_Path::iterator i = rows.begin(); i != rows.end(); ++i) {
if ((iter = model->get_iter (*i))) {
- note = (*iter)[columns._note];
-
+ note = (*iter)[columns._note];
+
switch (prop) {
case MidiModel::NoteDiffCommand::Velocity:
cmd->change (note, prop, (uint8_t) (note->velocity() + idelta));
@@ -731,7 +731,7 @@ MidiListEditor::edited (const std::string& path, const std::string& text)
/* model has been redisplayed by now */
/* keep selected row(s), move cursor there, don't continue editing */
-
+
TreeViewColumn* col = view.get_column (edit_column);
view.set_cursor (edit_path, *col, 0);
@@ -776,7 +776,7 @@ MidiListEditor::redisplay_model ()
const Evoral::Beats dur = (*i)->end_time() - (*i)->time();
bbt.beats = dur.get_beats ();
bbt.ticks = dur.get_ticks ();
-
+
uint64_t len_ticks = (*i)->length().to_ticks();
std::map<int,string>::iterator x = note_length_map.find (len_ticks);
@@ -811,7 +811,7 @@ MidiListEditor::selection_changed ()
for (TreeView::Selection::ListHandle_Path::iterator i = rows.begin(); i != rows.end(); ++i) {
if ((iter = model->get_iter (*i))) {
- note = (*iter)[columns._note];
+ note = (*iter)[columns._note];
player->add (note);
}
}
diff --git a/gtk2_ardour/midi_region_view.cc b/gtk2_ardour/midi_region_view.cc
index 09b20f048d..5300a82574 100644
--- a/gtk2_ardour/midi_region_view.cc
+++ b/gtk2_ardour/midi_region_view.cc
@@ -271,7 +271,7 @@ MidiRegionView::init (bool wfd)
NoteBase::NoteBaseDeleted.connect (note_delete_connection, MISSING_INVALIDATOR,
boost::bind (&MidiRegionView::maybe_remove_deleted_note_from_selection, this, _1),
gui_context());
-
+
if (wfd) {
Glib::Threads::Mutex::Lock lm(midi_region()->midi_source(0)->mutex());
midi_region()->midi_source(0)->load_model(lm);
@@ -502,10 +502,10 @@ MidiRegionView::button_press (GdkEventButton* ev)
}
if (_mouse_state != SelectTouchDragging) {
-
+
_pressed_button = ev->button;
_mouse_state = Pressed;
-
+
return true;
}
@@ -578,7 +578,7 @@ MidiRegionView::button_release (GdkEventButton* ev)
grid snap without it overlapping this one.
*/
beats -= Evoral::Beats::tick();
-
+
create_note_at (editor.pixel_to_sample (event_x), event_y, beats, true);
break;
@@ -646,9 +646,9 @@ MidiRegionView::motion (GdkEventMotion* ev)
case Pressed:
if (_pressed_button == 1) {
-
+
MouseMode m = editor.current_mouse_mode();
-
+
if (m == MouseDraw || (m == MouseContent && Keyboard::modifier_state_contains (ev->state, Keyboard::insert_note_modifier()))) {
editor.drags()->set (new NoteCreateDrag (dynamic_cast<Editor *> (&editor), group, this), (GdkEvent *) ev);
_mouse_state = AddDragging;
@@ -677,7 +677,7 @@ MidiRegionView::motion (GdkEventMotion* ev)
case AddDragging:
editor.drags()->motion_handler ((GdkEvent *) ev, false);
break;
-
+
case SelectTouchDragging:
return false;
@@ -733,7 +733,7 @@ MidiRegionView::key_press (GdkEventKey* ev)
*/
bool unmodified = Keyboard::no_modifier_keys_pressed (ev);
-
+
if (unmodified && (ev->keyval == GDK_Alt_L || ev->keyval == GDK_Alt_R)) {
_mouse_state = SelectTouchDragging;
return true;
@@ -878,7 +878,7 @@ MidiRegionView::velocity_edit ()
if (_selection.empty()) {
return;
}
-
+
/* pick a note somewhat at random (since Selection is a set<>) to
* provide the "current" velocity for the dialog.
*/
@@ -1191,7 +1191,7 @@ MidiRegionView::redisplay_model()
bool visible;
if (note_in_region_range (note, visible)) {
-
+
if (!empty_when_starting && (cne = find_canvas_note (note)) != 0) {
cne->validate ();
@@ -1216,7 +1216,7 @@ MidiRegionView::redisplay_model()
}
} else {
-
+
if (!empty_when_starting && (cne = find_canvas_note (note)) != 0) {
cne->validate ();
cne->hide ();
@@ -1229,17 +1229,17 @@ MidiRegionView::redisplay_model()
if (!empty_when_starting) {
for (Events::iterator i = _events.begin(); i != _events.end(); ) {
if (!(*i)->valid ()) {
-
+
for (vector<GhostRegion*>::iterator j = ghosts.begin(); j != ghosts.end(); ++j) {
MidiGhostRegion* gr = dynamic_cast<MidiGhostRegion*> (*j);
if (gr) {
gr->remove_note (*i);
}
}
-
+
delete *i;
i = _events.erase (i);
-
+
} else {
++i;
}
@@ -1303,7 +1303,7 @@ MidiRegionView::display_sysexes()
for (MidiModel::SysExes::const_iterator i = _model->sysexes().begin(); i != _model->sysexes().end(); ++i) {
const boost::shared_ptr<const Evoral::MIDIEvent<Evoral::Beats> > mev =
boost::static_pointer_cast<const Evoral::MIDIEvent<Evoral::Beats> > (*i);
-
+
if (mev) {
if (mev->is_spp() || mev->is_mtc_quarter() || mev->is_mtc_full()) {
have_periodic_system_messages = true;
@@ -1311,19 +1311,19 @@ MidiRegionView::display_sysexes()
}
}
}
-
+
if (have_periodic_system_messages) {
double zoom = trackview.editor().get_current_zoom (); // frames per pixel
-
+
/* get an approximate value for the number of samples per video frame */
-
+
double video_frame = trackview.session()->frame_rate() * (1.0/30);
-
+
/* if we are zoomed out beyond than the cutoff (i.e. more
* frames per pixel than frames per 4 video frames), don't
* show periodic sysex messages.
*/
-
+
if (zoom > (video_frame*4)) {
display_periodic_messages = false;
}
@@ -1955,7 +1955,7 @@ patch_applies (const ARDOUR::MidiModel::constPatchChangePtr pc, Evoral::Beats ti
{
return pc->time() <= time && pc->channel() == channel;
}
-
+
void
MidiRegionView::get_patch_key_at (Evoral::Beats time, uint8_t channel, MIDI::Name::PatchPrimaryKey& key) const
{
@@ -2255,13 +2255,13 @@ MidiRegionView::select_matching_notes (uint8_t notenum, uint16_t channel_mask, b
uint8_t high_note = 0;
MidiModel::Notes& notes (_model->notes());
_optimization_iterator = _events.begin();
-
+
if (extend && !have_selection) {
extend = false;
}
/* scan existing selection to get note range */
-
+
for (Selection::iterator i = _selection.begin(); i != _selection.end(); ++i) {
if ((*i)->note()->note() < low_note) {
low_note = (*i)->note()->note();
@@ -2270,7 +2270,7 @@ MidiRegionView::select_matching_notes (uint8_t notenum, uint16_t channel_mask, b
high_note = (*i)->note()->note();
}
}
-
+
if (!add) {
clear_selection ();
@@ -2593,7 +2593,7 @@ MidiRegionView::note_dropped(NoteBase *, frameoffset_t dt, int8_t dnote)
start_note_diff_command (_("move notes"));
for (Selection::iterator i = _selection.begin(); i != _selection.end() ; ++i) {
-
+
framepos_t new_frames = source_beats_to_absolute_frames ((*i)->note()->time()) + dt;
Evoral::Beats new_time = absolute_frames_to_source_beats (new_frames);
@@ -2857,7 +2857,7 @@ MidiRegionView::commit_resizing (NoteBase* primary, bool at_front, double delta_
/* Get the new x position for this resize, which is in pixels relative
* to the region position.
*/
-
+
double current_x;
if (at_front) {
@@ -3711,7 +3711,7 @@ MidiRegionView::update_ghost_note (double x, double y)
_note_group->canvas_to_item (x, y);
PublicEditor& editor = trackview.editor ();
-
+
framepos_t const unsnapped_frame = editor.pixel_to_sample (x);
framecnt_t grid_frames;
framepos_t const f = snap_frame_to_grid_underneath (unsnapped_frame, grid_frames);
@@ -4084,7 +4084,7 @@ framepos_t
MidiRegionView::snap_frame_to_grid_underneath (framepos_t p, framecnt_t& grid_frames) const
{
PublicEditor& editor = trackview.editor ();
-
+
const Evoral::Beats grid_beats = get_grid_beats(p);
grid_frames = region_beats_to_region_frames (grid_beats);
diff --git a/gtk2_ardour/midi_region_view.h b/gtk2_ardour/midi_region_view.h
index bcc4e7aca2..786a7ec7c4 100644
--- a/gtk2_ardour/midi_region_view.h
+++ b/gtk2_ardour/midi_region_view.h
@@ -309,7 +309,7 @@ public:
Selection selection () const {
return _selection;
}
-
+
void selection_as_notelist (Notes& selected, bool allow_all_if_none_selected = false);
void enable_display (bool);
@@ -331,7 +331,7 @@ public:
void clear_selection (bool signal = true) { clear_selection_except (0, signal); }
ARDOUR::InstrumentInfo& instrument_info() const;
-
+
protected:
void region_resized (const PBD::PropertyChange&);
@@ -401,7 +401,7 @@ private:
uint8_t _current_range_min;
uint8_t _current_range_max;
-
+
typedef std::list<NoteBase*> Events;
typedef std::vector< boost::shared_ptr<PatchChange> > PatchChanges;
typedef std::vector< boost::shared_ptr<SysEx> > SysExes;
@@ -514,7 +514,7 @@ private:
bool _mouse_changed_selection;
framepos_t snap_frame_to_grid_underneath (framepos_t p, framecnt_t &) const;
-
+
PBD::ScopedConnection _mouse_mode_connection;
boost::shared_ptr<CursorContext> _press_cursor_ctx;
diff --git a/gtk2_ardour/midi_streamview.cc b/gtk2_ardour/midi_streamview.cc
index d1a479d28c..ce34fb9b88 100644
--- a/gtk2_ardour/midi_streamview.cc
+++ b/gtk2_ardour/midi_streamview.cc
@@ -75,7 +75,7 @@ MidiStreamView::MidiStreamView (MidiTimeAxisView& tv)
can be put below ghost regions from MIDI underlays
*/
_note_lines = new ArdourCanvas::LineSet (_canvas_group, ArdourCanvas::LineSet::Horizontal);
-
+
_note_lines->Event.connect(
sigc::bind(sigc::mem_fun(_trackview.editor(),
&PublicEditor::canvas_stream_view_event),
@@ -345,7 +345,7 @@ MidiStreamView::draw_note_lines()
double h = y - prev_y;
double mid = y + (h/2.0);
-
+
if (height > 1.0) { // XXX ? should that not be h >= 1 ?
_note_lines->add (mid, h, color);
}
@@ -647,7 +647,7 @@ void
MidiStreamView::resume_updates ()
{
_updates_suspended = false;
-
+
draw_note_lines ();
apply_note_range_to_regions ();
diff --git a/gtk2_ardour/midi_time_axis.cc b/gtk2_ardour/midi_time_axis.cc
index 934cc6a21d..9564ed239c 100644
--- a/gtk2_ardour/midi_time_axis.cc
+++ b/gtk2_ardour/midi_time_axis.cc
@@ -132,7 +132,7 @@ void
MidiTimeAxisView::set_route (boost::shared_ptr<Route> rt)
{
_route = rt;
-
+
_view = new MidiStreamView (*this);
if (is_track ()) {
@@ -319,11 +319,11 @@ MidiTimeAxisView::set_route (boost::shared_ptr<Route> rt)
_channel_status_box.set_homogeneous (false);
_channel_status_box.set_spacing (4);
-
+
ArdourButton *channel_selector_button = manage (new ArdourButton(_("Chns")));
channel_selector_button->set_name ("route button");
set_tooltip (channel_selector_button, _("Click to edit channel settings"));
-
+
// Insert expanding space labels to get full width justification
_channel_status_box.pack_start (_playback_channel_status, false, false, 2);
_channel_status_box.pack_start (*Gtk::manage(new Gtk::Label(" ")), true, true);
@@ -333,7 +333,7 @@ MidiTimeAxisView::set_route (boost::shared_ptr<Route> rt)
_channel_status_box.show_all ();
channel_selector_button->signal_clicked.connect (sigc::mem_fun (*this, &MidiTimeAxisView::toggle_channel_selector));
-
+
_midi_controls_box.pack_start (_channel_status_box, false, false, 10);
if (!patch_manager.all_models().empty()) {
@@ -483,7 +483,7 @@ MidiTimeAxisView::set_height (uint32_t h, TrackHeightMode m)
} else {
_midi_controls_box.hide();
}
-
+
if (h >= KEYBOARD_MIN_HEIGHT) {
if (is_track() && _range_scroomer) {
_range_scroomer->show();
@@ -539,7 +539,7 @@ MidiTimeAxisView::append_extra_display_menu_items ()
if (color_mode_menu) {
items.push_back (MenuElem (_("Color Mode"), *color_mode_menu));
}
-
+
items.push_back (SeparatorElem ());
}
@@ -921,7 +921,7 @@ MidiTimeAxisView::build_controller_menu ()
l != device_names->controls().end(); ++l) {
boost::shared_ptr<ControlNameList> name_list = l->second;
Menu* ctl_menu = NULL;
-
+
for (ControlNameList::Controls::const_iterator c = name_list->controls().begin();
c != name_list->controls().end();) {
const uint16_t ctl = c->second->number();
@@ -931,7 +931,7 @@ MidiTimeAxisView::build_controller_menu ()
/* Create a new submenu */
ctl_menu = manage (new Menu);
}
-
+
MenuList& ctl_items (ctl_menu->items());
if (chn_cnt > 1) {
add_multi_channel_controller_item(ctl_items, ctl, c->second->name());
@@ -1069,7 +1069,7 @@ MidiTimeAxisView::set_color_mode (ColorMode mode, bool force, bool redisplay, bo
if (_color_mode == mode && !force) {
return;
}
-
+
if (_channel_selector) {
if (mode == ChannelColors) {
_channel_selector->set_channel_colors(NoteBase::midi_channel_colors);
@@ -1077,7 +1077,7 @@ MidiTimeAxisView::set_color_mode (ColorMode mode, bool force, bool redisplay, bo
_channel_selector->set_default_channel_color();
}
}
-
+
_color_mode = mode;
set_gui_property ("color-mode", enum_2_string(_color_mode));
if (redisplay) {
diff --git a/gtk2_ardour/midi_tracer.cc b/gtk2_ardour/midi_tracer.cc
index fbee3552c3..3d5e6ac796 100644
--- a/gtk2_ardour/midi_tracer.cc
+++ b/gtk2_ardour/midi_tracer.cc
@@ -131,7 +131,7 @@ MidiTracer::ports_changed ()
{
string const c = _port_combo.get_active_text ();
_port_combo.clear ();
-
+
ARDOUR::PortManager::PortList pl;
ARDOUR::AudioEngine::instance()->get_ports (ARDOUR::DataType::MIDI, pl);
@@ -182,7 +182,7 @@ MidiTracer::port_changed ()
mp->set_trace_on (true);
traced_port = mp;
}
-
+
} else {
async->parser()->any.connect_same_thread (_parser_connection, boost::bind (&MidiTracer::tracer, this, _1, _2, _3));
}
diff --git a/gtk2_ardour/midi_tracer.h b/gtk2_ardour/midi_tracer.h
index 63a17d4bc9..e0e3f01dc9 100644
--- a/gtk2_ardour/midi_tracer.h
+++ b/gtk2_ardour/midi_tracer.h
@@ -57,7 +57,7 @@ class MidiTracer : public ArdourWindow
Gtk::Label line_count_label;
Gtk::HBox line_count_box;
struct timeval _last_receipt;
-
+
bool autoscroll;
bool show_hex;
bool show_delta_time;
diff --git a/gtk2_ardour/midi_velocity_dialog.cc b/gtk2_ardour/midi_velocity_dialog.cc
index 13a960c0db..5b21e566e4 100644
--- a/gtk2_ardour/midi_velocity_dialog.cc
+++ b/gtk2_ardour/midi_velocity_dialog.cc
@@ -41,7 +41,7 @@ MidiVelocityDialog::MidiVelocityDialog (uint8_t current_velocity)
add_button (Stock::CANCEL, RESPONSE_CANCEL);
add_button (Stock::OK, RESPONSE_OK);
-
+
spinner.signal_activate().connect (sigc::bind (sigc::mem_fun (*this, &MidiVelocityDialog::response), Gtk::RESPONSE_OK));
}
diff --git a/gtk2_ardour/mixer_actor.cc b/gtk2_ardour/mixer_actor.cc
index dfbdf1a12c..ffd68ff6c4 100644
--- a/gtk2_ardour/mixer_actor.cc
+++ b/gtk2_ardour/mixer_actor.cc
@@ -80,7 +80,7 @@ void
MixerActor::load_bindings ()
{
/* XXX move this to a better place */
-
+
bindings.set_action_map (myactions);
std::string binding_file;
diff --git a/gtk2_ardour/mixer_group_tabs.cc b/gtk2_ardour/mixer_group_tabs.cc
index e7d82ae708..f84c53b8e1 100644
--- a/gtk2_ardour/mixer_group_tabs.cc
+++ b/gtk2_ardour/mixer_group_tabs.cc
@@ -101,13 +101,13 @@ MixerGroupTabs::draw_tab (cairo_t* cr, Tab const & tab) const
{
double const arc_radius = get_height();
double r, g, b, a;
-
+
if (tab.group && tab.group->is_active()) {
ArdourCanvas::color_to_rgba (tab.color, r, g, b, a);
} else {
ArdourCanvas::color_to_rgba (UIConfiguration::instance().color ("inactive group tab"), r, g, b, a);
}
-
+
a = 1.0;
cairo_set_source_rgba (cr, r, g, b, a);
@@ -122,7 +122,7 @@ MixerGroupTabs::draw_tab (cairo_t* cr, Tab const & tab) const
cairo_text_extents_t ext;
cairo_text_extents (cr, tab.group->name().c_str(), &ext);
-
+
ArdourCanvas::Color c = ArdourCanvas::contrasting_text_color (ArdourCanvas::rgba_to_color (r, g, b, a));
ArdourCanvas::color_to_rgba (c, r, g, b, a);
diff --git a/gtk2_ardour/mixer_strip.cc b/gtk2_ardour/mixer_strip.cc
index 57501062a4..2ff54512c6 100644
--- a/gtk2_ardour/mixer_strip.cc
+++ b/gtk2_ardour/mixer_strip.cc
@@ -154,7 +154,7 @@ MixerStrip::init ()
if (_mixer_owned) {
t += string_compose (_("\n%1-%2-click to toggle the width of all strips."), Keyboard::primary_modifier_name(), Keyboard::tertiary_modifier_name ());
}
-
+
width_button.set_icon (ArdourIcon::StripWidth);
set_tooltip (width_button, t);
@@ -162,7 +162,7 @@ MixerStrip::init ()
set_tooltip (&hide_button, _("Hide this mixer strip"));
input_button_box.set_spacing(2);
-
+
input_button.set_text (_("Input"));
input_button.set_name ("mixer strip button");
input_button_box.pack_start (input_button, true, true);
@@ -177,7 +177,7 @@ MixerStrip::init ()
meter_point_button.signal_button_press_event().connect (sigc::mem_fun (gpm, &GainMeter::meter_press), false);
meter_point_button.signal_button_release_event().connect (sigc::mem_fun (gpm, &GainMeter::meter_release), false);
-
+
hide_button.set_events (hide_button.get_events() & ~(Gdk::ENTER_NOTIFY_MASK|Gdk::LEAVE_NOTIFY_MASK));
solo_isolated_led = manage (new ArdourButton (ArdourButton::led_default_elements));
@@ -238,7 +238,7 @@ MixerStrip::init ()
button_size_group->add_widget (*monitor_input_button);
}
}
-
+
mute_solo_table.set_homogeneous (true);
mute_solo_table.set_spacings (2);
@@ -408,7 +408,7 @@ bool
MixerStrip::mixer_strip_enter_event (GdkEventCrossing* /*ev*/)
{
_entered_mixer_strip = this;
-
+
//although we are triggering on the "enter", to the user it will appear that it is happenin on the "leave"
//because the mixerstrip control is a parent that encompasses the strip
deselect_all_processors();
@@ -431,7 +431,7 @@ MixerStrip::mixer_strip_leave_event (GdkEventCrossing *ev)
//if we leave this mixer strip we need to clear out any selections
//processor_box.processor_display.select_none(); //but this doesn't work, because it gets triggered when (for example) you open the menu or start a drag
}
-
+
return false;
}
@@ -456,7 +456,7 @@ MixerStrip::set_route (boost::shared_ptr<Route> rt)
if (group_button.get_parent()) {
bottom_button_table.remove (group_button);
}
-
+
RouteUI::set_route (rt);
/* ProcessorBox needs access to _route so that it can read
@@ -469,7 +469,7 @@ MixerStrip::set_route (boost::shared_ptr<Route> rt)
/* unpack these from the parent and stuff them into our own
table
*/
-
+
if (gpm.peak_display.get_parent()) {
gpm.peak_display.get_parent()->remove (gpm.peak_display);
}
@@ -478,7 +478,7 @@ MixerStrip::set_route (boost::shared_ptr<Route> rt)
}
gpm.set_type (rt->meter_type());
-
+
mute_solo_table.attach (gpm.gain_display,0,1,1,2, EXPAND|FILL, EXPAND);
mute_solo_table.attach (gpm.peak_display,1,2,1,2, EXPAND|FILL, EXPAND);
@@ -798,7 +798,7 @@ MixerStrip::output_release (GdkEventButton *ev)
edit_output_configuration ();
break;
}
-
+
return false;
}
@@ -869,7 +869,7 @@ MixerStrip::output_press (GdkEventButton *ev)
)
);
}
-
+
citems.push_back (SeparatorElem());
citems.push_back (MenuElem (_("Routing Grid"), sigc::mem_fun (*(static_cast<RouteUI*>(this)), &RouteUI::edit_output_configuration)));
@@ -929,7 +929,7 @@ MixerStrip::input_press (GdkEventButton *ev)
citems.push_back (SeparatorElem());
uint32_t const n_with_separator = citems.size ();
-
+
input_menu_bundles.clear ();
ARDOUR::BundleList current = _route->input()->bundles_connected ();
@@ -1195,7 +1195,7 @@ MixerStrip::update_io_button (boost::shared_ptr<ARDOUR::Route> route, Width widt
ostringstream tooltip;
char * tooltip_cstr;
-
+
//to avoid confusion, the button caption should only show connections that match the datatype of the track
DataType dt = DataType::AUDIO;
if ( boost::dynamic_pointer_cast<MidiTrack>(route) != 0 ) {
@@ -1220,7 +1220,7 @@ MixerStrip::update_io_button (boost::shared_ptr<ARDOUR::Route> route, Width widt
} else {
port = route->output()->nth (io_index);
}
-
+
port_connections.clear ();
port->get_connections(port_connections);
@@ -1598,7 +1598,7 @@ MixerStrip::build_route_ops_menu ()
if (!selection.selected (rtav)) {
selection.set (rtav);
}
-
+
items.push_front (SeparatorElem());
items.push_front (MenuElem (_("Remove"), sigc::mem_fun(PublicEditor::instance(), &PublicEditor::remove_tracks)));
}
@@ -1644,7 +1644,7 @@ MixerStrip::number_button_button_press (GdkEventButton* ev)
/* do not allow rename if the track is record-enabled */
rename_menu_item->set_sensitive (!_route->record_enabled());
route_ops_menu->popup (1, ev->time);
-
+
return true;
}
@@ -1670,7 +1670,7 @@ MixerStrip::set_selected (bool yn)
global_frame.set_name ("MixerStripFrame");
}
global_frame.queue_draw ();
-
+
// if (!yn)
// processor_box.deselect_all_processors();
}
@@ -1735,7 +1735,7 @@ MixerStrip::width_button_pressed (GdkEventButton* ev)
if (ev->button != 1) {
return false;
}
-
+
if (Keyboard::modifier_state_contains (ev->state, Keyboard::ModifierMask (Keyboard::PrimaryModifier | Keyboard::TertiaryModifier)) && _mixer_owned) {
switch (_width) {
case Wide:
@@ -1880,19 +1880,19 @@ MixerStrip::meter_point_string (MeterPoint mp)
case MeterInput:
return _("In");
break;
-
+
case MeterPreFader:
return _("Pre");
break;
-
+
case MeterPostFader:
return _("Post");
break;
-
+
case MeterOutput:
return _("Out");
break;
-
+
case MeterCustom:
default:
return _("Custom");
@@ -1904,19 +1904,19 @@ MixerStrip::meter_point_string (MeterPoint mp)
case MeterInput:
return S_("Meter|In");
break;
-
+
case MeterPreFader:
return S_("Meter|Pr");
break;
-
+
case MeterPostFader:
return S_("Meter|Po");
break;
-
+
case MeterOutput:
return S_("Meter|O");
break;
-
+
case MeterCustom:
default:
return S_("Meter|C");
@@ -2204,7 +2204,7 @@ MixerStrip::override_solo_visibility () const
if (_route && _route->is_master ()) {
return boost::optional<bool> (false);
}
-
+
return boost::optional<bool> ();
}
@@ -2362,7 +2362,7 @@ MixerStrip::add_level_meter_item_point (Menu_Helpers::MenuList& items,
RadioMenuItem::Group& group, string const & name, MeterPoint point)
{
using namespace Menu_Helpers;
-
+
items.push_back (RadioMenuElem (group, name, sigc::bind (sigc::mem_fun (*this, &MixerStrip::set_meter_point), point)));
RadioMenuItem* i = dynamic_cast<RadioMenuItem *> (&items.back ());
i->set_active (_route->meter_point() == point);
@@ -2380,7 +2380,7 @@ MixerStrip::add_level_meter_item_type (Menu_Helpers::MenuList& items,
RadioMenuItem::Group& group, string const & name, MeterType type)
{
using namespace Menu_Helpers;
-
+
items.push_back (RadioMenuElem (group, name, sigc::bind (sigc::mem_fun (*this, &MixerStrip::set_meter_type), type)));
RadioMenuItem* i = dynamic_cast<RadioMenuItem *> (&items.back ());
i->set_active (_route->meter_type() == type);
diff --git a/gtk2_ardour/mixer_ui.cc b/gtk2_ardour/mixer_ui.cc
index cf2a90e4b4..b742382d73 100644
--- a/gtk2_ardour/mixer_ui.cc
+++ b/gtk2_ardour/mixer_ui.cc
@@ -299,7 +299,7 @@ Mixer_UI::show_window ()
ms->parameter_changed (X_("mixer-element-visibility"));
}
}
-
+
/* force focus into main area */
scroller_base.grab_focus ();
@@ -343,44 +343,44 @@ Mixer_UI::add_strips (RouteList& routes)
for (RouteList::iterator x = routes.begin(); x != routes.end(); ++x) {
boost::shared_ptr<Route> route = (*x);
-
+
if (route->is_auditioner()) {
continue;
}
-
+
if (route->is_monitor()) {
-
+
if (!_monitor_section) {
_monitor_section = new MonitorSection (_session);
-
+
XMLNode* mnode = ARDOUR_UI::instance()->tearoff_settings (X_("monitor-section"));
if (mnode) {
_monitor_section->tearoff().set_state (*mnode);
}
}
-
+
out_packer.pack_end (_monitor_section->tearoff(), false, false);
_monitor_section->set_session (_session);
_monitor_section->tearoff().show_all ();
-
+
route->DropReferences.connect (*this, invalidator(*this), boost::bind (&Mixer_UI::monitor_section_going_away, this), gui_context());
-
+
/* no regular strip shown for control out */
-
+
continue;
}
-
+
strip = new MixerStrip (*this, _session, route);
strips.push_back (strip);
UIConfiguration::instance().get_default_narrow_ms() ? _strip_width = Narrow : _strip_width = Wide;
-
+
if (strip->width_owner() != strip) {
strip->set_width_enum (_strip_width, this);
}
-
+
show_strip (strip);
-
+
TreeModel::Row row = *(track_model->insert(insert_iter));
row[track_columns.text] = route->name();
row[track_columns.visible] = strip->route()->is_master() ? true : strip->marked_for_display();
@@ -390,9 +390,9 @@ Mixer_UI::add_strips (RouteList& routes)
if (!from_scratch) {
_selection.add (strip);
}
-
+
route->PropertyChanged.connect (*this, invalidator (*this), boost::bind (&Mixer_UI::strip_property_changed, this, _1, strip), gui_context());
-
+
strip->WidthChanged.connect (sigc::mem_fun(*this, &Mixer_UI::strip_width_changed));
strip->signal_button_release_event().connect (sigc::bind (sigc::mem_fun(*this, &Mixer_UI::strip_button_release_event), strip));
}
@@ -402,7 +402,7 @@ Mixer_UI::add_strips (RouteList& routes)
no_track_list_redisplay = false;
track_display.set_model (track_model);
-
+
sync_order_keys_from_treeview ();
redisplay_track_list ();
}
@@ -442,11 +442,11 @@ Mixer_UI::remove_strip (MixerStrip* strip)
TreeModel::Children rows = track_model->children();
TreeModel::Children::iterator ri;
list<MixerStrip *>::iterator i;
-
+
if ((i = find (strips.begin(), strips.end(), strip)) != strips.end()) {
strips.erase (i);
}
-
+
for (ri = rows.begin(); ri != rows.end(); ++ri) {
if ((*ri)[track_columns.strip] == strip) {
PBD::Unwinder<bool> uw (_route_deletion_in_progress, true);
@@ -464,7 +464,7 @@ Mixer_UI::reset_remote_control_ids ()
}
TreeModel::Children rows = track_model->children();
-
+
if (rows.empty()) {
return;
}
@@ -479,11 +479,11 @@ Mixer_UI::reset_remote_control_ids ()
for (ri = rows.begin(); ri != rows.end(); ++ri) {
/* skip two special values */
-
+
if (rid == Route::MasterBusRemoteControlID) {
rid++;
}
-
+
if (rid == Route::MonitorBusRemoteControlID) {
rid++;
}
@@ -492,14 +492,14 @@ Mixer_UI::reset_remote_control_ids ()
bool visible = (*ri)[track_columns.visible];
if (!route->is_master() && !route->is_monitor()) {
-
+
uint32_t new_rid = (visible ? rid : invisible_key--);
-
+
if (new_rid != route->remote_control_id()) {
- route->set_remote_control_id_explicit (new_rid);
+ route->set_remote_control_id_explicit (new_rid);
rid_change = true;
}
-
+
if (visible) {
rid++;
}
@@ -520,7 +520,7 @@ Mixer_UI::sync_order_keys_from_treeview ()
}
TreeModel::Children rows = track_model->children();
-
+
if (rows.empty()) {
return;
}
@@ -550,10 +550,10 @@ Mixer_UI::sync_order_keys_from_treeview ()
uint32_t new_rid = (visible ? rid : invisible_key--);
if (new_rid != route->remote_control_id()) {
- route->set_remote_control_id_explicit (new_rid);
+ route->set_remote_control_id_explicit (new_rid);
rid_change = true;
}
-
+
if (visible) {
rid++;
}
@@ -610,7 +610,7 @@ Mixer_UI::sync_treeview_from_order_keys ()
neworder.assign (sorted_routes.size(), 0);
uint32_t n = 0;
-
+
for (OrderKeySortedRoutes::iterator sr = sorted_routes.begin(); sr != sorted_routes.end(); ++sr, ++n) {
neworder[n] = sr->old_display_order;
@@ -640,7 +640,7 @@ Mixer_UI::follow_editor_selection ()
_following_editor_selection = true;
_selection.block_routes_changed (true);
-
+
TrackSelection& s (PublicEditor::instance().get_selection().tracks);
_selection.clear_routes ();
@@ -690,13 +690,13 @@ Mixer_UI::strip_button_release_event (GdkEventButton *ev, MixerStrip *strip)
} else if (Keyboard::modifier_state_equals (ev->state, Keyboard::RangeSelectModifier)) {
if (!_selection.selected(strip)) {
-
+
/* extend selection */
-
+
vector<MixerStrip*> tmp;
bool accumulate = false;
bool found_another = false;
-
+
tmp.push_back (strip);
for (list<MixerStrip*>::iterator i = strips.begin(); i != strips.end(); ++i) {
@@ -845,15 +845,15 @@ Mixer_UI::update_track_visibility ()
{
Unwinder<bool> uw (no_track_list_redisplay, true);
-
+
for (i = rows.begin(); i != rows.end(); ++i) {
MixerStrip *strip = (*i)[track_columns.strip];
(*i)[track_columns.visible] = strip->marked_for_display ();
}
-
+
/* force route order keys catch up with visibility changes
*/
-
+
sync_order_keys_from_treeview ();
}
@@ -926,20 +926,20 @@ Mixer_UI::set_all_strips_visibility (bool yn)
{
Unwinder<bool> uw (no_track_list_redisplay, true);
-
+
for (i = rows.begin(); i != rows.end(); ++i) {
-
+
TreeModel::Row row = (*i);
MixerStrip* strip = row[track_columns.strip];
-
+
if (strip == 0) {
continue;
}
-
+
if (strip->route()->is_master() || strip->route()->is_monitor()) {
continue;
}
-
+
(*i)[track_columns.visible] = yn;
}
}
@@ -956,33 +956,33 @@ Mixer_UI::set_all_audio_midi_visibility (int tracks, bool yn)
{
Unwinder<bool> uw (no_track_list_redisplay, true);
-
+
for (i = rows.begin(); i != rows.end(); ++i) {
TreeModel::Row row = (*i);
MixerStrip* strip = row[track_columns.strip];
-
+
if (strip == 0) {
continue;
}
-
+
if (strip->route()->is_master() || strip->route()->is_monitor()) {
continue;
}
-
+
boost::shared_ptr<AudioTrack> at = strip->audio_track();
boost::shared_ptr<MidiTrack> mt = strip->midi_track();
-
+
switch (tracks) {
case 0:
(*i)[track_columns.visible] = yn;
break;
-
+
case 1:
if (at) { /* track */
(*i)[track_columns.visible] = yn;
}
break;
-
+
case 2:
if (!at && !mt) { /* bus */
(*i)[track_columns.visible] = yn;
@@ -1077,7 +1077,7 @@ Mixer_UI::redisplay_track_list ()
{
TreeModel::Children rows = track_model->children();
TreeModel::Children::iterator i;
-
+
if (no_track_list_redisplay) {
return;
}
@@ -1176,7 +1176,7 @@ Mixer_UI::initial_track_display ()
track_model->clear ();
add_strips (copy);
}
-
+
_session->sync_order_keys ();
redisplay_track_list ();
@@ -1792,7 +1792,7 @@ Mixer_UI::on_key_release_event (GdkEventKey* ev)
}
KeyboardKey k (ev->state, ev->keyval);
-
+
if (bindings.activate (k, Bindings::Release)) {
return true;
}
@@ -1935,7 +1935,7 @@ Mixer_UI::update_title ()
{
if (_session) {
string n;
-
+
if (_session->snap_name() != _session->name()) {
n = _session->snap_name ();
} else {
@@ -1945,14 +1945,14 @@ Mixer_UI::update_title ()
if (_session->dirty ()) {
n = "*" + n;
}
-
+
WindowTitle title (n);
title += S_("Window|Mixer");
title += Glib::get_application_name ();
set_title (title.get_string());
} else {
-
+
WindowTitle title (S_("Window|Mixer"));
title += Glib::get_application_name ();
set_title (title.get_string());
@@ -2015,7 +2015,7 @@ Mixer_UI::toggle_midi_input_active (bool flip_others)
onoff = !mt->input_active();
}
}
-
+
_session->set_exclusive_input_active (rl, onoff, flip_others);
}
diff --git a/gtk2_ardour/monitor_selector.cc b/gtk2_ardour/monitor_selector.cc
index ad5b799627..5f71a79b6f 100644
--- a/gtk2_ardour/monitor_selector.cc
+++ b/gtk2_ardour/monitor_selector.cc
@@ -237,7 +237,7 @@ void
MonitorSelectorWindow::io_name_changed (void*)
{
ENSURE_GUI_THREAD (*this, &MonitorSelectorWindow::io_name_changed, src)
-
+
std::string title;
if (!_selector.find_inputs_for_io_outputs()) {
diff --git a/gtk2_ardour/mono_panner.cc b/gtk2_ardour/mono_panner.cc
index f5bba63446..23b64eee28 100644
--- a/gtk2_ardour/mono_panner.cc
+++ b/gtk2_ardour/mono_panner.cc
@@ -93,7 +93,7 @@ MonoPanner::MonoPanner (boost::shared_ptr<ARDOUR::PannerShell> p)
MonoPanner::~MonoPanner ()
{
-
+
}
void
diff --git a/gtk2_ardour/mono_panner.h b/gtk2_ardour/mono_panner.h
index 4d5f1ffec0..c5843f756c 100644
--- a/gtk2_ardour/mono_panner.h
+++ b/gtk2_ardour/mono_panner.h
@@ -58,7 +58,7 @@ class MonoPanner : public PannerInterface
private:
PannerEditor* editor ();
boost::shared_ptr<ARDOUR::PannerShell> _panner_shell;
-
+
boost::shared_ptr<PBD::Controllable> position_control;
PBD::ScopedConnectionList panvalue_connections;
PBD::ScopedConnectionList panshell_connections;
diff --git a/gtk2_ardour/mono_panner_editor.cc b/gtk2_ardour/mono_panner_editor.cc
index cf8c57a8e1..134c812822 100644
--- a/gtk2_ardour/mono_panner_editor.cc
+++ b/gtk2_ardour/mono_panner_editor.cc
@@ -38,12 +38,12 @@ MonoPannerEditor::MonoPannerEditor (MonoPanner* p)
t->set_spacings (6);
int n = 0;
-
+
t->attach (*manage (left_aligned_label (_("Left"))), 0, 1, n, n + 1);
t->attach (_left, 1, 2, n, n + 1);
t->attach (*manage (left_aligned_label (_("%"))), 2, 3, n, n + 1);
++n;
-
+
t->attach (*manage (left_aligned_label (_("Right"))), 0, 1, n, n + 1);
t->attach (_right, 1, 2, n, n + 1);
t->attach (*manage (left_aligned_label (_("%"))), 2, 3, n, n + 1);
@@ -78,7 +78,7 @@ MonoPannerEditor::update_editor ()
if (!_panner) {
return;
}
-
+
float const v = _panner->get_controllable()->get_value();
_ignore_changes = true;
@@ -110,7 +110,7 @@ MonoPannerEditor::right_changed ()
}
float const v = _right.get_value () / 100;
-
+
_ignore_changes = true;
_left.set_value (100 * (1 - v));
_panner->get_controllable()->set_value (v);
diff --git a/gtk2_ardour/mono_panner_editor.h b/gtk2_ardour/mono_panner_editor.h
index eb4e857e96..f8b12cf25c 100644
--- a/gtk2_ardour/mono_panner_editor.h
+++ b/gtk2_ardour/mono_panner_editor.h
@@ -33,7 +33,7 @@ private:
void update_editor ();
void left_changed ();
void right_changed ();
-
+
MonoPanner* _panner;
Gtk::SpinButton _left;
Gtk::SpinButton _right;
diff --git a/gtk2_ardour/mouse_cursors.cc b/gtk2_ardour/mouse_cursors.cc
index dc14d60086..68ad19ebb7 100644
--- a/gtk2_ardour/mouse_cursors.cc
+++ b/gtk2_ardour/mouse_cursors.cc
@@ -147,7 +147,7 @@ MouseCursors::set_cursor_set (const std::string& name)
}
/* these will throw exceptions if their images cannot be found.
-
+
the default hotspot coordinates will be overridden by any
data found by Gtkmm2ext::Cursors::load_cursor_info(). the values
here from the set of cursors used by Ardour; new cursor/icon
diff --git a/gtk2_ardour/mouse_cursors.h b/gtk2_ardour/mouse_cursors.h
index 5e40a84c4c..8cd98ac32c 100644
--- a/gtk2_ardour/mouse_cursors.h
+++ b/gtk2_ardour/mouse_cursors.h
@@ -79,7 +79,7 @@ public:
is actually a valid value for a Gdk::Cursor - it indicates
"use the parent window's cursor"
*/
-
+
static bool is_invalid (Gdk::Cursor* c) { if (!_invalid) { create_invalid(); } return c == _invalid; }
static Gdk::Cursor* invalid_cursor() { if (!_invalid) { create_invalid(); } return _invalid; }
diff --git a/gtk2_ardour/msvc/winmain.cc b/gtk2_ardour/msvc/winmain.cc
index a9fe3d4224..85b847ea99 100644
--- a/gtk2_ardour/msvc/winmain.cc
+++ b/gtk2_ardour/msvc/winmain.cc
@@ -40,7 +40,7 @@ char* argv[256];
// Essential!! Make sure that any files used by Ardour
// will be created or opened in BINARY mode!
_fmode = O_BINARY;
-
+
GetModuleFileName (NULL, (LPSTR)szPathToProgram, (DWORD)sizeof(szPathToProgram));
argv[0] = new char[(strlen(szPathToProgram) + 1)];
diff --git a/gtk2_ardour/option_editor.cc b/gtk2_ardour/option_editor.cc
index c536bd29bb..a8c35f250f 100644
--- a/gtk2_ardour/option_editor.cc
+++ b/gtk2_ardour/option_editor.cc
@@ -64,11 +64,11 @@ OptionEditorComponent::add_widgets_to_page (OptionEditorPage* p, Gtk::Widget* wa
if (!_note.empty ()) {
++m;
}
-
+
p->table.resize (m, 3);
p->table.attach (*wa, 1, 2, n, n + 1, FILL);
p->table.attach (*wb, 2, 3, n, n + 1, FILL | EXPAND);
-
+
maybe_add_note (p, n + 1);
}
@@ -236,7 +236,7 @@ BoolComboOption::BoolComboOption (
_combo->append_text (f);
/* and option 1 is the true */
_combo->append_text (t);
-
+
_combo->signal_changed().connect (sigc::mem_fun (*this, &BoolComboOption::changed));
}
@@ -263,9 +263,9 @@ BoolComboOption::set_sensitive (bool yn)
{
_combo->set_sensitive (yn);
}
-
-
+
+
FaderOption::FaderOption (string const & i, string const & n, sigc::slot<gain_t> g, sigc::slot<bool, gain_t> s)
: Option (i, n)
, _db_adjustment (gain_to_slider_position_with_max (1.0, Config->get_max_gain()), 0, 1, 0.01, 0.1)
diff --git a/gtk2_ardour/option_editor.h b/gtk2_ardour/option_editor.h
index 13b0285c32..67835b291a 100644
--- a/gtk2_ardour/option_editor.h
+++ b/gtk2_ardour/option_editor.h
@@ -78,7 +78,7 @@ public:
private:
void maybe_add_note (OptionEditorPage *, int);
-
+
std::string _note;
};
@@ -625,7 +625,7 @@ public:
private:
void selection_changed ();
-
+
sigc::slot<std::string> _get; ///< slot to get the configuration variable's value
sigc::slot<bool, std::string> _set; ///< slot to set the configuration variable's value
Gtk::FileChooserButton _file_chooser;
@@ -654,13 +654,13 @@ public:
void add_option (std::string const &, OptionEditorComponent *);
void add_page (std::string const &, Gtk::Widget& page_widget);
-
+
void set_current_page (std::string const &);
protected:
virtual void parameter_changed (std::string const &);
-
+
PBD::Configuration* _config;
private:
diff --git a/gtk2_ardour/panner_interface.h b/gtk2_ardour/panner_interface.h
index a18c083528..3e79c35536 100644
--- a/gtk2_ardour/panner_interface.h
+++ b/gtk2_ardour/panner_interface.h
@@ -45,7 +45,7 @@ public:
private:
bool _dragging;
};
-
+
/** Parent class for some panner UI classes that contains some common code */
class PannerInterface : public Gtk::DrawingArea, public PBD::Destructible
@@ -65,7 +65,7 @@ protected:
virtual void set_tooltip () = 0;
void value_change ();
-
+
bool on_enter_notify_event (GdkEventCrossing *);
bool on_leave_notify_event (GdkEventCrossing *);
bool on_key_release_event (GdkEventKey *);
diff --git a/gtk2_ardour/patch_change.cc b/gtk2_ardour/patch_change.cc
index 96cd2f5ebc..c8d003f845 100644
--- a/gtk2_ardour/patch_change.cc
+++ b/gtk2_ardour/patch_change.cc
@@ -62,7 +62,7 @@ PatchChange::PatchChange(MidiRegionView& region,
UIConfiguration::instance().color_mod ("midi patch change fill", "midi patch change fill"),
ArdourCanvas::Duple (x, y),
true);
-
+
CANVAS_DEBUG_NAME (_flag, text);
_flag->Event.connect (sigc::mem_fun (*this, &PatchChange::event_handler));
@@ -98,12 +98,12 @@ PatchChange::initialize_popup_menus()
++bank) {
Glib::RefPtr<Glib::Regex> underscores = Glib::Regex::create("_");
std::string replacement(" ");
-
+
Gtk::Menu& patch_bank_menu = *manage(new Gtk::Menu());
-
+
const PatchNameList& patches = (*bank)->patch_name_list();
Gtk::Menu::MenuList& patch_menus = patch_bank_menu.items();
-
+
for (PatchNameList::const_iterator patch = patches.begin();
patch != patches.end();
++patch) {
@@ -131,13 +131,13 @@ PatchChange::initialize_popup_menus()
const PatchNameList& patches = patch_banks.front()->patch_name_list();
Gtk::Menu::MenuList& patch_menus = _popup.items();
-
+
for (PatchNameList::const_iterator patch = patches.begin();
patch != patches.end();
++patch) {
std::string name = (*patch)->name();
boost::replace_all (name, "_", " ");
-
+
patch_menus.push_back (
Gtk::Menu_Helpers::MenuElem (
name,
@@ -158,7 +158,7 @@ PatchChange::event_handler (GdkEvent* ev)
{
/* XXX: icky dcast */
Editor* e = dynamic_cast<Editor*> (&_region.get_time_axis_view().editor());
-
+
if (!e->internal_editing()) {
return false;
}
@@ -176,7 +176,7 @@ PatchChange::event_handler (GdkEvent* ev)
_region.edit_patch_change (this);
return true;
-
+
} else if (ev->button.button == 1) {
e->drags()->set (new PatchChangeDrag (e, this, &_region), ev);
return true;
diff --git a/gtk2_ardour/patch_change_dialog.cc b/gtk2_ardour/patch_change_dialog.cc
index 519e0df240..1c0d824321 100644
--- a/gtk2_ardour/patch_change_dialog.cc
+++ b/gtk2_ardour/patch_change_dialog.cc
@@ -62,7 +62,7 @@ PatchChangeDialog::PatchChangeDialog (
int r = 0;
if (_time_converter) {
-
+
l = manage (left_aligned_label (_("Time")));
t->attach (*l, 0, 1, r, r + 1);
t->attach (_time, 1, 2, r, r + 1);
@@ -84,7 +84,7 @@ PatchChangeDialog::PatchChangeDialog (
t->attach (*l, 0, 1, r, r + 1);
t->attach (_patch_combo, 1, 2, r, r + 1);
++r;
-
+
_patch_combo.signal_changed().connect (sigc::mem_fun (*this, &PatchChangeDialog::patch_combo_changed));
l = manage (left_aligned_label (_("Channel")));
@@ -180,7 +180,7 @@ void
PatchChangeDialog::set_active_bank_combo ()
{
_current_patch_bank.reset ();
-
+
boost::shared_ptr<MIDI::Name::ChannelNameSet> cns = _info.get_patches (_channel.get_value_as_int() - 1);
if (!cns) {
@@ -215,7 +215,7 @@ PatchChangeDialog::bank_combo_changed ()
if (_ignore_signals) {
return;
}
-
+
_current_patch_bank.reset ();
boost::shared_ptr<MIDI::Name::ChannelNameSet> cns = _info.get_patches (_channel.get_value_as_int() - 1);
@@ -278,7 +278,7 @@ PatchChangeDialog::set_active_patch_combo ()
_ignore_signals = false;
return;
}
-
+
const MIDI::Name::PatchNameList& patches = _current_patch_bank->patch_name_list ();
for (MIDI::Name::PatchNameList::const_iterator j = patches.begin(); j != patches.end(); ++j) {
string n = (*j)->name ();
@@ -296,7 +296,7 @@ PatchChangeDialog::set_active_patch_combo ()
_ignore_signals = true;
_patch_combo.set_active (-1);
_ignore_signals = false;
-}
+}
/** Set _program from the current state of _patch_combo */
void
diff --git a/gtk2_ardour/piano_roll_header.cc b/gtk2_ardour/piano_roll_header.cc
index 8b2e49770d..043f6c546e 100644
--- a/gtk2_ardour/piano_roll_header.cc
+++ b/gtk2_ardour/piano_roll_header.cc
@@ -467,7 +467,7 @@ PianoRollHeader::on_motion_notify_event (GdkEventMotion* ev)
if (_dragging) {
if ( false /*editor().current_mouse_mode() == Editing::MouseRange*/ ) { //ToDo: fix this. this mode is buggy, and of questionable utility anyway
-
+
/* select note range */
if (Keyboard::no_modifiers_active (ev->state)) {
@@ -480,9 +480,9 @@ PianoRollHeader::on_motion_notify_event (GdkEventMotion* ev)
if (_clicked_note != NO_MIDI_NOTE && _clicked_note != note) {
_active_notes[_clicked_note] = false;
send_note_off(_clicked_note);
-
+
_clicked_note = note;
-
+
if (!_active_notes[note]) {
_active_notes[note] = true;
send_note_on(note);
@@ -511,12 +511,12 @@ PianoRollHeader::on_button_press_event (GdkEventButton* ev)
} else if (ev->button == 1 && note >= 0 && note < 128) {
add_modal_grab();
_dragging = true;
-
+
if (!_active_notes[note]) {
_active_notes[note] = true;
_clicked_note = note;
send_note_on(note);
-
+
invalidate_note_range(note, note);
} else {
reset_clicked_note(note);
@@ -540,7 +540,7 @@ PianoRollHeader::on_button_release_event (GdkEventButton* ev)
} else if (Keyboard::modifier_state_equals (ev->state, Keyboard::RangeSelectModifier)) {
ExtendNoteSelection (note); // EMIT SIGNAL
}
-
+
} else {
if (_dragging) {
diff --git a/gtk2_ardour/pingback.cc b/gtk2_ardour/pingback.cc
index 35c90f4160..ecea85f657 100644
--- a/gtk2_ardour/pingback.cc
+++ b/gtk2_ardour/pingback.cc
@@ -112,7 +112,7 @@ _pingback (void *arg)
curl_global_init (CURL_GLOBAL_NOTHING);
c = curl_easy_init ();
-
+
curl_easy_setopt (c, CURLOPT_WRITEFUNCTION, curl_write_data);
curl_easy_setopt (c, CURLOPT_WRITEDATA, &return_str);
char errbuf[CURL_ERROR_SIZE];
@@ -219,7 +219,7 @@ _pingback (void *arg)
std::cerr << "Announcement string is too long (probably behind a proxy)." << std::endl;
} else {
std::cerr << "Announcement is: " << return_str << std::endl;
-
+
//write announcements to local file, even if the
//announcement is empty
diff --git a/gtk2_ardour/playlist_selector.cc b/gtk2_ardour/playlist_selector.cc
index cdc144d1b7..35a64f38dd 100644
--- a/gtk2_ardour/playlist_selector.cc
+++ b/gtk2_ardour/playlist_selector.cc
@@ -118,7 +118,7 @@ PlaylistSelector::show_for (RouteUI* ruix)
for (TrackPlaylistMap::iterator x = trpl_map.begin(); x != trpl_map.end(); ++x) {
boost::shared_ptr<Track> tr = boost::dynamic_pointer_cast<Track> (_session->route_by_id (x->first));
-
+
/* legacy sessions stored the diskstream ID as the original
* playlist owner. so try there instead.
*/
diff --git a/gtk2_ardour/plugin_eq_gui.cc b/gtk2_ardour/plugin_eq_gui.cc
index 35ba31eeb2..3115f54c41 100644
--- a/gtk2_ardour/plugin_eq_gui.cc
+++ b/gtk2_ardour/plugin_eq_gui.cc
@@ -330,7 +330,7 @@ PluginEqGui::run_impulse_analysis()
{
/* Allocate some thread-local buffers so that Plugin::connect_and_run can use them */
ARDOUR_UI::instance()->get_process_buffers ();
-
+
uint32_t inputs = _plugin->get_info()->n_inputs.n_audio();
uint32_t outputs = _plugin->get_info()->n_outputs.n_audio();
diff --git a/gtk2_ardour/plugin_selector.cc b/gtk2_ardour/plugin_selector.cc
index f2a6ae2a2d..8aff9c4252 100644
--- a/gtk2_ardour/plugin_selector.cc
+++ b/gtk2_ardour/plugin_selector.cc
@@ -65,7 +65,7 @@ PluginSelector::PluginSelector (PluginManager& mgr)
: ArdourDialog (_("Plugin Manager"), true, false)
, filter_button (Stock::CLEAR)
, manager (mgr)
-
+
{
set_name ("PluginSelectorWindow");
add_events (Gdk::KEY_PRESS_MASK|Gdk::KEY_RELEASE_MASK);
@@ -340,7 +340,7 @@ PluginSelector::refiller (const PluginInfoList& plugs, const::std::string& filte
newrow[plugin_columns.audio_ins] = buf;
snprintf (buf, sizeof(buf), "%d", (*i)->n_inputs.n_midi());
newrow[plugin_columns.midi_ins] = buf;
-
+
snprintf (buf, sizeof(buf), "%d", (*i)->n_outputs.n_audio());
newrow[plugin_columns.audio_outs] = buf;
snprintf (buf, sizeof(buf), "%d", (*i)->n_outputs.n_midi());
diff --git a/gtk2_ardour/plugin_ui.cc b/gtk2_ardour/plugin_ui.cc
index ed73e50b7c..37c01462b2 100644
--- a/gtk2_ardour/plugin_ui.cc
+++ b/gtk2_ardour/plugin_ui.cc
@@ -100,7 +100,7 @@ PluginUIWindow::PluginUIWindow (
case ARDOUR::Windows_VST:
have_gui = create_windows_vst_editor (insert);
break;
-
+
case ARDOUR::LXVST:
have_gui = create_lxvst_editor (insert);
break;
@@ -662,7 +662,7 @@ bool
PlugUIBase::bypass_button_release (GdkEventButton*)
{
bool view_says_bypassed = (bypass_button.active_state() != 0);
-
+
if (view_says_bypassed != insert->active()) {
if (view_says_bypassed) {
insert->activate ();
@@ -712,7 +712,7 @@ PlugUIBase::toggle_description()
description_expander.add(*label);
description_expander.show_all();
}
-
+
if (!description_expander.get_expanded()) {
description_expander.remove();
}
diff --git a/gtk2_ardour/plugin_ui.h b/gtk2_ardour/plugin_ui.h
index 4aed3648c7..41f4ef39f1 100644
--- a/gtk2_ardour/plugin_ui.h
+++ b/gtk2_ardour/plugin_ui.h
@@ -145,7 +145,7 @@ class PlugUIBase : public virtual sigc::trackable, public PBD::ScopedConnectionL
ArdourButton automation_write_all_button;
/** a button which sets all controls' automation setting to Touch */
ArdourButton automation_touch_all_button;
-
+
void set_latency_label ();
LatencyGUI* latency_gui;
diff --git a/gtk2_ardour/port_matrix.cc b/gtk2_ardour/port_matrix.cc
index d41b5f1a06..b29e117f1f 100644
--- a/gtk2_ardour/port_matrix.cc
+++ b/gtk2_ardour/port_matrix.cc
@@ -450,7 +450,7 @@ PortMatrix::popup_menu (BundleChannel column, BundleChannel row, uint32_t t)
sub.push_back (MenuElem (buf, sigc::bind (sigc::mem_fun (*this, &PortMatrix::add_channel_proxy), w, *i)));
}
}
-
+
/* Now add other ones */
for (DataType::iterator i = DataType::begin(); i != DataType::end(); ++i) {
if (!should_show (*i)) {
@@ -497,12 +497,12 @@ PortMatrix::popup_menu (BundleChannel column, BundleChannel row, uint32_t t)
/* we're looking just at bundles, or our bundle has only one channel, so just offer
to disassociate all on the bundle.
*/
-
+
snprintf (buf, sizeof (buf), _("%s all"), disassociation_verb().c_str());
sub.push_back (
MenuElem (buf, sigc::bind (sigc::mem_fun (*this, &PortMatrix::disassociate_all_on_bundle), w, dim))
);
-
+
} else if (c != 0) {
if (bc[dim].channel != -1) {
@@ -543,7 +543,7 @@ PortMatrix::popup_menu (BundleChannel column, BundleChannel row, uint32_t t)
items.push_back (MenuElem (_("Flip"), sigc::mem_fun (*this, &PortMatrix::flip)));
items.back().set_sensitive (can_flip ());
-
+
_menu->popup (1, t);
}
@@ -634,7 +634,7 @@ PortMatrix::setup_global_ports_proxy ()
/* Avoid a deadlock by calling this in an idle handler: see IOSelector::io_changed_proxy
for a discussion.
*/
-
+
Glib::signal_idle().connect_once (sigc::mem_fun (*this, &PortMatrix::setup_global_ports));
}
@@ -935,7 +935,7 @@ PortMatrix::visible_ports (int d) const
the TOP_TO_RIGHT arrangement we reverse the order of the vertical
tabs in setup_notebooks ().
*/
-
+
int n = 0;
if (d == _row_index) {
if (_arrangement == LEFT_TO_BOTTOM) {
@@ -1007,11 +1007,11 @@ PortMatrix::update_tab_highlighting ()
if (!_session) {
return;
}
-
+
for (int i = 0; i < 2; ++i) {
Gtk::Notebook* notebook = row_index() == i ? &_vnotebook : &_hnotebook;
-
+
PortGroupList const * gl = ports (i);
int p = 0;
for (PortGroupList::List::const_iterator j = gl->begin(); j != gl->end(); ++j) {
@@ -1166,7 +1166,7 @@ pair<int, int>
PortMatrix::check_flip () const
{
/* Look for the row's port group name in the columns */
-
+
int new_column = 0;
boost::shared_ptr<const PortGroup> r = visible_ports (_row_index);
PortGroupList::List::const_iterator i = _ports[_column_index].begin();
@@ -1180,7 +1180,7 @@ PortMatrix::check_flip () const
}
/* Look for the column's port group name in the rows */
-
+
int new_row = 0;
boost::shared_ptr<const PortGroup> c = visible_ports (_column_index);
i = _ports[_row_index].begin();
diff --git a/gtk2_ardour/port_matrix_column_labels.cc b/gtk2_ardour/port_matrix_column_labels.cc
index f2c4ce146c..cf591f8ff8 100644
--- a/gtk2_ardour/port_matrix_column_labels.cc
+++ b/gtk2_ardour/port_matrix_column_labels.cc
@@ -162,7 +162,7 @@ PortMatrixColumnLabels::render (cairo_t* cr)
(*i)->bundle,
(*i)->bundle->type_channel_to_overall (_matrix->type (), j)
);
-
+
render_channel_name (cr, background_colour (), c, x, 0, bc);
x += grid_spacing();
}
@@ -504,7 +504,7 @@ PortMatrixColumnLabels::motion (double x, double y)
if (!_matrix->should_show (w.bundle->channel_type (i))) {
continue;
}
-
+
ARDOUR::BundleChannel const bc (w.bundle, i);
n.push_back (PortMatrixNode (ARDOUR::BundleChannel (), bc));
}
diff --git a/gtk2_ardour/port_matrix_grid.cc b/gtk2_ardour/port_matrix_grid.cc
index 23fda6e484..77995489a3 100644
--- a/gtk2_ardour/port_matrix_grid.cc
+++ b/gtk2_ardour/port_matrix_grid.cc
@@ -137,7 +137,7 @@ PortMatrixGrid::render (cairo_t* cr)
cairo_line_to (cr, _width, y);
cairo_stroke (cr);
}
-
+
/* ASSOCIATION INDICATORS and NON-CONNECTABLE INDICATORS */
/* we draw a grey square in a matrix box if the two ports that intersect at that box
@@ -230,7 +230,7 @@ PortMatrixGrid::render (cairo_t* cr)
*/
draw_non_connectable_indicator (cr, x, y);
}
-
+
x += grid_spacing();
}
diff --git a/gtk2_ardour/port_matrix_row_labels.cc b/gtk2_ardour/port_matrix_row_labels.cc
index 8ed464954f..507e9fc254 100644
--- a/gtk2_ardour/port_matrix_row_labels.cc
+++ b/gtk2_ardour/port_matrix_row_labels.cc
@@ -123,7 +123,7 @@ PortMatrixRowLabels::render (cairo_t* cr)
(*i)->bundle,
(*i)->bundle->type_channel_to_overall (_matrix->type (), j)
);
-
+
render_channel_name (cr, background_colour (), c, 0, y, bc);
y += grid_spacing();
++M;
@@ -132,7 +132,7 @@ PortMatrixRowLabels::render (cairo_t* cr)
if (N == 0) {
y += grid_spacing ();
}
-
+
} else {
y += grid_spacing();
}
diff --git a/gtk2_ardour/processor_box.cc b/gtk2_ardour/processor_box.cc
index 63aa5aa765..b72fcbe276 100644
--- a/gtk2_ardour/processor_box.cc
+++ b/gtk2_ardour/processor_box.cc
@@ -118,7 +118,7 @@ ProcessorEntry::ProcessorEntry (ProcessorBox* parent, boost::shared_ptr<Processo
, _output_icon(false)
{
_vbox.show ();
-
+
_button.set_distinct_led_click (true);
_button.set_fallthrough_to_parent(true);
_button.set_led_left (true);
@@ -155,7 +155,7 @@ ProcessorEntry::ProcessorEntry (ProcessorBox* parent, boost::shared_ptr<Processo
set<Evoral::Parameter> p = _processor->what_can_be_automated ();
for (set<Evoral::Parameter>::iterator i = p.begin(); i != p.end(); ++i) {
-
+
std::string label = _processor->describe_parameter (*i);
if (boost::dynamic_pointer_cast<Send> (_processor)) {
@@ -165,7 +165,7 @@ ProcessorEntry::ProcessorEntry (ProcessorBox* parent, boost::shared_ptr<Processo
}
Control* c = new Control (_processor->automation_control (*i), label);
-
+
_controls.push_back (c);
if (boost::dynamic_pointer_cast<Amp> (_processor) == 0) {
@@ -458,7 +458,7 @@ ProcessorEntry::build_controls_menu ()
items.push_back (
MenuElem (_("Show All Controls"), sigc::mem_fun (*this, &ProcessorEntry::show_all_controls))
);
-
+
items.push_back (
MenuElem (_("Hide All Controls"), sigc::mem_fun (*this, &ProcessorEntry::hide_all_controls))
);
@@ -466,7 +466,7 @@ ProcessorEntry::build_controls_menu ()
if (!_controls.empty ()) {
items.push_back (SeparatorElem ());
}
-
+
for (list<Control*>::iterator i = _controls.begin(); i != _controls.end(); ++i) {
items.push_back (CheckMenuElem ((*i)->name ()));
Gtk::CheckMenuItem* c = dynamic_cast<Gtk::CheckMenuItem*> (&items.back ());
@@ -538,7 +538,7 @@ ProcessorEntry::Control::Control (boost::shared_ptr<AutomationControl> c, string
//c->Changed.connect (_connection, MISSING_INVALIDATOR, boost::bind (&Control::control_changed, this), gui_context ());
} else {
-
+
_slider.set_name ("ProcessorControlSlider");
_slider.set_text (_name);
@@ -569,7 +569,7 @@ ProcessorEntry::Control::Control (boost::shared_ptr<AutomationControl> c, string
_adjustment.set_step_increment (smallstep);
_adjustment.set_page_increment (largestep);
_slider.set_default_value (normal);
-
+
_adjustment.signal_value_changed().connect (sigc::mem_fun (*this, &Control::slider_adjusted));
// dup. currently timers are used :(
//c->Changed.connect (_connection, MISSING_INVALIDATOR, boost::bind (&Control::control_changed, this), gui_context ());
@@ -578,7 +578,7 @@ ProcessorEntry::Control::Control (boost::shared_ptr<AutomationControl> c, string
// yuck, do we really need to do this?
// according to c404374 this is only needed for send automation
timer_connection = Timers::rapid_connect (sigc::mem_fun (*this, &Control::control_changed));
-
+
control_changed ();
set_tooltip ();
@@ -617,7 +617,7 @@ ProcessorEntry::Control::slider_adjusted ()
if (_ignore_ui_adjustment) {
return;
}
-
+
boost::shared_ptr<AutomationControl> c = _control.lock ();
if (!c) {
@@ -657,7 +657,7 @@ ProcessorEntry::Control::control_changed ()
if (c->toggled ()) {
_button.set_active (c->get_value() > 0.5);
-
+
} else {
// as long as rapid timers are used, only update the tooltip
// if the value has changed.
@@ -667,7 +667,7 @@ ProcessorEntry::Control::control_changed ()
set_tooltip ();
}
}
-
+
_ignore_ui_adjustment = false;
}
@@ -700,7 +700,7 @@ ProcessorEntry::Control::set_visible (bool v)
} else {
box.hide ();
}
-
+
_visible = v;
}
@@ -1343,7 +1343,7 @@ ProcessorBox::processor_operation (ProcessorOperation op)
if ( (op == ProcessorsDelete) && targets.empty() )
return false; //nothing to delete. return false so the editor-mixer, because the user was probably intending to delete something in the editor
-
+
switch (op) {
case ProcessorsSelectAll:
processor_display.select_all ();
@@ -1398,7 +1398,7 @@ ProcessorBox::processor_operation (ProcessorOperation op)
default:
break;
}
-
+
return true;
}
@@ -1441,7 +1441,7 @@ ProcessorBox::processor_button_press_event (GdkEventButton *ev, ProcessorEntry*
} else if (Keyboard::is_context_menu_event (ev)) {
show_processor_menu (ev->time);
-
+
ret = true;
} else if (processor && ev->button == 1 && selected) {
@@ -1782,7 +1782,7 @@ ProcessorBox::maybe_add_processor_to_ui_list (boost::weak_ptr<Processor> w)
if (ui_xml) {
wp->set_state (*ui_xml);
}
-
+
void* existing_ui = p->get_ui ();
if (existing_ui) {
@@ -1830,7 +1830,7 @@ ProcessorBox::add_processor_to_display (boost::weak_ptr<Processor> p)
}
boost::shared_ptr<PluginInsert> plugin_insert = boost::dynamic_pointer_cast<PluginInsert> (processor);
-
+
ProcessorEntry* e = 0;
if (plugin_insert) {
e = new PluginInsertProcessorEntry (this, plugin_insert, _width);
@@ -1841,7 +1841,7 @@ ProcessorBox::add_processor_to_display (boost::weak_ptr<Processor> p)
boost::shared_ptr<Send> send = boost::dynamic_pointer_cast<Send> (processor);
boost::shared_ptr<PortInsert> ext = boost::dynamic_pointer_cast<PortInsert> (processor);
boost::shared_ptr<UnknownProcessor> stub = boost::dynamic_pointer_cast<UnknownProcessor> (processor);
-
+
//faders and meters are not deletable, copy/paste-able, so they shouldn't be selectable
if (!send && !plugin_insert && !ext && !stub)
e->set_selectable(false);
@@ -2220,11 +2220,11 @@ ProcessorBox::paste_processor_state (const XMLNodeList& nlist, boost::shared_ptr
continue;
} else if (type->value() == "intsend") {
-
+
/* aux sends are OK, but those used for
* other purposes, are not.
*/
-
+
assert (role);
if (role->value() != "Aux") {
@@ -2253,7 +2253,7 @@ ProcessorBox::paste_processor_state (const XMLNodeList& nlist, boost::shared_ptr
Send* s = new Send (*_session, _route->pannable(), _route->mute_master());
IOProcessor::prepare_for_reset (n, s->name());
-
+
if (s->set_state (n, Stateful::loading_state_version)) {
delete s;
return;
@@ -2279,13 +2279,13 @@ ProcessorBox::paste_processor_state (const XMLNodeList& nlist, boost::shared_ptr
XMLNode n (**niter);
PortInsert* pi = new PortInsert (*_session, _route->pannable (), _route->mute_master ());
-
+
IOProcessor::prepare_for_reset (n, pi->name());
-
+
if (pi->set_state (n, Stateful::loading_state_version)) {
return;
}
-
+
p.reset (pi);
} else {
@@ -3004,7 +3004,7 @@ ProcessorBox::entry_gui_object_state (ProcessorEntry* entry)
}
GUIObjectState& st = _parent_strip->gui_object_state ();
-
+
XMLNode* strip = st.get_or_add_node (_parent_strip->state_id ());
assert (strip);
return st.get_or_add_node (strip, entry->state_id());
@@ -3120,7 +3120,7 @@ ProcessorWindowProxy::get (bool create)
if (!create) {
return 0;
}
-
+
is_custom = want_custom;
_window = _processor_box->get_editor_window (p, is_custom);
diff --git a/gtk2_ardour/processor_box.h b/gtk2_ardour/processor_box.h
index ce4a0e8851..18ec38a056 100644
--- a/gtk2_ardour/processor_box.h
+++ b/gtk2_ardour/processor_box.h
@@ -118,7 +118,7 @@ public:
bool is_selectable() const {return _selectable;}
void set_selectable(bool s) { _selectable = s; }
-
+
enum Position {
PreFader,
Fader,
@@ -183,7 +183,7 @@ private:
std::string name () const {
return _name;
}
-
+
Gtk::Alignment box;
private:
@@ -305,7 +305,7 @@ class ProcessorBox : public Gtk::HBox, public PluginInterestedObject, public ARD
void generic_edit_processor (boost::shared_ptr<ARDOUR::Processor>);
void update_gui_object_state (ProcessorEntry *);
-
+
sigc::signal<void,boost::shared_ptr<ARDOUR::Processor> > ProcessorSelected;
sigc::signal<void,boost::shared_ptr<ARDOUR::Processor> > ProcessorUnselected;
diff --git a/gtk2_ardour/public_editor.h b/gtk2_ardour/public_editor.h
index 9b4566e1e4..bcf98dbac4 100644
--- a/gtk2_ardour/public_editor.h
+++ b/gtk2_ardour/public_editor.h
@@ -211,7 +211,7 @@ class PublicEditor : public Gtk::Window, public PBD::StatefulDestructible, publi
virtual void set_show_measures (bool yn) = 0;
virtual bool show_measures () const = 0;
virtual void remove_tracks () = 0;
-
+
virtual Editing::MouseMode effective_mouse_mode () const = 0;
/** Import existing media */
@@ -471,7 +471,7 @@ public:
*/
ActionManager::disable_active_actions ();
}
-
+
~MainMenuDisabler () {
ActionManager::enable_active_actions ();
}
diff --git a/gtk2_ardour/rc_option_editor.cc b/gtk2_ardour/rc_option_editor.cc
index 9520c6eb88..f7ba164345 100644
--- a/gtk2_ardour/rc_option_editor.cc
+++ b/gtk2_ardour/rc_option_editor.cc
@@ -101,10 +101,10 @@ public:
_click_emphasis_browse_button.signal_clicked ().connect (
sigc::mem_fun (*this, &ClickOptions::click_emphasis_browse_clicked));
t->attach (_click_emphasis_browse_button, 2, 3, 2, 3, FILL);
-
+
_box->pack_start (*t, false, false);
- _click_path_entry.signal_activate().connect (sigc::mem_fun (*this, &ClickOptions::click_changed));
+ _click_path_entry.signal_activate().connect (sigc::mem_fun (*this, &ClickOptions::click_changed));
_click_emphasis_path_entry.signal_activate().connect (sigc::mem_fun (*this, &ClickOptions::click_emphasis_changed));
if (_rc_config->get_click_sound ().empty() &&
@@ -155,7 +155,7 @@ private:
{
click_chosen (_click_path_entry.get_text ());
}
-
+
void click_emphasis_browse_clicked ()
{
SoundFileChooser sfdb (_("Choose Click Emphasis"));
@@ -1077,7 +1077,7 @@ public:
vector<string> presets;
/* these must match the order of the enums for BufferingPreset */
-
+
presets.push_back (_("Small sessions (4-16 tracks)"));
presets.push_back (_("Medium sessions (16-64 tracks)"));
presets.push_back (_("Large sessions (64+ tracks)"));
@@ -1094,7 +1094,7 @@ public:
_box->pack_start (*h, false, false);
_buffering_presets_combo.signal_changed().connect (sigc::mem_fun (*this, &BufferingOptions::preset_changed));
-
+
_playback_adjustment.set_value (_rc_config->get_audio_playback_buffer_seconds());
l = manage (new Label (_("Playback (seconds of buffering):")));
@@ -1192,7 +1192,7 @@ private:
break;
}
}
-
+
void playback_changed ()
{
_rc_config->set_audio_playback_buffer_seconds ((long) _playback_adjustment.get_value());
@@ -1269,7 +1269,7 @@ private:
void protocol_status_changed (ControlProtocolInfo* cpi) {
/* find the row */
TreeModel::Children rows = _store->children();
-
+
for (TreeModel::Children::iterator x = rows.begin(); x != rows.end(); ++x) {
string n = ((*x)[_model.name]);
@@ -1785,7 +1785,7 @@ private:
*/
_set (_visibility_group->get_state_value ());
}
-
+
OptionEditorHeading _heading;
VisibilityGroup* _visibility_group;
sigc::slot<std::string> _get;
@@ -1931,7 +1931,7 @@ RCOptionEditor::RCOptionEditor ()
(_("<b>When enabled</b> the loop button does not start playback but forces playback to always play the loop\n\n"
"<b>When disabled</b> the loop button starts playing the loop, but stop then cancels loop playback")));
add_option (_("Transport"), tsf);
-
+
tsf = new BoolOption (
"stop-recording-on-xrun",
_("Stop recording when an xrun occurs"),
@@ -2274,7 +2274,7 @@ RCOptionEditor::RCOptionEditor ()
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::get_name_new_markers),
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::set_name_new_markers)
);
-
+
add_option (_("Editor"), bo);
Gtkmm2ext::UI::instance()->set_tip (bo->tip_widget(), _("If enabled, popup a dialog when a new marker is created to allow its name to be set as it is created."
"\n\nYou can always rename markers by right-clicking on them"));
@@ -2851,7 +2851,7 @@ RCOptionEditor::RCOptionEditor ()
(sics->tip_widget(),
_("Increasing the cache size uses more memory to store waveform images, which can improve graphical performance."));
add_option (S_("Preferences|GUI"), sics);
-
+
/* Lock GUI timeout */
Gtk::Adjustment *lts = manage (new Gtk::Adjustment(0, 0, 1000, 1, 10));
@@ -2876,7 +2876,7 @@ RCOptionEditor::RCOptionEditor ()
_mixer_strip_visibility.add (0, X_("SoloIsoLock"), _("Solo Iso / Lock"));
_mixer_strip_visibility.add (0, X_("Output"), _("Output"));
_mixer_strip_visibility.add (0, X_("Comments"), _("Comments"));
-
+
add_option (
S_("Preferences|GUI"),
new VisibilityOption (
diff --git a/gtk2_ardour/rc_option_editor.h b/gtk2_ardour/rc_option_editor.h
index 95adee2115..879a9c4464 100644
--- a/gtk2_ardour/rc_option_editor.h
+++ b/gtk2_ardour/rc_option_editor.h
@@ -30,7 +30,7 @@
* are expressed using subclasses of Option. More complex UI elements are represented
* using individual classes subclassed from OptionEditorBox.
*/
-
+
/** Editor for options which are obtained from and written back to one of the .rc files. */
class RCOptionEditor : public OptionEditor
{
diff --git a/gtk2_ardour/region_layering_order_editor.cc b/gtk2_ardour/region_layering_order_editor.cc
index 7a1a2c2140..759b69fae1 100644
--- a/gtk2_ardour/region_layering_order_editor.cc
+++ b/gtk2_ardour/region_layering_order_editor.cc
@@ -107,7 +107,7 @@ RegionLayeringOrderEditor::RegionLayeringOrderEditor (PublicEditor& pe)
RegionLayeringOrderEditor::~RegionLayeringOrderEditor ()
{
-
+
}
void
@@ -123,15 +123,15 @@ RegionLayeringOrderEditor::row_selected ()
if (!iter) {
return;
}
-
+
TreeModel::Row row = *iter;
RegionView* rv = row[layering_order_columns.region_view];
-
+
vector<RegionView*> eq;
editor.get_equivalent_regions (rv, eq, Properties::select.property_id);
/* XXX this should be reversible, really */
-
+
for (vector<RegionView*>::iterator i = eq.begin(); i != eq.end(); ++i) {
boost::shared_ptr<Playlist> pl = (*i)->region()->playlist();
if (pl) {
@@ -150,7 +150,7 @@ void
RegionLayeringOrderEditor::refill ()
{
assert (_time_axis_view);
-
+
regions_at_position = 0;
in_row_change = true;
layering_order_model->clear ();
diff --git a/gtk2_ardour/region_view.cc b/gtk2_ardour/region_view.cc
index aeede86bb6..7ddca8b574 100644
--- a/gtk2_ardour/region_view.cc
+++ b/gtk2_ardour/region_view.cc
@@ -159,14 +159,14 @@ RegionView::init (bool wfd)
name_highlight->set_data ("regionview", this);
name_highlight->Event.connect (sigc::bind (sigc::mem_fun (PublicEditor::instance(), &PublicEditor::canvas_region_view_name_highlight_event), name_highlight, this));
}
-
+
if (frame_handle_start) {
frame_handle_start->set_data ("regionview", this);
frame_handle_start->set_data ("isleft", (void*) 1);
frame_handle_start->Event.connect (sigc::bind (sigc::mem_fun (PublicEditor::instance(), &PublicEditor::canvas_frame_handle_event), frame_handle_start, this));
frame_handle_start->raise_to_top();
}
-
+
if (frame_handle_end) {
frame_handle_end->set_data ("regionview", this);
frame_handle_end->set_data ("isleft", (void*) 0);
@@ -531,7 +531,7 @@ RegionView::get_fill_color () const
{
ArdourCanvas::Color f = TimeAxisViewItem::get_fill_color();
char const *modname;
-
+
if (_region->opaque()) {
modname = "opaque region base";
} else {
@@ -684,7 +684,7 @@ RegionView::move (double x_delta, double y_delta)
*/
ArdourCanvas::Item *item = get_canvas_group ();
-
+
if (item->position().x + x_delta < 0) {
x_delta = -item->position().x; /* move it to zero */
}
diff --git a/gtk2_ardour/route_group_dialog.cc b/gtk2_ardour/route_group_dialog.cc
index e7e48f777e..aa381d3c47 100644
--- a/gtk2_ardour/route_group_dialog.cc
+++ b/gtk2_ardour/route_group_dialog.cc
@@ -85,7 +85,7 @@ RouteGroupDialog::RouteGroupDialog (RouteGroup* g, bool creating_new)
hbox->pack_start (*l, false, false);
hbox->pack_start (_color, false, false);
top_vbox->pack_start (*hbox, false, false);
-
+
main_vbox->pack_start (*top_vbox, false, false);
_active.set_active (_group->is_active ());
@@ -96,7 +96,7 @@ RouteGroupDialog::RouteGroupDialog (RouteGroup* g, bool creating_new)
VBox* options_box = manage (new VBox);
options_box->set_spacing (6);
-
+
l = manage (new Label (_("<b>Sharing</b>"), Gtk::ALIGN_LEFT, Gtk::ALIGN_CENTER, false ));
l->set_use_markup ();
options_box->pack_start (*l, false, true);
@@ -135,7 +135,7 @@ RouteGroupDialog::RouteGroupDialog (RouteGroup* g, bool creating_new)
_route_active.signal_toggled().connect (sigc::mem_fun (*this, &RouteGroupDialog::update));
_share_color.signal_toggled().connect (sigc::mem_fun (*this, &RouteGroupDialog::update));
_share_monitoring.signal_toggled().connect (sigc::mem_fun (*this, &RouteGroupDialog::update));
-
+
gain_toggled ();
Table* table = manage (new Table (11, 4, false));
@@ -229,7 +229,7 @@ RouteGroupDialog::update ()
plist.add (Properties::monitoring, _share_monitoring.get_active());
_group->apply_changes (plist);
-
+
GroupTabs::set_group_color (_group, gdk_color_to_rgba (_color.get_color ()));
}
diff --git a/gtk2_ardour/route_processor_selection.cc b/gtk2_ardour/route_processor_selection.cc
index 8975bf90bc..30943e22d0 100644
--- a/gtk2_ardour/route_processor_selection.cc
+++ b/gtk2_ardour/route_processor_selection.cc
@@ -105,11 +105,11 @@ RouteProcessorSelection::add (RouteUI* r)
r->set_selected (true);
MixerStrip* ms = dynamic_cast<MixerStrip*> (r);
-
+
if (ms) {
ms->CatchDeletion.connect (*this, invalidator (*this), boost::bind (&RouteProcessorSelection::remove, this, _1), gui_context());
}
-
+
if (!_no_route_change_signal) {
RoutesChanged();
}
diff --git a/gtk2_ardour/route_sorter.h b/gtk2_ardour/route_sorter.h
index 768eac66f3..c203afa188 100644
--- a/gtk2_ardour/route_sorter.h
+++ b/gtk2_ardour/route_sorter.h
@@ -38,7 +38,7 @@ struct RoutePlusOrderKey {
, old_display_order (ok)
, new_display_order (nk) {}
};
-
+
typedef std::vector<RoutePlusOrderKey> OrderKeySortedRoutes;
struct SortByNewDisplayOrder {
diff --git a/gtk2_ardour/route_time_axis.cc b/gtk2_ardour/route_time_axis.cc
index 57c2cd791f..5a1585289c 100644
--- a/gtk2_ardour/route_time_axis.cc
+++ b/gtk2_ardour/route_time_axis.cc
@@ -189,7 +189,7 @@ RouteTimeAxisView::set_route (boost::shared_ptr<Route> rt)
}
rec_enable_button->set_sensitive (_session->writable());
-
+
/* set playlist button tip to the current playlist, and make it update when it changes */
update_playlist_tip ();
track()->PlaylistChanged.connect (*this, invalidator (*this), ui_bind(&RouteTimeAxisView::update_playlist_tip, this), gui_context());
@@ -251,7 +251,7 @@ RouteTimeAxisView::set_route (boost::shared_ptr<Route> rt)
controls_table.attach (route_group_button, 4, 5, 2, 3, Gtk::SHRINK, Gtk::SHRINK, 0, 0);
controls_table.attach (gm.get_gain_slider(), 0, 2, 2, 3, Gtk::FILL|Gtk::EXPAND, Gtk::FILL|Gtk::EXPAND, 1, 0);
}
-
+
set_tooltip(*solo_button,_("Solo"));
set_tooltip(*mute_button,_("Mute"));
set_tooltip(route_group_button, _("Route Group"));
@@ -324,7 +324,7 @@ RouteTimeAxisView::set_route (boost::shared_ptr<Route> rt)
RouteTimeAxisView::~RouteTimeAxisView ()
{
cleanup_gui_properties ();
-
+
for (list<ProcessorAutomationInfo*>::iterator i = processor_automation.begin(); i != processor_automation.end(); ++i) {
delete *i;
}
@@ -507,7 +507,7 @@ RouteTimeAxisView::build_automation_action_menu (bool for_selection)
/* Attach the plugin submenu. It may have previously been used elsewhere,
so it was detached above
*/
-
+
if (!subplugin_menu.items().empty()) {
items.push_back (SeparatorElem ());
items.push_back (MenuElem (_("Processor automation"), subplugin_menu));
@@ -634,7 +634,7 @@ RouteTimeAxisView::build_display_menu ()
*/
_ignore_set_layer_display = true;
-
+
layers_items.push_back (RadioMenuElem (layers_group, _("Overlaid")));
RadioMenuItem* i = dynamic_cast<RadioMenuItem*> (&layers_items.back ());
i->set_active (overlaid != 0 && stacked == 0);
@@ -646,7 +646,7 @@ RouteTimeAxisView::build_display_menu ()
i->set_active (overlaid == 0 && stacked != 0);
i->set_inconsistent (overlaid != 0 && stacked != 0);
i->signal_activate().connect (sigc::bind (sigc::mem_fun (*this, &RouteTimeAxisView::set_layer_display), Stacked, true));
-
+
_ignore_set_layer_display = false;
items.push_back (MenuElem (_("Layers"), *layers_menu));
@@ -813,7 +813,7 @@ RouteTimeAxisView::build_display_menu ()
}
route_group_menu->detach ();
-
+
WeakRouteList r;
for (TrackSelection::iterator i = _editor.get_selection().tracks.begin(); i != _editor.get_selection().tracks.end(); ++i) {
RouteTimeAxisView* rtv = dynamic_cast<RouteTimeAxisView*> (*i);
@@ -821,19 +821,19 @@ RouteTimeAxisView::build_display_menu ()
r.push_back (rtv->route ());
}
}
-
+
if (r.empty ()) {
r.push_back (route ());
}
route_group_menu->build (r);
items.push_back (MenuElem (_("Group"), *route_group_menu->menu ()));
-
+
build_automation_action_menu (true);
items.push_back (MenuElem (_("Automation"), *automation_action_menu));
-
+
items.push_back (SeparatorElem());
-
+
int active = 0;
int inactive = 0;
TrackSelection const & s = _editor.get_selection().tracks;
@@ -1550,11 +1550,11 @@ RouteTimeAxisView::cut_copy_clear (Selection& selection, CutCopyOp op)
vector<Command*> cmds;
playlist->rdiff (cmds);
_session->add_commands (cmds);
-
+
_session->add_command (new StatefulDiffCommand (playlist));
}
break;
-
+
case Cut:
if ((what_we_got = playlist->cut (time)) != 0) {
_editor.get_cut_buffer().add (what_we_got);
@@ -1727,29 +1727,29 @@ RouteTimeAxisView::use_playlist (RadioMenuItem *item, boost::weak_ptr<Playlist>
}
track()->use_playlist (pl);
-
+
RouteGroup* rg = route_group();
-
+
if (rg && rg->is_active() && rg->enabled_property (ARDOUR::Properties::select.property_id)) {
std::string group_string = "." + rg->name() + ".";
-
+
std::string take_name = pl->name();
std::string::size_type idx = take_name.find(group_string);
-
+
if (idx == std::string::npos)
return;
-
+
take_name = take_name.substr(idx + group_string.length()); // find the bit containing the take number / name
-
+
boost::shared_ptr<RouteList> rl (rg->route_list());
-
+
for (RouteList::const_iterator i = rl->begin(); i != rl->end(); ++i) {
if ((*i) == this->route()) {
continue;
}
std::string playlist_name = (*i)->name()+group_string+take_name;
-
+
boost::shared_ptr<Track> track = boost::dynamic_pointer_cast<Track>(*i);
if (!track) {
continue;
@@ -1759,7 +1759,7 @@ RouteTimeAxisView::use_playlist (RadioMenuItem *item, boost::weak_ptr<Playlist>
/* Don't change playlists of frozen tracks */
continue;
}
-
+
boost::shared_ptr<Playlist> ipl = session()->playlists->by_name(playlist_name);
if (!ipl) {
// No playlist for this track for this take yet, make it
@@ -1778,10 +1778,10 @@ RouteTimeAxisView::update_playlist_tip ()
RouteGroup* rg = route_group ();
if (rg && rg->is_active() && rg->enabled_property (ARDOUR::Properties::select.property_id)) {
string group_string = "." + rg->name() + ".";
-
+
string take_name = track()->playlist()->name();
string::size_type idx = take_name.find(group_string);
-
+
if (idx != string::npos) {
/* find the bit containing the take number / name */
take_name = take_name.substr (idx + group_string.length());
@@ -1793,7 +1793,7 @@ RouteTimeAxisView::update_playlist_tip ()
Glib::Markup::escape_text(rg->name()),
Glib::Markup::escape_text(take_name))
);
-
+
return;
}
}
@@ -2209,7 +2209,7 @@ RouteTimeAxisView::add_processor_automation_curve (boost::shared_ptr<Processor>
boost::shared_ptr<AutomationControl> control
= boost::dynamic_pointer_cast<AutomationControl>(processor->control(what, true));
-
+
pan->view = boost::shared_ptr<AutomationTimeAxisView>(
new AutomationTimeAxisView (_session, _route, processor, control, control->parameter (),
_editor, *this, false, parent_canvas,
@@ -2251,7 +2251,7 @@ RouteTimeAxisView::add_existing_processor_automation_curves (boost::weak_ptr<Pro
processor->what_has_data (existing);
for (set<Evoral::Parameter>::iterator i = existing.begin(); i != existing.end(); ++i) {
-
+
Evoral::Parameter param (*i);
boost::shared_ptr<AutomationLine> al;
@@ -2365,7 +2365,7 @@ RouteTimeAxisView::add_processor_to_subplugin_menu (boost::weak_ptr<Processor> p
items.push_back (CheckMenuElem (name));
mitem = dynamic_cast<Gtk::CheckMenuItem*> (&items.back());
-
+
_subplugin_menu_map[*i] = mitem;
if (has_visible_automation.find((*i)) != has_visible_automation.end()) {
@@ -2414,7 +2414,7 @@ RouteTimeAxisView::processor_menu_item_toggled (RouteTimeAxisView::ProcessorAuto
if (pan->view && pan->view->set_marked_for_display (showit)) {
redraw = true;
}
-
+
if (redraw && !no_redraw) {
request_redraw ();
}
@@ -2503,7 +2503,7 @@ RouteTimeAxisView::set_layer_display (LayerDisplay d, bool apply_to_selection)
if (_ignore_set_layer_display) {
return;
}
-
+
if (apply_to_selection) {
_editor.get_selection().tracks.foreach_route_time_axis (boost::bind (&RouteTimeAxisView::set_layer_display, _1, d, false));
} else {
@@ -2909,7 +2909,7 @@ void
RouteTimeAxisView::remove_child (boost::shared_ptr<TimeAxisView> c)
{
TimeAxisView::remove_child (c);
-
+
boost::shared_ptr<AutomationTimeAxisView> a = boost::dynamic_pointer_cast<AutomationTimeAxisView> (c);
if (a) {
for (AutomationTracks::iterator i = _automation_tracks.begin(); i != _automation_tracks.end(); ++i) {
diff --git a/gtk2_ardour/route_ui.cc b/gtk2_ardour/route_ui.cc
index 0d9ed1a958..b05877346f 100644
--- a/gtk2_ardour/route_ui.cc
+++ b/gtk2_ardour/route_ui.cc
@@ -103,7 +103,7 @@ RouteUI::~RouteUI()
delete input_selector;
delete output_selector;
delete _invert_menu;
-
+
send_blink_connection.disconnect ();
rec_blink_connection.disconnect ();
}
@@ -165,7 +165,7 @@ RouteUI::init ()
monitor_input_button->set_text (_("In"));
UI::instance()->set_tip (monitor_input_button, _("Monitor input"), "");
monitor_input_button->set_no_show_all (true);
-
+
monitor_disk_button = manage (new ArdourButton (ArdourButton::default_elements));
monitor_disk_button->set_name ("monitor button");
monitor_disk_button->set_text (_("Disk"));
@@ -189,7 +189,7 @@ RouteUI::init ()
solo_button->signal_button_release_event().connect (sigc::mem_fun(*this, &RouteUI::solo_release), false);
mute_button->signal_button_press_event().connect (sigc::mem_fun(*this, &RouteUI::mute_press), false);
mute_button->signal_button_release_event().connect (sigc::mem_fun(*this, &RouteUI::mute_release), false);
-
+
monitor_input_button->set_distinct_led_click (false);
monitor_disk_button->set_distinct_led_click (false);
@@ -270,7 +270,7 @@ RouteUI::set_route (boost::shared_ptr<Route> rp)
boost::shared_ptr<Track> t = boost::dynamic_pointer_cast<Track>(_route);
t->RecordEnableChanged.connect (route_connections, invalidator (*this), boost::bind (&RouteUI::route_rec_enable_changed, this), gui_context());
-
+
rec_enable_button->show();
rec_enable_button->set_controllable (t->rec_enable_control());
@@ -341,7 +341,7 @@ RouteUI::mute_press (GdkEventButton* ev)
//if this is a binding action, let the ArdourButton handle it
if ( BindingProxy::is_bind_action(ev) )
return false;
-
+
multiple_mute_change = false;
if (Keyboard::is_context_menu_event (ev)) {
@@ -351,7 +351,7 @@ RouteUI::mute_press (GdkEventButton* ev)
}
mute_menu->popup(0,ev->time);
-
+
return true;
} else {
@@ -373,7 +373,7 @@ RouteUI::mute_press (GdkEventButton* ev)
* elements of the list we need to work
* on a copy.
*/
-
+
boost::shared_ptr<RouteList> copy (new RouteList);
*copy = *_session->get_routes ();
@@ -404,9 +404,9 @@ RouteUI::mute_press (GdkEventButton* ev)
if (ev->button == 1) {
if (_route->route_group()) {
-
+
rl = _route->route_group()->route_list();
-
+
if (_mute_release) {
_mute_release->routes = rl;
}
@@ -425,7 +425,7 @@ RouteUI::mute_press (GdkEventButton* ev)
boost::shared_ptr<RouteList> rl (new RouteList);
rl->push_back (_route);
-
+
if (_mute_release) {
_mute_release->routes = rl;
}
@@ -510,7 +510,7 @@ RouteUI::solo_press(GdkEventButton* ev)
//if this is a binding action, let the ArdourButton handle it
if ( BindingProxy::is_bind_action(ev) )
return false;
-
+
multiple_solo_change = false;
if (Keyboard::is_context_menu_event (ev)) {
@@ -598,9 +598,9 @@ RouteUI::solo_press(GdkEventButton* ev)
if (ev->button == 1) {
if (_route->route_group()) {
-
+
rl = _route->route_group()->route_list();
-
+
if (_solo_release) {
_solo_release->routes = rl;
}
@@ -674,7 +674,7 @@ RouteUI::rec_enable_press(GdkEventButton* ev)
//if this is a binding action, let the ArdourButton handle it
if ( BindingProxy::is_bind_action(ev) )
return false;
-
+
if (!_session->engine().connected()) {
MessageDialog msg (_("Not connected to AudioEngine - cannot engage record"));
msg.run ();
@@ -694,7 +694,7 @@ RouteUI::rec_enable_press(GdkEventButton* ev)
if (is_track() && rec_enable_button) {
if (Keyboard::is_button2_event (ev)) {
-
+
//rec arm does not have a momentary mode
return false;
@@ -712,11 +712,11 @@ RouteUI::rec_enable_press(GdkEventButton* ev)
if (ev->button == 1) {
boost::shared_ptr<RouteList> rl;
-
+
if (_route->route_group()) {
-
+
rl = _route->route_group()->route_list();
-
+
} else {
rl.reset (new RouteList);
rl->push_back (_route);
@@ -810,7 +810,7 @@ RouteUI::monitor_disk_release (GdkEventButton* ev)
bool
RouteUI::monitor_release (GdkEventButton* ev, MonitorChoice monitor_choice)
-{
+{
if (ev->button != 1) {
return false;
}
@@ -823,7 +823,7 @@ RouteUI::monitor_release (GdkEventButton* ev, MonitorChoice monitor_choice)
MonitorChoice mc;
boost::shared_ptr<RouteList> rl;
-
+
/* XXX for now, monitoring choices are orthogonal. cue monitoring
will follow in 3.X but requires mixing the input and playback (disk)
signal together, which requires yet more buffers.
@@ -837,7 +837,7 @@ RouteUI::monitor_release (GdkEventButton* ev, MonitorChoice monitor_choice)
mc = monitor_choice;
}
- if (Keyboard::modifier_state_equals (ev->state, Keyboard::ModifierMask (Keyboard::PrimaryModifier|Keyboard::TertiaryModifier))) {
+ if (Keyboard::modifier_state_equals (ev->state, Keyboard::ModifierMask (Keyboard::PrimaryModifier|Keyboard::TertiaryModifier))) {
rl = _session->get_routes ();
} else if (Keyboard::modifier_state_equals (ev->state, Keyboard::PrimaryModifier)) {
@@ -853,7 +853,7 @@ RouteUI::monitor_release (GdkEventButton* ev, MonitorChoice monitor_choice)
}
DisplaySuspender ds;
- _session->set_monitoring (rl, mc, Session::rt_cleanup, true);
+ _session->set_monitoring (rl, mc, Session::rt_cleanup, true);
return false;
}
@@ -1532,11 +1532,11 @@ RouteUI::set_color (const Gdk::Color & c)
char buf[64];
_color = c;
snprintf (buf, sizeof (buf), "%d:%d:%d", c.get_red(), c.get_green(), c.get_blue());
-
+
/* note: we use the route state ID here so that color is the same for both
the time axis view and the mixer strip
*/
-
+
gui_object_state().set_property<string> (route_state_id(), X_("color"), buf);
_route->gui_changed ("color", (void *) 0); /* EMIT_SIGNAL */
}
@@ -1575,12 +1575,12 @@ RouteUI::verify_new_route_name (const std::string& name)
if (name.find (':') == string::npos) {
return true;
}
-
+
MessageDialog colon_msg (
_("The use of colons (':') is discouraged in track and bus names.\nDo you want to use this new name?"),
false, MESSAGE_QUESTION, BUTTONS_NONE
);
-
+
colon_msg.add_button (_("Use the new name"), Gtk::RESPONSE_ACCEPT);
colon_msg.add_button (_("Re-edit the name"), Gtk::RESPONSE_CANCEL);
@@ -1939,7 +1939,7 @@ RouteUI::open_remote_control_id_dialog ()
if (Config->get_remote_model() == UserOrdered) {
uint32_t const limit = _session->ntracks() + _session->nbusses () + 4;
-
+
HBox* hbox = manage (new HBox);
hbox->set_spacing (6);
hbox->pack_start (*manage (new Label (_("Remote control ID:"))));
@@ -1950,7 +1950,7 @@ RouteUI::open_remote_control_id_dialog ()
spin->set_value (_route->remote_control_id());
hbox->pack_start (*spin);
dialog.get_vbox()->pack_start (*hbox);
-
+
dialog.add_button (Stock::CANCEL, RESPONSE_CANCEL);
dialog.add_button (Stock::APPLY, RESPONSE_ACCEPT);
} else {
@@ -2043,7 +2043,7 @@ RouteUI::set_invert_button_state ()
*/
ArdourButton* b = _invert_buttons.front ();
-
+
if (_route->phase_invert().count() == _route->phase_invert().size()) {
b->set_active_state (Gtkmm2ext::ExplicitActive);
} else if (_route->phase_invert().any()) {
@@ -2060,7 +2060,7 @@ RouteUI::set_invert_button_state ()
for (vector<ArdourButton*>::iterator i = _invert_buttons.begin(); i != _invert_buttons.end(); ++i, ++j) {
(*i)->set_active (_route->phase_invert (j));
}
-
+
}
}
@@ -2092,7 +2092,7 @@ RouteUI::invert_press (GdkEventButton* ev)
*/
return false;
}
-
+
delete _invert_menu;
_invert_menu = new Menu;
_invert_menu->set_name ("ArdourContextMenu");
@@ -2171,7 +2171,7 @@ Gdk::Color
RouteUI::color () const
{
RouteGroup* g = _route->route_group ();
-
+
if (g && g->is_color()) {
Gdk::Color c;
set_color_from_rgba (c, GroupTabs::group_color (g));
diff --git a/gtk2_ardour/route_ui.h b/gtk2_ardour/route_ui.h
index 98d66fef84..7bc434f37f 100644
--- a/gtk2_ardour/route_ui.h
+++ b/gtk2_ardour/route_ui.h
@@ -304,7 +304,7 @@ class RouteUI : public virtual AxisView
static void set_showing_sends_to (boost::shared_ptr<ARDOUR::Route>);
static boost::weak_ptr<ARDOUR::Route> _showing_sends_to;
-
+
static uint32_t _max_invert_buttons;
};
diff --git a/gtk2_ardour/save_as_dialog.cc b/gtk2_ardour/save_as_dialog.cc
index bb4f3de2c8..9c8d3cb734 100644
--- a/gtk2_ardour/save_as_dialog.cc
+++ b/gtk2_ardour/save_as_dialog.cc
@@ -39,7 +39,7 @@ SaveAsDialog::SaveAsDialog ()
VBox* vbox = get_vbox();
vbox->set_spacing (6);
-
+
HBox* hbox;
Label* label;
@@ -62,7 +62,7 @@ SaveAsDialog::SaveAsDialog ()
VBox* sub_vbox = manage (new VBox);
HBox* sub_hbox = manage (new HBox);
HBox* empty = manage (new HBox);
-
+
sub_vbox->pack_start (copy_media_button, false, false);
sub_vbox->pack_start (copy_external_button, false, false);
@@ -73,17 +73,17 @@ SaveAsDialog::SaveAsDialog ()
vbox->pack_start (no_include_media_button, false, false);
vbox->pack_start (*sub_hbox, false, false);
-
+
switch_to_button.set_active (true);
copy_media_button.set_active (true);
-
+
vbox->show_all ();
add_button (Stock::CANCEL, RESPONSE_CANCEL);
add_button (Stock::OK, RESPONSE_OK);
no_include_media_button.signal_toggled ().connect (sigc::mem_fun (*this, &SaveAsDialog::no_include_toggled));
-
+
new_parent_folder_selector.set_action (FILE_CHOOSER_ACTION_SELECT_FOLDER);
new_parent_folder_selector.set_current_folder (Glib::get_home_dir()); // Why $HOME and not poor_mans_glob (Config->get_default_session_parent_dir ()) ??
new_name_entry.signal_changed().connect (sigc::mem_fun (*this, &SaveAsDialog::name_entry_changed));
diff --git a/gtk2_ardour/save_as_dialog.h b/gtk2_ardour/save_as_dialog.h
index f016aaf2cd..5284bea74d 100644
--- a/gtk2_ardour/save_as_dialog.h
+++ b/gtk2_ardour/save_as_dialog.h
@@ -33,7 +33,7 @@ public:
std::string new_parent_folder () const;
std::string new_name () const;
-
+
bool switch_to () const;
bool include_media () const;
bool copy_media () const;
@@ -41,7 +41,7 @@ public:
void clear_name ();
void set_name (std::string);
-
+
private:
Gtk::CheckButton switch_to_button;
Gtk::CheckButton copy_media_button;
diff --git a/gtk2_ardour/session_dialog.cc b/gtk2_ardour/session_dialog.cc
index f5f37aaa0c..1eb846b9ff 100644
--- a/gtk2_ardour/session_dialog.cc
+++ b/gtk2_ardour/session_dialog.cc
@@ -99,19 +99,19 @@ SessionDialog::SessionDialog (bool require_new, const std::string& session_name,
get_vbox()->pack_start (info_frame, false, false);
setup_new_session_page ();
-
+
if (!new_only) {
setup_initial_choice_box ();
get_vbox()->pack_start (ic_vbox, true, true);
} else {
get_vbox()->pack_start (session_new_vbox, true, true);
}
-
+
if (!template_name.empty()) {
use_template_button.set_active (false);
load_template_override = template_name;
}
-
+
get_vbox()->show_all ();
/* fill data models and show/hide accordingly */
@@ -131,7 +131,7 @@ SessionDialog::SessionDialog (bool require_new, const std::string& session_name,
if (cnt > 0) {
recent_scroller.show();
recent_label.show ();
-
+
if (cnt > 4) {
recent_scroller.set_size_request (-1, 300);
}
@@ -240,7 +240,7 @@ SessionDialog::session_name (bool& should_be_new)
/* Try recent session selection */
TreeIter iter = recent_session_display.get_selection()->get_selected();
-
+
if (iter) {
should_be_new = false;
return (*iter)[recent_session_columns.visible_name];
@@ -266,9 +266,9 @@ SessionDialog::session_folder ()
}
/* Try recent session selection */
-
+
TreeIter iter = recent_session_display.get_selection()->get_selected();
-
+
if (iter) {
string s = (*iter)[recent_session_columns.fullpath];
if (Glib::file_test (s, Glib::FILE_TEST_IS_REGULAR)) {
@@ -342,10 +342,10 @@ SessionDialog::setup_initial_choice_box ()
hbox->pack_start (*image, false, false);
}
}
-
+
vbox->pack_start (ic_new_session_button, true, true, 20);
hbox->pack_start (*vbox, true, true, 20);
-
+
centering_vbox->pack_start (*hbox, false, false);
/* Possible update message */
@@ -380,29 +380,29 @@ SessionDialog::setup_initial_choice_box ()
recent_scroller.set_no_show_all (true);
recent_label.set_markup (string_compose ("<span weight=\"bold\" size=\"large\">%1</span>", _("Recent Sessions")));
-
+
centering_vbox->pack_start (recent_label, false, false, 12);
centering_vbox->pack_start (recent_scroller, true, true);
/* Browse button */
-
+
existing_session_chooser.set_title (_("Select session file"));
existing_session_chooser.signal_file_set().connect (sigc::mem_fun (*this, &SessionDialog::existing_session_selected));
existing_session_chooser.set_current_folder(poor_mans_glob (Config->get_default_session_parent_dir()));
-
+
FileFilter session_filter;
session_filter.add_pattern (string_compose(X_("*%1"), ARDOUR::statefile_suffix));
session_filter.set_name (string_compose (_("%1 sessions"), PROGRAM_NAME));
existing_session_chooser.add_filter (session_filter);
existing_session_chooser.set_filter (session_filter);
-
+
#ifdef GTKOSX
existing_session_chooser.add_shortcut_folder ("/Volumes");
#endif
-
+
Label* browse_label = manage (new Label);
browse_label->set_markup (string_compose ("<span weight=\"bold\" size=\"large\">%1</span>", _("Other Sessions")));
-
+
centering_vbox->pack_start (*browse_label, false, false, 12);
centering_vbox->pack_start (existing_session_chooser, false, false);
@@ -544,7 +544,7 @@ SessionDialog::setup_new_session_page ()
#endif
vbox1->pack_start (*hbox2, false, false);
-
+
session_new_vbox.pack_start (*vbox1, false, false);
/* --- */
@@ -567,20 +567,20 @@ SessionDialog::setup_new_session_page ()
HBox* hbox4a = manage (new HBox);
use_template_button.set_label (_("Use this template"));
-
+
TreeModel::Row row = *template_model->prepend ();
row[session_template_columns.name] = (_("no template"));
row[session_template_columns.path] = string();
-
+
hbox4a->set_spacing (6);
hbox4a->pack_start (use_template_button, false, false);
hbox4a->pack_start (template_chooser, true, true);
-
+
template_chooser.set_model (template_model);
-
+
Gtk::CellRendererText* text_renderer = Gtk::manage (new Gtk::CellRendererText);
text_renderer->property_editable() = false;
-
+
template_chooser.pack_start (*text_renderer);
template_chooser.add_attribute (text_renderer->property_text(), session_template_columns.name);
template_chooser.set_active (0);
@@ -588,21 +588,21 @@ SessionDialog::setup_new_session_page ()
vbox3->pack_start (*hbox4a, false, false);
/* --- */
-
+
HBox* hbox5 = manage (new HBox);
-
+
hbox5->set_spacing (6);
hbox5->pack_start (more_new_session_options_button, false, false);
-
+
setup_more_options_box ();
more_new_session_options_button.add (more_options_vbox);
-
+
vbox3->pack_start (*hbox5, false, false);
hbox3->pack_start (*vbox3, true, true, 8);
vbox2->pack_start (*hbox3, false, false);
-
+
/* --- */
-
+
session_new_vbox.pack_start (*vbox2, false, false);
session_new_vbox.show_all ();
}
@@ -647,7 +647,7 @@ SessionDialog::redisplay_recent_sessions ()
for (ARDOUR::RecentSessions::iterator i = rs.begin(); i != rs.end(); ++i) {
session_directories.push_back ((*i).second);
}
-
+
int session_snapshot_count = 0;
for (vector<std::string>::const_iterator i = session_directories.begin(); i != session_directories.end(); ++i)
@@ -737,7 +737,7 @@ SessionDialog::redisplay_recent_sessions ()
s = Glib::build_filename (dirname, *i2 + statefile_suffix);
Gtk::TreeModel::Row child_row = *(recent_session_model->append (row.children()));
-
+
child_row[recent_session_columns.visible_name] = *i2;
child_row[recent_session_columns.fullpath] = s;
child_row[recent_session_columns.tip] = Glib::Markup::escape_text (dirname);
@@ -750,7 +750,7 @@ SessionDialog::redisplay_recent_sessions ()
if (gsb.st_mtime > most_recent) {
most_recent = gsb.st_mtime;
}
-
+
if (Session::get_info_from_path (s, sr, sf) == 0) {
child_row[recent_session_columns.sample_rate] = rate_as_string (sr);
switch (sf) {
diff --git a/gtk2_ardour/session_option_editor.cc b/gtk2_ardour/session_option_editor.cc
index 769a94b6d7..fa02278752 100644
--- a/gtk2_ardour/session_option_editor.cc
+++ b/gtk2_ardour/session_option_editor.cc
@@ -196,7 +196,7 @@ SessionOptionEditor::SessionOptionEditor (Session* s)
hf->add (BWF, _("Broadcast WAVE (4GB size limit)"));
#ifdef HAVE_RF64_RIFF
hf->add (MBWF, _("Broadcast RF64"));
-#endif
+#endif
hf->add (WAVE, _("WAVE (4GB size limit)"));
hf->add (WAVE64, _("WAVE-64"));
hf->add (CAF, _("CAF"));
diff --git a/gtk2_ardour/sfdb_freesound_mootcher.cc b/gtk2_ardour/sfdb_freesound_mootcher.cc
index ebd165186d..586ad09ddd 100644
--- a/gtk2_ardour/sfdb_freesound_mootcher.cc
+++ b/gtk2_ardour/sfdb_freesound_mootcher.cc
@@ -100,7 +100,7 @@ void Mootcher::ensureWorkingDir ()
}
#endif
}
-
+
//------------------------------------------------------------------------
size_t Mootcher::WriteMemoryCallback(void *ptr, size_t size, size_t nmemb, void *data)
@@ -127,7 +127,7 @@ std::string Mootcher::sortMethodString(enum sortMethod sort)
// sort the results in the requested way.
switch (sort) {
- case sort_duration_desc: return "duration_desc";
+ case sort_duration_desc: return "duration_desc";
case sort_duration_asc: return "duration_asc";
case sort_created_desc: return "created_desc";
case sort_created_asc: return "created_asc";
@@ -135,7 +135,7 @@ std::string Mootcher::sortMethodString(enum sortMethod sort)
case sort_downloads_asc: return "downloads_asc";
case sort_rating_desc: return "rating_desc";
case sort_rating_asc: return "rating_asc";
- default: return "";
+ default: return "";
}
}
@@ -150,7 +150,7 @@ void Mootcher::setcUrlOptions()
curl_easy_setopt(curl, CURLOPT_ERRORBUFFER, errorBuffer);
// Allow redirection
curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1);
-
+
// Allow connections to time out (without using signals)
curl_easy_setopt(curl, CURLOPT_NOSIGNAL, 1);
curl_easy_setopt(curl, CURLOPT_CONNECTTIMEOUT, 30);
@@ -180,9 +180,9 @@ std::string Mootcher::doRequest(std::string uri, std::string params)
} else {
url += "api_key=" + api_key + "&format=xml";
}
-
+
curl_easy_setopt(curl, CURLOPT_URL, url.c_str() );
-
+
// perform online request
CURLcode res = curl_easy_perform(curl);
if( res != 0 ) {
@@ -194,7 +194,7 @@ std::string Mootcher::doRequest(std::string uri, std::string params)
if (xml_page.memory) {
result = xml_page.memory;
}
-
+
free (xml_page.memory);
xml_page.memory = NULL;
xml_page.size = 0;
@@ -234,7 +234,7 @@ std::string Mootcher::searchText(std::string query, int page, std::string filter
params += "&f=" + std::string(ef);
free(ef);
}
-
+
if (sort)
params += "&s=" + sortMethodString(sort);
@@ -317,7 +317,7 @@ CURLcode res;
res = curl_easy_perform (curl);
fclose (theFile);
curl_easy_setopt (curl, CURLOPT_NOPROGRESS, 1); // turn off the progress bar
-
+
if (res != CURLE_OK) {
/* it's not an error if the user pressed the stop button */
if (res != CURLE_ABORTED_BY_CALLBACK) {
@@ -373,7 +373,7 @@ bool Mootcher::checkAudioFile(std::string originalFileName, std::string theID)
fclose (testFile);
return true;
}
-
+
// else file was small, probably an error, delete it
fclose(testFile);
remove( audioFileName.c_str() );
@@ -397,7 +397,7 @@ bool Mootcher::fetchAudioFile(std::string originalFileName, std::string theID, s
if (!theFile) {
return false;
}
-
+
// create the download url
audioURL += "?api_key=" + api_key;
@@ -453,7 +453,7 @@ Mootcher::progress_callback(void *caller, double dltotal, double dlnow, double /
// and we want access to some private members of Mootcher.
Mootcher *thisMootcher = (Mootcher *) caller;
-
+
if (thisMootcher->cancel_download) {
return -1;
}
diff --git a/gtk2_ardour/sfdb_ui.cc b/gtk2_ardour/sfdb_ui.cc
index 3bfb74884e..6f6912abc9 100644
--- a/gtk2_ardour/sfdb_ui.cc
+++ b/gtk2_ardour/sfdb_ui.cc
@@ -576,19 +576,19 @@ SoundFileBrowser::SoundFileBrowser (string title, ARDOUR::Session* s, bool persi
//add the file chooser
chooser.set_border_width (12);
-
+
audio_and_midi_filter.add_custom (FILE_FILTER_FILENAME, sigc::mem_fun (*this, &SoundFileBrowser::on_audio_and_midi_filter));
audio_and_midi_filter.set_name (_("Audio and MIDI files"));
-
+
audio_filter.add_custom (FILE_FILTER_FILENAME, sigc::mem_fun(*this, &SoundFileBrowser::on_audio_filter));
audio_filter.set_name (_("Audio files"));
-
+
midi_filter.add_custom (FILE_FILTER_FILENAME, sigc::mem_fun(*this, &SoundFileBrowser::on_midi_filter));
midi_filter.set_name (_("MIDI files"));
-
+
matchall_filter.add_pattern ("*.*");
matchall_filter.set_name (_("All files"));
-
+
chooser.add_filter (audio_and_midi_filter);
chooser.add_filter (audio_filter);
chooser.add_filter (midi_filter);
@@ -601,13 +601,13 @@ SoundFileBrowser::SoundFileBrowser (string title, ARDOUR::Session* s, bool persi
/* some broken redraw behaviour - this is a bandaid */
chooser.signal_selection_changed().connect (mem_fun (chooser, &Widget::queue_draw));
#endif
-
+
if (!persistent_folder.empty()) {
chooser.set_current_folder (persistent_folder);
}
notebook.append_page (chooser, _("Browse Files"));
-
+
hpacker.set_spacing (6);
hpacker.pack_start (notebook, true, true);
hpacker.pack_start (preview, false, false);
@@ -621,52 +621,52 @@ SoundFileBrowser::SoundFileBrowser (string title, ARDOUR::Session* s, bool persi
VBox* vbox;
HBox* hbox;
-
-
+
+
hbox = manage(new HBox);
hbox->pack_start (found_entry);
hbox->pack_start (found_search_btn);
-
+
Gtk::ScrolledWindow *scroll = manage(new ScrolledWindow);
scroll->add(found_list_view);
scroll->set_policy(Gtk::POLICY_AUTOMATIC, Gtk::POLICY_AUTOMATIC);
-
+
vbox = manage(new VBox);
vbox->pack_start (*hbox, PACK_SHRINK);
vbox->pack_start (*scroll);
-
+
found_list_view.append_column(_("Paths"), found_list_columns.pathname);
-
+
found_list_view.get_selection()->signal_changed().connect(sigc::mem_fun(*this, &SoundFileBrowser::found_list_view_selected));
-
+
found_list_view.signal_row_activated().connect (sigc::mem_fun (*this, &SoundFileBrowser::found_list_view_activated));
-
+
found_search_btn.signal_clicked().connect(sigc::mem_fun(*this, &SoundFileBrowser::found_search_clicked));
found_entry.signal_activate().connect(sigc::mem_fun(*this, &SoundFileBrowser::found_search_clicked));
-
+
notebook.append_page (*vbox, _("Search Tags"));
//add freesound search
HBox* passbox;
Label* label;
-
+
passbox = manage(new HBox);
passbox->set_spacing (6);
-
+
label = manage (new Label);
label->set_text (_("Tags:"));
passbox->pack_start (*label, false, false);
passbox->pack_start (freesound_entry, true, true);
-
+
label = manage (new Label);
label->set_text (_("Sort:"));
passbox->pack_start (*label, false, false);
passbox->pack_start (freesound_sort, false, false);
freesound_sort.clear_items();
-
+
// Order of the following must correspond with enum sortMethod
- // in sfdb_freesound_mootcher.h
+ // in sfdb_freesound_mootcher.h
freesound_sort.append_text(_("None"));
freesound_sort.append_text(_("Longest"));
freesound_sort.append_text(_("Shortest"));
@@ -677,7 +677,7 @@ SoundFileBrowser::SoundFileBrowser (string title, ARDOUR::Session* s, bool persi
freesound_sort.append_text(_("Highest rated"));
freesound_sort.append_text(_("Lowest rated"));
freesound_sort.set_active(0);
-
+
passbox->pack_start (freesound_search_btn, false, false);
passbox->pack_start (freesound_more_btn, false, false);
freesound_more_btn.set_label(_("More"));
@@ -686,11 +686,11 @@ SoundFileBrowser::SoundFileBrowser (string title, ARDOUR::Session* s, bool persi
passbox->pack_start (freesound_similar_btn, false, false);
freesound_similar_btn.set_label(_("Similar"));
freesound_similar_btn.set_sensitive(false);
-
+
scroll = manage(new ScrolledWindow);
scroll->add(freesound_list_view);
scroll->set_policy(Gtk::POLICY_AUTOMATIC, Gtk::POLICY_AUTOMATIC);
-
+
vbox = manage(new VBox);
vbox->set_spacing (3);
vbox->pack_start (*passbox, PACK_SHRINK);
@@ -710,7 +710,7 @@ SoundFileBrowser::SoundFileBrowser (string title, ARDOUR::Session* s, bool persi
freesound_list_view.get_column(3)->set_alignment(0.5);
freesound_list_view.get_column(4)->set_alignment(0.5);
freesound_list_view.get_column(5)->set_alignment(0.5);
-
+
freesound_list_view.get_selection()->signal_changed().connect(sigc::mem_fun(*this, &SoundFileBrowser::freesound_list_view_selected));
freesound_list_view.set_tooltip_column(1);
@@ -1067,9 +1067,9 @@ SoundFileBrowser::freesound_similar_clicked ()
prev_cursor = gdk_window_get_cursor (get_window()->gobj());
gdk_window_set_cursor (get_window()->gobj(), gdk_cursor_new(GDK_WATCH));
gdk_flush();
-
+
std::string theString = mootcher.searchSimilar(id);
-
+
gdk_window_set_cursor (get_window()->gobj(), prev_cursor);
handle_freesound_results(theString);
}
@@ -1353,28 +1353,28 @@ SoundFileOmega::reset_options ()
if (selected_audio_track_cnt > 0) {
if (channel_combo.get_active_text().length()) {
ImportDisposition id = get_channel_disposition();
-
+
switch (id) {
case Editing::ImportDistinctFiles:
if (selected_audio_track_cnt == paths.size()) {
action_strings.push_back (importmode2string (ImportToTrack));
}
break;
-
+
case Editing::ImportDistinctChannels:
/* XXX it would be nice to allow channel-per-selected track
but its too hard we don't want to deal with all the
different per-file + per-track channel configurations.
*/
break;
-
+
default:
action_strings.push_back (importmode2string (ImportToTrack));
break;
}
}
}
-
+
} else {
/* MIDI ONLY */
@@ -1489,7 +1489,7 @@ SoundFileOmega::reset_options ()
/* We must copy MIDI files or those from Freesound
* or any file if we are under nsm control */
bool const must_copy = _session->get_nsm_state() || have_a_midi_file || notebook.get_current_page() == 2;
-
+
if (UIConfiguration::instance().get_only_copy_imported_files()) {
if (selection_can_be_embedded_with_links && !must_copy) {
@@ -1505,7 +1505,7 @@ SoundFileOmega::reset_options ()
if (must_copy) {
copy_files_btn.set_active (true);
- }
+ }
copy_files_btn.set_sensitive (!must_copy);
}
@@ -1952,14 +1952,14 @@ SoundFileOmega::do_something (int action)
}
/* lets do it */
-
+
vector<string> paths = get_paths ();
ImportPosition pos = get_position ();
ImportMode mode = get_mode ();
ImportDisposition chns = get_channel_disposition ();
PluginInfoPtr instrument = instrument_combo.selected_instrument();
framepos_t where;
-
+
switch (pos) {
case ImportAtEditPoint:
where = PublicEditor::instance().get_preferred_edit_position ();
@@ -1974,13 +1974,13 @@ SoundFileOmega::do_something (int action)
where = _session->current_start_frame();
break;
}
-
+
SrcQuality quality = get_src_quality();
-
+
if (copy_files_btn.get_active()) {
PublicEditor::instance().do_import (paths, chns, mode, quality, where, instrument);
} else {
PublicEditor::instance().do_embed (paths, chns, mode, where, instrument);
}
}
-
+
diff --git a/gtk2_ardour/sfdb_ui.h b/gtk2_ardour/sfdb_ui.h
index 1eb6f2e122..3c4f088258 100644
--- a/gtk2_ardour/sfdb_ui.h
+++ b/gtk2_ardour/sfdb_ui.h
@@ -198,7 +198,7 @@ class SoundFileBrowser : public ArdourWindow
void freesound_search();
void refresh_display(std::string ID, std::string file);
-
+
protected:
bool resetting_ourselves;
int matches;
@@ -239,7 +239,7 @@ class SoundFileBrowser : public ArdourWindow
void freesound_more_clicked ();
void freesound_similar_clicked ();
int freesound_page;
-
+
void chooser_file_activated ();
std::string freesound_get_audio_file(Gtk::TreeIter iter);
diff --git a/gtk2_ardour/shuttle_control.cc b/gtk2_ardour/shuttle_control.cc
index ba520152c4..94c27c2807 100644
--- a/gtk2_ardour/shuttle_control.cc
+++ b/gtk2_ardour/shuttle_control.cc
@@ -322,7 +322,7 @@ ShuttleControl::on_button_release_event (GdkEventButton* ev)
shuttle_grabbed = false;
remove_modal_grab ();
gdk_pointer_ungrab (GDK_CURRENT_TIME);
-
+
if (Config->get_shuttle_behaviour() == Sprung) {
if (shuttle_speed_on_grab == 0 ) {
_session->request_stop ();
@@ -397,7 +397,7 @@ ShuttleControl::on_scroll_event (GdkEventScroll* ev)
default:
return false;
}
-
+
if (semis) {
float lower_side_of_dead_zone = semitones_as_fract (-24, true);
diff --git a/gtk2_ardour/soundcloud_export_selector.h b/gtk2_ardour/soundcloud_export_selector.h
index fcfbdfe91b..c05214a489 100644
--- a/gtk2_ardour/soundcloud_export_selector.h
+++ b/gtk2_ardour/soundcloud_export_selector.h
@@ -40,7 +40,7 @@ class SoundcloudExportSelector : public Gtk::VBox, public ARDOUR::SessionHandleP
Gtk::CheckButton soundcloud_download_checkbox;
bool soundcloud_cancel;
Gtk::ProgressBar progress_bar;
-
+
};
#endif // __soundcloud_export_selector_h__
diff --git a/gtk2_ardour/splash.cc b/gtk2_ardour/splash.cc
index 2b28ff4953..63ca20d057 100644
--- a/gtk2_ardour/splash.cc
+++ b/gtk2_ardour/splash.cc
@@ -45,7 +45,7 @@ Splash* Splash::the_splash = 0;
Splash::Splash ()
{
assert (the_splash == 0);
-
+
std::string splash_file;
if (!find_file (ardour_data_search_path(), "splash.png", splash_file)) {
@@ -202,7 +202,7 @@ void
Splash::display ()
{
bool was_mapped = is_mapped ();
-
+
if (!was_mapped) {
expose_done = false;
expose_is_the_one = false;
@@ -210,7 +210,7 @@ Splash::display ()
pop_front ();
present ();
-
+
if (!was_mapped) {
while (!expose_done) {
gtk_main_iteration ();
@@ -230,7 +230,7 @@ Splash::message (const string& msg)
layout->set_markup (str);
Glib::RefPtr<Gdk::Window> win = darea.get_window();
-
+
if (win) {
expose_done = false;
diff --git a/gtk2_ardour/startup.cc b/gtk2_ardour/startup.cc
index c19c14f7aa..e020ee18d7 100644
--- a/gtk2_ardour/startup.cc
+++ b/gtk2_ardour/startup.cc
@@ -79,14 +79,14 @@ ArdourStartup::ArdourStartup ()
{
set_position (WIN_POS_CENTER);
set_border_width (12);
-
+
if ((icon_pixbuf = ::get_icon ("ardour_icon_48px")) == 0) {
throw failed_constructor();
}
-
+
list<Glib::RefPtr<Gdk::Pixbuf> > window_icons;
Glib::RefPtr<Gdk::Pixbuf> icon;
-
+
if ((icon = ::get_icon ("ardour_icon_16px")) != 0) {
window_icons.push_back (icon);
}
@@ -102,7 +102,7 @@ ArdourStartup::ArdourStartup ()
if (!window_icons.empty ()) {
set_default_icon_list (window_icons);
}
-
+
setup_new_user_page ();
setup_first_time_config_page ();
setup_monitoring_choice_page ();
@@ -124,7 +124,7 @@ ArdourStartup::required ()
*/
const int current_version = atoi (PROGRAM_VERSION);
-
+
for (int v = current_version; v != 0; --v) {
if (Glib::file_test (ARDOUR::been_here_before_path (v), Glib::FILE_TEST_EXISTS)) {
if (v != current_version) {
@@ -179,7 +179,7 @@ ArdourStartup::default_dir_changed ()
{
Config->set_default_session_parent_dir (default_dir_chooser->get_filename());
// make new session folder chooser point to the new default
- new_folder_chooser.set_current_folder (Config->get_default_session_parent_dir());
+ new_folder_chooser.set_current_folder (Config->get_default_session_parent_dir());
config_changed ();
}
@@ -424,7 +424,7 @@ ArdourStartup::on_apply ()
PBD::ScopedFileDescriptor fout (g_open (been_here_before_path ().c_str(), O_CREAT|O_TRUNC|O_RDWR, 0666));
}
-
+
_response = RESPONSE_OK;
gtk_main_quit ();
}
diff --git a/gtk2_ardour/stereo_panner.cc b/gtk2_ardour/stereo_panner.cc
index 0736a426c1..91c8b025ac 100644
--- a/gtk2_ardour/stereo_panner.cc
+++ b/gtk2_ardour/stereo_panner.cc
@@ -306,7 +306,7 @@ StereoPanner::on_button_press_event (GdkEventButton* ev)
if (_panner_shell->bypassed()) {
return true;
}
-
+
drag_start_x = ev->x;
last_drag_x = ev->x;
@@ -447,7 +447,7 @@ StereoPanner::on_button_release_event (GdkEventButton* ev)
if (PannerInterface::on_button_release_event (ev)) {
return true;
}
-
+
if (ev->button != 1) {
return false;
}
@@ -537,7 +537,7 @@ StereoPanner::on_motion_notify_event (GdkEventMotion* ev)
if (dragging_left) {
delta = -delta;
}
-
+
if (dragging_left || dragging_right) {
if (Keyboard::modifier_state_contains (ev->state, Keyboard::SecondaryModifier)) {
@@ -547,7 +547,7 @@ StereoPanner::on_motion_notify_event (GdkEventMotion* ev)
*/
_panner->freeze ();
-
+
double pv = position_control->get_value();
if (dragging_left) {
@@ -573,27 +573,27 @@ StereoPanner::on_motion_notify_event (GdkEventMotion* ev)
} else {
/* maintain position as invariant as we change the width */
-
+
/* create a detent close to the center */
-
+
if (!detented && fabs (current_width) < 0.02) {
detented = true;
/* snap to zero */
width_control->set_value (0);
}
-
+
if (detented) {
-
+
accumulated_delta += delta;
-
+
/* have we pulled far enough to escape ? */
-
+
if (fabs (accumulated_delta) >= 0.025) {
width_control->set_value (current_width + accumulated_delta);
detented = false;
accumulated_delta = false;
}
-
+
} else {
/* width needs to change by 2 * delta because both L & R move */
width_control->set_value (current_width + (delta * 2.0));
diff --git a/gtk2_ardour/stereo_panner.h b/gtk2_ardour/stereo_panner.h
index 1c278f344d..ba98232146 100644
--- a/gtk2_ardour/stereo_panner.h
+++ b/gtk2_ardour/stereo_panner.h
@@ -61,7 +61,7 @@ class StereoPanner : public PannerInterface
private:
PannerEditor* editor ();
boost::shared_ptr<ARDOUR::PannerShell> _panner_shell;
-
+
boost::shared_ptr<PBD::Controllable> position_control;
boost::shared_ptr<PBD::Controllable> width_control;
PBD::ScopedConnectionList panvalue_connections;
diff --git a/gtk2_ardour/stereo_panner_editor.cc b/gtk2_ardour/stereo_panner_editor.cc
index 0cc856f500..e7a4a452fe 100644
--- a/gtk2_ardour/stereo_panner_editor.cc
+++ b/gtk2_ardour/stereo_panner_editor.cc
@@ -40,12 +40,12 @@ StereoPannerEditor::StereoPannerEditor (StereoPanner* p)
t->set_spacings (6);
int n = 0;
-
+
t->attach (*manage (left_aligned_label (_("Position"))), 0, 1, n, n + 1);
t->attach (_position, 1, 2, n, n + 1);
t->attach (*manage (left_aligned_label (_("%"))), 2, 3, n, n + 1);
++n;
-
+
t->attach (*manage (left_aligned_label (_("Width"))), 0, 1, n, n + 1);
t->attach (_width, 1, 2, n, n + 1);
t->attach (*manage (left_aligned_label (_("%"))), 2, 3, n, n + 1);
@@ -66,7 +66,7 @@ StereoPannerEditor::StereoPannerEditor (StereoPanner* p)
_panner->get_width_controllable()->Changed.connect (
_connections, invalidator (*this), boost::bind (&StereoPannerEditor::update_editor, this), gui_context ()
);
-
+
_panner->DropReferences.connect (_connections, invalidator (*this), boost::bind (&StereoPannerEditor::panner_going_away, this), gui_context ());
_position.signal_value_changed().connect (sigc::mem_fun (*this, &StereoPannerEditor::position_changed));
_width.signal_value_changed().connect (sigc::mem_fun (*this, &StereoPannerEditor::width_changed));
@@ -87,7 +87,7 @@ StereoPannerEditor::update_editor ()
if (!_panner) {
return;
}
-
+
_ignore_changes = true;
_position.set_value (100 * _panner->get_position_controllable()->get_value ());
_width.set_value (100 * _panner->get_width_controllable()->get_value ());
@@ -135,4 +135,4 @@ StereoPannerEditor::set_width_range ()
pair<double, double> const wr = _panner->panner()->width_range ();
_width.set_range (wr.first * 100, wr.second * 100);
}
-
+
diff --git a/gtk2_ardour/stereo_panner_editor.h b/gtk2_ardour/stereo_panner_editor.h
index 8c561e5545..1a01564a4c 100644
--- a/gtk2_ardour/stereo_panner_editor.h
+++ b/gtk2_ardour/stereo_panner_editor.h
@@ -35,7 +35,7 @@ private:
void width_changed ();
void set_position_range ();
void set_width_range ();
-
+
StereoPanner* _panner;
Gtk::SpinButton _position;
Gtk::SpinButton _width;
diff --git a/gtk2_ardour/streamview.cc b/gtk2_ardour/streamview.cc
index 5f50b7e8cb..c737f7842c 100644
--- a/gtk2_ardour/streamview.cc
+++ b/gtk2_ardour/streamview.cc
@@ -66,7 +66,7 @@ StreamView::StreamView (RouteTimeAxisView& tv, ArdourCanvas::Container* canvas_g
, last_rec_data_frame(0)
{
CANVAS_DEBUG_NAME (_canvas_group, string_compose ("SV canvas group %1", _trackview.name()));
-
+
/* set_position() will position the group */
canvas_rect = new ArdourCanvas::Rectangle (_canvas_group);
@@ -583,7 +583,7 @@ StreamView::get_selectables (framepos_t start, framepos_t end, double top, doubl
layer_t const l = (*i)->region()->layer ();
layer_ok = (min_layer <= l && l <= max_layer);
}
-
+
if (within) {
if ((*i)->region()->coverage (start, end) == Evoral::OverlapExternal && layer_ok) {
results.push_back (*i);
@@ -593,7 +593,7 @@ StreamView::get_selectables (framepos_t start, framepos_t end, double top, doubl
results.push_back (*i);
}
}
-
+
}
}
@@ -619,7 +619,7 @@ StreamView::child_height () const
case Expanded:
return height / (_layers * 2 + 1);
}
-
+
abort(); /* NOTREACHED */
return height;
}
@@ -670,7 +670,7 @@ StreamView::set_layer_display (LayerDisplay d)
if (_layer_display == Overlaid) {
layer_regions ();
}
-
+
update_contents_height ();
update_coverage_frames ();
}
diff --git a/gtk2_ardour/streamview.h b/gtk2_ardour/streamview.h
index 0c3faf3b21..8a56040afb 100644
--- a/gtk2_ardour/streamview.h
+++ b/gtk2_ardour/streamview.h
@@ -118,7 +118,7 @@ public:
void check_record_layers (boost::shared_ptr<ARDOUR::Region>, ARDOUR::framepos_t);
virtual void playlist_layered (boost::weak_ptr<ARDOUR::Track>);
-
+
sigc::signal<void, RegionView*> RegionViewAdded;
sigc::signal<void> RegionViewRemoved;
/** Emitted when the height of regions has changed */
diff --git a/gtk2_ardour/sys_ex.cc b/gtk2_ardour/sys_ex.cc
index 3607aa5e2a..b6251938a7 100644
--- a/gtk2_ardour/sys_ex.cc
+++ b/gtk2_ardour/sys_ex.cc
@@ -39,7 +39,7 @@ SysEx::SysEx (
UIConfiguration::instance().color_mod ("midi sysex fill", "midi sysex fill"),
ArdourCanvas::Duple (x, y)
);
-
+
_flag->set_text (text);
}
diff --git a/gtk2_ardour/sys_ex.h b/gtk2_ardour/sys_ex.h
index cc3559ba1f..709841cabb 100644
--- a/gtk2_ardour/sys_ex.h
+++ b/gtk2_ardour/sys_ex.h
@@ -44,7 +44,7 @@ public:
ArdourCanvas::Item& item() const { return *_flag; }
-private:
+private:
bool event_handler (GdkEvent* ev);
ArdourCanvas::Flag* _flag;
diff --git a/gtk2_ardour/tempo_dialog.cc b/gtk2_ardour/tempo_dialog.cc
index 37771eff76..0b570abdaa 100644
--- a/gtk2_ardour/tempo_dialog.cc
+++ b/gtk2_ardour/tempo_dialog.cc
@@ -105,7 +105,7 @@ TempoDialog::init (const Timecode::BBT_Time& when, double bpm, double note_type,
if (x == note_types.end()) {
pulse_selector.set_active_text (strings[3]); // "quarter"
}
-
+
Table* table;
if (UIConfiguration::instance().get_allow_non_quarter_pulse()) {
@@ -249,7 +249,7 @@ double
TempoDialog::get_note_type ()
{
NoteTypes::iterator x = note_types.find (pulse_selector.get_active_text());
-
+
if (x == note_types.end()) {
error << string_compose(_("incomprehensible pulse note type (%1)"), pulse_selector.get_active_text()) << endmsg;
return 0;
@@ -367,7 +367,7 @@ MeterDialog::init (const Timecode::BBT_Time& when, double bpb, double divisor, b
break;
}
}
-
+
if (x == note_types.end()) {
note_type.set_active_text (strings[3]); // "quarter"
}
@@ -498,7 +498,7 @@ double
MeterDialog::get_note_type ()
{
NoteTypes::iterator x = note_types.find (note_type.get_active_text());
-
+
if (x == note_types.end()) {
error << string_compose(_("incomprehensible meter note type (%1)"), note_type.get_active_text()) << endmsg;
return 0;
diff --git a/gtk2_ardour/theme_manager.cc b/gtk2_ardour/theme_manager.cc
index 2abfb79105..3d1a1f8952 100644
--- a/gtk2_ardour/theme_manager.cc
+++ b/gtk2_ardour/theme_manager.cc
@@ -78,16 +78,16 @@ ThemeManager::ThemeManager()
, palette_window (0)
{
/* Now the alias list */
-
+
alias_list = TreeStore::create (alias_columns);
alias_display.set_model (alias_list);
alias_display.append_column (_("Object"), alias_columns.name);
-
+
Gtkmm2ext::CellRendererColorSelector* color_renderer = manage (new Gtkmm2ext::CellRendererColorSelector);
TreeViewColumn* color_column = manage (new TreeViewColumn (_("Color"), *color_renderer));
color_column->add_attribute (color_renderer->property_color(), alias_columns.color);
alias_display.append_column (*color_column);
-
+
alias_display.get_column (0)->set_data (X_("colnum"), GUINT_TO_POINTER(0));
alias_display.get_column (0)->set_expand (true);
alias_display.get_column (1)->set_data (X_("colnum"), GUINT_TO_POINTER(1));
@@ -101,7 +101,7 @@ ThemeManager::ThemeManager()
alias_scroller.add (alias_display);
/* various buttons */
-
+
RadioButton::Group group = dark_button.get_group();
light_button.set_group(group);
theme_selection_hbox.set_homogeneous(false);
@@ -137,7 +137,7 @@ ThemeManager::ThemeManager()
pack_start (*hbox, PACK_SHRINK);
}
-
+
hbox = Gtk::manage (new Gtk::HBox());
hbox->set_spacing (6);
hbox->pack_start (waveform_gradient_depth, true, true);
@@ -156,21 +156,21 @@ ThemeManager::ThemeManager()
palette_scroller.add (palette_viewport);
modifier_scroller.add (modifier_vbox);
-
+
notebook.append_page (alias_scroller, _("Items"));
notebook.append_page (palette_scroller, _("Palette"));
notebook.append_page (modifier_scroller, _("Transparency"));
-
+
pack_start (notebook);
show_all ();
waveform_gradient_depth.set_update_policy (Gtk::UPDATE_DELAYED);
timeline_item_gradient_depth.set_update_policy (Gtk::UPDATE_DELAYED);
-
+
color_dialog.get_colorsel()->set_has_opacity_control (true);
color_dialog.get_colorsel()->set_has_palette (true);
-
+
set_ui_to_state();
color_dialog.get_ok_button()->signal_clicked().connect (sigc::bind (sigc::mem_fun (color_dialog, &Gtk::Dialog::response), RESPONSE_ACCEPT));
@@ -200,7 +200,7 @@ ThemeManager::ThemeManager()
/* no need to call setup_palette() here, it will be done when its size is allocated */
setup_aliases ();
setup_modifiers ();
-
+
UIConfiguration::instance().ColorsChanged.connect (sigc::mem_fun (*this, &ThemeManager::colors_changed));
}
@@ -216,7 +216,7 @@ ThemeManager::setup_modifiers ()
Gtk::HBox* mod_hbox;
Gtk::Label* mod_label;
Gtk::HScale* mod_scale;
-
+
Gtkmm2ext::container_clear (modifier_vbox);
for (UIConfiguration::Modifiers::const_iterator m = modifiers.begin(); m != modifiers.end(); ++m) {
@@ -231,7 +231,7 @@ ThemeManager::setup_modifiers ()
mod_label = manage (new Label (m->first));
mod_label->set_alignment (1.0, 0.5);
mod_label->set_size_request (150, -1); /* 150 pixels should be enough for anyone */
-
+
mod_hbox->pack_start (*mod_label, false, true, 12);
mod_hbox->pack_start (*mod_scale, true, true);
@@ -246,7 +246,7 @@ void
ThemeManager::modifier_edited (Gtk::Range* range, string name)
{
using namespace ArdourCanvas;
-
+
double alpha = range->get_value();
SVAModifier svam (SVAModifier::Assign, -1.0, -1.0, alpha);
UIConfiguration::instance().set_modifier (name, svam);
@@ -256,8 +256,8 @@ void
ThemeManager::colors_changed ()
{
setup_palette ();
- setup_aliases ();
- setup_modifiers ();
+ setup_aliases ();
+ setup_modifiers ();
}
int
@@ -338,7 +338,7 @@ ThemeManager::on_dark_theme_button_toggled()
if (!dark_button.get_active()) return;
UIConfiguration* uic (&UIConfiguration::instance());
-
+
uic->set_color_file("dark");
}
@@ -348,7 +348,7 @@ ThemeManager::on_light_theme_button_toggled()
if (!light_button.get_active()) return;
UIConfiguration* uic (&UIConfiguration::instance());
-
+
uic->set_color_file("light");
}
@@ -409,7 +409,7 @@ ThemeManager::initialize_palette_canvas (ArdourCanvas::Canvas& canvas)
canvas.set_background_color (rgba_to_color (0.0, 0.0, 1.0, 0.0));
/* bi-directional scroll group */
-
+
ScrollGroup* scroll_group = new ScrollGroup (canvas.root(), ScrollGroup::ScrollSensitivity (ScrollGroup::ScrollsVertically|ScrollGroup::ScrollsHorizontally));
canvas.add_scroller (*scroll_group);
@@ -459,7 +459,7 @@ ThemeManager::build_palette_canvas (ArdourCanvas::Canvas& canvas, ArdourCanvas::
}
SortByHue sorter;
sort (nc.begin(), nc.end(), sorter);
-
+
const uint32_t color_limit = nc.size();
const double box_size = 20.0;
const double width = canvas.width();
@@ -468,9 +468,9 @@ ThemeManager::build_palette_canvas (ArdourCanvas::Canvas& canvas, ArdourCanvas::
uint32_t color_num = 0;
/* clear existing rects and delete them */
-
+
group.clear (true);
-
+
for (uint32_t y = 0; y < height - box_size && color_num < color_limit; y += box_size) {
for (uint32_t x = 0; x < width - box_size && color_num < color_limit; x += box_size) {
ArdourCanvas::Rectangle* r = new ArdourCanvas::Rectangle (&group, ArdourCanvas::Rect (x, y, x + box_size, y + box_size));
@@ -501,7 +501,7 @@ ThemeManager::palette_size_request (Gtk::Requisition* req)
req->height = (int) floor (c * box_size);
/* add overflow row if necessary */
-
+
if (fmod (ncolors, c) != 0.0) {
req->height += box_size;
}
@@ -554,7 +554,7 @@ ThemeManager::palette_color_response (int result, std::string name)
using namespace ArdourCanvas;
color_dialog_connection.disconnect ();
-
+
UIConfiguration* uic (&UIConfiguration::instance());
Gdk::Color gdkcolor;
double r,g, b, a;
@@ -567,10 +567,10 @@ ThemeManager::palette_color_response (int result, std::string name)
r = gdkcolor.get_red_p();
g = gdkcolor.get_green_p();
b = gdkcolor.get_blue_p();
-
+
uic->set_color (name, rgba_to_color (r, g, b, a));
break;
-
+
default:
break;
}
@@ -630,14 +630,14 @@ ThemeManager::choose_color_from_palette (string const & name)
palette_window = new ArdourDialog (_("Color Palette"));
palette_window->add_button (Stock::CANCEL, RESPONSE_REJECT); /* using CANCEL causes confusion if dialog is closed via CloseAllDialogs */
palette_window->add_button (Stock::OK, RESPONSE_OK);
-
+
ArdourCanvas::GtkCanvas* canvas = new ArdourCanvas::GtkCanvas ();
ArdourCanvas::Container* group = initialize_palette_canvas (*canvas);
-
+
canvas->signal_size_request().connect (sigc::mem_fun (*this, &ThemeManager::palette_size_request));
canvas->signal_size_allocate().connect (sigc::bind (sigc::mem_fun (*this, &ThemeManager::palette_canvas_allocated), group, canvas,
sigc::bind (sigc::mem_fun (*this, &ThemeManager::alias_palette_event), name)));
-
+
palette_window->get_vbox()->pack_start (*canvas);
palette_window->show_all ();
@@ -651,7 +651,7 @@ void
ThemeManager::setup_aliases ()
{
using namespace ArdourCanvas;
-
+
UIConfiguration* uic (&UIConfiguration::instance());
UIConfiguration::ColorAliases& aliases (uic->color_aliases);
@@ -683,7 +683,7 @@ ThemeManager::setup_aliases ()
row = *(alias_list->append());
row[alias_columns.name] = parent;
row[alias_columns.alias] = "";
-
+
/* now add the child as a child of this one */
row = *(alias_list->insert (row->children().end()));
diff --git a/gtk2_ardour/theme_manager.h b/gtk2_ardour/theme_manager.h
index d4a8653bcf..6ed58207fa 100644
--- a/gtk2_ardour/theme_manager.h
+++ b/gtk2_ardour/theme_manager.h
@@ -64,20 +64,20 @@ class ThemeManager : public Gtk::VBox
private:
Gtk::Notebook notebook;
-
+
struct BasicColorDisplayModelColumns : public Gtk::TreeModel::ColumnRecord {
BasicColorDisplayModelColumns() {
add (name);
add (gdkcolor);
}
-
+
Gtk::TreeModelColumn<std::string> name;
Gtk::TreeModelColumn<Gdk::Color> gdkcolor;
};
-
+
Gtk::ColorSelectionDialog color_dialog;
sigc::connection color_dialog_connection;
-
+
Gtk::HBox theme_selection_hbox;
Gtk::RadioButton dark_button;
Gtk::RadioButton light_button;
@@ -104,7 +104,7 @@ class ThemeManager : public Gtk::VBox
Gtk::ScrolledWindow palette_scroller;
ArdourCanvas::GtkCanvasViewport palette_viewport;
ArdourCanvas::Container* palette_group;
-
+
/* these methods create and manage a canvas for use in either the
palette tab or in a separate dialog. Different behaviour is
accomplished by changing the event handler passed into the
@@ -130,7 +130,7 @@ class ThemeManager : public Gtk::VBox
on it inside the palette tab.
*/
void edit_palette_color (std::string);
-
+
struct ColorAliasModelColumns : public Gtk::TreeModel::ColumnRecord {
ColorAliasModelColumns() {
add (name);
@@ -138,7 +138,7 @@ class ThemeManager : public Gtk::VBox
add (color);
add (key);
}
-
+
Gtk::TreeModelColumn<std::string> name;
Gtk::TreeModelColumn<std::string> alias;
Gtk::TreeModelColumn<Gdk::Color> color;
@@ -154,9 +154,9 @@ class ThemeManager : public Gtk::VBox
ArdourDialog* palette_window;
sigc::connection palette_response_connection;
-
+
void choose_color_from_palette (std::string const &target_name);
-
+
bool alias_palette_event (GdkEvent*, std::string, std::string);
void alias_palette_response (int, std::string, std::string);
@@ -165,10 +165,10 @@ class ThemeManager : public Gtk::VBox
Gtk::ScrolledWindow modifier_scroller;
Gtk::VBox modifier_vbox;
-
+
void setup_modifiers ();
void modifier_edited (Gtk::Range*, std::string);
-
+
void colors_changed ();
void set_ui_to_state ();
};
diff --git a/gtk2_ardour/time_axis_view.cc b/gtk2_ardour/time_axis_view.cc
index 09799c7d14..436e161583 100644
--- a/gtk2_ardour/time_axis_view.cc
+++ b/gtk2_ardour/time_axis_view.cc
@@ -138,7 +138,7 @@ TimeAxisView::TimeAxisView (ARDOUR::Session* sess, PublicEditor& ed, TimeAxisVie
CANVAS_DEBUG_NAME (selection_group, "selection for TAV");
selection_group->set_data (X_("timeselection"), (void *) 1);
selection_group->hide();
-
+
_ghost_group = new ArdourCanvas::Container (_canvas_display);
CANVAS_DEBUG_NAME (_ghost_group, "ghost for TAV");
_ghost_group->lower_to_bottom();
@@ -319,7 +319,7 @@ TimeAxisView::show_at (double y, int& nth, VBox *parent)
_canvas_display->raise_to_top ();
_canvas_display->show ();
-
+
_hidden = false;
_effective_height = current_height ();
@@ -407,7 +407,7 @@ TimeAxisView::controls_ebox_button_press (GdkEventButton* event)
}
_ebox_release_can_act = true;
-
+
if (maybe_set_cursor (event->y) > 0) {
_resize_drag_start = event->y_root;
}
@@ -668,7 +668,7 @@ TimeAxisView::begin_name_edit ()
if (can_edit_name()) {
name_entry = manage (new Gtkmm2ext::FocusEntry);
-
+
name_entry->set_width_chars(8); // min width, entry expands
name_entry->set_name ("EditorTrackNameDisplay");
@@ -681,7 +681,7 @@ TimeAxisView::begin_name_edit ()
if (name_label.is_ancestor (name_hbox)) {
name_hbox.remove (name_label);
}
-
+
name_hbox.pack_end (*name_entry, true, true);
name_entry->show ();
@@ -705,9 +705,9 @@ TimeAxisView::end_name_edit (int response)
*/
return;
}
-
+
PBD::Unwinder<bool> uw (ending_name_edit, true);
-
+
bool edit_next = false;
bool edit_prev = false;
@@ -743,24 +743,24 @@ TimeAxisView::end_name_edit (int response)
TrackViewList const & allviews = _editor.get_track_views ();
TrackViewList::const_iterator i = find (allviews.begin(), allviews.end(), this);
-
+
if (i != allviews.end()) {
-
+
do {
if (++i == allviews.end()) {
return;
}
-
+
RouteTimeAxisView* rtav = dynamic_cast<RouteTimeAxisView*>(*i);
-
+
if (rtav && rtav->route()->record_enabled()) {
continue;
}
-
+
if (!(*i)->hidden()) {
break;
}
-
+
} while (true);
}
@@ -773,28 +773,28 @@ TimeAxisView::end_name_edit (int response)
TrackViewList const & allviews = _editor.get_track_views ();
TrackViewList::const_iterator i = find (allviews.begin(), allviews.end(), this);
-
+
if (i != allviews.begin()) {
do {
if (i == allviews.begin()) {
return;
}
-
+
--i;
-
+
RouteTimeAxisView* rtav = dynamic_cast<RouteTimeAxisView*>(*i);
-
+
if (rtav && rtav->route()->record_enabled()) {
continue;
}
-
+
if (!(*i)->hidden()) {
break;
}
-
+
} while (true);
}
-
+
if ((i != allviews.end()) && (*i != this) && !(*i)->hidden()) {
_editor.ensure_time_axis_view_is_visible (**i, false);
(*i)->begin_name_edit ();
@@ -1226,19 +1226,19 @@ TimeAxisView::color_handler ()
(*i)->start_trim->set_fill_color (UIConfiguration::instance().color ("selection"));
(*i)->start_trim->set_outline_color (UIConfiguration::instance().color ("selection"));
-
+
(*i)->end_trim->set_fill_color (UIConfiguration::instance().color ("selection"));
(*i)->end_trim->set_outline_color (UIConfiguration::instance().color ("selection"));
}
-
+
for (list<SelectionRect*>::iterator i = free_selection_rects.begin(); i != free_selection_rects.end(); ++i) {
-
+
(*i)->rect->set_fill_color (UIConfiguration::instance().color_mod ("selection rect", "selection rect"));
(*i)->rect->set_outline_color (UIConfiguration::instance().color ("selection"));
-
+
(*i)->start_trim->set_fill_color (UIConfiguration::instance().color ("selection"));
(*i)->start_trim->set_outline_color (UIConfiguration::instance().color ("selection"));
-
+
(*i)->end_trim->set_fill_color (UIConfiguration::instance().color ("selection"));
(*i)->end_trim->set_outline_color (UIConfiguration::instance().color ("selection"));
}
@@ -1314,7 +1314,7 @@ TimeAxisView::covered_by_y_range (double y0, double y1) const
/* if either the top or bottom of the axisview is in the vertical
* range, we cover it.
*/
-
+
if ((y0 < _y_position && y1 < _y_position) ||
(y0 >= _y_position + height && y1 >= _y_position + height)) {
return false;
@@ -1392,7 +1392,7 @@ TimeAxisView::reset_visual_state ()
/* this method is not required to trigger a global redraw */
string str = gui_property ("height");
-
+
if (!str.empty()) {
set_height (atoi (str));
} else {
diff --git a/gtk2_ardour/time_axis_view_item.cc b/gtk2_ardour/time_axis_view_item.cc
index c985088c1e..5a85005e3a 100644
--- a/gtk2_ardour/time_axis_view_item.cc
+++ b/gtk2_ardour/time_axis_view_item.cc
@@ -146,9 +146,9 @@ TimeAxisViewItem::TimeAxisViewItem (const TimeAxisViewItem& other)
/* share the other's parent, but still create a new group */
ArdourCanvas::Item* parent = other.group->parent();
-
+
_selected = other._selected;
-
+
init (parent, other.samples_per_pixel, other.fill_color, other.frame_position,
other.item_duration, other.visibility, other.wide_enough_for_name, other.high_enough_for_name);
}
@@ -189,7 +189,7 @@ TimeAxisViewItem::init (ArdourCanvas::Item* parent, double fpp, uint32_t base_co
ArdourCanvas::Rect (0.0, 0.0,
trackview.editor().sample_to_pixel(duration),
trackview.current_height()));
-
+
frame->set_outline_what (ArdourCanvas::Rectangle::What (ArdourCanvas::Rectangle::LEFT|ArdourCanvas::Rectangle::RIGHT));
CANVAS_DEBUG_NAME (frame, string_compose ("frame for %1", get_item_name()));
@@ -200,7 +200,7 @@ TimeAxisViewItem::init (ArdourCanvas::Item* parent, double fpp, uint32_t base_co
frame->set_outline_color (UIConfiguration::instance().color ("time axis frame"));
}
}
-
+
if (UIConfiguration::instance().get_show_name_highlight() && (visibility & ShowNameHighlight)) {
/* rectangle size will be set in ::manage_name_highlight() */
@@ -488,7 +488,7 @@ TimeAxisViewItem::set_selected(bool yn)
if (_selected == yn) {
return;
}
-
+
Selectable::set_selected (yn);
set_frame_color ();
set_name_text_color ();
@@ -557,7 +557,7 @@ TimeAxisViewItem::set_height (double height)
}
if (frame) {
-
+
frame->set_y0 (0.0);
frame->set_y1 (height);
@@ -603,7 +603,7 @@ TimeAxisViewItem::manage_name_highlight ()
name_highlight->show();
// name_highlight->set_x_position (1.0);
name_highlight->set (ArdourCanvas::Rect (0.0, (double) _height - NAME_HIGHLIGHT_SIZE, _width - 2.0, _height));
-
+
} else {
name_highlight->hide();
}
@@ -658,10 +658,10 @@ TimeAxisViewItem::set_name_text_color ()
if (!name_text) {
return;
}
-
+
uint32_t f;
-
+
if (UIConfiguration::instance().get_show_name_highlight()) {
/* name text will always be on top of name highlight, which
will always use our fill color.
@@ -718,7 +718,7 @@ TimeAxisViewItem::set_frame_gradient ()
frame->set_gradient (ArdourCanvas::Fill::StopList (), 0);
return;
}
-
+
ArdourCanvas::Fill::StopList stops;
double r, g, b, a;
double h, s, v;
@@ -726,18 +726,18 @@ TimeAxisViewItem::set_frame_gradient ()
/* need to get alpha value */
ArdourCanvas::color_to_rgba (f, r, g, b, a);
-
+
stops.push_back (std::make_pair (0.0, f));
-
+
/* now a darker version */
-
+
ArdourCanvas::color_to_hsv (f, h, s, v);
v = min (1.0, v * (1.0 - UIConfiguration::instance().get_timeline_item_gradient_depth()));
-
+
ArdourCanvas::Color darker = ArdourCanvas::hsva_to_color (h, s, v, a);
stops.push_back (std::make_pair (1.0, darker));
-
+
frame->set_gradient (stops, true);
}
@@ -895,7 +895,7 @@ TimeAxisViewItem::manage_name_text ()
name_text->hide ();
return;
}
-
+
if (name_text->text().empty()) {
name_text->hide ();
}
diff --git a/gtk2_ardour/time_fx_dialog.cc b/gtk2_ardour/time_fx_dialog.cc
index 5d8bf57a3b..7efabc93ed 100644
--- a/gtk2_ardour/time_fx_dialog.cc
+++ b/gtk2_ardour/time_fx_dialog.cc
@@ -157,7 +157,7 @@ TimeFXDialog::TimeFXDialog (Editor& e, bool pitch)
}
set_default_response (Gtk::RESPONSE_ACCEPT);
-
+
VBox* progress_box = manage (new VBox);
progress_box->set_spacing (6);
diff --git a/gtk2_ardour/time_fx_dialog.h b/gtk2_ardour/time_fx_dialog.h
index 424bfe9813..a7e4a7ab10 100644
--- a/gtk2_ardour/time_fx_dialog.h
+++ b/gtk2_ardour/time_fx_dialog.h
@@ -68,7 +68,7 @@ public:
gint delete_in_progress (GdkEventAny*);
private:
-
+
void update_progress_gui (float);
};
diff --git a/gtk2_ardour/time_info_box.cc b/gtk2_ardour/time_info_box.cc
index 55e7472f4f..a26ec50932 100644
--- a/gtk2_ardour/time_info_box.cc
+++ b/gtk2_ardour/time_info_box.cc
@@ -235,7 +235,7 @@ TimeInfoBox::sync_punch_mode (AudioClock* src)
syncing_punch = false;
}
}
-
+
void
TimeInfoBox::set_session (Session* s)
@@ -251,11 +251,11 @@ TimeInfoBox::set_session (Session* s)
if (s) {
Location* punch = s->locations()->auto_punch_location ();
-
+
if (punch) {
watch_punch (punch);
}
-
+
punch_changed (punch);
_session->auto_punch_location_changed.connect (_session_connections, MISSING_INVALIDATOR,
@@ -329,7 +329,7 @@ TimeInfoBox::selection_changed ()
Glib::RefPtr<Action> act = ActionManager::get_action ("MouseMode", "set-mouse-mode-object-range");
Glib::RefPtr<ToggleAction> tact = Glib::RefPtr<ToggleAction>::cast_dynamic (act);
- if (tact && tact->get_active() && !selection.regions.empty()) {
+ if (tact && tact->get_active() && !selection.regions.empty()) {
/* show selected regions */
s = selection.regions.start();
e = selection.regions.end_frame();
@@ -357,7 +357,7 @@ TimeInfoBox::selection_changed ()
default:
selection_start->set_off (true);
selection_end->set_off (true);
- selection_length->set_off (true);
+ selection_length->set_off (true);
break;
}
}
@@ -395,5 +395,5 @@ TimeInfoBox::punch_changed (Location* loc)
punch_start->set (loc->start());
punch_end->set (loc->end());
-}
+}
diff --git a/gtk2_ardour/ui_config.cc b/gtk2_ardour/ui_config.cc
index 232eb8f1a4..d4ec4ca9f8 100644
--- a/gtk2_ardour/ui_config.cc
+++ b/gtk2_ardour/ui_config.cc
@@ -120,7 +120,7 @@ void
UIConfiguration::parameter_changed (string param)
{
_dirty = true;
-
+
if (param == "ui-rc-file") {
load_rc_file (true);
} else if (param == "color-file") {
@@ -136,9 +136,9 @@ UIConfiguration::reset_gtk_theme ()
stringstream ss;
ss << "gtk_color_scheme = \"" << hex;
-
+
for (ColorAliases::iterator g = color_aliases.begin(); g != color_aliases.end(); ++g) {
-
+
if (g->first.find ("gtk_") == 0) {
const string gtk_name = g->first.substr (4);
ss << gtk_name << ":#" << std::setw (6) << setfill ('0') << (color (g->second) >> 8) << ';';
@@ -223,7 +223,7 @@ UIConfiguration::load_defaults ()
{
std::string rcfile;
int ret = -1;
-
+
if (find_file (ardour_config_search_path(), default_ui_config_file_name, rcfile) ) {
XMLTree tree;
@@ -274,7 +274,7 @@ UIConfiguration::load_color_theme (bool allow_own)
if (!found) {
basename = color_file.get();
basename += ".colors";
-
+
if (find_file (ardour_config_search_path(), basename, cfile)) {
found = true;
}
@@ -283,7 +283,7 @@ UIConfiguration::load_color_theme (bool allow_own)
if (found) {
XMLTree tree;
-
+
info << string_compose (_("Loading color file %1"), cfile) << endmsg;
if (!tree.read (cfile.c_str())) {
@@ -322,7 +322,7 @@ UIConfiguration::store_color_theme ()
parent->add_child_nocopy (*node);
}
root->add_child_nocopy (*parent);
-
+
parent = new XMLNode (X_("ColorAliases"));
for (ColorAliases::const_iterator i = color_aliases.begin(); i != color_aliases.end(); ++i) {
XMLNode* node = new XMLNode (X_("ColorAlias"));
@@ -343,7 +343,7 @@ UIConfiguration::store_color_theme ()
XMLTree tree;
std::string colorfile = Glib::build_filename (user_config_directory(), (string ("my-") + color_file.get() + ".colors"));
-
+
tree.set_root (root);
if (!tree.write (colorfile.c_str())){
@@ -410,7 +410,7 @@ UIConfiguration::save_state()
if (_dirty) {
std::string rcfile = Glib::build_filename (user_config_directory(), ui_config_file_name);
-
+
XMLTree tree;
tree.set_root (&get_state());
@@ -434,7 +434,7 @@ UIConfiguration::save_state()
colors_modified = false;
modifiers_modified = false;
}
-
+
return 0;
}
@@ -530,7 +530,7 @@ UIConfiguration::load_color_aliases (XMLNode const & node)
XMLNodeConstIterator niter;
XMLProperty const *name;
XMLProperty const *alias;
-
+
color_aliases.clear ();
for (niter = nlist.begin(); niter != nlist.end(); ++niter) {
@@ -553,7 +553,7 @@ UIConfiguration::load_colors (XMLNode const & node)
XMLNodeConstIterator niter;
XMLProperty const *name;
XMLProperty const *color;
-
+
colors.clear ();
for (niter = nlist.begin(); niter != nlist.end(); ++niter) {
@@ -579,9 +579,9 @@ UIConfiguration::load_modifiers (XMLNode const & node)
XMLNodeConstIterator niter;
XMLProperty const *name;
XMLProperty const *mod;
-
+
modifiers.clear ();
-
+
for (niter = nlist.begin(); niter != nlist.end(); ++niter) {
if ((*niter)->name() != X_("Modifier")) {
continue;
@@ -639,7 +639,7 @@ UIConfiguration::color (const std::string& name, bool* failed) const
if (failed) {
*failed = false;
}
-
+
if (e != color_aliases.end ()) {
Colors::const_iterator rc = colors.find (e->second);
if (rc != colors.end()) {
@@ -652,7 +652,7 @@ UIConfiguration::color (const std::string& name, bool* failed) const
return rc->second;
}
}
-
+
if (!failed) {
/* only show this message if the caller wasn't interested in
the fail status.
@@ -663,7 +663,7 @@ UIConfiguration::color (const std::string& name, bool* failed) const
if (failed) {
*failed = true;
}
-
+
return rgba_to_color ((g_random_int()%256)/255.0,
(g_random_int()%256)/255.0,
(g_random_int()%256)/255.0,
diff --git a/gtk2_ardour/ui_config.h b/gtk2_ardour/ui_config.h
index 15a58ffc44..06338aae39 100644
--- a/gtk2_ardour/ui_config.h
+++ b/gtk2_ardour/ui_config.h
@@ -69,7 +69,7 @@ private:
void set_alias (std::string const & name, std::string const & alias);
void set_color (const std::string& name, ArdourCanvas::Color);
void set_modifier (std::string const &, ArdourCanvas::SVAModifier svam);
-
+
std::string color_as_alias (ArdourCanvas::Color c);
ArdourCanvas::Color quantized (ArdourCanvas::Color) const;
@@ -85,7 +85,7 @@ private:
void set_pango_fontsize ();
float get_ui_scale ();
-
+
sigc::signal<void> DPIReset;
sigc::signal<void,std::string> ParameterChanged;
@@ -102,7 +102,7 @@ private:
/** called after the GUI toolkit has been initialized.
*/
UIConfiguration* post_gui_init ();
-
+
#undef UI_CONFIG_VARIABLE
#define UI_CONFIG_VARIABLE(Type,var,name,value) \
Type get_##var () const { return var.get(); } \
@@ -132,7 +132,7 @@ private:
bool aliases_modified;
bool colors_modified;
bool modifiers_modified;
-
+
int store_color_theme ();
void load_color_aliases (XMLNode const &);
void load_colors (XMLNode const &);
diff --git a/gtk2_ardour/utils.cc b/gtk2_ardour/utils.cc
index e0607675df..68f4c83426 100644
--- a/gtk2_ardour/utils.cc
+++ b/gtk2_ardour/utils.cc
@@ -507,7 +507,7 @@ ARDOUR_UI_UTILS::key_press_focus_accelerator_handler (Gtk::Window& window, GdkEv
ev->keyval, fakekey));
DEBUG_TRACE (DEBUG::Accelerators, string_compose ("\tmodified modifier was %1\n", show_gdk_event_state (modifier)));
-
+
if (allow_activating && gtk_accel_groups_activate(G_OBJECT(win), fakekey, modifier)) {
DEBUG_TRACE (DEBUG::Accelerators, "\taccel group activated by fakekey\n");
return true;
@@ -590,7 +590,7 @@ ARDOUR_UI_UTILS::get_icon_sets ()
Searchpath spath(ARDOUR::ardour_data_search_path());
spath.add_subdirectory_to_paths ("icons");
vector<string> r;
-
+
r.push_back (_("default"));
for (vector<string>::iterator s = spath.begin(); s != spath.end(); ++s) {
@@ -626,22 +626,22 @@ ARDOUR_UI_UTILS::get_icon_path (const char* cname, string icon_set, bool is_imag
/* add "icons/icon_set" but .. not allowed to add both of these at once */
spath.add_subdirectory_to_paths ("icons");
spath.add_subdirectory_to_paths (icon_set);
-
+
find_file (spath, name, data_file_path);
} else {
spath.add_subdirectory_to_paths ("icons");
find_file (spath, name, data_file_path);
}
-
+
if (is_image && data_file_path.empty()) {
-
+
if (!icon_set.empty() && icon_set != _("default")) {
warning << string_compose (_("icon \"%1\" not found for icon set \"%2\", fallback to default"), cname, icon_set) << endmsg;
}
-
+
Searchpath def (ARDOUR::ardour_data_search_path());
def.add_subdirectory_to_paths ("icons");
-
+
if (!find_file (def, name, data_file_path)) {
fatal << string_compose (_("cannot find icon image for %1 using %2"), name, spath.to_string()) << endmsg;
abort(); /*NOTREACHED*/
diff --git a/gtk2_ardour/verbose_cursor.h b/gtk2_ardour/verbose_cursor.h
index 7d12a2a13e..6160bb3296 100644
--- a/gtk2_ardour/verbose_cursor.h
+++ b/gtk2_ardour/verbose_cursor.h
@@ -41,7 +41,7 @@ public:
void show ();
void hide ();
-
+
private:
Editor* _editor;
ArdourCanvas::TrackingText* _canvas_item;
diff --git a/gtk2_ardour/visibility_group.cc b/gtk2_ardour/visibility_group.cc
index 82621283b6..46a941d0fc 100644
--- a/gtk2_ardour/visibility_group.cc
+++ b/gtk2_ardour/visibility_group.cc
@@ -54,7 +54,7 @@ VisibilityGroup::add (Gtk::Widget* widget, string const & id, string const & nam
m.name = name;
m.visible = visible;
m.override = override;
-
+
_members.push_back (m);
}
@@ -161,7 +161,7 @@ VisibilityGroup::set_state (string v)
}
v = v.substr (comma + 1);
-
+
} while (1);
update ();
@@ -195,11 +195,11 @@ VisibilityGroup::update_list_view ()
if (!_model) {
return;
}
-
+
_ignore_list_view_change = true;
_model->clear ();
-
+
for (vector<Member>::iterator i = _members.begin(); i != _members.end(); ++i) {
Gtk::TreeModel::iterator j = _model->append ();
Gtk::TreeModel::Row row = *j;
@@ -235,7 +235,7 @@ VisibilityGroup::list_view_visible_changed (string const & path)
if (_ignore_list_view_change) {
return;
}
-
+
Gtk::TreeModel::iterator i = _model->get_iter (path);
if (!i) {
return;
diff --git a/gtk2_ardour/visibility_group.h b/gtk2_ardour/visibility_group.h
index 20be7dcf72..8ac2c1db5f 100644
--- a/gtk2_ardour/visibility_group.h
+++ b/gtk2_ardour/visibility_group.h
@@ -36,7 +36,7 @@ class VisibilityGroup
{
public:
VisibilityGroup (std::string const &);
-
+
void add (
Gtk::Widget *,
std::string const &,
@@ -44,7 +44,7 @@ public:
bool visible = false,
boost::function<boost::optional<bool> ()> = 0
);
-
+
Gtk::Menu* menu ();
Gtk::Widget* list_view ();
bool button_press_event (GdkEventButton *);
@@ -55,7 +55,7 @@ public:
std::string get_state_value () const;
PBD::Signal0<void> VisibilityChanged;
-
+
private:
struct Member {
diff --git a/gtk2_ardour/volume_controller.cc b/gtk2_ardour/volume_controller.cc
index 85f615aea8..346ed6e33b 100644
--- a/gtk2_ardour/volume_controller.cc
+++ b/gtk2_ardour/volume_controller.cc
@@ -63,7 +63,7 @@ void
VolumeController::dB_printer (char buf[32], const boost::shared_ptr<PBD::Controllable>& c)
{
if (c) {
-
+
if (_linear) {
double val = accurate_coefficient_to_dB (c->get_value());
@@ -83,7 +83,7 @@ VolumeController::dB_printer (char buf[32], const boost::shared_ptr<PBD::Control
}
} else {
-
+
double dB = accurate_coefficient_to_dB (c->get_value());
if (step_inc < 1.0) {
diff --git a/gtk2_ardour/vst_plugin_ui.cc b/gtk2_ardour/vst_plugin_ui.cc
index a5e3afe300..a964e96b4e 100644
--- a/gtk2_ardour/vst_plugin_ui.cc
+++ b/gtk2_ardour/vst_plugin_ui.cc
@@ -94,7 +94,7 @@ VSTPluginUI::package (Gtk::Window& win)
_vst->state()->width + _vst->state()->hoffset,
_vst->state()->height + _vst->state()->voffset);
#endif
-
+
return 0;
}
diff --git a/gtk2_ardour/vst_plugin_ui.h b/gtk2_ardour/vst_plugin_ui.h
index 8996fe0a21..5c8df726c7 100644
--- a/gtk2_ardour/vst_plugin_ui.h
+++ b/gtk2_ardour/vst_plugin_ui.h
@@ -41,11 +41,11 @@ public:
virtual int package (Gtk::Window &);
bool non_gtk_gui () const { return true; }
-
+
protected:
virtual int get_XID () = 0;
-
+
boost::shared_ptr<ARDOUR::VSTPlugin> _vst;
Gtk::Socket _socket;
diff --git a/gtk2_ardour/window_manager.cc b/gtk2_ardour/window_manager.cc
index f15e0b3621..b476787926 100644
--- a/gtk2_ardour/window_manager.cc
+++ b/gtk2_ardour/window_manager.cc
@@ -163,7 +163,7 @@ Manager::set_transient_for (Gtk::Window* parent)
}
}
}
-
+
current_transient_parent = parent;
#endif
}
@@ -300,12 +300,12 @@ XMLNode&
ProxyBase::get_state () const
{
XMLNode* node = new XMLNode (X_("Window"));
- char buf[32];
+ char buf[32];
node->add_property (X_("name"), _name);
if (_window && vistracker) {
-
+
/* we have a window, so use current state */
_visible = vistracker->partially_visible ();
@@ -316,7 +316,7 @@ ProxyBase::get_state () const
}
node->add_property (X_("visible"), _visible? X_("yes") : X_("no"));
-
+
snprintf (buf, sizeof (buf), "%d", _x_off);
node->add_property (X_("x-off"), buf);
snprintf (buf, sizeof (buf), "%d", _y_off);
@@ -371,7 +371,7 @@ ProxyBase::setup ()
}
set_session(_session);
}
-
+
void
ProxyBase::show ()
{
diff --git a/gtk2_ardour/window_manager.h b/gtk2_ardour/window_manager.h
index 40591f84ba..6e89be3b26 100644
--- a/gtk2_ardour/window_manager.h
+++ b/gtk2_ardour/window_manager.h
@@ -74,7 +74,7 @@ class Manager : public ARDOUR::SessionHandlePtr
static Manager* _instance;
};
-
+
class ProxyBase : public ARDOUR::SessionHandlePtr, public sigc::trackable {
public:
ProxyBase (const std::string& name, const std::string& menu_name);
@@ -126,7 +126,7 @@ class ProxyBase : public ARDOUR::SessionHandlePtr, public sigc::trackable {
void setup ();
};
-
+
class ProxyTemporary: public ProxyBase {
public:
ProxyTemporary (const std::string& name, Gtk::Window* win);
@@ -143,16 +143,16 @@ class ProxyTemporary: public ProxyBase {
ARDOUR::SessionHandlePtr* session_handle ();
};
-
+
template<typename T>
class ProxyWithConstructor: public ProxyBase {
public:
ProxyWithConstructor (const std::string& name, const std::string& menu_name, const boost::function<T*()>& c)
: ProxyBase (name, menu_name) , creator (c) {}
-
+
ProxyWithConstructor (const std::string& name, const std::string& menu_name, const boost::function<T*()>& c, const XMLNode* node)
: ProxyBase (name, menu_name, *node) , creator (c) {}
-
+
Gtk::Window* get (bool create = false) {
if (!_window) {
if (!create) {
@@ -163,7 +163,7 @@ class ProxyWithConstructor: public ProxyBase {
if (_window) {
setup ();
- }
+ }
}
return _window;
@@ -199,7 +199,7 @@ class Proxy : public ProxyBase {
Proxy (const std::string& name, const std::string& menu_name, const XMLNode* node)
: ProxyBase (name, menu_name, *node) {}
-
+
Gtk::Window* get (bool create = false) {
if (!_window) {
if (!create) {
@@ -210,7 +210,7 @@ class Proxy : public ProxyBase {
if (_window) {
setup ();
- }
+ }
}
return _window;
diff --git a/gtk2_ardour/windows_vst_plugin_ui.cc b/gtk2_ardour/windows_vst_plugin_ui.cc
index e8bb51cb1c..5281890963 100644
--- a/gtk2_ardour/windows_vst_plugin_ui.cc
+++ b/gtk2_ardour/windows_vst_plugin_ui.cc
@@ -86,10 +86,10 @@ WindowsVSTPluginUI::forward_key_event (GdkEventKey* ev)
/* buffer full */
return;
}
-
+
int special_windows_key = 0;
int character_windows_key = 0;
-
+
switch (ev->keyval) {
case GDK_Left:
special_windows_key = 0x25;
@@ -111,11 +111,11 @@ WindowsVSTPluginUI::forward_key_event (GdkEventKey* ev)
character_windows_key = ev->keyval;
break;
}
-
+
fst->pending_keys[fst->n_pending_keys].special = special_windows_key;
fst->pending_keys[fst->n_pending_keys].character = character_windows_key;
fst->n_pending_keys++;
-
+
pthread_mutex_unlock (&fst->lock);
}
diff --git a/gtk2_ardour/windows_vst_plugin_ui.h b/gtk2_ardour/windows_vst_plugin_ui.h
index 2fa0bbc705..8b366b7da6 100644
--- a/gtk2_ardour/windows_vst_plugin_ui.h
+++ b/gtk2_ardour/windows_vst_plugin_ui.h
@@ -33,7 +33,7 @@ public:
void forward_key_event (GdkEventKey *);
private:
-
+
int get_XID ();
-
+
};