┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/dolphinviewcontainer.cpp
diff options
context:
space:
mode:
authorAkseli Lahtinen <[email protected]>2024-11-27 12:28:13 +0200
committerAkseli Lahtinen <[email protected]>2024-11-27 12:28:13 +0200
commit67b319b7fc27254c8a7ee8f72f5fc7b10b0c4552 (patch)
treeecbc28323aea1f5758257c14b4b79e9591e1f667 /src/dolphinviewcontainer.cpp
parentc4ecf1cb2bf199ddccd02990429b535385475ffc (diff)
DolphinViewContainer: setSearchPath value only if searchBox is active
Fixes a crash when searchbox is not active and tab gets renamed. I forgot to add this to merge request https://invent.kde.org/system/dolphin/-/merge_requests/864 CCBUG:496387
Diffstat (limited to 'src/dolphinviewcontainer.cpp')
-rw-r--r--src/dolphinviewcontainer.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/dolphinviewcontainer.cpp b/src/dolphinviewcontainer.cpp
index 33f261bf4..f2df638f6 100644
--- a/src/dolphinviewcontainer.cpp
+++ b/src/dolphinviewcontainer.cpp
@@ -896,7 +896,9 @@ void DolphinViewContainer::redirect(const QUrl &oldUrl, const QUrl &newUrl)
// URL history.
m_urlNavigator->saveLocationState(QByteArray());
m_urlNavigator->setLocationUrl(newUrl);
- m_searchBox->setSearchPath(newUrl);
+ if (m_searchBox->isActive()) {
+ m_searchBox->setSearchPath(newUrl);
+ }
setSearchModeEnabled(isSearchUrl(newUrl));
m_urlNavigator->blockSignals(block);