From 168ba15c74e6234e12de31f6b517b68ad7762851 Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Thu, 3 Nov 2011 16:33:15 +0100 Subject: Fix to bug 242675 backported in Branches.0.8 --- src/mainwindow.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 23ccf25d..beab3afc 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -669,14 +669,14 @@ void MainWindow::fileSaveAs() name = srcUrl.host() + QString(".html"); } - const QString destUrl = KFileDialog::getSaveFileName(name, QString(), this); + const KUrl destUrl = KFileDialog::getSaveUrl(name, QString(), this); if (destUrl.isEmpty()) return; if (w->page()->isContentEditable()) { QString code = w->page()->mainFrame()->toHtml(); - QFile file(destUrl); + QFile file(destUrl.url()); if (!file.open(QIODevice::WriteOnly | QIODevice::Text)) return; @@ -686,7 +686,7 @@ void MainWindow::fileSaveAs() return; } - KIO::Job *job = KIO::file_copy(srcUrl, KUrl(destUrl), -1, KIO::Overwrite); + KIO::Job *job = KIO::file_copy(srcUrl, destUrl, -1, KIO::Overwrite); job->addMetaData("MaxCacheSize", "0"); // Don't store in http cache. job->addMetaData("cache", "cache"); // Use entry from cache if available. job->uiDelegate()->setAutoErrorHandlingEnabled(true); -- cgit v1.2.1