Class IconsFileViewPanel

java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.pushingpixels.flamingo.api.common.JCommandButtonPanel
org.pushingpixels.flamingo.api.common.AbstractFileViewPanel<File>
be.gaudry.swing.file.navigator.fileview.IconsFileViewPanel
All Implemented Interfaces:
IFileView, DragGestureListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible, Scrollable

public class IconsFileViewPanel extends org.pushingpixels.flamingo.api.common.AbstractFileViewPanel<File> implements IFileView, DragGestureListener
Panel that hosts image-based buttons with file icons.
Since:
1.0 Sep 15, 2009
Author:
Steph GAUDRY
See Also:
Serialized Form
  • Field Details

    • bar

      protected BrolCrumbBar bar
    • actions

      final Collection<FileDesktopAction> actions
    • iconMapping

      protected static Map<String,​org.pushingpixels.flamingo.api.common.icon.ResizableIcon> iconMapping
    • defaultIcon

      protected static org.pushingpixels.flamingo.api.common.icon.ResizableIcon defaultIcon
    • useNativeIcons

      protected boolean useNativeIcons
  • Constructor Details

    • IconsFileViewPanel

      public IconsFileViewPanel()
      Creates a new panel. Default constructor only for the GUI Editor.
    • IconsFileViewPanel

      public IconsFileViewPanel(BrolCrumbBar bar, int startingDimension, org.pushingpixels.flamingo.api.common.ProgressListener progressListener)
      Creates a new panel.
      Parameters:
      bar - The breadcrumb bar that is used to browse local or remote repository of image files.
      startingDimension - Initial dimension for image icons.
      progressListener - Progress listener to report back on loaded SVG images.
    • IconsFileViewPanel

      public IconsFileViewPanel(BrolCrumbBar bar, org.pushingpixels.flamingo.api.common.CommandButtonDisplayState startingState, org.pushingpixels.flamingo.api.common.ProgressListener progressListener)
      Creates a new panel.
      Parameters:
      bar - The breadcrumb bar that is used to browse local or remote repository of image files.
      startingState - Initial state for image icons.
      progressListener - Progress listener to report back on loaded SVG images.
  • Method Details

    • dragGestureRecognized

      public void dragGestureRecognized(DragGestureEvent dge)
      Specified by:
      dragGestureRecognized in interface DragGestureListener
    • getSelectedFileObservable

      public SelectedFileObservable getSelectedFileObservable()
      Returns:
      the selectedFile Observable object
    • setUseNativeIcons

      public void setUseNativeIcons(boolean useNativeIcons)
    • toShowFile

      protected boolean toShowFile(org.pushingpixels.flamingo.api.common.StringValuePair<File> pair)
      Specified by:
      toShowFile in class org.pushingpixels.flamingo.api.common.AbstractFileViewPanel<File>
    • setFolder

      public void setFolder(List<org.pushingpixels.flamingo.api.common.StringValuePair<File>> files)
      Specified by:
      setFolder in interface IFileView
      Overrides:
      setFolder in class org.pushingpixels.flamingo.api.common.AbstractFileViewPanel<File>
    • getResizableIcon

      protected org.pushingpixels.flamingo.api.common.icon.ResizableIcon getResizableIcon(org.pushingpixels.flamingo.api.common.AbstractFileViewPanel.Leaf leaf, InputStream stream, org.pushingpixels.flamingo.api.common.CommandButtonDisplayState state, Dimension dimension)
      Specified by:
      getResizableIcon in class org.pushingpixels.flamingo.api.common.AbstractFileViewPanel<File>
    • getPopupMenu

      protected JPopupMenu getPopupMenu()
    • getLeafContent

      protected InputStream getLeafContent(File leaf)
      Specified by:
      getLeafContent in class org.pushingpixels.flamingo.api.common.AbstractFileViewPanel<File>
    • setFile

      public void setFile(File file)
      Specified by:
      setFile in interface IFileView
    • configureCommandButton

      protected void configureCommandButton(org.pushingpixels.flamingo.api.common.AbstractFileViewPanel.Leaf leaf, org.pushingpixels.flamingo.api.common.JCommandButton button, org.pushingpixels.flamingo.api.common.icon.ResizableIcon arg2)
      Specified by:
      configureCommandButton in class org.pushingpixels.flamingo.api.common.AbstractFileViewPanel<File>