[TIMOB-10317] Android: Ti.Map.View crashes when inside TableView on scroll
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | High |
Status | Closed |
Resolution | Won't Fix |
Resolution Date | 2013-03-27T16:29:18.000+0000 |
Affected Version/s | Release 2.1.0, Release 2.1.1 |
Fix Version/s | n/a |
Components | Android |
Labels | api, exalture, parity |
Reporter | Michael Walsh |
Assignee | Ingo Muschenetz |
Created | 2012-07-19T18:39:35.000+0000 |
Updated | 2017-03-22T22:55:01.000+0000 |
Description
When embedding a Ti.Map.View inside a Ti.UI.TableViewRow on the Android platform, the app crashes after scrolling back to the map a second time. This does not occur on the iPhone platform.
Steps to reproduce.
Scroll down to view embedded MapView
Scroll back up to top of list, obscuring the MapView from the visible screen
Scroll back down to the MapView in the list
App crashes with 'MapView already created' exception
var mountainView = Titanium.Map.createAnnotation({
latitude:37.390749,
longitude:-122.081651,
title:"Appcelerator Headquarters",
subtitle:'Mountain View, CA',
pincolor:Titanium.Map.ANNOTATION_RED,
animate:true,
myid:1
});
var mapview = Titanium.Map.createView({
mapType: Titanium.Map.STANDARD_TYPE,
region: {latitude:33.74511, longitude:-84.38993,
latitudeDelta:0.01, longitudeDelta:0.01},
animate:true,
regionFit:true,
userLocation:true,
annotations:[mountainView],
height:300
});
var maprow = Ti.UI.createTableViewRow();
maprow.add(mapview);
var table = Ti.UI.createTableView();
table.setData([
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
Ti.UI.createTableViewRow({ title:'buffer row' }),
maprow
]);
var win = Ti.UI.createWindow();
win.add(table);
win.open();
Note that this is possible by using the new Google maps module on SDK 3.0.2 and above: https://marketplace.appcelerator.com/apps/5005?1856365980
Closing ticket as "Won't Fix".