[TIMOB-26288] Android: Add ability to hide/show back button on Window
GitHub Issue | n/a |
---|---|
Type | Improvement |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2018-11-13T19:24:56.000+0000 |
Affected Version/s | Release 7.1.0 |
Fix Version/s | Release 8.0.0 |
Components | n/a |
Labels | n/a |
Reporter | Hans Knöchel |
Assignee | Gary Mathews |
Created | 2018-08-11T22:47:30.000+0000 |
Updated | 2018-11-13T19:24:56.000+0000 |
Description
We implemented the ability to hide the back-button on iOS (enabled by default) via TIMOB-25871. For Android, the back-button (home indicator) is not shown, but for parity sake, we should make this toggleable (on creation only).
Right now, the following needs to done for
every
sub-window:
function onOpen() {
const actionBar = $.window.getActivity().getActionBar();
if (actionBar !== null) {
actionBar.displayHomeAsUp = true;
actionBar.onHomeIconItemSelected = close;
}
}
Having a property and doing this internally would be a huge cross-platform shared parity-code improvement, especially for larger scaled apps. On long-term, this should part of the Ti.UI.NavigationWindow
effort, but I think this did not gain much love so far.
Android navigation window will support this.