Package com._1c.g5.v8.dt.erd.ui.handlers
Class DropEntitiesHandler
java.lang.Object
org.eclipse.core.commands.common.EventManager
org.eclipse.core.commands.AbstractHandler
com._1c.g5.v8.dt.erd.ui.handlers.AbstractDiagramHandler
com._1c.g5.v8.dt.erd.ui.handlers.DropEntitiesHandler
- All Implemented Interfaces:
IDropEntitiesHandler,org.eclipse.core.commands.IHandler,org.eclipse.core.commands.IHandler2
Handler for drop entities action. Adds dropped entities to diagram.
If all entities already on diagram, finds and selects first entity in list.
How to use
How to use
- set drop event via
setDropEvent(DropTargetEvent) - execute via
execute(ErdEditor)
-
Nested Class Summary
Nested classes/interfaces inherited from class com._1c.g5.v8.dt.erd.ui.handlers.AbstractDiagramHandler
AbstractDiagramHandler.DiagramBuilder, AbstractDiagramHandler.DiagramRefresher, AbstractDiagramHandler.NotUndoableEvent -
Field Summary
Fields inherited from class com._1c.g5.v8.dt.erd.ui.handlers.AbstractDiagramHandler
bmModelManager, convertersService, extractor, projectManager, resourceLookup -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidExecutes drop action.execute(org.eclipse.core.commands.ExecutionEvent event) protected voidprocessMdObjects(Collection<MdObject> mdObjects, ErdEditor editor) Processes given md objects.voidsetDropEvent(org.eclipse.swt.dnd.DropTargetEvent dropEvent) Sets drop event.Methods inherited from class com._1c.g5.v8.dt.erd.ui.handlers.AbstractDiagramHandler
askForNewTab, convertToMdObjects, fillLiterals, getConfigurationObjects, getConfigurationSubsystems, getController, isProjectSelected, lookForMdObjects, showNoSelectedObjectsMessageMethods inherited from class org.eclipse.core.commands.AbstractHandler
addHandlerListener, dispose, fireHandlerChanged, hasListeners, isEnabled, isHandled, removeHandlerListener, setBaseEnabled, setEnabledMethods inherited from class org.eclipse.core.commands.common.EventManager
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject
-
Constructor Details
-
DropEntitiesHandler
public DropEntitiesHandler()
-
-
Method Details
-
setDropEvent
public void setDropEvent(org.eclipse.swt.dnd.DropTargetEvent dropEvent) Description copied from interface:IDropEntitiesHandlerSets drop event.- Specified by:
setDropEventin interfaceIDropEntitiesHandler- Parameters:
dropEvent- the dropEvent to set. Can't benull.
-
execute
Description copied from interface:IDropEntitiesHandlerExecutes drop action.- Specified by:
executein interfaceIDropEntitiesHandler- Parameters:
editor- - editor to execute action. Can't benull.
-
execute
public Object execute(org.eclipse.core.commands.ExecutionEvent event) throws org.eclipse.core.commands.ExecutionException - Specified by:
executein interfaceorg.eclipse.core.commands.IHandler- Overrides:
executein classAbstractDiagramHandler- Throws:
org.eclipse.core.commands.ExecutionException
-
processMdObjects
Description copied from class:AbstractDiagramHandlerProcesses given md objects. Realization varies.- Specified by:
processMdObjectsin classAbstractDiagramHandler- Parameters:
mdObjects- - objects to process. Can't benull.editor- - context editor. Can't benull.
-