aboutsummaryrefslogtreecommitdiff
path: root/node_modules/montage-user/ui/loading.reel/loading.js
diff options
context:
space:
mode:
authorValerio Virgillito2012-02-01 00:09:27 -0800
committerValerio Virgillito2012-02-01 00:09:27 -0800
commit8592cfb89db05f0e52d8c1b8c7046e6f49e3522d (patch)
treea6f9b5adfe16fd6232708f8a2345cd79056caca9 /node_modules/montage-user/ui/loading.reel/loading.js
parentc6d1a1da9e7cdf477daf32410d80691eb1e828d5 (diff)
downloadninja-8592cfb89db05f0e52d8c1b8c7046e6f49e3522d.tar.gz
Adding a montage framework copy for the user document
Adding a new montage copy containing the latest version of montage to use the new native widgets Signed-off-by: Valerio Virgillito <valerio@motorola.com>
Diffstat (limited to 'node_modules/montage-user/ui/loading.reel/loading.js')
-rwxr-xr-xnode_modules/montage-user/ui/loading.reel/loading.js61
1 files changed, 61 insertions, 0 deletions
diff --git a/node_modules/montage-user/ui/loading.reel/loading.js b/node_modules/montage-user/ui/loading.reel/loading.js
new file mode 100755
index 00000000..f0574d72
--- /dev/null
+++ b/node_modules/montage-user/ui/loading.reel/loading.js
@@ -0,0 +1,61 @@
1/* <copyright>
2 This file contains proprietary software owned by Motorola Mobility, Inc.<br/>
3 No rights, expressed or implied, whatsoever to this software are provided by Motorola Mobility, Inc. hereunder.<br/>
4 (c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved.
5 </copyright> */
6/**
7 @module "montage/ui/loading.reel"
8 @requires montage/core/core
9 @requires montage/ui/component
10*/
11var Montage = require("montage").Montage,
12 Component = require("ui/component").Component;
13/**
14 @class module:montage/ui/loading.Loading
15 @extends module:montage/ui/component.Component
16 */
17
18var Loading = exports.Loading = Montage.create(Component,/** @lends module:"montage/ui/loading.reel".Loading# */ {
19/**
20 Description TODO
21 @private
22*/
23 _loading: {
24 value: null
25 },
26/**
27 Description TODO
28 @type {Function}
29 @default null
30 */
31 loading: {
32 get: function() {
33 return this._loading;
34 },
35 set: function(isloading) {
36 if (this._loading !== isloading) {
37 this._loading = isloading;
38 this.needsDraw = true;
39 }
40 }
41 },
42/**
43 Description TODO
44 @function
45 */
46 draw: {
47 value: function() {
48 var classList = this.element.classList, exists = classList.contains("animate");
49 if (this.loading) {
50 if (!exists) {
51 classList.add("animate");
52 }
53 } else {
54 if (exists) {
55 classList.remove("animate");
56 }
57
58 }
59 }
60 }
61});