summaryrefslogtreecommitdiff
path: root/src/bookmarks/bookmarkspanel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/bookmarks/bookmarkspanel.cpp')
-rw-r--r--src/bookmarks/bookmarkspanel.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/bookmarks/bookmarkspanel.cpp b/src/bookmarks/bookmarkspanel.cpp
index 94a3de94..8ad15309 100644
--- a/src/bookmarks/bookmarkspanel.cpp
+++ b/src/bookmarks/bookmarkspanel.cpp
@@ -43,9 +43,9 @@
BookmarksPanel::BookmarksPanel(const QString &title, QWidget *parent, Qt::WindowFlags flags)
- : UrlPanel(title, parent, flags)
- , _bkTreeModel(new BookmarksTreeModel(this))
- , _loadingState(false)
+ : UrlPanel(title, parent, flags)
+ , _bkTreeModel(new BookmarksTreeModel(this))
+ , _loadingState(false)
{
setObjectName("bookmarksPanel");
setVisible(ReKonfig::showBookmarksPanel());
@@ -71,7 +71,7 @@ void BookmarksPanel::loadFoldedState()
void BookmarksPanel::contextMenu(const QPoint &pos)
{
- if (_loadingState)
+ if(_loadingState)
return;
BookmarksContextMenu menu(bookmarkForIndex(panelTreeView()->indexAt(pos)),
@@ -86,7 +86,7 @@ void BookmarksPanel::contextMenu(const QPoint &pos)
void BookmarksPanel::deleteBookmark()
{
QModelIndex index = panelTreeView()->currentIndex();
- if (_loadingState || !index.isValid())
+ if(_loadingState || !index.isValid())
return;
rApp->bookmarkProvider()->bookmarkOwner()->deleteBookmark(bookmarkForIndex(index));
@@ -95,7 +95,7 @@ void BookmarksPanel::deleteBookmark()
void BookmarksPanel::onCollapse(const QModelIndex &index)
{
- if (_loadingState)
+ if(_loadingState)
return;
bookmarkForIndex(index).internalElement().setAttribute("folded", "yes");
@@ -105,7 +105,7 @@ void BookmarksPanel::onCollapse(const QModelIndex &index)
void BookmarksPanel::onExpand(const QModelIndex &index)
{
- if (_loadingState)
+ if(_loadingState)
return;
bookmarkForIndex(index).internalElement().setAttribute("folded", "no");
@@ -129,19 +129,19 @@ void BookmarksPanel::setup()
void BookmarksPanel::loadFoldedState(const QModelIndex &root)
{
QAbstractItemModel *model = panelTreeView()->model();
- if (!model)
+ if(!model)
return;
int count = model->rowCount(root);
QModelIndex index;
- for (int i = 0; i < count; ++i)
+ for(int i = 0; i < count; ++i)
{
index = model->index(i, 0, root);
- if (index.isValid())
+ if(index.isValid())
{
KBookmark bm = bookmarkForIndex(index);
- if (bm.isGroup())
+ if(bm.isGroup())
{
panelTreeView()->setExpanded(index, bm.toGroup().isOpen());
loadFoldedState(index);
@@ -153,7 +153,7 @@ void BookmarksPanel::loadFoldedState(const QModelIndex &root)
KBookmark BookmarksPanel::bookmarkForIndex(const QModelIndex &index)
{
- if (!index.isValid())
+ if(!index.isValid())
return KBookmark();
const UrlFilterProxyModel *proxyModel = static_cast<const UrlFilterProxyModel*>(index.model());