diff options
Diffstat (limited to 'js/panels/properties.reel/sections')
-rwxr-xr-x | js/panels/properties.reel/sections/custom.reel/custom.js | 8 | ||||
-rwxr-xr-x | js/panels/properties.reel/sections/position-size.reel/position-size.css (renamed from js/panels/properties.reel/sections/position-and-size.reel/position-and-size.css) | 0 | ||||
-rwxr-xr-x | js/panels/properties.reel/sections/position-size.reel/position-size.html (renamed from js/panels/properties.reel/sections/position-and-size.reel/position-and-size.html) | 36 | ||||
-rwxr-xr-x | js/panels/properties.reel/sections/position-size.reel/position-size.js (renamed from js/panels/properties.reel/sections/position-and-size.reel/position-and-size.js) | 14 |
4 files changed, 30 insertions, 28 deletions
diff --git a/js/panels/properties.reel/sections/custom.reel/custom.js b/js/panels/properties.reel/sections/custom.reel/custom.js index 876fe110..3ab32888 100755 --- a/js/panels/properties.reel/sections/custom.reel/custom.js +++ b/js/panels/properties.reel/sections/custom.reel/custom.js | |||
@@ -19,7 +19,7 @@ var HT = require("js/components/hottext.reel").HotText; | |||
19 | var Dropdown = require("js/components/combobox.reel").Combobox; | 19 | var Dropdown = require("js/components/combobox.reel").Combobox; |
20 | var TextField = require("js/components/textfield.reel").TextField; | 20 | var TextField = require("js/components/textfield.reel").TextField; |
21 | var FileInput = require("js/components/ui/file-input.reel").FileInput; | 21 | var FileInput = require("js/components/ui/file-input.reel").FileInput; |
22 | var Checkbox = require("js/components/checkbox.reel").Checkbox; | 22 | var LabelCheckbox = require("js/components/ui/label-checkbox.reel").LabelCheckbox; |
23 | var ColorChip = require("js/components/ui/color-chip.reel").ColorChip; | 23 | var ColorChip = require("js/components/ui/color-chip.reel").ColorChip; |
24 | var Button = require("montage/ui/button.reel").Button; | 24 | var Button = require("montage/ui/button.reel").Button; |
25 | 25 | ||
@@ -77,7 +77,7 @@ exports.CustomSection = Montage.create(Component, { | |||
77 | this.rows.push(tmpRow); | 77 | this.rows.push(tmpRow); |
78 | 78 | ||
79 | } else if(this._fields[i].length === 3) { | 79 | } else if(this._fields[i].length === 3) { |
80 | 80 | ||
81 | } | 81 | } |
82 | 82 | ||
83 | } | 83 | } |
@@ -103,7 +103,7 @@ exports.CustomSection = Montage.create(Component, { | |||
103 | handleChange: { | 103 | handleChange: { |
104 | value:function(event) { | 104 | value:function(event) { |
105 | if(event._event.wasSetByCode) return; | 105 | if(event._event.wasSetByCode) return; |
106 | 106 | ||
107 | var obj = event.currentTarget; | 107 | var obj = event.currentTarget; |
108 | this._dispatchPropEvent({"type": "change", "id": obj.id, "prop": obj.prop, "value": obj.value, "control": obj}); | 108 | this._dispatchPropEvent({"type": "change", "id": obj.id, "prop": obj.prop, "value": obj.value, "control": obj}); |
109 | } | 109 | } |
@@ -349,7 +349,7 @@ exports.CustomSection = Montage.create(Component, { | |||
349 | value: function(aField) { | 349 | value: function(aField) { |
350 | 350 | ||
351 | // Generate Textfield | 351 | // Generate Textfield |
352 | var obj = Checkbox.create(); | 352 | var obj = LabelCheckbox.create(); |
353 | 353 | ||
354 | // Set Values for TextField | 354 | // Set Values for TextField |
355 | if (aField.id) obj.id = aField.id; | 355 | if (aField.id) obj.id = aField.id; |
diff --git a/js/panels/properties.reel/sections/position-and-size.reel/position-and-size.css b/js/panels/properties.reel/sections/position-size.reel/position-size.css index 7f8fdbc2..7f8fdbc2 100755 --- a/js/panels/properties.reel/sections/position-and-size.reel/position-and-size.css +++ b/js/panels/properties.reel/sections/position-size.reel/position-size.css | |||
diff --git a/js/panels/properties.reel/sections/position-and-size.reel/position-and-size.html b/js/panels/properties.reel/sections/position-size.reel/position-size.html index a7aac84e..5d1a805a 100755 --- a/js/panels/properties.reel/sections/position-and-size.reel/position-and-size.html +++ b/js/panels/properties.reel/sections/position-size.reel/position-size.html | |||
@@ -6,11 +6,11 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot | |||
6 | </copyright> --> | 6 | </copyright> --> |
7 | <html lang="en"> | 7 | <html lang="en"> |
8 | <head> | 8 | <head> |
9 | <link rel="stylesheet" href="position-and-size.css" type="text/css"> | 9 | <link rel="stylesheet" href="position-size.css" type="text/css"> |
10 | <script type="text/montage-serialization"> | 10 | <script type="text/montage-serialization"> |
11 | { | 11 | { |
12 | "owner": { | 12 | "owner": { |
13 | "prototype" : "js/panels/properties.reel/sections/position-and-size.reel[PosSize]", | 13 | "prototype" : "js/panels/properties.reel/sections/position-size.reel", |
14 | "properties" : { | 14 | "properties" : { |
15 | "element" : {"#": "section"}, | 15 | "element" : {"#": "section"}, |
16 | "position": {"#": "position"}, | 16 | "position": {"#": "position"}, |
@@ -23,6 +23,7 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot | |||
23 | "bindButton": {"@": "bindButton"} | 23 | "bindButton": {"@": "bindButton"} |
24 | } | 24 | } |
25 | }, | 25 | }, |
26 | |||
26 | "PosX": { | 27 | "PosX": { |
27 | "prototype": "js/components/hottextunit.reel[HotTextUnit]", | 28 | "prototype": "js/components/hottextunit.reel[HotTextUnit]", |
28 | "properties": { | 29 | "properties": { |
@@ -31,11 +32,7 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot | |||
31 | "minValue": -10000 | 32 | "minValue": -10000 |
32 | }, | 33 | }, |
33 | "bindings": { | 34 | "bindings": { |
34 | "value": { | 35 | "value": {"<<->": "@owner.leftPosition"} |
35 | "boundObject": {"@": "owner"}, | ||
36 | "boundObjectPropertyPath": "leftPosition", | ||
37 | "oneway": false | ||
38 | } | ||
39 | } | 36 | } |
40 | }, | 37 | }, |
41 | "PosY": { | 38 | "PosY": { |
@@ -46,38 +43,31 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot | |||
46 | "minValue": -10000 | 43 | "minValue": -10000 |
47 | }, | 44 | }, |
48 | "bindings": { | 45 | "bindings": { |
49 | "value": { | 46 | "value": {"<<->": "@owner.topPosition"} |
50 | "boundObject": {"@": "owner"}, | ||
51 | "boundObjectPropertyPath": "topPosition", | ||
52 | "oneway": false | ||
53 | } | ||
54 | } | 47 | } |
55 | }, | 48 | }, |
49 | |||
56 | "PosH": { | 50 | "PosH": { |
57 | "prototype": "js/components/hottextunit.reel[HotTextUnit]", | 51 | "prototype": "js/components/hottextunit.reel[HotTextUnit]", |
58 | "properties": { | 52 | "properties": { |
59 | "element": {"#": "PosH"} | 53 | "element": {"#": "PosH"} |
60 | }, | 54 | }, |
61 | "bindings": { | 55 | "bindings": { |
62 | "value": { | 56 | "value": {"<<->": "@owner.heightSize"} |
63 | "boundObject": {"@": "owner"}, | ||
64 | "boundObjectPropertyPath": "heightSize", | ||
65 | "oneway": false | ||
66 | } | ||
67 | } | 57 | } |
68 | }, | 58 | }, |
59 | |||
69 | "PosW": { | 60 | "PosW": { |
70 | "prototype": "js/components/hottextunit.reel[HotTextUnit]", | 61 | "prototype": "js/components/hottextunit.reel[HotTextUnit]", |
71 | "properties": { | 62 | "properties": { |
72 | "element": {"#": "PosW"} | 63 | "element": {"#": "PosW"}, |
64 | "acceptableUnits" : ["px", "%"], | ||
65 | "units": "px" | ||
73 | }, | 66 | }, |
74 | "bindings": { | 67 | "bindings": { |
75 | "value": { | 68 | "value": {"<<->": "@owner.widthSize"} |
76 | "boundObject": {"@": "owner"}, | ||
77 | "boundObjectPropertyPath": "widthSize", | ||
78 | "oneway": false | ||
79 | } | ||
80 | } | 69 | } |
70 | |||
81 | }, | 71 | }, |
82 | "bindButton": { | 72 | "bindButton": { |
83 | "prototype": "montage/ui/toggle-button.reel", | 73 | "prototype": "montage/ui/toggle-button.reel", |
diff --git a/js/panels/properties.reel/sections/position-and-size.reel/position-and-size.js b/js/panels/properties.reel/sections/position-size.reel/position-size.js index 1e47916f..10e084be 100755 --- a/js/panels/properties.reel/sections/position-and-size.reel/position-and-size.js +++ b/js/panels/properties.reel/sections/position-size.reel/position-size.js | |||
@@ -7,7 +7,7 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot | |||
7 | var Montage = require("montage/core/core").Montage; | 7 | var Montage = require("montage/core/core").Montage; |
8 | var Component = require("montage/ui/component").Component; | 8 | var Component = require("montage/ui/component").Component; |
9 | 9 | ||
10 | exports.PosSize = Montage.create(Component, { | 10 | exports.PositionSize = Montage.create(Component, { |
11 | leftPosition: { | 11 | leftPosition: { |
12 | value: 0 | 12 | value: 0 |
13 | }, | 13 | }, |
@@ -23,7 +23,19 @@ exports.PosSize = Montage.create(Component, { | |||
23 | widthSize: { | 23 | widthSize: { |
24 | value: 0 | 24 | value: 0 |
25 | }, | 25 | }, |
26 | /* | ||
27 | widthSize: { | ||
28 | get: function() { return this._widthSize;}, | ||
29 | set: function(value) { | ||
30 | this._widthSize = parseInt(value); | ||
31 | this.widthUnit = value; | ||
32 | } | ||
33 | }, | ||
26 | 34 | ||
35 | widthUnit: { | ||
36 | value: "px" | ||
37 | }, | ||
38 | */ | ||
27 | savedPosition: { | 39 | savedPosition: { |
28 | value: null | 40 | value: null |
29 | }, | 41 | }, |