Merge "Make sure we don't accidentally allow the night mode tile" into nyc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
126366dde5
@@ -80,14 +80,16 @@ public class AutoTileManager {
|
|||||||
new NightModeController.Listener() {
|
new NightModeController.Listener() {
|
||||||
@Override
|
@Override
|
||||||
public void onNightModeChanged() {
|
public void onNightModeChanged() {
|
||||||
mHost.addTile("night");
|
if (mHost.getNightModeController().isEnabled()) {
|
||||||
Prefs.putBoolean(mContext, Key.QS_NIGHT_ADDED, true);
|
mHost.addTile("night");
|
||||||
mHandler.post(new Runnable() {
|
Prefs.putBoolean(mContext, Key.QS_NIGHT_ADDED, true);
|
||||||
@Override
|
mHandler.post(new Runnable() {
|
||||||
public void run() {
|
@Override
|
||||||
mHost.getNightModeController().removeListener(mNightModeListener);
|
public void run() {
|
||||||
}
|
mHost.getNightModeController().removeListener(mNightModeListener);
|
||||||
});
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
Reference in New Issue
Block a user