Titanium JIRA Archive
Appcelerator Community (AC)

[AC-5548] iOS: leftNavButton on window renders after native control

GitHub Issuen/a
TypeBug
Priorityn/a
StatusResolved
ResolutionDuplicate
Resolution Date2018-02-07T21:04:05.000+0000
Affected Version/sn/a
Fix Version/sn/a
Componentsn/a
Labelsn/a
ReporterBrian García
AssigneeShak Hossain
Created2018-01-25T15:19:15.000+0000
Updated2018-02-09T14:25:49.000+0000

Description

Setting leftNavButton property on a window causes the effect seen on the gif

Attachments

FileDateSize
close.png2018-02-09T14:25:49.000+00001094
LeftNavButton-issue.gif2018-01-25T15:18:49.000+000039872

Comments

  1. Sharif AbuDarda 2018-02-05

    Hello [~bgarcia], Thanks for sharing with us.Please attach a sample test code in here that reproduces the issue. Also, provide the SDK and CLI version you are testing on. Thanks.
  2. Brian García 2018-02-09

    Why it's marked as duplicated without a reference to the original issue? here is the snippet requested:
       var win2 = Titanium.UI.createWindow({
           backgroundColor: 'red',
           title: 'Red Window'
       });
       
       var win1 = Titanium.UI.iOS.createNavigationWindow({
          window: win2
       });
       
       var win3 = Titanium.UI.createWindow({
           backgroundColor: 'blue',
           title: 'Blue Window',
           leftNavButton:Ti.UI.createButton({image:"/images/close.png"})
       });
       
       var button = Titanium.UI.createButton({
           title: 'Open Blue Window'
       });
       button.addEventListener('click', function(){
           win1.openWindow(win3, {animated:true});
       });
       
       win2.add(button);
       var button2 = Titanium.UI.createButton({
           title: 'Close Blue Window'
       });
       button2.addEventListener('click', function(){
           win1.closeWindow(win3, {animated:false}); //win3.close() will also work!!
       });
       
       win3.add(button2);
       win1.open();
       

JSON Source