edu.rice.cs.drjava.ui
Class MainFrame.DJFileDisplayManager
java.lang.Object
edu.rice.cs.util.swing.DefaultFileDisplayManager
edu.rice.cs.drjava.ui.MainFrame.DJFileDisplayManager
- All Implemented Interfaces:
- DisplayManager<File>, FileDisplayManager
- Enclosing class:
- MainFrame
private static class MainFrame.DJFileDisplayManager
- extends DefaultFileDisplayManager
This manager is meant to retrieve the correct icons for the given filename. The only files recognized
are the files obviously listed below in the function (.java, .dj0, .dj1, .dj2, .dj). The icons that represent
each filetype are given into the managers constructor upon instantiation. This class is static since
it currently does not depend of the main frame for information.
|
Method Summary |
Icon |
getIcon(File f)
This method chooses the custom icon only for the known filetypes. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_java
private final Icon _java
_dj0
private final Icon _dj0
_dj1
private final Icon _dj1
_dj2
private final Icon _dj2
_dj
private final Icon _dj
_other
private final Icon _other
MainFrame.DJFileDisplayManager
public MainFrame.DJFileDisplayManager(Icon java,
Icon dj0,
Icon dj1,
Icon dj2,
Icon dj,
Icon other)
getIcon
public Icon getIcon(File f)
- This method chooses the custom icon only for the known filetypes. If these filetypes are not receiving
the correct icons, make sure the filenames are correct and that the icons are present in the ui/icons
directory.
- Specified by:
getIcon in interface DisplayManager<File>- Overrides:
getIcon in class DefaultFileDisplayManager
- Parameters:
f - The file to base the icon decision on
- Returns:
- The icon to display for the given file