1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-07-01 07:33:44 +02:00

66 Commits

Author SHA1 Message Date
Paul Licameli
ef62bc4e2a Fix checkmarks and Start item in scrub handle context menu 2016-06-02 16:20:15 -04:00
Paul Licameli
bbb93a7400 One more alternate play button image, for seeking 2016-06-02 15:55:16 -04:00
Paul Licameli
6a3613e8e9 Implement scrub and seek buttons on ruler; redo scrub menu items 2016-06-02 15:55:16 -04:00
Paul Licameli
eafc416d55 Remove double-click and scrolling menu items for scrub/seek...
... Use the toggle button on the ruler instead
2016-06-01 13:30:01 -04:00
Paul Licameli
fecc6f53e4 Consolidate the code that starts and stops play/rec head scrolling 2016-06-01 13:25:01 -04:00
Paul Licameli
fbcdc6b28f Scrolling drag scrub tracks the mouse much better 2016-05-28 12:15:32 -04:00
Paul Licameli
35b0502ce1 Don't let seek make a stutter at less than unit speed 2016-05-28 12:11:26 -04:00
Paul Licameli
a9a404c7cf Further simplified argument passing 2016-05-28 12:02:16 -04:00
Paul Licameli
e4fadf4aaf Improve scrubbing speed control (2 finger swipe) on Mac 2016-05-28 11:59:22 -04:00
Paul Licameli
af7a92c2ab Improve scrub responsiveness: a secondary thread polls the mouse 2016-05-28 11:59:22 -04:00
Paul Licameli
b6764d1bf7 Reduce scrub lag yet more, at expense of possible skips in play...
by discarding work from the queue sometimes on the consumer side.

Also more careful mixed long - double arithmetic.
2016-05-28 11:59:14 -04:00
Paul Licameli
b14fa507c9 Reorganize logic of initializing queue entries 2016-05-28 08:44:25 -04:00
Paul Licameli
4f2ee32a1a One second countdown now based on the correct timer interval 2016-05-27 11:40:17 -04:00
Paul Licameli
24ef578a89 Don't squeak when starting a drag-scrub 2016-05-22 16:35:20 -04:00
Paul Licameli
c585bb16fb Move bounding times and minimum stutter length into ScrubOptions 2016-05-22 15:27:35 -04:00
Paul Licameli
ffe596c760 Move some fields into ScrubbingOptions 2016-05-22 15:27:35 -04:00
Paul Licameli
671f60492d Move some static functions into ScrubbingOptions 2016-05-22 15:27:35 -04:00
Paul Licameli
8ed93b8147 Fix conditional compilation branch 2016-05-22 15:27:35 -04:00
Paul Licameli
3dcf802bdc Have just one scrub enqueueing function: use options for distinctions 2016-05-22 15:27:35 -04:00
Paul Licameli
cdbdd6480b Define and pass around struct ScrubbingOptions, but nothing in it yet 2016-05-22 15:27:35 -04:00
Paul Licameli
5997beec9d Rename Scrubbber::mScrubHasFocues to mPaused, reverse its sense 2016-05-22 15:27:34 -04:00
Paul Licameli
9e2916a80b Better implementation of switch from scrub to quick play; ...
... also, don't ever draw the scrub handle while dragging the quick play
region.
2016-05-18 11:58:57 -04:00
Paul Licameli
47efa2dbbc fix gcc build 2016-05-17 12:38:30 -04:00
Paul Licameli
c66262d790 Double click on Record button pins record head right, not center 2016-05-17 12:25:39 -04:00
Paul Licameli
0602343a2d Make drag scrub less sluggish (do less redrawing) 2016-05-15 16:41:24 -04:00
Paul Licameli
3792d18f2d Correct "scrub delay" for whatever scrub timer, so that the lag is right 2016-05-14 19:57:06 -04:00
Paul Licameli
16d33c6005 Give the scrubber its own timer separate from TrackPanel's, so that...
... we can experiment with changing the interval.
2016-05-14 05:47:32 -04:00
Paul Licameli
1bff08a75a Make drag-scrub seek, rather than playing at more than unit speed 2016-05-12 01:22:07 -04:00
Paul Licameli
737e24e24e Allow pausing and unpausing of scrub. Just treat it differently internally. 2016-05-11 19:59:11 -04:00
Paul Licameli
928e96c6cc Fix assertion violations about double capture; while still making sure...
... that if you drag-scrub and ESC, you don't get a leftover white guide line.
2016-05-10 15:35:46 -04:00
Paul Licameli
19ef2f6681 Implement drag-scrub, compatibly with the existing move-scrub...
... Start scrub by click or double click on the scrub head; release button or
not; then move.

If you release before moving, you get scrubbing as before, controlled by
motion.  Click or drag to switch in and out of seeking.  Stop with ESC,
spacebar, etc.  No change of selection.

But now if you drag, then scrubbing contines until you release the mouse or
otherwise stop with a key.

If by release of the mouse, then the selection changes as if by a click at
the last play position.  If you hold shift, then, as if by shift-click.

If drag begins with a double-click, then the play head remains centered and
the track moves.
2016-05-10 09:37:10 -04:00
Paul Licameli
5944391e24 Let's commit to EXPERIMENTAL_SCRUBBING_SMOOTH_SCROLL 2016-05-09 23:21:56 -04:00
Paul Licameli
cc0190054c Fix regression in scroll scrub 2016-05-09 21:53:32 -04:00
Paul Licameli
34d0a52011 Better updating of the white guideline for scrub, and hiding it when scrub stops 2016-05-09 19:35:23 -04:00
Paul Licameli
7c2a531486 New base classes of TrackPanel just for the bitmap backing and overlay system...
... to make it reusable by other classes.

Also, don't create a second DC when repainting TrackPanel.
2016-05-09 11:37:32 -04:00
Paul Licameli
c5d42377b7 Scrub during play stops play, repositions play head 2016-05-06 12:38:41 -04:00
Paul Licameli
66454b7e4c Fix status bar messages and disabling of pause button for scrubbing. 2016-05-06 12:17:33 -04:00
Paul Licameli
0d9d8a057d Revert "Disable scrubbing when pause button is down."
This reverts commit 97fdce5f85e884cbe6f161963789694015cdf328.
2016-05-06 11:32:56 -04:00
Paul Licameli
97fdce5f85 Disable scrubbing when pause button is down. 2016-05-05 22:48:23 -04:00
Paul Licameli
f48694ef47 Move the code that scrolls during scrub out of Scrubbing.cpp 2016-05-03 22:43:19 -04:00
Paul Licameli
2704c85fd1 When starting a scrub, limit the x coordinate to track control area...
... This fixes a display bug if you use a shortcut key for the Scrub command
while the mouse is left or right of the wave area.  You should not get the
green line right at the pointer!
2016-05-02 10:10:40 -04:00
Paul Licameli
042d6801df Context menu for scrub head shows checkmarks, and is available during scrub 2016-04-27 20:56:38 -04:00
Paul Licameli
cc9b880852 Conditional compilation flag can disabled the checkmarks in scrub sub menu 2016-04-27 20:35:32 -04:00
Paul Licameli
6a1d387093 Fix assertions and crashes in context menu for scrubber 2016-04-26 15:37:55 -04:00
Paul Licameli
9ab0e42f29 Control scrub with motion, click, drag, wheel almost anywhere in main window...
... if the event is not handled and skipped by sub-windows first, such as for
toolbar button clicks.

(But track panel clicks are skipped even after doing something, so they may
also cause seeking besides other responses.  So click can seek AND set cursor.)

This is meant to make drag to seek and wheel for change of speed easier,
without needing to keep the mouse in the narrow time ruler.

Also lets you click in the ruler, then move in any direction, and not miss the
motion event that should start the scrub playback.

The event handling is a bit of a hack, using propagation.  It does not use
capture.
2016-04-26 12:12:06 -04:00
Paul Licameli
3d222bcd87 Context menu for scrubbing in the ruler 2016-04-26 12:12:06 -04:00
Paul Licameli
cd57e0a26c Scrubbing phase 2. Scrub starts with click on the indicator in the ruler...
... and works in any of the six tools.

Click and drag in select tool during scrub works just as when not scrubbing.

Seeks now only if you left-click or drag in the ruler, but this may change.

Mouse motion anywhere on the screen controls scrub as before.

No mouse clicks in TrackPanel are used by scrubbing.

The Ctrl-Click in TrackPanel is now unused.  Should 2.1.0 behavior be restored?
That was click to quick play, redundant with click in the (lower part of) the
ruler.
2016-04-26 12:12:06 -04:00
Paul Licameli
b0d2f38786 ESC leaves scrubbing even when clicked only; disable scrub menu items when...
... another project is playing
2016-04-26 09:02:38 -04:00
Paul Licameli
6d2528ae10 Update the status bar message as left button switches in an out of seeking. 2016-04-25 16:04:24 -04:00
Paul Licameli
a57ef7a560 When changing the scrub mode via menu command or shortcut, update status bar 2016-04-25 15:43:26 -04:00