Return-Path: X-Original-To: apmail-cordova-commits-archive@www.apache.org Delivered-To: apmail-cordova-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id F111518AE4 for ; Wed, 27 May 2015 23:03:19 +0000 (UTC) Received: (qmail 58391 invoked by uid 500); 27 May 2015 23:03:19 -0000 Delivered-To: apmail-cordova-commits-archive@cordova.apache.org Received: (qmail 58369 invoked by uid 500); 27 May 2015 23:03:19 -0000 Mailing-List: contact commits-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list commits@cordova.apache.org Received: (qmail 58360 invoked by uid 99); 27 May 2015 23:03:19 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 27 May 2015 23:03:19 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id B63A0E0419; Wed, 27 May 2015 23:03:19 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: shazron@apache.org To: commits@cordova.apache.org Message-Id: X-Mailer: ASF-Git Admin Mailer Subject: cordova-lib git commit: CB-8783 - 'default' value for Orientation does not support both landscape and portrait orientations. (new 'all' value) Date: Wed, 27 May 2015 23:03:19 +0000 (UTC) Repository: cordova-lib Updated Branches: refs/heads/master c33d9193d -> 518ffa46c CB-8783 - 'default' value for Orientation does not support both landscape and portrait orientations. (new 'all' value) Project: http://git-wip-us.apache.org/repos/asf/cordova-lib/repo Commit: http://git-wip-us.apache.org/repos/asf/cordova-lib/commit/518ffa46 Tree: http://git-wip-us.apache.org/repos/asf/cordova-lib/tree/518ffa46 Diff: http://git-wip-us.apache.org/repos/asf/cordova-lib/diff/518ffa46 Branch: refs/heads/master Commit: 518ffa46c80e1e167ff7b1e3e1ccc8fe2a04cd58 Parents: c33d919 Author: Shazron Abdullah Authored: Wed May 27 16:03:17 2015 -0700 Committer: Shazron Abdullah Committed: Wed May 27 16:03:17 2015 -0700 ---------------------------------------------------------------------- .../spec-cordova/metadata/parserhelper/preferences.spec.js | 3 ++- cordova-lib/src/cordova/metadata/ios_parser.js | 5 +++++ cordova-lib/src/cordova/metadata/parserhelper/preferences.js | 4 +++- 3 files changed, 10 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cordova-lib/blob/518ffa46/cordova-lib/spec-cordova/metadata/parserhelper/preferences.spec.js ---------------------------------------------------------------------- diff --git a/cordova-lib/spec-cordova/metadata/parserhelper/preferences.spec.js b/cordova-lib/spec-cordova/metadata/parserhelper/preferences.spec.js index e44b0ac..88368df 100644 --- a/cordova-lib/spec-cordova/metadata/parserhelper/preferences.spec.js +++ b/cordova-lib/spec-cordova/metadata/parserhelper/preferences.spec.js @@ -35,7 +35,8 @@ describe('preferences', function() { expect(preferences.ORIENTATION_DEFAULT).toEqual('default'); expect(preferences.ORIENTATION_PORTRAIT).toEqual('portrait'); expect(preferences.ORIENTATION_LANDSCAPE).toEqual('landscape'); - expect(preferences.ORIENTATION_GLOBAL_ORIENTATIONS).toEqual([ 'default', 'portrait', 'landscape' ]); + expect(preferences.ORIENTATION_ALL).toEqual('all'); + expect(preferences.ORIENTATION_GLOBAL_ORIENTATIONS).toEqual([ 'default', 'portrait', 'landscape', 'all' ]); }); }); http://git-wip-us.apache.org/repos/asf/cordova-lib/blob/518ffa46/cordova-lib/src/cordova/metadata/ios_parser.js ---------------------------------------------------------------------- diff --git a/cordova-lib/src/cordova/metadata/ios_parser.js b/cordova-lib/src/cordova/metadata/ios_parser.js index ddb9fc2..32843ad 100644 --- a/cordova-lib/src/cordova/metadata/ios_parser.js +++ b/cordova-lib/src/cordova/metadata/ios_parser.js @@ -93,6 +93,11 @@ ios_parser.prototype.update_from_config = function(config) { infoPlist['UISupportedInterfaceOrientations'] = [ 'UIInterfaceOrientationLandscapeLeft', 'UIInterfaceOrientationLandscapeRight' ]; infoPlist['UISupportedInterfaceOrientations~ipad'] = [ 'UIInterfaceOrientationLandscapeLeft', 'UIInterfaceOrientationLandscapeRight' ]; break; + case 'all': + infoPlist['UIInterfaceOrientation'] = [ 'UIInterfaceOrientationPortrait' ]; + infoPlist['UISupportedInterfaceOrientations'] = [ 'UIInterfaceOrientationPortrait', 'UIInterfaceOrientationPortraitUpsideDown', 'UIInterfaceOrientationLandscapeLeft', 'UIInterfaceOrientationLandscapeRight' ]; + infoPlist['UISupportedInterfaceOrientations~ipad'] = [ 'UIInterfaceOrientationPortrait', 'UIInterfaceOrientationPortraitUpsideDown', 'UIInterfaceOrientationLandscapeLeft', 'UIInterfaceOrientationLandscapeRight' ]; + break; default: infoPlist['UIInterfaceOrientation'] = [ orientation ]; delete infoPlist['UISupportedInterfaceOrientations']; http://git-wip-us.apache.org/repos/asf/cordova-lib/blob/518ffa46/cordova-lib/src/cordova/metadata/parserhelper/preferences.js ---------------------------------------------------------------------- diff --git a/cordova-lib/src/cordova/metadata/parserhelper/preferences.js b/cordova-lib/src/cordova/metadata/parserhelper/preferences.js index 1906bc6..f645f9d 100644 --- a/cordova-lib/src/cordova/metadata/parserhelper/preferences.js +++ b/cordova-lib/src/cordova/metadata/parserhelper/preferences.js @@ -26,13 +26,15 @@ var events = require('../../../events'); var _ORIENTATION_DEFAULT = 'default'; var _ORIENTATION_PORTRAIT = 'portrait'; var _ORIENTATION_LANDSCAPE = 'landscape'; -var _ORIENTATION_GLOBAL_ORIENTATIONS = [ _ORIENTATION_DEFAULT, _ORIENTATION_PORTRAIT, _ORIENTATION_LANDSCAPE ]; +var _ORIENTATION_ALL = 'all'; +var _ORIENTATION_GLOBAL_ORIENTATIONS = [ _ORIENTATION_DEFAULT, _ORIENTATION_PORTRAIT, _ORIENTATION_LANDSCAPE, _ORIENTATION_ALL ]; module.exports = { ORIENTATION_DEFAULT: _ORIENTATION_DEFAULT, ORIENTATION_PORTRAIT: _ORIENTATION_PORTRAIT, ORIENTATION_LANDSCAPE: _ORIENTATION_LANDSCAPE, + ORIENTATION_ALL: _ORIENTATION_ALL, ORIENTATION_GLOBAL_ORIENTATIONS: _ORIENTATION_GLOBAL_ORIENTATIONS, /** --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org For additional commands, e-mail: commits-help@cordova.apache.org