X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/175538020824355115cd98637ce83ecc53badd44..bb67def173f31819bb9a696627f9af71c7037dcd:/src/dolphintabwidget.cpp diff --git a/src/dolphintabwidget.cpp b/src/dolphintabwidget.cpp index 17fa0ff4e..cfb695e7d 100644 --- a/src/dolphintabwidget.cpp +++ b/src/dolphintabwidget.cpp @@ -87,15 +87,8 @@ void DolphinTabWidget::readProperties(const KConfigGroup& group) if (i >= count()) { openNewActivatedTab(); } - if (group.hasKey("Tab Data " % QString::number(i))) { - // Tab state created with Dolphin > 4.14.x - const QByteArray state = group.readEntry("Tab Data " % QString::number(i), QByteArray()); - tabPageAt(i)->restoreState(state); - } else { - // Tab state created with Dolphin <= 4.14.x - const QByteArray state = group.readEntry("Tab " % QString::number(i), QByteArray()); - tabPageAt(i)->restoreStateV1(state); - } + const QByteArray state = group.readEntry("Tab Data " % QString::number(i), QByteArray()); + tabPageAt(i)->restoreState(state); } const int index = group.readEntry("Active Tab Index", 0); @@ -210,7 +203,7 @@ void DolphinTabWidget::openDirectories(const QList& dirs, bool splitView) // Required for updateViewState() call in openFiles() to work as expected // If there is a selection, updateViewState() calls are effectively a no-op tabPage->activeViewContainer()->view()->clearSelection(); - } else if (splitView) { + } else if (splitView && (it != dirs.constEnd())) { const QUrl& secondaryUrl = *(it++); if (somethingWasAlreadyOpen) { openNewTab(primaryUrl, secondaryUrl);