summaryrefslogtreecommitdiff
path: root/libs/input/TouchSpotController.h
diff options
context:
space:
mode:
authorTreehugger Robot <treehugger-gerrit@google.com>2020-08-24 11:28:48 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2020-08-24 11:28:48 +0000
commit42e412b5111f99e6e4813aa9ab7450ec215ca09b (patch)
tree08eec6c6c1d0725ed35b7db71a1d15f9ea18db6c /libs/input/TouchSpotController.h
parentbe053b7e197809408865a2a4989df05d3012385b (diff)
parent5267d9227289a074aa4c4a972586d182ce4c76a5 (diff)
Merge "Switch to callback animation" am: 51060f3f7a am: 5267d92272
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1399752 Change-Id: I3e4d82a9a2f9e9f4f1232a2de21a55cc19a2168a
Diffstat (limited to 'libs/input/TouchSpotController.h')
-rw-r--r--libs/input/TouchSpotController.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/libs/input/TouchSpotController.h b/libs/input/TouchSpotController.h
index f3b355010bee..703de3603f48 100644
--- a/libs/input/TouchSpotController.h
+++ b/libs/input/TouchSpotController.h
@@ -17,6 +17,8 @@
#ifndef _UI_TOUCH_SPOT_CONTROLLER_H
#define _UI_TOUCH_SPOT_CONTROLLER_H
+#include <functional>
+
#include "PointerControllerContext.h"
namespace android {
@@ -34,7 +36,7 @@ public:
void clearSpots();
void reloadSpotResources();
- bool doFadingAnimation(nsecs_t timestamp, bool keepAnimating);
+ bool doAnimations(nsecs_t timestamp);
private:
struct Spot {
@@ -76,6 +78,8 @@ private:
std::vector<Spot*> displaySpots;
std::vector<sp<Sprite>> recycledSprites;
+ bool animating{false};
+
} mLocked GUARDED_BY(mLock);
Spot* getSpot(uint32_t id, const std::vector<Spot*>& spots);
@@ -84,6 +88,8 @@ private:
void releaseSpotLocked(Spot* spot);
void fadeOutAndReleaseSpotLocked(Spot* spot);
void fadeOutAndReleaseAllSpotsLocked();
+ bool doFadingAnimationLocked(nsecs_t timestamp);
+ void startAnimationLocked();
};
} // namespace android