alloy 3.0.0 → 3.1.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.
Files changed (74) hide show
  1. package/.github/workflows/cla.yaml +1 -1
  2. package/Alloy/alloy.js +7 -4
  3. package/Alloy/builtins/social.js +1 -1
  4. package/Alloy/builtins/string.js +1 -4
  5. package/Alloy/commands/compile/Orphanage.js +1 -2
  6. package/Alloy/commands/compile/README.md +1 -1
  7. package/Alloy/commands/compile/ast/builtins-plugin.js +1 -1
  8. package/Alloy/commands/compile/ast/controller.js +52 -27
  9. package/Alloy/commands/compile/compilerUtils.js +24 -11
  10. package/Alloy/commands/compile/index.js +211 -62
  11. package/Alloy/commands/compile/parsers/Alloy.Abstract._BackboneClass.js +3 -2
  12. package/Alloy/commands/compile/parsers/Alloy.Require.js +10 -4
  13. package/Alloy/commands/compile/parsers/Ti.UI.ActivityIndicator.js +9 -0
  14. package/Alloy/commands/compile/parsers/Ti.UI.Column.js +9 -0
  15. package/Alloy/commands/compile/parsers/Ti.UI.MaskedImage.js +9 -0
  16. package/Alloy/commands/compile/parsers/Ti.UI.Notification.js +9 -0
  17. package/Alloy/commands/compile/parsers/Ti.UI.ProgressBar.js +9 -0
  18. package/Alloy/commands/compile/parsers/Ti.UI.RefreshControl.js +9 -0
  19. package/Alloy/commands/compile/parsers/Ti.UI.Row.js +9 -0
  20. package/Alloy/commands/compile/parsers/Ti.UI.SearchBar.js +9 -0
  21. package/Alloy/commands/compile/parsers/Ti.UI.Shortcut.js +9 -0
  22. package/Alloy/commands/compile/parsers/Ti.UI.ShortcutItem.js +9 -0
  23. package/Alloy/commands/compile/sourceMapper.js +0 -16
  24. package/Alloy/commands/compile/styler.js +101 -58
  25. package/Alloy/commands/db/index.js +76 -0
  26. package/Alloy/commands/generate/targets/jmk.js +1 -1
  27. package/Alloy/commands/generate/targets/style.js +1 -1
  28. package/Alloy/commands/generate/targets/widget.js +2 -2
  29. package/Alloy/commands/new/index.js +1 -1
  30. package/Alloy/commands/purgetss/index.js +5 -0
  31. package/Alloy/common/constants.js +2 -11
  32. package/Alloy/lib/alloy/sync/localStorage.js +0 -8
  33. package/Alloy/lib/alloy/sync/sql.js +12 -9
  34. package/Alloy/plugin/plugin.py +1 -123
  35. package/Alloy/template/lib/alloy.js +7 -8
  36. package/Alloy/tiapp.js +18 -0
  37. package/CHANGELOG.md +6 -0
  38. package/README.md +4 -0
  39. package/package.json +1 -1
  40. package/platforms/windows/index.js +0 -4
  41. package/samples/apps/advanced/complex_styling/config.json +1 -4
  42. package/samples/apps/advanced/custom_tss_queries/styles/index.tss +0 -6
  43. package/samples/apps/advanced/device_query/specs/index.js +1 -12
  44. package/samples/apps/advanced/device_query/styles/index.tss +0 -12
  45. package/samples/apps/advanced/form_factor/views/index.xml +1 -7
  46. package/samples/apps/advanced/inheritance/controllers/index.js +4 -8
  47. package/samples/apps/advanced/inheritance/specs/baseDialog.js +2 -2
  48. package/samples/apps/advanced/master_detail/specs/row.js +3 -3
  49. package/samples/apps/advanced/proxy_property_requires/widgets/com.foo.widget/views/section.xml +3 -3
  50. package/samples/apps/advanced/proxy_property_requires/widgets/com.foo.widget/widget.json +2 -2
  51. package/samples/apps/advanced/require_children/widgets/alloy.container/widget.json +2 -2
  52. package/samples/apps/advanced/themes/specs/dialog.js +1 -18
  53. package/samples/apps/advanced/themes/specs/index.js +1 -45
  54. package/samples/apps/advanced/theming_widgets/widgets/starrating/widget.json +2 -2
  55. package/samples/apps/basics/builtins/specs/index.js +2 -2
  56. package/samples/apps/basics/config_json/config.json +1 -4
  57. package/samples/apps/basics/global_style/specs/item.js +2 -2
  58. package/samples/apps/basics/simple/specs/index.js +2 -2
  59. package/samples/apps/models/binding_tableview/controllers/tab_1.js +2 -2
  60. package/samples/apps/models/binding_tableview/controllers/tab_2.js +2 -2
  61. package/samples/apps/models/binding_tableview/controllers/tab_3.js +2 -2
  62. package/samples/apps/models/binding_tableview/controllers/tab_4.js +2 -2
  63. package/samples/apps/ui/buttonbar/views/index.xml +1 -1
  64. package/samples/apps/ui/switch/views/index.xml +2 -2
  65. package/samples/apps/widgets/basic/widgets/com.foo.widget/widget.json +2 -2
  66. package/samples/apps/widgets/complex/widgets/com.appcelerator.loading/widget.json +1 -1
  67. package/samples/apps/widgets/complex/widgets/com.testing.searchForBooks/widget.json +1 -1
  68. package/samples/apps/widgets/models/widgets/alloy.datatable/widget.json +1 -1
  69. package/samples/apps/widgets/wpath/widgets/com.test.hellobutton/widget.json +1 -1
  70. package/test/specs/new.js +0 -2
  71. package/test/specs/optimizer.js +0 -2
  72. package/test/specs/purgetss.js +74 -0
  73. package/test/specs/require.js +94 -0
  74. package/test/specs/styler.js +271 -0
