diff options
23 files changed, 562 insertions, 387 deletions
diff --git a/assets/descriptor.json b/assets/descriptor.json new file mode 100644 index 00000000..53bfb684 --- /dev/null +++ b/assets/descriptor.json | |||
@@ -0,0 +1,34 @@ | |||
1 | { | ||
2 | "copyright": "This file contains proprietary software owned by Motorola Mobility, Inc. No rights, expressed or implied, whatsoever to this software are provided by Motorola Mobility, Inc. hereunder. (c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved.", | ||
3 | "version": "0.0.0.0", | ||
4 | "root": "/assets/", | ||
5 | "directories": [{"name": "images"}, {"name": "shaders"}], | ||
6 | "files": [ | ||
7 | "images/black.png", | ||
8 | "images/blue.png", | ||
9 | "images/BoxB2_AO.png", | ||
10 | "images/BoxB2_DM.png", | ||
11 | "images/cubelight.png", | ||
12 | "images/grey.png", | ||
13 | "images/material_paint.png", | ||
14 | "images/metal.png", | ||
15 | "images/normalMap.png", | ||
16 | "images/random_normal.png", | ||
17 | "images/rocky-diffuse.jpg", | ||
18 | "images/rocky-normal.jpg", | ||
19 | "images/rocky-spec.jpg", | ||
20 | "images/silver.png", | ||
21 | "images/white.png", | ||
22 | "shaders/Basic.frag.glsl", | ||
23 | "shaders/Basic.vert.glsl", | ||
24 | "shaders/linearGradient.frag.glsl", | ||
25 | "shaders/linearGradient.vert.glsl", | ||
26 | "shaders/radialGradient.frag.glsl", | ||
27 | "shaders/radialGradient.vert.glsl", | ||
28 | "shaders/test_fshader.glsl", | ||
29 | "shaders/test_fshader_full.glsl", | ||
30 | "shaders/test_vshader.glsl", | ||
31 | "shaders/ub_fshader.glsl", | ||
32 | "shaders/ub_vshader.glsl" | ||
33 | ] | ||
34 | } \ No newline at end of file | ||
diff --git a/css/ninja.css b/css/ninja.css index d22cfc22..824a675a 100755 --- a/css/ninja.css +++ b/css/ninja.css | |||
@@ -118,9 +118,9 @@ body { position: absolute; margin: 0px; width: 100%; height: 100%; background-co | |||
118 | 118 | ||
119 | #sceneBar { height: 70px; background-color: #474747; } | 119 | #sceneBar { height: 70px; background-color: #474747; } |
120 | 120 | ||
121 | #mainContainer #rulerTop { background: url("../images/temp/ruler-top.png"); height: 15px; margin-bottom: 0px; } | 121 | #mainContainer #rulerTop { background: url("../images/temp/ruler-top.png"); height: 15px; margin-bottom: 0px; display:none;} |
122 | 122 | ||
123 | #rulerLeft { background: url("../images/temp/ruler-left.png"); width: 16px; } | 123 | #rulerLeft { background: url("../images/temp/ruler-left.png"); width: 16px; display:none;} |
124 | 124 | ||
125 | #stateBar { height: 20px; background-color: #282828; margin-bottom: 0px; } | 125 | #stateBar { height: 20px; background-color: #282828; margin-bottom: 0px; } |
126 | 126 | ||
@@ -174,6 +174,8 @@ body { position: absolute; margin: 0px; width: 100%; height: 100%; background-co | |||
174 | 174 | ||
175 | #documentBar { height: 25px; width: 1000px; position: relative; overflow: hidden; color: white; } | 175 | #documentBar { height: 25px; width: 1000px; position: relative; overflow: hidden; color: white; } |
176 | 176 | ||
177 | .montage-popup-modal-mask { opacity: 1; background: -webkit-radial-gradient(center, ellipse cover, rgba(0, 0, 0, 0.65) 0%, rgba(0, 0, 0, 0.8) 80%); } | ||
178 | |||
177 | #middleDocArea { -webkit-box-orient: horizontal; -moz-box-orient: horizontal; box-orient: horizontal; -moz-box-flex: 1; -webkit-box-flex: 1; box-flex: 1; margin: 1px; margin-bottom: 3px; border-style: solid; border-width: 1px; } | 179 | #middleDocArea { -webkit-box-orient: horizontal; -moz-box-orient: horizontal; box-orient: horizontal; -moz-box-flex: 1; -webkit-box-flex: 1; box-flex: 1; margin: 1px; margin-bottom: 3px; border-style: solid; border-width: 1px; } |
178 | 180 | ||
179 | #mainStageIFrame { border: none; margin: 4px; } | 181 | #mainStageIFrame { border: none; margin: 4px; } |
diff --git a/js/components/ui/FilePicker/pickerNavigator.reel/pickerNavigator.css b/js/components/ui/FilePicker/pickerNavigator.reel/pickerNavigator.css index 9c85c6b5..796c283f 100644 --- a/js/components/ui/FilePicker/pickerNavigator.reel/pickerNavigator.css +++ b/js/components/ui/FilePicker/pickerNavigator.reel/pickerNavigator.css | |||
@@ -6,7 +6,7 @@ | |||
6 | 6 | ||
7 | .picker{ | 7 | .picker{ |
8 | font-size:12px; | 8 | font-size:12px; |
9 | width:510px; | 9 | width:523px; |
10 | height:500px; | 10 | height:500px; |
11 | padding-top:15px; | 11 | padding-top:15px; |
12 | padding-left:15px; | 12 | padding-left:15px; |
@@ -53,6 +53,7 @@ | |||
53 | height:75%; | 53 | height:75%; |
54 | width:auto; | 54 | width:auto; |
55 | border-right: none; | 55 | border-right: none; |
56 | margin: 8px 0px 0px 8px; | ||
56 | } | 57 | } |
57 | 58 | ||
58 | .picker .right-bottom{ | 59 | .picker .right-bottom{ |
diff --git a/js/components/ui/FilePicker/pickerNavigator.reel/pickerNavigator.js b/js/components/ui/FilePicker/pickerNavigator.reel/pickerNavigator.js index 6b0d92f7..411386f9 100644 --- a/js/components/ui/FilePicker/pickerNavigator.reel/pickerNavigator.js +++ b/js/components/ui/FilePicker/pickerNavigator.reel/pickerNavigator.js | |||
@@ -203,6 +203,13 @@ var PickerNavigator = exports.PickerNavigator = Montage.create(Component, { | |||
203 | this.pickerModel.storeHistory(this.pickerModel.currentRoot);//populate history | 203 | this.pickerModel.storeHistory(this.pickerModel.currentRoot);//populate history |
204 | 204 | ||
205 | this.updateMetadata(this.currentURI); | 205 | this.updateMetadata(this.currentURI); |
206 | |||
207 | //for directory selection, selected url is the folder entered | ||
208 | if(!this.pickerModel.inFileMode ){ | ||
209 | this.okButton.removeAttribute("disabled"); | ||
210 | //put into selectedItems..currently single selection is supported | ||
211 | this.selectedItems = [this.pickerModel.currentRoot]; | ||
212 | } | ||
206 | } | 213 | } |
207 | 214 | ||
208 | this.element.addEventListener("openFolder", function(evt){that.handlePickerNavOpenFolder(evt);}, false);//add icon double click event listener to reload iconList with new set of data | 215 | this.element.addEventListener("openFolder", function(evt){that.handlePickerNavOpenFolder(evt);}, false);//add icon double click event listener to reload iconList with new set of data |
@@ -211,6 +218,7 @@ var PickerNavigator = exports.PickerNavigator = Montage.create(Component, { | |||
211 | this.element.addEventListener("updateMetadata", function(evt){that.handlePickerNavUpdateMetadata(evt);}, false);//show metadata on click of icon | 218 | this.element.addEventListener("updateMetadata", function(evt){that.handlePickerNavUpdateMetadata(evt);}, false);//show metadata on click of icon |
212 | //this.addressGo.addEventListener("click", this, false); | 219 | //this.addressGo.addEventListener("click", this, false); |
213 | this.addressBarUri.addEventListener("keydown", this, false); | 220 | this.addressBarUri.addEventListener("keydown", this, false); |
221 | this.addressBarUri.addEventListener("keyup", this, false); | ||
214 | this.refreshButton.addEventListener("click", this, false);//refresh - gets from file system directly | 222 | this.refreshButton.addEventListener("click", this, false);//refresh - gets from file system directly |
215 | this.backArrow.addEventListener("click", this, false); | 223 | this.backArrow.addEventListener("click", this, false); |
216 | this.forwardArrow.addEventListener("click", this, false); | 224 | this.forwardArrow.addEventListener("click", this, false); |
@@ -608,6 +616,13 @@ var PickerNavigator = exports.PickerNavigator = Montage.create(Component, { | |||
608 | this.backArrow.classList.remove("disable"); | 616 | this.backArrow.classList.remove("disable"); |
609 | } | 617 | } |
610 | 618 | ||
619 | //for directory selection, selected url is the folder entered | ||
620 | if(!this.pickerModel.inFileMode ){ | ||
621 | this.okButton.removeAttribute("disabled"); | ||
622 | //put into selectedItems..currently single selection is supported | ||
623 | this.selectedItems = [evt.folderUri]; | ||
624 | } | ||
625 | |||
611 | } | 626 | } |
612 | }, | 627 | }, |
613 | 628 | ||
@@ -720,6 +735,21 @@ var PickerNavigator = exports.PickerNavigator = Montage.create(Component, { | |||
720 | } | 735 | } |
721 | }, | 736 | }, |
722 | 737 | ||
738 | handleAddressBarUriKeyup:{ | ||
739 | value: function(evt){ | ||
740 | //disable ok if user enters an invalid uri | ||
741 | if(!this.application.ninja.coreIoApi.isValidUri(this.addressBarUri.value)){ | ||
742 | //disable OK | ||
743 | if(!this.okButton.hasAttribute("disabled")){ | ||
744 | this.okButton.setAttribute("disabled", "true"); | ||
745 | } | ||
746 | }else{ | ||
747 | this.okButton.removeAttribute("disabled"); | ||
748 | this.selectedItems = [this.addressBarUri.value]; | ||
749 | } | ||
750 | } | ||
751 | }, | ||
752 | |||
723 | handleRefreshButtonClick:{ | 753 | handleRefreshButtonClick:{ |
724 | value:function(evt){ | 754 | value:function(evt){ |
725 | var uri = this.addressBarUri.value; | 755 | var uri = this.addressBarUri.value; |
@@ -794,7 +824,7 @@ var PickerNavigator = exports.PickerNavigator = Montage.create(Component, { | |||
794 | 824 | ||
795 | handleOkButtonAction : { | 825 | handleOkButtonAction : { |
796 | value: function(evt){ | 826 | value: function(evt){ |
797 | console.log("$$$ File Picker : selected "+ this.selectedItems.toString()); | 827 | //console.log("$$$ File Picker : selected "+ this.selectedItems.toString()); |
798 | var success = true; | 828 | var success = true; |
799 | if(!!this.pickerModel.callback && (this.selectedItems.length > 0)){//call the callback if it is available | 829 | if(!!this.pickerModel.callback && (this.selectedItems.length > 0)){//call the callback if it is available |
800 | try{ | 830 | try{ |
diff --git a/js/components/ui/icon-list-basic/icon.reel/icon.css b/js/components/ui/icon-list-basic/icon.reel/icon.css index 4d71f6b8..9fb180d2 100644 --- a/js/components/ui/icon-list-basic/icon.reel/icon.css +++ b/js/components/ui/icon-list-basic/icon.reel/icon.css | |||
@@ -5,14 +5,14 @@ | |||
5 | </copyright> */ | 5 | </copyright> */ |