Skip to content

Commit d1ed2d1

Browse files
committed
Update the recordset label in the Browse tab after closing a DB
Reset the recordset label in the Browse Data tab of the main window after closing a DB file. See issue sqlitebrowser#44.
1 parent a7110ea commit d1ed2d1

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/MainWindow.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -361,6 +361,14 @@ void MainWindow::fileClose()
361361
resetBrowser();
362362
populateStructure();
363363
loadPragmas();
364+
365+
// Delete the model for the Browse tab and create a new one
366+
delete m_browseTableModel;
367+
m_browseTableModel = new SqliteTableModel(this, &db, PreferencesDialog::getSettingsValue("db", "prefetchsize").toInt());
368+
369+
// Manually update the recordset label inside the Browse tab now
370+
setRecordsetLabel();
371+
364372
activateFields(false);
365373
ui->buttonLogClear->click();
366374
for(int i=ui->tabSqlAreas->count()-1;i>=0;i--)

0 commit comments

Comments
 (0)