@@ -1,123 +1 @@
1
- import os, sys, subprocess, hashlib
2
-
3
- import subprocess
4
-
5
- def check_output(*popenargs, **kwargs):
6
- r"""Run command with arguments and return its output as a byte string.
7
-
8
- Backported from Python 2.7 as it's implemented as pure python on stdlib.
9
-
10
- >>> check_output(['/usr/bin/python', '--version'])
11
- Python 2.6.2
12
- """
13
- process = subprocess.Popen(stdout=subprocess.PIPE, *popenargs, **kwargs)
14
- output, unused_err = process.communicate()
15
- retcode = process.poll()
16
- if retcode:
17
- cmd = kwargs.get("args")
18
- if cmd is None:
19
- cmd = popenargs[0]
20
- error = subprocess.CalledProcessError(retcode, cmd)
21
- error.output = output
22
- raise error
23
- return output
24
-
25
- def compile(config):
26
- paths = {}
27
- binaries = ["alloy","node"]
28
-
29
- dotAlloy = os.path.abspath(os.path.join(config['project_dir'], 'build', '.alloynewcli'))
30
- if os.path.exists(dotAlloy):
31
- print "[DEBUG] build/.alloynewcli file found, skipping plugin..."
32
- os.remove(dotAlloy)
33
- else:
34
- for binary in binaries:
35
- try:
36
- # see if the environment variable is defined
37
- paths[binary] = os.environ["ALLOY_" + ("NODE_" if binary == "node" else "") + "PATH"]
38
- except KeyError as ex:
39
- # next try PATH, and then our guess paths
40
- if sys.platform == "darwin" or sys.platform.startswith('linux'):
41
- userPath = os.environ["HOME"]
42
- guessPaths = [
43
- "/usr/local/bin/"+binary,
44
- "/opt/local/bin/"+binary,
45
- userPath+"/local/bin/"+binary,
46
- "/opt/bin/"+binary,
47
- "/usr/bin/"+binary,
48
- "/usr/local/share/npm/bin/"+binary
49
- ]
50
-
51
- try:
52
- binaryPath = check_output(["which",binary], stderr=subprocess.STDOUT).strip()
53
- print "[DEBUG] %s installed at '%s'" % (binary,binaryPath)
54
- except:
55
- print "[WARN] Couldn't find %s on your PATH:" % binary
56
- print "[WARN] %s" % os.environ["PATH"]
57
- print "[WARN]"
58
- print "[WARN] Checking for %s in a few default locations:" % binary
59
- for p in guessPaths:
60
- sys.stdout.write("[WARN] %s -> " % p)
61
- if os.path.exists(p):
62
- binaryPath = p
63
- print "FOUND"
64
- break
65
- else:
66
- print "not found"
67
- binaryPath = None
68
-
69
- if binaryPath is None:
70
- print "[ERROR] Couldn't find %s" % binary
71
- sys.exit(1)
72
- else:
73
- paths[binary] = binaryPath
74
-
75
- # no guesses on windows, just use the PATH
76
- elif sys.platform == "win32":
77
- paths["alloy"] = "alloy.cmd"
78
-
79
- f = os.path.abspath(os.path.join(config['project_dir'], 'app'))
80
- if os.path.exists(f):
81
- print "[INFO] alloy app found at %s" % f
82
- rd = os.path.abspath(os.path.join(config['project_dir'], 'Resources'))
83
-
84
- devicefamily = 'none'
85
- simtype = 'none'
86
- version = '0'
87
- deploytype = 'development'
88
-
89
- if config['platform']==u'ios':
90
- version = config['iphone_version']
91
- devicefamily = config['devicefamily']
92
- deploytype = config['deploytype']
93
- if config['platform']==u'android':
94
- builder = config['android_builder']
95
- version = builder.tool_api_level
96
- deploytype = config['deploy_type']
97
- if config['platform']==u'mobileweb':
98
- builder = config['mobileweb_builder']
99
- deploytype = config['deploytype']
100
-
101
- cfg = "platform=%s,version=%s,simtype=%s,devicefamily=%s,deploytype=%s," % (config['platform'],version,simtype,devicefamily,deploytype)
102
-
103
- if sys.platform == "win32":
104
- cmd = [paths["alloy"], "compile", f, "--no-colors", "--config", cfg]
105
- else:
106
- cmd = [paths["node"], paths["alloy"], "compile", f, "--no-colors", "--config", cfg]
107
-
108
- print "[INFO] Executing Alloy compile:"
109
- print "[INFO] %s" % " ".join(cmd)
110
-
111
- try:
112
- print check_output(cmd, stderr=subprocess.STDOUT)
113
- except subprocess.CalledProcessError as ex:
114
- if hasattr(ex, 'output'):
115
- print ex.output
116
- print "[ERROR] Alloy compile failed"
117
- retcode = 1
118
- if hasattr(ex, 'returncode'):
119
- retcode = ex.returncode
120
- sys.exit(retcode)
121
- except EnvironmentError as ex:
122
- print "[ERROR] Unexpected error with Alloy compiler plugin: %s" % ex.strerror
123
- sys.exit(2)
1
+ #
@@ -32,7 +32,6 @@ exports._ = _;
32
32
  exports.Backbone = Backbone;
