aboutsummaryrefslogtreecommitdiff
path: root/js/panels/resize-composer.js
diff options
context:
space:
mode:
authorArmen Kesablyan2012-03-22 14:31:12 -0700
committerArmen Kesablyan2012-03-22 14:31:12 -0700
commit49596f2a6b518ed0ee945006787d3c69e40a5757 (patch)
tree0d8e40b9fe4ca3fc0d12fa5539f02e8ff0eaaa17 /js/panels/resize-composer.js
parent60107392554fa993a16e748f7281be423055cd19 (diff)
downloadninja-49596f2a6b518ed0ee945006787d3c69e40a5757.tar.gz
Updated Resizers for Panels and timeline
Signed-off-by: Armen Kesablyan <armen@motorola.com>
Diffstat (limited to 'js/panels/resize-composer.js')
-rw-r--r--js/panels/resize-composer.js23
1 files changed, 21 insertions, 2 deletions
diff --git a/js/panels/resize-composer.js b/js/panels/resize-composer.js
index 6e5e89f8..450dc7b6 100644
--- a/js/panels/resize-composer.js
+++ b/js/panels/resize-composer.js
@@ -9,6 +9,14 @@ var Composer = require("montage/ui/composer/composer").Composer;
9 9
10exports.ResizeComposer = Montage.create(Composer, { 10exports.ResizeComposer = Montage.create(Composer, {
11 11
12 xAxis: {
13 value: true
14 },
15
16 yAxis: {
17 value: true
18 },
19
12 enabled : { 20 enabled : {
13 enumerable: false, 21 enumerable: false,
14 value: true 22 value: true
@@ -104,8 +112,19 @@ exports.ResizeComposer = Montage.create(Composer, {
104 112
105 captureMousemove: { 113 captureMousemove: {
106 value: function(e) { 114 value: function(e) {
107 this._deltaX = e.clientX - this._startX; 115
108 this._deltaY = e.clientY - this._startY; 116 if (this.xAxis) {
117 this._deltaX = e.clientX - this._startX;
118 }
119 else {
120 this._deltaX = 0;
121 }
122 if (this.yAxis) {
123 this._deltaY = e.clientY - this._startY;
124 }
125 else {
126 this._deltaY = 0;
127 }
109 this._executeEvent("resizeMove"); 128 this._executeEvent("resizeMove");
110 } 129 }
111 }, 130 },