summaryrefslogtreecommitdiff
path: root/packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java
diff options
context:
space:
mode:
authorScott Lobdell <slobdell@google.com>2019-01-31 11:53:41 -0800
committerScott Lobdell <slobdell@google.com>2019-02-01 14:08:42 -0800
commit88b45c586d461df38b866d529bc98d1dfa3e8838 (patch)
treeae57a86275dac94c0899015923778f3016c865b2 /packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java
parent067596650927fa91a97355e84b152b21826f7ae2 (diff)
parent9b9ca46fc2d3da231bf9ef6ff630105720f94cf2 (diff)
Merge QP1A.190122.001
Conflicts: api/system-current.txt core/java/android/bluetooth/BluetoothAdapter.java core/jni/android_util_Process.cpp core/jni/com_android_internal_os_Zygote.cpp core/res/res/values/config.xml core/res/res/values/symbols.xml media/java/android/media/MediaCodecInfo.java packages/SystemUI/src/com/android/systemui/statusbar/SignalClusterView.java services/core/java/com/android/server/ConnectivityService.java services/core/java/com/android/server/LocationManagerService.java services/core/java/com/android/server/am/ActivityManagerService.java services/core/java/com/android/server/connectivity/NetworkAgentInfo.java services/core/java/com/android/server/location/GnssLocationProvider.java services/core/java/com/android/server/wm/ActivityStack.java services/net/java/android/net/ip/IpClient.java telecomm/java/android/telecom/Connection.java telephony/java/android/telephony/ims/ImsCallSession.java telephony/java/android/telephony/ims/ImsCallSessionListener.java telephony/java/android/telephony/ims/aidl/IImsCallSessionListener.aidl telephony/java/android/telephony/ims/compat/stub/ImsCallSessionImplBase.java telephony/java/com/android/ims/internal/IImsCallSessionListener.aidl wifi/java/android/net/wifi/WifiConfiguration.java Change-Id: I367301986f2ae80a528050c3d78776b5a4c6b5ee
Diffstat (limited to 'packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java')
-rw-r--r--packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java30
1 files changed, 14 insertions, 16 deletions
diff --git a/packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java b/packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java
index c6f172684686..bb549ada6830 100644
--- a/packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java
+++ b/packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java
@@ -72,7 +72,6 @@ public class KeyguardStatusView extends GridLayout implements
private ArraySet<View> mVisibleInDoze;
private boolean mPulsing;
- private boolean mWasPulsing;
private float mDarkAmount = 0;
private int mTextColor;
private int mLastLayoutHeight;
@@ -141,6 +140,13 @@ public class KeyguardStatusView extends GridLayout implements
onDensityOrFontScaleChanged();
}
+ /**
+ * If we're presenting a custom clock of just the default one.
+ */
+ public boolean hasCustomClock() {
+ return mClockView.hasCustomClock();
+ }
+
private void setEnableMarquee(boolean enabled) {
if (DEBUG) Log.v(TAG, "Schedule setEnableMarquee: " + (enabled ? "Enable" : "Disable"));
if (enabled) {
@@ -195,10 +201,6 @@ public class KeyguardStatusView extends GridLayout implements
updateOwnerInfo();
updateLogoutView();
updateDark();
-
- // Disable elegant text height because our fancy colon makes the ymin value huge for no
- // reason.
- mClockView.setElegantTextHeight(false);
}
/**
@@ -207,7 +209,7 @@ public class KeyguardStatusView extends GridLayout implements
private void onSliceContentChanged() {
LinearLayout.LayoutParams layoutParams =
(LinearLayout.LayoutParams) mClockView.getLayoutParams();
- layoutParams.bottomMargin = mPulsing ? mSmallClockPadding : 0;
+ layoutParams.bottomMargin = mKeyguardSlice.hasHeader() ? mSmallClockPadding : 0;
mClockView.setLayoutParams(layoutParams);
}
@@ -217,16 +219,16 @@ public class KeyguardStatusView extends GridLayout implements
@Override
public void onLayoutChange(View view, int left, int top, int right, int bottom,
int oldLeft, int oldTop, int oldRight, int oldBottom) {
- int heightOffset = mPulsing || mWasPulsing ? 0 : getHeight() - mLastLayoutHeight;
+ boolean smallClock = mKeyguardSlice.hasHeader();
+ int heightOffset = smallClock ? 0 : getHeight() - mLastLayoutHeight;
long duration = KeyguardSliceView.DEFAULT_ANIM_DURATION;
- long delay = mPulsing || mWasPulsing ? 0 : duration / 4;
- mWasPulsing = false;
+ long delay = smallClock ? 0 : duration / 4;
boolean shouldAnimate = mKeyguardSlice.getLayoutTransition() != null
&& mKeyguardSlice.getLayoutTransition().isRunning();
if (view == mClockView) {
- float clockScale = mPulsing ? mSmallClockScale : 1;
- Paint.Style style = mPulsing ? Paint.Style.FILL_AND_STROKE : Paint.Style.FILL;
+ float clockScale = smallClock ? mSmallClockScale : 1;
+ Paint.Style style = smallClock ? Paint.Style.FILL_AND_STROKE : Paint.Style.FILL;
mClockView.animate().cancel();
if (shouldAnimate) {
mClockView.setY(oldTop + heightOffset);
@@ -431,15 +433,11 @@ public class KeyguardStatusView extends GridLayout implements
}
}
- public void setPulsing(boolean pulsing, boolean animate) {
+ public void setPulsing(boolean pulsing) {
if (mPulsing == pulsing) {
return;
}
- if (mPulsing) {
- mWasPulsing = true;
- }
mPulsing = pulsing;
- mKeyguardSlice.setPulsing(pulsing, animate);
updateDozeVisibleViews();
}