aboutsummaryrefslogtreecommitdiff
path: root/js/panels/css-panel/declaration.reel
diff options
context:
space:
mode:
authorEric Guzman2012-04-26 03:15:49 -0700
committerEric Guzman2012-04-26 03:15:49 -0700
commit143105a0b9c7765898b22d53489b4bd8df3dff2e (patch)
tree05c6cd14d6400dc2393ebc4465ac3c31c42feb47 /js/panels/css-panel/declaration.reel
parentf1d4c48cd12d4c1a4a8b8d7ce648ea510607cb88 (diff)
downloadninja-143105a0b9c7765898b22d53489b4bd8df3dff2e.tar.gz
CSS Panel - add handlers for css panel actions
Diffstat (limited to 'js/panels/css-panel/declaration.reel')
-rw-r--r--js/panels/css-panel/declaration.reel/declaration.html7
-rw-r--r--js/panels/css-panel/declaration.reel/declaration.js10
2 files changed, 13 insertions, 4 deletions
diff --git a/js/panels/css-panel/declaration.reel/declaration.html b/js/panels/css-panel/declaration.reel/declaration.html
index 79865fed..3a513871 100644
--- a/js/panels/css-panel/declaration.reel/declaration.html
+++ b/js/panels/css-panel/declaration.reel/declaration.html
@@ -14,7 +14,8 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot
14 "module" : "js/panels/css-panel/declaration.reel", 14 "module" : "js/panels/css-panel/declaration.reel",
15 "name" : "Declaration", 15 "name" : "Declaration",
16 "properties" : { 16 "properties" : {
17 "element" : {"#" : "container"} 17 "element" : {"#" : "container"},
18 "treeController": {"@": "treeController"}
18 } 19 }
19 }, 20 },
20 "styleShorthand": { 21 "styleShorthand": {
@@ -26,9 +27,7 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot
26 "name": "TreeController", 27 "name": "TreeController",
27 "properties" : { 28 "properties" : {
28 "branchKey" : "properties", 29 "branchKey" : "properties",
29 "labelKey" : "name", 30 "labelKey" : "name"
30
31 "delegate": {"@": "owner" }
32 }, 31 },
33 "bindings": { 32 "bindings": {
34 "content": { 33 "content": {
diff --git a/js/panels/css-panel/declaration.reel/declaration.js b/js/panels/css-panel/declaration.reel/declaration.js
index 55fe0e18..9685510b 100644
--- a/js/panels/css-panel/declaration.reel/declaration.js
+++ b/js/panels/css-panel/declaration.reel/declaration.js
@@ -9,12 +9,16 @@ var Montage = require("montage/core/core").Montage,
9 ShorthandProps = require("js/panels/CSSPanel/css-shorthand-map"); 9 ShorthandProps = require("js/panels/CSSPanel/css-shorthand-map");
10 10
11exports.Declaration = Montage.create(Component, { 11exports.Declaration = Montage.create(Component, {
12 focusDelegate : {
13 value: null
14 },
12 includeEmptyStyle : { 15 includeEmptyStyle : {
13 value: true 16 value: true
14 }, 17 },
15 templateDidLoad : { 18 templateDidLoad : {
16 value: function() { 19 value: function() {
17 console.log("declaration - template did load"); 20 console.log("declaration - template did load");
21 this.treeController.delegate = this.focusDelegate || this;
18 } 22 }
19 }, 23 },
20 prepareForDraw : { 24 prepareForDraw : {
@@ -115,6 +119,12 @@ exports.Declaration = Montage.create(Component, {
115 distinct: true 119 distinct: true
116 }, 120 },
117 121
122 addNewStyle : {
123 value: function() {
124 debugger;
125 }
126 },
127
118 /* drag/drop events */ 128 /* drag/drop events */
119 handleDrop : { 129 handleDrop : {
120 value: function(e) { 130 value: function(e) {