Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-1493] iOS: MapView user interaction disabled when removing event listener

GitHub Issuen/a
TypeBug
PriorityMedium
StatusClosed
ResolutionCannot Reproduce
Resolution Date2012-07-25T17:26:07.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsiOS
Labelsn/a
ReporterGoran Skledar
AssigneeNeeraj Gupta
Created2011-04-15T02:54:15.000+0000
Updated2012-07-26T22:20:46.000+0000

Description

If you attach an event listener to a MapView and then remove it, the MapView will stay frozen, e.g. no user interaction will be possible.

To reproduce the problem, run the attached app.js file and try this:

  1. Click the "Add listener" button
  2. Note you can move and pinch the map
  3. Click the "Remove listener" button
  4. MapView "freezes", you are not able to move or pinch the map.

The issue seems to come from handleListenerRemovedWithEvent in TiUIView.m, specifically this part:

self.userInteractionEnabled = NO;
self.multipleTouchEnabled = NO;
User interaction should probably stay enabled with MapView even when there aren't any touch event listeners attached.

Attachments

FileDateSize
app.js2011-04-15T02:54:16.000+0000795

Comments

  1. Stephen Tramer 2012-07-25

    Cannot reproduce in SDK 2.2.0.014b86f, iPhone Sim 5.1.

JSON Source