aboutsummaryrefslogtreecommitdiffstats
path: root/app/paclient.h
diff options
context:
space:
mode:
authorMatt Porter <mporter@konsulko.com>2017-04-19 12:53:55 -0400
committerMatt Porter <mporter@konsulko.com>2017-04-20 22:00:09 -0400
commitb8423505e6e7360b509cdfd22f8d86f45169443d (patch)
treebfd146499506418a2200e3a78aa0b81af62b907e /app/paclient.h
parent3fd71f4b6bc026f2f9054140f7bf612855e45d7d (diff)
Convert the sink/source volume caches from a list to hashes
Maintain the cached sink/source volume state in separate hashes for quick lookup. This will further simplify external volume event support that will need to update the cache. AGL-Bug: SPEC-548 Change-Id: I47b8e070318f3992a5343d1753c50baa8c1d9cb3 Signed-off-by: Matt Porter <mporter@konsulko.com>
Diffstat (limited to 'app/paclient.h')
-rw-r--r--app/paclient.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/app/paclient.h b/app/paclient.h
index 1367e81..002fbb3 100644
--- a/app/paclient.h
+++ b/app/paclient.h
@@ -16,6 +16,7 @@
#include <pulse/pulseaudio.h>
+#include <QtCore/QHash>
#include <QtCore/QObject>
const char * const channel_position_string[] =
@@ -85,5 +86,6 @@ class PaClient : public QObject
pa_threaded_mainloop *m_ml;
pa_mainloop_api *m_mlapi;
pa_context *m_ctx;
- QList<CState *> m_cstatelist;
+ QHash<int, pa_cvolume *> m_sink_states;
+ QHash<int, pa_cvolume *> m_source_states;
};