mirror of
https://github.com/sqlitebrowser/sqlitebrowser.git
synced 2026-01-20 02:50:46 -06:00
Simplify code
This commit is contained in:
@@ -124,11 +124,8 @@ void DbStructureModel::reloadData()
|
||||
beginResetModel();
|
||||
|
||||
// Remove all data except for the root item
|
||||
for(int i=rootItem->childCount();i;i--)
|
||||
{
|
||||
delete rootItem->child(i-1);
|
||||
rootItem->removeChild(rootItem->child(i-1));
|
||||
}
|
||||
while(rootItem->childCount())
|
||||
delete rootItem->child(0);
|
||||
|
||||
// Return here if no DB is opened
|
||||
if(!m_db.isOpen())
|
||||
|
||||
Reference in New Issue
Block a user