Comment more cases of bad sampleCount truncation, and even worse...
Fix progress indicator again: must do a floating-point division...
A little more type agnosticism
Remove more unnecessary casts to sampleCount
Fix more narrowings of sampleCount
Caused by optimisation of NumericTextCtrl::ValueToControls(). It now only updates on a change, and because mValueStr was being updated without calling value to controls, the string was not being identified as having changed.
* sampleCount:
Remove unnecessary casts to sampleCount
Type agnosticism for some other variables that were not sampleCount...
Remove many mentions of sampleCount with auto and decltype...
Use sf_count_t not sampleCount
some uses of size_t
Use long long for argument passed to wxString::ToLongLong
More cautions in SBSMSEffect.cpp...
... This makes much code agnostic about how other things (functions and
arguments) are typed.
Many of these neeed to become size_t instead of sampleCount.
These changes fix a broken build in Windows.
#include <algorithm> needed for min/max to be in std.
decltype(+name) was declaring a const variable, that could not be incremented. Changed to auto.
Uniform init in blockfile ctors (prevents implicit narrowings)
spaces
change a variable name
Don't use conversion of sampleCount to bool
Add explicit cast to sampleCount where negative values are possible
use std::min and std::max
an assertion
LadspaEffect::mSampleRate has type double, like other plug-in effects
I added a new flag, HasWaveDataFlag that checks not only for the presence of a WaveTrack but also for audio actually in it. This is now applied to the Scrub and Seek menu items, with the result that they grey out in the menu, and their buttons are dulled on the toolbar, if there is no audio.
This also makes it clearer in the code when we are dealing with a Toolbar ID (for the scrubbing toolbar) and when we are dealing with a button ID (for enabling/disabling the scrub ruler).
... I believe this list of four places is exhaustive.
There are many, many more safe narrowings that I examined.
This resulted from changing the definition of sampleCount in my builds so that
narrowing conversions failed to compile without some fixes, and I examined and
fixed every place.
The rest of that work is not yet shared.