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 30BC2E535 for ; Fri, 18 Jan 2013 02:00:27 +0000 (UTC) Received: (qmail 30645 invoked by uid 500); 18 Jan 2013 02:00:27 -0000 Delivered-To: apmail-cordova-commits-archive@cordova.apache.org Received: (qmail 30628 invoked by uid 500); 18 Jan 2013 02:00:27 -0000 Mailing-List: contact commits-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: callback-dev@cordova.apache.org Delivered-To: mailing list commits@cordova.apache.org Received: (qmail 30621 invoked by uid 99); 18 Jan 2013 02:00:27 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 18 Jan 2013 02:00:27 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id CDA48819507; Fri, 18 Jan 2013 02:00:26 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: agrieve@apache.org To: commits@cordova.apache.org X-Mailer: ASF-Git Admin Mailer Subject: spec commit: Add User-Agent display and PDF test to InAppBrowser Message-Id: <20130118020026.CDA48819507@tyr.zones.apache.org> Date: Fri, 18 Jan 2013 02:00:26 +0000 (UTC) Updated Branches: refs/heads/master 654a3ef1f -> 09bfd9381 Add User-Agent display and PDF test to InAppBrowser Project: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/repo Commit: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/commit/09bfd938 Tree: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/tree/09bfd938 Diff: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/diff/09bfd938 Branch: refs/heads/master Commit: 09bfd9381e6b5bc03ad6c925030f4d8075dbe6a2 Parents: 654a3ef Author: Andrew Grieve Authored: Thu Jan 17 20:59:11 2013 -0500 Committer: Andrew Grieve Committed: Thu Jan 17 20:59:11 2013 -0500 ---------------------------------------------------------------------- inappbrowser/index.html | 10 ++++++++++ inappbrowser/local.html | 15 +++++++++++---- inappbrowser/local.pdf | Bin 0 -> 8568 bytes index.html | 1 + main.js | 1 + 5 files changed, 23 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/09bfd938/inappbrowser/index.html ---------------------------------------------------------------------- diff --git a/inappbrowser/index.html b/inappbrowser/index.html index 05a4338..6a6d71e 100644 --- a/inappbrowser/index.html +++ b/inappbrowser/index.html @@ -42,6 +42,11 @@ deviceReady = true; console.log("Device="+device.platform+" "+device.version); }, false); + function updateUserAgent() { + document.getElementById("user-agent").textContent = navigator.userAgent; + } + updateUserAgent(); + window.setInterval(updateUserAgent, 1500); window.setTimeout(function() { if (!deviceReady) { alert("Error: Apache Cordova did not initialize. Demo will not run correctly."); @@ -58,7 +63,9 @@
Make sure http://www.google.com is white listed Make sure http://www.apple.com is not in the white list +

User-Agent:

+
Back

Local URL

Default: CordovaWebView
Target=Self: CordovaWebView
@@ -80,6 +87,9 @@
Target=Blank: InAppBrowser
Target=Random: InAppBrowser
Target=Random, no location bar: InAppBrowser
+

PDF URL

+
Remote URL
+
Local URL

Back
http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/09bfd938/inappbrowser/local.html ---------------------------------------------------------------------- diff --git a/inappbrowser/local.html b/inappbrowser/local.html index 7e24aae..082d603 100644 --- a/inappbrowser/local.html +++ b/inappbrowser/local.html @@ -27,14 +27,21 @@ Cordova Mobile Spec - + -

InAppBrowser - Local URL

You have successfully loaded a local URL -
+ +
User-Agent =

Back
- + + http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/09bfd938/inappbrowser/local.pdf ---------------------------------------------------------------------- diff --git a/inappbrowser/local.pdf b/inappbrowser/local.pdf new file mode 100644 index 0000000..b54f1b7 Binary files /dev/null and b/inappbrowser/local.pdf differ http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/09bfd938/index.html ---------------------------------------------------------------------- diff --git a/index.html b/index.html index 502450a..464ccf8 100644 --- a/index.html +++ b/index.html @@ -41,6 +41,7 @@

Model:

Width: , Height: , Color Depth:

+

User-Agent:

Automatic Test Accelerometer http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/09bfd938/main.js ---------------------------------------------------------------------- diff --git a/main.js b/main.js index cc4d97d..66c1bd3 100644 --- a/main.js +++ b/main.js @@ -159,4 +159,5 @@ function init() { // doesn't have a scroll button // document.addEventListener("touchmove", preventBehavior, false); document.addEventListener("deviceready", deviceInfo, true); + document.getElementById("user-agent").textContent = navigator.userAgent; }