Class LayoutEditorDashboard
- java.lang.Object
-
- com.vaadin.flow.component.Component
-
- com.vaadin.flow.component.orderedlayout.VerticalLayout
-
- org.neotropic.kuwaiba.modules.optional.layouteditor.widgets.LayoutEditorDashboard
-
- All Implemented Interfaces:
com.vaadin.flow.component.AttachNotifier
,com.vaadin.flow.component.ClickNotifier<com.vaadin.flow.component.orderedlayout.VerticalLayout>
,com.vaadin.flow.component.DetachNotifier
,com.vaadin.flow.component.HasComponents
,com.vaadin.flow.component.HasElement
,com.vaadin.flow.component.HasEnabled
,com.vaadin.flow.component.HasOrderedComponents<com.vaadin.flow.component.orderedlayout.VerticalLayout>
,com.vaadin.flow.component.HasSize
,com.vaadin.flow.component.HasStyle
,com.vaadin.flow.component.orderedlayout.FlexComponent<com.vaadin.flow.component.orderedlayout.VerticalLayout>
,com.vaadin.flow.component.orderedlayout.ThemableLayout
,Serializable
,PropertySheet.IPropertyValueChangedListener
public class LayoutEditorDashboard extends com.vaadin.flow.component.orderedlayout.VerticalLayout implements PropertySheet.IPropertyValueChangedListener
Layout editor Main Dashboard.- Author:
- Orlando Paz <Orlando.Paz@kuwaiba.org>
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
CLASS_CUSTOM
static double
DEFAULT_SHAPE_HEIGHT
static double
DEFAULT_SHAPE_WIDTH
static String
INNER_SHAPE
static String
NODE_GUIDE
static String
PROPERTY_BORDER_COLOR
static String
PROPERTY_BORDER_WIDTH
static String
PROPERTY_COLOR
static String
PROPERTY_ELLIPSE_COLOR
static String
PROPERTY_HEIGHT
static String
PROPERTY_INTERIOR_COLOR
static String
PROPERTY_IS_EQUIPMENT
static String
PROPERTY_IS_SLOT
static String
PROPERTY_NAME
static String
PROPERTY_NUM_OF_SIDES
static String
PROPERTY_OPAQUE
static String
PROPERTY_OUTLINE_COLOR
static String
PROPERTY_OVAL_COLOR
static String
PROPERTY_TYPE
static String
PROPERTY_WIDTH
static String
PROPERTY_X
static String
PROPERTY_Y
static String
SHAPE_CUSTOM
static String
SHAPE_ELLIPSE
static String
SHAPE_LABEL
static String
SHAPE_POLYGON
static String
SHAPE_RECTANGLE
static int
UNIT_HEIGHT
static int
UNIT_WIDTH
-
Constructor Summary
Constructors Constructor Description LayoutEditorDashboard(TranslationService ts, MetadataEntityManager mem, ApplicationEntityManager aem, BusinessEntityManager bem, ResourceFactory resourceFactory, DeleteLayoutViewVisualAction deleteLayoutViewVisualAction, NewLayoutViewVisualAction newLayoutViewVisualAction, LoggingService log)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addNode(BusinessObjectLight businessObject, Properties properties)
byte[]
getAsXML(boolean export)
ViewObject
getCurrentView()
com.neotropic.flow.component.mxgraph.Rectangle
getLayoutBounds(List<com.neotropic.flow.component.mxgraph.MxGraphNode> children)
void
loadCustomShapes()
void
loadLayouts()
protected void
onAttach(com.vaadin.flow.component.AttachEvent attachEvent)
void
onDetach(com.vaadin.flow.component.DetachEvent ev)
void
resetDashboard()
resets the layout view instance and creates a empty onestatic void
setButtonTitle(com.vaadin.flow.component.button.Button button, String title)
Set the title/tool tip for the given buttonvoid
showActionCompledMessages(ActionCompletedListener.ActionCompletedEvent ev)
void
updatePropertyChanged(AbstractProperty property)
-
Methods inherited from class com.vaadin.flow.component.orderedlayout.VerticalLayout
addAndExpand, getAlignItems, getAlignSelf, getDefaultHorizontalComponentAlignment, getHorizontalComponentAlignment, setAlignItems, setAlignSelf, setDefaultHorizontalComponentAlignment, setHorizontalComponentAlignment, setPadding, setSpacing
-
Methods inherited from class com.vaadin.flow.component.Component
addListener, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getLocale, getParent, getTranslation, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onEnabledStateChanged, set, setElement, setId, setVisible
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.vaadin.flow.component.ClickNotifier
addClickListener, addClickShortcut
-
Methods inherited from interface com.vaadin.flow.component.orderedlayout.FlexComponent
expand, getFlexGrow, getJustifyContentMode, replace, setFlexGrow, setJustifyContentMode
-
Methods inherited from interface com.vaadin.flow.component.HasComponents
add, add, addComponentAsFirst, addComponentAtIndex, remove, removeAll
-
Methods inherited from interface com.vaadin.flow.component.HasOrderedComponents
getChildren, getComponentAt, getComponentCount, indexOf
-
Methods inherited from interface com.vaadin.flow.component.HasSize
getHeight, getHeightUnit, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getWidth, getWidthUnit, setHeight, setHeight, setHeightFull, setMaxHeight, setMaxHeight, setMaxWidth, setMaxWidth, setMinHeight, setMinHeight, setMinWidth, setMinWidth, setSizeFull, setSizeUndefined, setWidth, setWidth, setWidthFull
-
-
-
-
Field Detail
-
PROPERTY_TYPE
public static String PROPERTY_TYPE
-
PROPERTY_NAME
public static String PROPERTY_NAME
-
PROPERTY_X
public static String PROPERTY_X
-
PROPERTY_Y
public static String PROPERTY_Y
-
PROPERTY_WIDTH
public static String PROPERTY_WIDTH
-
PROPERTY_HEIGHT
public static String PROPERTY_HEIGHT
-
PROPERTY_COLOR
public static String PROPERTY_COLOR
-
PROPERTY_BORDER_WIDTH
public static String PROPERTY_BORDER_WIDTH
-
PROPERTY_BORDER_COLOR
public static String PROPERTY_BORDER_COLOR
-
PROPERTY_IS_EQUIPMENT
public static String PROPERTY_IS_EQUIPMENT
-
PROPERTY_OPAQUE
public static String PROPERTY_OPAQUE
-
SHAPE_CUSTOM
public static String SHAPE_CUSTOM
-
SHAPE_RECTANGLE
public static String SHAPE_RECTANGLE
-
SHAPE_POLYGON
public static String SHAPE_POLYGON
-
SHAPE_ELLIPSE
public static String SHAPE_ELLIPSE
-
SHAPE_LABEL
public static String SHAPE_LABEL
-
PROPERTY_IS_SLOT
public static final String PROPERTY_IS_SLOT
- See Also:
- Constant Field Values
-
PROPERTY_ELLIPSE_COLOR
public static String PROPERTY_ELLIPSE_COLOR
-
PROPERTY_OVAL_COLOR
public static String PROPERTY_OVAL_COLOR
-
PROPERTY_NUM_OF_SIDES
public static String PROPERTY_NUM_OF_SIDES
-
PROPERTY_OUTLINE_COLOR
public static String PROPERTY_OUTLINE_COLOR
-
PROPERTY_INTERIOR_COLOR
public static String PROPERTY_INTERIOR_COLOR
-
UNIT_WIDTH
public static final int UNIT_WIDTH
- See Also:
- Constant Field Values
-
UNIT_HEIGHT
public static final int UNIT_HEIGHT
- See Also:
- Constant Field Values
-
NODE_GUIDE
public static String NODE_GUIDE
-
CLASS_CUSTOM
public static String CLASS_CUSTOM
-
INNER_SHAPE
public static String INNER_SHAPE
-
DEFAULT_SHAPE_WIDTH
public static double DEFAULT_SHAPE_WIDTH
-
DEFAULT_SHAPE_HEIGHT
public static double DEFAULT_SHAPE_HEIGHT
-
-
Constructor Detail
-
LayoutEditorDashboard
public LayoutEditorDashboard(TranslationService ts, MetadataEntityManager mem, ApplicationEntityManager aem, BusinessEntityManager bem, ResourceFactory resourceFactory, DeleteLayoutViewVisualAction deleteLayoutViewVisualAction, NewLayoutViewVisualAction newLayoutViewVisualAction, LoggingService log)
-
-
Method Detail
-
getCurrentView
public ViewObject getCurrentView()
-
onAttach
protected void onAttach(com.vaadin.flow.component.AttachEvent attachEvent)
- Overrides:
onAttach
in classcom.vaadin.flow.component.Component
-
onDetach
public void onDetach(com.vaadin.flow.component.DetachEvent ev)
- Overrides:
onDetach
in classcom.vaadin.flow.component.Component
-
showActionCompledMessages
public void showActionCompledMessages(ActionCompletedListener.ActionCompletedEvent ev)
-
resetDashboard
public void resetDashboard()
resets the layout view instance and creates a empty one
-
loadLayouts
public void loadLayouts()
-
loadCustomShapes
public void loadCustomShapes()
-
updatePropertyChanged
public void updatePropertyChanged(AbstractProperty property)
- Specified by:
updatePropertyChanged
in interfacePropertySheet.IPropertyValueChangedListener
-
addNode
public void addNode(BusinessObjectLight businessObject, Properties properties)
-
setButtonTitle
public static void setButtonTitle(com.vaadin.flow.component.button.Button button, String title)
Set the title/tool tip for the given button- Parameters:
button
- the button to be settitle
- the title to be added
-
getAsXML
public byte[] getAsXML(boolean export)
-
getLayoutBounds
public com.neotropic.flow.component.mxgraph.Rectangle getLayoutBounds(List<com.neotropic.flow.component.mxgraph.MxGraphNode> children)
-
-