Commit Graph

53 Commits

Author SHA1 Message Date
Paul Licameli
7ccd35d219 wxWidgets docs recommend: don't SetSizeHints on non-top-level windows 2019-11-28 14:24:43 -05:00
Paul Licameli
8c59f66583 ScrubbingToolBar eats less idle time after commit 192530d 2019-07-05 13:30:11 -04:00
Paul Licameli
e2362bc25a Move project status string management to new attached object class 2019-07-02 21:01:34 -04:00
Paul Licameli
02afcbca8c Redo TP_UpdateStatusMessage...
... Rename it as SetStatus; make it part of AudacityProject not
TrackPanelListener; and use a roundabout event signalling to cause the timer
restart.

Because SetStatus will be one of very few things left in AudacityProject, but
the timer handling will be part of another class decoupled from it.

And TrackPanelListener won't really be needed: TrackPanel will not need to
pretend it doesn't know what an AudacityProject is.
2019-05-28 19:36:47 -04:00
Paul Licameli
ed29ab89f8 Many WindowAccessible subclasses moved out of header files 2019-03-31 13:27:18 -04:00
Paul Licameli
a915a510bd include <wx/setup.h> in all files where wxUSE* macros are used...
... even if it's redundant; improving on what was done at b47e2f9
2019-03-23 14:56:02 -04:00
Paul Licameli
5e7d41ec07 Each .cpp/.mm file includes corresponding header before any other...
... except Audacity.h

This forces us to make each header contain all forward declarations or nested
headers that it requires, rather than depend on context.
2019-03-17 22:54:52 -04:00
Paul Licameli
2db49dc1f0 Use standard library style members of wxArrayString (and wxString) ...
... which will make it easier to change the types of those containers to
std::vectors of other string-like classes

for wxString,

IsEmpty => empty
Clear => clear
Alloc => reserve

for wxArrayString,

Count => size
GetCount => size
IsEmpty => empty
Add => push_back
Clear => clear
Empty => clear
Sort => std::sort (only with default comparator)
SetCount => resize
Last => back
Item => operator []
Alloc => reserve
2019-03-10 14:43:57 -04:00
David Bailes
f027708fe1 Fix an issue caused by the accessibility changes in wxWidgets 3.1.1
The main change in wx accessibility is this:
7dab555f71 (diff-04f5191d86f95b1c4d5d9c979da65878)

However wxWindowAccessible has not been updated to take into account of that change. In particular wxWindowAccessible::GetParent() was always wrong, but it was consistent with the rest of the framework. Now it's wrong and inconsistent. This function should return an object with role window, and which has the same name.

The fix is to introduce class WindowAccessible, which is effectively our own version of wxWindowAccessible. This class does not override GetParent(), and so just relies on a standard accessible object to to the right thing in wxIAccessible::get_accParent() (which is does). This class also allows us to have our own version of GetName(), which allows us to set the accessibility names of buttons.

These changes will break the accessibility of Audacity if it is built with wxWidgets 3.0.X. If this is a problem, then there could be some #if stuff in WindowAccessible.h to turn the WindowAccessible class into one which simply inherits from wxWindowAccessible, and doesn't override anything.
2018-04-03 14:57:59 +01:00
Paul Licameli
de568fc111 Avoid some needless repaints of AButton 2018-02-21 21:43:04 -05:00
Paul Licameli
7c73011629 Where if and else branches were the same, simplify...
... None of the examples was really a bug.

ExpandingToolBar.cpp is unused in fact.
2018-01-26 10:12:13 -05:00
James Crook
41ac4cd47a Add Hover-Over-Down State for Button
Previously hovering over a down button made no difference.
Also tweaked the appearance of hover-over thumbs on dark theme sliders.
Also tweaked hover images and colours generally.

