10#include "pulseaudioqt_export.h"
49class PULSEAUDIOQT_EXPORT Context :
public QObject
57 Q_PROPERTY(
State state READ state NOTIFY stateChanged)
65 Q_PROPERTY(
bool autoConnecting READ isAutoConnecting NOTIFY autoConnectingChanged)
84 static Context *instance();
91 static void setApplicationId(
const QString &applicationId);
156 pa_context *context()
const;
158 void setCardProfile(quint32 index,
const QString &profile);
159 void setDefaultSink(
const QString &name);
160 void setDefaultSource(
const QString &name);
167 [[nodiscard]]
State state()
const;
174 [[nodiscard]]
bool isAutoConnecting()
const;
195 void unloadModule(PulseAudioQt::Module *module);
203 void reconnectDaemon();
249 void clientAdded(PulseAudioQt::Client *client);
254 void clientRemoved(PulseAudioQt::Client *client);
259 void cardAdded(PulseAudioQt::Card *card);
264 void cardRemoved(PulseAudioQt::Card *card);
269 void moduleAdded(PulseAudioQt::Module *module);
274 void moduleRemoved(PulseAudioQt::Module *module);
279 void streamRestoreAdded(PulseAudioQt::StreamRestore *streamRestore);
284 void streamRestoreRemoved(PulseAudioQt::StreamRestore *streamRestore);
298 void autoConnectingChanged();
301 explicit Context(
QObject *parent =
nullptr);
303 std::unique_ptr<class ContextPrivate> d;
306 friend class SinkInput;
308 friend class SourceOutput;
310 friend class StreamRestorePrivate;
312 friend class SinkModel;
313 friend class SinkInputModel;
314 friend class SourceModel;
315 friend class SourceOutputModel;
316 friend class StreamRestoreModel;
317 friend class CardModel;
318 friend class ModuleModel;
KCMUTILS_EXPORT KCModule * loadModule(const KPluginMetaData &metaData, QWidget *parent=nullptr, const QVariantList &args={}, const std::shared_ptr< QQmlEngine > &engine={})
bool isValid(QStringView ifopt)
The primary namespace of PulseAudioQt.
qint64 normalVolume()
The normal volume (100%, 0 dB).
qint64 maximumUIVolume()
The maximum volume suitable to display in a UI.
qint64 minimumVolume()
The minimum volume (0%).
qint64 maximumVolume()
The maximum volume PulseAudio can store.