diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2017-12-28 02:35:07 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2017-12-28 02:35:07 +0000 |
commit | 281998c825ad48d842bb653e2f462719fdb0c1d9 (patch) | |
tree | bc8bfcce809257b3ddbb423a9808082292b9f6a3 /java/com/android/incallui/InCallOrientationEventListener.java | |
parent | fc81a030a7b4f6d4a497f71aed593d398795e7da (diff) | |
parent | 183cb71663320f16149d83eeebaff7795a4b55f2 (diff) |
Merge "Remove field prefixes."
Diffstat (limited to 'java/com/android/incallui/InCallOrientationEventListener.java')
-rw-r--r-- | java/com/android/incallui/InCallOrientationEventListener.java | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/java/com/android/incallui/InCallOrientationEventListener.java b/java/com/android/incallui/InCallOrientationEventListener.java index 8aae6fb37..854bdd193 100644 --- a/java/com/android/incallui/InCallOrientationEventListener.java +++ b/java/com/android/incallui/InCallOrientationEventListener.java @@ -68,9 +68,9 @@ public class InCallOrientationEventListener extends OrientationEventListener { private static final int ROTATION_THRESHOLD = 10; /** Cache the current rotation of the device. */ - @ScreenOrientation private static int sCurrentOrientation = SCREEN_ORIENTATION_0; + @ScreenOrientation private static int currentOrientation = SCREEN_ORIENTATION_0; - private boolean mEnabled = false; + private boolean enabled = false; public InCallOrientationEventListener(Context context) { super(context); @@ -94,7 +94,7 @@ public class InCallOrientationEventListener extends OrientationEventListener { @ScreenOrientation public static int getCurrentOrientation() { - return sCurrentOrientation; + return currentOrientation; } /** @@ -114,14 +114,14 @@ public class InCallOrientationEventListener extends OrientationEventListener { final int orientation = toScreenOrientation(rotation); - if (orientation != SCREEN_ORIENTATION_UNKNOWN && sCurrentOrientation != orientation) { + if (orientation != SCREEN_ORIENTATION_UNKNOWN && currentOrientation != orientation) { LogUtil.i( "InCallOrientationEventListener.onOrientationChanged", "orientation: %d -> %d", - sCurrentOrientation, + currentOrientation, orientation); - sCurrentOrientation = orientation; - InCallPresenter.getInstance().onDeviceOrientationChange(sCurrentOrientation); + currentOrientation = orientation; + InCallPresenter.getInstance().onDeviceOrientationChange(currentOrientation); } } @@ -133,15 +133,15 @@ public class InCallOrientationEventListener extends OrientationEventListener { * changed. */ public void enable(boolean notifyDeviceOrientationChange) { - if (mEnabled) { + if (enabled) { Log.v(this, "enable: Orientation listener is already enabled. Ignoring..."); return; } super.enable(); - mEnabled = true; + enabled = true; if (notifyDeviceOrientationChange) { - InCallPresenter.getInstance().onDeviceOrientationChange(sCurrentOrientation); + InCallPresenter.getInstance().onDeviceOrientationChange(currentOrientation); } } @@ -154,18 +154,18 @@ public class InCallOrientationEventListener extends OrientationEventListener { /** Disables the OrientationEventListener. */ @Override public void disable() { - if (!mEnabled) { + if (!enabled) { Log.v(this, "enable: Orientation listener is already disabled. Ignoring..."); return; } - mEnabled = false; + enabled = false; super.disable(); } /** Returns true the OrientationEventListener is enabled, false otherwise. */ public boolean isEnabled() { - return mEnabled; + return enabled; } /** |