aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorValerio Virgillito2012-07-18 11:45:54 -0700
committerValerio Virgillito2012-07-18 11:45:54 -0700
commit2f009ea40ca815a9aff27a5862bba5a6b335586c (patch)
tree10a409394038c642c2aa811ba9a0ffaf667dfed7
parent9730dead250067abad10625c2da46cbd24fc0a1e (diff)
parentecc2f1c6296ac5e706b1d6388254c8df24a01066 (diff)
downloadninja-2f009ea40ca815a9aff27a5862bba5a6b335586c.tar.gz
Merge branch 'refs/heads/master' into menu-fixes
-rw-r--r--README.md4
-rw-r--r--js/panels/Timeline/DragDrop.js161
-rw-r--r--js/panels/Timeline/Keyframe.reel/Keyframe.js104
-rw-r--r--js/panels/Timeline/Layer.reel/Layer.js29
-rw-r--r--js/panels/Timeline/PropertyTrack.reel/PropertyTrack.js384
-rw-r--r--js/panels/Timeline/Span.reel/Span.js192
-rw-r--r--js/panels/Timeline/Style.reel/Style.js695
-rw-r--r--js/panels/Timeline/Style.reel/css/Style.css124
-rw-r--r--js/panels/Timeline/Style.reel/scss/Style.scss2
-rw-r--r--js/panels/Timeline/TimelinePanel.reel/TimelinePanel.html2
-rw-r--r--js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js2831
-rw-r--r--js/panels/Timeline/TimelinePanel.reel/css/TimelinePanel.css115
-rwxr-xr-xjs/panels/Timeline/TimelinePanel.reel/images/knob.pngbin0 -> 1036 bytes
-rw-r--r--js/panels/Timeline/TimelinePanel.reel/scss/TimelinePanel.scss27
-rw-r--r--js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js993
-rw-r--r--js/panels/Timeline/Track.reel/Track.html88
-rw-r--r--js/panels/Timeline/Track.reel/Track.js212
-rw-r--r--js/panels/Timeline/Track.reel/css/Track.css57
-rw-r--r--js/panels/Timeline/TrackSpacer.reel/TrackSpacer.html55
-rw-r--r--js/panels/Timeline/TrackSpacer.reel/TrackSpacer.js46
-rw-r--r--js/panels/Timeline/TrackSpacer.reel/css/TrackSpacer.css36
-rw-r--r--js/panels/Timeline/Tween.reel/Tween.js145
-rwxr-xr-xjs/panels/color/colorpopup-manager.js26
-rw-r--r--manifest.json2
24 files changed, 2834 insertions, 3496 deletions
diff --git a/README.md b/README.md
index 286a99ae..9479a000 100644
--- a/README.md
+++ b/README.md
@@ -25,13 +25,13 @@ If you're already familiar with using Git, GitHub, you can clone master branch o
25 - Browse to HKEY_CURRENT_USER/Software/Motorola Mobility/Ninja Local Cloud/Options. 25 - Browse to HKEY_CURRENT_USER/Software/Motorola Mobility/Ninja Local Cloud/Options.
26 - Right click and select New > String value. 26 - Right click and select New > String value.
27 - Type 'Local Ninja Origin' no quotes. 27 - Type 'Local Ninja Origin' no quotes.
28 - Double click on Local Ninja Origin and paste in the Ninja app ID copied in step 6 from the Chrome extensions page in the Value data field. 28 - Double click on Local Ninja Origin and paste in the Ninja app ID copied in step 6 from the Chrome extensions page in the Value data field. To have multiple builds of Ninja installed but not running simultaneously as this is not supported, multiple app IDs can be added separated by comma and no space.
29 - Close Registry Editor. 29 - Close Registry Editor.
308. On Mac: 308. On Mac:
31 - Launch Finder. 31 - Launch Finder.
32 - Double click on /Users/\<user\>/Library/Preferences/com.MotorolaMobility.Ninja-Local-Cloud.plist. Note: on Lion (10.7), user library folder is hidden by default. To browse to it, in Finder choose Go > Go to Folder and type ~/Library, or select Go menu with Alt (Option) key down to see Library listed in Go menu or make the user library folder permanently visible by running the following command in Terminal: chflags nohidden ~/Library 32 - Double click on /Users/\<user\>/Library/Preferences/com.MotorolaMobility.Ninja-Local-Cloud.plist. Note: on Lion (10.7), user library folder is hidden by default. To browse to it, in Finder choose Go > Go to Folder and type ~/Library, or select Go menu with Alt (Option) key down to see Library listed in Go menu or make the user library folder permanently visible by running the following command in Terminal: chflags nohidden ~/Library
33 - Click on Add Child Type 'Local Ninja Origin' no quotes. 33 - Click on Add Child Type 'Local Ninja Origin' no quotes.
34 - For value, paste in the Ninja app ID copied in step 6 from the Chrome extensions page. 34 - For value, paste in the Ninja app ID copied in step 6 from the Chrome extensions page. To have multiple builds of Ninja installed but not running simultaneously as this is not supported, multiple app IDs can be added separated by comma and no space.
35 - Save (File > Save or Cmd S). 35 - Save (File > Save or Cmd S).
36 - Close Property List Editor. 36 - Close Property List Editor.
379. Quit Ninja Local Cloud 379. Quit Ninja Local Cloud
diff --git a/js/panels/Timeline/DragDrop.js b/js/panels/Timeline/DragDrop.js
deleted file mode 100644
index b13df482..00000000
--- a/js/panels/Timeline/DragDrop.js
+++ /dev/null
@@ -1,161 +0,0 @@
1/* <copyright>
2Copyright (c) 2012, Motorola Mobility LLC.
3All Rights Reserved.
4
5Redistribution and use in source and binary forms, with or without
6modification, are permitted provided that the following conditions are met:
7
8* Redistributions of source code must retain the above copyright notice,
9 this list of conditions and the following disclaimer.
10
11* Redistributions in binary form must reproduce the above copyright notice,
12 this list of conditions and the following disclaimer in the documentation
13 and/or other materials provided with the distribution.
14
15* Neither the name of Motorola Mobility LLC nor the names of its
16 contributors may be used to endorse or promote products derived from this
17 software without specific prior written permission.
18
19THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
20AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
22ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
23LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
24CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
25SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
26INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
27CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
28ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29POSSIBILITY OF SUCH DAMAGE.
30</copyright> */
31
32var Montage = require("montage/core/core").Montage;
33var Composer = require("montage/ui/composer/composer").Composer;
34
35exports.DragDropComposer = Montage.create(Composer, {
36
37 draggable: {
38 value: true
39 },
40
41 droppable: {
42 value: true
43 },
44
45 identifier: {
46 value: "generic"
47 },
48
49 _dragover: {
50 value: false
51 },
52
53 load: {
54 value: function() {
55 //TODO: to make this work even better check to see if this is a component or not
56 //right now it does not support data-montage id's
57 this.element.addEventListener("mouseover", this, true);
58 this.element.addEventListener("mouseout", this, true);
59 this.component.element.addEventListener("dragenter", this, true);
60 this.component.element.addEventListener("dragleave", this, true);
61 this.component.element.addEventListener("dragend", this, true);
62 this.component.element.addEventListener("drop", this, true);
63 this.component.element.addEventListener("dragover", this, true);
64 this.component.element.addEventListener("dragstart", this, true);
65 }
66 },
67
68 unload: {
69 value: function() {
70 this.element.removeEventListener("mouseover", this, true);
71 this.element.removeEventListener("mouseout", this, true);
72 this.component.element.removeEventListener("dragenter", this, true);
73 this.component.element.removeEventListener("dragleave", this, true);
74 this.component.element.removeEventListener("dragend", this, true);
75 this.component.element.removeEventListener("drop", this, true);
76 this.component.element.removeEventListener("dragover", this, true);
77 this.component.element.removeEventListener("dragstart", this, true);
78 }
79 },
80
81 captureMouseover: {
82 value: function(e) {
83 if(this.draggable) {
84 this.component.element.draggable = true;
85 }
86 }
87 },
88
89 captureMouseout: {
90 value: function(e) {
91 this.component.element.draggable = false;
92 }
93 },
94
95 /* ------ Drag Drop Events ------- */
96
97 // This Function will determine what is being moved
98 captureDragstart: {
99 value:function(e) {
100 e.dataTransfer.effectAllowed = 'move';
101 e.dataTransfer.setData('Text', this.identifier);
102 this.component.element.classList.add("dragging");
103 this.component.application.ninja.componentBeingDragged = this.component;
104 }
105 },
106
107 captureDragenter: {
108 value: function(e) {
109
110 }
111 },
112
113 captureDragover: {
114 value:function(e) {
115 e.preventDefault();
116 e.stopImmediatePropagation();
117 if (!this._dragover) {
118 this._dragover = true;
119 this.component.element.classList.add("dragOver");
120 }
121 }
122 },
123
124 captureDragleave: {
125 value: function(e) {
126 if (this._dragover) {
127 this._dragover = false;
128 this.component.element.classList.remove("dragOver");
129 }
130 }
131 },
132
133 captureDrop: {
134 value:function(e) {
135 e.stopPropagation(); // Stops some browsers from redirecting.
136 e.preventDefault();
137 if (this._dragover) {
138 this._dragover = false;
139 this.component.element.classList.remove("dragOver");
140 if (this.identifier === e.dataTransfer.getData("Text")) {
141 if(this.component.application.ninja.componentBeingDragged !== this.component) {
142 dropEvent = document.createEvent("CustomEvent");
143 dropEvent.initCustomEvent("dropped", true, false, null);
144 dropEvent.draggedComponent = this.component.application.ninja.componentBeingDragged;
145 dropEvent.droppedComponent = this.component;
146 this.component.dispatchEvent(dropEvent);
147 }
148 }
149 this.component.application.ninja.componentBeingDragged = null;
150 }
151
152 }
153 },
154
155 captureDragend: {
156 value:function(e) {
157 this.component.element.classList.remove("dragging");
158 }
159 }
160
161});
diff --git a/js/panels/Timeline/Keyframe.reel/Keyframe.js b/js/panels/Timeline/Keyframe.reel/Keyframe.js
index e261f926..3efd1584 100644
--- a/js/panels/Timeline/Keyframe.reel/Keyframe.js
+++ b/js/panels/Timeline/Keyframe.reel/Keyframe.js
@@ -34,6 +34,7 @@ var Component = require("montage/ui/component").Component;
34 34
35var Keyframe = exports.Keyframe = Montage.create(Component, { 35var Keyframe = exports.Keyframe = Montage.create(Component, {
36 36
37 // ==== Begin models