D22594: [Dolphin] Open Preferred Search Tool action
Elvis Angelaccio
noreply at phabricator.kde.org
Sun Oct 13 16:19:04 BST 2019
elvisangelaccio requested changes to this revision.
elvisangelaccio added a comment.
This revision now requires changes to proceed.
Almost there!
INLINE COMMENTS
> pdabrowski wrote in dolphinmainwindow.cpp:916-919
> There is no other way to update the open_preferred_search_tool action *before* the Configure Shortcuts window is shown.
> This action is then listed in that window, so it should be up-to-date when it is displayed.
> This update is instantaneous if user made no changes to the search tools in the meantime.
Please write this information in a comment above that `connect()`.
> dolphinmainwindow.cpp:968
> + QAction* openPreferredSearchTool = actionCollection()->action(QStringLiteral("open_preferred_search_tool"));
> + QList<QWidget*> widgets = openPreferredSearchTool->associatedWidgets();
> + for (QWidget* widget : widgets) {
Missing `const`
> dolphinpart.cpp:536
> {
> - QString dir(QDir::homePath());
> -
> - QUrl u(url());
> -
> - // If the given directory is not local, it can still be the URL of an
> - // ioslave using UDS_LOCAL_PATH which to be converted first.
> - KIO::StatJob* statJob = KIO::mostLocalUrl(u);
> - KJobWidgets::setWindow(statJob, widget());
> - statJob->exec();
> - u = statJob->mostLocalUrl();
> -
> - //If the URL is local after the above conversion, set the directory.
> - if (u.isLocalFile()) {
> - dir = u.toLocalFile();
> - }
> -
> - KToolInvocation::invokeTerminal(QString(), dir);
> + KToolInvocation::invokeTerminal(QString(), KParts::ReadOnlyPart::localFilePath());
> }
This is an unrelated change actually, isn't it? It makes sense, but it should go in another commit.
REPOSITORY
R318 Dolphin
REVISION DETAIL
https://phabricator.kde.org/D22594
To: pdabrowski, #dolphin, ngraham, elvisangelaccio
Cc: pkloc, kfm-devel, kde-doc-english, iasensio, fprice, gennad, MrPepe, fbampaloukas, alexde, Codezela, feverfew, meven, spoorun, navarromorales, firef, ngraham, andrebarros, skadinna, emmanuelp, mikesomov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-doc-english/attachments/20191013/a42beb4a/attachment.html>
More information about the kde-doc-english
mailing list