aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt/manage_interfaces_dialog.cpp
diff options
context:
space:
mode:
authorDario Lombardo <lomato@gmail.com>2017-08-14 23:08:56 +0200
committerAnders Broman <a.broman58@gmail.com>2017-08-15 14:44:11 +0000
commitbc9bf64f8dc7053ebe3ae75152472d7149e077ce (patch)
treeb7856e94faa6157ea6926c5dcf1f88810eca35f6 /ui/qt/manage_interfaces_dialog.cpp
parent35f9349396d4dfbcccdf977cf9d7f3096df5aa0e (diff)
Qt: fix compilation without pcap.
Change-Id: Ib8d21d63730ea6e18032b89ba0042ee7521645a8 Reviewed-on: https://code.wireshark.org/review/23078 Reviewed-by: Michael Mann <mmann78@netscape.net> Petri-Dish: Dario Lombardo <lomato@gmail.com> Tested-by: Dario Lombardo <lomato@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'ui/qt/manage_interfaces_dialog.cpp')
-rw-r--r--ui/qt/manage_interfaces_dialog.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/ui/qt/manage_interfaces_dialog.cpp b/ui/qt/manage_interfaces_dialog.cpp
index 02a45e4713..6e7714eb73 100644
--- a/ui/qt/manage_interfaces_dialog.cpp
+++ b/ui/qt/manage_interfaces_dialog.cpp
@@ -45,8 +45,6 @@
#include <QDebug>
-#ifdef HAVE_LIBPCAP
-
#include "ui/capture_ui_utils.h"
#include <ui/qt/models/path_chooser_delegate.h>
@@ -211,7 +209,9 @@ void ManageInterfacesDialog::updateWidgets()
void ManageInterfacesDialog::on_buttonBox_accepted()
{
+#ifdef HAVE_LIBPCAP
sourceModel->save();
+#endif
#ifdef HAVE_PCAP_REMOTE
remoteAccepted();
#endif
@@ -220,6 +220,7 @@ void ManageInterfacesDialog::on_buttonBox_accepted()
emit ifsChanged();
}
+#ifdef HAVE_LIBPCAP
void ManageInterfacesDialog::on_addPipe_clicked()
{
interface_t device;
@@ -241,6 +242,7 @@ void ManageInterfacesDialog::on_addPipe_clicked()
device.if_info.type = IF_PIPE;
sourceModel->addDevice(&device);
+
updateWidgets();
}
@@ -254,6 +256,7 @@ void ManageInterfacesDialog::on_delPipe_clicked()
sourceModel->deleteDevice( pipeProxyModel->mapToSource(selIndex) );
updateWidgets();
}
+#endif
void ManageInterfacesDialog::on_buttonBox_helpRequested()
{
@@ -575,8 +578,6 @@ void ManageInterfacesDialog::setRemoteSettings(interface_t *iface)
}
#endif // HAVE_PCAP_REMOTE
-#endif /* HAVE_LIBPCAP */
-
/*
* Editor modelines
*