// Path: api/src/main/java/de/tesis/dynaware/grapheditor/EditorElement.java
// public enum EditorElement
// {
//     CONNECTOR,
//     NODE,
//     JOINT;
// }


import de.tesis.dynaware.grapheditor.EditorElement;
import javafx.geometry.Point2D;
import javafx.scene.Cursor;
import javafx.scene.input.MouseEvent;
import javafx.scene.layout.Region;
/*
 * Copyright (C) 2005 - 2014 by TESIS DYNAware GmbH
 */
package de.tesis.dynaware.grapheditor.utils;


/**
 * A draggable, resizable box that can display children.
 *
 * <p>
 * See {@link DraggableBox} for more information.
 * </p>
 */
public class ResizableBox extends DraggableBox
{

    private static final int DEFAULT_RESIZE_BORDER_TOLERANCE = 8;

    private double lastWidth;
    private double lastHeight;

    private RectangleMouseRegion lastMouseRegion;

    private boolean mouseInPositionForResize;

    /**
     * Creates an empty resizable box.
     *
     * @param pType
     *         {@link EditorElement}
     */
// Path: api/src/main/java/de/tesis/dynaware/grapheditor/EditorElement.java
// public enum EditorElement
// {
//     CONNECTOR,
//     NODE,
//     JOINT;
// }


// Path: api/src/main/java/de/tesis/dynaware/grapheditor/utils/ResizableBox.java
import de.tesis.dynaware.grapheditor.EditorElement;
import javafx.geometry.Point2D;
import javafx.scene.Cursor;
import javafx.scene.input.MouseEvent;
import javafx.scene.layout.Region;

/*
 * Copyright (C) 2005 - 2014 by TESIS DYNAware GmbH
 */
package de.tesis.dynaware.grapheditor.utils;


/**
 * A draggable, resizable box that can display children.
 *
 * <p>
 * See {@link DraggableBox} for more information.
 * </p>
 */
public class ResizableBox extends DraggableBox
{

    private static final int DEFAULT_RESIZE_BORDER_TOLERANCE = 8;

    private double lastWidth;
    private double lastHeight;

    private RectangleMouseRegion lastMouseRegion;

    private boolean mouseInPositionForResize;

    /**
     * Creates an empty resizable box.
     *
     * @param pType
     *         {@link EditorElement}
     */
    public ResizableBox(final EditorElement pType)