| 253 | lastEvent.getActionIndex(), |
| 254 | lastEvent.getPointerLocations(), |
| 255 | currentTime, |
| 256 | lastEvent.getOffsetSinceSource() + offsetSinceLastEvent, |
| 257 | lastEvent.getSource())); |
| 258 | return true; |
| 259 | } |
| 260 | |
| 261 | EventId LayerRoot::enqueueEvent(EventCallback&& eventCallback, Duration after) { |
| 262 | auto eventId = _eventQueue.enqueue(after, std::move(eventCallback)); |
| 263 | enqueueFrame(); |
| 264 | return eventId; |
| 265 | } |
| 266 | |
| 267 | bool LayerRoot::cancelEvent(EventId eventId) { |
| 268 | return _eventQueue.cancel(eventId); |
| 269 | } |
| 270 | |
| 271 | void LayerRoot::enqueueFrame() { |
| 272 | if (canEnqueueFrame() && _listener != nullptr) { |
| 273 | _didEnqueueFrame = true; |
| 274 | _listener->onNeedsProcessFrame(*this); |
nothing calls this directly
no test coverage detected