Commit 6f6fafe1 authored by Kai Koehne's avatar Kai Koehne
Browse files

Insert default sidebar items in the order of the argument list

parent fc33e355
......@@ -56,8 +56,11 @@ SideBar::SideBar(QList<SideBarItem*> itemList,
foreach (SideBarItem *item, itemList) {
const QString title = item->widget()->windowTitle();
m_itemMap.insert(title, item);
if (defaultVisible.contains(item))
foreach (SideBarItem *item, defaultVisible) {
if (!itemList.contains(item))
m_availableItems = m_itemMap.keys();
......@@ -166,7 +169,7 @@ void SideBar::readSettings(QSettings *settings)
} else {
foreach (const QString &title, m_defaultVisible)
insertSideBarWidget(0, title);
insertSideBarWidget(m_widgets.count(), title);
if (settings->contains("HelpSideBar/Visible"))
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment