RhythmGame 1.4.3
Loading...
Searching...
No Matches
Signals | Public Member Functions | Properties | List of all members
qml_components::ProfileList Class Referencefinal

The list of local profiles. More...

#include <ProfileList.h>

Inheritance diagram for qml_components::ProfileList:
Inheritance graph
[legend]
Collaboration diagram for qml_components::ProfileList:
Collaboration graph
[legend]

Signals

void mainProfileChanged ()
 
void profilesChanged ()
 
void battleActiveChanged ()
 
void battleAllowedChanged ()
 

Public Member Functions

 ProfileList (std::filesystem::path mainDbPath, db::SqliteCppDb *songDb, const QMap< QString, ThemeFamily > &themeFamilies, std::filesystem::path profilesFolder, QList< QString > assetsPaths, QNetworkAccessManager *networkAccessManager, resource_managers::SongAssetStore *songAssetStore, QObject *parent=nullptr)
 
auto getProfiles () -> const QList< resource_managers::Profile * > &
 
Q_INVOKABLE resource_managers::Profile * at (int index) const
 
Q_INVOKABLE resource_managers::Profile * createProfile ()
 
Q_INVOKABLE void removeProfile (resource_managers::Profile *profile)
 Remove the selected profile, completely deleting it.
 
void setMainProfile (resource_managers::Profile *profile)
 
auto getMainProfile () const -> resource_managers::Profile *
 
auto getBattleProfiles () -> BattleProfiles *
 
auto getBattleActive () const -> bool
 
void setBattleActive (bool active)
 
auto getBattleAllowed () const -> bool
 
void setBattleAllowed (bool allowed)
 

Properties

resource_managers::Profile * mainProfile {}
 The profile that is used to select themes and theme settings. Never null.
 
qml_components::BattleProfiles *battleProfiles READ getBattleProfiles
 The profiles used in battle mode.
 
QList< resource_managers::Profile * > profiles
 The list of all available profiles.
 
bool battleActive {}
 Launch SP charts in battle mode with two profiles.
 
bool battleAllowed { true }
 

Detailed Description

The list of local profiles.

Besides listing all local profiles, this class also contains the list of active profiles (for battle mode) and the main profile, used to select themes and theme settings.

Constructor & Destructor Documentation

◆ ProfileList()

qml_components::ProfileList::ProfileList ( std::filesystem::path  mainDbPath,
db::SqliteCppDb *  songDb,
const QMap< QString, ThemeFamily > &  themeFamilies,
std::filesystem::path  profilesFolder,
QList< QString >  assetsPaths,
QNetworkAccessManager *  networkAccessManager,
resource_managers::SongAssetStore *  songAssetStore,
QObject *  parent = nullptr 
)
explicit

Member Function Documentation

◆ at()

auto qml_components::ProfileList::at ( int  index) const

◆ battleActiveChanged

void qml_components::ProfileList::battleActiveChanged ( )
signal

◆ battleAllowedChanged

void qml_components::ProfileList::battleAllowedChanged ( )
signal

◆ createProfile()

auto qml_components::ProfileList::createProfile ( )

◆ getBattleActive()

auto qml_components::ProfileList::getBattleActive ( ) const -> bool

◆ getBattleAllowed()

auto qml_components::ProfileList::getBattleAllowed ( ) const -> bool

◆ getBattleProfiles()

auto qml_components::ProfileList::getBattleProfiles ( ) -> BattleProfiles *

◆ getMainProfile()

auto qml_components::ProfileList::getMainProfile ( ) const -> resource_managers::Profile*

◆ getProfiles()

auto qml_components::ProfileList::getProfiles ( ) -> const QList<resource_managers::Profile*>&

◆ mainProfileChanged

void qml_components::ProfileList::mainProfileChanged ( )
signal

◆ profilesChanged

void qml_components::ProfileList::profilesChanged ( )
signal

◆ removeProfile()

void qml_components::ProfileList::removeProfile ( resource_managers::Profile *  profile)

Remove the selected profile, completely deleting it.

Warning
Be careful.

◆ setBattleActive()

void qml_components::ProfileList::setBattleActive ( bool  active)

◆ setBattleAllowed()

void qml_components::ProfileList::setBattleAllowed ( bool  allowed)

◆ setMainProfile()

void qml_components::ProfileList::setMainProfile ( resource_managers::Profile *  profile)

Property Documentation

◆ battleActive

bool qml_components::ProfileList::battleActive {}
readwrite

Launch SP charts in battle mode with two profiles.

Both battleProfiles.player1Profile and battleProfiles.player2Profile must be set before enabling battle.

◆ battleAllowed

bool qml_components::ProfileList::battleAllowed { true }
read

◆ getBattleProfiles

auto qml_components::ProfileList::getBattleProfiles

The profiles used in battle mode.

See also
battleActive

◆ mainProfile

resource_managers::Profile * qml_components::ProfileList::mainProfile {}
read

The profile that is used to select themes and theme settings. Never null.

It also specifies the shared settings in battle mode. The main profile does not need to be assigned to P1 or P2.

◆ profiles

QList< resource_managers::Profile * > qml_components::ProfileList::profiles
read

The list of all available profiles.


The documentation for this class was generated from the following files: