mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-10-01 01:26:01 -04:00
Disconnect entry from database, when removed.
This commit is contained in:
parent
89f138a868
commit
34204f3281
@ -323,6 +323,7 @@ void Group::removeEntry(Entry* entry)
|
||||
Q_EMIT entryAboutToRemove(entry);
|
||||
|
||||
entry->disconnect(this);
|
||||
entry->disconnect(m_db);
|
||||
m_entries.removeAll(entry);
|
||||
Q_EMIT modified();
|
||||
Q_EMIT entryRemoved();
|
||||
|
@ -88,6 +88,11 @@ void TestModified::testSignals()
|
||||
QCOMPARE(spyModified.count(), spyCount);
|
||||
QCOMPARE(spyModified2.count(), spyCount2);
|
||||
|
||||
entry2->setTitle("test2");
|
||||
spyCount2++;
|
||||
QCOMPARE(spyModified.count(), spyCount);
|
||||
QCOMPARE(spyModified2.count(), spyCount2);
|
||||
|
||||
Group* g3 = new Group();
|
||||
g3->setParent(root);
|
||||
spyCount++;
|
||||
|
Loading…
Reference in New Issue
Block a user