summaryrefslogtreecommitdiffstats
path: root/ui/qt/widgets/path_selection_edit.cpp
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-09-19 04:14:53 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-09-19 04:14:53 +0000
commita86c5f7cae7ec9a3398300555a0b644689d946a1 (patch)
tree39fe4b107c71174fd1e8a8ceb9a4d2aa14116248 /ui/qt/widgets/path_selection_edit.cpp
parentReleasing progress-linux version 4.2.6-1~progress7.99u1. (diff)
downloadwireshark-a86c5f7cae7ec9a3398300555a0b644689d946a1.tar.xz
wireshark-a86c5f7cae7ec9a3398300555a0b644689d946a1.zip
Merging upstream version 4.4.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'ui/qt/widgets/path_selection_edit.cpp')
-rw-r--r--ui/qt/widgets/path_selection_edit.cpp12
1 files changed, 4 insertions, 8 deletions
diff --git a/ui/qt/widgets/path_selection_edit.cpp b/ui/qt/widgets/path_selection_edit.cpp
index eb30f1d0..660a6f53 100644
--- a/ui/qt/widgets/path_selection_edit.cpp
+++ b/ui/qt/widgets/path_selection_edit.cpp
@@ -10,18 +10,18 @@
#include "config.h"
-#include "epan/prefs.h"
#include "ui/util.h"
#include <ui/qt/widgets/path_selection_edit.h>
#include "ui/qt/widgets/wireshark_file_dialog.h"
+#include "ui/qt/utils/qt_ui_utils.h"
#include <QHBoxLayout>
#include <QToolButton>
#include <QWidget>
#include <QLineEdit>
-PathSelectionEdit::PathSelectionEdit(QString title, QString path, bool selectFile, QWidget *parent) :
+PathSelectionEdit::PathSelectionEdit(QString title, QString path, bool selectFile, QWidget *parent) :
QWidget(parent)
{
_title = title;
@@ -49,7 +49,7 @@ PathSelectionEdit::PathSelectionEdit(QString title, QString path, bool selectFil
setFocusPolicy(_edit->focusPolicy());
}
-PathSelectionEdit::PathSelectionEdit(QWidget *parent) :
+PathSelectionEdit::PathSelectionEdit(QWidget *parent) :
PathSelectionEdit(tr("Select a path"), QString(), true, parent)
{}
@@ -75,11 +75,7 @@ void PathSelectionEdit::browseForPath()
QString openDir = _path;
if (openDir.isEmpty()) {
- if (prefs.gui_fileopen_style == FO_STYLE_LAST_OPENED) {
- openDir = QString(get_open_dialog_initial_dir());
- } else if (prefs.gui_fileopen_style == FO_STYLE_SPECIFIED) {
- openDir = QString(prefs.gui_fileopen_dir);
- }
+ openDir = openDialogInitialDir();
}
QString newPath;