summaryrefslogtreecommitdiff
path: root/java/com/android/incallui/InCallOrientationEventListener.java
diff options
context:
space:
mode:
authorlinyuh <linyuh@google.com>2017-12-27 17:02:37 -0800
committerCopybara-Service <copybara-piper@google.com>2017-12-27 17:03:47 -0800
commit183cb71663320f16149d83eeebaff7795a4b55f2 (patch)
treebc8bfcce809257b3ddbb423a9808082292b9f6a3 /java/com/android/incallui/InCallOrientationEventListener.java
parentfc81a030a7b4f6d4a497f71aed593d398795e7da (diff)
Remove field prefixes.
Test: Existing tests PiperOrigin-RevId: 180230450 Change-Id: I0b2589cfeeaef81e42a04efa48af24b4e4d0e95f
Diffstat (limited to 'java/com/android/incallui/InCallOrientationEventListener.java')
-rw-r--r--java/com/android/incallui/InCallOrientationEventListener.java26
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;
}
/**