Class MultiFrame

java.lang.Object
ucar.unidata.ui.MultiFrame
Direct Known Subclasses:
IdvWindow

public class MultiFrame extends Object
A class that holds either a JFrame or a JInteralFrame. It allows for client code to eqaily switch between regular windows and JDesktop windows
Author:
IDV development team
  • Constructor Details

    • MultiFrame

      public MultiFrame()
      ctor
    • MultiFrame

      public MultiFrame(String title)
      ctor
      Parameters:
      title - Create a JFrame with the given title
    • MultiFrame

      public MultiFrame(JFrame frame)
      ctor
      Parameters:
      frame - The frame
    • MultiFrame

      public MultiFrame(JInternalFrame internalFrame)
      ctor
      Parameters:
      internalFrame - The internal frame
  • Method Details

    • useDesktopPane

      public static void useDesktopPane(JDesktopPane desktopPane)
      Set the global desktopPane. This causes all default MultiFrames to be an internalFrame.
      Parameters:
      desktopPane - desktop pane
    • show

      public void show()
      Show the component
    • dispose

      public void dispose()
      dispose of the component
    • setVisible

      public void setVisible(boolean visible)
      set visibility of the component
      Parameters:
      visible - visible
    • getContentPane

      public Container getContentPane()
      Get the content pane of the component
      Returns:
      content pane
    • getContainer

      public Container getContainer()
      Get the container
      Returns:
      Either the frame or the internalFrame
    • setCursor

      public void setCursor(Cursor cursor)
      Set the cursor
      Parameters:
      cursor - cursor
    • setState

      public void setState(int state)
      wrapper method
      Parameters:
      state - state
    • setTitle

      public void setTitle(String title)
      Set the title
      Parameters:
      title - The title
    • getTitle

      public String getTitle()
      Get the title
      Returns:
      The title
    • getFrame

      public JFrame getFrame()
      access the JFrame
      Returns:
      The frame
    • getInternalFrame

      public JInternalFrame getInternalFrame()
      Access the internal frame
      Returns:
      internal frame
    • getWindow

      public Window getWindow()
      Finds the Window we are a part of
      Returns:
      the window
    • pack

      public void pack()
      wrapper method
    • setDefaultCloseOperation

      public void setDefaultCloseOperation(int operation)
      wrapper method
      Parameters:
      operation - operation
    • addWindowListener

      public void addWindowListener(WindowListener l)
      wrapper method
      Parameters:
      l - listener
    • removeWindowListener

      public void removeWindowListener(WindowListener l)
      wrapper method
      Parameters:
      l - _more_
    • setJMenuBar

      public void setJMenuBar(JMenuBar menuBar)
      wrapper method
      Parameters:
      menuBar - _more_
    • getBounds

      public Rectangle getBounds()
      wrapper method
      Returns:
      _more_
    • setBounds

      public void setBounds(Rectangle bounds)
      wrapper method
      Parameters:
      bounds - _more_
    • setIconImage

      public void setIconImage(Image icon)
      wrapper method
      Parameters:
      icon - _more_
    • toFront

      public void toFront()
      wrapper method
    • getComponent

      public Component getComponent()
      Return the component. Either the frame or the internalFrame
      Returns:
      The component
    • isVisible

      public boolean isVisible()
      wrapper method
      Returns:
      is visible
    • isShowing

      public boolean isShowing()
      wrapper method
      Returns:
      is showing
    • getLocation

      public Point getLocation()
      wrapper method
      Returns:
      location
    • setLocation

      public void setLocation(int x, int y)
      wrapper method
      Parameters:
      x - x
      y - y
    • setSize

      public void setSize(Dimension size)
      wrapper method
      Parameters:
      size - size_
    • getSize

      public Dimension getSize()
      wrapper method
      Returns:
      size
    • getState

      public int getState()
      wrapper method
      Returns:
      state