Commit 4983ee7e authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Use scheme()

parent 45c12d46
......@@ -37,7 +37,7 @@ QCheckBox* FileDialog::mAppendCheck = 0;
QString FileDialog::getSaveFileName(const KUrl& dir, const QString& filter, QWidget* parent, const QString& caption, bool* append)
{
bool defaultDir = dir.isEmpty();
bool specialDir = !defaultDir && dir.protocol() == QLatin1String("kfiledialog");
bool specialDir = !defaultDir && dir.scheme() == QLatin1String("kfiledialog");
// Use AutoQPointer to guard against crash on application exit while
// the dialogue is still open. It prevents double deletion (both on
// deletion of parent, and on return from this function).
......
......@@ -163,7 +163,7 @@ void LineEdit::dropEvent(QDropEvent* e)
QString mailto = QLatin1String("mailto");
for (KUrl::List::Iterator it = files.begin(); it != files.end(); ++it)
{
if ((*it).protocol() == mailto)
if ((*it).scheme() == mailto)
newEmails.append((*it).path());
}
break;
......@@ -179,7 +179,7 @@ void LineEdit::dropEvent(QDropEvent* e)
QString txt = data->text();
if (mType == Emails)
{
// Remove newlines from a list of email addresses, and allow an eventual mailto: protocol
// Remove newlines from a list of email addresses, and allow an eventual mailto: scheme
QString mailto = QLatin1String("mailto:");
newEmails = txt.split(QRegExp(QLatin1String("[\r\n]+")), QString::SkipEmptyParts);
for (QStringList::Iterator it = newEmails.begin(); it != newEmails.end(); ++it)
......
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