From 413a8988116708ab8bcf9efbb9bc8f52e048efa5 Mon Sep 17 00:00:00 2001 From: rekols Date: Fri, 16 Nov 2018 19:21:31 +0800 Subject: [PATCH] fix(drecentmanager): uniform url format. Change-Id: If61c023af00d55c72713697dfd8e6a229cf23169 --- src/util/drecentmanager.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/util/drecentmanager.cpp b/src/util/drecentmanager.cpp index 98aff4fe..1b03e6e2 100644 --- a/src/util/drecentmanager.cpp +++ b/src/util/drecentmanager.cpp @@ -28,7 +28,6 @@ #include #include #include -#include DCORE_BEGIN_NAMESPACE @@ -141,9 +140,10 @@ bool DRecentManager::addItem(const QString &uri, DRecentData &data) // add new elements if they don't exist. else { QDomElement bookmarkEle, infoEle, metadataEle, mimeEle, appsEle, appChildEle; + QString hrefStr = QString::fromLatin1(url.toEncoded(QUrl::FullyEncoded)); bookmarkEle = doc.createElement("bookmark"); - bookmarkEle.setAttribute("href", url.toString()); + bookmarkEle.setAttribute("href", hrefStr); bookmarkEle.setAttribute("added", dateTime); bookmarkEle.setAttribute("modified", dateTime); bookmarkEle.setAttribute("visited", dateTime);