[TIMOB-3549] Android: Table View leftImage Sizing Inconsistency with iOS
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Low |
Status | Closed |
Resolution | Won't Fix |
Resolution Date | 2017-08-16T01:25:27.000+0000 |
Affected Version/s | Release 1.6.2, Release 2.0.1 |
Fix Version/s | n/a |
Components | Android |
Labels | android, inconsistency, parity, rplist |
Reporter | Dawson Toth |
Assignee | Ingo Muschenetz |
Created | 2011-04-15T03:46:32.000+0000 |
Updated | 2017-08-16T01:25:27.000+0000 |
Description
Problem
On Android, the leftImage resizes the row to fit the dimensions of the image. But on iOS, the leftImage will resize to fit the row (so if the row is 20 pixels tall, the image will resize to be 20 pixels tall).
Solution
It would be great if the two platforms behaved the same with this property.
I personally think resizing is better behavior, because it seems like a more likely use case to me. I recognize that's highly subjective, though, and that there are implications to having resized images inside a table view row on Android.
Sample Code
The following, dropped in an app.js, shows the problem:
var win = Ti.UI.createWindow({ backgroundColor: '#fff' });
win.add(Ti.UI.createTableView({
data: [
{ leftImage: 'appicon.png', title: 'One' },
{ leftImage: 'appicon.png', title: 'Two' },
{ leftImage: 'appicon.png', title: 'Three' }
]
}));
win.open();
Tested On
Titanium SDK version: 1.6.2 (03/30/11 17:25 0243d42...)
RESIZES IMAGE on iPhone Simulator 4.2
RESIZES ROW on Android Samsung Epic 4G 2.2
Associated Helpdesk Ticket
http://support.appcelerator.com/tickets/TXA-23345-536">http://support.appcelerator.com/tickets/TXA-23345-536
Hit enter too soon... Tagged as an inconsistency (testing the waters with that) -- it's not really a defect, and it's not a feature. Just something different between the platform implementations.
Tested with 2.0.1GA2 on the iOS simulator and a Samsung Galaxy S2, this issue still exists. Instead of using 'appicon.png', change it to 'default.png', the result is a lot more obvious.
Closing due to inactivity. If this issue still exists, please raise a new ticket.