I basically have a listener on a widget.button ( doubt that it being a widget button matters, but i’ll mention that anyways) where it does stuff on pressed/moved/release events
Normally everything behaves as it should with all of the events being fired properly and everything working just dandy, but it’s possible to basically touch the button, and then quickly drag it and let it go, and then ended event does not get fired, which makes it seem like you are still holding the button yet you already let it go
This does not happen in simulator, not when built on android, but only on ios/xcode simulator
In the press phase i do have
display.getCurrentStage():insert(event.target)
display.getCurrentStage():setFocus(event.target)
and in the ended phase
display.getCurrentStage():setFocus(nil)
I tried setting the event.target.isFocus = true in press and false in ended as some examples have it, but that didn’t help
I even tried running with with printouts for every event to make sure there’s nothing silly going on, yet everything works as i described
sample of it working (these are logs from running on xcode sim):
2013-01-21 11:28:28.735 AM : Phase press x 280 y 90
2013-01-21 11:28:29.154 AM : Phase moved x 272 y 79
2013-01-21 11:28:29.172 AM : Phase moved x 272 y 78
2013-01-21 11:28:29.188 AM : Phase moved x 272 y 76
2013-01-21 11:28:29.206 AM : Phase moved x 271 y 72
2013-01-21 11:28:29.221 AM : Phase moved x 267 y 67
2013-01-21 11:28:29.244 AM : Phase moved x 262 y 62
2013-01-21 11:28:29.255 AM : Phase moved x 258 y 57
2013-01-21 11:28:29.277 AM : Phase moved x 255 y 55
2013-01-21 11:28:29.311 AM : Phase moved x 254 y 54
2013-01-21 11:28:30.191 AM : Phase moved x 253 y 53
2013-01-21 11:28:30.224 AM : Phase moved x 253 y 51
2013-01-21 11:28:30.257 AM : Phase moved x 253 y 50
2013-01-21 11:28:30.358 AM : Phase moved x 253 y 49
2013-01-21 11:28:30.377 AM : Phase moved x 252 y 51
2013-01-21 11:28:30.391 AM : Phase moved x 236 y 66
2013-01-21 11:28:30.410 AM : Phase moved x 200 y 96
2013-01-21 11:28:30.425 AM : Phase moved x 159 y 132
2013-01-21 11:28:30.444 AM : Phase moved x 101 y 180
2013-01-21 11:28:30.458 AM : Phase moved x 65 y 209
2013-01-21 11:28:30.477 AM : Phase release x 46 y 224
Sample of it breaking (same logs from xcode sim):
2013-01-21 11:28:35.328 AM : Phase press x 280 y 90
2013-01-21 11:28:35.423 AM : Phase moved x 272 y 93
2013-01-21 11:28:35.440 AM : Phase moved x 272 y 91
2013-01-21 11:28:35.456 AM : Phase moved x 271 y 87
2013-01-21 11:28:35.474 AM : Phase moved x 269 y 83
2013-01-21 11:28:35.490 AM : Phase moved x 266 y 78
2013-01-21 11:28:35.506 AM : Phase moved x 262 y 73
2013-01-21 11:28:35.523 AM : Phase moved x 258 y 67
2013-01-21 11:28:35.544 AM : Phase moved x 253 y 64
2013-01-21 11:28:35.557 AM : Phase moved x 251 y 61
2013-01-21 11:28:35.576 AM : Phase moved x 248 y 58
2013-01-21 11:28:35.590 AM : Phase moved x 247 y 58
2013-01-21 11:28:35.690 AM : Phase moved x 247 y 57
2013-01-21 11:28:35.709 AM : Phase moved x 247 y 56
2013-01-21 11:28:35.724 AM : Phase moved x 246 y 55
2013-01-21 11:28:35.743 AM : Phase moved x 246 y 52
2013-01-21 11:28:35.757 AM : Phase moved x 245 y 49
2013-01-21 11:28:35.777 AM : Phase moved x 244 y 47
2013-01-21 11:28:35.790 AM : Phase moved x 243 y 45
2013-01-21 11:28:35.824 AM : Phase moved x 242 y 44
2013-01-21 11:28:36.576 AM : Phase moved x 242 y 42
2013-01-21 11:28:36.593 AM : Phase moved x 241 y 43
2013-01-21 11:28:36.610 AM : Phase moved x 241 y 44
2013-01-21 11:28:36.626 AM : Phase moved x 241 y 46
2013-01-21 11:28:36.727 AM : Phase moved x 241 y 47
2013-01-21 11:28:36.760 AM : Phase moved x 241 y 46
2013-01-21 11:28:36.777 AM : Phase moved x 241 y 45
2013-01-21 11:28:36.794 AM : Phase moved x 243 y 44
2013-01-21 11:28:36.810 AM : Phase moved x 244 y 42
2013-01-21 11:28:36.827 AM : Phase moved x 246 y 41
2013-01-21 11:28:36.861 AM : Phase moved x 247 y 39
2013-01-21 11:28:36.910 AM : Phase moved x 249 y 37
2013-01-21 11:28:36.927 AM : Phase moved x 249 y 36
2013-01-21 11:28:36.961 AM : Phase moved x 251 y 36
2013-01-21 11:28:37.028 AM : Phase moved x 252 y 35
2013-01-21 11:28:37.044 AM : Phase moved x 246 y 39
2013-01-21 11:28:37.061 AM : Phase moved x 222 y 56
2013-01-21 11:28:37.078 AM : Phase moved x 185 y 76
2013-01-21 11:28:37.095 AM : Phase moved x 127 y 107
(this is when the object was released and no ended event was fired)
What can be the reasons for the ended event not to get fired on iOS?
Any help will be appreciated
[import]uid: 121569 topic_id: 35159 reply_id: 335159[/import]