[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdelibs/phonon
From: Matthias Kretz <kretz () kde ! org>
Date: 2008-01-31 22:33:36
Message-ID: 1201818816.210750.29119.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 769238 by mkretz:
allow to override the hide advanced devices setting
M +4 -2 globalconfig.cpp
M +6 -1 globalconfig.h
--- trunk/KDE/kdelibs/phonon/globalconfig.cpp #769237:769238
@@ -53,12 +53,14 @@
}
}
-QList<int> GlobalConfig::audioOutputDeviceListFor(Phonon::Category category) const
+QList<int> GlobalConfig::audioOutputDeviceListFor(Phonon::Category category, \
HideAdvancedDevicesOverride override) const {
//The devices need to be stored independently for every backend
const QSettingsGroup backendConfig(&m_config, \
QLatin1String("AudioOutputDevice")); // + Factory::identifier());
const QSettingsGroup generalGroup(&m_config, QLatin1String("General"));
- const bool hideAdvancedDevices = \
generalGroup.value(QLatin1String("HideAdvancedDevices"), true); + const bool \
hideAdvancedDevices = (override == FromSettings + ? \
generalGroup.value(QLatin1String("HideAdvancedDevices"), true) + : \
static_cast<bool>(override));
//First we lookup the available devices directly from the backend
BackendInterface *backendIface = qobject_cast<BackendInterface \
*>(Factory::backend());
--- trunk/KDE/kdelibs/phonon/globalconfig.h #769237:769238
@@ -37,7 +37,12 @@
GlobalConfig(QObject *parent = 0);
~GlobalConfig();
- QList<int> audioOutputDeviceListFor(Phonon::Category category) const;
+ enum HideAdvancedDevicesOverride {
+ ShowAdvancedDevices = 0,
+ HideAdvancedDevices = 1,
+ FromSettings = 2
+ };
+ QList<int> audioOutputDeviceListFor(Phonon::Category category, \
HideAdvancedDevicesOverride override = FromSettings) const; int \
audioOutputDeviceFor(Phonon::Category category) const;
// QList<int> audioCaptureDeviceList() const;
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic