summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Cullmann <cullmann@kde.org>2014-01-24 11:31:57 (GMT)
committerChristoph Cullmann <cullmann@kde.org>2014-01-24 11:31:57 (GMT)
commit0d0ff493c4e874367d987005886ba34f39bbe497 (patch)
tree4b7e787230fb63fdbe6e05ca6c44c4f171e4c01b
parentaada429e1f6824cd30644135f3034ea88ab47cba (diff)
less public API
-rw-r--r--kate/src/kateviewmanager.cpp29
-rw-r--r--kate/src/kateviewmanager.h12
2 files changed, 21 insertions, 20 deletions
diff --git a/kate/src/kateviewmanager.cpp b/kate/src/kateviewmanager.cpp
index bfd6476..f2c577c 100644
--- a/kate/src/kateviewmanager.cpp
+++ b/kate/src/kateviewmanager.cpp
@@ -62,6 +62,7 @@ KateViewManager::KateViewManager(QWidget *parentW, KateMainWindow *parent)
, m_blockViewCreationAndActivation(false)
, m_activeViewRunning(false)
, m_minAge(0)
+ , m_guiMergedView(nullptr)
{
// while init
m_init = true;
@@ -69,8 +70,6 @@ KateViewManager::KateViewManager(QWidget *parentW, KateMainWindow *parent)
// important, set them up, as we use them in other methodes
setupActions();
- guiMergedView = 0;
-
// resize mode
setOpaqueResize(style()->styleHint(QStyle::SH_Splitter_OpaqueResize, 0, this));
@@ -119,9 +118,9 @@ KateViewManager::~KateViewManager()
/**
* remove the single client that is registered at the factory, if any
*/
- if (guiMergedView) {
- mainWindow()->guiFactory()->removeClient(guiMergedView);
- guiMergedView = nullptr;
+ if (m_guiMergedView) {
+ mainWindow()->guiFactory()->removeClient(m_guiMergedView);
+ m_guiMergedView = nullptr;
}
}
@@ -498,9 +497,9 @@ bool KateViewManager::deleteView(KTextEditor::View *view)
/**
* deregister if needed
*/
- if (guiMergedView == view) {
- mainWindow()->guiFactory()->removeClient(guiMergedView);
- guiMergedView = nullptr;
+ if (m_guiMergedView == view) {
+ mainWindow()->guiFactory()->removeClient(m_guiMergedView);
+ m_guiMergedView = nullptr;
}
#ifdef KActivities_FOUND
@@ -647,15 +646,15 @@ void KateViewManager::activateView(KTextEditor::View *view)
mainWindow()->toolBar()->hide(); // hide to avoid toolbar flickering
}
- if (guiMergedView) {
- mainWindow()->guiFactory()->removeClient(guiMergedView);
- guiMergedView = nullptr;
+ if (m_guiMergedView) {
+ mainWindow()->guiFactory()->removeClient(m_guiMergedView);
+ m_guiMergedView = nullptr;
}
if (!m_blockViewCreationAndActivation) {
mainWindow()->guiFactory()->addClient(view);
- guiMergedView = view;
+ m_guiMergedView = view;
}
if (toolbarVisible) {
@@ -940,9 +939,9 @@ void KateViewManager::restoreViewConfiguration(const KConfigGroup &config)
/**
* remove the single client that is registered at the factory, if any
*/
- if (guiMergedView) {
- mainWindow()->guiFactory()->removeClient(guiMergedView);
- guiMergedView = nullptr;
+ if (m_guiMergedView) {
+ mainWindow()->guiFactory()->removeClient(m_guiMergedView);
+ m_guiMergedView = nullptr;
}
/**
diff --git a/kate/src/kateviewmanager.h b/kate/src/kateviewmanager.h
index 5d0a6cc..41bb9f3 100644
--- a/kate/src/kateviewmanager.h
+++ b/kate/src/kateviewmanager.h
@@ -54,14 +54,14 @@ public:
KateViewManager(QWidget *parentW, KateMainWindow *parent);
~KateViewManager();
- void updateViewSpaceActions();
-
private:
/**
* create all actions needed for the view manager
*/
void setupActions();
+ void updateViewSpaceActions();
+
public:
/* This will save the splitter configuration */
void saveViewConfiguration(KConfigGroup &group);
@@ -104,9 +104,6 @@ public Q_SLOTS:
void activateNextView();
void activatePrevView();
-protected:
- QPointer<KTextEditor::View> guiMergedView;
-
Q_SIGNALS:
void viewChanged(KTextEditor::View *);
void viewCreated(KTextEditor::View *);
@@ -276,6 +273,11 @@ private:
* current minimal age
*/
qint64 m_minAge;
+
+ /**
+ * the view that is ATM merged to the xml gui factory
+ */
+ QPointer<KTextEditor::View> m_guiMergedView;
};
#endif