summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Cullmann <cullmann@kde.org>2014-01-24 00:55:21 (GMT)
committerChristoph Cullmann <cullmann@kde.org>2014-01-24 00:55:21 (GMT)
commit13917d21f6126df9f4a051926a1f6ceeaa9887e5 (patch)
tree4024c39440589766b9066c5705e7a9e560e69de9
parent81dfc45eb2ee0dbad922064e1ad747ac233d7e3d (diff)
fix crash on open document if only one document that is untitled and fresh is around
-rw-r--r--kate/src/kateviewspace.cpp17
1 files changed, 0 insertions, 17 deletions
diff --git a/kate/src/kateviewspace.cpp b/kate/src/kateviewspace.cpp
index e8dd49c..579c570 100644
--- a/kate/src/kateviewspace.cpp
+++ b/kate/src/kateviewspace.cpp
@@ -187,25 +187,8 @@ void KateViewSpace::removeView(KTextEditor::View *v)
Q_ASSERT(m_docToView.contains(v->document()));
m_docToView.remove(v->document());
- // first check wheter this view is the active one
- const bool wasActive = (v == currentView());
-
// ...and now: remove from view space
stack->removeWidget(v);
-
- // the last recently used view/document is always at the end of the list
- if (wasActive && m_lruDocList.size() >= 2) {
- m_lruDocList.prepend(m_lruDocList.takeLast());
- KTextEditor::Document * doc = m_lruDocList.last();
- if (m_docToView.contains(doc)) {
- showView(doc);
- } else {
- m_viewManager->createView(doc, this);
- }
- } else {
- // FIXME: what to do?
- //m_viewManager->createView(some document?!, this);
- }
}
bool KateViewSpace::showView(KTextEditor::Document *document)