33
33
 
34
34
  var DEFAULT_WIDGET = 'widget';
35
- var MW320_CHECK = OS_MOBILEWEB;
36
35
  var IDENTITY_TRANSFORM = OS_ANDROID ? (Ti.UI.createMatrix2D ? Ti.UI.createMatrix2D() : Ti.UI.create2DMatrix()) : undefined;
37
36
  var RESET = {
38
37
  bottom: null,
@@ -203,6 +202,12 @@ exports.C = function(name, modelDesc, model) {
203
202
  return Collection;
204
203
  };
205
204
 
205
+ function resolveNS(ns) {
206
+ var parts = ns.split('.'), obj = global, i = 0;
207
+ for (; i < parts.length; i++) { obj = obj[parts[i]]; }
208
+ return obj;
209
+ }
210
+
206
211
  exports.UI = {};
207
212
  exports.UI.create = function(controller, apiName, opts) {
208
213
  opts = opts || {};
@@ -226,7 +231,7 @@ exports.UI.create = function(controller, apiName, opts) {
226
231
  var style = exports.createStyle(controller, opts);
227
232
 
228
233
  // create the titanium proxy object
229
- return eval(ns)['create' + baseName](style);
234
+ return resolveNS(ns)['create' + baseName](style);
230
235
  };
231
236
 
232
237
  exports.createStyle = function(controller, opts, defaults) {
@@ -318,8 +323,6 @@ exports.createStyle = function(controller, opts, defaults) {
318
323
  styleFinal[CONST.CLASS_PROPERTY] = classes;
319
324
  styleFinal[CONST.APINAME_PROPERTY] = apiName;
320
325
 
321
- if (MW320_CHECK) { delete styleFinal[CONST.APINAME_PROPERTY]; }
322
-
323
326
  return defaults ? _.defaults(styleFinal, defaults) : styleFinal;
324
327
  };
325
328
 
@@ -337,7 +340,6 @@ exports.addClass = function(controller, proxy, classes, opts) {
337
340
  // make sure we actually have classes to add
338
341
  if (!classes) {
339
342
  if (opts) {
340
- if (MW320_CHECK) { delete opts.apiName; }
341
343
  proxy.applyProperties(opts);
342
344
  }
343
345
  return;
@@ -351,7 +353,6 @@ exports.addClass = function(controller, proxy, classes, opts) {
351
353
  // make sure we actually added classes before processing styles
352
354
  if (beforeLen === newClasses.length) {
353
355
  if (opts) {
354
- if (MW320_CHECK) { delete opts.apiName; }
355
356
  proxy.applyProperties(opts);
356
357
  }
357
358
  return;
@@ -369,7 +370,6 @@ exports.removeClass = function(controller, proxy, classes, opts) {
369
370
  // make sure there's classes to remove before processing
370
371
  if (!beforeLen || !classes.length) {
371
372
  if (opts) {
372
- if (MW320_CHECK) { delete opts.apiName; }
373
373
  proxy.applyProperties(opts);
374
374
  }
375
375
  return;
@@ -381,7 +381,6 @@ exports.removeClass = function(controller, proxy, classes, opts) {
381
381
  // make sure there was actually a difference before processing
382
382
  if (beforeLen === newClasses.length) {
383
383
  if (opts) {
384
- if (MW320_CHECK) { delete opts.apiName; }
385
384
  proxy.applyProperties(opts);
386
385
  }
387
386
  return;
package/Alloy/tiapp.js CHANGED
@@ -39,6 +39,24 @@ tiapp.getSdkVersion = function() {
39
39
  }
40
40
  };
41
41
 
42
+ tiapp.getBundleId = function() {
43
+ var elems = doc.documentElement.getElementsByTagName('id');
44
+ if (elems && elems.length > 0) {
45
+ var bundleId = U.XML.getNodeText(elems.item(elems.length - 1));
46
+ var isForced = false;
47
+ for (var i = 0; i < elems.length; i++) {
48
+ if (elems.item(i).getAttribute('platform') === 'android') {
49
+ // platform specific ID
50
+ isForced = true;
51
+ bundleId = U.XML.getNodeText(elems.item(i));
52
+ } else if (elems.item(i).getAttribute('platform') === '' && !isForced) {
53
+ // normal ID - only if no platform specific was set already
54
+ bundleId = U.XML.getNodeText(elems.item(i));
55
+ }
56
+ }
57
+ return bundleId;
58
+ }
59
+ };
42
60
 
43
61
  // Get the value of a property from the tiapp.xml
44
62
  tiapp.getProperty = function(name) {
package/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ ## Unreleased
2
+
3
+ ### Deprecated
4
+
5
+ * Deprecate the `alloy purgetss` shortcut. Use the standalone `purgetss` CLI instead.
6
+
1
7
  # [2.1.0](https://github.com/tidev/alloy/compare/2.0.2...2.1.0) (2024-01-09)
2
8
 
3
9
 
package/README.md CHANGED
@@ -23,6 +23,10 @@ Alloy is an MVC application framework by [TiDev](https://tidev.io) for the [Tita
23
23
  [sudo] npm install -g git://github.com/tidev/alloy.git
24
24
  ```
25
25
 
26
+ ## PurgeTSS
27
+
28
+ The `alloy purgetss` shortcut is deprecated and remains available for compatibility. Install the standalone CLI with `npm install -g purgetss`, then run `purgetss` directly from your Alloy project directory. Use `purgetss --help` for the current commands and options.
29
+
26
30
  ## Running Sample Test Apps
27
31
 
28
32
  Alloy includes many sample and test apps in the **sample/apps** folder (see above). For example, [basics/simple](https://github.com/tidev/alloy/tree/master/samples/apps/basics/simple). You can run these in a few different ways:
package/package.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "html5",
12
12
  "appc-client"
13
13
  ],
14
- "version": "3.0.0",
14
+ "version": "3.1.0",
15
15
  "author": "TiDev, Inc. <npm@tidev.io>",
16
16
  "bugs": {
17
17
  "url": "https://github.com/tidev/alloy/issues"
@@ -1,7 +1,3 @@
1
1
  module.exports = new (require('../base.js'))({
2
2
  platform: 'windows',
3
- alloyFolder: 'windows',
4
- titaniumFolder: 'windows',
5
- name: 'Windows Phone',
6
- osname: ['windowsphone', 'windowsstore']
7
3
  });
@@ -11,8 +11,5 @@
11
11
  "os:android": {
12
12
  "theme":"android"
13
13
  },
14
- "os:mobileweb":{
15
- "theme":"mobileweb"
16
- },
17
14
  "dependencies": {}
18
- }
15
+ }
@@ -37,12 +37,6 @@
37
37
  "#title2[platform=ios if=Alloy.Globals.someProperty]": {
38
38
  text: "Platform: iOS, Alloy.Globals.someProperty==true"
39
39
  }
40
- "#title2[platform=mobileweb if=Alloy.Globals.someProperty]": {
41
- text: "Platform: MobileWeb, Alloy.Globals.someProperty==true"
42
- }
43
- "#title2[platform=windows if=Alloy.Globals.someProperty]": {
44
- text: "Platform: Windows, Alloy.Globals.someProperty==true"
45
- }
46
40
 
47
41
  /* ID selector overrides other selectors if platform is iOS */
48
42
  "#title3":{
@@ -9,12 +9,7 @@ module.exports = function($) {
9
9
  bgColor = '#0f0';
10
10
  } else if (OS_IOS) {
11
11
  bgColor = '#f00';
12
- } else if (OS_MOBILEWEB) {
13
- bgColor = '#00f';
14
12
  }
15
- // else if (OS_BLACKBERRY) {
16
- // bgColor = '#0ff';
17
- // }
18
13
 
19
14
  validateUiComponent($, 'win', {
20
15
  api: 'Ti.UI.Window',
@@ -34,12 +29,6 @@ module.exports = function($) {
34
29
  color = '#000';
35
30
  } else if (OS_IOS) {
36
31
  text = Alloy.isTablet ? 'iPad' : 'iPhone';
37
- } else if (OS_MOBILEWEB) {
38
- text = 'Mobileweb';
39
- // } else if (OS_BLACKBERRY) {
40
- // text = 'Blackberry';
41
- } else if (OS_WINDOWS) {
42
- text = 'Windows';
43
32
  }
44
33
 
45
34
  validateUiComponent($, 'osLabel', {
@@ -50,7 +39,7 @@ module.exports = function($) {
50
39
  width: Ti.UI.SIZE,
51
40
  textAlign: 'center',
52
41
  font: {
53
- fontSize: (Alloy.isTablet ? 96 : 48) + (OS_MOBILEWEB ? 'px' : 0),
42
+ fontSize: (Alloy.isTablet ? 96 : 48),
54
43
  fontWeight: 'bold'
55
44
  },
56
45
  text: text,
@@ -58,15 +58,3 @@
58
58
  text: "Android\nTablet",
59
59
  color: "#000"
60
60
  }
61
-
62
- "#osLabel[platform=mobileweb]": {
63
- text: "Mobileweb"
64
- }
65
-
66
- "#osLabel[platform=blackberry]": {
67
- text: "Blackberry"
68
- }
69
-
70
- "#osLabel[platform=windows]": {
71
- text: "Windows"
72
- }
@@ -13,12 +13,6 @@
13
13
  <Label id="platformLabel" platform="android" formFactor="handheld">android handheld</Label>
14
14
  <Label id="platformLabel" platform="ios" formFactor="tablet">ipad</Label>
15
15
  <Label id="platformLabel" platform="ios" formFactor="handheld">iphone</Label>
16
- <Label id="platformLabel" platform="blackberry" formFactor="tablet">blackberry tablet</Label>
17
- <Label id="platformLabel" platform="blackberry" formFactor="handheld">blackberry handheld</Label>
18
- <Label id="platformLabel" platform="mobileweb" formFactor="tablet">mobileweb tablet</Label>
19
- <Label id="platformLabel" platform="mobileweb" formFactor="handheld">mobileweb handheld</Label>
20
- <Label id="platformLabel" platform="windows" formFactor="handheld">windows handheld</Label>
21
- <Label id="platformLabel" platform="windows" formFactor="tablet">windows tablet</Label>
22
16
  </View>
23
17
  </Window>
24
- </Alloy>
18
+ </Alloy>
@@ -1,11 +1,7 @@
1
1
  function openDialog(e) {
2
- if (OS_MOBILEWEB) {
3
- alert('Mobileweb version not full implemented.\nSee TIMOB-13816 for details.');
4
- } else {
5
- Alloy.createController(e.source.title, {
6
- message: 'Opened ' + e.source.title
7
- }).openDialog($.index);
8
- }
2
+ Alloy.createController(e.source.title, {
3
+ message: 'Opened ' + e.source.title
4
+ }).openDialog($.index);
9
5
  }
10
6
 
11
7
  $.index.open();
@@ -13,4 +9,4 @@ $.index.open();
13
9
  // runtime unit tests
14
10
  if (!ENV_PROD) {
15
11
  require('specs/index')($);
16
- }
12
+ }
@@ -41,7 +41,7 @@ module.exports = function($, opts) {
41
41
  top: 10,
42
42
  height: Ti.UI.SIZE,
43
43
  font: {
44
- fontSize: OS_MOBILEWEB ? '16px' : '16dp'
44
+ fontSize: '16dp'
45
45
  },
46
46
  textAlign: 'center',
47
47
  text: opts.message,
@@ -60,4 +60,4 @@ module.exports = function($, opts) {
60
60
  });
61
61
 
62
62
  launchTests();
63
- };
63
+ };
@@ -22,7 +22,7 @@ module.exports = function($, opts) {
22
22
  top: '5dp',
23
23
  left: '10dp',
24
24
  font: {
25
- fontSize: OS_MOBILEWEB ? '24px' : '24dp',
25
+ fontSize: '24dp',
26
26
  fontWeight: 'bold'
27
27
  },
28
28
  id: 'name'
@@ -38,7 +38,7 @@ module.exports = function($, opts) {
38
38
  bottom: '5dp',
39
39
  left: '20dp',
40
40
  font: {
41
- fontSize: OS_MOBILEWEB ? '16px' : '16dp',
41
+ fontSize: '16dp',
42
42
  fontWeight: 'normal'
43
43
  },
44
44
  id: 'nickname'
@@ -50,4 +50,4 @@ module.exports = function($, opts) {
50
50
  expect($.nickname.text).toEqual(opts.nickname);
51
51
  });
52
52
  });
53
- };
53
+ };
@@ -1,5 +1,5 @@
1
1
  <Alloy>
2
- <TableViewSection platform="android,windows">
2
+ <TableViewSection platform="android">
3
3
  <HeaderView>
4
4
  <Label>Test</Label>
5
5
  </HeaderView>
@@ -7,9 +7,9 @@
7
7
  <TableViewRow title="android row"/>
8
8
  <TableViewRow title="android row"/>
9
9
  </TableViewSection>
10
- <TableViewSection platform="ios,mobileweb" headerTitle="Test">
10
+ <TableViewSection platform="ios" headerTitle="Test">
11
11
  <TableViewRow title="table row"/>
12
12
  <TableViewRow title="table row"/>
13
13
  <TableViewRow title="table row"/>
14
14
  </TableViewSection>
15
- </Alloy>
15
+ </Alloy>
@@ -9,6 +9,6 @@
9
9
  "min-alloy-version": "1.0",
10
10
  "min-titanium-version":"2.1",
11
11
  "tags":"",
12
- "platforms":"android,ios,mobileweb,windows",
12
+ "platforms":"android,ios",
13
13
  "dependencies": {}
14
- }
14
+ }
@@ -4,6 +4,6 @@
4
4
  "description" : "Alloy Container",
5
5
  "author": "Tony Lukasavage",
6
6
  "version": "1.0",
7
- "platforms":"android,ios,mobileweb,blackberry,windows",
7
+ "platforms":"android,ios",
8
8
  "dependencies": {}
9
- }
9
+ }
@@ -47,23 +47,6 @@ module.exports = function($, opts) {
47
47
  backgroundImage: '/button_green.png'
48
48
  }
49
49
  };
50
- } else if (OS_MOBILEWEB) {
51
- styler = {
52
- mainView: {
53
- backgroundImage: '/bg_gray.png',
54
- borderColor: '#1e99fd'
55
- },
56
- progressBack: {
57
- backgroundColor: '#333'
58
- },
59
- progressFront: {
60
- backgroundImage: '/title_blue.png'
61
- },
62
- button: {
63
- backgroundImage: '/button_blue.png',
64
- color: '#fff'
65
- }
66
- };
67
50
  }
68
51
 
69
52
  $.__styler = styler;
@@ -144,4 +127,4 @@ module.exports = function($, opts) {
144
127
  });
145
128
 
146
129
  launchTests();
147
- };
130
+ };
@@ -67,50 +67,6 @@ module.exports = function($) {
67
67
  right: 15
68
68
  }
69
69
  };
70
- } else if (OS_MOBILEWEB) {
71
- styler = {
72
- index: {
73
- backgroundImage: '/bg_gray.png'
74
- },
75
- title: {
76
- color: '#fff',
77
- backgroundImage: '/title_blue.png',
78
- font: {
79
- fontSize: '24px',
80
- fontWeight: 'bold'
81
- }
82
- },
83
- container: {
84
- backgroundGradient: {
85
- type: 'linear',
86
- startPoint: {
87
- x: '0%',
88
- y: '0%'
89
- },
90
- endPoint: {
91
- x: '0%',
92
- y: '100%'
93
- },
94
- colors: [ '#39abfb', '#0285ff' ]
95
- }
96
- },
97
- label: {
98
- color: '#fff',
99
- font: {
100
- fontSize: '140px',
101
- fontWeight: 'bold'
102
- }
103
- },
104
- slider: {
105
- leftTrackImage: '/title_blue.png',
106
- bottom: 100,
107
- width: 250
108
- },
109
- testButton: {
110
- color: '#fff',
111
- backgroundImage: '/button_blue.png'
112
- }
113
- };
114
70
  }
115
71
 
116
72
  // add the styer as a hidden argument to the controller to
@@ -194,4 +150,4 @@ module.exports = function($) {
194
150
  });
195
151
 
196
152
  launchTests();
197
- };
153
+ };
@@ -9,5 +9,5 @@
9
9
  "min-alloy-version": "1.0",
10
10
  "min-titanium-version":"3.0",
11
11
  "tags":"",
12
- "platforms":"android,ios,mobileweb,windows"
13
- }
12
+ "platforms":"android,ios"
13
+ }
@@ -27,7 +27,7 @@ module.exports = function($) {
27
27
  style: {
28
28
  color: '#eee',
29
29
  font: {
30
- fontSize: OS_MOBILEWEB ? '28px' : '28dp',
30
+ fontSize: '28dp',
31
31
  fontWeight: 'bold'
32
32
  },
33
33
  text: 'Trimmable String',
@@ -72,4 +72,4 @@ module.exports = function($) {
72
72
  });
73
73
 
74
74
  launchTests();
75
- };
75
+ };
@@ -1,10 +1,7 @@
1
1
  {
2
2
  "global": { "someValue": "unknown" },
3
3
  "os:android": { "someValue": "Android" },
4
- "os:blackberry": { "someValue": "Blackberry" },
5
4
  "os:ios": { "someValue": "iOS" },
6
- "os:mobileweb": { "someValue": "Mobileweb" },
7
- "os:windows": { "someValue": "Windows" },
8
5
  "sourcemap": false,
9
6
  "adapters": []
10
- }
7
+ }
@@ -17,7 +17,7 @@ module.exports = function($) {
17
17
  style: {
18
18
  color: '#f00',
19
19
  font: {
20
- fontSize: OS_MOBILEWEB ? '24px' : 24,
20
+ fontSize: 24,
21
21
  fontWeight: 'bold'
22
22
  },
23
23
  textAlign: 'center',
@@ -26,4 +26,4 @@ module.exports = function($) {
26
26
  }
27
27
  });
28
28
  });
29
- };
29
+ };
@@ -19,7 +19,7 @@ module.exports = function($) {
19
19
  style: {
20
20
  color: '#000',
21
21
  font: {
22
- fontSize: OS_MOBILEWEB ? '18px' : '18dp',
22
+ fontSize: '18dp',
23
23
  fontWeight: 'bold'
24
24
  },
25
25
  height: Ti.UI.SIZE,
@@ -37,4 +37,4 @@ module.exports = function($) {
37
37
  });
38
38
 
39
39
  launchTests();
40
- };
40
+ };
@@ -13,9 +13,9 @@ function removeItem(e) {
13
13
  common.removeItem(myModels, e.index);
14
14
  }
15
15
 
16
- if (OS_IOS || OS_MOBILEWEB) {
16
+ if (OS_IOS) {
17
17
  common.prepNavBar($.window, addItem);
18
18
  }
19
19
 
20
20
  myModels.comparator = common.comparator;
21
- myModels.fetch();
21
+ myModels.fetch();
@@ -13,8 +13,8 @@ function removeItem(e) {
13
13
  common.removeItem(myModels, e.index);
14
14
  }
15
15
 
16
- if (OS_IOS || OS_MOBILEWEB) {
16
+ if (OS_IOS) {
17
17
  common.prepNavBar($.window, addItem);
18
18
  }
19
19
 
20
- myModels.fetch();
20
+ myModels.fetch();
@@ -14,9 +14,9 @@ function removeItem(e) {
14
14
  common.removeItem(myModels, e.index);
15
15
  }
16
16
 
17
- if (OS_IOS || OS_MOBILEWEB) {
17
+ if (OS_IOS) {
18
18
  common.prepNavBar($.window, addItem);
19
19
  }
20
20
 
21
21
  myModels.comparator = common.comparator;
22
- myModels.fetch();
22
+ myModels.fetch();
@@ -14,9 +14,9 @@ function removeItem(e) {
14
14
  common.removeItem(myModels, e.index);
15
15
  }
16
16
 
17
- if (OS_IOS || OS_MOBILEWEB) {
17
+ if (OS_IOS) {
18
18
  common.prepNavBar($.window, addItem);
19
19
  }
20
20
 
21
21
  myModels.comparator = common.comparator;
22
- myModels.fetch();
22
+ myModels.fetch();
@@ -23,6 +23,6 @@
23
23
  -->
24
24
  <!-- <View opacity="0.25" backgroundColor="#a00" width="50%"/> -->
25
25
  </ButtonBar>
26
- <Label platform="android,mobileweb">Ti.UI.ButtonBar only supported on iOS</Label>
26
+ <Label platform="android">Ti.UI.ButtonBar only supported on iOS</Label>
27
27
  </Window>
28
28
  </Alloy>