Titanium Mobile - 12/22/2011

This release includes:

  • New features for Android and iOS

  • A beta release of our new MobileWeb platform

  • Improvements to the APIDocs

  • Many bug fixes

Please note, the shipping version of the platform is versioned as All references to 1.8.0 below apply to the shipped release.

Please see the updated Titanium Mobile Reference Documentation for 1.8.0.

Full list of Issues that were addressed in 1.8.0

Significant Changes In Titanium Mobile

  • Several changes for platform parity.
  • V8 is the default runtime for Android devices providing a higher level of performance than the Rhino engine. If you would rather use Rhino, see the tiapp.xml guide and look for ti.android.runtime. Set it to rhino in your tiapp.xml file. Or in Titanium Studio, edit tiapp.xml and select a runtime from the Android Runtime list (on the Overview tab of the TiApp editor).
  • We no longer support Android 2.1 (API 7).
  • We no longer support iOS versions less than 4.0.
  • The new Android runtime support required updating modules support. Modules will have to be ported to apiversion 2. Android Modules Porting Guide
  • Replace deprecated API globalPoint with a member function on View called convertPointToView. Android-TIMOB-5122, iOS-TIMOB-5121
  • Titanium.Platform.id is deprecated in this release. A future release will provide alternative API(s). TIMOB-5980
  • Titanium.UI.create3DMatrix is deprecated, use Titanium.UI.iOS.create3DMatrix instead. TIMOB-4990
  • Titanium.UI.CoverFlowView is deprecated, use Titanium.UI.iOS.CoverFlowView instead. TIMOB-4912
  • Titanium.UI.Toolbar is deprecated, use Titanium.UI.iOS.Toolbar instead. TIMOB-5166
  • Several iOS specific UI constants in the common namespace have been deprecated and moved under an iOS namespace. TIMOB-5166
  • Titanium.UI.TabbedBar is deprecated, use Titanium.UI.iOS.TabbedBar instead. TIMOB-5171
  • New API for detecting runtimes - Titanium.Platform.runtime. TIMOB-6007
  • Android Services are on the Javascript thread - In previous releases, our Android Services implementation would run your Service's Javascript on its own thread to avoid blocking (or being blocked by) the execution of your standard Javascript files such as app.js. In this version, your Service's Javascript runs on the same runtime thread as your other Javascript files. This is a temporary situation that will be addressed in an upcoming version. TIMOB-6528
  • XML Module for iOS and Android are now almost 100% DOM Level 2 compliant.
  • Improvements and parity efforts around CommonJS require usage. Modules imported with require run in their own contexts, and cannot access the global context. This may require modules to be imported in multiple places.

Known Issues

The following is a regression in

  • On iOS, calling setRequestHeader and passing null value for the header value does not clear the header, as documented.

Introducing MobileWeb (Beta)

This version of Titanium Mobile now ships with a beta version of our MobileWeb platform. The MobileWeb platform allows you to use the Titanium tooling and APIs you are familiar with to target devices that support HTML5. JIRA list of MobileWeb issues

APIDoc Changes

Another exciting addition to our product is an improved documentation system for our APIDocs. We published our TDoc Specification for our APIDoc and have been reworking the docs to comply with the spec. While the real magic is hidden in the source, we're able to actually use the documentation as the specification for the Titanium Mobile API. Our documentation now gets used as an HTML reference, in content assist, provides coverage data for platform parity analysis, and may be generated in other formats as required. Another gain is that we can annotate APIs to the method and property level with supported platforms, versions supported, deprecations, exclusions, and more. We have also worked on content changes and clarifications for many APIs.

The new APIDoc format uses some new conventions and annotations which may be unfamiliar. These include new conventions for describing types, and new annotations for describing how properties can be accessed.

