summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRoman Birg <roman@cyngn.com>2016-05-03 14:09:44 -0700
committerRoman Birg <roman@cyngn.com>2016-05-04 15:34:43 -0700
commit2a5d138c396ba5dcf724a8bdbc7063d025e98e6e (patch)
tree64b46609fd7063b1e47e9db5833eff391ed92134 /src
parentcf9de81d602a7c1e1497c32d5bad6022a4a0cbd9 (diff)
downloadandroid_packages_apps_AudioFX-2a5d138c396ba5dcf724a8bdbc7063d025e98e6e.tar.gz
android_packages_apps_AudioFX-2a5d138c396ba5dcf724a8bdbc7063d025e98e6e.tar.bz2
android_packages_apps_AudioFX-2a5d138c396ba5dcf724a8bdbc7063d025e98e6e.zip
AudioFX: fix output listener regression
We need to register with Audio Manager before doing anything else to receive callbacks properly. Ticket: OPO-343 Change-Id: I5533b02b533ec160f3ca357692709294c118263f Signed-off-by: Roman Birg <roman@cyngn.com>
Diffstat (limited to 'src')
-rw-r--r--src/com/cyngn/audiofx/service/AudioFxService.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/com/cyngn/audiofx/service/AudioFxService.java b/src/com/cyngn/audiofx/service/AudioFxService.java
index 00d03ee..1def25c 100644
--- a/src/com/cyngn/audiofx/service/AudioFxService.java
+++ b/src/com/cyngn/audiofx/service/AudioFxService.java
@@ -143,6 +143,7 @@ public class AudioFxService extends Service
mHandler = new Handler(handlerThread.getLooper());
mOutputListener = new AudioOutputChangeListener(getApplicationContext(), mHandler);
+ mOutputListener.addCallback(this);
mDevicePrefs = new DevicePreferenceManager(getApplicationContext());
if (!mDevicePrefs.initDefaults()) {
@@ -151,8 +152,7 @@ public class AudioFxService extends Service
}
mSessionManager = new SessionManager(getApplicationContext(), mHandler, mDevicePrefs);
-
- mOutputListener.addCallback(mDevicePrefs, mSessionManager, this);
+ mOutputListener.addCallback(mDevicePrefs, mSessionManager);
final CMAudioManager cma = CMAudioManager.getInstance(getApplicationContext());
for (AudioSessionInfo asi : cma.listAudioSessions(AudioManager.STREAM_MUSIC)) {