{ "id": "61511", "key": "TIMOB-879", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "11224", "name": "Release 1.4.0", "archived": true, "released": true, "releaseDate": "2010-07-16" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2011-04-17T01:54:32.000+0000", "created": "2011-04-15T02:38:26.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "ipad", "orientationmodes" ], "versions": [], "issuelinks": [], "assignee": { "name": "bfreedman(atappcelerator)", "key": "bfreedman(atappcelerator)", "displayName": "bfreedman (at appcelerator)", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2011-04-17T01:54:32.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "{html}
Put this in app.js
\nTitanium.UI.iPhone.statusBarHidden = true;
\nvar webView = Titanium.UI.createWebView({url:'http://google.com'});
\nvar win = Titanium.UI.createWindow({fullscreen: true});
win.orientationModes = [
\nTitanium.UI.PORTRAIT,\nTitanium.UI.UPSIDE_PORTRAIT
\n
\n];
\nwin.add(webView);
\nwin.open();
I know that there would be no reason to limit orientationModes\nfor displaying google.
\nHowever, I am building a two player board game (like chess) in\nHTML/JavaScript.
\nThe idea is to replicate a real board with both players sitting\nat each end of the ipad. It doesn't make sense for the board to be\nan any orientation other than portrait - so ideally I need to be\nable to lock the orientation to PORTRAIT or UPSIDE_PORTRAIT
\nHunting through he docs I see there is a way to do this with\nwin.orientationModes, but it doesn't work in the case outlined\nabove.
\nI wonder if it may be that Titanium.UI.createWebView also needs\norientationModes?
\nI've tested in the simulator and on an ipad, same issue in both\nplaces.
\nScreen shot attached.
I'm not sure who the general public should assign tickets to, so\nI assigned it to Bill Dawson 'cos your name came up a lot!
This also appears to be an issue on Android with the 1.3 Ti\nSDK.
Note that setting the orientation mode works fine in Ti 1.2, but\nwas broken in 1.3.
\nIs a fix scheduled for 1.4?
This appears to be a duplicate of a bug that either Blain or I\nfixed, relating to orientation on the iPad. With the provided test\ncode I was able to get the window to orient only when in one of the\nportrait-style modes, which seems to be what you want.
\nIf this is still a problem with Android, I'd create a separate\nticket for that. They may also have been working on orientation\nissues, I'm not sure.