com.dlsc.flexgantt.swing.layer.system

## Interface IEditModeController

- All Known Implementing Classes:
    ActivityObjectEditModeController, CapacityObjectEditModeController, DefaultEditModeController

      public interface IEditModeController

  Edit mode controllers are used to fine-tune the editing behaviour of timeline objects. The controller determines what kind of editing operation can be performed on a timeline object based on a mouse move event. The possible editing operations are listed in the enumerator class `IEditModeController.EditMode`. The drag layer retrieves the correct controller based on the object type of the timeline object over which the mouse cursor hovers. Once retrieved the mouse event is sent to the controller, which then needs to reply with one of the values of `IEditModeController.EditMode`. The controller can not only use the location of the mouse event but also the modifiers. This way some editing modes can be more protected when they can only be reached with certain modifiers active.
  Since:
    1.0
  Version:
    $Revision: 1.8 $
  Author:
    Dirk Lemmermann
  See Also:
    `DragLayer.setEditModeController(Class, IEditModeController)`

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface and Description
    --- | ---
    `static class` | `IEditModeController.EditMode` An enumeration of possible editing states that the drag layer can be in.

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `IEditModeController.EditMode` | `getEditMode(DragLayer layer, ObjectBounds bounds, MouseEvent evt)` Returns an edit mode based on the given bounds and mouse event.

- - ### Method Detail

    - #### getEditMode

          IEditModeController.EditMode getEditMode(DragLayer layer,
                                                   ObjectBounds bounds,
                                                   MouseEvent evt)

      Returns an edit mode based on the given bounds and mouse event. The method can evaluate the location and the modifiers of the event in order to determine what kind of editing operation will be supported.
      Parameters:
        `layer` - the drag layer requesting the edit mode
        `bounds` - the object bounds over which the mouse cursor currently hovers
        `evt` - the mouse event that triggered the request
      Returns:
        the edit mode that is appropriate for the given location and key modifiers
      Since:
        1.0

Copyright © 2006–2020 Dirk Lemmermann Software & Consulting. All rights reserved.