Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-13044] Android: Custom AndroidManifest is messing with picker in Samsung S3

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionDuplicate
Resolution Date2013-03-18T17:35:29.000+0000
Affected Version/sRelease 3.0.2
Fix Version/sn/a
ComponentsAndroid
LabelsSupportTeam
ReporterMauro Parra-Miranda
AssigneeIngo Muschenetz
Created2013-03-13T05:30:33.000+0000
Updated2017-03-21T18:51:09.000+0000

Description

Problem Description

When using a custom AndroidManifest.xml (included here), the picker in Samsung S3 looks wrong (image attached).

Steps to reproduce.

1. Create a new app. 2. Paste this to app.js:
var win = Ti.UI.createWindow();
win.backgroundColor = 'black';

var picker = Ti.UI.createPicker();

var data = [];
data[0] = Ti.UI.createPickerRow({
	title : 'Bananas',
	custom_item : 'b'
});
data[1] = Ti.UI.createPickerRow({
	title : 'Strawberries',
	custom_item : 's'
});
data[2] = Ti.UI.createPickerRow({
	title : 'Mangos',
	custom_item : 'm'
});
data[3] = Ti.UI.createPickerRow({
	title : 'Grapes',
	custom_item : 'g'
});

// turn on the selection indicator (off by default)
picker.selectionIndicator = true;

picker.add(data);

win.add(picker);

picker.setSelectedRow(0, 1, true);

var label = Ti.UI.createLabel({
	text : 'Make a move',
	top : 6,
	width : 'auto',
	height : 'auto',
	textAlign : 'center',
	color : 'white'
});
win.add(label);

var button = Ti.UI.createButton({
	title : 'Set to Grapes',
	top : 34,
	width : 120,
	height : 30
});
win.add(button);

button.addEventListener('click', function() {
	// column, row, animated (optional)
	picker.setSelectedRow(0, 3, true);
});

picker.addEventListener('change', function(e) {
	Ti.API.info("You selected row: " + e.row + ", column: " + e.column + ", custom_item: " + e.row.custom_item);
	label.text = "row index: " + e.rowIndex + ", column index: " + e.columnIndex;
});

picker.setSelectedRow(0, 1, false);

win.open();
3. Add this custom AndroidManifest.xml
<?xml version="1.0" ?>
<manifest android:versionCode="1" android:versionName="1.0.0" package="com.xyz.abc" xmlns:android="http://schemas.android.com/apk/res/android">
	<supports-screens android:anyDensity="false"/>
	<uses-sdk android:minSdkVersion="8"/>
	<!-- TI_MANIFEST -->
	<application android:debuggable="false" android:icon="@drawable/appicon" android:label="Hidden Name" android:name="HiddennameApplication">
		<activity android:alwaysRetainTaskState="true" android:configChanges="orientation|keyboardHidden" android:label="Hidden Name" android:name=".HiddennameActivity"  android:theme="@android:style/Theme.Translucent" android:screenOrientation="portrait">
			<intent-filter>
				<action android:name="android.intent.action.MAIN"/>
				<category android:name="android.intent.category.LAUNCHER"/>
			</intent-filter>
		</activity>
		<activity android:configChanges="orientation|keyboardHidden" android:launchMode="singleTask" android:name="ti.modules.titanium.map.TiMapActivity" android:screenOrientation="portrait"/>
		<uses-library android:name="com.google.android.maps"/>
		<activity android:configChanges="orientation|keyboardHidden" android:name="org.appcelerator.titanium.TiActivity" android:screenOrientation="portrait"/>
		<activity android:configChanges="orientation|keyboardHidden" android:name="org.appcelerator.titanium.TiTranslucentActivity" android:theme="@android:style/Theme.Translucent" android:screenOrientation="portrait"/>
		<activity android:configChanges="orientation|keyboardHidden" android:name="org.appcelerator.titanium.TiModalActivity" android:theme="@android:style/Theme.Translucent" android:screenOrientation="portrait"/>
		<activity android:configChanges="orientation|keyboardHidden" android:name="ti.modules.titanium.ui.TiTabActivity" android:screenOrientation="portrait"/>
		<activity android:configChanges="orientation|keyboardHidden" android:name="ti.modules.titanium.ui.android.TiPreferencesActivity" android:screenOrientation="portrait"/>
		<service android:exported="false" android:name="org.appcelerator.titanium.analytics.TiAnalyticsService"/>
	</application>
	<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
	<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
	<uses-permission android:name="android.permission.ACCESS_MOCK_LOCATION"/>
	<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
	<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
	<uses-permission android:name="android.permission.INTERNET"/>
	<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
</manifest>
4. Run this in Samsung S3

Attachments

FileDateSize
s3.png2013-03-13T05:30:33.000+000086647

Comments

  1. Ingo Muschenetz 2013-03-18

    Duplicate of linked issue.
  2. Lee Morris 2017-03-21

    Closing ticket as duplicate.

JSON Source