aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xcss/ninja.css75
-rwxr-xr-xjs/controllers/document-controller.js9
-rwxr-xr-xjs/mediators/keyboard-mediator.js6
-rw-r--r--js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js10
-rwxr-xr-xjs/panels/properties/content.reel/content.js15
-rwxr-xr-xscss/imports/scss/_toolbar.scss87
6 files changed, 105 insertions, 97 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 fa611de4..1c9d9d59 100755
--- a/js/controllers/document-controller.js
+++ b/js/controllers/document-controller.js
@@ -84,8 +84,13 @@ var DocumentController = exports.DocumentController = Montage.create(Component,
84 // 84 //
85 handleAppLoaded: { 85 handleAppLoaded: {
86 value: function() { 86 value: function() {
87 //Adding an intercept to resources loaded to ensure user assets load from cloud simulator 87 //Checking for app to be loaded through extension
88 if (window.chrome.app.isInstalled) { 88 var check;
89 if (chrome && chrome.app) {
90 check = chrome.app.getDetails();
91 }
92 if (check !== null) {
93 //Adding an intercept to resources loaded to ensure user assets load from cloud simulator
89 chrome.webRequest.onBeforeRequest.addListener(this.handleWebRequest.bind(this), {urls: ["<all_urls>"]}, ["blocking"]); 94 chrome.webRequest.onBeforeRequest.addListener(this.handleWebRequest.bind(this), {urls: ["<all_urls>"]}, ["blocking"]);
90 } 95 }
91 } 96 }
diff --git a/js/mediators/keyboard-mediator.js b/js/mediators/keyboard-mediator.js
index 0282060f..a4bf9baa 100755
--- a/js/mediators/keyboard-mediator.js
+++ b/js/mediators/keyboard-mediator.js
@@ -162,15 +162,17 @@ exports.KeyboardMediator = Montage.create(Component, {
162 return; 162 return;
163 } 163 }
164 164
165 // Hand tool
165 if(evt.keyCode === Keyboard.H ) { 166 if(evt.keyCode === Keyboard.H ) {
166 evt.preventDefault(); 167 evt.preventDefault();
167 this.application.ninja.handleSelectTool({"detail": this.application.ninja.toolsData.defaultToolsData[15]}); 168 this.application.ninja.handleSelectTool({"detail": this.application.ninja.toolsData.defaultToolsData[13]});
168 return; 169 return;
169 } 170 }
170 171
172 // Zoom tool
171 if(evt.keyCode === Keyboard.Z ) { 173 if(evt.keyCode === Keyboard.Z ) {
172 evt.preventDefault(); 174 evt.preventDefault();
173 this.application.ninja.handleSelectTool({"detail": this.application.ninja.toolsData.defaultToolsData[16]}); 175 this.application.ninja.handleSelectTool({"detail": this.application.ninja.toolsData.defaultToolsData[14]});
174 return; 176 return;
175 } 177 }
176 178
diff --git a/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js b/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js
index 1a0b9e80..62ae625f 100644
--- a/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js
+++ b/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js
@@ -513,9 +513,9 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, {
513 this._LayerUndoIndex = thingToPush.layerID; 513 this._LayerUndoIndex = thingToPush.layerID;
514 this._LayerUndoStatus = true; 514 this._LayerUndoStatus = true;
515 this._TrackUndoObject = newTrack; 515 this._TrackUndoObject = newTrack;
516 if(_firstLayerDraw){ 516// if(_firstLayerDraw){
517 this.application.ninja.selectionController.executeSelectElement(); 517// this.application.ninja.selectionController.executeSelectElement();
518 } 518// }
519 519
520 } 520 }
521 } 521 }
@@ -840,9 +840,9 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, {
840 this.trackRepetition.selectedIndexes = [layerIndex]; 840 this.trackRepetition.selectedIndexes = [layerIndex];
841 this.currentLayerSelected = this.arrLayers[layerIndex]; 841 this.currentLayerSelected = this.arrLayers[layerIndex];
842 this.currentTrackSelected = this.arrTracks[layerIndex]; 842 this.currentTrackSelected = this.arrTracks[layerIndex];
843 if(this._captureSelection){ 843 /*if(this._captureSelection){
844 this.application.ninja.selectionController.selectElements(this.currentLayerSelected.elementsList) 844 this.application.ninja.selectionController.selectElements(this.currentLayerSelected.elementsList)
845 } 845 }*/
846 this._captureSelection = true; 846 this._captureSelection = true;
847 } else { 847 } else {
848 this.layerRepetition.selectedIndexes = null; 848 this.layerRepetition.selectedIndexes = null;
diff --git a/js/panels/properties/content.reel/content.js b/js/panels/properties/content.reel/content.js
index 9b6416c7..8fa33a75 100755
--- a/js/panels/properties/content.reel/content.js
+++ b/js/panels/properties/content.reel/content.js
@@ -255,6 +255,12 @@ exports.Content = Montage.create(Component, {
255 255
256 if(currentValue) 256 if(currentValue)
257 { 257 {
258 if(currentValue.color)
259 {
260 currentValue.color.wasSetByCode = true;
261 currentValue.color.type = "change";
262 }
263
258 if(currentValue.mode === "gradient") 264 if(currentValue.mode === "gradient")
259 { 265 {
260 this.application.ninja.colorController.colorModel["gradient"] = 266 this.application.ninja.colorController.colorModel["gradient"] =
@@ -267,7 +273,14 @@ exports.Content = Montage.create(Component, {
267 this.application.ninja.colorController.colorModel.alpha = 273 this.application.ninja.colorController.colorModel.alpha =
268 {value: currentValue.color.a, wasSetByCode: true, type: 'change'}; 274 {value: currentValue.color.a, wasSetByCode: true, type: 'change'};
269 } 275 }
270 this.application.ninja.colorController.colorModel[currentValue.color.mode] = currentValue.color; 276 if(currentValue.color.mode)
277 {
278 this.application.ninja.colorController.colorModel[currentValue.color.mode] = currentValue.color;
279 }
280 else
281 {
282 this.application.ninja.colorController.colorModel["rgb"] = currentValue.color;
283 }
271 } 284 }
272 } 285 }
273 else 286 else
diff --git a/scss/imports/scss/_toolbar.scss b/scss/imports/scss/_toolbar.scss
index 00d8b5f0..9bf540cd 100755
--- a/scss/imports/scss/_toolbar.scss
+++ b/scss/imports/scss/_toolbar.scss
@@ -186,72 +186,71 @@
186 /*opacity: 0.7;*/ 186 /*opacity: 0.7;*/
187/*}*/ 187/*}*/
188 188
189/*// Selection Tool Options */ 189// Selection Tool Options
190/*.topAlignUp {*/ 190.topAlignUp {
191 191
192 /*@include background-pos(8,2,26px,23px);*/ 192 @include background-pos(8,2,26px,23px);
193/*}*/ 193}
194 194