mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2026-01-01 00:30:17 -05:00
Add extend entry-size calculation (resolved #1387)
Extended the calculation for the size of history items to match KeePass2 Small refactoring regarding readability in EntryAttachements
This commit is contained in:
parent
83f1a53d32
commit
045f157a63
7 changed files with 34 additions and 12 deletions
|
|
@ -283,14 +283,14 @@ void EntryAttributes::clear()
|
|||
emit modified();
|
||||
}
|
||||
|
||||
int EntryAttributes::attributesSize()
|
||||
int EntryAttributes::attributesSize() const
|
||||
{
|
||||
int size = 0;
|
||||
|
||||
QMapIterator<QString, QString> i(m_attributes);
|
||||
while (i.hasNext()) {
|
||||
i.next();
|
||||
size += i.value().toUtf8().size();
|
||||
size += i.key().toUtf8().size() + i.value().toUtf8().size();
|
||||
}
|
||||
return size;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue