Commit 9097149c authored by con's avatar con
Browse files

ViewManager --> StatusBarManager

parent 4053ac0c
......@@ -32,7 +32,7 @@ SOURCES += mainwindow.cpp \
messageoutputwindow.cpp \
outputpane.cpp \
vcsmanager.cpp \
viewmanager.cpp \
statusbarmanager.cpp \
versiondialog.cpp \
editormanager/editormanager.cpp \
editormanager/editorview.cpp \
......@@ -92,7 +92,7 @@ HEADERS += mainwindow.h \
messageoutputwindow.h \
outputpane.h \
vcsmanager.h \
viewmanager.h \
statusbarmanager.h \
editormanager/editormanager.h \
editormanager/editorview.h \
editormanager/openeditorsmodel.h \
......
......@@ -53,7 +53,7 @@
#include "settingsdialog.h"
#include "variablemanager.h"
#include "versiondialog.h"
#include "viewmanager.h"
#include "statusbarmanager.h"
#include "uniqueidmanager.h"
#include "manhattanstyle.h"
#include "dialogs/iwizard.h"
......@@ -127,7 +127,7 @@ MainWindow::MainWindow() :
m_scriptManager(new ScriptManagerPrivate(this)),
m_variableManager(new VariableManager(this)),
m_vcsManager(new VCSManager),
m_viewManager(0),
m_statusBarManager(0),
m_modeManager(0),
m_mimeDatabase(new MimeDatabase),
m_navigationWidget(0),
......@@ -190,7 +190,7 @@ MainWindow::MainWindow() :
m_modeStack = new FancyTabWidget(this);
m_modeManager = new ModeManager(this, m_modeStack);
m_modeManager->addWidget(m_progressManager->progressView());
m_viewManager = new ViewManager(this);
m_statusBarManager = new StatusBarManager(this);
m_messageManager = new MessageManager;
m_editorManager = new EditorManager(m_coreImpl, this);
m_editorManager->hide();
......@@ -256,7 +256,7 @@ MainWindow::~MainWindow()
pm->removeObject(m_outputMode);
delete m_outputMode;
m_outputMode = 0;
//we need to delete editormanager and viewmanager explicitly before the end of the destructor,
//we need to delete editormanager and statusbarmanager explicitly before the end of the destructor,
//because they might trigger stuff that tries to access data from editorwindow, like removeContextWidget
// All modes are now gone
......@@ -268,8 +268,8 @@ MainWindow::~MainWindow()
delete m_editorManager;
m_editorManager = 0;
delete m_viewManager;
m_viewManager = 0;
delete m_statusBarManager;
m_statusBarManager = 0;
delete m_progressManager;
m_progressManager = 0;
pm->removeObject(m_coreImpl);
......@@ -294,7 +294,7 @@ bool MainWindow::init(QString *errorMessage)
ExtensionSystem::PluginManager *pm = ExtensionSystem::PluginManager::instance();
pm->addObject(m_coreImpl);
m_viewManager->init();
m_statusBarManager->init();
m_modeManager->init();
m_progressManager->init();
QWidget *outputModeWidget = new QWidget;
......@@ -322,7 +322,7 @@ bool MainWindow::init(QString *errorMessage)
pm->addObject(m_shortcutSettings);
// Add widget to the bottom, we create the view here instead of inside the
// OutputPaneManager, since the ViewManager needs to be initilized before
// OutputPaneManager, since the StatusBarManager needs to be initilized before
m_outputView = new Core::StatusBarWidget;
m_outputView->setWidget(OutputPaneManager::instance()->buttonsWidget());
m_outputView->setPosition(Core::StatusBarWidget::Second);
......@@ -344,7 +344,7 @@ void MainWindow::extensionsInitialized()
{
m_editorManager->init();
m_viewManager->extensionsInitalized();
m_statusBarManager->extensionsInitalized();
m_messageManager->init();
OutputPaneManager::instance()->init();
......
......@@ -63,7 +63,6 @@ class SettingsDatabase;
class UniqueIDManager;
class VariableManager;
class VCSManager;
class ViewManagerInterface;
class IMode;
namespace Internal {
......@@ -75,7 +74,7 @@ class GeneralSettings;
class NavigationWidget;
class ProgressManagerPrivate;
class ShortcutSettings;
class ViewManager;
class StatusBarManager;
class VersionDialog;
class CORE_EXPORT MainWindow : public EventFilteringMainWindow
......@@ -189,7 +188,7 @@ private:
ScriptManager *m_scriptManager;
VariableManager *m_variableManager;
VCSManager *m_vcsManager;
ViewManager *m_viewManager;
StatusBarManager *m_statusBarManager;
ModeManager *m_modeManager;
MimeDatabase *m_mimeDatabase;
FancyTabWidget *m_modeStack;
......
......@@ -27,7 +27,7 @@
**
**************************************************************************/
#include "viewmanager.h"
#include "statusbarmanager.h"
#include "coreconstants.h"
#include "mainwindow.h"
......@@ -47,7 +47,7 @@
using namespace Core;
using namespace Core::Internal;
ViewManager::ViewManager(MainWindow *mainWnd)
StatusBarManager::StatusBarManager(MainWindow *mainWnd)
: QObject(mainWnd),
m_mainWnd(mainWnd)
{
......@@ -63,11 +63,11 @@ ViewManager::ViewManager(MainWindow *mainWnd)
new QLabel(), 1);
}
ViewManager::~ViewManager()
StatusBarManager::~StatusBarManager()
{
}
void ViewManager::init()
void StatusBarManager::init()
{
connect(ExtensionSystem::PluginManager::instance(), SIGNAL(objectAdded(QObject*)),
this, SLOT(objectAdded(QObject*)));
......@@ -75,7 +75,7 @@ void ViewManager::init()
this, SLOT(aboutToRemoveObject(QObject*)));
}
void ViewManager::objectAdded(QObject *obj)
void StatusBarManager::objectAdded(QObject *obj)
{
StatusBarWidget *view = Aggregation::query<StatusBarWidget>(obj);
if (!view)
......@@ -88,7 +88,7 @@ void ViewManager::objectAdded(QObject *obj)
m_mainWnd->addContextObject(view);
}
void ViewManager::aboutToRemoveObject(QObject *obj)
void StatusBarManager::aboutToRemoveObject(QObject *obj)
{
StatusBarWidget *view = Aggregation::query<StatusBarWidget>(obj);
if (!view)
......@@ -96,6 +96,6 @@ void ViewManager::aboutToRemoveObject(QObject *obj)
m_mainWnd->removeContextObject(view);
}
void ViewManager::extensionsInitalized()
void StatusBarManager::extensionsInitalized()
{
}
......@@ -27,8 +27,8 @@
**
**************************************************************************/
#ifndef VIEWMANAGER_H
#define VIEWMANAGER_H
#ifndef STATUSBARMANAGER_H
#define STATUSBARMANAGER_H
#include <QtCore/QMap>
#include <QtGui/QWidget>
......@@ -50,13 +50,13 @@ namespace Internal {
class MainWindow;
class NavigationWidget;
class ViewManager : public QObject
class StatusBarManager : public QObject
{
Q_OBJECT
public:
ViewManager(MainWindow *mainWnd);
~ViewManager();
StatusBarManager(MainWindow *mainWnd);
~StatusBarManager();
void init();
void extensionsInitalized();
......@@ -73,4 +73,4 @@ private:
} // namespace Internal
} // namespace Core
#endif // VIEWMANAGER_H
#endif // STATUSBARMANAGER_H
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment