EditorIconRegistry
Engine/source/gui/worldEditor/editorIconRegistry.h
This class is used to find the correct icon file path for different SimObject class types.
Protected Types
IconMap
Protected Attributes
The default icon returned when no matching icon is found.
Public Functions
findIcon(AbstractClassRep * classRep)
Looks up an icon given an AbstractClassRep.
bool
hasIconNoRecurse(const SimObject * object)
Returns true if an icon is defined this object's class.
loadFromPath(const String & path, bool overwrite)
Loops thru all the AbstractClassReps looking for icons in the path.
Detailed Description
This class is used to find the correct icon file path for different SimObject class types.
It is typically used by the editors.
Protected Types
typedef HashTable< StringNoCase, GFXTexHandle > IconMap
Protected Attributes
GFXTexHandle mDefaultIcon
The default icon returned when no matching icon is found.
IconMap mIcons
Public Functions
EditorIconRegistry()
~EditorIconRegistry()
add(const String & className, const String & imageFile, bool overwrite)
Adds a single icon to the registry.
clear()
Clears all the icons from the registry.
DECLARE_STATIC_CLASS(EditorIconRegistry )
findIcon(AbstractClassRep * classRep)
Looks up an icon given an AbstractClassRep.
Other findIcon methods redirect to this.
findIcon(const char * className)
Looks up an icon given a className.
findIcon(const SimObject * object)
Looks up an icon given a SimObject.
hasIconNoRecurse(const SimObject * object)
Returns true if an icon is defined this object's class.
Does not recurse up the class hierarchy.
loadFromPath(const String & path, bool overwrite)
Loops thru all the AbstractClassReps looking for icons in the path.