From f1387bc995766b8d941f93e605a91c49c8931645 Mon Sep 17 00:00:00 2001 From: Kruti Shah Date: Tue, 22 May 2012 10:28:41 -0700 Subject: Layer Control Signed-off-by: Kruti Shah --- js/panels/Timeline/Style.reel/Style.js | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) (limited to 'js/panels/Timeline/Style.reel') diff --git a/js/panels/Timeline/Style.reel/Style.js b/js/panels/Timeline/Style.reel/Style.js index c39f3a56..91abaa71 100644 --- a/js/panels/Timeline/Style.reel/Style.js +++ b/js/panels/Timeline/Style.reel/Style.js @@ -221,7 +221,6 @@ var LayerStyle = exports.LayerStyle = Montage.create(Component, { value: function(event) { // this should be handled via binding, but somehow is not. Setting manually for now. this.editorProperty = this.myHintable.value; - // Change views. this.whichView = "propval"; } @@ -303,6 +302,9 @@ var LayerStyle = exports.LayerStyle = Montage.create(Component, { this.valueEditorHottext.units = tweenable.units; this.valueEditorHottext.minValue = tweenable.min; this.valueEditorHottext.maxValue = tweenable.max; + this.valueEditorHottext.identifier="hottext" + this.valueEditorHottext.addEventListener("change",this,false); + this.valueEditorHottext.addEventListener("changing",this,false); this.valueEditorHottext.needsDraw = true; } else if (tweenable.tweener === "color" ) { this.editorInputContainer.classList.add("hidden"); @@ -612,6 +614,21 @@ var LayerStyle = exports.LayerStyle = Montage.create(Component, { } ] + }, + + handleHottextChange:{ + value:function(){ + debugger; + this.application.ninja.elementMediator.setProperty(this.parentComponent.parentComponent.parentComponent.parentComponent.layerData.elementsList, this.editorProperty, [this.editorValue + "%"] , "Change", "timeline"); + } + }, + + handleHottextChanging:{ + value:function(){ + + debugger; + this.application.ninja.elementMediator.setProperty(this.parentComponent.parentComponent.parentComponent.parentComponent.layerData.elementsList, this.editorProperty, [this.editorValue + "%"] , "Changing", "timeline"); + } }, /* Begin: Logging routines */ -- cgit v1.2.3 From fdc4f5c7f81ae3b9adeca2232e60268b4be594a2 Mon Sep 17 00:00:00 2001 From: Kruti Shah Date: Tue, 22 May 2012 15:32:42 -0700 Subject: Style Layer Control Signed-off-by: Kruti Shah --- js/panels/Timeline/Style.reel/Style.js | 27 ++++++++++++++++++++------- 1 file changed, 20 insertions(+), 7 deletions(-) (limited to 'js/panels/Timeline/Style.reel') diff --git a/js/panels/Timeline/Style.reel/Style.js b/js/panels/Timeline/Style.reel/Style.js index 91abaa71..532982f7 100644 --- a/js/panels/Timeline/Style.reel/Style.js +++ b/js/panels/Timeline/Style.reel/Style.js @@ -316,6 +316,7 @@ var LayerStyle = exports.LayerStyle = Montage.create(Component, { this.editorColorContainer.classList.add("hidden"); this.editorHottextContainer.classList.add("hidden"); this.valueEditorInput.value = this.editorValue; + this.valueEditorInput.addEventListener("blur",this,false); } else { this.log("Warning: unknown tweenable -"+tweenable.tweener+"- specified in style.js.") } @@ -559,7 +560,7 @@ var LayerStyle = exports.LayerStyle = Montage.create(Component, { { "property" : "opacity", "tweener" : "hottext", - "units" : "%", + "units" : "", "min" : 0, "max" : 100, "default" : 100 @@ -617,19 +618,31 @@ var LayerStyle = exports.LayerStyle = Montage.create(Component, { }, handleHottextChange:{ - value:function(){ - debugger; - this.application.ninja.elementMediator.setProperty(this.parentComponent.parentComponent.parentComponent.parentComponent.layerData.elementsList, this.editorProperty, [this.editorValue + "%"] , "Change", "timeline"); + value:function(event){ + + if(this.editorValue===""){ + this.editorValue = 0; + } + this.application.ninja.elementMediator.setProperty(this.parentComponent.parentComponent.parentComponent.parentComponent.layerData.elementsList, this.editorProperty, [this.editorValue + event.target._units] , "Change", "timeline"); } }, handleHottextChanging:{ - value:function(){ + value:function(event){ + + if(this.editorValue===""){ + this.editorValue = 0; + } + this.application.ninja.elementMediator.setProperty(this.parentComponent.parentComponent.parentComponent.parentComponent.layerData.elementsList, this.editorProperty, [this.editorValue + event.target._units ] , "Changing", "timeline"); + } + }, - debugger; - this.application.ninja.elementMediator.setProperty(this.parentComponent.parentComponent.parentComponent.parentComponent.layerData.elementsList, this.editorProperty, [this.editorValue + "%"] , "Changing", "timeline"); + handleBlur:{ + value:function(event){ + this.application.ninja.elementMediator.setProperty(this.parentComponent.parentComponent.parentComponent.parentComponent.layerData.elementsList, this.editorProperty, [event.target.value] , "Change", "timeline"); } }, + /* Begin: Logging routines */ _boolDebug: { -- cgit v1.2.3 From fadf2a5f05c9b3e19caa2f18fc6d4d0e1e4fb02f Mon Sep 17 00:00:00 2001 From: Jon Reid Date: Thu, 24 May 2012 16:06:02 -0700 Subject: Timeline: Bug fix IKNINJA 1566: Adding a css style property makes the blow layer name disappear. --- js/panels/Timeline/Style.reel/css/Style.css | 79 ++++++--------------------- js/panels/Timeline/Style.reel/scss/Style.scss | 3 + 2 files changed, 19 insertions(+), 63 deletions(-) (limited to 'js/panels/Timeline/Style.reel') diff --git a/js/panels/Timeline/Style.reel/css/Style.css b/js/panels/Timeline/Style.reel/css/Style.css index 6c7542cb..0cc8a1f8 100644 --- a/js/panels/Timeline/Style.reel/css/Style.css +++ b/js/panels/Timeline/Style.reel/css/Style.css @@ -1,88 +1,36 @@ -/* Layer.scss - * Main SCSS file for Layer component, compiled by SASS into the file css/Layer.css. - */ /* 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.
*/ -/* - * _colors.scss - * Defines the colors for the UI of the application. - * To create a new theme, copy this file and change the values as desired. - * Note: Some colors are defined as both rgb and rgba; some of the rgba versions have multiple a values. - */ -/* Colors for radio buttons and other form elements */ -/* Base colors for dividers - * - * Dividers consist of a div with a background color and either - * a top & bottom border (in the case of horizontal dividers) - * or a left & right border (in the case of vertical dividers), - * for a total of three different colors. - * - */ -/* top and left */ -/* Middle */ -/* Bottom and right */ -/* Main background color of entire app */ -/* Main app background color. */ -/* rgba version */ -/* Main app border color */ -/* color of drop shadows */ -/* Stage color */ -/* body border color */ -/* Body background color */ -/* Colors for main dropdown menus: background & text for both regular and highlighted states, dividers */ -/* Colors for tools: background, text, how they interact with the UI */ -/* Colors for panels: background & text, both regular and highlighted states, dividers, borders, shadows, etc. */ -/* used for editable items in their non-edit state, etc. */ -/* Border for panel and for block elements */ -/* Shadow for text and block elements */ -/* Colors for scroll bars */ -/* - 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. -
*/ -/* - * themes/themename/mixins.scss - * Mixins that are theme-dependent (e.g. sprite mixins, etc) - */ -/* - 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. -
*/ -/* - * mixins.scss - * Generic mixins. Theme-specific mixins (e.g. for sprites) - * should go in the theme/themename/mixins.scss file. +/* Layer.scss + * Main SCSS file for Layer component, compiled by SASS into the file css/Layer.css. */ -/* line 12, ../scss/Style.scss */ +/* line 18, ../scss/Style.scss */ .hidden { display: none; } -/* line 15, ../scss/Style.scss */ +/* line 21, ../scss/Style.scss */ .row-editor { position: relative; height: 14px; } -/* line 19, ../scss/Style.scss */ +/* line 25, ../scss/Style.scss */ .style-padding { padding-left: 5px; padding-top: 3px; padding-right: 5px; } -/* line 24, ../scss/Style.scss */ +/* line 30, ../scss/Style.scss */ .style-row { height: 20px; border-bottom: 1px solid #505050; } -/* line 29, ../scss/Style.scss */ +/* line 35, ../scss/Style.scss */ div.content-style div.editable2 { height: 14px; background-color: #242424 !important; @@ -96,7 +44,7 @@ div.content-style div.editable2 { width: 100%; } -/* line 43, ../scss/Style.scss */ +/* line 49, ../scss/Style.scss */ .content-style.collapsible-content, .content-style.collapsible-content div, .content-style.collapsible-content span { @@ -104,7 +52,7 @@ div.content-style div.editable2 { text-overflow: visible; } -/* line 48, ../scss/Style.scss */ +/* line 54, ../scss/Style.scss */ div.content-style div.cell-property, div.content-style div.cell-value { width: 45%; @@ -116,7 +64,7 @@ div.content-style div.cell-value { line-height: 18px; } -/* line 57, ../scss/Style.scss */ +/* line 63, ../scss/Style.scss */ div.content-style div.cell-property div { min-width: 90%; height: 100%; @@ -125,9 +73,14 @@ div.content-style div.cell-property div { white-space: nowrap; } -/* line 65, ../scss/Style.scss */ +/* line 71, ../scss/Style.scss */ div.content-style input.nj-skinned { height: 10px; font-size: 12px; top: -3px; } + +/* line 76, ../scss/Style.scss */ +div.style-row .container-propvals { + overflow: hidden; +} diff --git a/js/panels/Timeline/Style.reel/scss/Style.scss b/js/panels/Timeline/Style.reel/scss/Style.scss index 30bf43fe..66028cbe 100644 --- a/js/panels/Timeline/Style.reel/scss/Style.scss +++ b/js/panels/Timeline/Style.reel/scss/Style.scss @@ -73,4 +73,7 @@ div.content-style input.nj-skinned { font-size: 12px; top: -3px; } +div.style-row .container-propvals { + overflow: hidden; +} -- cgit v1.2.3 From 4a8a293ba3fdf934a431152a9351f45092fb3695 Mon Sep 17 00:00:00 2001 From: Jon Reid Date: Fri, 25 May 2012 14:01:45 -0700 Subject: Timeline: bug fix: better selection/deselection of styles within layers. --- js/panels/Timeline/Style.reel/Style.js | 5 +++-- js/panels/Timeline/Style.reel/scss/Style.scss | 4 ++++ 2 files changed, 7 insertions(+), 2 deletions(-) (limited to 'js/panels/Timeline/Style.reel') diff --git a/js/panels/Timeline/Style.reel/Style.js b/js/panels/Timeline/Style.reel/Style.js index c39f3a56..d712f2bd 100644 --- a/js/panels/Timeline/Style.reel/Style.js +++ b/js/panels/Timeline/Style.reel/Style.js @@ -35,6 +35,7 @@ var LayerStyle = exports.LayerStyle = Montage.create(Component, { return this._isSelected; }, set: function(newVal) { + console.log("Style["+this.styleID+"].isSelected.set ", newVal) if (newVal !== this._isSelected) { this._isSelected = newVal; this.needsDraw = true; @@ -191,9 +192,9 @@ var LayerStyle = exports.LayerStyle = Montage.create(Component, { this._showView(); } if (this.isSelected) { - this.element.classList.add("selected"); + this.element.classList.add("style-selected"); } else { - this.element.classList.remove("selected"); + this.element.classList.remove("style-selected"); } } }, diff --git a/js/panels/Timeline/Style.reel/scss/Style.scss b/js/panels/Timeline/Style.reel/scss/Style.scss index 66028cbe..3ea943d8 100644 --- a/js/panels/Timeline/Style.reel/scss/Style.scss +++ b/js/panels/Timeline/Style.reel/scss/Style.scss @@ -77,3 +77,7 @@ div.style-row .container-propvals { overflow: hidden; } +.content-style .style-row.style-selected { + //background-color: red !important; +} + -- cgit v1.2.3 From 82b0c1b8ee197e23fbd5184cbb0522ca76e651c8 Mon Sep 17 00:00:00 2001 From: Kruti Shah Date: Thu, 31 May 2012 14:27:51 -0700 Subject: Color Chip Signed-off-by: Kruti Shah --- js/panels/Timeline/Style.reel/Style.html | 7 +- js/panels/Timeline/Style.reel/Style.js | 662 +++++++++++++++++-------------- 2 files changed, 377 insertions(+), 292 deletions(-) (limited to 'js/panels/Timeline/Style.reel') diff --git a/js/panels/Timeline/Style.reel/Style.html b/js/panels/Timeline/Style.reel/Style.html index 5be159c3..cdc355e7 100644 --- a/js/panels/Timeline/Style.reel/Style.html +++ b/js/panels/Timeline/Style.reel/Style.html @@ -19,7 +19,8 @@ "styleProperty" : {"#": "container-property"}, "valueEditorHottext" : {"@":"hottextunit"}, "dtextProperty" : {"@":"dtext1"}, - "myHintable" : {"@" :"hintable"} + "myHintable" : {"@" :"hintable"}, + "_fillColorCtrl": {"#": "fillColorCtrl"} } }, "dtext1" : { @@ -78,7 +79,9 @@