Package diva.gui

Class ViewEvent

  • All Implemented Interfaces:
    java.io.Serializable

    public class ViewEvent
    extends java.util.EventObject
    A view event is generated when a view of a Document is iconified, selected, closed, and so on.
    Version:
    $Id$
    Author:
    John Reekie, Heloise Hse
    See Also:
    Serialized Form
    Pt.AcceptedRating:
    Red
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int VIEW_CLOSED
      The view closed event type
      static int VIEW_CLOSING
      The view closing event type
      static int VIEW_DESELECTED
      The view deselected event type
      static int VIEW_HIDDEN
      The view hidden event type
      static int VIEW_MOVED
      The view moved event type
      static int VIEW_RESIZED
      The view resized event type
      static int VIEW_SELECTED
      The view selected event type
      static int VIEW_SHOWN
      The view shown event type
      • Fields inherited from class java.util.EventObject

        source
    • Constructor Summary

      Constructors 
      Constructor Description
      ViewEvent​(javax.swing.JComponent view, int id)
      Create a view event with the specified component and type.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int getID()
      Return the event type.
      javax.swing.JComponent getView()
      Return the component/view that the event refers to
      • Methods inherited from class java.util.EventObject

        getSource, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • VIEW_CLOSING

        public static final int VIEW_CLOSING
        The view closing event type
        See Also:
        Constant Field Values
      • VIEW_CLOSED

        public static final int VIEW_CLOSED
        The view closed event type
        See Also:
        Constant Field Values
      • VIEW_DESELECTED

        public static final int VIEW_DESELECTED
        The view deselected event type
        See Also:
        Constant Field Values
      • VIEW_HIDDEN

        public static final int VIEW_HIDDEN
        The view hidden event type
        See Also:
        Constant Field Values
      • VIEW_MOVED

        public static final int VIEW_MOVED
        The view moved event type
        See Also:
        Constant Field Values
      • VIEW_RESIZED

        public static final int VIEW_RESIZED
        The view resized event type
        See Also:
        Constant Field Values
      • VIEW_SELECTED

        public static final int VIEW_SELECTED
        The view selected event type
        See Also:
        Constant Field Values
      • VIEW_SHOWN

        public static final int VIEW_SHOWN
        The view shown event type
        See Also:
        Constant Field Values
    • Constructor Detail

      • ViewEvent

        public ViewEvent​(javax.swing.JComponent view,
                         int id)
        Create a view event with the specified component and type. The component is accessible either with the getSource() method or the more type-specific getView() method.
    • Method Detail

      • getID

        public int getID()
        Return the event type.
      • getView

        public javax.swing.JComponent getView()
        Return the component/view that the event refers to