![]() |
Miam-Player
0.8.0
A nice music player
|
SettingsPrivate class contains all relevant pairs of (keys, values) used by Miam-Player. More...
#include <settingsprivate.h>
Public Types | |
enum | DragDropAction { DD_OpenPopup = 0, DD_AddToLibrary = 1, DD_AddToPlaylist = 2 } |
enum | FontFamily { FF_Playlist = 0, FF_Library = 1, FF_Menu = 2 } |
enum | InsertPolicy { IP_Artists = 0, IP_Albums = 1, IP_ArtistsAlbums = 2, IP_Years = 3 } |
enum | LibrarySearchMode { LSM_Filter = 0, LSM_HighlightOnly = 1 } |
enum | PlaylistDefaultAction { PDA_AskUserForAction = 0, PDA_SaveOnClose = 1, PDA_DiscardOnClose = 2 } |
Signals | |
void | customIconForMediaButtonChanged (const QString &button) |
void | languageAboutToChange (const QString &newLanguage) |
void | fontHasChanged (FontFamily, const QFont &font) |
void | librarySearchModeHasChanged () |
void | monitorFileSystemChanged (bool) |
void | musicLocationsHaveChanged (const QStringList &oldLocations, const QStringList &newLocations) |
void | remoteControlChanged (bool enabled, uint port) |
Public Member Functions | |
void | addPlugin (const PluginInfo &plugin) |
void | disablePlugin (const QString &absFilePath) |
bool | colorsAlternateBG () const |
bool | copyTracksFromPlaylist () const |
const QString | customIcon (const QString &buttonName) const |
QPalette | customPalette () const |
QString | defaultLocationFileExplorer () const |
DragDropAction | dragDropAction () const |
QFont | font (const FontFamily fontFamily) |
int | fontSize (const FontFamily fontFamily) |
bool | hasCustomIcon (const QString &buttonName) const |
InsertPolicy | insertPolicy () const |
bool | isCustomColors () const |
bool | isCustomTextColorOverriden () const |
bool | isExtendedSearchVisible () const |
bool | isFileSystemMonitored () const |
bool | isLibraryFilteredByArticles () const |
bool | isPlaylistResizeColumns () const |
bool | isRectTabs () const |
bool | isRemoteControlEnabled () const |
bool | isReorderArtistsArticle () const |
bool | isButtonThemeCustomized () const |
QString | language () |
QByteArray | lastActivePlaylistGeometry () const |
QByteArray | lastActiveViewGeometry (const QString &menuAction) const |
QList< uint > | lastPlaylistSession () const |
QStringList | libraryFilteredByArticles () const |
LibrarySearchMode | librarySearchMode () const |
QStringList | musicLocations () const |
int | tabsOverlappingLength () const |
qint64 | playbackSeekTime () const |
PlayBack options. More... | |
PlaylistDefaultAction | playbackDefaultActionForClose () const |
bool | playbackKeepPlaylists () const |
bool | playbackRestorePlaylistsAtStartup () const |
QMap< QString, PluginInfo > | plugins () const |
uint | remoteControlPort () const |
void | setCustomColorRole (QPalette::ColorRole cr, const QColor &color) |
void | setCustomIcon (const QString &buttonName, const QString &iconPath) |
bool | setLanguage (const QString &lang) |
void | setLastActiveViewGeometry (const QString &menuAction, const QByteArray &viewGeometry) |
void | setLastPlaylistSession (const QList< uint > &ids) |
void | setMusicLocations (const QStringList &locations) |
void | setRemoteControlEnabled (bool b) |
void | setShortcut (const QString &objectName, const QKeySequence &keySequence) |
QKeySequence | shortcut (const QString &objectName) const |
int | volumeBarHideAfter () const |
void | setDefaultLocationFileExplorer (const QString &location) |
void | setInsertPolicy (InsertPolicy ip) |
Static Public Member Functions | |
static SettingsPrivate * | instance () |
Public Attributes | |
QTranslator | playerTranslator |
QTranslator | defaultQtTranslator |
SettingsPrivate class contains all relevant pairs of (keys, values) used by Miam-Player.
This class implements the Singleton pattern. Instead of using standard "this->value(QString)", lots of methods are built on-top of it. It keeps the code easy to read and some important enums are shared between plugins too.
|
slot |
SLOTS.
Add a list of folders to settings.
void SettingsPrivate::addPlugin | ( | const PluginInfo & | plugin | ) |
Add an activated plugin to the application.
bool SettingsPrivate::colorsAlternateBG | ( | ) | const |
Returns true if the background color in playlist is using alternatative colors.
bool SettingsPrivate::copyTracksFromPlaylist | ( | ) | const |
const QString SettingsPrivate::customIcon | ( | const QString & | buttonName | ) | const |
Custom icons in Customize(Theme)
|
signal |
QPalette SettingsPrivate::customPalette | ( | ) | const |
QString SettingsPrivate::defaultLocationFileExplorer | ( | ) | const |
void SettingsPrivate::disablePlugin | ( | const QString & | absFilePath | ) |
Disable a previously registered plugin (so it still can be listed in options).
SettingsPrivate::DragDropAction SettingsPrivate::dragDropAction | ( | ) | const |
QFont SettingsPrivate::font | ( | const FontFamily | fontFamily | ) |
Returns the font of the application.
|
signal |
int SettingsPrivate::fontSize | ( | const FontFamily | fontFamily | ) |
Sets the font of the application.
bool SettingsPrivate::hasCustomIcon | ( | const QString & | buttonName | ) | const |
Custom icons in CustomizeTheme
SettingsPrivate::InsertPolicy SettingsPrivate::insertPolicy | ( | ) | const |
|
static |
Singleton Pattern to easily use Settings everywhere in the app.
Singleton pattern to be able to easily use SettingsPrivate everywhere in the app.
bool SettingsPrivate::isButtonThemeCustomized | ( | ) | const |
Returns true if a user has modified one of defaults theme.
bool SettingsPrivate::isCustomColors | ( | ) | const |
bool SettingsPrivate::isCustomTextColorOverriden | ( | ) | const |
bool SettingsPrivate::isExtendedSearchVisible | ( | ) | const |
bool SettingsPrivate::isFileSystemMonitored | ( | ) | const |
Returns true if background process is active to keep library up-to-date.
bool SettingsPrivate::isLibraryFilteredByArticles | ( | ) | const |
Returns the hierarchical order of the library tree view.
bool SettingsPrivate::isPlaylistResizeColumns | ( | ) | const |
bool SettingsPrivate::isRectTabs | ( | ) | const |
Returns true if tabs should be displayed like rectangles.
bool SettingsPrivate::isRemoteControlEnabled | ( | ) | const |
bool SettingsPrivate::isReorderArtistsArticle | ( | ) | const |
Returns true if the article should be displayed after artist's name.
QString SettingsPrivate::language | ( | ) |
Returns the language of the application.
|
signal |
QByteArray SettingsPrivate::lastActivePlaylistGeometry | ( | ) | const |
Returns the last active playlist header state.
QByteArray SettingsPrivate::lastActiveViewGeometry | ( | const QString & | menuAction | ) | const |
QList< uint > SettingsPrivate::lastPlaylistSession | ( | ) | const |
Returns the last playlists that were opened when player was closed.
QStringList SettingsPrivate::libraryFilteredByArticles | ( | ) | const |
SettingsPrivate::LibrarySearchMode SettingsPrivate::librarySearchMode | ( | ) | const |
|
signal |
|
signal |
QStringList SettingsPrivate::musicLocations | ( | ) | const |
Returns all music locations.
|
signal |
Signal sent whether the music locations have changed or not.
SettingsPrivate::PlaylistDefaultAction SettingsPrivate::playbackDefaultActionForClose | ( | ) | const |
Default action to execute when one is closing a playlist.
bool SettingsPrivate::playbackKeepPlaylists | ( | ) | const |
Automatically save all playlists before exit.
bool SettingsPrivate::playbackRestorePlaylistsAtStartup | ( | ) | const |
Automatically restore all saved playlists at startup.
qint64 SettingsPrivate::playbackSeekTime | ( | ) | const |
PlayBack options.
QMap< QString, PluginInfo > SettingsPrivate::plugins | ( | ) | const |
|
signal |
uint SettingsPrivate::remoteControlPort | ( | ) | const |
|
slot |
|
slot |
Sets an alternate background color for playlists.
|
slot |
Copy or move tracks from one playlist to another.
void SettingsPrivate::setCustomColorRole | ( | QPalette::ColorRole | cr, |
const QColor & | color | ||
) |
XXX
|
slot |
Sets custom colors for the whole application.
void SettingsPrivate::setCustomIcon | ( | const QString & | buttonName, |
const QString & | iconPath | ||
) |
Custom icons in CustomizeTheme
|
slot |
Sets custom text color instead of classic black or white.
void SettingsPrivate::setDefaultLocationFileExplorer | ( | const QString & | location | ) |
|
slot |
Sets the default action when one is dropping tracks or folders.
|
slot |
Sets a popup when one is searching text in Library (Playlist mode only).
|
slot |
Sets the font of a part of the application.
|
slot |
Sets the font size of a part of the application.
void SettingsPrivate::setInsertPolicy | ( | SettingsPrivate::InsertPolicy | ip | ) |
Define the hierarchical order of the library tree view.
|
slot |
Sets user defined articles (like 'The', 'Le') to sort the Library.
bool SettingsPrivate::setLanguage | ( | const QString & | lang | ) |
Sets the language of the application.
|
slot |
Save the last active playlist header state.
void SettingsPrivate::setLastActiveViewGeometry | ( | const QString & | menuAction, |
const QByteArray & | viewGeometry | ||
) |
void SettingsPrivate::setLastPlaylistSession | ( | const QList< uint > & | ids | ) |
Sets the last playlists that were opened when player is about to close.
|
slot |
Sets user defined list of articles to sort the Library.
|
slot |
Sets if MiamPlayer should launch background process to keep library up-to-date.
void SettingsPrivate::setMusicLocations | ( | const QStringList & | locations | ) |
|
slot |
|
slot |
|
slot |
|
slot |
PlayBack options.
void SettingsPrivate::setRemoteControlEnabled | ( | bool | b | ) |
|
slot |
|
slot |
|
slot |
void SettingsPrivate::setShortcut | ( | const QString & | objectName, |
const QKeySequence & | keySequence | ||
) |
|
slot |
|
slot |
|
slot |
QKeySequence SettingsPrivate::shortcut | ( | const QString & | objectName | ) | const |
int SettingsPrivate::tabsOverlappingLength | ( | ) | const |
int SettingsPrivate::volumeBarHideAfter | ( | ) | const |
QTranslator SettingsPrivate::defaultQtTranslator |
QTranslator SettingsPrivate::playerTranslator |