Use the Global value rather than the Secure value
Fixes: 137876221 Test: manual - have setting in dev options turned off, post a bubble => no bubble appears - have setting in dev options turned on, post a bubble => bubble appears Change-Id: I4490b978059a73b45fa8d09bf28e05965f42eec1
This commit is contained in:
@@ -16,8 +16,6 @@
|
|||||||
|
|
||||||
package com.android.settings.development;
|
package com.android.settings.development;
|
||||||
|
|
||||||
import static android.provider.Settings.Secure.NOTIFICATION_BUBBLES;
|
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.provider.Settings;
|
import android.provider.Settings;
|
||||||
|
|
||||||
@@ -42,7 +40,7 @@ public class BubbleGlobalPreferenceController extends DeveloperOptionsPreference
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String getPreferenceKey() {
|
public String getPreferenceKey() {
|
||||||
return NOTIFICATION_BUBBLES;
|
return Settings.Global.NOTIFICATION_BUBBLES;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -64,12 +62,12 @@ public class BubbleGlobalPreferenceController extends DeveloperOptionsPreference
|
|||||||
}
|
}
|
||||||
|
|
||||||
private boolean isEnabled() {
|
private boolean isEnabled() {
|
||||||
return Settings.Secure.getInt(mContext.getContentResolver(),
|
return Settings.Global.getInt(mContext.getContentResolver(),
|
||||||
NOTIFICATION_BUBBLES, OFF) == ON;
|
Settings.Global.NOTIFICATION_BUBBLES, OFF) == ON;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void writeSetting(boolean isEnabled) {
|
private void writeSetting(boolean isEnabled) {
|
||||||
Settings.Secure.putInt(mContext.getContentResolver(),
|
Settings.Global.putInt(mContext.getContentResolver(),
|
||||||
NOTIFICATION_BUBBLES, isEnabled ? ON : OFF);
|
Settings.Global.NOTIFICATION_BUBBLES, isEnabled ? ON : OFF);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user