From 54e07ccfdd3c19becbaa0759033260d68e85f643 Mon Sep 17 00:00:00 2001 From: Doubek-Kraft Date: Fri, 23 Jun 2017 13:48:33 -0700 Subject: [PATCH] [Layout] Line endpoint coordinate editing Added appropriate line endpoint coordinate editing input fields --- platform/features/fixed/bundle.js | 8 ++++---- platform/features/layout/src/elements/LineProxy.js | 6 ++++++ 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/platform/features/fixed/bundle.js b/platform/features/fixed/bundle.js index 91cd8dc119..8ae678c5f1 100644 --- a/platform/features/fixed/bundle.js +++ b/platform/features/fixed/bundle.js @@ -162,28 +162,28 @@ define([ "control": "textfield" }, { - "method": "editX1", + "property": "editX1", "text": "X1", "name": "X1", "cssClass": "l-input-sm", "control" : "textfield" }, { - "property": "y1", + "property": "editY1", "text": "Y1", "name": "Y1", "cssClass": "l-input-sm", "control" : "textfield" }, { - "property": "x2", + "property": "editX2", "text": "X2", "name": "X2", "cssClass": "l-input-sm", "control" : "textfield" }, { - "property": "y2", + "property": "editY2", "text": "Y2", "name": "Y2", "cssClass": "l-input-sm", diff --git a/platform/features/layout/src/elements/LineProxy.js b/platform/features/layout/src/elements/LineProxy.js index 9b061db329..849feb0785 100644 --- a/platform/features/layout/src/elements/LineProxy.js +++ b/platform/features/layout/src/elements/LineProxy.js @@ -148,6 +148,12 @@ define( return handles; }; + // Expose endpoint coordinates for editing + proxy.editX1 = new AccessorMutator(element,'x', proxy.checkNumeric); + proxy.editY1 = new AccessorMutator(element,'y', proxy.checkNumeric); + proxy.editX2 = new AccessorMutator(element,'x2', proxy.checkNumeric); + proxy.editY2 = new AccessorMutator(element,'y2', proxy.checkNumeric); + return proxy; }