Cockatrice
2026-10-19-Development-3.1.2-beta.2
A virtual tabletop for multiplayer card games
Toggle main menu visibility
Loading...
Searching...
No Matches
sound_settings.h
Go to the documentation of this file.
1
#ifndef SOUND_SETTINGS_H
2
#define SOUND_SETTINGS_H
3
4
#include "
settings_manager.h
"
5
6
#include <QString>
7
#include <
libcockatrice/interfaces/interface_sound_settings_provider.h
>
8
#include <qtmetamacros.h>
9
10
class
QObject;
11
12
class
SoundSettings
:
public
SettingsManager
,
public
ISoundSettingsProvider
13
{
14
Q_OBJECT
15
friend
class
SettingsCache
;
16
17
public
:
18
[[nodiscard]]
bool
getSoundEnabled
()
const override
;
19
[[nodiscard]] QString
getSoundThemeName
()
const override
;
20
[[nodiscard]]
int
getMasterVolume
()
const override
;
21
22
void
setSoundEnabled
(
bool
_soundEnabled);
23
void
setSoundThemeName
(
const
QString &_soundThemeName);
24
void
setMasterVolume
(
int
_masterVolume);
25
26
signals:
27
void
soundEnabledChanged
();
28
void
soundThemeChanged
();
29
void
masterVolumeChanged
(
int
value);
30
31
public
:
32
explicit
SoundSettings
(
const
QString &
settingPath
, QObject *parent =
nullptr
);
33
34
private
:
35
SoundSettings
(
const
SoundSettings
&
/*other*/
);
36
};
37
38
#endif
// SOUND_SETTINGS_H
ISoundSettingsProvider
Definition
interface_sound_settings_provider.h:7
SettingsManager::SettingsManager
SettingsManager(const QString &settingPath, const QString &defaultGroup=QString(), const QString &defaultSubGroup=QString(), QObject *parent=nullptr)
Definition
settings_manager.cpp:3
SettingsManager::settingPath
QString settingPath
Definition
settings_manager.h:36
SoundSettings::soundThemeChanged
void soundThemeChanged()
SoundSettings::setSoundEnabled
void setSoundEnabled(bool _soundEnabled)
Definition
sound_settings.cpp:29
SoundSettings::setMasterVolume
void setMasterVolume(int _masterVolume)
Definition
sound_settings.cpp:41
SoundSettings::setSoundThemeName
void setSoundThemeName(const QString &_soundThemeName)
Definition
sound_settings.cpp:35
SoundSettings::getSoundThemeName
QString getSoundThemeName() const override
Definition
sound_settings.cpp:19
SoundSettings::SoundSettings
SoundSettings(const SoundSettings &)
SoundSettings::SoundSettings
SoundSettings(const QString &settingPath, QObject *parent=nullptr)
Definition
sound_settings.cpp:9
SoundSettings::SettingsCache
friend class SettingsCache
Definition
sound_settings.h:15
SoundSettings::getMasterVolume
int getMasterVolume() const override
Definition
sound_settings.cpp:24
SoundSettings::masterVolumeChanged
void masterVolumeChanged(int value)
SoundSettings::getSoundEnabled
bool getSoundEnabled() const override
Definition
sound_settings.cpp:14
SoundSettings::soundEnabledChanged
void soundEnabledChanged()
interface_sound_settings_provider.h
settings_manager.h
libcockatrice_settings
libcockatrice
settings
sound_settings.h
Generated by
1.18.0