Class InternalFrameMDIManager


  • public class InternalFrameMDIManager
    extends MDIManager
    An MDI Manager implementation for "childframe" mode (ie using JInternalFrame's).

    Layer management:

    • PEDrawingBoard's are added to JLayeredPane.DEFAULT_LAYER (bottom most layer)
    • DockablePanel's are added to JLayeredPane.PALETTE_LAYER

    Since:
    jPicEdt 1.2
    Version:
    $Id: InternalFrameMDIManager.java,v 1.20.2.1 2007/09/02 11:56:30 reynal Exp $
    Author:
    Sylvain Reynal
    • Field Detail

      • desktopPane

        public javax.swing.JDesktopPane desktopPane
      • KEY_GEOMETRY_WIDTH

        public static final java.lang.String KEY_GEOMETRY_WIDTH
        See Also:
        Constant Field Values
      • KEY_GEOMETRY_HEIGHT

        public static final java.lang.String KEY_GEOMETRY_HEIGHT
        See Also:
        Constant Field Values
      • KEY_DESKTOP_COLOR

        public static final java.lang.String KEY_DESKTOP_COLOR
        See Also:
        Constant Field Values
      • desktopColorDEFAULT

        public static final java.awt.Color desktopColorDEFAULT
    • Constructor Detail

      • InternalFrameMDIManager

        public InternalFrameMDIManager​(PEProgressBar progressBar)
        Parameters:
        progressBar - The progress bar to inform of progress in the initialization ; can be null.
    • Method Detail

      • getName

        public java.lang.String getName()
        Specified by:
        getName in class MDIManager
      • createMDIComponent

        public MDIManager.MDIComponent createMDIComponent​(javax.swing.JPanel pane)
        Factory method that creates an MDIComponent which acts as a UI delegate to the given pane. This implementation returns a properly init'd JInternalFrame, with the given pane added to its content-pane.
        Specified by:
        createMDIComponent in class MDIManager
      • getDesktopSize

        public java.awt.Dimension getDesktopSize()
        Returns the dimension of the desktop that hosts the components of this MDIManager.
        Specified by:
        getDesktopSize in class MDIManager
      • update

        public void update()
        Updates local properties from the JPicEdt's preferences (e.g. GUI colours, rendering-hints,...) This implementation calls the superclass's method, then update the desktop-pane colour.
        Overrides:
        update in class MDIManager
      • updateAccelerators

        public void updateAccelerators()
        Update JMenuItem's accelerators from the key/value pairs stored in JPicEdt's preferences
        Specified by:
        updateAccelerators in class MDIManager
      • updateMenuBar

        public void updateMenuBar()
        Update the content (i.e. PEMenu's) of the menu-bar depending on the current state of the MDIManager.
        Specified by:
        updateMenuBar in class MDIManager
      • updateRecentFilesSubmenu

        public void updateRecentFilesSubmenu()
        Updates the "recent files" sub-menu items after a frame was saved or opened.
        Specified by:
        updateRecentFilesSubmenu in class MDIManager
        Since:
        PicEdt 1.1
      • updateScriptsMenu

        public void updateScriptsMenu()
        Updates the "script" menu items
        Specified by:
        updateScriptsMenu in class MDIManager
        Since:
        jpicedt 1.3.2
      • updateFragmentsMenu

        public void updateFragmentsMenu()
        Updates the "fragments" menu items
        Specified by:
        updateFragmentsMenu in class MDIManager
        Since:
        jpicedt 1.3.2
      • updateUndoRedoMenus

        public void updateUndoRedoMenus​(java.lang.String undoName,
                                        java.lang.String redoName)
        update "undo" and "redo" text
        Specified by:
        updateUndoRedoMenus in class MDIManager
        Since:
        jpicedt 1.3.2
      • updateWindowMenu

        public void updateWindowMenu()
                              throws java.util.MissingResourceException
        Updates the Window menu as soon as an internal frame is opened or closed (this menu keeps tracks of every open internal frames so that the user can activate them quickly by use of a shortcut)
        Specified by:
        updateWindowMenu in class MDIManager
        Throws:
        java.util.MissingResourceException
        Since:
        PicEdt 1.1
      • updateToolkitMenu

        public void updateToolkitMenu​(java.beans.PropertyChangeEvent e)
        update currently "selected" menuitem in Toolkit menu
        Specified by:
        updateToolkitMenu in class MDIManager
      • getMenuItems

        public javax.swing.JMenuItem[] getMenuItems()
        Return an array containing all the menu-items components attached to menubars
        Specified by:
        getMenuItems in class MDIManager
      • getActiveDrawingBoard

        public PEDrawingBoard getActiveDrawingBoard()
        Returns the currently active drawing board ; null if there's no internal frame in the desktopPane.
        If there's at least one internal frame in the desktop, but it's deactivated (this should never happen however), then the policy is to arbitrarly activate one frame (namely the topmost frame on the desktop which is also the last one in the framearray)
        Specified by:
        getActiveDrawingBoard in class MDIManager
      • showModalDialogBox

        public void showModalDialogBox​(java.lang.String title,
                                       javax.swing.JComponent innerPane)
        [pending] experimental ! 1.3.2-beta9 ; not used yet.