mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-10-01 01:26:01 -04:00
Use static constants for default icon numbers.
This commit is contained in:
parent
62073fa74d
commit
621ec80bbe
@ -28,7 +28,7 @@ Entry::Entry()
|
||||
m_updateTimeinfo = true;
|
||||
m_tmpHistoryItem = 0;
|
||||
|
||||
m_data.iconNumber = 0;
|
||||
m_data.iconNumber = DefaultIconNumber;
|
||||
m_data.autoTypeEnabled = true;
|
||||
m_data.autoTypeObfuscation = 0;
|
||||
|
||||
@ -56,6 +56,8 @@ Entry::~Entry()
|
||||
qDeleteAll(m_history);
|
||||
}
|
||||
|
||||
const int Entry::DefaultIconNumber = 0;
|
||||
|
||||
template <class T> bool Entry::set(T& property, const T& value)
|
||||
{
|
||||
if (property != value) {
|
||||
|
@ -89,6 +89,8 @@ public:
|
||||
EntryAttachments* attachments();
|
||||
const EntryAttachments* attachments() const;
|
||||
|
||||
static const int DefaultIconNumber;
|
||||
|
||||
void setUuid(const Uuid& uuid);
|
||||
void setIcon(int iconNumber);
|
||||
void setIcon(const Uuid& uuid);
|
||||
|
@ -23,7 +23,7 @@
|
||||
|
||||
Group::Group()
|
||||
{
|
||||
m_iconNumber = 48;
|
||||
m_iconNumber = DefaultIconNumber;
|
||||
m_isExpanded = true;
|
||||
m_autoTypeEnabled = Inherit;
|
||||
m_searchingEnabled = Inherit;
|
||||
@ -55,6 +55,8 @@ Group::~Group()
|
||||
}
|
||||
}
|
||||
|
||||
const int Group::DefaultIconNumber = 48;
|
||||
|
||||
template <class P, class V> bool Group::set(P& property, const V& value) {
|
||||
if (property != value) {
|
||||
property = value;
|
||||
|
@ -51,6 +51,8 @@ public:
|
||||
Group::TriState searchingEnabled() const;
|
||||
Entry* lastTopVisibleEntry() const;
|
||||
|
||||
static const int DefaultIconNumber;
|
||||
|
||||
void setUuid(const Uuid& uuid);
|
||||
void setName(const QString& name);
|
||||
void setNotes(const QString& notes);
|
||||
|
Loading…
Reference in New Issue
Block a user