Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. Open XCode. Choose File > New > Project.
  2. Select Cordova-based Application from the list of templates.
     
  3. Enter the following options on the next screen:
    1. Product Name: uMobile
    2. Organization Name: Your organization's name
    3. Company Identifier: org.jasig.umobile.phonegap.ios
    4. Check: Use Automatic Reference Counting
     
  4. Choose a location for your project.
     
  5. Disable Automatic Reference Counting in the build.  To do this, select the uMobile target
    1. Select uMobile under Targets in the main project view
    , click
    1. .
    2. Click on the
    "
    1. Build Settings
    "
    1. tab
    at the top, and enter
    1. .
    2. Make sure the All and Combined filters are selected.
    3. Search for reference in the search bar.
     Select
    1. Set the
    "
    1. Objective-C Automatic Reference
    Count. . ." property and set it
    1. Counting property to No.
    Image Removed

    Image Added
  6. Check the uMobile source out into the new project directory.

    Code Block
    git clone git@github.com:Jasig/umobile-app-phonegap umobile-ios
  7. Copy the iPhone-specific Cordova Javascript file to "cordova.js".

    Code Block
    cd umobile-ios
    cp www/lib/external/cordova-iphone-1.7.0rc1.js www/lib/external/cordova.js
  8. Open the coned GitHub clone in Finder, then drag the www folder into the top of the XCode project with your mouse.

  9. Configure cordova.plist by setting OpenAllWhitelistURLsInWebView to true.  Next, add the hostname of your uMobile server, any authentication server, and any other servers hosting uMobile resources to ExternalHosts.  If you're working with the uMobile application server quickstart, you can simply add localhost to the list. Under Plugins add Key: SessionTracking, String: SessionTracking.

  10. Add SessionTracking Plugin files into the Plugins folder: SessionTracking.h and SessionTracking.m

  11. Configure www/config.js.  If you're working with the quickstart, set the value of config.uMobileServerUrl to http://localhost:8080.

  12. Overwrite the file /Classes/MainViewController.m with this one: MainViewController.m

  13. Set the scheme at the top of the project to iPhone 5.1 Simulator and run the project!

...