mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-28 00:49:28 -05:00
Expand All/Contacts items by default & store/load expand settings.
This commit is contained in:
parent
672ab256d7
commit
a63482d642
@ -250,6 +250,10 @@ void IdDialog::processSettings(bool load)
|
||||
|
||||
// state of splitter
|
||||
Settings->setValue("splitter", ui->splitter->saveState());
|
||||
|
||||
//save expanding
|
||||
Settings->setValue("ExpandAll", allItem->isExpanded());
|
||||
Settings->setValue("ExpandContacts", contactsItem->isExpanded());
|
||||
}
|
||||
|
||||
Settings->endGroup();
|
||||
@ -511,6 +515,11 @@ void IdDialog::insertIdList(uint32_t token)
|
||||
ui->idTreeWidget->insertTopLevelItem(0, contactsItem );
|
||||
ui->idTreeWidget->insertTopLevelItem(0, allItem);
|
||||
|
||||
Settings->beginGroup("IdDialog");
|
||||
allItem->setExpanded(Settings->value("ExpandAll", QVariant(true)).toBool());
|
||||
contactsItem->setExpanded(Settings->value("ExpandContacts", QVariant(true)).toBool());
|
||||
Settings->endGroup();
|
||||
|
||||
if (fillIdListItem(vit->second, item, ownPgpId, accept))
|
||||
if(vit->second.mIsAContact)
|
||||
contactsItem->addChild(item);
|
||||
|
Loading…
Reference in New Issue
Block a user