Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
Akregator
Commits
6e51ec4b
Commit
6e51ec4b
authored
Dec 08, 2021
by
Laurent Montel
Browse files
Port deprecated methods
parent
49eaf98f
Pipeline
#107034
passed with stage
in 1 minute and 24 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
CMakeLists.txt
View file @
6e51ec4b
...
...
@@ -95,7 +95,7 @@ set_package_properties(KUserFeedback PROPERTIES DESCRIPTION "User Feedback lib"
include_directories
(
${
akregator_SOURCE_DIR
}
${
akregator_BINARY_DIR
}
)
add_definitions
(
-DTRANSLATION_DOMAIN=\"akregator\"
)
add_definitions
(
-DQT_DISABLE_DEPRECATED_BEFORE=0x050e00
)
add_definitions
(
-DKF_DISABLE_DEPRECATED_BEFORE_AND_AT=0x055
5
00
)
add_definitions
(
-DKF_DISABLE_DEPRECATED_BEFORE_AND_AT=0x055
8
00
)
if
(
TARGET KUserFeedbackWidgets
)
add_definitions
(
-DWITH_KUSERFEEDBACK
)
endif
()
...
...
export/akregatorstorageexporter.cpp
View file @
6e51ec4b
...
...
@@ -16,6 +16,7 @@
#include
<Syndication/Constants>
#include
<kcoreaddons_version.h>
#include
<KPluginMetaData>
#include
<QDateTime>
#include
<QFile>
#include
<QIODevice>
...
...
@@ -31,6 +32,7 @@
#include
<iostream>
#include
<KPluginFactory>
#include
<cassert>
using
namespace
Akregator
;
...
...
@@ -299,13 +301,9 @@ static KService::List queryStoragePlugins()
static
Plugin
*
createFromService
(
const
KService
::
Ptr
&
service
)
{
KPluginLoader
loader
(
*
service
);
KPluginFactory
*
factory
=
loader
.
factory
();
KPluginFactory
*
factory
=
KPluginFactory
::
loadFactory
(
KPluginMetaData
(
service
->
library
())).
plugin
;
if
(
!
factory
)
{
qCritical
()
<<
QStringLiteral
(
" Could not create plugin factory for: %1
\n
"
" Error message: %2"
)
.
arg
(
service
->
library
(),
loader
.
errorString
());
qCritical
()
<<
QStringLiteral
(
" Could not create plugin factory for: %1"
).
arg
(
service
->
library
());
return
nullptr
;
}
return
factory
->
create
<
Akregator
::
Plugin
>
();
...
...
src/pluginmanager.cpp
View file @
6e51ec4b
...
...
@@ -49,13 +49,9 @@ Plugin *PluginManager::createFromService(const KService::Ptr &service, QObject *
{
qCDebug
(
AKREGATOR_LOG
)
<<
"Trying to load:"
<<
service
->
library
();
KPluginLoader
loader
(
*
service
);
KPluginFactory
*
factory
=
loader
.
factory
();
KPluginFactory
*
factory
=
KPluginFactory
::
loadFactory
(
KPluginMetaData
(
service
->
library
())).
plugin
;
if
(
!
factory
)
{
qCWarning
(
AKREGATOR_LOG
)
<<
QStringLiteral
(
" Could not create plugin factory for: %1
\n
"
" Error message: %2"
)
.
arg
(
service
->
library
(),
loader
.
errorString
());
qCWarning
(
AKREGATOR_LOG
)
<<
QStringLiteral
(
" Could not create plugin factory for: %1"
).
arg
(
service
->
library
());
return
nullptr
;
}
auto
const
plugin
=
factory
->
create
<
Plugin
>
(
parent
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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