mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-02-25 17:01:17 -05:00
Prefix object attribute with "m_".
This commit is contained in:
parent
97ca81f316
commit
d2e677c7f4
@ -23,21 +23,21 @@
|
|||||||
|
|
||||||
GroupView::GroupView(Database* db, QWidget* parent) : QTreeView(parent)
|
GroupView::GroupView(Database* db, QWidget* parent) : QTreeView(parent)
|
||||||
{
|
{
|
||||||
model = new GroupModel(db, this);
|
m_model = new GroupModel(db, this);
|
||||||
QTreeView::setModel(model);
|
QTreeView::setModel(m_model);
|
||||||
recInitExpanded(db->rootGroup());
|
recInitExpanded(db->rootGroup());
|
||||||
setHeaderHidden(true);
|
setHeaderHidden(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void GroupView::expandedChanged(const QModelIndex& index)
|
void GroupView::expandedChanged(const QModelIndex& index)
|
||||||
{
|
{
|
||||||
Group* group = const_cast<Group*>(model->groupFromIndex(index));
|
Group* group = const_cast<Group*>(m_model->groupFromIndex(index));
|
||||||
group->setExpanded(isExpanded(index));
|
group->setExpanded(isExpanded(index));
|
||||||
}
|
}
|
||||||
|
|
||||||
void GroupView::recInitExpanded(const Group* group)
|
void GroupView::recInitExpanded(const Group* group)
|
||||||
{
|
{
|
||||||
QModelIndex index = model->index(group);
|
QModelIndex index = m_model->index(group);
|
||||||
setExpanded(index, group->isExpanded());
|
setExpanded(index, group->isExpanded());
|
||||||
|
|
||||||
Q_FOREACH (const Group* child, group->children()) {
|
Q_FOREACH (const Group* child, group->children()) {
|
||||||
|
@ -38,8 +38,7 @@ private Q_SLOTS:
|
|||||||
private:
|
private:
|
||||||
void recInitExpanded(const Group* group);
|
void recInitExpanded(const Group* group);
|
||||||
|
|
||||||
Database* db;
|
GroupModel* m_model;
|
||||||
GroupModel* model;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // KEEPASSX_GROUPVIEW_H
|
#endif // KEEPASSX_GROUPVIEW_H
|
||||||
|
Loading…
x
Reference in New Issue
Block a user