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 07B1410A91 for ; Tue, 17 Dec 2013 20:32:58 +0000 (UTC) Received: (qmail 93143 invoked by uid 500); 17 Dec 2013 20:32:57 -0000 Delivered-To: apmail-cordova-commits-archive@cordova.apache.org Received: (qmail 93123 invoked by uid 500); 17 Dec 2013 20:32:57 -0000 Mailing-List: contact commits-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list commits@cordova.apache.org Received: (qmail 93116 invoked by uid 99); 17 Dec 2013 20:32:57 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 17 Dec 2013 20:32:57 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_FILL_THIS_FORM_SHORT X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 17 Dec 2013 20:32:30 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id D6A202388C5A; Tue, 17 Dec 2013 20:31:43 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1551686 [11/19] - in /cordova/site/public/docs/en: 3.3.0/ edge/ Date: Tue, 17 Dec 2013 20:31:37 -0000 To: commits@cordova.apache.org From: mwbrooks@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20131217203143.D6A202388C5A@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Modified: cordova/site/public/docs/en/edge/cordova_camera_camera.md.html URL: http://svn.apache.org/viewvc/cordova/site/public/docs/en/edge/cordova_camera_camera.md.html?rev=1551686&r1=1551685&r2=1551686&view=diff ============================================================================== --- cordova/site/public/docs/en/edge/cordova_camera_camera.md.html (original) +++ cordova/site/public/docs/en/edge/cordova_camera_camera.md.html Tue Dec 17 20:31:35 2013 @@ -17,16 +17,18 @@ specific language governing permissions and limitations under the License. --> - - - - -Apache Cordova API Documentation - - - - - + + + + + + Apache Cordova API Documentation + + + + + +

Camera

@@ -191,17 +194,14 @@ obtaining the user's permission (e.g., b OK and No Thanks). For more information, please see the Privacy Guide.

-

-Methods -

+

Methods

-

-Accessing the Feature -

+ +

Accessing the Feature

As of version 3.0, Cordova implements device-level APIs as plugins. Use the CLI's plugin command, described in The Command-Line @@ -279,10 +279,12 @@ platform-specific configuration settings

Reference: Application Manifest for Tizen Web Application

+

Some platforms may support this feature without requiring any special configuration. See Platform Support for an overview.


+

camera.getPicture

Takes a photo using the camera, or retrieves a photo from the device's @@ -294,9 +296,7 @@ reposition the file selection popover.navigator.camera.getPicture( cameraSuccess, cameraError, [ cameraOptions ] ); -

-Description -

+

Description

