{ "id": "152652", "key": "AC-1609", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "7", "description": "", "name": "Invalid" }, "resolutiondate": "2015-12-08T09:15:10.000+0000", "created": "2015-11-04T16:15:56.000+0000", "labels": [], "versions": [], "issuelinks": [], "assignee": { "name": "mrahman", "key": "mrahman", "displayName": "Mostafizur Rahman", "active": true, "timeZone": "Asia/Dhaka" }, "updated": "2016-03-08T07:38:05.000+0000", "status": { "description": "A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.", "name": "Resolved", "id": "5", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "14544", "name": "Alloy", "description": "Please enter tickets related to the Alloy here." } ], "description": "When using a _TabGroup_ within a _NavigationWindow_, the _RightNavButtons_ of any _Window_ within the _TabGroup_ do not appear in the navigation bar. I've included example code of the issue below. Upon clicking the \"Open Window\" button on the main view, the _TabGroup_ opens and the *< Back* option appears in the navigation bar, but the _RightNavButtons_ do not appear. I've found that If I remove the _NavigationWindow_ and use a standard _Window_ element in index.xml (and update index.js to use {{view.open()}} instead of {{$.nav.openWindow(view)}}), then the _RightNavButtons_ will be visible for the _Window_ in that _TabGroup_. \r\n\r\nI'm using an alloy project that has 2 views; *index* and *tabs*. All of the relevant code to reproduce the issue is as follows:\r\n\r\n*index.xml*\r\n{code}\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n{code}\r\n\r\n\r\n*index.js*\r\n\r\n{code}\r\n$.nav.open(); \r\nfunction open()\r\n{\r\n var view = Alloy.createController(\"tabs\").getView();\r\n $.nav.openWindow(view); \r\n}\r\n{code}\r\n\r\n*tabs.xml*\r\n{code}\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n{code}", "attachment": [], "flagged": false, "summary": "Cannot see RightNavButtons with TabGroup inside NavigationWindow", "creator": { "name": "bachmakm", "key": "bachmakm", "displayName": "Kristen Bachman", "active": true, "timeZone": "America/Havana" }, "subtasks": [], "reporter": { "name": "bachmakm", "key": "bachmakm", "displayName": "Kristen Bachman", "active": true, "timeZone": "America/Havana" }, "environment": "OS: Mac OS X El Capitan, 10.11.1\r\nMobile Platform(s): iOS 9.1 - iPhone 5s\r\nTitanium SDK: 5.0.2.GA\r\nAppcelerator Studio: 4.3.3.201510212245-21102015224619", "comment": { "comments": [ { "id": "369067", "author": { "name": "aislam", "key": "aislam", "displayName": "Aminul Islam", "active": false, "timeZone": "Etc/GMT-6" }, "body": "Hi , \r\nThanks for your concern. TabGroups create their own controller when you open windows ON the tab. But when you use {{$.nav.openWindow(view)}} , NavigationWindow hide the TabGroup's *RightNavButtons* .\r\nThis is not a bug.\r\n\r\nThanks", "updateAuthor": { "name": "aislam", "key": "aislam", "displayName": "Aminul Islam", "active": false, "timeZone": "Etc/GMT-6" }, "created": "2015-11-05T07:54:48.000+0000", "updated": "2015-11-05T07:56:26.000+0000" }, { "id": "369104", "author": { "name": "bachmakm", "key": "bachmakm", "displayName": "Kristen Bachman", "active": true, "timeZone": "America/Havana" }, "body": "Hi Aminul,\r\n\r\nThanks for responding so quickly. I've done a considerable amount of API digging and trial and error, and it seems that I do not have control over the visibility of the _RightNavButtons_ when they are in a _TabGroup_ that is opened by a _NavigationWindow_. _RightNavButtons_ will only appear if the _NavigationWindow_ directly opens a _Window_. For example, if I change *tabs.xml* (from above) to the example below, then the _RightNavButtons_ are visible.\r\n\r\nNew *tabs.xml*:\r\n{code}\r\n\r\n\t\r\n\t\t\r\n\t\t\r\n\t\r\n\t\r\n\r\n{code} \r\n\r\n\r\nIn addition, according to the API documentation, neither _Tab_ nor _TabGroup_ objects support the use of _RightNavButtons_ as they do not inherit from {{Titanium.UI.Window}}. Although _NavigationWindow_ has a {{rightNavButtons}} property, setting that property does not make the _rightNavButtons_ visible. In other words, in index.js, adding the following code has no effect on the navigation bar; no \"test\" button appears: {code}$.nav.setRightNavButtons(Ti.UI.createButton({title:\"test\"}));{code} \r\n\r\nTo summarize, it seems that _RightNavButtons_ will only appear when a _NavigationWindow_ directly opens a _Window_ that has those _RightNavButtons_. However, _RightNavButtons_ will NOT appear when a _NavigationWindow_ opens a _TabGroup_ containing _Windows_ that have _RightNavButtons_. \r\n\r\nIs it possible to make the _RightNavButtons_ visible in the latter scenario? If so, how?", "updateAuthor": { "name": "bachmakm", "key": "bachmakm", "displayName": "Kristen Bachman", "active": true, "timeZone": "America/Havana" }, "created": "2015-11-05T18:14:52.000+0000", "updated": "2015-11-05T18:20:36.000+0000" }, { "id": "371347", "author": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "body": "Hello [~bachmakm], The reason you can't see the RightNavButtons is your navigation bar is opening under the tab bar. Why do you need the navigation bar? Each Tab already has a Navigation Controller, so adding a NavigationWindow is simply wrong. Please follow this community post and try on Malcolm Hollingsworth's answer about [tackling navigation window in tab group alloy|https://developer.appcelerator.com/question/175579/tackle-navigation-window-in-tab-group-alloy]\r\n", "updateAuthor": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "created": "2015-11-24T15:12:17.000+0000", "updated": "2015-11-24T15:12:17.000+0000" }, { "id": "371670", "author": { "name": "bachmakm", "key": "bachmakm", "displayName": "Kristen Bachman", "active": true, "timeZone": "America/Havana" }, "body": "Hi Sharif, I looked at link that you had posted in your comment above and that scenario is slightly different than mine. In the community post, the user is trying to open a NavigationWindow within a TabGroup, whereas in my case, I am trying to open a TabGroup within a NavigationWindow. The proposed solution in the community solution is to save a reference to the Tab in the TabGroup and open any new Window objects within that referenced Tab. Unfortunately, this is not a viable solution for me. In my case, I do not see 2 navigation bars; I see one navigation bar, and I understand that the TabGroup navbar may be hidden underneath the NavigationWindow navbar, but I want to manipulate what appears in the RightNavButtons section of the visible navigation bar. Is there not a way to do this? ", "updateAuthor": { "name": "bachmakm", "key": "bachmakm", "displayName": "Kristen Bachman", "active": true, "timeZone": "America/Havana" }, "created": "2015-11-30T19:47:01.000+0000", "updated": "2015-11-30T19:47:01.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }