Commit Graph

180 Commits

Author SHA1 Message Date
Thomas Brand
63ea7b6516 NO-OP whitespace (updated GH PR #357) 2017-07-01 19:28:26 +02:00
b4346862e1 context click on marker > loop range should set loop range 2017-05-11 13:16:07 +01:00
962e7a214a Revert "consistent use of context-menu popups"
This reverts commit b3722f7063.

In some cases ardour shows context-menu on right-mouse-button
release. In this case selecting a menu-entry should happen
with the left-mouse button (or any button?!)

Using ev->button is only correct if the menu is temporary and only
visible while the button is held, button release then activates the
menu-item.

This needs further work, in some cases allowing any button (0) to work
makes sense and overall consistency needs to be improved.
Different places use different strategies for context-menus which
don't always match the button used in the event-handler.

This is a hotfix (to make TAV context menus work again with left-click)
2017-03-24 14:48:46 +01:00
b3722f7063 consistent use of context-menu popups 2017-03-16 02:36:48 +01:00
nick_m
5c741b7a07 tempo editing updates
- a tempo marker may now be set to always continue (clamped)
	  this means that the end tempo of the previous section will
	  track the start tempo during tempo ops.
	  it mimics the behaviour in 5.8, with the gui indicating
	  the curves to be changed.
2017-03-05 05:21:56 +11:00
nick_m
38b5d88795 allow continuation of tempo via right-click 'Continue' where appropriate.
- this is the opposite of 'Ramp to Next'.
	  it removes discontinuities between the
	  last end tempo and the current by altering the current one.
2017-03-01 01:58:53 +11:00
nick_m
25d78ef306 only allow 'ramp to next' if the next tempo is actually different. 2017-02-27 20:16:10 +01:00
nick_m
f41748803a remove commented line 2017-02-27 20:16:10 +01:00
nick_m
bb8b229a1e fix tempo marker ramp to next. 2017-02-27 20:16:10 +01:00
nick_m
663d0e1743 add right-click 'Ramp to Next' tempo marker menu item. 2017-02-27 20:16:10 +01:00
nick_m
c9387055e4 remove "Make Ramped" from right click tempo marker menu. 2017-02-27 20:16:10 +01:00
nick_m
97c4c2a28c complete changes to tempo type.
- this implements in the intention behind the previous commit.
	  a tempo mark is constant until its end has been changed by a
	  shift-drag on the next marker.
2017-02-27 20:16:10 +01:00
nick_m
ccb51a8ddb rework tempo editing.
most changes are due to a new design where tempo discontinuities at the
beginning of a ramped section may be set.
this allows easier mapping of live performance, especially in
the common case of a ramped ritard before the beginning of a new section.

feature summary:

holding constraint modifier (shift) while dragging the BBT ruler area
drags the tempo lines by changing the start tempo (as before)

holding copy modifier (control) while dragging the BBT ruler area
drags the tempo lines by changing the end tempo (ahem. not quite there)

dragging a tempo mark while holding constraint (shift) will change the
previous end tempo to match the marker position *worth trying*.

holding constraint and copy modifier (control + shift) while dragging
the BBT ruler area attempts to'pinch' or twist the surrounding tempi
sp that later ones are not repositioned (currently suffereng from
rounding errors)
2017-02-27 20:16:10 +01:00
3d3f2a79f6 use leave/enter from track canvas to be the primary driver of region action sensitivity
This works for context menus also, because GTK sends us leave/enter notify
events when they appear.
2017-02-15 20:07:49 +01:00
nick_m
0938b6a9c1 add undo for changing marker lock style from menu 2017-01-27 03:39:33 +11:00
nick_m
d0580ecfbc allow all types of range location (loop, start, end etc.) to be glued to bars and beats. 2016-12-29 01:39:31 +11:00
nick_m
27b95300e2 add frame parameter for Meter ctor and TempoMap::replace_meter(). allow for various failures. 2016-12-19 04:02:01 +11:00
nick_m
34e41a3ca6 rename MetricSection movable -> initial, but of course initial is !movable.. 2016-12-12 02:07:00 +11:00
nick_m
33e95a1577 rename Tempo _beats_per_minute to _note_types_per_minute, provide pulse helpers.
- adds quarter_notes_per_minute(), note_divisions_per_minute (double)
	  pulses_per_minute() and frames_per_quarter_note()

	- this should be a no-op except for the use of tempo by
	  the vst callback which definitely uses quarter notes per minute.

	- the XML node for TempoSection named 'beats-per-minute'
	  has been renamed.
2016-11-11 03:37:08 +11:00
nick_m
0e867b544b Refactor tempo api, include quarter-note distance in frames method.
- moves frame rounding up to TempoMap, which is needed
	  in order to calculate pulse distance without frame rounding.

	- the time unit for tempo is still minute, but this now also
	  applies to meter sections. (new audio locked meter sections no
	  longer require a frame position).

	- there is no longer a discontinuity
	  in the pulse for audio-locked meter/tempi.

	- temporarily add debugging output in Region::set_position()
	  to test for region beat not matching region frame.
2016-11-11 03:37:08 +11:00
cf52d6e4b4 enough with umpteen "i18n.h" files. Consolidate on pbd/i18n.h 2016-07-14 14:45:23 -04:00
nick_m
0bdbe56cf1 Stop passing references to things that may disappear when a metric section is replaced. 2016-07-10 02:18:37 +10:00
nick_m
074db3b861 Tempo ramps - more code consolidation wrt add meter/tempo. 2016-05-27 23:38:16 +10:00
nick_m
82d876b48b Tempo ramps - clean up add/replace tempo 2016-05-27 23:38:16 +10:00
nick_m
2d3d7a5355 Tempo ramps - fix ambiguous api, fix flickering tempo curves. 2016-05-27 23:38:16 +10:00
nick_m
37ed0f6e9b Tempo ramps - restore correct drag behaviour wrt audio-locked meters and right-click of associalted tempo 2016-05-27 23:38:15 +10:00
nick_m
e0607ca913 Tempo ramps - add gui dilation of tempos.
- a meter can be dragged using the constraint modifier, which
	  sets the previous tempo accordingly.
	  This could be added to the bbt ruler to allow direct dragging
	  of beats and bars, but the exact behavior of that is still
	  undecided. comments?

	- also preliminary work on the necessary tempos locked to
	  audio-locked meters.
2016-05-27 23:38:15 +10:00
nick_m
4f8fa6787a Tempo ramps - add undo to right-click lock style & ramp type changes. 2016-05-27 23:38:15 +10:00
nick_m
eb70cdce1f Tempo ramps - don't set incorrect lock style when changing tempo type.
- fixes random crashes when changing tempo type with right click.
2016-05-27 23:38:15 +10:00
nick_m
b6afce7173 Tempo ramps - ok so you really do need to redisplay when tempo lock style is changed.. 2016-05-27 23:38:15 +10:00
nick_m
f0955aeb57 Tempo ramps - redraw correctly when changing meter lock style. 2016-05-27 23:38:15 +10:00
nick_m
c6a66f1014 Tempo ramps - redraw after setting tempo type (ramped, constant) from context menu.
- not needed for lock style change.
2016-05-27 23:38:15 +10:00
nick_m
85c3284adc Tempo ramps - add some right-click options to meter and tempo markers. 2016-05-27 23:38:15 +10:00
nick_m
cb43d485fa Tempo ramps - another approach to first meter/tempo.
- first tempo is glued to first meter position as they are now
	  both locked to AudioTime.
	- all existing audio-locked tempos to the left of the first meter
	  are made inactive. all to the right are made active.
2016-05-27 23:38:12 +10:00
6991a07902 remove all trace of SAE from source code.
This had become incoherent over time, and posed a development hazard and burden going forward
2016-02-22 15:31:24 -05:00
22b07e0233 NOOP, remove trailing tabs/whitespace. 2015-10-05 16:17:49 +02:00
621fd845e6 Revert "add new action and loop marker menu item for setting up loop record"
This reverts commit ebb43508f1.
2015-09-28 17:44:04 -04:00
ebb43508f1 add new action and loop marker menu item for setting up loop record 2015-09-28 17:42:11 -04:00
c3a7730c88 redisplay markers after removal - fixes #6596 2015-09-24 00:27:32 +02:00
e1f168de11 rename Marker class
Classes are in the global namespace.
OSX has a flat namespace and OSX32bit/Carbon has a Marker too.
2015-07-23 17:58:40 +02:00
91fac4c96d merge fix for tempo branch 2015-04-21 08:35:20 -05:00
ffd32ae5e1 Right-clicking on the Loop/Punch ruler should "Do Something". 2015-03-13 16:25:59 -05:00
1973243a98 Separate out creation of xrun markers from Editor::mouse_add_new_marker()
Remove the is_xrun parameter from Editor::mouse_add_new_marker(), and just
create the marker directly in ARDOUR_UI::create_xrun_marker(), so that xrun
markers don't become automatically selected when they appear.
2015-02-12 18:06:16 +00:00
nick_m
9af9e17adc Add editor selection state to session history via a SelectionMemento, which
combines selection related editor properties with the current editor selection.

The related editor properties are:
mouse mode,
zoom setting,
left frame of the canvas,
y origin of the canvas.

Selection state now includes region views (storing the underlying region id)
and time.

This patch also fixes a region mute undo bug.
2014-12-18 11:03:10 -05:00
6b3a8915f3 add abort() to non-reached code
This cleans up a lot of false-positives in static analysis
and also helps compilers to optimize code paths in general.
(tagging the fatal stingstream operator as ‘noreturn’ is
far less trivial)
2014-11-14 11:30:08 +01:00
f900711136 port changes to ARDOUR::Location and ARDOUR::Locations APIs from Tracks to Ardour.
Fixes deadlocks caused by mutex on Locations list, and clarifies the purposes and uses of the class-level and
object-level change-related signals.
2014-10-24 12:18:46 -04:00
6a971e645d use new ARDOUR::Location signals in GUI
Conflicts:
	gtk2_ardour/editor_markers.cc
2014-09-19 23:06:26 -04:00
4130513689 remove old connections to (now) static Location signals 2014-09-17 09:39:05 -04:00
8b98125ad3 fix various loop-initiation faults 2014-09-15 12:44:45 -05:00
6a5d805b38 more canvas refactoring.
Remove Canvas::Layout, use Canvas::Container for the same purpose, move child-rendering into Item::render_children() so that it
could theoretically be used by any derived type.
2014-06-22 11:41:05 -04:00