aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/resourceeditor
diff options
context:
space:
mode:
authorhjk <hjk121@nokiamail.com>2013-09-12 16:06:33 +0200
committerhjk <hjk121@nokiamail.com>2013-09-13 14:06:16 +0200
commit65cc8ae4c28d794dfba2675af434cf790db290f5 (patch)
tree0b31d6895f01167eb5d66678bc6abd30e31003c5 /src/plugins/resourceeditor
parent3bb7339fd4d7887231db4dc0504c79c1f1594cd3 (diff)
Core: Clean up FileIconProvider interface
Change-Id: I98c3c8796cb887f5bb3c5184854562ff36727836 Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
Diffstat (limited to 'src/plugins/resourceeditor')
-rw-r--r--src/plugins/resourceeditor/qrceditor/resourcefile.cpp2
-rw-r--r--src/plugins/resourceeditor/resourceeditorfactory.cpp4
2 files changed, 2 insertions, 4 deletions
diff --git a/src/plugins/resourceeditor/qrceditor/resourcefile.cpp b/src/plugins/resourceeditor/qrceditor/resourcefile.cpp
index 8a997ff0f0..781242124a 100644
--- a/src/plugins/resourceeditor/qrceditor/resourcefile.cpp
+++ b/src/plugins/resourceeditor/qrceditor/resourcefile.cpp
@@ -760,7 +760,7 @@ QVariant ResourceModel::data(const QModelIndex &index, int role) const
if (iconFileExtension(path))
file->icon = QIcon(path);
else
- file->icon = Core::FileIconProvider::instance()->icon(QFileInfo(path));
+ file->icon = Core::FileIconProvider::icon(path);
}
if (!file->icon.isNull())
result = file->icon;
diff --git a/src/plugins/resourceeditor/resourceeditorfactory.cpp b/src/plugins/resourceeditor/resourceeditorfactory.cpp
index 120c342800..e4dae1909e 100644
--- a/src/plugins/resourceeditor/resourceeditorfactory.cpp
+++ b/src/plugins/resourceeditor/resourceeditorfactory.cpp
@@ -50,9 +50,7 @@ ResourceEditorFactory::ResourceEditorFactory(ResourceEditorPlugin *plugin) :
setMimeTypes(QStringList(QLatin1String(C_RESOURCE_MIMETYPE)));
setDisplayName(qApp->translate("OpenWith::Editors", C_RESOURCEEDITOR_DISPLAY_NAME));
- Core::FileIconProvider *iconProvider = Core::FileIconProvider::instance();
- iconProvider->registerIconOverlayForSuffix(QIcon(QLatin1String(":/resourceeditor/images/qt_qrc.png")),
- QLatin1String("qrc"));
+ Core::FileIconProvider::registerIconOverlayForSuffix(":/resourceeditor/images/qt_qrc.png", "qrc");
}
Core::IEditor *ResourceEditorFactory::createEditor(QWidget *parent)