From e9670c51fef2c8447a04a30778a24646df4ef915 Mon Sep 17 00:00:00 2001 From: Yoann Laissus Date: Tue, 23 Mar 2010 22:56:26 +0100 Subject: A lot of fix and improvements for the bookmark and the history panels --- src/bookmarks/bookmarkspanel.h | 36 ++++++++++++++++++++++++++++++++++-- 1 file changed, 34 insertions(+), 2 deletions(-) (limited to 'src/bookmarks/bookmarkspanel.h') diff --git a/src/bookmarks/bookmarkspanel.h b/src/bookmarks/bookmarkspanel.h index f5376d98..ea33e265 100644 --- a/src/bookmarks/bookmarkspanel.h +++ b/src/bookmarks/bookmarkspanel.h @@ -31,10 +31,17 @@ // Local Includes #include "rekonqprivate_export.h" +#include "application.h" +#include "urltreeview.h" // Qt Includes #include +// KDE Includes +#include +#include +#include + // Forward Declarations class KUrl; class QModelIndex; @@ -49,13 +56,38 @@ public: ~BookmarksPanel(); signals: - void openUrl(const KUrl &); + void openUrl(const KUrl &, const Rekonq::OpenType &); + void itemHovered(const QString &); + void saveExpFinished(const QString &); + void saveRequested(); private slots: - void bookmarkActivated( const QModelIndex &index ); + void contextMenuBk(const QPoint &pos); + void contextMenuBkGroup(const QPoint &pos, const bool emptyGroup = false); + void contextMenuBlank(const QPoint &pos); + void deleteBookmark(); + void openAll(); + void editBookmark(); + void newBookmark(); + void newBookmarkGroup(); + void newSeparator(); + void bookmarkPage(); + void autoExpand(const QModelIndex &root = QModelIndex()); + void onCollapse(const QModelIndex &index); + void onExpand(const QModelIndex &index); + void callAutoExpand(); private: void setup(); + void setupActions(); + void contextMenuSeparator(const QPoint &pos); + KBookmark bookmarkForIndex(const QModelIndex &index); + + UrlTreeView *m_treeView; + QStringList m_expList; + KActionCollection m_ac; + KMenu *menu; + bool expandLock; }; #endif // BOOKMARKSPANEL_H -- cgit v1.2.1 From 632389517ca496031bb1cbe468d904884961bf57 Mon Sep 17 00:00:00 2001 From: Yoann Laissus Date: Sat, 27 Mar 2010 19:04:11 +0100 Subject: - Fix a crash when the cancel button of the add bookmark menu is clicked - Use the same behaviour for delete bookmark as the toolbar - Some strings changed - Keep the selection of a folder when it's expanded/collapsed - Fix the name of some methods and properties - Code cleaned a bit --- src/bookmarks/bookmarkspanel.h | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) (limited to 'src/bookmarks/bookmarkspanel.h') diff --git a/src/bookmarks/bookmarkspanel.h b/src/bookmarks/bookmarkspanel.h index ea33e265..be52804f 100644 --- a/src/bookmarks/bookmarkspanel.h +++ b/src/bookmarks/bookmarkspanel.h @@ -40,7 +40,6 @@ // KDE Includes #include #include -#include // Forward Declarations class KUrl; @@ -58,24 +57,24 @@ public: signals: void openUrl(const KUrl &, const Rekonq::OpenType &); void itemHovered(const QString &); - void saveExpFinished(const QString &); - void saveRequested(); + void saveOnlyRequested(); private slots: void contextMenuBk(const QPoint &pos); void contextMenuBkGroup(const QPoint &pos, const bool emptyGroup = false); void contextMenuBlank(const QPoint &pos); void deleteBookmark(); - void openAll(); + void openFolderInTabs(); void editBookmark(); void newBookmark(); void newBookmarkGroup(); void newSeparator(); - void bookmarkPage(); - void autoExpand(const QModelIndex &root = QModelIndex()); void onCollapse(const QModelIndex &index); void onExpand(const QModelIndex &index); - void callAutoExpand(); + void bookmarkCurrentPage(); + void loadFoldedState(const QModelIndex &root); + void loadFoldedState(); + private: void setup(); @@ -84,10 +83,8 @@ private: KBookmark bookmarkForIndex(const QModelIndex &index); UrlTreeView *m_treeView; - QStringList m_expList; - KActionCollection m_ac; - KMenu *menu; - bool expandLock; + KActionCollection *m_ac; + bool m_loadingState; }; #endif // BOOKMARKSPANEL_H -- cgit v1.2.1 From 6183e8e1c21807299f04f4e84c43486cf684f140 Mon Sep 17 00:00:00 2001 From: Yoann Laissus Date: Sat, 27 Mar 2010 22:17:20 +0100 Subject: - Remove the Add Bookmark action from the different context menus - Add Bookmark Here now add the bookmark on top of the selected item - ctor initialisation for the UrlTreeView of the history panel --- src/bookmarks/bookmarkspanel.h | 1 - 1 file changed, 1 deletion(-) (limited to 'src/bookmarks/bookmarkspanel.h') diff --git a/src/bookmarks/bookmarkspanel.h b/src/bookmarks/bookmarkspanel.h index be52804f..f8528b71 100644 --- a/src/bookmarks/bookmarkspanel.h +++ b/src/bookmarks/bookmarkspanel.h @@ -66,7 +66,6 @@ private slots: void deleteBookmark(); void openFolderInTabs(); void editBookmark(); - void newBookmark(); void newBookmarkGroup(); void newSeparator(); void onCollapse(const QModelIndex &index); -- cgit v1.2.1