From 29ad6355ef60cfb3b3fc7f780504f3ed30845883 Mon Sep 17 00:00:00 2001 From: John Mayhew Date: Mon, 7 May 2012 14:30:47 -0700 Subject: More implementation of moving color chips to the individual subtools. Removed the tool color bar Added new icons for inkbottle Removed Pencil tool Removed Inkbottle tool Added chips to the pen, brush and tag tools Aligned controls in several subtools --- js/components/layout/tools-list.reel/tools-list.html | 10 ---------- js/components/layout/tools-list.reel/tools-list.js | 4 ---- .../layout/tools-properties.reel/tools-properties.html | 16 ---------------- 3 files changed, 30 deletions(-) (limited to 'js/components/layout') diff --git a/js/components/layout/tools-list.reel/tools-list.html b/js/components/layout/tools-list.reel/tools-list.html index acee20b2..f559e748 100755 --- a/js/components/layout/tools-list.reel/tools-list.html +++ b/js/components/layout/tools-list.reel/tools-list.html @@ -85,9 +85,6 @@ "LineTool1": { "prototype": "js/tools/LineTool" }, - "PencilTool1": { - "prototype": "js/tools/PencilTool" - }, "BrushTool1": { "prototype": "js/tools/BrushTool" }, @@ -97,9 +94,6 @@ "InkBottleTool1": { "prototype": "js/tools/InkBottleTool" }, - "EyedropperTool1": { - "prototype": "js/tools/EyedropperTool" - }, "EraserTool1": { "prototype": "js/tools/EraserTool" }, @@ -142,11 +136,9 @@ "OvalTool": {"@": "OvalTool1"}, "RectTool": {"@": "RectTool1"}, "LineTool": {"@": "LineTool1"}, - "PencilTool": {"@": "PencilTool1"}, "BrushTool": {"@": "BrushTool1"}, "FillTool": {"@": "FillTool1"}, "InkBottleTool": {"@": "InkBottleTool1"}, - "EyedropperTool": {"@": "EyedropperTool1"}, "EraserTool": {"@": "EraserTool1"}, "RotateStageTool3D": {"@": "RotateStageTool3D1"}, "PanTool": {"@": "PanTool1"}, @@ -169,8 +161,6 @@
- -
diff --git a/js/components/layout/tools-list.reel/tools-list.js b/js/components/layout/tools-list.reel/tools-list.js index d68e8a56..ed4ee45f 100755 --- a/js/components/layout/tools-list.reel/tools-list.js +++ b/js/components/layout/tools-list.reel/tools-list.js @@ -20,11 +20,9 @@ exports.ToolsList = Montage.create(Component, { OvalTool: { value: null }, RectTool: { value: null }, LineTool: { value: null }, - PencilTool: { value: null }, BrushTool: { value: null }, FillTool: { value: null }, InkBottleTool: { value: null }, - EyedropperTool: { value: null }, EraserTool: { value: null }, RotateStageTool3D: { value: null }, PanTool: { value: null }, @@ -68,10 +66,8 @@ exports.ToolsList = Montage.create(Component, { this.OvalTool.options = this.application.ninja.toolsProperties.shapeProperties.ovalProperties; this.RectTool.options = this.application.ninja.toolsProperties.shapeProperties.rectProperties; this.LineTool.options = this.application.ninja.toolsProperties.shapeProperties.lineProperties; - this.PencilTool.options = this.application.ninja.toolsProperties.pencilProperties; this.BrushTool.options = this.application.ninja.toolsProperties.brushProperties; - this.EyedropperTool.options = this.application.ninja.toolsProperties.eyedropperProperties; this.EraserTool.options = this.application.ninja.toolsProperties.eraserProperties; this.RotateStageTool3D.options = this.application.ninja.toolsProperties.rotateStageProperties; this.PanTool.options = this.application.ninja.toolsProperties.panProperties; diff --git a/js/components/layout/tools-properties.reel/tools-properties.html b/js/components/layout/tools-properties.reel/tools-properties.html index 8dd0f713..c51ab27d 100755 --- a/js/components/layout/tools-properties.reel/tools-properties.html +++ b/js/components/layout/tools-properties.reel/tools-properties.html @@ -66,12 +66,6 @@ } } }, - "pencilProperties1": { - "prototype": "js/components/tools-properties/pencil-properties.reel", - "properties": { - "element": {"#": "pencilProperties"} - } - }, "brushProperties1": { "prototype": "js/components/tools-properties/brush-properties.reel", "properties": { @@ -90,12 +84,6 @@ "element": {"#": "inkbottleProperties"} } }, - "eyedropperProperties1": { - "prototype": "js/components/tools-properties/eyedropper-properties.reel", - "properties": { - "element": {"#": "eyedropperProperties"} - } - }, "eraserProperties1": { "prototype": "js/components/tools-properties/eraser-properties.reel", "properties": { @@ -147,11 +135,9 @@ "penProperties": {"@": "penProperties1"}, "textProperties": {"@": "textProperties1"}, "shapeProperties": {"@": "shapeProperties1"}, - "pencilProperties": {"@": "pencilProperties1"}, "brushProperties": {"@": "brushProperties1"}, "fillProperties": {"@": "fillProperties1"}, "inkbottleProperties": {"@": "inkbottleProperties1"}, - "eyedropperProperties": {"@": "eyedropperProperties1"}, "eraserProperties": {"@": "eraserProperties1"}, "rotateStageProperties": {"@": "rotateStageProperties1"}, "panProperties": {"@": "panProperties1"}, @@ -179,11 +165,9 @@
-
-
-- cgit v1.2.3 From dd663d8fe9191cc57c9cebe6d425562cb45982c2 Mon Sep 17 00:00:00 2001 From: John Mayhew Date: Tue, 8 May 2012 07:25:09 -0700 Subject: Removed unused SubSelect Tool --- js/components/layout/tools-list.reel/tools-list.html | 4 ---- js/components/layout/tools-list.reel/tools-list.js | 2 -- js/components/layout/tools-properties.reel/tools-properties.html | 8 -------- 3 files changed, 14 deletions(-) (limited to 'js/components/layout') diff --git a/js/components/layout/tools-list.reel/tools-list.html b/js/components/layout/tools-list.reel/tools-list.html index 0c51aa9a..d5c33624 100755 --- a/js/components/layout/tools-list.reel/tools-list.html +++ b/js/components/layout/tools-list.reel/tools-list.html @@ -55,9 +55,6 @@ "SelectionTool1": { "prototype": "js/tools/SelectionTool" }, - "SubselectionTool1": { - "prototype": "js/tools/SubSelectTool" - }, "Rotate3DTool1": { "prototype": "js/tools/RotateObject3DTool" }, @@ -126,7 +123,6 @@ "properties": { "element": {"#": "toolsList"}, "SelectionTool": {"@": "SelectionTool1"}, - "SubselectionTool": {"@": "SubselectionTool1"}, "Rotate3DTool": {"@": "Rotate3DTool1"}, "Translate3DTool": {"@": "Translate3DTool1"}, "TagTool": {"@": "TagTool1"}, diff --git a/js/components/layout/tools-list.reel/tools-list.js b/js/components/layout/tools-list.reel/tools-list.js index ed4ee45f..a10b6c3e 100755 --- a/js/components/layout/tools-list.reel/tools-list.js +++ b/js/components/layout/tools-list.reel/tools-list.js @@ -10,7 +10,6 @@ var Component = require("montage/ui/component").Component; exports.ToolsList = Montage.create(Component, { SelectionTool: { value: null }, - SubselectionTool: { value: null }, Rotate3DTool: { value: null }, Translate3DTool: { value: null }, TagTool: { value: null }, @@ -51,7 +50,6 @@ exports.ToolsList = Montage.create(Component, { this.PenTool.options = this.application.ninja.toolsProperties.shapeProperties.lineProperties;//this.application.Ninja.toolsProperties.penProperties; this.SelectionTool.options = this.application.ninja.toolsProperties.selectionProperties; - this.SubselectionTool.options = this.application.ninja.toolsProperties.subSelectionProperties; this.Rotate3DTool.options = this.application.ninja.toolsProperties.rotate3DProperties; this.Translate3DTool.options = this.application.ninja.toolsProperties.rotate3DProperties; diff --git a/js/components/layout/tools-properties.reel/tools-properties.html b/js/components/layout/tools-properties.reel/tools-properties.html index a24ce658..e7d1ac8b 100755 --- a/js/components/layout/tools-properties.reel/tools-properties.html +++ b/js/components/layout/tools-properties.reel/tools-properties.html @@ -18,12 +18,6 @@ "element": {"#": "selectionProperties"} } }, - "subSelectionProperties1": { - "prototype": "js/components/tools-properties/subselection-properties.reel[SubSelectionProperties]", - "properties": { - "element": {"#": "subSelectionProperties"} - } - }, "object3DProperties1": { "prototype": "js/components/tools-properties/object3d-properties.reel[Object3DProperties]", "properties": { @@ -128,7 +122,6 @@ "properties": { "element": {"#": "toolsProperties"}, "selectionProperties": {"@": "selectionProperties1"}, - "subSelectionProperties": {"@": "subSelectionProperties1"}, "rotate3DProperties": {"@": "object3DProperties1"}, "translate3DProperties": {"@": "object3DProperties1"}, "tagProperties": {"@": "tagProperties1"}, @@ -159,7 +152,6 @@
-
-- cgit v1.2.3 From 919a0d0ed35c24b1047281723ddde2ac98fc9a3e Mon Sep 17 00:00:00 2001 From: Valerio Virgillito Date: Tue, 15 May 2012 22:36:44 -0700 Subject: document close handler. initial working draft Signed-off-by: Valerio Virgillito --- js/components/layout/document-entry.reel/document-entry.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'js/components/layout') diff --git a/js/components/layout/document-entry.reel/document-entry.js b/js/components/layout/document-entry.reel/document-entry.js index 81a63c90..4d09a362 100755 --- a/js/components/layout/document-entry.reel/document-entry.js +++ b/js/components/layout/document-entry.reel/document-entry.js @@ -117,7 +117,7 @@ exports.DocumentEntry = Montage.create(Component, { handleClick: { value: function(event) { if(event._event.target.nodeName === "IMG") { - this.application.ninja.documentController.closeDocument(this._uuid); + this.application.ninja.documentController.closeFile(this.application.ninja.documentController._findDocumentByUUID(this._uuid)); } else { if(!this._document.isActive) { this.application.ninja.stage.stageView.switchDocument(this.application.ninja.documentController._findDocumentByUUID(this._uuid)); -- cgit v1.2.3 From 2c9ed2068b12884fc026fe3a7b57021e7e591f1c Mon Sep 17 00:00:00 2001 From: Valerio Virgillito Date: Wed, 16 May 2012 16:04:22 -0700 Subject: fixing a null value for the document entry bar Signed-off-by: Valerio Virgillito --- js/components/layout/document-entry.reel/document-entry.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'js/components/layout') diff --git a/js/components/layout/document-entry.reel/document-entry.js b/js/components/layout/document-entry.reel/document-entry.js index 4d09a362..ad0236c6 100755 --- a/js/components/layout/document-entry.reel/document-entry.js +++ b/js/components/layout/document-entry.reel/document-entry.js @@ -33,8 +33,10 @@ exports.DocumentEntry = Montage.create(Component, { } this._document = value; - this._uuid = value.uuid; - //this.needsDraw = true; + + if(value) { + this._uuid = value.uuid; + } } }, -- cgit v1.2.3 From b97570f5daff9d0c40f274c2c29a457079da1c1a Mon Sep 17 00:00:00 2001 From: Valerio Virgillito Date: Thu, 17 May 2012 12:23:31 -0700 Subject: fixing the breadcrumb Signed-off-by: Valerio Virgillito --- .../layout/bread-crumb.reel/bread-crumb.html | 37 ++++++++-------------- .../layout/bread-crumb.reel/bread-crumb.js | 24 ++++---------- 2 files changed, 19 insertions(+), 42 deletions(-) (limited to 'js/components/layout') diff --git a/js/components/layout/bread-crumb.reel/bread-crumb.html b/js/components/layout/bread-crumb.reel/bread-crumb.html index ae3e2022..0dabc781 100755 --- a/js/components/layout/bread-crumb.reel/bread-crumb.html +++ b/js/components/layout/bread-crumb.reel/bread-crumb.html @@ -32,30 +32,23 @@ } ], "bindings": { - "label": { - "boundObject": {"@": "repetition1"}, - "boundObjectPropertyPath": "objectAtCurrentIteration.label", - "oneway": true - }, - "value": { - "boundObject": {"@": "repetition1"}, - "boundObjectPropertyPath": "objectAtCurrentIteration.nodeUuid", - "oneway": true - } + "label": {"<-": "@buttonsList.objectAtCurrentIteration.label"}, + "value": {"<-": "@buttonsList.objectAtCurrentIteration.nodeUuid"} + } + }, + + "buttonsListController": { + "prototype": "montage/ui/controller/array-controller", + "bindings": { + "content": {"<<->": "@owner.containerElements"} } }, - "repetition1": { + "buttonsList": { "prototype": "montage/ui/repetition.reel", "properties": { - "element": {"#": "breadcrumb_container"} - }, - "bindings": { - "objects": { - "boundObject": {"@": "owner"}, - "boundObjectPropertyPath": "containerElements", - "oneway": true - } + "element": {"#": "breadcrumb_container"}, + "contentController": {"@": "buttonsListController"} } }, @@ -65,11 +58,7 @@ "element": {"#": "disabledCondition"} }, "bindings": { - "condition": { - "boundObject": {"@": "owner"}, - "boundObjectPropertyPath": "disabled", - "oneway": true - } + "condition": {"<-": "@owner.disabled"} } } } diff --git a/js/components/layout/bread-crumb.reel/bread-crumb.js b/js/components/layout/bread-crumb.reel/bread-crumb.js index c1b021a3..d2a6b1e4 100755 --- a/js/components/layout/bread-crumb.reel/bread-crumb.js +++ b/js/components/layout/bread-crumb.reel/bread-crumb.js @@ -60,30 +60,18 @@ exports.Breadcrumb = Montage.create(Component, { value: function() { var parentNode; - this.containerElements.length = 0; +// delete this.containerElements; + this.containerElements = []; parentNode = this.container; - // This is for the old template support. - // TODO: Remove marker for old template: NINJA-STAGE-REWORK - if(this.application.ninja.currentDocument.documentRoot.id === "UserContent") { - while(parentNode.id !== "UserContent") { - this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": parentNode.nodeName}); - parentNode = parentNode.parentNode; - } - - // This is always the top container which is now hardcoded to body - this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": "Body"}); - } else { - while(parentNode !== this.application.ninja.currentDocument.documentRoot) { - this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": parentNode.nodeName}); - parentNode = parentNode.parentNode; - } - - // This is always the top container which is now hardcoded to body + while(parentNode !== this.application.ninja.currentDocument.documentRoot) { this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": parentNode.nodeName}); + parentNode = parentNode.parentNode; } + // This is always the top container which is now hardcoded to body + this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": parentNode.nodeName}); } }, -- cgit v1.2.3