Change tab title on Android?
For starters I need to say that this is my first day developing with Titanium. But I haven't found any answer to how to accomplish this after spent way too much time googling the issue.
I have a problems trying to change a tab's title dynamically.
Extract from the code:
var tab1 = Titanium.UI.createTab({
title:"some tab",
window:win
});
// [..]
var textfield = Titanium.UI.createTextField({
color:'#336699',
value:"Tab title",
height:35,
width:300,
borderStyle:Titanium.UI.INPUT_BORDERSTYLE_ROUNDED
});
// Change the tab's title to textfield.value
textfield.addEventListener("change", function(e) {
tab1.title = e.value;
});
win.add(textfield);
This works perfectly fine in the iPhone-emulator, but it doesn't work in Android (APIs 1.6). Is it possible to change a tab's title dynamically on the Android? If it is, how?
6 Answers
-
Accepted Answer
It's not possible on Android. At some point we may release a different tab control, but currently you can't change any aspect of the group once it has been created.
-
Hi, may I know have this been fixed? I'm working on android app, need to change the tab title dynamically after user change language. In iphone not problem, but cannot do that in android… Please help.
-
Same problem for me. Any idea on how to change the tab title dynamically?
-
Is this now possible in any way?
It's a necessary feature for multilanguage apps… -
Has anyone been able to solve this or come up with a good workaround? The closest workaround I've heard so far was to close and re-open the tab group. Unfortunately, this causes my application to lock up for some reason. Perhaps it's because my tab group is defined within my app.js file? Please see my related question on stackoverflow. Thanks.
-
They opened a new feature request on JIRA for it. I would suggest you all put a watch to that JIRA ticket, so they see how many people want this feature:
http://jira.appcelerator.org/browse/TIMOB-6144