The camera.getPicture function opens the device's default camera application that allows users to snap pictures. This behavior occurs @@ -319,6 +319,7 @@ one of the following formats, depending

  • A String containing the base64-encoded photo image.

  • A String representing the image file location on local storage (default).

  • +

    You can do whatever you want with the encoded image or URI, for example:

    @@ -327,15 +328,14 @@ example:

  • Save the data locally (LocalStorage, Lawnchair, etc.)

  • Post the data to a remote server

  • +

    NOTE: Photo resolution on newer devices is quite good. Photos selected from the device's gallery are not downscaled to a lower quality, even if a quality parameter is specified. To avoid common memory problems, set Camera.destinationType to FILE_URI rather than DATA_URL.

    -

    -Supported Platforms -

    +

    Supported Platforms

    • Amazon Fire OS
    • @@ -346,17 +346,14 @@ than DATA_URL.

    • Windows Phone 7 and 8
    • Windows 8
    -

    -Amazon Fire OS Quirks -

    + +

    Amazon Fire OS Quirks

    Amazon Fire OS uses intents to launch the camera activity on the device to capture images, and on phones with low memory, the Cordova activity may be killed. In this scenario, the image may not appear when the cordova activity is restored.

    -

    -Android Quirks -

    +

    Android Quirks

    Android 4.4 only: Android 4.4 introduced a new Storage Access Framework that makes it easier for users to browse and open documents across all of their preferred document storage providers. @@ -369,9 +366,7 @@ if they go through the "Gallery" app fir images, and on phones with low memory, the Cordova activity may be killed. In this scenario, the image may not appear when the Cordova activity is restored.

    -

    -iOS Quirks -

    +

    iOS Quirks

    Including a JavaScript alert() in either of the callback functions can cause problems. Wrap the alert within a setTimeout() to allow @@ -383,24 +378,18 @@ displays:

    }, 0); -

    -Windows Phone 7 Quirks -

    +

    Windows Phone 7 Quirks

    Invoking the native camera application while the device is connected via Zune does not work, and triggers an error callback.

    -

    -Tizen Quirks -

    +

    Tizen Quirks

    Tizen only supports a destinationType of Camera.DestinationType.FILE_URI and a sourceType of Camera.PictureSourceType.PHOTOLIBRARY.

    -

    -Quick Example -

    +

    Quick Example

    Take a photo and retrieve it as a base64-encoded image:

    @@ -433,9 +422,7 @@ function onFail(message) { } -

    -Full Example -

    +

    Full Example

    <!DOCTYPE html>
     <html>
    @@ -544,6 +531,7 @@ function onFail(message) {
     

    +

    cameraSuccess

    onSuccess callback function that provides the image data.

    @@ -553,18 +541,15 @@ function onFail(message) { } -

    -Parameters -

    +

    Parameters

    • imageData: Base64 encoding of the image data, or the image file URI, depending on cameraOptions in effect. (String)
    -

    -Example -

    + +

    Example

    // Show image
     //
    @@ -575,6 +560,7 @@ function cameraCallback(imageData) {
     

    +

    cameraError

    onError callback function that provides an error message.

    @@ -584,16 +570,16 @@ function cameraCallback(imageData) { } -

    -Parameters -

    +

    Parameters

    • message: The message is provided by the device's native code. (String)
    +
    +

    cameraOptions

    Optional parameters to customize the camera settings.

    @@ -609,9 +595,7 @@ function cameraCallback(imageData) { saveToPhotoAlbum: false }; -

    -Options -

    +

    Options

    • quality: Quality of the saved image, expressed as a range of 0-100, where 100 is typically full resolution with no loss from file compression. (Number) (Note that information about the camera's resolution is unavailable.)

    • @@ -671,27 +655,24 @@ function cameraCallback(imageData) {
    -

    -Amazon Fire OSQuirks -

    + +

    Amazon Fire OSQuirks

    • Any cameraDirection value results in a back-facing photo.

    • Ignores the allowEdit parameter.

    • Camera.PictureSourceType.PHOTOLIBRARY and Camera.PictureSourceType.SAVEDPHOTOALBUM both display the same photo album.

    -

    -Android Quirks -

    + +

    Android Quirks

    • Any cameraDirection value results in a back-facing photo.

    • Ignores the allowEdit parameter.

    • Camera.PictureSourceType.PHOTOLIBRARY and Camera.PictureSourceType.SAVEDPHOTOALBUM both display the same photo album.

    -

    -BlackBerry 10 Quirks -

    + +

    BlackBerry 10 Quirks

    • Ignores the quality parameter.

    • @@ -701,32 +682,31 @@ function cameraCallback(imageData) {
    • Ignores the correctOrientation parameter.

    • Ignores the cameraDirection parameter.

    -

    -iOS Quirks -

    + +

    iOS Quirks

    • Set quality below 50 to avoid memory errors on some devices.

    • When using destinationType.FILE_URI, photos are saved in the application's temporary directory. You may delete the contents of this directory using the navigator.fileMgr APIs if storage space is a concern.

    -

    -Tizen Quirks -

    + +

    Tizen Quirks

    • options not supported

    • always returns a FILE URI

    -

    -Windows Phone 7 and 8 Quirks -

    + +

    Windows Phone 7 and 8 Quirks

    • Ignores the allowEdit parameter.

    • Ignores the correctOrientation parameter.

    • Ignores the cameraDirection parameter.

    +
    +

    CameraPopoverOptions

    iOS-only parameters that specify the anchor element location and arrow @@ -741,9 +721,7 @@ or album.

    }; -

    -CameraPopoverOptions -

    +

    CameraPopoverOptions

    • x: x pixel coordinate of screen element onto which to anchor the popover. (Number)

    • @@ -763,14 +741,13 @@ or album.

    +

    Note that the size of the popover may change to adjust to the direction of the arrow and orientation of the screen. Make sure to account for orientation changes when specifying the anchor element location.

    -

    -Quick Example -

    +

    Quick Example

     var popover = new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
      var options = {
    @@ -793,28 +770,25 @@ location.


    +

    CameraPopoverHandle

    A handle to the popover dialog created by camera.getPicture.

    -

    -Methods -

    +

    Methods

    • setPosition: Set the position of the popover.
    -

    -Supported Platforms -

    + +

    Supported Platforms

    • iOS
    -

    -setPosition -

    + +

    setPosition

    Set the position of the popover.

    @@ -824,17 +798,14 @@ location.

  • cameraPopoverOptions: the CameraPopoverOptions that specify the new position
  • -

    -Quick Example -

    + +

    Quick Example

     var cameraPopoverOptions = new CameraPopoverOptions(300, 300, 100, 100, Camera.PopoverArrowDirection.ARROW_ANY);
      cameraPopoverHandle.setPosition(cameraPopoverOptions);
     
    -

    -Full Example -

    +

    Full Example

     function onSuccess(imageData) {
           // Do stuff with the image!
    @@ -859,6 +830,7 @@ location.

    - - + + + Modified: cordova/site/public/docs/en/edge/cordova_compass_compass.md.html URL: http://svn.apache.org/viewvc/cordova/site/public/docs/en/edge/cordova_compass_compass.md.html?rev=1551686&r1=1551685&r2=1551686&view=diff ============================================================================== --- cordova/site/public/docs/en/edge/cordova_compass_compass.md.html (original) +++ cordova/site/public/docs/en/edge/cordova_compass_compass.md.html Tue Dec 17 20:31:35 2013 @@ -17,16 +17,18 @@ specific language governing permissions and limitations under the License. --> - - - - -Apache Cordova API Documentation - - - - - + + + + + + Apache Cordova API Documentation + + + + + +

    Compass

    @@ -186,9 +189,7 @@

    Obtains the direction that the device is pointing.

    -

    -Methods -

    +

    Methods

    -

    -Arguments -

    + +

    Arguments

    -

    -Accessing the Feature -

    + +

    Accessing the Feature

    As of version 3.0, Cordova implements device-level APIs as plugins. Use the CLI's plugin command, described in The Command-Line @@ -291,10 +290,12 @@ platform-specific configuration settings

    Reference: Application Manifest for Windows Phone

    +

    Some platforms may support this feature without requiring any special configuration. See Platform Support for an overview.


    +

    compass.getCurrentHeading

    Get the current compass heading.

    @@ -302,9 +303,7 @@ configuration. See navigator.compass.getCurrentHeading(compassSuccess, compassError, compassOptions); -

    -Description -

    +

    Description

    The compass is a sensor that detects the direction or heading that the device is pointed, typically from the top of the device. It measures @@ -313,9 +312,7 @@ the heading in degrees from 0 to 359.99,

    The compass heading information is returned via a CompassHeading object using the compassSuccess callback function.

    -

    -Supported Platforms -

    +

    Supported Platforms

    -

    -Windows Phone Quirks -

    + +

    Windows Phone Quirks

    • When running in the emulator, always detects navigator.connection.type as Connection.UNKNOWN.

    • @@ -398,9 +387,8 @@ eventually be removed.

    -

    -Tizen Quirks -

    + +

    Tizen Quirks

    • Tizen can only detect a WiFi or cellular connection. @@ -410,10 +398,12 @@ eventually be removed.

    -
    + + - - + + + Modified: cordova/site/public/docs/en/edge/cordova_contacts_contacts.md.html URL: http://svn.apache.org/viewvc/cordova/site/public/docs/en/edge/cordova_contacts_contacts.md.html?rev=1551686&r1=1551685&r2=1551686&view=diff ============================================================================== --- cordova/site/public/docs/en/edge/cordova_contacts_contacts.md.html (original) +++ cordova/site/public/docs/en/edge/cordova_contacts_contacts.md.html Tue Dec 17 20:31:35 2013 @@ -17,16 +17,18 @@ specific language governing permissions and limitations under the License. --> - - - - -Apache Cordova API Documentation - - - - - + + + + + + Apache Cordova API Documentation + + + + + +

    Contacts

    @@ -242,17 +245,14 @@ clear and easy-to-understand user experi contact data helps avoid user confusion and perceived misuse of contact data. For more information, please see the Privacy Guide.

    -

    -Methods -

    +

    Methods

    -

    -Arguments -

    + +

    Arguments

    -

    -Objects -

    + +

    Objects

    -

    -Accessing the Feature -

    + +

    Accessing the Feature

    As of version 3.0, Cordova implements device-level APIs as plugins. Use the CLI's plugin command, described in The Command-Line @@ -370,10 +368,12 @@ which forbids inline scripts. Initialize

    Reference: Application Manifest for Windows Phone

    +

    Some platforms may support this feature without requiring any special configuration. See Platform Support for an overview.


    +

    contacts.create

    Returns a new Contact object.

    @@ -381,18 +381,14 @@ configuration. See var contact = navigator.contacts.create(properties); -

    -Description -

    +

    Description

    The contacts.create method is synchronous, and returns a new Contact object.

    This method does not retain the Contact object in the device contacts database, for which you need to invoke the Contact.save method.

    -

    -Supported Platforms -

    +

    Supported Platforms

    • Android
    • @@ -400,16 +396,13 @@ database, for which you need to invoke t
    • iOS
    • Windows Phone 7 and 8
    -

    -Quick Example -

    + +

    Quick Example

    var myContact = navigator.contacts.create({"displayName": "Test User"});
     
    -

    -Full Example -

    +

    Full Example

    <!DOCTYPE html>
     <html>
    @@ -441,6 +434,7 @@ database, for which you need to invoke t
     

    +

    contacts.find

    Queries the device contacts database and returns one or more Contact @@ -449,9 +443,7 @@ objects, each containing the fields spec

    navigator.contacts.find(contactFields, contactSuccess, contactError, contactFindOptions);
     
    -

    -Description -

    +

    Description

    The contacts.find method executes asynchronously, querying the device contacts database and returning an array of Contact objects. @@ -471,9 +463,7 @@ case-insensitive, partial value match is specified in the contactFields parameter. If there's a match for any of the specified fields, the contact is returned.

    -

    -Parameters -

    +

    Parameters

    • contactFields: Contact fields to use as a search qualifier. The resulting Contact object only features values for these fields. (DOMString[]) [Required]

    • @@ -481,9 +471,8 @@ specified in the contactError: Error callback function, invoked when an error occurs. [Optional]

    • contactFindOptions: Search options to filter contacts. [Optional]

    -

    -Supported Platforms -

    + +

    Supported Platforms

    + + - - + + +