diff --git a/src/plugins/resourceeditor/resourceeditorw.cpp b/src/plugins/resourceeditor/resourceeditorw.cpp index b5941722971..cb4bd0c867c 100644 --- a/src/plugins/resourceeditor/resourceeditorw.cpp +++ b/src/plugins/resourceeditor/resourceeditorw.cpp @@ -315,8 +315,7 @@ void ResourceEditorW::openFile(const QString &fileName) void ResourceEditorW::onRefresh() { - if (!m_resourceEditor.isNull()) - m_resourceEditor.data()->refresh(); + m_resourceEditor->refresh(); } void ResourceEditorW::renameCurrentFile() @@ -326,14 +325,12 @@ void ResourceEditorW::renameCurrentFile() void ResourceEditorW::onUndo() { - if (!m_resourceEditor.isNull()) - m_resourceEditor.data()->onUndo(); + m_resourceEditor->onUndo(); } void ResourceEditorW::onRedo() { - if (!m_resourceEditor.isNull()) - m_resourceEditor.data()->onRedo(); + m_resourceEditor->onRedo(); } } // namespace Internal diff --git a/src/plugins/resourceeditor/resourceeditorw.h b/src/plugins/resourceeditor/resourceeditorw.h index 38b47b76dd8..1342d09fc30 100644 --- a/src/plugins/resourceeditor/resourceeditorw.h +++ b/src/plugins/resourceeditor/resourceeditorw.h @@ -34,8 +34,6 @@ #include #include -#include - QT_BEGIN_NAMESPACE class QMenu; class QToolBar; @@ -113,7 +111,7 @@ private: const QString m_fileFilter; QString m_displayName; QString m_suggestedName; - QPointer m_resourceEditor; + QrcEditor *m_resourceEditor; ResourceEditorDocument *m_resourceDocument; ResourceEditorPlugin *m_plugin; bool m_shouldAutoSave;