diff options
Diffstat (limited to 'node_modules/montage/ui/flow-path-lerp.js')
-rwxr-xr-x | node_modules/montage/ui/flow-path-lerp.js | 36 |
1 files changed, 15 insertions, 21 deletions
diff --git a/node_modules/montage/ui/flow-path-lerp.js b/node_modules/montage/ui/flow-path-lerp.js index 42c168ce..b88fee39 100755 --- a/node_modules/montage/ui/flow-path-lerp.js +++ b/node_modules/montage/ui/flow-path-lerp.js | |||
@@ -1,33 +1,27 @@ | |||
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 | var Montage = require("montage").Montage; | 1 | var Montage = require("montage").Montage; |
8 | 2 | ||
9 | var FlowPathLerp = exports.FlowPathLerp = Montage.create(Montage, { | 3 | var FlowPathLerp = exports.FlowPathLerp = Montage.create(Montage, { |
10 | 4 | ||
11 | _path1: { | 5 | _path1: { |
12 | enumerable: false, | 6 | enumerable: false, |
13 | value: null | 7 | value: null |
14 | }, | 8 | }, |
15 | 9 | ||
16 | _path2: { | 10 | _path2: { |
17 | enumerable: false, | 11 | enumerable: false, |
18 | value: null | 12 | value: null |
19 | }, | 13 | }, |
20 | 14 | ||
21 | _interpolant: { | 15 | _interpolant: { |
22 | enumerable: false, | 16 | enumerable: false, |
23 | value: 0 | 17 | value: 0 |
24 | }, | 18 | }, |
25 | 19 | ||
26 | path1: { | 20 | path1: { |
27 | get: function () { | 21 | get: function () { |
28 | return this._path1; | 22 | return this._path1; |
29 | }, | 23 | }, |
30 | set: function (value) { | 24 | set: function (value) { |
31 | this._path1 = value; | 25 | this._path1 = value; |
32 | this.resultPath = true; | 26 | this.resultPath = true; |
33 | } | 27 | } |
@@ -37,12 +31,12 @@ var FlowPathLerp = exports.FlowPathLerp = Montage.create(Montage, { | |||
37 | get: function () { | 31 | get: function () { |
38 | return this._path2; | 32 | return this._path2; |
39 | }, | 33 | }, |
40 | set: function (value) { | 34 | set: function (value) { |
41 | this._path2 = value; | 35 | this._path2 = value; |
42 | this.resultPath = true; | 36 | this.resultPath = true; |
43 | } | 37 | } |
44 | }, | 38 | }, |
45 | 39 | ||
46 | interpolant: { | 40 | interpolant: { |
47 | get: function () { | 41 | get: function () { |
48 | return this._interpolant; | 42 | return this._interpolant; |
@@ -52,19 +46,19 @@ var FlowPathLerp = exports.FlowPathLerp = Montage.create(Montage, { | |||
52 | this.resultPath = true; | 46 | this.resultPath = true; |
53 | } | 47 | } |
54 | }, | 48 | }, |
55 | 49 | ||
56 | _resultPath: { | 50 | _resultPath: { |
57 | enumerable: false, | 51 | enumerable: false, |
58 | value: null | 52 | value: null |
59 | }, | 53 | }, |
60 | 54 | ||
61 | resultPath: { | 55 | resultPath: { |
62 | get: function () { | 56 | get: function () { |
63 | return this._resultPath; | 57 | return this._resultPath; |
64 | }, | 58 | }, |
65 | set: function () { | 59 | set: function () { |
66 | var self = this; | 60 | var self = this; |
67 | 61 | ||
68 | this._resultPath = { | 62 | this._resultPath = { |
69 | value: function (slide) { | 63 | value: function (slide) { |
70 | var v1=self._path1.value(slide), | 64 | var v1=self._path1.value(slide), |
@@ -73,7 +67,7 @@ var FlowPathLerp = exports.FlowPathLerp = Montage.create(Montage, { | |||
73 | m2=self._interpolant, | 67 | m2=self._interpolant, |
74 | result={}, | 68 | result={}, |
75 | i; | 69 | i; |
76 | 70 | ||
77 | for (i in v1) { | 71 | for (i in v1) { |
78 | if (v1.hasOwnProperty(i)&&(i!="style")) { | 72 | if (v1.hasOwnProperty(i)&&(i!="style")) { |
79 | if (v2.hasOwnProperty(i)) { | 73 | if (v2.hasOwnProperty(i)) { |
@@ -86,7 +80,7 @@ var FlowPathLerp = exports.FlowPathLerp = Montage.create(Montage, { | |||
86 | result[i]=v1[i]; | 80 | result[i]=v1[i]; |
87 | } | 81 | } |
88 | } | 82 | } |
89 | } | 83 | } |
90 | for (i in v2) { | 84 | for (i in v2) { |
91 | if (v2.hasOwnProperty(i)&&(i!="style")&&(!v1.hasOwnProperty(i))) { | 85 | if (v2.hasOwnProperty(i)&&(i!="style")&&(!v1.hasOwnProperty(i))) { |
92 | result[i]=v2[i]; | 86 | result[i]=v2[i]; |
@@ -109,4 +103,4 @@ var FlowPathLerp = exports.FlowPathLerp = Montage.create(Montage, { | |||
109 | }; | 103 | }; |
110 | } | 104 | } |
111 | } | 105 | } |
112 | }); \ No newline at end of file | 106 | }); |