There is a new tool button that can be used to turn the metronome on and
off. Per default the metronome is turned off. When enabled the metronome
will during on song playback, pattern playback and BB playback. During
export it is ignored.
A new icon was added as well.
The state is currently stored in the Mixer. It might make sense to put
the metronome configuration in its own class in the future. The state is
currently not stored in the file but this might be a good choice for now
until a better place is found for the metronome data.
Also removed some repeated calls to Engine::getSong() and
Engine::fxMixer().
A new option to save a project as the default template is now available
in the file menu. If the default template already exists the user is
asked whether he wants to overwrite it.
Removes the non-intuitive saving of the default template in
MainWindow::createNewProject.
Other fixed problems:
* User entries were not shown in the menu of the tool button that
creates new projects from templates. Now they are shown as well.
Other changes:
* Adds a new option "New from template" in the file menu. It shows the
same menu as the tool button.
Fixed the rendering of the tact numbers in the timeline widget. Before
this fix they were not readable because they were too big. Interestingly
in this case the fix is to use a font size in pixels (half the height of
the widget). The numbers are now also rendered a bit darker than the
lines.
Also removed the pixmap for the timeline from the code and from the
filesystem. It was only used to determine the fixed height of the widget
but not rendered. Therefore it was removed and the height is now
directly set to 18 pixels which was the height of the pixmap.
ControllerRackView now uses a layout to organize the ControllerViews.
The ControllerViews in turn use layouts to organize their widgets
(labels and push button). ControllerView now inherits from QFrame
instead of QWidget. The (static) background image for controllers was
deleted because the ControllerView can now be resized dynamically.
Song: Added specific signals for added and removed controllers. Also
removed a TODO by putting the functionality to remove all controllers in
a method (removeAllControllers).
Deleted Controllers now don't unregister from Song during deletion. This
has to be done by the client (Hollywood principle - "Don't call us, we
call you.").
TODO: For some strange reason I cannot programmatically resize the
controller rack to make it fit the controllers on my screen.
Removal of a superfluous include in AudioAlsaSetupWidget.cpp
Removal of the function "bool hasCapabilities(char *device_name)" which
was not used anyway. It implemented a test for ALSA device capabilities
needed by LMMS (SND_PCM_ACCESS_RW_INTERLEAVED, SND_PCM_FORMAT_S16_LE,
etc.).
Corrected header name in AudioAlsaSetupWidget.h.
Created an implementation file for AudioDeviceSetupWidget to make more
clear that it's part of the GUI.
Fix build for builds that use Port Audio. The setup widget of
AudioPortAudio.h still inherited from AudioDevice::setupWidget instead
of the new AudioDeviceSetupWidget.
This version lets the user select the ALSA device to use with a combo
box. It does not check whether the device works for the parameters that
LMMS uses (SND_PCM_ACCESS_RW_INTERLEAVED, SND_PCM_FORMAT_S16_LE, etc.).
Doing these checks while compiling the list of available devices led to
strange effects which are likely caused by the fact that the PCM device
has to be opened to query its capabilities. This in turn led to error
messages a la "Resource or device busy" when testing the new
functionality repeatedly.
However, having a combo box to select devices from should be a good step
forward compared to a simple line edit. :)
Moved AudioDevice::setupWidget into its own class AudioDeviceSetupWidget
which logically should belong to the GUI (unfortunately the include
structure does not make this obvious).
For the ALSA driver there is an implementation AudioAlsaSetupWidget
which provides a combo box for selection of the card and device.
All other driver widgets have been changed to inherit from
AudioAlsaSetupWidget but have not been changed otherwise.
SetupDialog has been adjusted to keep a map of AudioAlsaSetupWidgets
now.
Shows a combo box with the available ALSA cards and devices instead of a
line edit. The problem currently is that the widgets are nested classes
of AudioDevice and therefore the macro Q_OBJECT does not work which
means that its not possible to define slots that react to retrieved
signals.