@maccesar/titools 5.2.5 → 5.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CONTRIBUTING.md +1 -1
- package/README.md +58 -97
- package/agents/ti-pro.md +4 -2
- package/commands/ti-audit.md +7 -5
- package/docs/examples.md +24 -13
- package/docs/knowledge-index.md +2 -1
- package/lib/config.js +1 -0
- package/package.json +1 -1
- package/skills/alloy-guides/SKILL.md +18 -179
- package/skills/alloy-guides/references/CLI_TASKS.md +17 -216
- package/skills/alloy-guides/references/CONCEPTS.md +27 -162
- package/skills/alloy-guides/references/CONTROLLERS.md +38 -236
- package/skills/alloy-guides/references/MODELS.md +47 -723
- package/skills/alloy-guides/references/MODELS_ADVANCED.md +21 -482
- package/skills/alloy-guides/references/VIEWS_DYNAMIC.md +12 -222
- package/skills/alloy-guides/references/VIEWS_STYLES.md +39 -358
- package/skills/alloy-guides/references/VIEWS_XML.md +36 -552
- package/skills/alloy-guides/references/WIDGETS.md +49 -127
- package/skills/alloy-howtos/SKILL.md +14 -169
- package/skills/alloy-howtos/references/best_practices.md +9 -113
- package/skills/alloy-howtos/references/cli_reference.md +18 -223
- package/skills/alloy-howtos/references/config_files.md +50 -133
- package/skills/alloy-howtos/references/debugging_troubleshooting.md +19 -63
- package/skills/alloy-howtos/references/samples.md +21 -138
- package/skills/ti-api/SKILL.md +10 -2
- package/skills/ti-api/references/api-android.md +36 -2
- package/skills/ti-api/references/api-app-platform.md +39 -3
- package/skills/ti-api/references/api-core.md +50 -18
- package/skills/ti-api/references/api-data-network.md +49 -35
- package/skills/ti-api/references/api-media.md +45 -27
- package/skills/ti-api/references/api-services.md +39 -9
- package/skills/ti-api/references/api-ui-android.md +33 -13
- package/skills/ti-api/references/api-ui-extras.md +41 -15
- package/skills/ti-api/references/api-ui-ios-animator.md +42 -26
- package/skills/ti-api/references/api-ui-ios.md +74 -2
- package/skills/ti-api/references/api-ui-lists.md +32 -16
- package/skills/ti-api/references/api-ui-text-input.md +34 -17
- package/skills/ti-api/references/api-ui-views.md +27 -1
- package/skills/ti-api/references/api-ui-windows-navigation.md +32 -18
- package/skills/ti-api/references/api-xml-global.md +66 -16
- package/skills/ti-create-release/SKILL.md +98 -0
- package/skills/ti-create-release/references/module-discovery.md +69 -0
- package/skills/ti-expert/references/adaptive-layouts.md +1 -1
- package/skills/ti-guides/SKILL.md +37 -76
- package/skills/ti-guides/references/advanced-data-and-images.md +122 -126
- package/skills/ti-guides/references/android-manifest.md +24 -83
- package/skills/ti-guides/references/app-distribution.md +31 -377
- package/skills/ti-guides/references/application-frameworks.md +127 -335
- package/skills/ti-guides/references/cli-reference.md +184 -633
- package/skills/ti-guides/references/commonjs-advanced.md +81 -231
- package/skills/ti-guides/references/compatibility-matrix.md +36 -75
- package/skills/ti-guides/references/hello-world.md +95 -70
- package/skills/ti-guides/references/hyperloop-native-access.md +52 -448
- package/skills/ti-guides/references/resources.md +174 -142
- package/skills/ti-guides/references/sdk-release-notes.md +28 -71
- package/skills/ti-guides/references/tiapp-config.md +222 -598
- package/skills/ti-howtos/SKILL.md +23 -123
- package/skills/ti-howtos/references/cross-platform-development.md +119 -324
- package/skills/ti-howtos/references/debugging-profiling.md +77 -445
- package/skills/ti-howtos/references/extending-titanium.md +199 -673
- package/skills/ti-howtos/references/local-data-sources.md +87 -300
- package/skills/ti-howtos/references/location-and-maps.md +86 -213
- package/skills/ti-howtos/references/media-apis.md +103 -223
- package/skills/ti-howtos/references/notification-services.md +86 -506
- package/skills/ti-howtos/references/remote-data-sources.md +97 -316
- package/skills/ti-howtos/references/using-modules.md +77 -133
- package/skills/ti-synthengine/SKILL.md +62 -111
- package/skills/ti-synthengine/assets/example/README.md +50 -59
- package/skills/ti-synthengine/assets/example/app.js +67 -65
- package/skills/ti-synthengine/assets/example/lib/sequenceOwner.js +39 -40
- package/skills/ti-synthengine/assets/example/lib/soundPreset.js +34 -0
- package/skills/ti-synthengine/assets/index.d.ts +122 -2
- package/skills/ti-synthengine/references/advanced-examples.md +4 -4
- package/skills/ti-synthengine/references/api.md +40 -18
- package/skills/ti-synthengine/references/audio-engine.md +15 -57
- package/skills/ti-synthengine/references/examples.md +63 -6
- package/skills/ti-synthengine/references/guide.md +61 -57
- package/skills/ti-synthengine/references/instruments-and-effects.md +15 -15
- package/skills/ti-synthengine/references/native-variation.md +53 -14
- package/skills/ti-synthengine/references/recipes-interaction.md +25 -20
- package/skills/ti-synthengine/references/recipes.md +19 -16
- package/skills/ti-synthengine/references/recommendations.md +12 -12
- package/skills/ti-synthengine/references/sound-api.md +197 -0
- package/skills/ti-synthengine/references/sound-design.md +7 -7
- package/skills/ti-synthengine/references/source-notes.md +62 -172
- package/skills/ti-synthengine/references/troubleshooting.md +17 -19
- package/skills/ti-synthengine/references/upgrade-2.0.0.md +40 -0
- package/skills/ti-ui/SKILL.md +28 -143
- package/skills/ti-ui/references/icons-and-splash-screens.md +74 -403
- package/skills/ti-ui/references/layouts-and-positioning.md +175 -402
- package/skills/ti-ui/references/listviews-and-performance.md +100 -703
- package/skills/ti-ui/references/platform-conventions.md +180 -0
- package/skills/ti-ui/references/user-interface.md +43 -0
- package/skills/alloy-guides/references/VIEWS_WITHOUT_CONTROLLERS.md +0 -102
- package/skills/alloy-howtos/references/custom_tags.md +0 -148
- package/skills/ti-guides/references/coding-best-practices.md +0 -149
- package/skills/ti-guides/references/javascript-primer.md +0 -414
- package/skills/ti-guides/references/reserved-words.md +0 -36
- package/skills/ti-guides/references/style-and-conventions.md +0 -103
- package/skills/ti-howtos/references/android-platform-deep-dives.md +0 -624
- package/skills/ti-howtos/references/automation-fastlane-appium.md +0 -96
- package/skills/ti-howtos/references/buffer-codec-streams.md +0 -162
- package/skills/ti-howtos/references/google-maps-v2.md +0 -172
- package/skills/ti-howtos/references/ios-map-kit.md +0 -149
- package/skills/ti-howtos/references/ios-platform-deep-dives.md +0 -611
- package/skills/ti-howtos/references/tutorials.md +0 -565
- package/skills/ti-howtos/references/web-content-integration.md +0 -287
- package/skills/ti-howtos/references/webpack-build-pipeline.md +0 -124
- package/skills/ti-synthengine/references/android-sim80-correction-evidence.zip +0 -0
- package/skills/ti-synthengine/references/android-sim80-correction.json +0 -162
- package/skills/ti-synthengine/references/audio-pipeline-validation.md +0 -19
- package/skills/ti-synthengine/references/bypass-physical-recheck-evidence.zip +0 -0
- package/skills/ti-synthengine/references/frontier-android-evidence.zip +0 -0
- package/skills/ti-synthengine/references/frontier-ipad-evidence.zip +0 -0
- package/skills/ti-synthengine/references/frontier-physical-validation.json +0 -1918
- package/skills/ti-synthengine/references/native-tone-repetition-validation.md +0 -59
- package/skills/ti-synthengine/references/native-variation-proposal.md +0 -182
- package/skills/ti-synthengine/references/native-variation-validation.md +0 -63
- package/skills/ti-synthengine/references/performance-review-evidence.zip +0 -0
- package/skills/ti-synthengine/references/performance-review.json +0 -1146
- package/skills/ti-synthengine/references/physical-validation.json +0 -1457
- package/skills/ti-synthengine/references/source-snapshot.json +0 -542
- package/skills/ti-synthengine/references/stats-performance.json +0 -2992
- package/skills/ti-synthengine/references/stats-performance.md +0 -82
- package/skills/ti-synthengine/references/studio-validation.json +0 -6202
- package/skills/ti-synthengine/references/unified-bypass-performance.json +0 -22425
- package/skills/ti-synthengine/references/unified-validation.json +0 -314
- package/skills/ti-ui/references/accessibility-deep-dive.md +0 -288
- package/skills/ti-ui/references/animation-and-matrices.md +0 -569
- package/skills/ti-ui/references/application-structures.md +0 -626
- package/skills/ti-ui/references/custom-fonts-styling.md +0 -549
- package/skills/ti-ui/references/event-handling.md +0 -401
- package/skills/ti-ui/references/gestures.md +0 -448
- package/skills/ti-ui/references/orientation.md +0 -374
- package/skills/ti-ui/references/platform-ui-android.md +0 -727
- package/skills/ti-ui/references/platform-ui-ios.md +0 -576
- package/skills/ti-ui/references/scrolling-views.md +0 -288
- package/skills/ti-ui/references/tableviews.md +0 -542
|
@@ -1,670 +1,294 @@
|
|
|
1
|
-
# tiapp.xml
|
|
1
|
+
# tiapp.xml
|
|
2
2
|
|
|
3
|
-
Reference for Titanium app configuration files. `tiapp.xml` is the main config file for Titanium apps. `timodule.xml` is for custom modules.
|
|
4
3
|
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
Every element the build reads, verified against Titanium SDK 13.4.1. For what
|
|
5
|
+
`tiapp.xml` is and where it sits, see
|
|
6
|
+
[project structure](https://titaniumsdk.com/docs/build/project-structure).
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
- [Application properties](#application-properties)
|
|
11
|
-
- [Android section](#android-section)
|
|
12
|
-
- [iOS section](#ios-section)
|
|
13
|
-
- [Google Play Services](#google-play-services)
|
|
14
|
-
- [timodule.xml (module configuration)](#timodulexml-module-configuration)
|
|
15
|
-
- [SDK version precedence](#sdk-version-precedence)
|
|
16
|
-
- [References](#references)
|
|
8
|
+
Edit it in a text editor, or from a script with `ti project`. Elements are
|
|
9
|
+
children of the root `<ti:app>` unless the table says otherwise.
|
|
17
10
|
|
|
18
|
-
|
|
11
|
+
> [!IMPORTANT]
|
|
12
|
+
> An element the SDK does not recognise is not an error. A misspelled top-level
|
|
13
|
+
> element is parsed and then never read; a misspelled child of `<ios>` or
|
|
14
|
+
> `<android>` is discarded outright. Either way the build succeeds and your
|
|
15
|
+
> setting does nothing, so check the spelling here before assuming a bug.
|
|
19
16
|
|
|
20
|
-
##
|
|
17
|
+
## Identity
|
|
21
18
|
|
|
22
19
|
```xml
|
|
23
|
-
<ti:app xmlns:ti="http://ti.
|
|
24
|
-
<id>com.
|
|
25
|
-
<name>
|
|
26
|
-
<version>1.0
|
|
20
|
+
<ti:app xmlns:ti="http://ti.titaniumsdk.com">
|
|
21
|
+
<id>com.example.hello</id>
|
|
22
|
+
<name>Hello</name>
|
|
23
|
+
<version>1.0</version>
|
|
24
|
+
<guid>f0391a5d-2689-47cf-a6aa-df0f849fbe50</guid>
|
|
27
25
|
<icon>appicon.png</icon>
|
|
28
|
-
<fullscreen>false</fullscreen>
|
|
29
|
-
<navbar-hidden>false</navbar-hidden>
|
|
30
|
-
<analytics>false</analytics>
|
|
31
|
-
<guid>GUID</guid>
|
|
32
|
-
<ios>
|
|
33
|
-
<plist>
|
|
34
|
-
<dict>
|
|
35
|
-
<key>UISupportedInterfaceOrientations~iphone</key>
|
|
36
|
-
<array>
|
|
37
|
-
<string>UIInterfaceOrientationPortrait</string>
|
|
38
|
-
</array>
|
|
39
|
-
<key>UISupportedInterfaceOrientations~ipad</key>
|
|
40
|
-
<array>
|
|
41
|
-
<string>UIInterfaceOrientationPortrait</string>
|
|
42
|
-
<string>UIInterfaceOrientationPortraitUpsideDown</string>
|
|
43
|
-
<string>UIInterfaceOrientationLandscapeLeft</string>
|
|
44
|
-
<string>UIInterfaceOrientationLandscapeRight</string>
|
|
45
|
-
</array>
|
|
46
|
-
</dict>
|
|
47
|
-
</plist>
|
|
48
|
-
</ios>
|
|
49
|
-
<android xmlns:android="http://schemas.android.com/apk/res/android">
|
|
50
|
-
<tool-api-level>10</tool-api-level>
|
|
51
|
-
<abi>all</abi>
|
|
52
|
-
</android>
|
|
53
|
-
<modules/>
|
|
54
26
|
</ti:app>
|
|
55
27
|
```
|
|
56
28
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
#### `<guid>`
|
|
66
|
-
|
|
67
|
-
Required. Unique ID generated by the CLI. Do not modify unless you know why.
|
|
68
|
-
|
|
69
|
-
#### `<id>`
|
|
70
|
-
|
|
71
|
-
Required. Application ID.
|
|
72
|
-
|
|
73
|
-
- Android: package ID following Java package naming standards
|
|
74
|
-
- iOS: must match Bundle ID from Apple Developer Portal
|
|
75
|
-
|
|
76
|
-
```xml
|
|
77
|
-
<id>com.mycompany.fakeblock</id>
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
#### `<name>`
|
|
81
|
-
|
|
82
|
-
Required. Application name shown under the icon on device.
|
|
83
|
-
|
|
84
|
-
```xml
|
|
85
|
-
<name>Fakeblock</name>
|
|
86
|
-
```
|
|
87
|
-
|
|
88
|
-
Android warning: if the name starts with a digit, prefix the activity name with an underscore (for example, `_2Foo`).
|
|
89
|
-
|
|
90
|
-
### Optional elements
|
|
91
|
-
|
|
92
|
-
#### `<defaultLang>`
|
|
93
|
-
|
|
94
|
-
Sets the default language for Android i18n `strings.xml`. Android defaults to `en`. If you only use a single non-English i18n file, set this to that language.
|
|
95
|
-
|
|
96
|
-
```xml
|
|
97
|
-
<defaultLang>de</defaultLang>
|
|
98
|
-
```
|
|
99
|
-
|
|
100
|
-
#### `<copyright>`
|
|
101
|
-
|
|
102
|
-
Application copyright.
|
|
103
|
-
|
|
104
|
-
#### `<description>`
|
|
105
|
-
|
|
106
|
-
Application description.
|
|
107
|
-
|
|
108
|
-
```xml
|
|
109
|
-
<description>Tap to rock out with this block.</description>
|
|
110
|
-
```
|
|
111
|
-
|
|
112
|
-
#### `<fullscreen>`
|
|
113
|
-
|
|
114
|
-
Start the app in fullscreen (hides the status bar).
|
|
29
|
+
| Element | Value | What it controls |
|
|
30
|
+
| --------- | ------------------- | ----------------------------------------------------------------- |
|
|
31
|
+
| `id` | reverse-DNS string | Android package name and iOS bundle identifier. Required |
|
|
32
|
+
| `name` | string | The name under the icon. Required |
|
|
33
|
+
| `version` | `1`, `1.0`, `1.0.0` | The version shown in the stores. Defaults to `1.0` |
|
|
34
|
+
| `guid` | UUID | Generated per project. Required, and rejected if it is not a UUID |
|
|
35
|
+
| `icon` | filename | Must end in `.png`. Falls back to `appicon.png` |
|
|
115
36
|
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
37
|
+
`version` has to start with a whole number greater than zero, so `0.9` is
|
|
38
|
+
rejected and `1.0.0.beta1` is accepted. Set the property
|
|
39
|
+
`ti.skipVersionValidation` to bypass that check, and `ti.skipAppIdValidation`
|
|
40
|
+
to bypass the app id one.
|
|
119
41
|
|
|
120
|
-
|
|
42
|
+
> [!IMPORTANT]
|
|
43
|
+
> Changing `id` after publishing means a **new listing** in both stores rather
|
|
44
|
+
> than an update. Set it to a domain you control when you create the project.
|
|
121
45
|
|
|
122
|
-
|
|
46
|
+
`guid` identifies the project, so copying a `tiapp.xml` from another app carries
|
|
47
|
+
its guid along. Change it when you do that.
|
|
123
48
|
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
49
|
+
`publisher`, `url`, `description` and `copyright` are also accepted. Nothing
|
|
50
|
+
reads them: no build uses them and neither store shows them. `ti create` writes
|
|
51
|
+
`not specified` into all four.
|
|
127
52
|
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
Hide the navigation bar.
|
|
53
|
+
## What gets built
|
|
131
54
|
|
|
132
55
|
```xml
|
|
133
|
-
<
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
Application publisher.
|
|
141
|
-
|
|
142
|
-
```xml
|
|
143
|
-
<publisher>Bluth Company</publisher>
|
|
56
|
+
<sdk-version>13.4.1.GA</sdk-version>
|
|
57
|
+
<deployment-targets>
|
|
58
|
+
<target device="android">true</target>
|
|
59
|
+
<target device="iphone">true</target>
|
|
60
|
+
<target device="ipad">false</target>
|
|
61
|
+
</deployment-targets>
|
|
144
62
|
```
|
|
145
63
|
|
|
146
|
-
|
|
64
|
+
`sdk-version` pins which installed SDK builds the project, and `--sdk` overrides
|
|
65
|
+
it for one build. A project without it uses the newest installed SDK, which
|
|
66
|
+
means two machines can build the same commit differently.
|
|
147
67
|
|
|
148
|
-
|
|
68
|
+
`deployment-targets` is which platforms and device families are built. The
|
|
69
|
+
`device` values are `android`, `iphone` and `ipad`; turning `ipad` off is what
|
|
70
|
+
`--platforms iphone` does at creation. On iOS the two Apple entries decide the
|
|
71
|
+
device family the app declares.
|
|
149
72
|
|
|
150
|
-
|
|
151
|
-
<statusbar-hidden>false</statusbar-hidden> <!-- default -->
|
|
152
|
-
```
|
|
73
|
+
## Application settings
|
|
153
74
|
|
|
154
|
-
|
|
75
|
+
Top-level switches. Each says which platform reads it, because most of them are
|
|
76
|
+
read by one platform and silently ignored by the other.
|
|
155
77
|
|
|
156
|
-
|
|
78
|
+
| Element | Value | Platform | Effect |
|
|
79
|
+
| ---------------------- | ------ | -------- | ------------------------------------------------------------- |
|
|
80
|
+
| `fullscreen` | bool | Android | Hides the status bar, through the generated theme |
|
|
81
|
+
| `navbar-hidden` | bool | Android | Hides the title bar |
|
|
82
|
+
| `override-permissions` | bool | Android | Stops the build adding permissions it inferred from your code |
|
|
83
|
+
| `defaultLang` | string | Android | Which i18n locale becomes the unsuffixed resource directory |
|
|
84
|
+
| `statusbar-hidden` | bool | both | `UIStatusBarHidden` on iOS; hides the status bar on Android |
|
|
85
|
+
| `statusbar-style` | string | iOS | `UIStatusBarStyle`. See below |
|
|
86
|
+
| `persistent-wifi` | bool | iOS | `UIRequiresPersistentWiFi` |
|
|
87
|
+
| `prerendered-icon` | bool | iOS | `UIPrerenderedIcon` |
|
|
88
|
+
| `transpile` | bool | both | Transpiles your JavaScript. **On unless set to `false`** |
|
|
89
|
+
| `source-maps` | bool | both | Emits source maps. `--source-maps` overrides it |
|
|
157
90
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
91
|
+
`statusbar-style` is matched loosely: `opaque_black`, `opaque` or `black` give
|
|
92
|
+
`UIStatusBarStyleBlackOpaque`, and `translucent_black`, `transparent` or
|
|
93
|
+
`translucent` give `UIStatusBarStyleBlackTranslucent`. Anything else, including
|
|
94
|
+
a typo, gives the default style.
|
|
161
95
|
|
|
162
|
-
|
|
96
|
+
The element is `source-maps`. `sourcemaps` without the hyphen is one of the
|
|
97
|
+
unrecognised elements above: accepted, and then ignored.
|
|
163
98
|
|
|
164
|
-
|
|
99
|
+
## Runtime properties
|
|
165
100
|
|
|
166
101
|
```xml
|
|
167
|
-
<
|
|
102
|
+
<property name="ti.ui.defaultunit" type="string">dp</property>
|
|
103
|
+
<property name="apiRoot" type="string">https://example.com/api</property>
|
|
104
|
+
<property name="cacheSeconds" type="int">300</property>
|
|
168
105
|
```
|
|
169
106
|
|
|
170
|
-
|
|
107
|
+
Everything here is written into the app and readable at runtime through
|
|
108
|
+
`Ti.App.Properties`. `name` is required; a `<property>` without one is ignored.
|
|
171
109
|
|
|
172
|
-
|
|
110
|
+
| `type` | Parsed as |
|
|
111
|
+
| -------- | ---------------------------- |
|
|
112
|
+
| `bool` | `true` only for `true` |
|
|
113
|
+
| `int` | Whole number, `0` on failure |
|
|
114
|
+
| `double` | Decimal, `0` on failure |
|
|
115
|
+
| omitted | String |
|
|
173
116
|
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
<sdk-version>11.1.0.GA</sdk-version>
|
|
178
|
-
```
|
|
117
|
+
Any other `type` is treated as a string, so `type="boolean"` silently gives you
|
|
118
|
+
the string `"true"` rather than a boolean. Reading a property with a getter that
|
|
119
|
+
does not match its type returns the default instead of converting.
|
|
179
120
|
|
|
180
|
-
|
|
121
|
+
Properties the SDK itself reads:
|
|
181
122
|
|
|
182
|
-
|
|
123
|
+
| Property | What it does |
|
|
124
|
+
| --------------------------- | ------------------------------------------------------------- |
|
|
125
|
+
| `ti.ui.defaultunit` | What a bare number means in a layout. `ti create` writes `dp` |
|
|
126
|
+
| `ti.skipAppIdValidation` | Skips the app id format check |
|
|
127
|
+
| `ti.skipVersionValidation` | Skips the `version` format check |
|
|
128
|
+
| `ti.facebook.appid` | Wires the Facebook URL scheme into `Info.plist` |
|
|
129
|
+
| `ti.android.debug` | Debug logging in the Android runtime. Off unless `true` |
|
|
130
|
+
| `ti.android.loadfromsdcard` | Loads JavaScript off the SD card, for development |
|
|
131
|
+
| `android.javac.maxMemory` | Heap for the Java compiler, when a large project runs out |
|
|
183
132
|
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
<target device="android">true</target>
|
|
187
|
-
<target device="ipad">false</target>
|
|
188
|
-
<target device="iphone">false</target>
|
|
189
|
-
</deployment-targets>
|
|
190
|
-
```
|
|
133
|
+
`ti.ui.defaultunit` accepts `system`, `px`, `dp`, `dip`, `mm`, `cm` and `in`,
|
|
134
|
+
and defaults to `system`.
|
|
191
135
|
|
|
192
|
-
|
|
136
|
+
> [!NOTE]
|
|
137
|
+
> `run-on-main-thread` is in the default template and does nothing. It has been
|
|
138
|
+
> ignored since 8.0.0, when running on the main thread became the only
|
|
139
|
+
> behaviour. Deleting it changes nothing either.
|
|
193
140
|
|
|
194
|
-
|
|
141
|
+
## Modules and plugins
|
|
195
142
|
|
|
196
143
|
```xml
|
|
197
144
|
<modules>
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
<module platform="ios">ti.map</module>
|
|
201
|
-
<module version="2.0.0">ti.alloy</module>
|
|
202
|
-
<module deploy-type="production">ti.analytics</module>
|
|
145
|
+
<module platform="android" version="5.7.0">ti.map</module>
|
|
146
|
+
<module platform="iphone">ti.map</module>
|
|
203
147
|
</modules>
|
|
204
|
-
```
|
|
205
|
-
|
|
206
|
-
Attributes:
|
|
207
|
-
- `platform`: `android`, `commonjs`, `iphone`
|
|
208
|
-
- `version`: specific module version
|
|
209
|
-
- `deploy-type`: `development`, `test`, `production` (comma-separated)
|
|
210
|
-
|
|
211
|
-
#### `<plugins>`
|
|
212
148
|
|
|
213
|
-
Include plugins (in the `plugins/` folder).
|
|
214
|
-
|
|
215
|
-
```xml
|
|
216
149
|
<plugins>
|
|
217
|
-
|
|
150
|
+
<plugin version="1.0">ti.alloy</plugin>
|
|
218
151
|
</plugins>
|
|
219
152
|
```
|
|
220
153
|
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
154
|
+
A module on disk that is not listed here is not built in, and the failure is a
|
|
155
|
+
`require` returning nothing. `platform` and `version` are both optional; without
|
|
156
|
+
a version the newest installed is used. See [using modules](https://titaniumsdk.com/docs/build/modules).
|
|
157
|
+
|
|
158
|
+
`ti.alloy` in `plugins` is what makes a project an Alloy project, and
|
|
159
|
+
`alloy new` adds it. A plugin listed here that is not installed fails the build
|
|
160
|
+
rather than being skipped.
|
|
161
|
+
|
|
162
|
+
## iOS
|
|
163
|
+
|
|
164
|
+
Children of `<ios>`. Anything else inside `<ios>` is discarded without a
|
|
165
|
+
warning.
|
|
166
|
+
|
|
167
|
+
| Element | Value | Effect |
|
|
168
|
+
| --------------------------------- | --------- | ------------------------------------------------------------------------- |
|
|
169
|
+
| `plist` | dict | Merged over `Info.plist`, last. See below |
|
|
170
|
+
| `entitlements` | dict | Merged into `Entitlements.plist` |
|
|
171
|
+
| `capabilities` | element | Only `<app-groups>` is understood, giving app group entitlements |
|
|
172
|
+
| `extensions` | element | App extensions to build alongside the app |
|
|
173
|
+
| `min-ios-ver` | `15.0` | Raises the deployment target. **Only honored above the SDK's own floor** |
|
|
174
|
+
| `team-id` | string | Apple Developer team, when your account has more than one |
|
|
175
|
+
| `default-background-color` | `#rrggbb` | Background of the generated launch storyboard |
|
|
176
|
+
| `use-app-thinning` | bool | App thinning and asset catalogs. Off unless set to `true` |
|
|
177
|
+
| `use-jscore-framework` | bool | Apple's JavaScriptCore instead of the bundled one. **On unless `false`** |
|
|
178
|
+
| `use-autolayout` | bool | Auto Layout. Off unless set to `true` |
|
|
179
|
+
| `use-new-build-system` | bool | Xcode's new build system. On for Xcode 10 and later |
|
|
180
|
+
| `enable-launch-screen-storyboard` | bool | Generates a launch storyboard instead of launch images |
|
|
181
|
+
| `exclude-dir-from-asset-catalog` | bool | Keeps a directory of images out of the asset catalog |
|
|
182
|
+
| `log-server-port` | int | Port for the log server, 1024 to 65535. Derived from the app id otherwise |
|
|
183
|
+
|
|
184
|
+
The SDK's own iOS floor is 15.0 in 13.4.1, so a `min-ios-ver` below that is
|
|
185
|
+
ignored rather than applied. The floor per release is on
|
|
186
|
+
[compatibility](https://titaniumsdk.com/docs/reference/compatibility).
|
|
187
|
+
|
|
188
|
+
`<plist>` takes `Info.plist` keys verbatim, which is where permission strings
|
|
189
|
+
and orientations go:
|
|
190
|
+
|
|
191
|
+
```xml
|
|
192
|
+
<ios>
|
|
193
|
+
<enable-launch-screen-storyboard>true</enable-launch-screen-storyboard>
|
|
194
|
+
<plist>
|
|
195
|
+
<dict>
|
|
196
|
+
<key>NSCameraUsageDescription</key>
|
|
197
|
+
<string>Attach a photo to a note.</string>
|
|
198
|
+
<key>UISupportedInterfaceOrientations~iphone</key>
|
|
199
|
+
<array>
|
|
200
|
+
<string>UIInterfaceOrientationPortrait</string>
|
|
201
|
+
</array>
|
|
202
|
+
</dict>
|
|
203
|
+
</plist>
|
|
204
|
+
</ios>
|
|
205
|
+
```
|
|
206
|
+
|
|
207
|
+
A missing usage string is an App Store rejection and, before that, a permission
|
|
208
|
+
dialog that never appears. See [media](https://titaniumsdk.com/docs/build/media).
|
|
209
|
+
|
|
210
|
+
Keys the build owns are stripped from `<plist>` before the merge:
|
|
211
|
+
`CFBundleDisplayName`, `CFBundleExecutable`, `CFBundleIconFile`,
|
|
212
|
+
`CFBundleIdentifier`, `CFBundleInfoDictionaryVersion`, `CFBundleName`,
|
|
213
|
+
`CFBundlePackageType`, `CFBundleSignature` and `LSRequiresIPhoneOS`. Setting one
|
|
214
|
+
of those here does nothing; set `<id>` and `<name>` instead.
|
|
215
|
+
|
|
216
|
+
## Android
|
|
217
|
+
|
|
218
|
+
Children of `<android>`. As with `<ios>`, anything else is discarded. The
|
|
219
|
+
`xmlns:android` declaration belongs on the `<android>` element.
|
|
220
|
+
|
|
221
|
+
| Element | Value | Effect |
|
|
222
|
+
| ---------------- | --------------- | ------------------------------------------------------------------- |
|
|
223
|
+
| `manifest` | XML | Merged into the generated `AndroidManifest.xml` |
|
|
224
|
+
| `tool-api-level` | int | The API level the app is compiled against |
|
|
225
|
+
| `abi` | comma-separated | Which ABIs to package. `all` packages every one |
|
|
226
|
+
| `activities` | element | Extra activities, each keyed by the JavaScript file it opens |
|
|
227
|
+
| `services` | element | Extra services. `type="quicksettings"` builds a quick settings tile |
|
|
264
228
|
|
|
265
229
|
```xml
|
|
266
230
|
<android xmlns:android="http://schemas.android.com/apk/res/android">
|
|
267
|
-
<
|
|
268
|
-
|
|
269
|
-
<
|
|
270
|
-
</activities>
|
|
271
|
-
<services>
|
|
272
|
-
<service url="service.js" type="standard"/>
|
|
273
|
-
</services>
|
|
274
|
-
<manifest>
|
|
275
|
-
<uses-sdk android:minSdkVersion="10" android:targetSdkVersion="14"/>
|
|
276
|
-
<application>
|
|
277
|
-
<activity>...</activity>
|
|
278
|
-
<service>...</service>
|
|
279
|
-
</application>
|
|
231
|
+
<manifest android:versionCode="1">
|
|
232
|
+
<uses-permission android:name="android.permission.CAMERA"/>
|
|
233
|
+
<application android:icon="@mipmap/ic_launcher"/>
|
|
280
234
|
</manifest>
|
|
235
|
+
<abi>arm64-v8a,x86_64</abi>
|
|
281
236
|
</android>
|
|
282
237
|
```
|
|
283
238
|
|
|
284
|
-
|
|
239
|
+
`android:versionCode` is the integer Google Play orders releases by, and it has
|
|
240
|
+
to increase on every upload. `<version>` above is the human one; these are
|
|
241
|
+
separate numbers and both matter.
|
|
285
242
|
|
|
286
|
-
|
|
243
|
+
Restricting `abi` shrinks the APK and is the usual reason to set it. An ABI you
|
|
244
|
+
drop is a device the app will not install on.
|
|
287
245
|
|
|
288
|
-
|
|
246
|
+
## Elements that no longer work
|
|
289
247
|
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
248
|
+
| Element | State |
|
|
249
|
+
| ------------------ | ------------------------------------------------------------------------ |
|
|
250
|
+
| `<iphone>` | **Removed in 7.0.0.** The iOS build stops with an error if it is present |
|
|
251
|
+
| `<code-processor>` | Parsed and never read. Nothing in the SDK acts on it |
|
|
252
|
+
| `<webpack>` | Parsed and never read by the SDK |
|
|
293
253
|
|
|
294
|
-
|
|
254
|
+
`<iphone>` is the only one that fails a build. Move its contents into `<ios>`.
|
|
295
255
|
|
|
296
|
-
|
|
256
|
+
## timodule.xml
|
|
297
257
|
|
|
298
|
-
|
|
258
|
+
A native or CommonJS module carries `timodule.xml` instead of `tiapp.xml`, and
|
|
259
|
+
the SDK parses it with the same code, so it accepts the same vocabulary. It does
|
|
260
|
+
not act on the same vocabulary: an app building a module reads exactly two
|
|
261
|
+
things out of it.
|
|
299
262
|
|
|
300
|
-
|
|
263
|
+
| Element | Effect on the app that includes the module |
|
|
264
|
+
| --------------------- | ------------------------------------------------------ |
|
|
265
|
+
| `<modules>` | Modules this module needs, added to the app's own list |
|
|
266
|
+
| `<android><manifest>` | Merged into the app's `AndroidManifest.xml` |
|
|
301
267
|
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
<activity url="activity.js">
|
|
305
|
-
<!-- Android Manifest elements -->
|
|
306
|
-
</activity>
|
|
307
|
-
</activities>
|
|
308
|
-
```
|
|
309
|
-
|
|
310
|
-
#### `<services>`
|
|
311
|
-
|
|
312
|
-
Custom JavaScript-based Android services (background processes).
|
|
268
|
+
Both are Android only. The iOS build reads nothing from `timodule.xml`: an iOS
|
|
269
|
+
module's `Info.plist` and entitlements come from its own files.
|
|
313
270
|
|
|
314
271
|
```xml
|
|
315
|
-
<
|
|
316
|
-
|
|
317
|
-
</
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
#### `<manifest>`
|
|
321
|
-
|
|
322
|
-
Ad-hoc AndroidManifest.xml elements.
|
|
323
|
-
|
|
324
|
-
Set target/minimum SDK:
|
|
325
|
-
```xml
|
|
326
|
-
<android xmlns:android="http://schemas.android.com/apk/res/android">
|
|
272
|
+
<ti:app xmlns:ti="http://ti.titaniumsdk.com">
|
|
273
|
+
<modules>
|
|
274
|
+
<module platform="android">ti.playservices</module>
|
|
275
|
+
</modules>
|
|
276
|
+
<android xmlns:android="http://schemas.android.com/apk/res/android">
|
|
327
277
|
<manifest>
|
|
328
|
-
|
|
329
|
-
<uses-sdk android:minSdkVersion="21" android:targetSdkVersion="29"/>
|
|
278
|
+
<uses-permission android:name="android.permission.VIBRATE"/>
|
|
330
279
|
</manifest>
|
|
331
|
-
</android>
|
|
332
|
-
```
|
|
333
|
-
|
|
334
|
-
Screen density support:
|
|
335
|
-
```xml
|
|
336
|
-
<manifest>
|
|
337
|
-
<supports-screens
|
|
338
|
-
android:smallScreens="true"
|
|
339
|
-
android:normalScreens="true"
|
|
340
|
-
android:largeScreens="true"
|
|
341
|
-
android:xlargeScreens="true"
|
|
342
|
-
/>
|
|
343
|
-
</manifest>
|
|
344
|
-
```
|
|
345
|
-
|
|
346
|
-
Do not set `android:anyDensity="false"`.
|
|
347
|
-
|
|
348
|
-
Enable debugging:
|
|
349
|
-
```xml
|
|
350
|
-
<manifest>
|
|
351
|
-
<application android:debuggable="true" />
|
|
352
|
-
</manifest>
|
|
353
|
-
```
|
|
354
|
-
|
|
355
|
-
Install location:
|
|
356
|
-
```xml
|
|
357
|
-
<manifest android:installLocation="preferExternal">
|
|
358
|
-
<uses-sdk android:minSdkVersion="7" />
|
|
359
|
-
</manifest>
|
|
360
|
-
```
|
|
361
|
-
|
|
362
|
-
Values: `preferExternal`, `auto`, `internalOnly`
|
|
363
|
-
|
|
364
|
-
Request large heap:
|
|
365
|
-
```xml
|
|
366
|
-
<manifest>
|
|
367
|
-
<application android:largeHeap="true"/>
|
|
368
|
-
</manifest>
|
|
369
|
-
```
|
|
370
|
-
|
|
371
|
-
### Android-specific properties
|
|
372
|
-
|
|
373
|
-
| Property | Type | Default | Description |
|
|
374
|
-
| -------------------------------------- | ------ | ------- | ------------------------------------------ |
|
|
375
|
-
| `ti.android.shake.factor` | double | 1.3 | Shake event sensitivity |
|
|
376
|
-
| `ti.android.shake.quiet.milliseconds` | int | 500 | Quiet time before shake event |
|
|
377
|
-
| `ti.android.shake.active.milliseconds` | int | 1000 | Active time for shake event |
|
|
378
|
-
| `ti.android.httpclient.maxbuffersize` | int | 524288 | HTTP response buffer size (bytes) |
|
|
379
|
-
| `ti.android.compilejs` | bool | - | Enable JS compilation (default: dist only) |
|
|
380
|
-
| `ti.android.debug` | bool | false | Enable detailed logging |
|
|
381
|
-
|
|
382
|
-
```xml
|
|
383
|
-
<property name="ti.android.fastdev">false</property>
|
|
384
|
-
```
|
|
385
|
-
|
|
386
|
-
---
|
|
387
|
-
|
|
388
|
-
## iOS section
|
|
389
|
-
|
|
390
|
-
```xml
|
|
391
|
-
<ti:app>
|
|
392
|
-
<ios>
|
|
393
|
-
<team-id>YOUR_TEAM_ID</team-id>
|
|
394
|
-
<entitlements>
|
|
395
|
-
<dict>
|
|
396
|
-
<key>com.apple.security.application-groups</key>
|
|
397
|
-
<array>
|
|
398
|
-
<string>group.com.titaniumsdk.mycoolapp</string>
|
|
399
|
-
</array>
|
|
400
|
-
</dict>
|
|
401
|
-
</entitlements>
|
|
402
|
-
<extensions>
|
|
403
|
-
...
|
|
404
|
-
</extensions>
|
|
405
|
-
<plist>
|
|
406
|
-
<dict>
|
|
407
|
-
<!-- Info.plist entries -->
|
|
408
|
-
</dict>
|
|
409
|
-
</plist>
|
|
410
|
-
<use-autolayout>true</use-autolayout>
|
|
411
|
-
<min-ios-ver>9.0</min-ios-ver>
|
|
412
|
-
</ios>
|
|
280
|
+
</android>
|
|
413
281
|
</ti:app>
|
|
414
282
|
```
|
|
415
283
|
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
Since 5.0.0. Required for app extensions (share, watch, Siri).
|
|
421
|
-
|
|
422
|
-
```xml
|
|
423
|
-
<team-id>YOUR_TEAM_ID</team-id>
|
|
424
|
-
```
|
|
425
|
-
|
|
426
|
-
#### `<entitlements>`
|
|
427
|
-
|
|
428
|
-
Since 6.1.0. Target entitlements (merged with internal entitlements).
|
|
429
|
-
|
|
430
|
-
```xml
|
|
431
|
-
<entitlements>
|
|
432
|
-
<dict>
|
|
433
|
-
<key>com.apple.security.application-groups</key>
|
|
434
|
-
<array>
|
|
435
|
-
<string>group.com.titaniumsdk.mycoolapp</string>
|
|
436
|
-
</array>
|
|
437
|
-
</dict>
|
|
438
|
-
</entitlements>
|
|
439
|
-
```
|
|
440
|
-
|
|
441
|
-
#### `<extensions>`
|
|
442
|
-
|
|
443
|
-
Since 5.0.0. iOS extensions.
|
|
444
|
-
|
|
445
|
-
```xml
|
|
446
|
-
<extensions>
|
|
447
|
-
<extension projectPath="extensions/foo/foo.xcodeproj">
|
|
448
|
-
<target name="foo WatchApp Extension">
|
|
449
|
-
<provisioning-profiles>
|
|
450
|
-
<devices/>
|
|
451
|
-
<dist-appstore/>
|
|
452
|
-
<dist-adhoc/>
|
|
453
|
-
</provisioning-profiles>
|
|
454
|
-
</target>
|
|
455
|
-
</extension>
|
|
456
|
-
</extensions>
|
|
457
|
-
```
|
|
458
|
-
|
|
459
|
-
#### `<min-ios-ver>`
|
|
460
|
-
|
|
461
|
-
Minimum iOS version.
|
|
462
|
-
|
|
463
|
-
```xml
|
|
464
|
-
<min-ios-ver>9.0</min-ios-ver> <!-- default -->
|
|
465
|
-
```
|
|
466
|
-
|
|
467
|
-
#### `<min-sdk-ver>`
|
|
468
|
-
|
|
469
|
-
Minimum Xcode version.
|
|
470
|
-
|
|
471
|
-
```xml
|
|
472
|
-
<min-sdk-ver>9.0</min-sdk-ver> <!-- default -->
|
|
473
|
-
```
|
|
474
|
-
|
|
475
|
-
#### `<plist>`
|
|
476
|
-
|
|
477
|
-
Settings for generated `Info.plist`. Uses key/value pairs.
|
|
478
|
-
|
|
479
|
-
Orientations:
|
|
480
|
-
```xml
|
|
481
|
-
<plist>
|
|
482
|
-
<dict>
|
|
483
|
-
<key>UISupportedInterfaceOrientations~iphone</key>
|
|
484
|
-
<array>
|
|
485
|
-
<string>UIInterfaceOrientationPortrait</string>
|
|
486
|
-
</array>
|
|
487
|
-
<key>UISupportedInterfaceOrientations~ipad</key>
|
|
488
|
-
<array>
|
|
489
|
-
<string>UIInterfaceOrientationPortrait</string>
|
|
490
|
-
<string>UIInterfaceOrientationPortraitUpsideDown</string>
|
|
491
|
-
<string>UIInterfaceOrientationLandscapeLeft</string>
|
|
492
|
-
<string>UIInterfaceOrientationLandscapeRight</string>
|
|
493
|
-
</array>
|
|
494
|
-
</dict>
|
|
495
|
-
</plist>
|
|
496
|
-
```
|
|
497
|
-
|
|
498
|
-
Background modes:
|
|
499
|
-
```xml
|
|
500
|
-
<plist>
|
|
501
|
-
<dict>
|
|
502
|
-
<key>UIBackgroundModes</key>
|
|
503
|
-
<array>
|
|
504
|
-
<string>audio</string>
|
|
505
|
-
<string>location</string>
|
|
506
|
-
<string>voip</string>
|
|
507
|
-
<string>newsstand-content</string>
|
|
508
|
-
<string>external-accessory</string>
|
|
509
|
-
<string>bluetooth-central</string>
|
|
510
|
-
<string>bluetooth-peripheral</string>
|
|
511
|
-
</array>
|
|
512
|
-
</dict>
|
|
513
|
-
</plist>
|
|
514
|
-
```
|
|
515
|
-
|
|
516
|
-
Device capabilities:
|
|
517
|
-
```xml
|
|
518
|
-
<plist>
|
|
519
|
-
<dict>
|
|
520
|
-
<key>UIRequiredDeviceCapabilities</key>
|
|
521
|
-
<array>
|
|
522
|
-
<string>telephony</string>
|
|
523
|
-
<string>wifi</string>
|
|
524
|
-
<string>sms</string>
|
|
525
|
-
<string>still-camera</string>
|
|
526
|
-
<string>auto-focus-camera</string>
|
|
527
|
-
<string>front-facing-camera</string>
|
|
528
|
-
<string>camera-flash</string>
|
|
529
|
-
<string>video-camera</string>
|
|
530
|
-
<string>accelerometer</string>
|
|
531
|
-
<string>gyroscope</string>
|
|
532
|
-
<string>location-services</string>
|
|
533
|
-
<string>gps</string>
|
|
534
|
-
<string>magnetometer</string>
|
|
535
|
-
<string>gamekit</string>
|
|
536
|
-
<string>microphone</string>
|
|
537
|
-
<string>opengles-1</string>
|
|
538
|
-
<string>opengles-2</string>
|
|
539
|
-
<string>armv6</string>
|
|
540
|
-
<string>armv7</string>
|
|
541
|
-
<string>peer-peer</string>
|
|
542
|
-
<string>bluetooth-le</string>
|
|
543
|
-
</array>
|
|
544
|
-
</dict>
|
|
545
|
-
</plist>
|
|
546
|
-
```
|
|
547
|
-
|
|
548
|
-
Persistent WiFi:
|
|
549
|
-
```xml
|
|
550
|
-
<key>UIRequiresPersistentWiFi</key><true/>
|
|
551
|
-
```
|
|
552
|
-
|
|
553
|
-
Status bar style:
|
|
554
|
-
```xml
|
|
555
|
-
<key>UIStatusBarStyle</key><string>UIStatusBarStyleBlackTranslucent</string>
|
|
556
|
-
```
|
|
557
|
-
|
|
558
|
-
iOS 9 URL schemes:
|
|
559
|
-
```xml
|
|
560
|
-
<key>LSApplicationQueriesSchemes</key>
|
|
561
|
-
<array>
|
|
562
|
-
<string>fbapi</string>
|
|
563
|
-
<string>fbauth2</string>
|
|
564
|
-
<string>twitter</string>
|
|
565
|
-
<string>whatsapp</string>
|
|
566
|
-
<string>instagram</string>
|
|
567
|
-
<string>comgooglemaps</string>
|
|
568
|
-
</array>
|
|
569
|
-
```
|
|
570
|
-
|
|
571
|
-
#### `<use-app-thinning>`
|
|
572
|
-
|
|
573
|
-
Since 5.1.0. Enable App Thinning with Asset Catalog.
|
|
574
|
-
|
|
575
|
-
```xml
|
|
576
|
-
<use-app-thinning>true</use-app-thinning>
|
|
577
|
-
```
|
|
578
|
-
|
|
579
|
-
Use `Ti.Filesystem.getAsset()` to read images from Asset Catalog.
|
|
580
|
-
|
|
581
|
-
#### `<use-autolayout>`
|
|
582
|
-
|
|
583
|
-
Since 5.1.0. Enable iOS auto-layout engine.
|
|
584
|
-
|
|
585
|
-
```xml
|
|
586
|
-
<use-autolayout>true</use-autolayout>
|
|
587
|
-
```
|
|
588
|
-
|
|
589
|
-
#### `<log-server-port>`
|
|
590
|
-
|
|
591
|
-
Since 6.0.0. Custom log server port.
|
|
592
|
-
|
|
593
|
-
```xml
|
|
594
|
-
<log-server-port>27973</log-server-port>
|
|
595
|
-
```
|
|
596
|
-
|
|
597
|
-
### Unsupported Info.plist keys
|
|
598
|
-
|
|
599
|
-
These are auto-generated by Titanium and cannot be overridden:
|
|
600
|
-
- `CFBundleDisplayName`
|
|
601
|
-
- `CFBundleExecutable`
|
|
602
|
-
- `CFBundleIconFile`
|
|
603
|
-
- `CFBundleIconFiles`
|
|
604
|
-
- `CFBundleIdentifier`
|
|
605
|
-
- `CFBundleInfoDictionaryVersion`
|
|
606
|
-
- `CFBundleName`
|
|
607
|
-
- `CFBundlePackageType`
|
|
608
|
-
- `CFBundleSignature`
|
|
609
|
-
- `CFBundleVersion` (pre-4.1.0)
|
|
610
|
-
- `CFBundleShortVersionString` (pre-4.1.0)
|
|
611
|
-
|
|
612
|
-
---
|
|
613
|
-
|
|
614
|
-
## Google Play Services
|
|
615
|
-
|
|
616
|
-
Since 9.0.0. Automatic validation of Google Play Services. Disable if needed:
|
|
617
|
-
|
|
618
|
-
```xml
|
|
619
|
-
<property name="ti.playservices.validate.on.startup" type="bool">false</property>
|
|
620
|
-
```
|
|
621
|
-
|
|
622
|
-
---
|
|
623
|
-
|
|
624
|
-
## timodule.xml (module configuration)
|
|
625
|
-
|
|
626
|
-
Used in custom Titanium modules. Follows the same structure as `tiapp.xml` but only contains platform-specific config (mainly Android).
|
|
627
|
-
|
|
628
|
-
Supports token substitution for app-specific values:
|
|
629
|
-
|
|
630
|
-
```xml
|
|
631
|
-
<!-- timodule.xml -->
|
|
632
|
-
<android xmlns:android="http://schemas.android.com/apk/res/android">
|
|
633
|
-
<manifest>
|
|
634
|
-
<permission android:name="${tiapp.properties['id']}.permission.MY_NEW_PERMISSION"
|
|
635
|
-
android:protectionLevel="signature" />
|
|
636
|
-
</manifest>
|
|
637
|
-
</android>
|
|
638
|
-
```
|
|
639
|
-
|
|
640
|
-
Becomes (for app with ID `com.example.app`):
|
|
641
|
-
|
|
642
|
-
```xml
|
|
643
|
-
<permission android:name="com.example.app.permission.MY_NEW_PERMISSION"
|
|
644
|
-
android:protectionLevel="signature" />
|
|
645
|
-
```
|
|
646
|
-
|
|
647
|
-
Access properties:
|
|
648
|
-
- `${tiapp.properties['id']}`: app ID
|
|
649
|
-
- `${tiapp.properties['name']}`: app name
|
|
650
|
-
- `${tiapp.properties['version']}`: app version
|
|
651
|
-
- `${tiapp.properties['publisher']}`: publisher
|
|
652
|
-
|
|
653
|
-
---
|
|
654
|
-
|
|
655
|
-
## SDK version precedence
|
|
656
|
-
|
|
657
|
-
The CLI checks SDK version in this order:
|
|
658
|
-
|
|
659
|
-
1. `tiapp.xml` `<sdk-version>` tag
|
|
660
|
-
2. `--sdk` CLI option
|
|
661
|
-
3. `app.sdk` config setting (`ti config app.sdk <version>`)
|
|
662
|
-
4. Selected SDK (`ti sdk select`)
|
|
284
|
+
Anything else you put in a `timodule.xml` is accepted by the parser and acted on
|
|
285
|
+
by nothing, so a module cannot set an app's `<property>` or its `<ios>` settings.
|
|
286
|
+
A module's own identity comes from its `manifest` file, not from here.
|
|
663
287
|
|
|
664
|
-
|
|
288
|
+
It is covered on this page rather than its own because two elements are not a
|
|
289
|
+
page, and both of them are the elements documented above behaving the same way
|
|
290
|
+
in a different file. See [native modules](https://titaniumsdk.com/docs/extend/modules) for writing one.
|
|
665
291
|
|
|
666
|
-
##
|
|
292
|
+
## Verification boundaries
|
|
667
293
|
|
|
668
|
-
|
|
669
|
-
- iOS Info.plist Key Reference: http://developer.apple.com/library/ios/#documentation/general/Reference/InfoPlistKeyReference/Articles/iPhoneOSKeys.html
|
|
670
|
-
- Java package naming: http://download.oracle.com/javase/tutorial/java/package/namingpkgs.html
|
|
294
|
+
Use the selected SDK's parser/compiler to verify a setting when a current guide and observed behavior disagree. Source-code encryption is not secure credential storage. On SDK 13.4.1 the `ti.crypt` encryption selector shown elsewhere on the website is not supported by the builders; use the released configuration, and defer SDK 14 changes until GA.
|