Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-12459] Android: optionsMenu items are incorrectly placed

GitHub Issuen/a
TypeBug
PriorityCritical
StatusClosed
ResolutionCannot Reproduce
Resolution Date2013-03-11T15:18:34.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsAndroid
Labelsactionbar, android, exalture, tabGroup
ReporterSteve Carpenter
AssigneeSunila
Created2013-01-16T05:40:05.000+0000
Updated2017-03-27T18:02:17.000+0000

Description

Steps to reproduce

1. Create a project in Studio using the tabbed application wizard, target SDK 3.0 2. Change tiapp.xml to target Android SDK 11 or higher, tool-api level 15 or higher 3. Titanium will replace old-style tabs with actionbar 4. Add an options menu to the root ApplicationWindow.js:
self.activity.onCreateOptionsMenu = function(e){
e.menu.clear();
saveSearch = e.menu.add({
title: 'Remove',
itemId : 1,
groupId : 0,
order : 0});
};

Result

The options icons is correctly placed in the bar, but selecting it results in the menu option label being offset too far to the right Tested on a Nexus 4, Jellybean 4.2.1 If I set the target SDK to lower than 11 and run the app again on the device, the old-style tabs return and the options menu is now located in the lower navigation bar, and works as expected.

Attachments

FileDateSize
Screenshot_2013-01-16-11-51-25.png2013-01-16T05:40:05.000+000027922

Comments

  1. Sunila 2013-03-11

    Tried with Google Nexus and Titanium SDK 3.1.0 The menu item shows up correctly.
  2. Lee Morris 2017-03-27

    Closing ticket as I am unable to reproduce this issue with the following environment; Pixel (7.1) MacOS 10.11.6 (15G31) Studio 4.8.1.201612050850 Ti SDK 6.0.3 GA Appc NPM 4.2.8 Appc CLI 6.1.0 Ti CLI 5.0.11 Alloy 1.9.5 Arrow 1.10.1 Xcode 8.2 (8C38) Node v4.6.0 Java 1.7.0_80

JSON Source