summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Michael Wright <michaelwr@google.com> 2022-10-22 01:09:59 +0100
committer Michael Wright <michaelwr@google.com> 2022-11-11 14:04:12 +0000
commit4a18c3e9b1bc98aa9e2f30d963bbd8f4f4adc430 (patch)
treed806c4a5e57ac1438aec7136db7673deb6bd2346
parent002f60d74594dd1a3ba22a73dc99c18157345755 (diff)
Rename pointer-related members to be more specific.
mIcon / mIconType weren't specific enough to be immediately related to pointer icons. Rename them just to make that connection more obvious. Bug: 254277939 Test: simple IDE-assisted refactor Change-Id: Iffe3dd9a7bc2a8166ec411ff6b2f9c8c4d74738d
-rw-r--r--services/core/java/com/android/server/input/InputManagerService.java24
1 files changed, 12 insertions, 12 deletions
diff --git a/services/core/java/com/android/server/input/InputManagerService.java b/services/core/java/com/android/server/input/InputManagerService.java
index c973cb848880..b518b2868333 100644
--- a/services/core/java/com/android/server/input/InputManagerService.java
+++ b/services/core/java/com/android/server/input/InputManagerService.java
@@ -303,9 +303,9 @@ public class InputManagerService extends IInputManager.Stub
private final AdditionalDisplayInputProperties mCurrentDisplayProperties =
new AdditionalDisplayInputProperties();
@GuardedBy("mAdditionalDisplayInputPropertiesLock")
- private int mIconType = PointerIcon.TYPE_NOT_SPECIFIED;
+ private int mPointerIconType = PointerIcon.TYPE_NOT_SPECIFIED;
@GuardedBy("mAdditionalDisplayInputPropertiesLock")
- private PointerIcon mIcon;
+ private PointerIcon mPointerIcon;
// Holds all the registered gesture monitors that are implemented as spy windows. The spy
// windows are mapped by their InputChannel tokens.
@@ -2326,12 +2326,12 @@ public class InputManagerService extends IInputManager.Stub
throw new IllegalArgumentException("Use setCustomPointerIcon to set custom pointers");
}
synchronized (mAdditionalDisplayInputPropertiesLock) {
- mIcon = null;
- mIconType = iconType;
+ mPointerIcon = null;
+ mPointerIconType = iconType;
if (!mCurrentDisplayProperties.pointerIconVisible) return;
- mNative.setPointerIconType(mIconType);
+ mNative.setPointerIconType(mPointerIconType);
}
}
@@ -2340,12 +2340,12 @@ public class InputManagerService extends IInputManager.Stub
public void setCustomPointerIcon(PointerIcon icon) {
Objects.requireNonNull(icon);
synchronized (mAdditionalDisplayInputPropertiesLock) {
- mIconType = PointerIcon.TYPE_CUSTOM;
- mIcon = icon;
+ mPointerIconType = PointerIcon.TYPE_CUSTOM;
+ mPointerIcon = icon;
if (!mCurrentDisplayProperties.pointerIconVisible) return;
- mNative.setCustomPointerIcon(mIcon);
+ mNative.setCustomPointerIcon(mPointerIcon);
}
}
@@ -3846,11 +3846,11 @@ public class InputManagerService extends IInputManager.Stub
if (properties.pointerIconVisible != mCurrentDisplayProperties.pointerIconVisible) {
mCurrentDisplayProperties.pointerIconVisible = properties.pointerIconVisible;
if (properties.pointerIconVisible) {
- if (mIconType == PointerIcon.TYPE_CUSTOM) {
- Objects.requireNonNull(mIcon);
- mNative.setCustomPointerIcon(mIcon);
+ if (mPointerIconType == PointerIcon.TYPE_CUSTOM) {
+ Objects.requireNonNull(mPointerIcon);
+ mNative.setCustomPointerIcon(mPointerIcon);
} else {
- mNative.setPointerIconType(mIconType);
+ mNative.setPointerIconType(mPointerIconType);
}
} else {
mNative.setPointerIconType(PointerIcon.TYPE_NULL);