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
PIM
PIM Data Exporter
Commits
4acb086d
Commit
4acb086d
authored
May 28, 2020
by
Laurent Montel
😁
Browse files
Make it compile without deprecated kf5.71 method
parent
efc498d0
Pipeline
#21441
passed with stage
in 19 minutes and 32 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
CMakeLists.txt
View file @
4acb086d
...
...
@@ -91,7 +91,7 @@ add_definitions(-DTRANSLATION_DOMAIN=\"pimdataexporter\")
if
(
EXISTS
"
${
CMAKE_SOURCE_DIR
}
/.git"
)
add_definitions
(
-DQT_DISABLE_DEPRECATED_BEFORE=0x050f00
)
add_definitions
(
-DKF_DISABLE_DEPRECATED_BEFORE_AND_AT=0x054
6
00
)
add_definitions
(
-DKF_DISABLE_DEPRECATED_BEFORE_AND_AT=0x054
7
00
)
endif
()
...
...
gui/dialog/showarchivestructuredialog.cpp
View file @
4acb086d
...
...
@@ -34,7 +34,13 @@
#include <QPushButton>
#include <QVBoxLayout>
#include <kio_version.h>
#if KIO_VERSION >= QT_VERSION_CHECK(5, 71, 0)
#include <KIO/JobUiDelegate>
#include <KIO/OpenUrlJob>
#else
#include <KRun>
#endif
#include <QFileDialog>
#include <QTemporaryDir>
#include <KTreeWidgetSearchLine>
...
...
@@ -119,8 +125,15 @@ void ShowArchiveStructureDialog::slotOpenFile()
qCWarning
(
PIMDATAEXPORTERGUI_LOG
)
<<
"Impossible to copy file: "
<<
currentItem
->
text
(
0
);
return
;
}
#if KIO_VERSION >= QT_VERSION_CHECK(5, 71, 0)
KIO
::
OpenUrlJob
*
job
=
new
KIO
::
OpenUrlJob
(
QUrl
::
fromLocalFile
(
fileName
));
job
->
setUiDelegate
(
new
KIO
::
JobUiDelegate
(
KJobUiDelegate
::
AutoHandlingEnabled
,
this
));
job
->
setRunExecutables
(
false
);
job
->
start
();
#else
KRun
*
runner
=
new
KRun
(
QUrl
::
fromLocalFile
(
fileName
),
this
);
// will delete itself
runner
->
setRunExecutables
(
false
);
#endif
}
}
}
...
...
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