Classic retains the old style.
Hi Contrast does not distinguish between hover-up and hover-down.
2017-12-14 14:39:56 +00:00
Paul Licameli
9aea0d3967 Do not redundantly track focus in AButton...
... I suspect it goes wrong on Mac sometimes, fault is in wxWidgets 3, not
sending all the kill focus events that it should.
2017-07-23 14:57:18 -04:00
Paul Licameli
d9c3a02542 Bug1623: Update play, record button images when modal dialog closes 2017-07-22 19:08:54 -04:00
James Crook
c12f849f36 Bug 1656 - (Windows) Disabled Edit Toolbar buttons not skipped for navigation and respond to ENTER as if auto-select was On
This fix addresses the second part.  ENTER (including from numpad) now has no effect if the button is disabled.
2017-07-04 22:34:43 +01:00
James Crook
6478895a39 Bug 1565 - Windows: Toolbars don't show tooltips when button is disabled 2017-05-14 14:58:50 +01:00
Paul Licameli
006aeda0a9 Use SafelyProcessEvent 2017-03-17 17:53:03 -04:00
Paul Licameli
5036583549 Fewer inclusions of AudacityApp.h 2017-03-17 17:52:24 -04:00
Paul Licameli
5d5edecca5 Remove unnecessary semicolons 2016-09-18 10:36:53 -04:00
Paul Licameli
d783762737 Remove unnecessary std::move in return statements...
... and comment where it is necessary.
2016-09-15 07:39:46 -04:00
Paul Licameli
15004b1ade More uses of std::make_unique 2016-08-08 10:07:37 -04:00
Paul Licameli
dab59cb79d Revert "Make tool bar pushbuttons cooperate with Voiceover on Mac..."
This reverts commit acde3d6152.
2016-07-01 17:35:50 -04:00
Paul Licameli
acde3d6152 Make tool bar pushbuttons cooperate with Voiceover on Mac...
... Use Command+f5 to start VoiceOver, then control+alt+ left and right arrows
to navigate.

