1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-05-06 14:52:34 +02:00

77 Commits

Author SHA1 Message Date
Paul Licameli
ce9f2e2538 Include Menus.h directly, only where needed, not via Project.h 2018-10-16 16:45:26 -04:00
Paul Licameli
9481587fa8 Move menu handling functions out of class AudacityProject 2018-09-29 12:10:27 -04:00
James Crook
72f9fade8d Bug 1749 - Timer record dialog: wxWidgets assert failure
The problem was that the end time was set to prohibit changes that brought it
before the start time.  However an update to start time could update the end time
before the end time updated its legal range.

The prohibition on going backwards in time is only for user interaction with
that control, so we now clear the legal range before update and then recreate it.

This change also fixes:
Bug 1978 - Windows: Timer Record - a "debugging check" dialog is shown to the user

In passing I also noticed that the controls were being updated every 50ms.
This is totally pointless as they only show the nearest second.  So I set the granularity
for control updates to 1s. (1000ms).
2018-09-17 15:31:55 +01:00
James Crook
de1e8d96de Fix TimerRecord ASSERT in debug builds.
Caused by misuse of sizers.
2018-04-22 18:08:52 +01:00
James Crook
fb490c24b8 Change wxMilliSleep from 10ms to 50ms
10ms is refreshing too often, and inconsistent with other places where it is 50ms.
2018-04-22 15:33:05 +01: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
0fb02a8024 IdentInterfaceSymbol in NumericTextCtrl; don't persist translated 2018-03-28 14:00:17 -04:00
James Crook
1c988b4e3a Automation: AudacityCommand
This is a squash of 50 commits.

This merges the capabilities of BatchCommands and Effects using a new
AudacityCommand class.  AudacityCommand provides one function to specify the
parameters, and then we leverage that one function in automation, whether by chains,
mod-script-pipe or (future) Nyquist.

- Now have AudacityCommand which is using the same mechanism as Effect
- Has configurable parameters
- Has data-entry GUI (built using shuttle GUI)
- Registers with PluginManager.
- Menu commands now provided in chains, and to python batch.
   - Tested with Zoom Toggle.

- ShuttleParams now can set, get, set defaults, validate and specify
the parameters.
- Bugfix: Don't overwrite values with defaults first time out.
- Add DefineParams function for all built-in effects.
- Extend CommandContext to carry output channels for results.

We abuse EffectsManager.  It handles both Effects and
AudacityCommands now.  In time an Effect should become a special case of
AudacityCommand and we'll split and rename the EffectManager class.

- Don't use 'default' as a parameter name.
- Massive renaming for CommandDefinitionInterface
- EffectIdentInterface becomes EffectDefinitionInterface
- EffectAutomationParameters becomes CommandAutomationParameters
- PluginType is now a bit field.

This way we can search for related types at the same time.

- Most old batch commands made into AudacityCommands.
The ones that weren't are for a reason.  They are used by mod-script-pipe
to carry commands and responses across from a non-GUI thread to the GUI
thread.

- Major tidy up of ScreenshotCommand
- Reworking of SelectCommand
- GetPreferenceCommand and SetPreferenceCommand
- GetTrackInfo and SetTrackInfo
- GetInfoCommand
- Help, Open, Save, Import and Export commands.
- Removed obsolete commands ExecMenu, GetProjectInfo and SetProjectInfo
  which are now better handled by other commands.

- JSONify "GetInfo: Commands" output, i.e. commas in the right places.

- General work on better Doxygen.
    - Lyrics -> LyricsPanel
    - Meter -> MeterPanel
- Updated Linux makefile.
- Scripting commands added into Extra menu.
- Distinct names for previously duplicated find-clipping parameters.
- Fixed longstanding error with erroneous status field number which
  previously caused an ASSERT in debug.
- Sensible formatting of numbers in Chains, 0.1 not 0.1000000000137
2018-02-24 14:20:22 -05:00
Paul Licameli
8625df6814 More NumericTextCtrl constructor options 2018-02-21 19:21:02 -05:00
Paul Licameli
5724780be9 NumericTextControl ctor arguments...
... follow wxWidgets conventions for first two arguments; add Options
2018-02-21 19:21:02 -05:00
Paul Licameli
1320879ab4 Reimplement multi-column format of TimerProgressDialog...
... Specify an array of arrays of strings.  Don't pack it all as a single
string that is parsed.  This makes the setup clearer.

It also avoids some concatenations of localized strings (which I want to
make uncompilable some day), and also removes the need for translators to
count the \n's and replicate precisely.
2018-01-05 16:20:33 -05:00
Paul Licameli
ab6de1181d No more functor objects; all command handler functions take same args 2018-01-05 09:27:29 -05:00
Paul Licameli
e0970ad1e8 Remove unnecesary Format, Printf, casts to wxString 2018-01-01 21:53:51 -05:00
Paul Licameli
7fd78183d2 Remove needless uses of wxString::c_str() in wxString::Format...
... and similar wx "variadics," which all treat wxString smartly enough that
you don't need this.

Don't need c_str either to convert wxString to const wxChar * because
wxString has a conversion operator that does the same.
2018-01-01 20:34:33 -05:00
Paul Licameli
e8b875ff81 Define AudacityMessageDialog wrapper around wxMessageDialog...
... Prohibiting use of the default caption which is unlocalized.  (But we
didn't use it in fact anywhere.)
2018-01-01 17:50:03 -05:00
Paul Licameli
ccb4bbac33 Translate "Message" as default title of message box...
... This required a sweeping change of all calls to wxMessageBox!  But it seems
safe to me, despite the great number of touched files.
2018-01-01 17:50:02 -05:00
Paul Licameli
70b5076b0b Fix some untranslated prompts and messages...
... Even if some commented out.  Such don't enlarge the .pot file, but make
them right in case they are ever un-commented.
2017-09-10 19:24:41 -04:00
James Crook
ce9938787c Use alpha or released or local manual for "help on selection".
Previously this was hard coded to use the online alphamanual.
Some other help-on-errors paths were hardcoded to use the online manual, and did not use local help even if available, so these were changed too.

Also two naming changes in the code:
ShowHelpDialog() became ShowHelp() because it typically shows the help in your browser, only showing the help in a dialog under certain circumstances.
The helpURL parameter became helpPage since it is usually a page name that is then elaborated into a url.
The Link() function became InnerLink().

Some careful http -> https changes made too.
2017-08-25 13:59:16 +01:00
Paul Licameli
5d48e96942 Where FileSelector was used, default to Documents not cwd; save prefs 2017-08-03 08:02:33 -04:00
Paul Licameli
d7ac0d30db Fix some missed internationalizations 2017-08-03 07:04:42 -04:00
Paul Licameli
1a90b7d942 TimerRecordDialog: comment why nothing need be done for exceptions 2017-03-21 14:11:20 -04:00
James Crook
47fb879157 Don't translate the empty string. 2017-03-18 18:04:56 +00:00
Paul Licameli
aa0d55ac83 Use enum class ProgressResult, don't interconvert with int or bool 2017-03-17 17:52:24 -04:00
Paul Licameli
5036583549 Fewer inclusions of AudacityApp.h 2017-03-17 17:52:24 -04:00
Mark Young
a4ae301a5b Bug 1402, rewrite logic for the display of hours and minutes and ensure we use one routine for this. 2016-10-02 22:56:04 +01:00
Gale Andrews
17afc51644 Typo in code comment 2016-09-18 18:56:34 +01:00
Steve Daulton
341e3e1207 Fix bug 1513
The error message is still a bit strange if trying to overwrite
a different project when the current project has been saved,
(why would you do that?), but probably not worth complicating
the message for such a fringe case.
2016-09-17 15:52:52 +01:00
tip2tail
56b1f2d2cb Bug 1403 - Message can now be displayed in multiple columns
Uses 'End-of-Transmission-Block' character to mark the column split(s)
and is defined as a static constant for ease of use.
2016-09-12 19:30:10 +01:00
Paul Licameli
32f24eabb2 Review uses of safenew...
... add comments and assertions, and use make_unique instead where possible
2016-08-13 23:16:05 -04:00
Paul Licameli
13e056de43 More uses of safenew 2016-08-08 10:07:37 -04:00
Paul Licameli
a52f7f8410 new -> NEW in comments, so text search for naked new excludes them 2016-08-08 10:07:37 -04:00
Gale Andrews
cf2625a7bd Merge pull request #146 from tip2tail/AudacityCapitalLetter
Tip2tail fix capitalisation of "Audacity"
2016-07-18 13:33:58 +01:00
Mark Young
bea6553ee4 Fixed capitalisation of "Audacity" in TimerRecord 2016-07-17 21:34:08 +01:00
Paul Licameli
84c0337aba Fix TAB key navigation on Mac for all dialogs (not only for panels) 2016-07-10 17:12:27 -04:00
Paul Licameli
839bb0a6db Help dialogs are modal only when necessary 2016-06-21 11:54:21 -04:00
Paul Licameli
186873e3cc Revert "Bug, unreported: Timer record "?" button brought up a frozen dialog..."
This reverts commit 5c044c0cea75f03bea493da4c479c2dc7d4a7705.
2016-06-20 13:00:58 -04:00
Paul Licameli
5c044c0cea Bug, unreported: Timer record "?" button brought up a frozen dialog...
... on Mac at least.
2016-06-19 19:32:40 -04:00
Gale Andrews
94249f1ea2 Captialization fixes.
Also renamed "Post Timer Recording Action" to "Action after Timer Recording" for
greater clarity.
2016-06-13 15:51:13 +01:00
Gale Andrews
9e74613a8e Disc > Disk (Bug 1400)
Also capitalize "Timer Recording" in the message because it is a unique Audacity entity.
2016-06-11 17:12:33 +01:00
Paul Licameli
db137ddf76 wxWindow takes ownership of its wxAccessible, so we can use safenew. 2016-05-06 21:03:37 -04:00
tip2tail
c95e7e8876 fixed capitalisation of strings 2016-04-09 14:23:30 +01:00
tip2tail
4ec3ef8fb4 Ensure help button works in same way as others in Audacity
Fixed messages in dialogs so times/duration shown in same order
2016-04-09 14:23:29 +01:00
tip2tail
b71da143b6 Add Help button to Timer Recording dialog that will link direct to the manual page on the Internet
Fixed spelling issues
2016-04-09 14:23:29 +01:00
tip2tail
6686d0e314 Introduce further enhancement of the Timer Recording process:
* Disk space warning if the recording potentially will not fit in disk space available.
* ProgressDialog enhancements that allow the Stop/Cancel button to be confirmed and the elapsed time to be hidden.
* Messages enhanced to clearly show the actions being taken.
2016-04-09 14:23:28 +01:00
David Bailes
d0d1a7fcb5 Improve accessibility of wxDatePickerCtrl in Timer Record
Currently the NVDA screen reader does not read the date pickers when the user
tabs to them. This bug has be logged in the nvda bug tracker: #3706.
This fixes the bug, though NVDA still doesn't provide any feedback when
the user moves between the fields of the date using left/right arrow keys.
2016-04-02 14:54:32 +01:00
Steve Daulton
127105618f Fix bug 1367 2016-04-01 15:17:39 +01:00
James Crook
b764c465d0 Reduced some repetitive code. Added credit for Mark Young.
Also added i18n-hint on translation and a couple of TODOs for further improvement.
2016-04-01 11:13:32 +01:00
tip2tail
758eae6b3a Resolved whitespace issue on long string message dialog text as per the development guidelines in wiki. 2016-03-31 10:30:33 +01:00
tip2tail
aa5ffe99a7 Timer Recording Enhancements to allow Automatic Save and Export after
recording.  Also allows for additional options to be carried out after a
successful timer recording such as Exit, Retsrat and Shutdown.
2016-03-30 20:42:59 +01:00
Paul Licameli
df6a7c5464 More uses of safenew for classes we derive from wxWindow classes...
... Also removed some unnecessary deletes of widgets that are managed by parent
windows
2016-02-14 20:39:28 -05:00