Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit f25c5e10 authored by Mark Gaiser's avatar Mark Gaiser

Fix deprecation warnings. setSelection -> setSelectedUrl ui -> uiDelegate

Summary: Fix deprecation warnings.

Test Plan: autotest

Reviewers: davidedmundson, graesslin

Reviewed By: davidedmundson, graesslin

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D5743
parent 4aef17e6
......@@ -127,7 +127,7 @@ void KDEPlatformFileDialog::selectFile(const QUrl &filename)
{
QUrl dirUrl = filename.adjusted(QUrl::RemoveFilename);
m_fileWidget->setUrl(dirUrl);
m_fileWidget->setSelection(filename.toString());
m_fileWidget->setSelectedUrl(filename);
}
void KDEPlatformFileDialog::setViewMode(QFileDialogOptions::ViewMode view)
......@@ -224,7 +224,7 @@ void KDEPlatformFileDialog::setDirectory(const QUrl &directory)
if (!entry.isDir()) {
// this is probably a file remove the file part
m_fileWidget->setUrl(directory.adjusted(QUrl::RemoveFilename));
m_fileWidget->setSelection(directory.fileName());
m_fileWidget->setSelectedUrl(directory);
}
else {
m_fileWidget->setUrl(directory);
......
......@@ -251,7 +251,7 @@ void KDirSelectDialog::Private::slotMoveToTrash()
if (job.askDeleteConfirmation(QList<QUrl>() << url, KIO::JobUiDelegate::Trash, KIO::JobUiDelegate::DefaultConfirmation)) {
KIO::CopyJob *copyJob = KIO::trash(url);
KJobWidgets::setWindow(copyJob, m_parent);
copyJob->ui()->setAutoErrorHandlingEnabled(true);
copyJob->uiDelegate()->setAutoErrorHandlingEnabled(true);
}
}
......@@ -262,7 +262,7 @@ void KDirSelectDialog::Private::slotDelete()
if (job.askDeleteConfirmation(QList<QUrl>() << url, KIO::JobUiDelegate::Delete, KIO::JobUiDelegate::DefaultConfirmation)) {
KIO::DeleteJob *deleteJob = KIO::del(url);
KJobWidgets::setWindow(deleteJob, m_parent);
deleteJob->ui()->setAutoErrorHandlingEnabled(true);
deleteJob->uiDelegate()->setAutoErrorHandlingEnabled(true);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment