Types are used in connections, they must be registered with both Q_DECLARE_METATYPE
and qRegisterMetaType as stated in the documentation.
> To use the type T in QVariant, using Q_DECLARE_METATYPE() is sufficient.
> To use the type T in queued signal and slot connections,
> qRegisterMetaType<T>() must be called before the first connection
> is established.
this will allow to unload the interface module without unloading Qt in a
further patch.
the new structure is still a vlc object as we use it notably for logging
capacity and to interact with vlc variables
previously RoundImage was implemented in QML using Opacitymask which was
slow, new implementation done in cpp using QQuickPaintedItem is around ~5x faster
qmlRegisterSingletonType provides a convenient way
for the QML-side to invoke static methods of classes
that are not created or can not be created.
PlayerListModel singleton is generated from the
static function of
PlayerControlbarModel::getPlaylistIdentifierListModel.
Signed-off-by: Pierre Lamot <pierre@videolabs.io>
* PlayerControlbarModel class is repurposed
and renamed to "player_controlbar_model.cpp/hpp".
PlayerControlbarModel is now a supermodel that
instantiates and handles three ControlListModel
for its 'left', 'center', and 'right' properties.
ControlListModel is the stripped down version of
the old PlayerControlbarModel.
* ControlbarProfileModel is created during
MainInterface initialization. ControlbarProfileModel
creates and handles toolbar/controlbar profiles
that act as a wrapper of PlayerControlbarModel
instances. Saving and loading from settings
happens in ControlbarProfileModel.
* Default control layout is now defined in
ControlbarProfile class. ControlbarProfile
injects the default configuration
during construction.
* Default profiles are now defined in
ControlbarProfileModel class.
ControlbarProfileModel class automatically
matches defaults based on player identifiers.
Signed-off-by: Pierre Lamot <pierre@videolabs.io>