Much better now, but still we need to do something about sliders, meters, and
numeric text controls.
2016-07-01 00:10:06 -04:00
Paul Licameli
57788c8d7a Fix Mac tabbing to sliders and meters, analogously to buttons...
... And make sure they don't steal focus when clicked or double clicked
2016-06-25 16:08:38 -04:00
Paul Licameli
d31e96aa57 Make tabbing between toolbar buttons work on Mac 2016-06-25 16:08:37 -04:00
Paul Licameli
fe509ed412 Fix drawing of focus rectangles in buttons, meters, sliders on Mac 2016-06-25 16:08:37 -04:00
Paul Licameli
48414d6e61 Bug1252 more: click buttons don't steal focus, ctrl+f6 still works 2016-06-23 16:38:15 -04:00
Paul Licameli
21ea9a5ead Bug1201: Be sure tool tips show for toolbar grabbers and resizers 2016-06-22 14:00:30 -04:00
Paul Licameli
9b21e11ff6 More rapid response from tooltips for pushbuttons, on Mac at least 2016-06-20 23:59:42 -04:00
Paul Licameli
16933363fe Update ruler button status messages if changed by keystroke and...
... pointer is in it
2016-06-12 00:00:04 -04:00
Paul Licameli
0ee65c0918 Remove superfluous code for changing transport button images 2016-06-01 12:00:56 -04:00
Paul Licameli
db137ddf76 wxWindow takes ownership of its wxAccessible, so we can use safenew. 2016-05-06 21:03:37 -04:00
Paul Licameli
039aaa13a0 Play buttons can detect double clicks (but don't do anything special yet) 2016-05-03 21:28:39 -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
d34715d6ad Various other drags could crash Mac debug build if you option-W. Fixed too...
... And I think this fix is now exhaustive.
2016-04-25 01:49:54 -04:00
Paul Licameli
7824e94030 Harmlessly qualify classes as final (or explicitly comment not)...
... Should have no effect on generated code, except perhaps some slight faster
virtual function calls.  Mostly useful as documentation of design intent.

Tried to mark every one of our classes that inherits from another, or is a
base for others, or has abstract virtual functions, and a few others besides.
2016-02-24 20:58:30 -05:00
Paul Licameli
daa7617e88 auto_ptr (deprecated) -> unique_ptr (preferred in C++11) 2016-02-13 12:00:28 -05:00
James Crook
39cc1fbc23 Bug 1204 - Crash when pressing both mouse buttons over toolbar buttons
Looks a very safe fix.  Post 2.1.2 should review ALL uses of CaptureMouse().
2015-09-21 23:11:55 +01:00
Leland Lucius
64e1136f06 Make sure they work on Windows too 2015-08-04 22:35:50 -05:00
Leland Lucius
7e49dc45d1 Fix some tabbing issues on Linux 2015-08-04 22:22:49 -05:00
lllucius
8bef14df36 Addresses meter accessibility mentioned in bug #33
And also corrects the missing focus rectangle display on
the toolbar buttons on Linux.
2015-01-04 09:24:26 +00:00
lllucius
3a098714d9 Persist looped button across toolbar resets...
...when started from the keyboard.
2015-01-03 11:27:24 +00:00
james.k.crook@gmail.com
7324997db6 Fix for http://bugzilla.audacityteam.org/show_bug.cgi?id=643 "Residual consistency issues with SHIFT showing Loop Play button icon" by Paul Licameli.
* Loop play-at-speed and cut preview play-at-speed implemented.
* Shift or ctrl down now affect all relevant buttons, loop or cut preview, normal or at speed, and append-record.
2014-11-29 17:22:05 +00:00
lllucius@gmail.com
126152a756 Converts the ladspa effects to the new format and adds realtime support
This also (hopefully) corrects some additional problems in general 
realtime support.  Particular focus should be given to the handling
of various combinations of stereo, left channel mono, right channel
mono, and true mono as this has been a particularly troublesome
area.
2014-11-05 07:06:38 +00:00
lllucius
1eeb4d979a The fabled realtime effects...
I've made it where you can enable and disable via experimentals:

EXPERIMENTAL_REALTIME_EFFECTS
EXPERIMENTAL_EFFECTS_RACK

You will notice that, as of now, the only effects currently set up for
realtime are VSTs.  Now that this is in, I will start converting the
rest.

As I start to convert the effects, the astute of you may notice that
they no longer directly access tracks or any "internal" Audacity
objects.  This isolates the effects from changes in Audacity and makes
it much easier to add new ones.

Anyway, all 3 platforms can now display VST effects in graphical mode.
Yes, that means Linux too.  There are quite a few VSTs for Linux if
you search for them.

The so-called "rack" definitely needs some discussion, work, and attention
from someone much better at graphics than me.  I'm not really sure it should
stay in as-is.  I'd originally planned for it to be simply a utility window
where you can store your (preconfigured) favorite effects.  It should probably
revert back to that idea.

You may notice that this DOES include the API work I did.  The realtime effects
were too tied to it and I didn't want to redo the whole thing.  As I mentioned
elsewhere, the API stuff may or may not be very future proof.

So, let the critter complaints commence.  I absolute KNOW there will be some.
(I know I'll be hearing from the Linux peeps pretty darn quickly.  ;-))
2014-10-26 03:24:10 +00:00
james.k.crook@gmail.com
fc7d961294 Highlight active AButtons when hover over, not just the toggle buttons. Fixes issue for small and large buttons. Paul L's patch. No impact on manual. Not tracked in Bugzilla. 2014-08-19 13:45:51 +00:00
benjamin.drung@gmail.com
277932dccb Remove trailing spaces. 2014-06-03 20:30:19 +00:00
martynshaw99
4f5de6d5e3 Quiet a bunch of 'unreferenced formal parameter' warnings on Windows.
The remaining ones are 'formal parameter's referenced by other platforms.
2013-09-25 22:57:54 +00:00
martynshaw99
4ce2643d5f Remove the
// Indentation settings for Vim and Emacs
etc. lines from all files, as Campbell's patch (except for other changes to Languages.cpp)
2013-09-24 00:14:37 +00:00
james.k.crook@gmail.com
dba81b3f1c Cleanup: Fixed lots of trivial MSVC warnings. 2013-08-25 21:51:26 +00:00