Wireshark  2.9.0-477-g68ec514b
The Wireshark network protocol analyzer
path_chooser_delegate.h
1 /* path_chooser_delegate.h
2  * Delegate to select a file path for a treeview entry
3  *
4  * Wireshark - Network traffic analyzer
5  * By Gerald Combs <gerald@wireshark.org>
6  * Copyright 1998 Gerald Combs
7  *
8  * SPDX-License-Identifier: GPL-2.0-or-later
9  */
10 
11 #ifndef PATH_CHOOSER_DELEGATE_H_
12 #define PATH_CHOOSER_DELEGATE_H_
13 
14 #include <QStyledItemDelegate>
15 
16 class PathChooserDelegate : public QStyledItemDelegate
17 {
18  Q_OBJECT
19 
20 public:
21  PathChooserDelegate(QObject *parent = 0);
22 
23 protected:
24  QWidget *createEditor(QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &idx) const;
25  void updateEditorGeometry (QWidget * editor, const QStyleOptionViewItem & option, const QModelIndex & idx) const;
26  void setEditorData(QWidget *editor, const QModelIndex &idx) const;
27  void setModelData(QWidget *editor, QAbstractItemModel *model, const QModelIndex &idx) const;
28 
29 private slots:
30  void browse_button_clicked();
31 };
32 
33 #endif /* PATH_CHOOSER_DELEGATE_H_ */
34 
35 /*
36  * Editor modelines
37  *
38  * Local Variables:
39  * c-basic-offset: 4
40  * tab-width: 8
41  * indent-tabs-mode: nil
42  * End:
43  *
44  * ex: set shiftwidth=4 tabstop=8 expandtab:
45  * :indentSize=4:tabSize=8:noTabs=true:
46  */
Definition: path_chooser_delegate.h:16
Definition: pcapng.c:148