There's no need to ever link a model to itself, allowing it can cause weird issues and crashes, plus it's easy to do by accident if you start a ctrl-drag and end it while still on the same widget
These methods are used to fetch the automated value of a model at a given MidiTime
These are still untested but that shouldn't be a problem since they aren't actually used by anything yet... but I'll be doing some testing and bugfixing (if needed) for them later.
These will be an important step in making sampletracks eventually be reliably playable from any position, and more generically, being able to reliably convert MidiTime to real time. Of course they can be useful for other things too (not sure what though, yet).
When using value from linked model, make sure to fit it into own range
as otherwise this can cause out-of-boundary accesses e.g. in ComboBoxModel.
Closes#505.
For some reason roundf() causes an exception on Win32 when calling with
negative values. This caused LMMS to crash when turning an external MIDI
pitch wheel downwards.
Closes#281.
When loading older projects where a particular model did not exist and
thus did not save any data do not load the possibly invalid default data
but reset to default value of model.
Recording single changes of objects or their specific properties is
completely superfluous as we have full implemented state tracking in all
objects already. Therefore use SerializingObject::saveState() and
SerializingObject::restoreState() in order to implement the undo/redo
functionality.
This is just an initial commit and needs some further work (especially
regarding stability). However even things like undo/redo of
addition/removal of Tracks and TrackContentObjects do work already.
The problem comes from AutomatableModel::m_initValue wich is not fitted
either in constructor or in setter. Idem for m_value in constructor, imo
this is not enough consistent.
I propose to:
- call fittedValue() in init value setter.
- always call setter to initialize current & init values.
Fixed some spelling errors found by Lintian while checking the Debian
package of LMMS. Thanks to Patrick Winnertz for pointing out this issue.
(cherry picked from commit 9fd3dacb67)
Most files and most of the core classes and their methods have been
renamed to match new coding style conventions:
391 files changed, 25400 insertions(+), 25598 deletions(-)
Furthermore splitted some files where model and view classes were
declared or implemented together in the same file.
Should be tested thoroughly as I might have missed renaming some virtual
methods or SIGNAL/SLOT parameters.
(cherry picked from commit 8c9a9dd14c)