[FYT Android Head Units] RoNeReR:
hello

just update to GTX rom and trying the XSofiaTweaker-UsbDac , unfortunately the option of block joying volume control and enable volume control over USB DAC not working,

when i press it the gui just crash.

i try to fix it by myself in the last hours with no luck, i know that u dont use dac, but we really need your help.

u can test it without dac, when u change volume u will see the stock android volume bar.

i will update here the fixed code if i will solve the problem.

thank u for your work :good:

Logcat:

03-09 11:06:47.082 3115 3115 D XSofiaTweaker-SettingsFragment: updated key is pref_enable_usb_dac
03-09 11:06:47.084 3115 3115 E InputEventReceiver: Exception dispatching input event.
03-09 11:06:47.084 3115 3115 E MessageQueue-JNI: Exception in MessageQueue callback: handleReceiveCallback
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: java.lang.ClassCastException: java.lang.Boolean cannot be cast to java.lang.String
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.app.SharedPreferencesImpl.getString(SharedPreferencesImpl.java:225)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at org.hvdw.xsofiatweaker.SettingsFragment.onSharedPreferenceChanged(SettingsFragment.java:193)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.app.SharedPreferencesImpl$EditorImpl.notifyListeners(SharedPreferencesImpl.java:479)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.app.SharedPreferencesImpl$EditorImpl.apply(SharedPreferencesImpl.java:387)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.preference.Preference.tryCommit(Preference.java:1415)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.preference.Preference.persistBoolean(Preference.java:1681)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.preference.TwoStatePreference.setChecked(TwoStatePreference.java:81)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.preference.TwoStatePreference.onClick(TwoStatePreference.java:66)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.preference.Preference.performClick(Preference.java:994)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.preference.PreferenceScreen.onItemClick(PreferenceScreen.java:214)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.widget.AdapterView.performItemClick(AdapterView.java:310)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.widget.AbsListView.performItemClick(AbsListView.java:1145)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.widget.AbsListView$PerformClick.run(AbsListView.java:3066)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.widget.AbsListView.onTouchUp(AbsListView.java:3915)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.widget.AbsListView.onTouchEvent(AbsListView.java:3680)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.View.dispatchTouchEvent(View.java:9300)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2547)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2240)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at com.android.internal.policy.PhoneWindow$DecorView.superDispatchTouchEvent(PhoneWindow.java:2403)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at com.android.internal.policy.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1737)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.app.Dialog.dispatchTouchEvent(Dialog.java:787)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at com.android.internal.policy.PhoneWindow$DecorView.dispatchTouchEvent(PhoneWindow.java:2364)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.View.dispatchPointerEvent(View.java:9520)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:4224)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:4090)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3636)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:3689)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:3655)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:3781)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:3663)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:3838)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3636)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:3689)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:3655)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:3663)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3636)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:5916)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:5890)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:5851)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:6019)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:185)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.os.MessageQueue.nativePollOnce(Native Method)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.os.MessageQueue.next(MessageQueue.java:323)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.os.Looper.loop(Looper.java:135)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at android.app.ActivityThread.main(ActivityThread.java:5444)
03-09 11:06:47.090 3115 3115 E MessageQueue-JNI: at java.lang.refle
03-09 11:06:47.090 3115 3115 D AndroidRuntime: Shutting down VM
--------- beginning of crash
03-09 11:06:47.093 3115 3115 E AndroidRuntime: FATAL EXCEPTION: main
03-09 11:06:47.093 3115 3115 E AndroidRuntime: Process: org.hvdw.xsofiatweaker, PID: 3115
03-09 11:06:47.093 3115 3115 E AndroidRuntime: java.lang.ClassCastException: java.lang.Boolean cannot be cast to java.lang.String
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.app.SharedPreferencesImpl.getString(SharedPreferencesImpl.java:225)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at org.hvdw.xsofiatweaker.SettingsFragment.onSharedPreferenceChanged(SettingsFragment.java:193)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.app.SharedPreferencesImpl$EditorImpl.notifyListeners(SharedPreferencesImpl.java:479)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.app.SharedPreferencesImpl$EditorImpl.apply(SharedPreferencesImpl.java:387)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.preference.Preference.tryCommit(Preference.java:1415)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.preference.Preference.persistBoolean(Preference.java:1681)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.preference.TwoStatePreference.setChecked(TwoStatePreference.java:81)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.preference.TwoStatePreference.onClick(TwoStatePreference.java:66)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.preference.Preference.performClick(Preference.java:994)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.preference.PreferenceScreen.onItemClick(PreferenceScreen.java:214)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.widget.AdapterView.performItemClick(AdapterView.java:310)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.widget.AbsListView.performItemClick(AbsListView.java:1145)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.widget.AbsListView$PerformClick.run(AbsListView.java:3066)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.widget.AbsListView.onTouchUp(AbsListView.java:3915)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.widget.AbsListView.onTouchEvent(AbsListView.java:3680)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.View.dispatchTouchEvent(View.java:9300)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2547)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2240)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at com.android.internal.policy.PhoneWindow$DecorView.superDispatchTouchEvent(PhoneWindow.java:2403)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at com.android.internal.policy.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1737)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.app.Dialog.dispatchTouchEvent(Dialog.java:787)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at com.android.internal.policy.PhoneWindow$DecorView.dispatchTouchEvent(PhoneWindow.java:2364)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.View.dispatchPointerEvent(View.java:9520)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:4224)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:4090)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3636)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:3689)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:3655)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:3781)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:3663)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:3838)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3636)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:3689)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:3655)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:3663)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3636)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:5916)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:5890)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:5851)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:6019)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:185)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.os.MessageQueue.nativePollOnce(Native Method)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.os.MessageQueue.next(MessageQueue.java:323)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.os.Looper.loop(Looper.java:135)
03-09 11:06:47.093 3115 3115 E AndroidRuntime: at android.app.Ac
03-09 11:06:47.101 719 2537 W ActivityManager: Force finishing activity org.hvdw.xsofiatweaker/.SettingsActivity
03-09 11:06:47.232 1417 1501 D us : top package is : org.hvdw.xsofiatweaker --> com.teslacoilsw.launcher