tav_expand_button.set_name ("TrackHeightButton");
tav_expand_button.set_size_request(-1,20);
tav_expand_button.add (*(manage (new Image (::get_icon("tav_exp")))));
- tav_expand_button.signal_clicked().connect (sigc::bind (sigc::mem_fun(*this, &Editor::tav_zoom_step), true));
+ tav_expand_button.signal_clicked().connect (sigc::bind (sigc::mem_fun(*this, &Editor::tav_zoom_step), false));
tav_shrink_button.set_name ("TrackHeightButton");
tav_shrink_button.set_size_request(-1,20);
tav_shrink_button.add (*(manage (new Image (::get_icon("tav_shrink")))));
- tav_shrink_button.signal_clicked().connect (sigc::bind (sigc::mem_fun(*this, &Editor::tav_zoom_step), false));
+ tav_shrink_button.signal_clicked().connect (sigc::bind (sigc::mem_fun(*this, &Editor::tav_zoom_step), true));
_zoom_box.pack_start (tav_shrink_button);
_zoom_box.pack_start (tav_expand_button);
}
}
last_track_height_step_timestamp = get_microseconds();
- current_stepping_trackview->step_height (true);
+ current_stepping_trackview->step_height (false);
return true;
} else {
scroll_tracks_up_line ();
}
}
last_track_height_step_timestamp = get_microseconds();
- current_stepping_trackview->step_height (false);
+ current_stepping_trackview->step_height (true);
return true;
} else {
scroll_tracks_down_line ();
switch (ev->direction) {
case GDK_SCROLL_UP:
if (Keyboard::modifier_state_equals (ev->state, Keyboard::TertiaryModifier)) {
- step_height (true);
+ step_height (false);
return true;
} else if (Keyboard::no_modifiers_active (ev->state)) {
_editor.scroll_tracks_up_line();
case GDK_SCROLL_DOWN:
if (Keyboard::modifier_state_equals (ev->state, Keyboard::TertiaryModifier)) {
- step_height (false);
+ step_height (true);
return true;
} else if (Keyboard::no_modifiers_active (ev->state)) {
_editor.scroll_tracks_down_line();
Hiding ();
}
+/** Steps through the defined heights for this TrackView.
+ * @param coarser true if stepping should decrease in size, otherwise false.
+ */
void
-TimeAxisView::step_height (bool bigger)
+TimeAxisView::step_height (bool coarser)
{
static const uint32_t step = 25;
- if (bigger) {
- if (height == preset_height(HeightSmall)) {
- set_height_enum (HeightSmaller);
- } else if (height == preset_height(HeightSmaller)) {
- set_height_enum (HeightNormal);
- } else {
- set_height (height + step);
- }
-
- } else {
+ if (coarser) {
+
if (height == preset_height (HeightSmall)) {
return;
}
set_height_enum (HeightSmaller);
} else {
set_height (height - step);
- }
+ }
+
+ } else {
+
+ if (height == preset_height(HeightSmall)) {
+ set_height_enum (HeightSmaller);
+ } else if (height == preset_height(HeightSmaller)) {
+ set_height_enum (HeightNormal);
+ } else {
+ set_height (height + step);
+ }
+
}
}
std::pair<TimeAxisView*, ARDOUR::layer_t> covers_y_position (double);
- /**
- * Steps through the defined heights for this TrackView.
- * Sets bigger to true to step up in size, set to fals eot step smaller.
- *
- * @param bigger true if stepping should increase in size, false otherwise
- */
- virtual void step_height (bool bigger);
+ virtual void step_height (bool);
virtual ARDOUR::RouteGroup* route_group() const { return 0; }
virtual boost::shared_ptr<ARDOUR::Playlist> playlist() const { return boost::shared_ptr<ARDOUR::Playlist> (); }