We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 74a550f commit 8dd9206Copy full SHA for 8dd9206
packages/SystemUI/src/com/android/systemui/statusbar/phone/QuickSettingsModel.java
@@ -399,7 +399,11 @@ void onRotationLockChanged() {
399
mRotationLockState.label = locked
400
? mContext.getString(R.string.quick_settings_rotation_locked_label)
401
: mContext.getString(R.string.quick_settings_rotation_unlocked_label);
402
- mRotationLockCallback.refreshView(mRotationLockTile, mRotationLockState);
+
403
+ // may be called before addRotationLockTile due to RotationPolicyListener in QuickSettings
404
+ if (mRotationLockTile != null && mRotationLockCallback != null) {
405
+ mRotationLockCallback.refreshView(mRotationLockTile, mRotationLockState);
406
+ }
407
}
408
409
0 commit comments