From 7a9536c1239a3a3f15a47715d0bc455dce49a510 Mon Sep 17 00:00:00 2001 From: hjk <qtc-committer@nokia.com> Date: Mon, 9 Mar 2009 12:41:34 +0100 Subject: [PATCH] Fixes: core: remove ViewManagerInterface Details: was a needless layer --- src/plugins/coreplugin/coreplugin.pro | 1 - src/plugins/coreplugin/viewmanager.cpp | 4 +- src/plugins/coreplugin/viewmanager.h | 7 +-- src/plugins/coreplugin/viewmanagerinterface.h | 61 ------------------- 4 files changed, 4 insertions(+), 69 deletions(-) delete mode 100644 src/plugins/coreplugin/viewmanagerinterface.h diff --git a/src/plugins/coreplugin/coreplugin.pro b/src/plugins/coreplugin/coreplugin.pro index e24e129d141..c3606c1f1bd 100644 --- a/src/plugins/coreplugin/coreplugin.pro +++ b/src/plugins/coreplugin/coreplugin.pro @@ -123,7 +123,6 @@ HEADERS += mainwindow.h \ iversioncontrol.h \ iview.h \ ifilewizardextension.h \ - viewmanagerinterface.h \ icorelistener.h \ versiondialog.h \ scriptmanager/metatypedeclarations.h \ diff --git a/src/plugins/coreplugin/viewmanager.cpp b/src/plugins/coreplugin/viewmanager.cpp index 5306ed27669..23fa49a4393 100644 --- a/src/plugins/coreplugin/viewmanager.cpp +++ b/src/plugins/coreplugin/viewmanager.cpp @@ -47,8 +47,8 @@ using namespace Core; using namespace Core::Internal; -ViewManager::ViewManager(MainWindow *mainWnd) : - ViewManagerInterface(mainWnd), +ViewManager::ViewManager(MainWindow *mainWnd) + : QObject(mainWnd), m_mainWnd(mainWnd) { for (int i = 0; i < 3; ++i) { diff --git a/src/plugins/coreplugin/viewmanager.h b/src/plugins/coreplugin/viewmanager.h index 7f527e279a9..80caa083288 100644 --- a/src/plugins/coreplugin/viewmanager.h +++ b/src/plugins/coreplugin/viewmanager.h @@ -30,8 +30,6 @@ #ifndef VIEWMANAGER_H #define VIEWMANAGER_H -#include "viewmanagerinterface.h" - #include <QtCore/QMap> #include <QtGui/QWidget> @@ -45,15 +43,14 @@ QT_END_NAMESPACE namespace Core { -class UniqueIDManager; +class IView; namespace Internal { class MainWindow; class NavigationWidget; -class ViewManager - : public Core::ViewManagerInterface +class ViewManager : public QObject { Q_OBJECT diff --git a/src/plugins/coreplugin/viewmanagerinterface.h b/src/plugins/coreplugin/viewmanagerinterface.h deleted file mode 100644 index 75acd6be57e..00000000000 --- a/src/plugins/coreplugin/viewmanagerinterface.h +++ /dev/null @@ -1,61 +0,0 @@ -/************************************************************************** -** -** This file is part of Qt Creator -** -** Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -** -** Contact: Qt Software Information (qt-info@nokia.com) -** -** Commercial Usage -** -** Licensees holding valid Qt Commercial licenses may use this file in -** accordance with the Qt Commercial License Agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and Nokia. -** -** GNU Lesser General Public License Usage -** -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 2.1 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPL included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 2.1 requirements -** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** If you are unsure which license is appropriate for your use, please -** contact the sales department at qt-sales@nokia.com. -** -**************************************************************************/ - -#ifndef VIEWMANAGERINTERFACE_H -#define VIEWMANAGERINTERFACE_H - -#include <coreplugin/core_global.h> -#include <QtCore/QObject> -#include <QtGui/QKeySequence> - -QT_BEGIN_NAMESPACE -class QIcon; -class QString; -QT_END_NAMESPACE - -namespace Core { - -class IView; - -class CORE_EXPORT ViewManagerInterface - : public QObject -{ - Q_OBJECT - -public: - ViewManagerInterface(QObject *parent = 0) : QObject(parent) { } - virtual ~ViewManagerInterface() { } - - // returns the view @p id - virtual IView * view(const QString & id) = 0; -}; - -} // namespace Core - -#endif // VIEWMANAGERINTERFACE_H -- GitLab