update epan/dissectors/pidl/drsuapi/drsuapi.idl from samba
[wireshark-sm.git] / ui / qt / utils / profile_switcher.h
blob2b7b7548621faf0ce24dc5b62b8a3934d4a1feb2
1 /** @file
3 * Wireshark - Network traffic analyzer
4 * By Gerald Combs <gerald@wireshark.org>
5 * Copyright 1998 Gerald Combs
7 * SPDX-License-Identifier: GPL-2.0-or-later
8 */
10 #pragma once
12 #include <config.h>
14 #include "capture_event.h"
15 #include "cfile.h"
17 #include <QObject>
18 #include <QVector>
20 struct profile_switch_filter {
21 QString name;
22 dfilter_t *dfcode;
25 class PacketListModel;
27 class ProfileSwitcher : public QObject
29 Q_OBJECT
30 public:
31 explicit ProfileSwitcher(QObject *parent = nullptr);
33 public slots:
34 void captureEventHandler(CaptureEvent ev);
35 void checkPacket(capture_file *cap_file, frame_data *fdata, qsizetype row);
37 private:
38 QVector<struct profile_switch_filter> profile_filters_;
39 bool capture_file_changed_;
40 bool profile_changed_;
41 QString previous_cap_file_;
43 void clearProfileFilters();
45 private slots:
46 void disableSwitching();