Register C++ header and source file icons by mime type

Makes sure that all files recognized by the CppEditorFactory get the
proper icon.
This commit is contained in:
Thorbjørn Lindeijer
2009-07-15 11:20:24 +02:00
parent c13f83268a
commit 8234858b46
4 changed files with 35 additions and 35 deletions

View File

@@ -40,13 +40,17 @@
namespace Core {
class CORE_EXPORT FileIconProvider {
class MimeType;
class CORE_EXPORT FileIconProvider
{
public:
~FileIconProvider(); // used to clear the cache
QIcon icon(const QFileInfo &fileInfo);
QPixmap overlayIcon(QStyle::StandardPixmap baseIcon, const QIcon &overlayIcon, const QSize &size) const;
void registerIconOverlayForSuffix(const QIcon &icon, const QString &suffix);
void registerIconOverlayForMimeType(const QIcon &icon, const MimeType &mimeType);
static FileIconProvider *instance();