mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Replace mainWindow() with MainWindow::instance()
C++ style of accessing single instance class object. Signed-off-by: Boris Barbulovski <bbarbulovski@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
cc37d2e94a
commit
c86822c2f4
18 changed files with 104 additions and 96 deletions
|
@ -68,7 +68,7 @@ void DiveLogImportDialog::on_buttonBox_accepted()
|
|||
specialCSV.contains(ui->knownImports->currentIndex()) ? CSVApps[ui->knownImports->currentIndex()].name.toUtf8().data() : "csv",
|
||||
&error);
|
||||
if (error != NULL) {
|
||||
mainWindow()->showError(error);
|
||||
MainWindow::instance()->showError(error);
|
||||
free(error);
|
||||
error = NULL;
|
||||
}
|
||||
|
@ -87,7 +87,7 @@ void DiveLogImportDialog::on_buttonBox_accepted()
|
|||
VALUE_IF_CHECKED(Tags),
|
||||
&error);
|
||||
if (error != NULL) {
|
||||
mainWindow()->showError(error);
|
||||
MainWindow::instance()->showError(error);
|
||||
free(error);
|
||||
error = NULL;
|
||||
}
|
||||
|
@ -95,7 +95,7 @@ void DiveLogImportDialog::on_buttonBox_accepted()
|
|||
}
|
||||
process_dives(true, false);
|
||||
|
||||
mainWindow()->refreshDisplay();
|
||||
MainWindow::instance()->refreshDisplay();
|
||||
}
|
||||
|
||||
#define SET_VALUE_AND_CHECKBOX(CSV, BOX, VAL) ({\
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue