From 46defc9bd11bf077efd672c72787a3b67da1a178 Mon Sep 17 00:00:00 2001 From: hwc487 Date: Mon, 12 Mar 2012 14:59:08 -0700 Subject: Uber material changes for IO --- .../RDGE/src/core/script/MeshManager.js | 2 +- .../RDGE/src/core/script/run_state.js | 16 +-- js/lib/geom/geom-obj.js | 6 +- js/lib/rdge/materials/flat-material.js | 6 - js/lib/rdge/materials/uber-material.js | 122 ++++++++++++++++++--- 5 files changed, 121 insertions(+), 31 deletions(-) (limited to 'js') diff --git a/js/helper-classes/RDGE/src/core/script/MeshManager.js b/js/helper-classes/RDGE/src/core/script/MeshManager.js index 43813078..7dfc79d4 100755 --- a/js/helper-classes/RDGE/src/core/script/MeshManager.js +++ b/js/helper-classes/RDGE/src/core/script/MeshManager.js @@ -69,7 +69,7 @@ MeshManager.prototype.deleteMesh = function (name) if (model) { g_Engine.ctxMan.forEach(function(context) - { + { context.renderer.deletePrimitive(model.primitive); }); diff --git a/js/helper-classes/RDGE/src/core/script/run_state.js b/js/helper-classes/RDGE/src/core/script/run_state.js index acdb6797..a5981caa 100755 --- a/js/helper-classes/RDGE/src/core/script/run_state.js +++ b/js/helper-classes/RDGE/src/core/script/run_state.js @@ -30,9 +30,9 @@ RunState.prototype.Init = function() this.userRunState.init(); } - if (this.hasUserState && this.userRunState && this.userRunState.onRunState) - this.userRunState.onRunState(); - + if (this.hasUserState && this.userRunState && this.userRunState.onRunState) + this.userRunState.onRunState(); + //////////////////////////////////////////////////////////////////////////////////////////////////////////////////// @@ -97,11 +97,11 @@ RunState.prototype.ReInit = function() if(!this.initialized) { this.Init(); - } - else - { - if (this.hasUserState && this.userRunState && this.userRunState.onRunState) - this.userRunState.onRunState(); + } + else + { + if (this.hasUserState && this.userRunState && this.userRunState.onRunState) + this.userRunState.onRunState(); } } diff --git a/js/lib/geom/geom-obj.js b/js/lib/geom/geom-obj.js index 1a197832..35ebadb9 100755 --- a/js/lib/geom/geom-obj.js +++ b/js/lib/geom/geom-obj.js @@ -285,9 +285,11 @@ var GeomObj = function GLGeomObj() { if (mat) mat.import( importStr ); - var endIndex = importStr.indexOf( "endMaterial\n" ); + // pull off the end of the material + var endMat = "endMaterial\n"; + var endIndex = importStr.indexOf( endMat ); if (endIndex < 0) break; - importStr = importStr.substr( endIndex ); + importStr = importStr.substr( endIndex + endMat.length ); } } diff --git a/js/lib/rdge/materials/flat-material.js b/js/lib/rdge/materials/flat-material.js index 97e4f646..fff0e68e 100755 --- a/js/lib/rdge/materials/flat-material.js +++ b/js/lib/rdge/materials/flat-material.js @@ -102,13 +102,7 @@ var FlatMaterial = function FlatMaterial() { try { var color = eval( "[" + pu.nextValue( "color: " ) + "]" ); - this.setProperty( "color", color); - - var endKey = "endMaterial\n"; - var index = importStr.indexOf( endKey ); - index += endKey.length; - rtnStr = importStr.substr( index ); } catch (e) { diff --git a/js/lib/rdge/materials/uber-material.js b/js/lib/rdge/materials/uber-material.js index 655d8e2a..8ec5b05c 100755 --- a/js/lib/rdge/materials/uber-material.js +++ b/js/lib/rdge/materials/uber-material.js @@ -4,6 +4,7 @@ (c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved. */ +var MaterialParser = require("js/lib/rdge/materials/material-parser").MaterialParser; var Material = require("js/lib/rdge/materials/material").Material; var UberMaterial = function UberMaterial() { @@ -375,19 +376,111 @@ var UberMaterial = function UberMaterial() { var endKey = "endMaterial\n"; var index = importStr.indexOf( endKey ); index += endKey.length; - importStr = importStr.substr( index ); + importStr = importStr.slice( 0, index ); var pu = new MaterialParser( importStr ); var matProps = pu.nextValue( "materialProps: " ); if (matProps) { - var ambientColor = Number( pu.nextValue( "ambientColor: " )); this.setProperty( "ambientColor", ambientColor ); - var diffuseColor = Number( pu.nextValue( "diffuseColor: " )); this.setProperty( "diffuseColor", diffuseColor ); - var specularColor = Number( pu.nextValue( "specularColor: " )); this.setProperty( "specularColor", specularColor ); - var specularPower = Number( pu.nextValue( "specularPower: " )); this.setProperty( "specularPower", specularPower ); + var ambientColor = eval( "[" + pu.nextValue("ambientColor: ") + ']' ); this.setProperty( "ambientColor", ambientColor ); + var diffuseColor = eval( "[" + pu.nextValue( "diffuseColor: ") + ']' ); this.setProperty( "diffuseColor", diffuseColor ); + var specularColor = eval( "[" + pu.nextValue( "specularColor: ") + ']' ); this.setProperty( "specularColor", specularColor ); + var specularPower = eval( "[" + pu.nextValue( "specularPower: ") + ']' ); this.setProperty( "specularPower", specularPower ); } - var lightProps = pu.nextValue( "theLights" ); + var lightProps = pu.nextValue( "lightProps: " ); + if (lightProps) + { + this._lights = []; + var lightStr; + for (var i=0; i 0) + { + this._ubershaderCaps.lighting = + { + 'light0' : this._lights[0], + 'light1' : this._lights[1], + 'light2' : this._lights[2], + 'light3' : this._lights[3] + } + } + } + + var diffuseMap = pu.nextValue( "diffuseMap: " ) + if(diffuseMap) + this.setProperty( "diffuseMap", diffuseMap ); + + var normalMap = pu.nextValue( "normalMap: " ); + if(normalMap) + this.setProperty( "normalMap", normalMap ); + + var specularMap = pu.nextValue( "specularMap: " ); + if(specularMap) + this.setProperty( "specularMap", specularMap ); + + var environmentMap = pu.nextValue( "environmentMap: " ); + if(environmentMap) + { + this.setProperty( "environmentMap", environmentMap ); + this.setProperty( "environmentAmount", Number( pu.nextValue( "envReflection" ) ) ); + } + + this.rebuildShader(); } this.export = function() @@ -428,20 +521,18 @@ var UberMaterial = function UberMaterial() { else if (light.type === 'spot') { exportStr += 'light' + i + 'Pos: ' + light['position'] + '\n'; - - var deg2Rad = Math.PI / 180; - exportStr += 'light' + i + 'Spot: ' + [ Math.cos( ( light['spotInnerCutoff'] || 45.0 ) * deg2Rad ), - Math.cos( ( light['spotOuterCutoff'] || 90.0 ) * deg2Rad )] + '\n'; + exportStr += 'light' + i + 'SpotInnerCutoff: ' + light['spotInnerCutoff'] + '\n'; + exportStr += 'light' + i + 'SpotOuterCutoff: ' + light['spotOuterCutoff'] + '\n'; } else // light.type === 'point' { - exportStr += 'light' + i + 'Pos: ' + (light['position'] || [ 0, 0, 0 ]) ; - exportStr += 'light' + i + 'Attenuation: ' + (light['attenuation'] || [ 1, 0, 0 ]) ; + exportStr += 'light' + i + 'Pos: ' + (light['position'] || [ 0, 0, 0 ]) + '\n'; + exportStr += 'light' + i + 'Attenuation: ' + (light['attenuation'] || [ 1, 0, 0 ]) + '\n'; } // common to all lights - exportStr += 'light' + i + 'Color: ' + light['diffuseColor'] || [ 1,1,1,1 ] + '\n'; - exportStr += 'light' + i + 'SpecularColor: ' + light['specularColor'] || [ 1, 1, 1, 1 ] + '\n'; + exportStr += 'light' + i + 'Color: ' + (light['diffuseColor'] || [ 1,1,1,1 ]) + '\n'; + exportStr += 'light' + i + 'SpecularColor: ' + (light['specularColor'] || [ 1, 1, 1, 1 ]) + '\n'; exportStr += "endlight\n"; } @@ -466,7 +557,10 @@ var UberMaterial = function UberMaterial() { exportStr += "specularMap: " + caps.specularMap.texture + "\n"; if(typeof caps.environmentMap != 'undefined') + { exportStr += "environmentMap: " + caps.environmentMap.texture + "\n"; + exportStr += "envReflection: " + caps.environmentMap.envReflection + "\n"; + } // every material needs to terminate like this exportStr += "endMaterial\n"; -- cgit v1.2.3 From 9d885aae7a17b4fc731a41f6b1ac8840092b83ac Mon Sep 17 00:00:00 2001 From: Nivesh Rajbhandari Date: Mon, 12 Mar 2012 17:06:05 -0700 Subject: Fixing snapping bugs in Selection, translate and rotate tools. We should show snap marker on mouse move for selection tool prior to mousing down as well. We should create drag plane parallel to the view and where the user moused down. Signed-off-by: Nivesh Rajbhandari --- js/helper-classes/3D/snap-manager.js | 12 ++++++++++-- js/tools/SelectionTool.js | 23 +++++++++++++---------- js/tools/Translate3DToolBase.js | 1 - js/tools/TranslateObject3DTool.js | 2 +- js/tools/modifier-tool-base.js | 12 ++++++------ 5 files changed, 30 insertions(+), 20 deletions(-) (limited to 'js') diff --git a/js/helper-classes/3D/snap-manager.js b/js/helper-classes/3D/snap-manager.js index cf8a91db..1caacd00 100755 --- a/js/helper-classes/3D/snap-manager.js +++ b/js/helper-classes/3D/snap-manager.js @@ -1978,12 +1978,20 @@ var SnapManager = exports.SnapManager = Montage.create(Component, { }, setupDragPlanes : { - value: function( hitRec ) { + value: function( hitRec, inGlobalMode ) { // get the location of the point in stage world space var elt = hitRec.getElt(); var localPt = hitRec.getLocalPoint(); var planeMat = hitRec.getPlaneMatrix(); - var stageWorldPt = viewUtils.postViewToStageWorld( MathUtils.transformPoint(localPt,planeMat), elt ); + var stageWorldPt; + if(inGlobalMode) + { + stageWorldPt = MathUtils.transformPoint(localPt,planeMat); + } + else + { + stageWorldPt = viewUtils.postViewToStageWorld( MathUtils.transformPoint(localPt,planeMat), elt ); + } /* // get a working plane parallel to the current working plane through the stage world point diff --git a/js/tools/SelectionTool.js b/js/tools/SelectionTool.js index 6d8ff175..13a04944 100755 --- a/js/tools/SelectionTool.js +++ b/js/tools/SelectionTool.js @@ -16,6 +16,7 @@ var Montage = require("montage/core/core").Montage, var SelectionTool = exports.SelectionTool = Montage.create(ModifierToolBase, { drawingFeedback: { value: { mode: "Draw2D", type: "" } }, + _inLocalMode: { value: false}, // This tool should always use global mode for translations _canOperateOnStage: { value: true}, _isSelecting: {value: false, writable:true}, _shiftMove: { value: 10}, @@ -34,14 +35,12 @@ var SelectionTool = exports.SelectionTool = Montage.create(ModifierToolBase, { value: function () { if(this._targets && this._targets.length) { - // TODO - drawUtils's elementPlanes check in drawSelectionBounds doesn't seem to work, - // so temporary workaround to simply check if all elements have identity matrix - // TODO - Eventually, this should instead check if all the selected items are on the view plane var len = this._targets.length; + var plane = this.application.ninja.stage.stageDeps.snapManager.getDragPlane(); for(var i = 0; i < len; i++) { - var mat = this._targets[i].mat; - if(!MathUtils.isIdentityMatrix(mat)) + var elt = this._targets[i].elt; + if(!this.application.ninja.stage.stageDeps.snapManager.elementIsOnPlane(elt, plane)) { return false; } @@ -123,14 +122,14 @@ var SelectionTool = exports.SelectionTool = Montage.create(ModifierToolBase, { this.doDraw(event); } else { this._showFeedbackOnMouseMove(event); - // if(this._canSnap) - // { - // this.doSnap(event); - // } + if(this._canSnap) + { + this.doSnap(event); + } } this.DrawHandles(this._delta); - if(this._canSnap && this._isDrawing) + if(this._canSnap) { this.application.ninja.stage.stageDeps.snapManager.drawLastHit(); } @@ -704,6 +703,10 @@ var SelectionTool = exports.SelectionTool = Montage.create(ModifierToolBase, { */ _showFeedbackOnMouseMove : { value: function (event) { + if(!this._showTransformHandles) + { + return; + } if(this._target && this._handles) { var len = this._handles.length; diff --git a/js/tools/Translate3DToolBase.js b/js/tools/Translate3DToolBase.js index 3d9191da..24a68ad1 100755 --- a/js/tools/Translate3DToolBase.js +++ b/js/tools/Translate3DToolBase.js @@ -10,7 +10,6 @@ Subclass TranslateObject3DTool will translate the object that was clicked. var Montage = require("montage/core/core").Montage, ModifierToolBase = require("js/tools/modifier-tool-base").ModifierToolBase, toolHandleModule = require("js/stage/tool-handle"), - snapManager = require("js/helper-classes/3D/snap-manager").SnapManager, viewUtils = require("js/helper-classes/3D/view-utils").ViewUtils, vecUtils = require("js/helper-classes/3D/vec-utils").VecUtils, drawUtils = require("js/helper-classes/3D/draw-utils").DrawUtils, diff --git a/js/tools/TranslateObject3DTool.js b/js/tools/TranslateObject3DTool.js index 5157e39c..92b9b2f7 100755 --- a/js/tools/TranslateObject3DTool.js +++ b/js/tools/TranslateObject3DTool.js @@ -103,7 +103,7 @@ exports.TranslateObject3DTool = Object.create(Translate3DToolBase, { } else { - this._dragPlane = snapManager.setupDragPlanes( hitRec ); + this._dragPlane = snapManager.setupDragPlanes( hitRec, true ); } } diff --git a/js/tools/modifier-tool-base.js b/js/tools/modifier-tool-base.js index 7892d015..80f7d758 100755 --- a/js/tools/modifier-tool-base.js +++ b/js/tools/modifier-tool-base.js @@ -171,7 +171,7 @@ exports.ModifierToolBase = Montage.create(DrawingTool, { // } // else // { - this._dragPlane = snapManager.setupDragPlanes( hitRec ); + this._dragPlane = snapManager.setupDragPlanes( hitRec, true ); // } } @@ -828,14 +828,14 @@ exports.ModifierToolBase = Montage.create(DrawingTool, { this.doDraw(event); } else { this._showFeedbackOnMouseMove(event); -// if(this._canSnap) -// { -// this.doSnap(event); -// } + if(this._canSnap) + { + this.doSnap(event); + } } this.DrawHandles(this._delta); - if(this._canSnap && this._isDrawing) + if(this._canSnap) { snapManager.drawLastHit(); } -- cgit v1.2.3 From 90e2f71d730fb4f4ec07b40d2c2569e6c46e8a1c Mon Sep 17 00:00:00 2001 From: Nivesh Rajbhandari Date: Mon, 12 Mar 2012 17:10:19 -0700 Subject: Fixing selection tool when moving multiple selection in 3d mode. Signed-off-by: Nivesh Rajbhandari --- js/tools/SelectionTool.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'js') diff --git a/js/tools/SelectionTool.js b/js/tools/SelectionTool.js index 13a04944..5f48f74d 100755 --- a/js/tools/SelectionTool.js +++ b/js/tools/SelectionTool.js @@ -451,7 +451,10 @@ var SelectionTool = exports.SelectionTool = Montage.create(ModifierToolBase, { if(this._use3DMode) { curMat = item.mat; - glmat4.multiply(curMat, qMat, curMat); + + curMat[12] += transMat[12]; + curMat[13] += transMat[13]; + curMat[14] += transMat[14]; viewUtils.setMatrixForElement( elt, curMat, true); this._targets[i].mat = curMat; } -- cgit v1.2.3 From 138da4b52049285dead085ff8349d6664b390eec Mon Sep 17 00:00:00 2001 From: Eric Guzman Date: Tue, 13 Mar 2012 11:14:39 -0700 Subject: Presets Panel - Adding hover state to ninja-leaf --- js/components/treeview/ninja-leaf.reel/ninja-leaf.css | 14 ++++++++++++-- js/panels/presets/content.reel/content.css | 4 +--- 2 files changed, 13 insertions(+), 5 deletions(-) (limited to 'js') diff --git a/js/components/treeview/ninja-leaf.reel/ninja-leaf.css b/js/components/treeview/ninja-leaf.reel/ninja-leaf.css index fedc1d9d..cc8108f6 100644 --- a/js/components/treeview/ninja-leaf.reel/ninja-leaf.css +++ b/js/components/treeview/ninja-leaf.reel/ninja-leaf.css @@ -3,7 +3,12 @@ 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. */ - +.treeRoot .branch-label, .treeRoot .leaf-label { + margin: 0 8px; +} +.treeRoot .leaf-label:hover { + margin: 0; +} .treeRoot .leaf-label { background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA0AAAANCAIAAAD9iXMrAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyRpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw%2FeHBhY2tldCBiZWdpbj0i77u%2FIiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8%2BIDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYxIDY0LjE0MDk0OSwgMjAxMC8xMi8wNy0xMDo1NzowMSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNS4xIE1hY2ludG9zaCIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDpEQzcwMEU1RjQxM0MxMUUxQUM0MERBNzM1MUVEMUQxMCIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDpEQzcwMEU2MDQxM0MxMUUxQUM0MERBNzM1MUVEMUQxMCI%2BIDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOkRDNzAwRTVENDEzQzExRTFBQzQwREE3MzUxRUQxRDEwIiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOkRDNzAwRTVFNDEzQzExRTFBQzQwREE3MzUxRUQxRDEwIi8%2BIDwvcmRmOkRlc2NyaXB0aW9uPiA8L3JkZjpSREY%2BIDwveDp4bXBtZXRhPiA8P3hwYWNrZXQgZW5kPSJyIj8%2BUcaK3QAAANFJREFUeNqMULEOREAQdYjvuE%2FYWlSUQqKQ7A%2FsD6n0SoVCFHpRa0SllvgFlpvzZO9OcfGSnbx9M%2FNmMpp2Dw96VVX9L%2FJ93wRrmkZJIKrZcRyK%2Bs25p5%2BU8pK4KCakMAzxL4oCJIqivu8Nw0DDu25ZFtW3ritIkiS0tGVZtm1%2F6rZtu4yr67osSyJBEJx3ybKsbVukOecU4zh2XRfKMAzTNJmYpWxgPM%2BzEIIxRrzrOs%2FzdMyVvyAxTdPxAJFzv%2BeBbz8cfN93kDzPb55ZewkwAF0Ddf6ATSsHAAAAAElFTkSuQmCC); background-position: 3px center; @@ -12,6 +17,11 @@ cursor: pointer; padding: 3px 0 4px; } +.branch .branch .leaf-label:hover { + background-color: #333333; + background-position: 33px center; + padding-left: 53px; +} /* First level */ .branch .leaf-label { padding-left: 25px; @@ -26,4 +36,4 @@ .branch .branch .branch .leaf-label { background-position: 45px center; padding-left: 65px; -} \ No newline at end of file +} diff --git a/js/panels/presets/content.reel/content.css b/js/panels/presets/content.reel/content.css index c0ccbad4..409e1960 100644 --- a/js/panels/presets/content.reel/content.css +++ b/js/panels/presets/content.reel/content.css @@ -10,9 +10,7 @@ -webkit-box-orient: vertical; -webkit-box-flex: 1; } -.presetsPanel .treeRoot { - margin: 0 8px; -} + .tab-bar { -webkit-box-flex: 0; background-color: #282828; -- cgit v1.2.3 From 9e5e7159e7fb1b881de6c5d957645a4c845cde93 Mon Sep 17 00:00:00 2001 From: Eric Guzman Date: Tue, 13 Mar 2012 11:15:02 -0700 Subject: Presets Panel - Adding single-click activation --- js/panels/presets/style-presets.reel/style-presets.html | 2 +- js/panels/presets/transitions-presets.reel/transitions-presets.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'js') diff --git a/js/panels/presets/style-presets.reel/style-presets.html b/js/panels/presets/style-presets.reel/style-presets.html index 0db4d3c0..784c9527 100644 --- a/js/panels/presets/style-presets.reel/style-presets.html +++ b/js/panels/presets/style-presets.reel/style-presets.html @@ -40,7 +40,7 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot "element" : {"#": "libraryContainer"}, "branchComponent" : {"@": "branch" }, "contentController": {"@": "presetsController"}, - "activationEvent" : "dblclick", + "activationEvent" : "click", "showRoot" : false } }, diff --git a/js/panels/presets/transitions-presets.reel/transitions-presets.html b/js/panels/presets/transitions-presets.reel/transitions-presets.html index 5dc28edf..58f494d7 100644 --- a/js/panels/presets/transitions-presets.reel/transitions-presets.html +++ b/js/panels/presets/transitions-presets.reel/transitions-presets.html @@ -40,7 +40,7 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot "element" : {"#": "libraryContainer"}, "branchComponent" : {"@": "branch" }, "contentController": {"@": "presetsController"}, - "activationEvent" : "dblclick", + "activationEvent" : "click", "showRoot": false } }, -- cgit v1.2.3 From 76f2021618c0a6a99a1b855233e353e84ca99467 Mon Sep 17 00:00:00 2001 From: Pushkar Joshi Date: Tue, 13 Mar 2012 11:23:32 -0700 Subject: Add a smoothing amount parameter, and hide options based on checkboxes --- .../brush-properties.reel/brush-properties.html | 24 ++++++++++++++--- .../brush-properties.reel/brush-properties.js | 30 ++++++++++++++++++++++ js/lib/geom/brush-stroke.js | 17 ++++++------ js/tools/BrushTool.js | 9 ++++--- 4 files changed, 66 insertions(+), 14 deletions(-) (limited to 'js') diff --git a/js/components/tools-properties/brush-properties.reel/brush-properties.html b/js/components/tools-properties/brush-properties.reel/brush-properties.html index 608111bd..cbe4c242 100755 --- a/js/components/tools-properties/brush-properties.reel/brush-properties.html +++ b/js/components/tools-properties/brush-properties.reel/brush-properties.html @@ -33,7 +33,8 @@ "maxValue": 100, "value": 100, "decimalPlace": 10, - "acceptableUnits" : ["px", "pt"] + "acceptableUnits" : ["%"], + "units" : "%" } }, @@ -46,6 +47,20 @@ "maxValue": 90, "value": 0, "decimalPlace": 10, + "acceptableUnits" : ["deg."], + "units" : "deg." + } + }, + + "smoothingAmountHT": { + "module": "js/components/hottextunit.reel", + "name": "HotTextUnit", + "properties": { + "element": {"#": "smoothingAmount"}, + "minValue": 0, + "maxValue": 100, + "value": 0, + "decimalPlace": 10, "acceptableUnits" : ["px", "pt"] } }, @@ -58,8 +73,10 @@ "_strokeSize": {"@": "strokeSizeHT"}, "_strokeHardness": {"@": "strokeHardnessHT"}, "_doSmoothing": {"#": "doSmoothing"}, + "_smoothingAmount": {"@": "smoothingAmountHT"}, "_useCalligraphic":{"#": "useCalligraphic"}, - "_strokeAngle": {"@": "strokeAngleHT"} + "_strokeAngle": {"@": "strokeAngleHT"}, + "_angleLabel": {"#": "angleLabel"} } } } @@ -75,8 +92,9 @@
+
- +
diff --git a/js/components/tools-properties/brush-properties.reel/brush-properties.js b/js/components/tools-properties/brush-properties.reel/brush-properties.js index e6faa0f0..fdcd50f8 100755 --- a/js/components/tools-properties/brush-properties.reel/brush-properties.js +++ b/js/components/tools-properties/brush-properties.reel/brush-properties.js @@ -9,6 +9,33 @@ var Component = require("montage/ui/component").Component; var ToolProperties = require("js/components/tools-properties/tool-properties").ToolProperties; exports.BrushProperties = Montage.create(ToolProperties, { + _subPrepare: { + value: function() { + this.handleChange(null); + this._useCalligraphic.addEventListener("change", this, false); + this._doSmoothing.addEventListener("change", this, false); + } + }, + handleChange: { + value: function(event) { + if(this._useCalligraphic.checked) { + this._strokeAngle.element.style["display"] = ""; + this._strokeAngle.visible = true; + this._angleLabel.style["display"] = ""; + } else { + this._strokeAngle.element.style["display"] = "none"; + this._strokeAngle.visible = false; + this._angleLabel.style["display"] = "none"; + } + if(this._doSmoothing.checked) { + this._smoothingAmount.element.style["display"] = ""; + this._smoothingAmount.visible = true; + } else { + this._smoothingAmount.element.style["display"] = "none"; + this._smoothingAmount.visible = false; + } + } + }, strokeSize: { get: function() { return this._strokeSize; } }, @@ -18,6 +45,9 @@ exports.BrushProperties = Montage.create(ToolProperties, { doSmoothing:{ get: function() {return this._doSmoothing.checked; } }, + smoothingAmount:{ + get: function() {return this._smoothingAmount;} + }, useCalligraphic: { get: function() {return this._useCalligraphic.checked;} }, diff --git a/js/lib/geom/brush-stroke.js b/js/lib/geom/brush-stroke.js index 4c42539a..52f81ffe 100755 --- a/js/lib/geom/brush-stroke.js +++ b/js/lib/geom/brush-stroke.js @@ -39,10 +39,7 @@ var BrushStroke = function GLBrushStroke() { this._strokeDoSmoothing = false; this._strokeUseCalligraphic = false; this._strokeAngle = 0; - - //the wetness of the brush (currently this is multiplied to the square of the stroke width, but todo should be changed to not depend on stroke width entirely - //smaller value means more samples for the path - this._WETNESS_FACTOR = 0.25; + this._strokeAmountSmoothing = 0; //threshold that tells us whether two samples are too far apart this._MAX_SAMPLE_DISTANCE_THRESHOLD = 5; @@ -125,7 +122,7 @@ var BrushStroke = function GLBrushStroke() { //add the point only if it is some epsilon away from the previous point var numPoints = this._Points.length; if (numPoints>0) { - var threshold = this._MIN_SAMPLE_DISTANCE_THRESHOLD;//this._WETNESS_FACTOR*this._strokeWidth; + var threshold = this._MIN_SAMPLE_DISTANCE_THRESHOLD; var prevPt = this._Points[numPoints-1]; var diffPt = [prevPt[0]-pt[0], prevPt[1]-pt[1]]; var diffPtMag = Math.sqrt(diffPt[0]*diffPt[0] + diffPt[1]*diffPt[1]); @@ -196,6 +193,10 @@ var BrushStroke = function GLBrushStroke() { this._strokeDoSmoothing = s; } + this.setSmoothingAmount = function(a){ + this._strokeAmountSmoothing = a; + } + this.setStrokeUseCalligraphic = function(c){ this._strokeUseCalligraphic = c; } @@ -252,7 +253,7 @@ var BrushStroke = function GLBrushStroke() { //**** add samples to the path if needed...linear interpolation for now //if (numPoints>1) { if (0){ - var threshold = this._WETNESS_FACTOR*this._strokeWidth; + var threshold = this._MAX_SAMPLE_DISTANCE_THRESHOLD; var prevPt = this._Points[0]; var prevIndex = 0; for (var i=1;i1) { @@ -330,7 +331,7 @@ var BrushStroke = function GLBrushStroke() { console.log("Inserted "+numInsertedPoints+" additional CatmullRom points"); //now do 3-4 iterations of Laplacian smoothing (setting the points to the average of their neighbors) - var numLaplacianIterations = 3; //todo figure out the proper number of Laplacian iterations (perhaps as a function of stroke width) + var numLaplacianIterations = this._strokeAmountSmoothing; for (var n=0;n 2) { + //Removing stops + this.element._components.stopsContainer.removeChild(stop); + //Stopping events related to this current stop + this.removeStopMoving(); } } }, @@ -327,7 +319,7 @@ exports.GradientPicker = Montage.create(Component, { // this.application.ninja.colorController.colorPopupManager.hideColorChipPopup(); // - if ((e._event.y+this.hack.y) > this.element._trackY+50 || (e._event.y+this.hack.y) < this.element._trackY) { + if ((e._event.y+this.hack.y) > this.element._trackY+70 || (e._event.y+this.hack.y) < this.element._trackY) { this.removeStop(this.currentStop); } // -- cgit v1.2.3 From 0b8383232bc412d94ef234e49898d813436c63cc Mon Sep 17 00:00:00 2001 From: Eric Guzman Date: Tue, 13 Mar 2012 13:33:52 -0700 Subject: Presets Panel - Re-add dbl-click activation --- js/panels/presets/style-presets.reel/style-presets.html | 2 +- js/panels/presets/transitions-presets.reel/transitions-presets.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'js') diff --git a/js/panels/presets/style-presets.reel/style-presets.html b/js/panels/presets/style-presets.reel/style-presets.html index 784c9527..0db4d3c0 100644 --- a/js/panels/presets/style-presets.reel/style-presets.html +++ b/js/panels/presets/style-presets.reel/style-presets.html @@ -40,7 +40,7 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot "element" : {"#": "libraryContainer"}, "branchComponent" : {"@": "branch" }, "contentController": {"@": "presetsController"}, - "activationEvent" : "click", + "activationEvent" : "dblclick", "showRoot" : false } }, diff --git a/js/panels/presets/transitions-presets.reel/transitions-presets.html b/js/panels/presets/transitions-presets.reel/transitions-presets.html index 58f494d7..5dc28edf 100644 --- a/js/panels/presets/transitions-presets.reel/transitions-presets.html +++ b/js/panels/presets/transitions-presets.reel/transitions-presets.html @@ -40,7 +40,7 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot "element" : {"#": "libraryContainer"}, "branchComponent" : {"@": "branch" }, "contentController": {"@": "presetsController"}, - "activationEvent" : "click", + "activationEvent" : "dblclick", "showRoot": false } }, -- cgit v1.2.3 From 451cdd792046eca1d57dd205940e5b638f8a08ac Mon Sep 17 00:00:00 2001 From: Jose Antonio Marquez Date: Tue, 13 Mar 2012 15:19:35 -0700 Subject: Renaming folder --- js/panels/Color/colorbutton-manager.js | 44 - .../ColorPanelPopup.scssc | Bin 15335 -> 0 bytes .../ColorPanelPopup.scssc | Bin 17879 -> 0 bytes .../ColorPanelBase.scssc | Bin 23592 -> 0 bytes .../Color/colorchippopup.reel/colorchippopup.html | 63 - .../Color/colorchippopup.reel/colorchippopup.js | 590 ------- js/panels/Color/colorchippopup.reel/config.rb | 9 - .../colorchippopup.reel/css/colorchippopup.css | 239 --- .../colorchippopup.reel/css/colorchippopup.scss | 240 --- .../Color/colorchippopup.reel/img/icon_bitmap.png | Bin 3072 -> 0 bytes .../colorchippopup.reel/img/icon_colorwheel.png | Bin 3420 -> 0 bytes .../colorchippopup.reel/img/icon_gradient.png | Bin 2815 -> 0 bytes .../Color/colorchippopup.reel/img/icon_nofill.png | Bin 2951 -> 0 bytes js/panels/Color/colorchippopup.reel/img/knob.png | Bin 1036 -> 0 bytes js/panels/Color/colorpanel.js | 53 - .../Color/colorpanelbase.reel/colorpanelbase.html | 76 - .../Color/colorpanelbase.reel/colorpanelbase.js | 1654 -------------------- js/panels/Color/colorpanelbase.reel/config.rb | 9 - .../colorpanelbase.reel/css/colorpanelbase.css | 332 ---- .../colorpanelbase.reel/css/colorpanelbase.scss | 339 ---- .../Color/colorpanelbase.reel/img/icon_default.png | Bin 3011 -> 0 bytes .../Color/colorpanelbase.reel/img/icon_nocolor.png | Bin 3036 -> 0 bytes .../Color/colorpanelbase.reel/img/icon_swap.png | Bin 2961 -> 0 bytes js/panels/Color/colorpanelbase.reel/img/knob.png | Bin 1036 -> 0 bytes .../colorpanelpopup.reel/colorpanelpopup.html | 68 - .../Color/colorpanelpopup.reel/colorpanelpopup.js | 466 ------ js/panels/Color/colorpanelpopup.reel/config.rb | 9 - .../colorpanelpopup.reel/css/colorpanelpopup.css | 239 --- .../colorpanelpopup.reel/css/colorpanelpopup.scss | 240 --- .../Color/colorpanelpopup.reel/img/icon_bitmap.png | Bin 3072 -> 0 bytes .../colorpanelpopup.reel/img/icon_colorwheel.png | Bin 3420 -> 0 bytes .../colorpanelpopup.reel/img/icon_gradient.png | Bin 2815 -> 0 bytes .../Color/colorpanelpopup.reel/img/icon_nofill.png | Bin 2951 -> 0 bytes js/panels/Color/colorpanelpopup.reel/img/knob.png | Bin 1036 -> 0 bytes js/panels/Color/colorpopup-manager.js | 529 ------- .../Color/colortoolbar.reel/colortoolbar.html | 54 - js/panels/Color/colortoolbar.reel/colortoolbar.js | 138 -- js/panels/Color/colortoolbar.reel/config.rb | 9 - .../Color/colortoolbar.reel/css/colortoolbar.css | 45 - .../Color/colortoolbar.reel/css/colortoolbar.scss | 52 - js/panels/_color/colorbutton-manager.js | 44 + .../_color/colorchippopup.reel/colorchippopup.html | 63 + .../_color/colorchippopup.reel/colorchippopup.js | 590 +++++++ js/panels/_color/colorchippopup.reel/config.rb | 9 + .../colorchippopup.reel/css/colorchippopup.css | 239 +++ .../colorchippopup.reel/css/colorchippopup.scss | 240 +++ .../_color/colorchippopup.reel/img/icon_bitmap.png | Bin 0 -> 3072 bytes .../colorchippopup.reel/img/icon_colorwheel.png | Bin 0 -> 3420 bytes .../colorchippopup.reel/img/icon_gradient.png | Bin 0 -> 2815 bytes .../_color/colorchippopup.reel/img/icon_nofill.png | Bin 0 -> 2951 bytes js/panels/_color/colorchippopup.reel/img/knob.png | Bin 0 -> 1036 bytes js/panels/_color/colorpanel.js | 53 + .../_color/colorpanelbase.reel/colorpanelbase.html | 76 + .../_color/colorpanelbase.reel/colorpanelbase.js | 1654 ++++++++++++++++++++ js/panels/_color/colorpanelbase.reel/config.rb | 9 + .../colorpanelbase.reel/css/colorpanelbase.css | 332 ++++ .../colorpanelbase.reel/css/colorpanelbase.scss | 339 ++++ .../colorpanelbase.reel/img/icon_default.png | Bin 0 -> 3011 bytes .../colorpanelbase.reel/img/icon_nocolor.png | Bin 0 -> 3036 bytes .../_color/colorpanelbase.reel/img/icon_swap.png | Bin 0 -> 2961 bytes js/panels/_color/colorpanelbase.reel/img/knob.png | Bin 0 -> 1036 bytes .../colorpanelpopup.reel/colorpanelpopup.html | 68 + .../_color/colorpanelpopup.reel/colorpanelpopup.js | 466 ++++++ js/panels/_color/colorpanelpopup.reel/config.rb | 9 + .../colorpanelpopup.reel/css/colorpanelpopup.css | 239 +++ .../colorpanelpopup.reel/css/colorpanelpopup.scss | 240 +++ .../colorpanelpopup.reel/img/icon_bitmap.png | Bin 0 -> 3072 bytes .../colorpanelpopup.reel/img/icon_colorwheel.png | Bin 0 -> 3420 bytes .../colorpanelpopup.reel/img/icon_gradient.png | Bin 0 -> 2815 bytes .../colorpanelpopup.reel/img/icon_nofill.png | Bin 0 -> 2951 bytes js/panels/_color/colorpanelpopup.reel/img/knob.png | Bin 0 -> 1036 bytes js/panels/_color/colorpopup-manager.js | 529 +++++++ .../_color/colortoolbar.reel/colortoolbar.html | 54 + js/panels/_color/colortoolbar.reel/colortoolbar.js | 138 ++ js/panels/_color/colortoolbar.reel/config.rb | 9 + .../_color/colortoolbar.reel/css/colortoolbar.css | 45 + .../_color/colortoolbar.reel/css/colortoolbar.scss | 52 + js/panels/color/colorbutton-manager.js | 44 + .../color/colorchippopup.reel/colorchippopup.html | 63 + .../color/colorchippopup.reel/colorchippopup.js | 590 +++++++ js/panels/color/colorchippopup.reel/config.rb | 9 + .../colorchippopup.reel/css/colorchippopup.css | 239 +++ .../colorchippopup.reel/css/colorchippopup.scss | 240 +++ .../color/colorchippopup.reel/img/icon_bitmap.png | Bin 0 -> 3072 bytes .../colorchippopup.reel/img/icon_colorwheel.png | Bin 0 -> 3420 bytes .../colorchippopup.reel/img/icon_gradient.png | Bin 0 -> 2815 bytes .../color/colorchippopup.reel/img/icon_nofill.png | Bin 0 -> 2951 bytes js/panels/color/colorchippopup.reel/img/knob.png | Bin 0 -> 1036 bytes js/panels/color/colorpanel.js | 53 + .../color/colorpanelbase.reel/colorpanelbase.html | 76 + .../color/colorpanelbase.reel/colorpanelbase.js | 1654 ++++++++++++++++++++ js/panels/color/colorpanelbase.reel/config.rb | 9 + .../colorpanelbase.reel/css/colorpanelbase.css | 332 ++++ .../colorpanelbase.reel/css/colorpanelbase.scss | 339 ++++ .../color/colorpanelbase.reel/img/icon_default.png | Bin 0 -> 3011 bytes .../color/colorpanelbase.reel/img/icon_nocolor.png | Bin 0 -> 3036 bytes .../color/colorpanelbase.reel/img/icon_swap.png | Bin 0 -> 2961 bytes js/panels/color/colorpanelbase.reel/img/knob.png | Bin 0 -> 1036 bytes .../colorpanelpopup.reel/colorpanelpopup.html | 68 + .../color/colorpanelpopup.reel/colorpanelpopup.js | 466 ++++++ js/panels/color/colorpanelpopup.reel/config.rb | 9 + .../colorpanelpopup.reel/css/colorpanelpopup.css | 239 +++ .../colorpanelpopup.reel/css/colorpanelpopup.scss | 240 +++ .../color/colorpanelpopup.reel/img/icon_bitmap.png | Bin 0 -> 3072 bytes .../colorpanelpopup.reel/img/icon_colorwheel.png | Bin 0 -> 3420 bytes .../colorpanelpopup.reel/img/icon_gradient.png | Bin 0 -> 2815 bytes .../color/colorpanelpopup.reel/img/icon_nofill.png | Bin 0 -> 2951 bytes js/panels/color/colorpanelpopup.reel/img/knob.png | Bin 0 -> 1036 bytes js/panels/color/colorpopup-manager.js | 529 +++++++ .../color/colortoolbar.reel/colortoolbar.html | 54 + js/panels/color/colortoolbar.reel/colortoolbar.js | 138 ++ js/panels/color/colortoolbar.reel/config.rb | 9 + .../color/colortoolbar.reel/css/colortoolbar.css | 45 + .../color/colortoolbar.reel/css/colortoolbar.scss | 52 + 114 files changed, 10994 insertions(+), 5497 deletions(-) delete mode 100755 js/panels/Color/colorbutton-manager.js delete mode 100755 js/panels/Color/colorchippopup.reel/.sass-cache/2fbca323ccf38cf180e7675ba0d8d3e07adeffea/ColorPanelPopup.scssc delete mode 100755 js/panels/Color/colorchippopup.reel/.sass-cache/6f8390f69a31f1a976968b9c18d0824d78460db2/ColorPanelPopup.scssc delete mode 100755 js/panels/Color/colorchippopup.reel/.sass-cache/de22270a8ac487505e8876f1cd16286e094a5127/ColorPanelBase.scssc delete mode 100755 js/panels/Color/colorchippopup.reel/colorchippopup.html delete mode 100755 js/panels/Color/colorchippopup.reel/colorchippopup.js delete mode 100755 js/panels/Color/colorchippopup.reel/config.rb delete mode 100755 js/panels/Color/colorchippopup.reel/css/colorchippopup.css delete mode 100755 js/panels/Color/colorchippopup.reel/css/colorchippopup.scss delete mode 100755 js/panels/Color/colorchippopup.reel/img/icon_bitmap.png delete mode 100755 js/panels/Color/colorchippopup.reel/img/icon_colorwheel.png delete mode 100755 js/panels/Color/colorchippopup.reel/img/icon_gradient.png delete mode 100755 js/panels/Color/colorchippopup.reel/img/icon_nofill.png delete mode 100755 js/panels/Color/colorchippopup.reel/img/knob.png delete mode 100755 js/panels/Color/colorpanel.js delete mode 100755 js/panels/Color/colorpanelbase.reel/colorpanelbase.html delete mode 100755 js/panels/Color/colorpanelbase.reel/colorpanelbase.js delete mode 100755 js/panels/Color/colorpanelbase.reel/config.rb delete mode 100755 js/panels/Color/colorpanelbase.reel/css/colorpanelbase.css delete mode 100755 js/panels/Color/colorpanelbase.reel/css/colorpanelbase.scss delete mode 100755 js/panels/Color/colorpanelbase.reel/img/icon_default.png delete mode 100755 js/panels/Color/colorpanelbase.reel/img/icon_nocolor.png delete mode 100755 js/panels/Color/colorpanelbase.reel/img/icon_swap.png delete mode 100755 js/panels/Color/colorpanelbase.reel/img/knob.png delete mode 100755 js/panels/Color/colorpanelpopup.reel/colorpanelpopup.html delete mode 100755 js/panels/Color/colorpanelpopup.reel/colorpanelpopup.js delete mode 100755 js/panels/Color/colorpanelpopup.reel/config.rb delete mode 100755 js/panels/Color/colorpanelpopup.reel/css/colorpanelpopup.css delete mode 100755 js/panels/Color/colorpanelpopup.reel/css/colorpanelpopup.scss delete mode 100755 js/panels/Color/colorpanelpopup.reel/img/icon_bitmap.png delete mode 100755 js/panels/Color/colorpanelpopup.reel/img/icon_colorwheel.png delete mode 100755 js/panels/Color/colorpanelpopup.reel/img/icon_gradient.png delete mode 100755 js/panels/Color/colorpanelpopup.reel/img/icon_nofill.png delete mode 100755 js/panels/Color/colorpanelpopup.reel/img/knob.png delete mode 100755 js/panels/Color/colorpopup-manager.js delete mode 100755 js/panels/Color/colortoolbar.reel/colortoolbar.html delete mode 100755 js/panels/Color/colortoolbar.reel/colortoolbar.js delete mode 100755 js/panels/Color/colortoolbar.reel/config.rb delete mode 100755 js/panels/Color/colortoolbar.reel/css/colortoolbar.css delete mode 100755 js/panels/Color/colortoolbar.reel/css/colortoolbar.scss create mode 100755 js/panels/_color/colorbutton-manager.js create mode 100755 js/panels/_color/colorchippopup.reel/colorchippopup.html create mode 100755 js/panels/_color/colorchippopup.reel/colorchippopup.js create mode 100755 js/panels/_color/colorchippopup.reel/config.rb create mode 100755 js/panels/_color/colorchippopup.reel/css/colorchippopup.css create mode 100755 js/panels/_color/colorchippopup.reel/css/colorchippopup.scss create mode 100755 js/panels/_color/colorchippopup.reel/img/icon_bitmap.png create mode 100755 js/panels/_color/colorchippopup.reel/img/icon_colorwheel.png create mode 100755 js/panels/_color/colorchippopup.reel/img/icon_gradient.png create mode 100755 js/panels/_color/colorchippopup.reel/img/icon_nofill.png create mode 100755 js/panels/_color/colorchippopup.reel/img/knob.png create mode 100755 js/panels/_color/colorpanel.js create mode 100755 js/panels/_color/colorpanelbase.reel/colorpanelbase.html create mode 100755 js/panels/_color/colorpanelbase.reel/colorpanelbase.js create mode 100755 js/panels/_color/colorpanelbase.reel/config.rb create mode 100755 js/panels/_color/colorpanelbase.reel/css/colorpanelbase.css create mode 100755 js/panels/_color/colorpanelbase.reel/css/colorpanelbase.scss create mode 100755 js/panels/_color/colorpanelbase.reel/img/icon_default.png create mode 100755 js/panels/_color/colorpanelbase.reel/img/icon_nocolor.png create mode 100755 js/panels/_color/colorpanelbase.reel/img/icon_swap.png create mode 100755 js/panels/_color/colorpanelbase.reel/img/knob.png create mode 100755 js/panels/_color/colorpanelpopup.reel/colorpanelpopup.html create mode 100755 js/panels/_color/colorpanelpopup.reel/colorpanelpopup.js create mode 100755 js/panels/_color/colorpanelpopup.reel/config.rb create mode 100755 js/panels/_color/colorpanelpopup.reel/css/colorpanelpopup.css create mode 100755 js/panels/_color/colorpanelpopup.reel/css/colorpanelpopup.scss create mode 100755 js/panels/_color/colorpanelpopup.reel/img/icon_bitmap.png create mode 100755 js/panels/_color/colorpanelpopup.reel/img/icon_colorwheel.png create mode 100755 js/panels/_color/colorpanelpopup.reel/img/icon_gradient.png create mode 100755 js/panels/_color/colorpanelpopup.reel/img/icon_nofill.png create mode 100755 js/panels/_color/colorpanelpopup.reel/img/knob.png create mode 100755 js/panels/_color/colorpopup-manager.js create mode 100755 js/panels/_color/colortoolbar.reel/colortoolbar.html create mode 100755 js/panels/_color/colortoolbar.reel/colortoolbar.js create mode 100755 js/panels/_color/colortoolbar.reel/config.rb create mode 100755 js/panels/_color/colortoolbar.reel/css/colortoolbar.css create mode 100755 js/panels/_color/colortoolbar.reel/css/colortoolbar.scss create mode 100755 js/panels/color/colorbutton-manager.js create mode 100755 js/panels/color/colorchippopup.reel/colorchippopup.html create mode 100755 js/panels/color/colorchippopup.reel/colorchippopup.js create mode 100755 js/panels/color/colorchippopup.reel/config.rb create mode 100755 js/panels/color/colorchippopup.reel/css/colorchippopup.css create mode 100755 js/panels/color/colorchippopup.reel/css/colorchippopup.scss create mode 100755 js/panels/color/colorchippopup.reel/img/icon_bitmap.png create mode 100755 js/panels/color/colorchippopup.reel/img/icon_colorwheel.png create mode 100755 js/panels/color/colorchippopup.reel/img/icon_gradient.png create mode 100755 js/panels/color/colorchippopup.reel/img/icon_nofill.png create mode 100755 js/panels/color/colorchippopup.reel/img/knob.png create mode 100755 js/panels/color/colorpanel.js create mode 100755 js/panels/color/colorpanelbase.reel/colorpanelbase.html create mode 100755 js/panels/color/colorpanelbase.reel/colorpanelbase.js create mode 100755 js/panels/color/colorpanelbase.reel/config.rb create mode 100755 js/panels/color/colorpanelbase.reel/css/colorpanelbase.css create mode 100755 js/panels/color/colorpanelbase.reel/css/colorpanelbase.scss create mode 100755 js/panels/color/colorpanelbase.reel/img/icon_default.png create mode 100755 js/panels/color/colorpanelbase.reel/img/icon_nocolor.png create mode 100755 js/panels/color/colorpanelbase.reel/img/icon_swap.png create mode 100755 js/panels/color/colorpanelbase.reel/img/knob.png create mode 100755 js/panels/color/colorpanelpopup.reel/colorpanelpopup.html create mode 100755 js/panels/color/colorpanelpopup.reel/colorpanelpopup.js create mode 100755 js/panels/color/colorpanelpopup.reel/config.rb create mode 100755 js/panels/color/colorpanelpopup.reel/css/colorpanelpopup.css create mode 100755 js/panels/color/colorpanelpopup.reel/css/colorpanelpopup.scss create mode 100755 js/panels/color/colorpanelpopup.reel/img/icon_bitmap.png create mode 100755 js/panels/color/colorpanelpopup.reel/img/icon_colorwheel.png create mode 100755 js/panels/color/colorpanelpopup.reel/img/icon_gradient.png create mode 100755 js/panels/color/colorpanelpopup.reel/img/icon_nofill.png create mode 100755 js/panels/color/colorpanelpopup.reel/img/knob.png create mode 100755 js/panels/color/colorpopup-manager.js create mode 100755 js/panels/color/colortoolbar.reel/colortoolbar.html create mode 100755 js/panels/color/colortoolbar.reel/colortoolbar.js create mode 100755 js/panels/color/colortoolbar.reel/config.rb create mode 100755 js/panels/color/colortoolbar.reel/css/colortoolbar.css create mode 100755 js/panels/color/colortoolbar.reel/css/colortoolbar.scss (limited to 'js') diff --git a/js/panels/Color/colorbutton-manager.js b/js/panels/Color/colorbutton-manager.js deleted file mode 100755 index a189d040..00000000 --- a/js/panels/Color/colorbutton-manager.js +++ /dev/null @@ -1,44 +0,0 @@ -/* -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. -
*/ - -//////////////////////////////////////////////////////////////////////// -// -var Montage = require("montage/core/core").Montage, - Component = require("montage/ui/component").Component; -//////////////////////////////////////////////////////////////////////// -//Exporting as ColorPopupManager -exports.ColorButtonManager = Montage.create(Component, { - //////////////////////////////////////////////////////////////////// - // - hasTemplate: { - value: false - }, - //////////////////////////////////////////////////////////////////// - //Storing color manager - _colorManager: { - enumerable: false, - value: null - }, - //////////////////////////////////////////////////////////////////// - // - colorManager: { - enumerable: true, - get: function() { - return this._colorManager; - }, - set: function(value) { - this._colorManager = value; - } - }, - //////////////////////////////////////////////////////////////////// - // - _buttons: { - enumerable: false, - value: {chip: [], fill: [], stroke: [], current: [], previous: [], rgbmode: [], hslmode: [], hexinput: [], nocolor: [], reset: [], swap: [], mlabel1: [], mlabel2: [], mlabel3: []} - } - //////////////////////////////////////////////////////////////////// - //////////////////////////////////////////////////////////////////// -}); \ No newline at end of file diff --git a/js/panels/Color/colorchippopup.reel/.sass-cache/2fbca323ccf38cf180e7675ba0d8d3e07adeffea/ColorPanelPopup.scssc b/js/panels/Color/colorchippopup.reel/.sass-cache/2fbca323ccf38cf180e7675ba0d8d3e07adeffea/ColorPanelPopup.scssc deleted file mode 100755 index aa8bf258..00000000 Binary files a/js/panels/Color/colorchippopup.reel/.sass-cache/2fbca323ccf38cf180e7675ba0d8d3e07adeffea/ColorPanelPopup.scssc and /dev/null differ diff --git a/js/panels/Color/colorchippopup.reel/.sass-cache/6f8390f69a31f1a976968b9c18d0824d78460db2/ColorPanelPopup.scssc b/js/panels/Color/colorchippopup.reel/.sass-cache/6f8390f69a31f1a976968b9c18d0824d78460db2/ColorPanelPopup.scssc deleted file mode 100755 index fca60390..00000000 Binary files a/js/panels/Color/colorchippopup.reel/.sass-cache/6f8390f69a31f1a976968b9c18d0824d78460db2/ColorPanelPopup.scssc and /dev/null differ diff --git a/js/panels/Color/colorchippopup.reel/.sass-cache/de22270a8ac487505e8876f1cd16286e094a5127/ColorPanelBase.scssc b/js/panels/Color/colorchippopup.reel/.sass-cache/de22270a8ac487505e8876f1cd16286e094a5127/ColorPanelBase.scssc deleted file mode 100755 index fd7938d8..00000000 Binary files a/js/panels/Color/colorchippopup.reel/.sass-cache/de22270a8ac487505e8876f1cd16286e094a5127/ColorPanelBase.scssc and /dev/null differ diff --git a/js/panels/Color/colorchippopup.reel/colorchippopup.html b/js/panels/Color/colorchippopup.reel/colorchippopup.html deleted file mode 100755 index 1ae40cc1..00000000 --- a/js/panels/Color/colorchippopup.reel/colorchippopup.html +++ /dev/null @@ -1,63 +0,0 @@ - - - - - - - - - - - - - - - -
-
- -
#
- - - - - - - -
- -
-
-
-
-
-
- -
-
Alpha
-
- -
%
-
- -
- - - - \ No newline at end of file diff --git a/js/panels/Color/colorchippopup.reel/colorchippopup.js b/js/panels/Color/colorchippopup.reel/colorchippopup.js deleted file mode 100755 index 05bcb447..00000000 --- a/js/panels/Color/colorchippopup.reel/colorchippopup.js +++ /dev/null @@ -1,590 +0,0 @@ -/* -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. -
*/ - -//////////////////////////////////////////////////////////////////////// -// -var Montage = require("montage/core/core").Montage, - Component = require("montage/ui/component").Component, - Slider = require("js/components/slider.reel").Slider, - Button = require("js/components/button.reel").Button, - HotText = require("js/components/hottext.reel").HotText, - ColorWheel = require("js/components/colorwheel.reel").ColorWheel, - GradientPicker = require("js/components/gradientpicker.reel").GradientPicker; -//////////////////////////////////////////////////////////////////////// -//Exporting as ColorPanelPopup -exports.ColorChipPopup = Montage.create(Component, { - //////////////////////////////////////////////////////////////////// - // - hasTemplate: { - value: true - }, - //////////////////////////////////////////////////////////////////// - //Storing color manager - _colorManager: { - enumerable: false, - value: false - }, - //////////////////////////////////////////////////////////////////// - //Color manager - colorManager: { - enumerable: true, - get: function() { - return this._colorManager; - }, - set: function(value) { - if (value !== this._colorManager) { - this._colorManager = value; - } - } - }, - //////////////////////////////////////////////////////////////////// - // - setNoColor: { - enumerable: true, - value: function (e) { - this.colorManager.applyNoColor(); - } - }, - //////////////////////////////////////////////////////////////////// - // - _colorChipWheel: { - enumerable: false, - value: null - }, - /////////////////////////////////////////////