Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-18120] iOS: UI - iOS System Texture Color constants are not working

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionInvalid
Resolution Date2014-12-02T23:14:17.000+0000
Affected Version/sRelease 3.5.0
Fix Version/sn/a
ComponentsiOS
Labelsqe-3.5.0, regression
ReporterKajenthiran Velummaylum
AssigneeIngo Muschenetz
Created2014-12-02T09:58:33.000+0000
Updated2017-03-22T21:48:28.000+0000

Description

iOS System Texture Color constants are not working. For example, following constants are having no effect on the code. Ti.UI.iOS.COLOR_SCROLLVIEW_BACKGROUND Ti.UI.iOS.COLOR_VIEW_FLIPSIDE_BACKGROUND Ti.UI.iOS.COLOR_UNDER_PAGE_BACKGROUND This is a *regression* since it doesn't occur in 3.4.1 GA

Steps To Reproduce

1. Create a classic app using following code
function main(_window) {
	// this sets the background color of the master UIView (when there are no windows/tab groups on it)
	Titanium.UI.setBackgroundColor('#000');

	// create tab group
	var tabGroup = Titanium.UI.createTabGroup();

	//
	// create base UI tab and root window
	//
	var win1 = Titanium.UI.createWindow({
		title : 'SCROLLVIEW',
		backgroundColor : Ti.UI.iOS.COLOR_SCROLLVIEW_BACKGROUND
	});
	var tab1 = Titanium.UI.createTab({
		icon : 'KS_nav_views.png',
		title : 'SCROLLVIEW',
		window : win1
	});

	//
	// create controls tab and root window
	//
	var win2 = Titanium.UI.createWindow({
		title : 'VIEW_FLIPSIDE',
		backgroundColor : Ti.UI.iOS.COLOR_VIEW_FLIPSIDE_BACKGROUND
	});
	var tab2 = Titanium.UI.createTab({
		icon : 'KS_nav_ui.png',
		title : 'VIEW_FLIPSIDE',
		window : win2
	});

	//
	// create controls tab and root window
	//
	var win3 = Titanium.UI.createWindow({
		title : 'UNDER_PAGE',
		backgroundColor : Ti.UI.iOS.COLOR_UNDER_PAGE_BACKGROUND
	});
	var tab3 = Titanium.UI.createTab({
		icon : 'KS_nav_ui.png',
		title : 'UNDER_PAGE',
		window : win3
	});

	tabGroup.addTab(tab1);
	tabGroup.addTab(tab2);
	tabGroup.addTab(tab3);

	tabGroup.open();
}

var _window = Ti.UI.createWindow({backgroundColor:"white"});
_window.fullscreen = true;
_window.open();
main(_window);
2. Run the app 3. Click VIEW_FLIPSIDE 4. Click UNDER_PAGE

Actual Result

White background is shown for all steps

Expected Result

Step 2: Should see a textured gray background Step 3: Should see a textured dark gray background Step 4: Should see a textured light gray background

Comments

  1. Ingo Muschenetz 2014-12-02

    It appears we removed these. [~bhatfield], can you confirm?
  2. Benjamin Hatfield 2014-12-02

    [~ingo] Underlying APIs are marked deprecated for iOS 7. Marked as deprecated in the code for 3.5.0 but there is not doc update in the YAML files.
  3. Ingo Muschenetz 2014-12-02

    If they are marked deprecated, they should still work, right?
  4. Vishal Duggal 2014-12-02

    They work in the sense that your app will not crash but they have no specific values since those iOS constants have been deprecated in iOS7 and we no longer support older versions. All those constants now result in transparent color.
  5. Lee Morris 2017-03-22

    Closing ticket as invalid with reference to previous comments.

JSON Source