X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=gtk2_ardour%2Ftime_axis_view.cc;h=b0618fdb028f7ec91c126531a27d91779d1fe386;hb=b65f8073ba306ac2d85133875746767e7c6b0eb6;hp=f62895c6f75edbbc70593353ea7748eb511459b5;hpb=7183242b8c8d9296f94a035fb66b1eae06fd3496;p=ardour.git diff --git a/gtk2_ardour/time_axis_view.cc b/gtk2_ardour/time_axis_view.cc index f62895c6f7..b0618fdb02 100644 --- a/gtk2_ardour/time_axis_view.cc +++ b/gtk2_ardour/time_axis_view.cc @@ -54,6 +54,7 @@ #include "i18n.h" +using namespace std; using namespace Gtk; using namespace Gdk; using namespace sigc; @@ -73,7 +74,7 @@ uint32_t TimeAxisView::hSmall = 0; bool TimeAxisView::need_size_info = true; int const TimeAxisView::_max_order = 512; -TimeAxisView::TimeAxisView (ARDOUR::Session& sess, PublicEditor& ed, TimeAxisView* rent, Canvas& canvas) +TimeAxisView::TimeAxisView (ARDOUR::Session& sess, PublicEditor& ed, TimeAxisView* rent, Canvas& /*canvas*/) : AxisView (sess), controls_table (2, 8), _y_position (0), @@ -174,11 +175,6 @@ TimeAxisView::TimeAxisView (ARDOUR::Session& sess, PublicEditor& ed, TimeAxisVie controls_hbox.pack_start (controls_ebox,true,true); controls_hbox.show (); - // controls_frame.add (controls_hbox); - // controls_frame.set_name ("TimeAxisViewControlsBaseUnselected"); - // controls_vbox.set_name ("TimeAxisViewControlsBaseUnselected"); - // controls_frame.set_shadow_type (Gtk::SHADOW_ETCHED_OUT); - ColorsChanged.connect (mem_fun (*this, &TimeAxisView::color_handler)); } @@ -354,7 +350,6 @@ TimeAxisView::hide () _canvas_display->hide (); _canvas_background->hide (); - controls_frame.hide (); if (control_parent) { control_parent->remove (controls_hbox); @@ -503,7 +498,7 @@ TimeAxisView::name_entry_key_release (GdkEventKey* ev) } bool -TimeAxisView::name_entry_focus_in (GdkEventFocus* ev) +TimeAxisView::name_entry_focus_in (GdkEventFocus*) { name_entry.select_region (0, -1); name_entry.set_name ("EditorActiveTrackNameDisplay"); @@ -511,7 +506,7 @@ TimeAxisView::name_entry_focus_in (GdkEventFocus* ev) } bool -TimeAxisView::name_entry_focus_out (GdkEventFocus* ev) +TimeAxisView::name_entry_focus_out (GdkEventFocus*) { /* clean up */ @@ -908,13 +903,13 @@ TimeAxisView::remove_child (boost::shared_ptr child) } void -TimeAxisView::get_selectables (nframes_t start, nframes_t end, double top, double bot, list& result) +TimeAxisView::get_selectables (nframes_t /*start*/, nframes_t /*end*/, double /*top*/, double /*bot*/, list& /*result*/) { return; } void -TimeAxisView::get_inverted_selectables (Selection& sel, list& result) +TimeAxisView::get_inverted_selectables (Selection& /*sel*/, list& /*result*/) { return; } @@ -1283,16 +1278,13 @@ bool TimeAxisView::resizer_button_press (GdkEventButton* event) { _resize_drag_start = event->y_root; - _resize_idle_target = current_height (); - _editor.start_resize_line_ops (); return true; } bool -TimeAxisView::resizer_button_release (GdkEventButton* ev) +TimeAxisView::resizer_button_release (GdkEventButton*) { _resize_drag_start = -1; - _editor.end_resize_line_ops (); return true; } @@ -1309,11 +1301,8 @@ TimeAxisView::resizer_motion (GdkEventMotion* ev) return true; } - int32_t const delta = (int32_t) floor (_resize_drag_start - ev->y_root); - - _resize_idle_target = std::max (_resize_idle_target - delta, (int) hSmall); - _editor.add_to_idle_resize (this, _resize_idle_target); - + int32_t const delta = (int32_t) floor (ev->y_root - _resize_drag_start); + _editor.add_to_idle_resize (this, delta); _resize_drag_start = ev->y_root; return true;