Android Audio Service Volume Controller, 볼륨 UI 업데이트
SystemUI AudioService VolumeDialogControllerImpl IVolumeController.Stub VC。
VolumeController UI 。
06-21 12:55:21.770 3122 3122 W System.err: java.lang.Exception: setVolumeController
06-21 12:55:21.771 3122 3122 W System.err: at com.android.systemui.volume.VolumeDialogControllerImpl.setVolumeController(VolumeDialogControllerImpl.java:150)
06-21 12:55:21.771 3122 3122 W System.err: at com.android.systemui.volume.VolumeDialogControllerImpl.register(VolumeDialogControllerImpl.java:176)
06-21 12:55:21.771 3122 3122 W System.err: at com.android.systemui.volume.VolumeDialogComponent.register(VolumeDialogComponent.java:171)
06-21 12:55:21.771 3122 3122 W System.err: at com.android.systemui.volume.VolumeUI.setDefaultVolumeController(VolumeUI.java:71)
06-21 12:55:21.771 3122 3122 W System.err: at com.android.systemui.volume.VolumeUI.start(VolumeUI.java:47)
06-21 12:55:21.771 3122 3122 W System.err: at com.android.systemui.SystemUIApplication.startServicesIfNeeded(SystemUIApplication.java:215)
06-21 12:55:21.771 3122 3122 W System.err: at com.android.systemui.SystemUIApplication.startServicesIfNeeded(SystemUIApplication.java:164)
06-21 12:55:21.771 3122 3122 W System.err: at com.android.systemui.SystemUIService.onCreate(SystemUIService.java:33)
06-21 12:55:21.771 3122 3122 W System.err: at android.app.ActivityThread.handleCreateService(ActivityThread.java:3339)
06-21 12:55:21.771 3122 3122 W System.err: at android.app.ActivityThread.-wrap4(Unknown Source:0)
06-21 12:55:21.771 3122 3122 W System.err: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1677)
06-21 12:55:21.771 3122 3122 W System.err: at android.os.Handler.dispatchMessage(Handler.java:106)
06-21 12:55:21.771 3122 3122 W System.err: at android.os.Looper.loop(Looper.java:164)
06-21 12:55:21.771 3122 3122 W System.err: at android.app.ActivityThread.main(ActivityThread.java:6494)
06-21 12:55:21.771 3122 3122 W System.err: at java.lang.reflect.Method.invoke(Native Method)
06-21 12:55:21.771 3122 3122 W System.err: at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
06-21 12:55:21.772 3122 3122 W System.err: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807)
06-21 12:55:21.774 2979 3337 D AudioService: Volume controller: VolumeController(android.os.BinderProxy@337c8cc,mVisible=false)
@Override
public void setVolumeController(final IVolumeController controller) {
enforceVolumeController("set the volume controller");
// return early if things are not actually changing
if (mVolumeController.isSameBinder(controller)) {
return;
}
// dismiss the old volume controller
mVolumeController.postDismiss();
if (controller != null) {
// we are about to register a new controller, listen for its death
try {
controller.asBinder().linkToDeath(new DeathRecipient() {
@Override
public void binderDied() {
if (mVolumeController.isSameBinder(controller)) {
Log.w(TAG, "Current remote volume controller died, unregistering");
setVolumeController(null);
}
}
}, 0);
} catch (RemoteException e) {
// noop
}
}
mVolumeController.setController(controller);
if (DEBUG_VOL) Log.d(TAG, "Volume controller: " + mVolumeController);
private final class VC extends IVolumeController.Stub {
private final String TAG = VolumeDialogControllerImpl.TAG + ".VC";
@Override
public void displaySafeVolumeWarning(int flags) throws RemoteException {
if (D.BUG) Log.d(TAG, "displaySafeVolumeWarning "
+ Util.audioManagerFlagsToString(flags));
if (mDestroyed) return;
mWorker.obtainMessage(W.SHOW_SAFETY_WARNING, flags, 0).sendToTarget();
}
@Override
public void volumeChanged(int streamType, int flags) throws RemoteException {
if (D.BUG) Log.d(TAG, "volumeChanged " + AudioSystem.streamToString(streamType)
+ " " + Util.audioManagerFlagsToString(flags));
if (mDestroyed) return;
mWorker.obtainMessage(W.VOLUME_CHANGED, streamType, flags).sendToTarget();
}
@Override
public void masterMuteChanged(int flags) throws RemoteException {
if (D.BUG) Log.d(TAG, "masterMuteChanged");
}
@Override
public void setLayoutDirection(int layoutDirection) throws RemoteException {
if (D.BUG) Log.d(TAG, "setLayoutDirection");
if (mDestroyed) return;
mWorker.obtainMessage(W.LAYOUT_DIRECTION_CHANGED, layoutDirection, 0).sendToTarget();
}
@Override
public void dismiss() throws RemoteException {
if (D.BUG) Log.d(TAG, "dismiss requested");
if (mDestroyed) return;
mWorker.obtainMessage(W.DISMISS_REQUESTED, Events.DISMISS_REASON_VOLUME_CONTROLLER, 0)
.sendToTarget();
mWorker.sendEmptyMessage(W.DISMISS_REQUESTED);
}
@Override
public void setA11yMode(int mode) {
if (D.BUG) Log.d(TAG, "setA11yMode to " + mode);
if (mDestroyed) return;
switch (mode) {
case VolumePolicy.A11Y_MODE_MEDIA_A11Y_VOLUME:
// "legacy" mode
mShowA11yStream = false;
break;
case VolumePolicy.A11Y_MODE_INDEPENDENT_A11Y_VOLUME:
mShowA11yStream = true;
break;
default:
Log.e(TAG, "Invalid accessibility mode " + mode);
break;
}
mWorker.obtainMessage(W.ACCESSIBILITY_MODE_CHANGED, mShowA11yStream).sendToTarget();
}
}
이 내용에 흥미가 있습니까?
현재 기사가 여러분의 문제를 해결하지 못하는 경우 AI 엔진은 머신러닝 분석(스마트 모델이 방금 만들어져 부정확한 경우가 있을 수 있음)을 통해 가장 유사한 기사를 추천합니다:
다양한 언어의 JSONJSON은 Javascript 표기법을 사용하여 데이터 구조를 레이아웃하는 데이터 형식입니다. 그러나 Javascript가 코드에서 이러한 구조를 나타낼 수 있는 유일한 언어는 아닙니다. 저는 일반적으로 '객체'{}...
텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
CC BY-SA 2.5, CC BY-SA 3.0 및 CC BY-SA 4.0에 따라 라이센스가 부여됩니다.