mirror of
https://invent.kde.org/network/falkon.git
synced 2024-11-11 01:22:10 +01:00
Fixed align of all bookmarks in center when show most visited is hidden
This commit is contained in:
parent
483ef1a9cb
commit
4ed8026bfa
|
@ -80,7 +80,7 @@ void BookmarksToolbar::loadClickedBookmark()
|
|||
void BookmarksToolbar::showMostVisited()
|
||||
{
|
||||
m_bookmarksModel->setShowingMostVisited(!m_bookmarksModel->isShowingMostVisited());
|
||||
refreshBookmarks();
|
||||
m_mostVis->setVisible(!m_mostVis->isVisible());
|
||||
}
|
||||
|
||||
void BookmarksToolbar::addBookmark(const BookmarksModel::Bookmark &bookmark)
|
||||
|
@ -174,12 +174,8 @@ void BookmarksToolbar::refreshBookmarks()
|
|||
|
||||
connect(button, SIGNAL(clicked()), this, SLOT(loadClickedBookmark()));
|
||||
m_layout->addWidget(button);
|
||||
|
||||
}
|
||||
|
||||
if (!m_bookmarksModel->isShowingMostVisited())
|
||||
return;
|
||||
|
||||
m_mostVis = new ToolButton(this);
|
||||
m_mostVis->setPopupMode(QToolButton::InstantPopup);
|
||||
m_mostVis->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
||||
|
@ -193,6 +189,8 @@ void BookmarksToolbar::refreshBookmarks()
|
|||
|
||||
m_layout->addWidget(m_mostVis);
|
||||
m_layout->addStretch();
|
||||
|
||||
m_mostVis->setVisible(m_bookmarksModel->isShowingMostVisited());
|
||||
}
|
||||
|
||||
void BookmarksToolbar::refreshMostVisited()
|
||||
|
|
|
@ -56,7 +56,6 @@ private:
|
|||
QMenu* m_menuMostVisited;
|
||||
ToolButton* m_mostVis;
|
||||
QHBoxLayout* m_layout;
|
||||
|
||||
};
|
||||
|
||||
#endif // BOOKMARKSTOOLBAR_H
|
||||
|
|
Loading…
Reference in New Issue
Block a user