Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-16118] iOS: NavigationWindow navigation bar does not animate correctly when closing context

GitHub Issuen/a
TypeBug
Priorityn/a
StatusOpen
ResolutionUnresolved
Affected Version/sRelease 3.2.0
Fix Version/sn/a
ComponentsiOS
Labelsn/a
ReporterSeth Benjamin
AssigneeUnknown
Created2013-12-23T18:25:42.000+0000
Updated2018-02-28T20:03:19.000+0000

Description

When pulling from the left-most side of a navigation window or closing a context (navigation window child) the navigation bar disappears immeidately due to setupWindowDecorations in TiUIWindowProxy. L932 is the culprit here, animated is effectively set to NO while it should be YES. Making this change fixes the issue.

Comments

  1. Ritu Agrawal 2013-12-26

    Thanks for suggesting the fix. It is much appreciated. It would speed up the process if you can provide us a test case that reproduces the problem and it would help us to evaluate the suggested fix.
  2. Mostafizur Rahman 2013-12-29

    We have not been able to reproduce this issue with iOS 7.0.3 and Titanium 3.2.0.GA SDK. Can you please take a look at the code below and let us know how your use case differs from the code below? We need a simple test case to troubleshoot this issue further.

    Test Environment

    Mac OSX 10.8.5, Titanium SDK 3.2.0 GA Titanium CLI 3.2.0 iOS Simulator 7.0.3

    Test Code

       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'
       });
       
       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 : true
       	});
       	//win3.close() will also work!!
       });
       
       win3.add(button2);
       win1.open(); 
       
  3. Seth Benjamin 2013-12-30

    Sorry for the delayed response. You can see the issue by making *win2* have the *navBarHidden* prop set to *true*. Everything else can remain the same. For brevity here is the updated test-case:
       var win2 = Titanium.UI.createWindow({
           backgroundColor : 'red',
           title : 'Red Window',
           navBarHidden : true
       });
       
       var win1 = Titanium.UI.iOS.createNavigationWindow({
           window : win2
       });
       
       var win3 = Titanium.UI.createWindow({
           backgroundColor : 'blue',
           title : 'Blue Window'
       });
       
       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 : true
           });
           //win3.close() will also work!!
       });
       
       win3.add(button2);
       win1.open();
       
  4. Ritu Agrawal 2014-01-02

    Moving this ticket to engineering as we can reproduce the issue with navBarHidden property set to true.
  5. Shameer Jan 2014-08-20

    Issue reproduces on both SDK version 3.2.0 and 3.4.0 (Unreleased) Titanium Command-Line Interface, CLI version 3.3.0, Titanium SDK version 3.4.0.GA Titanium SDK version 3.2.0.GA iOS SDK: 7.1 iOS iPhone: 7.1

JSON Source