Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
System
KHelpCenter
Commits
ff1d7a54
Commit
ff1d7a54
authored
Oct 12, 2020
by
Laurent Montel
😁
Browse files
Port krun
parent
f18038fa
Changes
1
Hide whitespace changes
Inline
Side-by-side
mainwindow.cpp
View file @
ff1d7a54
...
...
@@ -53,11 +53,18 @@
#include
<KConfigGroup>
#include
<KHTMLSettings>
#include
<KHTMLView>
#include
<KRun>
#include
<KStandardAction>
#include
<KStartupInfo>
#include
<KWindowConfig>
#include
<kio_version.h>
#if KIO_VERSION < QT_VERSION_CHECK(5, 71, 0)
#include
<KRun>
#else
#include
<KIO/JobUiDelegate>
#include
<KIO/OpenUrlJob>
#endif
#include
<KIO/Job>
#include
<prefs.h>
...
...
@@ -352,7 +359,13 @@ void MainWindow::viewUrl( const QUrl &url, const KParts::OpenUrlArguments &args,
}
if
(
!
own
)
{
#if KIO_VERSION < QT_VERSION_CHECK(5, 71, 0)
new
KRun
(
url
,
this
);
#else
auto
*
job
=
new
KIO
::
OpenUrlJob
(
QUrl
(
url
));
job
->
setUiDelegate
(
new
KIO
::
JobUiDelegate
(
KJobUiDelegate
::
AutoHandlingEnabled
,
this
));
job
->
start
();
#endif
return
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment