summaryrefslogtreecommitdiff
path: root/src/bookmarks.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/bookmarks.cpp')
-rw-r--r--src/bookmarks.cpp28
1 files changed, 28 insertions, 0 deletions
diff --git a/src/bookmarks.cpp b/src/bookmarks.cpp
index 9b48de6f..bb2fb162 100644
--- a/src/bookmarks.cpp
+++ b/src/bookmarks.cpp
@@ -112,6 +112,34 @@ BookmarksProvider::BookmarksProvider(KMainWindow* parent)
}
m_manager = KBookmarkManager::managerForExternalFile( bookfile.path() );
m_ac = new KActionCollection( this );
+
+ connect( m_manager, SIGNAL( changed(const QString &, const QString &) ), this, SLOT( slotBookmarksChanged(const QString &) ) );
+}
+
+
+void BookmarksProvider::slotBookmarksChanged(const QString & group)
+{
+ KBookmarkGroup toolbarGroup = m_manager->toolbar();
+// KBookmarkGroup tb = getToolbar(); // heavy for non cached toolbar version
+ kWarning() << "KBookmarkBar::slotBookmarksChanged( " << group << " )";
+
+ if ( toolbarGroup.isNull() )
+ return;
+
+/* if ( KBookmark::commonParent(group, tb.address()) == group) // Is group a parent of tb.address?
+ {
+ */m_bmToolbar->clear();
+ provideBmToolbar(m_bmToolbar);
+// }
+// else
+// {
+// // Iterate recursively into child menus
+// for ( QList<KBookmarkMenu *>::ConstIterator smit = m_lstSubMenus.constBegin(), smend = m_lstSubMenus.constEnd();
+// smit != smend; ++smit )
+// {
+// (*smit)->slotBookmarksChanged( group );
+// }
+// }
}