This repository was archived by the owner on Apr 29, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +13
-13
lines changed Expand file tree Collapse file tree 1 file changed +13
-13
lines changed Original file line number Diff line number Diff line change @@ -168,6 +168,19 @@ void exitAllDevices(_TrackedAnnotation trackedAnnotation) {
168
168
}
169
169
170
170
_TrackedAnnotation hitAnnotation = this . _findAnnotation ( hit ) ;
171
+ //enter
172
+ if ( ! hitAnnotation . activeDevices . Contains ( deviceId ) ) {
173
+ hitAnnotation . activeDevices . Add ( deviceId ) ;
174
+ if ( hitAnnotation . annotation ? . onEnter != null ) {
175
+ hitAnnotation . annotation . onEnter ( PointerEnterEvent . fromHoverEvent ( lastEvent ) ) ;
176
+ }
177
+ }
178
+
179
+ //hover
180
+ if ( hitAnnotation . annotation ? . onHover != null ) {
181
+ hitAnnotation . annotation . onHover ( PointerHoverEvent . fromHoverEvent ( lastEvent ) ) ;
182
+ }
183
+
171
184
//leave
172
185
foreach ( _TrackedAnnotation trackedAnnotation in this . _trackedAnnotations . Values ) {
173
186
if ( hitAnnotation == trackedAnnotation ) {
@@ -182,19 +195,6 @@ void exitAllDevices(_TrackedAnnotation trackedAnnotation) {
182
195
trackedAnnotation . activeDevices . Remove ( deviceId ) ;
183
196
}
184
197
}
185
-
186
- //enter
187
- if ( ! hitAnnotation . activeDevices . Contains ( deviceId ) ) {
188
- hitAnnotation . activeDevices . Add ( deviceId ) ;
189
- if ( hitAnnotation . annotation ? . onEnter != null ) {
190
- hitAnnotation . annotation . onEnter ( PointerEnterEvent . fromHoverEvent ( lastEvent ) ) ;
191
- }
192
- }
193
-
194
- //hover
195
- if ( hitAnnotation . annotation ? . onHover != null ) {
196
- hitAnnotation . annotation . onHover ( PointerHoverEvent . fromHoverEvent ( lastEvent ) ) ;
197
- }
198
198
}
199
199
}
200
200
}
You can’t perform that action at this time.
0 commit comments