aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xcss/ninja.css75
-rwxr-xr-xjs/controllers/document-controller.js8
-rwxr-xr-xjs/document/html-document.js41
-rwxr-xr-xjs/helper-classes/3D/view-utils.js8
-rwxr-xr-xjs/helper-classes/RDGE/GLCircle.js2
-rwxr-xr-xjs/helper-classes/RDGE/GLLine.js2
-rwxr-xr-xjs/helper-classes/RDGE/GLRectangle.js2
-rwxr-xr-xjs/helper-classes/RDGE/GLWorld.js29
-rwxr-xr-xjs/helper-classes/RDGE/rdge-compiled.js28
-rw-r--r--js/helper-classes/RDGE/runtime/CanvasDataManager.js98
-rw-r--r--js/helper-classes/RDGE/runtime/GLRuntime.js159
-rw-r--r--js/helper-classes/RDGE/src/tools/rdge-compiled.js28
-rwxr-xr-xjs/mediators/keyboard-mediator.js6
-rw-r--r--js/panels/Timeline/Keyframe.reel/Keyframe.html6
-rw-r--r--js/panels/Timeline/Keyframe.reel/Keyframe.js117
-rw-r--r--js/panels/Timeline/Layer.reel/Layer.html2
-rw-r--r--js/panels/Timeline/Layer.reel/Layer.js27
-rw-r--r--js/panels/Timeline/Layer.reel/css/Layer.css117
-rw-r--r--js/panels/Timeline/Layer.reel/scss/Layer.scss17
-rw-r--r--js/panels/Timeline/PropertyTrack.reel/PropertyTrack.html24
-rw-r--r--js/panels/Timeline/PropertyTrack.reel/PropertyTrack.js15
-rw-r--r--js/panels/Timeline/PropertyTrack.reel/css/PropertyTrack.css13
-rw-r--r--js/panels/Timeline/PropertyTrack.reel/scss/PropertyTrack.scss21
-rw-r--r--js/panels/Timeline/PropertyTrack.reel/scss/config.rb9
-rw-r--r--js/panels/Timeline/Span.reel/Span.html6
-rw-r--r--js/panels/Timeline/Span.reel/Span.js11
-rw-r--r--js/panels/Timeline/Style.reel/scss/Style.scss6
-rw-r--r--[-rwxr-xr-x]js/panels/Timeline/TimelinePanel.reel/TimelinePanel.html70
-rw-r--r--[-rwxr-xr-x]js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js216
-rw-r--r--js/panels/Timeline/TimelinePanel.reel/css/TimelinePanel.css25
-rw-r--r--js/panels/Timeline/TimelineTrack.reel/TimelineTrack.html102
-rw-r--r--js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js333
-rw-r--r--js/panels/Timeline/TimelineTrack.reel/css/TimelineTrack.css62
-rw-r--r--js/panels/Timeline/TimelineTrack.reel/scss/TimelineTrack.scss14
-rw-r--r--js/panels/Timeline/Tween.reel/Tween.html16
-rw-r--r--js/panels/Timeline/Tween.reel/Tween.js114
-rwxr-xr-xjs/panels/properties/content.reel/content.js15
-rwxr-xr-xjs/preloader/Preloader.js3
-rwxr-xr-xscss/imports/scss/_toolbar.scss87
39 files changed, 1277 insertions, 657 deletions
diff --git a/css/ninja.css b/css/ninja.css
index 4d450208..f085f6be 100755
--- a/css/ninja.css
+++ b/css/ninja.css
@@ -212,6 +212,10 @@ body { position: absolute; margin: 0px; width: 100%; height: 100%; background-co
212 212
213#mainContent .CodeMirror-scroll { height: 100%; overflow: scroll; overflow-x: auto; overflow-y: auto; } 213#mainContent .CodeMirror-scroll { height: 100%; overflow: scroll; overflow-x: auto; overflow-y: auto; }
214 214
215.montage-editor-frame { position: absolute; z-index: 7; top: 0; left: 0; display: none; -webkit-user-select: initial; }
216
217.montage-editor { padding: 0px; word-wrap: normal; }
218
215.panelContainer { margin: 0px; padding: 0px 0px; position: relative; overflow: auto; } 219.panelContainer { margin: 0px; padding: 0px 0px; position: relative; overflow: auto; }
216 220
217.panelDisclosureIcon { background-image: url("../images/panels/panelDisclosureIcon.png"); background-repeat: no-repeat; width: 16px; height: 16px; float: left; -webkit-transition-property: rotate; -webkit-transition-duration: 0.2s; -webkit-transition-timing-function: linear; padding-right: 2px; } 221.panelDisclosureIcon { background-image: url("../images/panels/panelDisclosureIcon.png"); background-repeat: no-repeat; width: 16px; height: 16px; float: left; -webkit-transition-property: rotate; -webkit-transition-duration: 0.2s; -webkit-transition-timing-function: linear; padding-right: 2px; }
@@ -888,49 +892,34 @@ input[type="radio"]:disabled { opacity: .3; background: #282828; border-width: 1
888/*width: 26px;*/ 892/*width: 26px;*/
889/*opacity: 0.7;*/ 893/*opacity: 0.7;*/
890/*}*/ 894/*}*/
891/*// Selection Tool Options */ 895.topAlignUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -240px -54px; background-repeat: no-repeat; height: 23px; width: 26px; }
892/*.topAlignUp {*/ 896
893/*@include background-pos(8,2,26px,23px);*/ 897.rightAlignUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -270px -54px; background-repeat: no-repeat; height: 23px; width: 26px; }
894/*}*/ 898
895/*.rightAlignUp {*/ 899.bottomAlignUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -300px -54px; background-repeat: no-repeat; height: 23px; width: 26px; }
896/*@include background-pos(9,2,26px,23px);*/ 900
897/*}*/ 901.verticalLeftUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -330px -54px; background-repeat: no-repeat; height: 23px; width: 26px; }
898/*.bottomAlignUp {*/ 902
899/*@include background-pos(10,2,26px,23px);*/ 903.verticalCenterUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -360px -54px; background-repeat: no-repeat; height: 23px; width: 26px; }
900/*}*/ 904
901/*.verticalLeftUp {*/ 905.verticalRightUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -390px -54px; background-repeat: no-repeat; height: 23px; width: 26px; }
902/*@include background-pos(11,2,26px,23px);*/ 906
903/*}*/ 907.distRightUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: 0px -81px; background-repeat: no-repeat; height: 23px; width: 26px; }
904/*.verticalCenterUp {*/ 908
905/*@include background-pos(12,2,26px,23px);*/ 909.distLeftUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -420px -54px; background-repeat: no-repeat; height: 23px; width: 26px; }
906/*}*/ 910
907/*.verticalRightUp {*/ 911.distCenterUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -60px -81px; background-repeat: no-repeat; height: 23px; width: 26px; }
908/*@include background-pos(13,2,26px,23px);*/ 912
909/*}*/ 913.distTopUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -30px -81px; background-repeat: no-repeat; height: 23px; width: 26px; }
910/*.distRightUp {*/ 914
911/*@include background-pos(0,3,26px,23px);*/ 915.distBottomUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -90px -81px; background-repeat: no-repeat; height: 23px; width: 26px; }
912/*}*/ 916
913/*.distLeftUp {*/ 917.distVCenterUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -450px -54px; background-repeat: no-repeat; height: 23px; width: 26px; }
914/*@include background-pos(14,2,26px,23px);*/ 918
915/*}*/ 919.bucketToolUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -330px 0px; background-repeat: no-repeat; height: 23px; width: 26px; }
916/*.distCenterUp {*/ 920
917/*@include background-pos(2,3,26px,23px);*/ 921.pencilToolUp { background-image: url("../images/SpriteSheets/NinjaSpriteSheet2_5.png"); background-position: -270px -27px; background-repeat: no-repeat; height: 23px; width: 26px; }
918/*}*/ 922
919/*.distTopUp {*/
920/*@include background-pos(1,3,26px,23px);*/
921/*}*/
922/*.distBottomUp {*/
923/*@include background-pos(3,3,26px,23px);*/
924/*}*/
925/*.distVCenterUp {*/
926/*@include background-pos(15,2,26px,23px);*/
927/*}*/
928/*.bucketToolUp {*/
929/*@include background-pos(11,0,26px,23px);*/
930/*}*/
931/*.pencilToolUp {*/
932/*@include background-pos(9,1,26px,23px);*/
933/*}*/
934.blueDiv { background: blue; opacity: 0.2; } 923.blueDiv { background: blue; opacity: 0.2; }
935 924
936::-webkit-scrollbar { width: 11px; height: 11px; } 925::-webkit-scrollbar { width: 11px; height: 11px; }
diff --git a/js/controllers/document-controller.js b/js/controllers/document-controller.js
index 6f7d098f..e221df68 100755
--- a/js/controllers/document-controller.js
+++ b/js/controllers/document-controller.js
@@ -86,8 +86,12 @@ var DocumentController = exports.DocumentController = Montage.create(Component,
86 // 86 //
87 handleAppLoaded: { 87 handleAppLoaded: {
88 value: function() { 88 value: function() {
89 //Checking for app not to be loaded via http/https to add app only listener 89 //Checking for app to be loaded through extension
90 if (window.location.protocol !== 'http:' && window.location.protocol !== 'https:') { 90 var check;
91 if (chrome && chrome.app) {
92 check = chrome.app.getDetails();
93 }
94 if (check !== null) {
91 //Adding an intercept to resources loaded to ensure user assets load from cloud simulator 95 //Adding an intercept to resources loaded to ensure user assets load from cloud simulator
92 chrome.webRequest.onBeforeRequest.addListener(this.handleWebRequest.bind(this), {urls: ["<all_urls>"]}, ["blocking"]); 96 chrome.webRequest.onBeforeRequest.addListener(this.handleWebRequest.bind(this), {urls: ["<all_urls>"]}, ["blocking"]);
93 } 97 }
diff --git a/js/document/html-document.js b/js/document/html-document.js
index c5293386..8798b407 100755
--- a/js/document/html-document.js
+++ b/js/document/html-document.js
@@ -168,13 +168,13 @@ exports.HTMLDocument = Montage.create(TextDocument, {
168 glData: { 168 glData: {
169 get: function() 169 get: function()
170 { 170 {
171 var elt = this.iframe;
172 var elt = this.iframe.contentWindow.document.getElementById("UserContent"); 171 var elt = this.iframe.contentWindow.document.getElementById("UserContent");
173 this._glData = null; 172 this._glData = null;
174 if (elt) 173 if (elt)
175 { 174 {
176 this._glData = new Array(); 175 var cdm = new CanvasDataManager();
177 this.collectGLData( elt, this._glData ); 176 this._glData = [];
177 cdm.collectGLData( elt, this._glData );
178 } 178 }
179 179
180 return this._glData 180 return this._glData
@@ -182,37 +182,12 @@ exports.HTMLDocument = Montage.create(TextDocument, {
182 182
183 set: function(value) 183 set: function(value)
184 { 184 {
185 var nWorlds = value.length; 185 var elt = this.iframe.contentWindow.document.getElementById("UserContent");
186 for (var i=0; i<nWorlds; i++) 186 if (elt)
187 { 187 {
188 var importStr = value[i]; 188 console.log( "load canvas data: " + value );
189 var startIndex = importStr.indexOf( "id: " ); 189 var cdm = new CanvasDataManager();
190 if (startIndex >= 0) 190 cdm.loadGLData(elt, value);
191 {
192 var endIndex = importStr.indexOf( "\n", startIndex );
193 if (endIndex > 0)
194 {
195 var id = importStr.substring( startIndex+4, endIndex );
196 var canvas = this.iframe.contentWindow.document.getElementById( id );
197 if (canvas)
198 {
199 if (!canvas.elementModel)
200 {
201 NJUtils.makeElementModel(canvas, "Canvas", "shape", true);
202 }
203
204 if (canvas.elementModel)
205