From e145523a2ae686dd2a2ae7996639e6e8d14d992a Mon Sep 17 00:00:00 2001 From: Eduardo Pedroni Date: Fri, 10 Oct 2014 13:22:16 +0200 Subject: Moved constants to a separate file, added a formal README --- src/jcgp/gui/dragresize/HorizontalDragResize.java | 4 ++-- src/jcgp/gui/dragresize/VerticalDragResize.java | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src/jcgp/gui/dragresize') diff --git a/src/jcgp/gui/dragresize/HorizontalDragResize.java b/src/jcgp/gui/dragresize/HorizontalDragResize.java index b618b74..e88eafd 100644 --- a/src/jcgp/gui/dragresize/HorizontalDragResize.java +++ b/src/jcgp/gui/dragresize/HorizontalDragResize.java @@ -4,7 +4,7 @@ import javafx.event.EventHandler; import javafx.scene.Cursor; import javafx.scene.input.MouseEvent; import javafx.scene.layout.Region; -import jcgp.gui.GUI; +import jcgp.gui.constants.Constants; /** * This class adds horizontal drag resize functionality to any @@ -125,7 +125,7 @@ public class HorizontalDragResize { * @return true if the mouse position is in the draggable area. */ private boolean isInDraggableZone(MouseEvent event) { - return event.getX() < (GUI.RESIZE_MARGIN); + return event.getX() < (Constants.RESIZE_MARGIN); } } diff --git a/src/jcgp/gui/dragresize/VerticalDragResize.java b/src/jcgp/gui/dragresize/VerticalDragResize.java index 06186c6..4f784e5 100644 --- a/src/jcgp/gui/dragresize/VerticalDragResize.java +++ b/src/jcgp/gui/dragresize/VerticalDragResize.java @@ -4,7 +4,7 @@ import javafx.event.EventHandler; import javafx.scene.Cursor; import javafx.scene.input.MouseEvent; import javafx.scene.layout.Region; -import jcgp.gui.GUI; +import jcgp.gui.constants.Constants; /** * This class adds vertical drag resize functionality to any @@ -126,7 +126,7 @@ public class VerticalDragResize { * @return true if the mouse position is in the draggable area. */ private boolean isInDraggableZone(MouseEvent event) { - return event.getY() < (GUI.RESIZE_MARGIN); + return event.getY() < (Constants.RESIZE_MARGIN); } } -- cgit v1.2.3