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
Network
Konqueror
Commits
ef48b82b
Commit
ef48b82b
authored
Feb 14, 2021
by
Ahmad Samir
Browse files
Port away from deprecated KIO signals
parent
dd9d2103
Changes
1
Hide whitespace changes
Inline
Side-by-side
sidebar/trees/dirtree_module/dirtree_module.cpp
View file @
ef48b82b
...
...
@@ -22,6 +22,7 @@
#include "dirtree_item.h"
#include <kconfiggroup.h>
#include <kio_version.h>
#include <kprotocolmanager.h>
#include <kdesktopfile.h>
#include <kmessagebox.h>
...
...
@@ -42,8 +43,12 @@ KonqSidebarDirTreeModule::~KonqSidebarDirTreeModule()
{
// KDirLister may still emit canceled while being deleted.
if
(
m_dirLister
)
{
#if KIO_VERSION < QT_VERSION_CHECK(5, 79, 0)
disconnect
(
m_dirLister
,
SIGNAL
(
canceled
(
QUrl
)),
this
,
SLOT
(
slotListingStopped
(
QUrl
)));
#else
disconnect
(
m_dirLister
,
&
KCoreDirLister
::
listingDirCanceled
,
this
,
&
KonqSidebarDirTreeModule
::
slotListingStopped
);
#endif
delete
m_dirLister
;
}
}
...
...
@@ -297,10 +302,17 @@ void KonqSidebarDirTreeModule::openSubFolder(KonqSidebarTreeItem *item)
this
,
SLOT
(
slotRefreshItems
(
QList
<
QPair
<
KFileItem
,
KFileItem
>
>
)));
connect
(
m_dirLister
,
SIGNAL
(
deleteItem
(
KFileItem
)),
this
,
SLOT
(
slotDeleteItem
(
KFileItem
)));
#if KIO_VERSION < QT_VERSION_CHECK(5, 79, 0)
connect
(
m_dirLister
,
SIGNAL
(
completed
(
QUrl
)),
this
,
SLOT
(
slotListingStopped
(
QUrl
)));
connect
(
m_dirLister
,
SIGNAL
(
canceled
(
QUrl
)),
this
,
SLOT
(
slotListingStopped
(
QUrl
)));
#else
connect
(
m_dirLister
,
&
KCoreDirLister
::
listingDirCompleted
,
this
,
&
KonqSidebarDirTreeModule
::
slotListingStopped
);
connect
(
m_dirLister
,
&
KCoreDirLister
::
listingDirCanceled
,
this
,
&
KonqSidebarDirTreeModule
::
slotListingStopped
);
#endif
connect
(
m_dirLister
,
SIGNAL
(
redirection
(
QUrl
,
QUrl
)),
this
,
SLOT
(
slotRedirection
(
QUrl
,
QUrl
)));
}
...
...
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