mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#882 RiaApplication : Renamed to lastUsedDialogDirectory and added currentProjectPath. Use project path as fallback path for LAS export
This commit is contained in:
@@ -46,13 +46,13 @@ void RicWellPathsImportFileFeature::onActionTriggered(bool isChecked)
|
||||
{
|
||||
// Open dialog box to select well path files
|
||||
RiaApplication* app = RiaApplication::instance();
|
||||
QString defaultDir = app->defaultFileDialogDirectory("WELLPATH_DIR");
|
||||
QString defaultDir = app->lastUsedDialogDirectory("WELLPATH_DIR");
|
||||
QStringList wellPathFilePaths = QFileDialog::getOpenFileNames(RiuMainWindow::instance(), "Import Well Paths", defaultDir, "Well Paths (*.json *.asc *.asci *.ascii *.dev);;All Files (*.*)");
|
||||
|
||||
if (wellPathFilePaths.size() < 1) return;
|
||||
|
||||
// Remember the path to next time
|
||||
app->setDefaultFileDialogDirectory("WELLPATH_DIR", QFileInfo(wellPathFilePaths.last()).absolutePath());
|
||||
app->setLastUsedDialogDirectory("WELLPATH_DIR", QFileInfo(wellPathFilePaths.last()).absolutePath());
|
||||
|
||||
app->addWellPathsToModel(wellPathFilePaths);
|
||||
if (app->project())
|
||||
|
||||
Reference in New Issue
Block a user