summaryrefslogtreecommitdiff
path: root/src/bookmarks
diff options
context:
space:
mode:
Diffstat (limited to 'src/bookmarks')
-rw-r--r--src/bookmarks/bookmarkprovider.cpp4
-rw-r--r--src/bookmarks/bookmarkstreemodel.cpp5
2 files changed, 7 insertions, 2 deletions
diff --git a/src/bookmarks/bookmarkprovider.cpp b/src/bookmarks/bookmarkprovider.cpp
index ec02ed31..3459108d 100644
--- a/src/bookmarks/bookmarkprovider.cpp
+++ b/src/bookmarks/bookmarkprovider.cpp
@@ -39,6 +39,7 @@
// KDE Includes
#include <KActionCollection>
#include <KStandardDirs>
+#include <KMimeType>
// Qt Includes
#include <QtCore/QFile>
@@ -230,7 +231,8 @@ void BookmarkProvider::fillBookmarkBar(BookmarkToolBar *toolBar)
void BookmarkProvider::slotAddBookmark()
{
- rootGroup().addBookmark(bookmarkOwner()->currentTitle(), bookmarkOwner()->currentUrl());
+ QString url = bookmarkOwner()->currentUrl();
+ rootGroup().addBookmark(bookmarkOwner()->currentTitle(), url, KMimeType::favIconForUrl( KUrl(url) ) );
bookmarkManager()->emitChanged();
}
diff --git a/src/bookmarks/bookmarkstreemodel.cpp b/src/bookmarks/bookmarkstreemodel.cpp
index ee19daf1..ba106ca5 100644
--- a/src/bookmarks/bookmarkstreemodel.cpp
+++ b/src/bookmarks/bookmarkstreemodel.cpp
@@ -62,8 +62,11 @@ QVariant BtmItem::data(int role) const
return m_kbm.text();
if (role == Qt::DecorationRole)
+ {
+ kDebug() << "BOOKMARK ICON: " << m_kbm.icon();
return KIcon(m_kbm.icon());
-
+ }
+
if (role == Qt::UserRole)
return m_kbm.url();