Type conventions:

  • Dictionary. Any object literal with key/value pairs.
  • Dictionary<type>. A dictionary object that holds properties for the specified type. This should be familiar to most Titanium developers as the type passed to Titanium factory methods. For example, Ti.UI.createWindow takes an argument of type Dictionary<Titanium.UI.Window>. In the Titanium APIs, a Dictionary<type> argument can frequently be passed in place of the named type.
  • Array<type>. An array of objects of the specified type.
  • Callback<type>. A callback function that takes an argument of the specified type.

Property annotations:

Properties can be annotated with permission and availability annotations. New with this release, the APIDocs contain a separate detail page for each property, including an optional longer description and default values.

  • Permission. Indicates whether the property is read-only, write-only, or read/write. Properties are read/write by default. In summary tables, properties that are not read/write include a yellow "READ-ONLY" or "WRITE-ONLY" annotation.

  • Availability. Indicates when the property can be set. By default, properties can be set both in the object's creator method, and after the object has been created. In summary tables, properties that can only be set in the creator method are marked with a yellow "CREATION" annotation, and properties that can not be set in the creator method are marked with a yellow "NOT-CREATION" annotation.

Note that the new APIDocs include detail pages for events and properties, in addition to methods. The detail pages may contain additional information, such as longer descriptions, code samples, or default values.

JIRA List of APIDoc changes

Android Changes

We addressed a significant number of issues, including:


Bug Fixes:

  • In Android, CommonJS modules are now sandboxed into their own contexts, so that Ti.include and require() paths both work in situations where relative paths are used. TIMOB-6073
  • Change zIndex at runtime TIMOB-1729
  • Embedded video support. Parity with iOS TIMOB-2565 - Previous default behavior, since we couldn't add the player to a parent view, was that fullscreen would be true. That's not the case for iOS, and for parity's sake it's no longer the case for Android now that we can put the player on a view. So if fullscreen is desired now in Android, you must specifically set fullscreen to true.
  • Support devices w/o sdcards TIMOB-2613
  • Updates to opacity and animation TIMOB-2851
  • Build failures with Subversion TIMOB-3021
  • Scroll view doesn't scroll horizontally TIMOB-3296
  • XML.parseString not detected TIMOB-3465
  • Webview crashes on reopen TIMOB-4357
  • Support for SDK Tools r14/r15 style add-on folders TIMOB-6135
  • Android emulator fails to launch on Windows if there is a space in the SDCard path. TIMOB-5393
  • JIRA List of over 200 Android bug fixes

iOS Changes

We addressed a significant number of issues, including:


Bug Fixes:

  • Device resource folder not working in simulator TIMOB-1177
  • SearchBar doesn't correctly display background image TIMOB-1689
  • Remove Dashboard row height limit TIMOB-1871
  • Fire errors on HTTPClient for 4xx and 5xx response codes TIMOB-2383
  • Route disappears on map when zooming TIMOB-2898
  • Handle exceptions thrown in simulator TIMOB-3561
  • Single evaluation with require TIMOB-4845
  • removeEventListener removes all events TIMOB-4198
  • userDefaults no remember properties that were set TIMOB-5494
  • Javascript parser crash on device with commonJS modules TIMOB-5355
  • HTTP request sent twice on iOS 5 TIMOB-6016
  • require() does not trigger debugging hooks TIMOB-4797
  • Debugging does not work with apps that have modules TIMOB-4989
  • Local modules are copied into the application bundle TIMOB-5026
  • Disabled timestamping on distribution builds. The addition of a timestamp to the version bundle string can make the string too long for Apple's submission guidelines. This timestamp has been removed from distribution builds, but retained in adhoc and simulator builds. TIMOB-6293
  • CommonJS: Module variables not updated. TIMOB-6688
  • Packaging: Failing to include all optional icons during packaging causes errors in Xcode pre-submission verification. TIMOB-6575
  • Some modules designed for CommonJS not exporting, even with the "export" variable set. TIMOB-6573
  • JIRA list of over 200 iOS bug fixes