Titanium JIRA Archive
Appcelerator Community (AC)

[AC-5448] Ti.UI.iOS.setStatusBarBackgroundColor takes only color name as parameter

GitHub Issuen/a
TypeBug
Priorityn/a
StatusResolved
ResolutionDone
Resolution Date2017-12-15T21:30:13.000+0000
Affected Version/sAppcelerator Studio 4.5.0
Fix Version/sn/a
ComponentsAlloy
Labelsios
ReporterTony Lau
AssigneeShak Hossain
Created2017-12-12T06:34:25.000+0000
Updated2017-12-15T21:30:13.000+0000

Description

No effect if using hex value of color on Ti.UI.iOS.setStatusBarBackgroundColor(); e.g. Ti.UI.iOS.setStatusBarBackgroundColor("#0D0D0D"); Works only if using predefined color names. 'aqua', 'black', 'blue', 'brown', 'cyan', 'darkgray', 'fuchsia', 'gray', 'green', 'lightgray', 'lime', 'magenta', 'maroon', 'navy', 'olive', 'orange', 'pink', 'purple', 'red', 'silver', 'teal', 'white', 'yellow'

Comments

  1. Mostafizur Rahman 2017-12-12

    Hello, Tested the issue and unable to reproduce this using the SDK 7.0.0.GA on iOS Simulator: iPhone X using the sample code below. *Test Environment:* Appcelerator Command-Line Interface, version 7.0.0 Mac OS X 10.13.1 Architecture 64bit CPUs 4 Memory 8589934592 Axway Appcelerator Studio, build: 5.0.0.201712081732 Node.js Version = 8.9.1 npm Version = 5.5.1 SDK 7.0.0.GA *Test steps:* 1. Open studio and create a classic project 2. Run the app with the sample code below 3. Status bar is displaying the background color using hex value *Test Code:* index.xml
       <Alloy>
       
       <Window class="container" backgroundColor="Pink">
       
       </Window>
       
       </Alloy>
       
    *index.js*
       Ti.UI.iOS.setStatusBarBackgroundColor("#51a01c");
       
       $.index.open();
       
       
    *Output:*[Screenshot](https://s18.postimg.org/lilqkd12x/Simulator_Screen_Shot_-_i_Phone_X_-_2017-12-12_at_15.18.04.png) Can you please try to update your environment , test the sample code above and let us know how it goes. Best
  2. Tony Lau 2017-12-15

    Upgraded to SDK 7.0.0, Axway Appcelerator Studio 5.0.0 Issue not found. Hurray!

JSON Source