mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-08-08 14:32:39 -04:00
Replace QMap with QHash when the key is a pointer
QHash gives faster lookups than QMap when the key is a pointer.
This commit is contained in:
parent
9a5bbea2e4
commit
ffea029001
2 changed files with 4 additions and 3 deletions
|
@ -19,6 +19,7 @@
|
|||
#ifndef KEEPASSX_MESSAGEBOX_H
|
||||
#define KEEPASSX_MESSAGEBOX_H
|
||||
|
||||
#include <QHash>
|
||||
#include <QMap>
|
||||
#include <QMessageBox>
|
||||
#include <QPushButton>
|
||||
|
@ -102,7 +103,7 @@ public:
|
|||
|
||||
private:
|
||||
static Button m_nextAnswer;
|
||||
static QMap<QAbstractButton*, Button> m_addedButtonLookup;
|
||||
static QHash<QAbstractButton*, Button> m_addedButtonLookup;
|
||||
static QMap<Button, std::pair<QString, QMessageBox::ButtonRole>> m_buttonDefs;
|
||||
|
||||
static Button messageBox(QWidget* parent,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue