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
Utilities
Filelight
Commits
654878ef
Commit
654878ef
authored
Aug 23, 2020
by
Martin Tobias Holmedahl Sandsmark
Browse files
fix deprecated KIO warning
parent
d74382ba
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/radialMap/widgetEvents.cpp
View file @
654878ef
...
...
@@ -53,6 +53,10 @@
#include <cmath> //::segmentAt()
#if KIO_VERSION >= QT_VERSION_CHECK(5, 71, 0)
#include <KIO/OpenUrlJob>
#endif
void
RadialMap
::
Widget
::
resizeEvent
(
QResizeEvent
*
)
{
if
(
m_map
.
resize
(
rect
()))
...
...
@@ -341,8 +345,17 @@ void RadialMap::Widget::mousePressEvent(QMouseEvent *e)
QAction
*
clicked
=
popup
.
exec
(
e
->
globalPos
(),
nullptr
);
if
(
openFileManager
&&
clicked
==
openFileManager
)
{
auto
*
job
=
new
KIO
::
OpenUrlJob
(
url
,
QStringLiteral
(
"inode/directory"
),
this
);
job
->
start
();
#if KIO_VERSION < QT_VERSION_CHECK(5, 71, 0)
KRun
::
runUrl
(
url
,
QStringLiteral
(
"inode/directory"
),
this
#if KIO_VERSION >= QT_VERSION_CHECK(5, 31, 0)
,
KRun
::
RunFlags
()
#endif
);
#else // KIO 5.71
KIO
::
OpenUrlJob
*
job
=
new
KIO
::
OpenUrlJob
(
url
,
QStringLiteral
(
"inode/directory"
),
this
);
job
->
setUiDelegate
(
new
KIO
::
JobUiDelegate
(
KJobUiDelegate
::
AutoHandlingEnabled
,
window
()));
job
->
start
();
#endif
}
else
if
(
openTerminal
&&
clicked
==
openTerminal
)
{
KToolInvocation
::
invokeTerminal
(
QString
(),
url
.
path
());
}
else
if
(
centerMap
&&
clicked
==
centerMap
)
{
...
...
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