{ "id": "65734", "key": "TIMOB-4205", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "11355", "description": "Mobile 1.8.0 M02", "name": "Sprint 2011-23", "archived": true, "released": true, "releaseDate": "2011-06-13" }, { "id": "11570", "description": "", "name": "Release 1.7.2", "archived": true, "released": true, "releaseDate": "2011-07-21" }, { "id": "11331", "description": "", "name": "Release 1.8.0", "archived": true, "released": true, "releaseDate": "2011-10-31" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2011-06-13T08:43:55.000+0000", "created": "2011-05-24T15:17:36.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [], "versions": [ { "id": "11244", "name": "Release 1.7.0", "archived": true, "released": true, "releaseDate": "2011-06-13" } ], "issuelinks": [], "assignee": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "updated": "2011-07-08T13:35:45.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" } ], "description": "h1. Problem\r\nGiven a map view, if you call \"selectAnnotation\" on a particular annotation, the map will automatically center on that annotation. This is a problem if you don't want it to automatically do this. It's also an inconsistency with iOS.\r\n\r\nh2. Solution\r\nProvide an argument to selectAnnotation that can disable this behavior. Something like \"doNotAutoCenter\".\r\n\r\nh2. Sample Code\r\nThe following app.js should select the annotation on the map and bump the map up north of the annotation. With Android's current behavior, it will center on the annotation.\r\n{code:title=app.js}\r\nvar win = Ti.UI.createWindow({ backgroundColor: '#fff' });\r\nvar map = Ti.Map.createView({\r\n mapType: Ti.Map.STANDARD_TYPE,\r\n regionFit: true\r\n});\r\nvar annotation = Ti.Map.createAnnotation({\r\n latitude: 59.93473,\r\n longitude: 10.760797,\r\n title: 'Print House AS',\r\n subtitle: 'Sandakerveien 24 C Bygg A2, 0473 Oslo',\r\n animate: true,\r\n pincolor: Ti.Map.ANNOTATION_PURPLE\r\n});\r\nmap.addAnnotation(annotation);\r\nmap.selectAnnotation(annotation);\r\nmap.setLocation({ latitude: 60, longitude: 10.760797, latitudeDelta: 0.035, longitudeDelta: 0.035 });\r\n\r\nwin.add(map);\r\nwin.open();\r\n{code}\r\n\r\nh2. Associated Helpdesk Ticket\r\nhttp://support-admin.appcelerator.com/display/RSN-92979-828", "attachment": [ { "id": "21051", "filename": "app.js", "author": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "created": "2011-06-09T11:59:12.000+0000", "size": 629, "mimeType": "application/x-javascript" }, { "id": "19748", "filename": "tsDefault.zip", "author": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "created": "2011-06-07T10:56:55.000+0000", "size": 5208270, "mimeType": "application/zip" } ], "flagged": false, "summary": "Android: Map Centers on selectAnnotation", "creator": { "name": "dtoth", "key": "dtoth", "displayName": "Dawson Toth", "active": true, "timeZone": "America/New_York" }, "subtasks": [], "reporter": { "name": "dtoth", "key": "dtoth", "displayName": "Dawson Toth", "active": true, "timeZone": "America/New_York" }, "environment": null, "comment": { "comments": [ { "id": "147047", "author": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "body": "test app showing the toggle behavior for centering on annotation via selectAnnotation call", "updateAuthor": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "created": "2011-06-07T10:56:55.000+0000", "updated": "2011-06-07T10:56:55.000+0000" }, { "id": "156348", "author": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "body": "test app.js modified from original test case that sets the center property to false", "updateAuthor": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "created": "2011-06-09T11:59:12.000+0000", "updated": "2011-06-09T11:59:12.000+0000" }, { "id": "156586", "author": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Verified with master.", "updateAuthor": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-06-13T08:43:55.000+0000", "updated": "2011-06-13T08:43:55.000+0000" }, { "id": "157709", "author": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "body": "merged onto 1_7_X", "updateAuthor": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-06-23T17:26:02.000+0000", "updated": "2011-06-23T17:26:02.000+0000" }, { "id": "159062", "author": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Verified fixed using sample code set to both \"true\" and \"False\" with Xoom 3.1 and Droid 1, 2.2.1. SDKs 1.7.2 r3d44999e and 1.8.0 r4b694252.", "updateAuthor": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-07-08T13:35:45.000+0000", "updated": "2011-07-08T13:35:45.000+0000" } ], "maxResults": 5, "total": 5, "startAt": 0 } } }