aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt/main_window_slots.cpp
diff options
context:
space:
mode:
authorJoerg Mayer <jmayer@loplof.de>2018-06-15 13:21:28 +0200
committerJörg Mayer <jmayer@loplof.de>2018-06-18 16:22:43 +0000
commitf1c410275f94116f729d4302a9d121192e65d1b1 (patch)
tree0a54ddb8aeb3dece84eee48d79ddd41d6169855a /ui/qt/main_window_slots.cpp
parent9ce30360371a320a6d989cf71a121998cd9713b1 (diff)
Get rid of some occurrences of Q_UNUSED
- Trivial by just doing it the C++ way - Non-Trivial where the whole function can be put into the #ifdef instead of the variable use case Change-Id: I034751b8a3c70211173f0c06c954def94450db46 Reviewed-on: https://code.wireshark.org/review/28311 Petri-Dish: Jörg Mayer <jmayer@loplof.de> Tested-by: Petri Dish Buildbot Reviewed-by: Jörg Mayer <jmayer@loplof.de>
Diffstat (limited to 'ui/qt/main_window_slots.cpp')
-rw-r--r--ui/qt/main_window_slots.cpp15
1 files changed, 3 insertions, 12 deletions
diff --git a/ui/qt/main_window_slots.cpp b/ui/qt/main_window_slots.cpp
index 66ddd12417..66f63e804b 100644
--- a/ui/qt/main_window_slots.cpp
+++ b/ui/qt/main_window_slots.cpp
@@ -486,8 +486,8 @@ void MainWindow::queuedFilterAction(QString action_filter, FilterAction::Action
// Capture callbacks
-void MainWindow::captureCapturePrepared(capture_session *) {
#ifdef HAVE_LIBPCAP
+void MainWindow::captureCapturePrepared(capture_session *) {
setTitlebarForCaptureInProgress();
setWindowIcon(wsApp->captureIcon());
@@ -500,11 +500,9 @@ void MainWindow::captureCapturePrepared(capture_session *) {
// /* Don't set up main window for a capture file. */
// main_set_for_capture_file(FALSE);
showCapture();
-#endif // HAVE_LIBPCAP
}
void MainWindow::captureCaptureUpdateStarted(capture_session *session) {
-#ifdef HAVE_LIBPCAP
/* We've done this in "prepared" above, but it will be cleared while
switching to the next multiple file. */
@@ -513,12 +511,9 @@ void MainWindow::captureCaptureUpdateStarted(capture_session *session) {
setForCaptureInProgress(true, session->capture_opts->ifaces);
setForCapturedPackets(true);
-#else
- Q_UNUSED(session)
-#endif // HAVE_LIBPCAP
}
+
void MainWindow::captureCaptureUpdateFinished(capture_session *) {
-#ifdef HAVE_LIBPCAP
/* The capture isn't stopping any more - it's stopped. */
capture_stopping_ = false;
@@ -538,11 +533,9 @@ void MainWindow::captureCaptureUpdateFinished(capture_session *) {
// Don't pop up a dialog to ask for unsaved files etc.
exit(0);
}
-#endif // HAVE_LIBPCAP
}
void MainWindow::captureCaptureFixedFinished(capture_session *) {
-#ifdef HAVE_LIBPCAP
/* The capture isn't stopping any more - it's stopped. */
capture_stopping_ = false;
@@ -562,11 +555,9 @@ void MainWindow::captureCaptureFixedFinished(capture_session *) {
// Don't pop up a dialog to ask for unsaved files etc.
exit(0);
}
-#endif // HAVE_LIBPCAP
}
void MainWindow::captureCaptureFailed(capture_session *) {
-#ifdef HAVE_LIBPCAP
/* Capture isn't stopping any more. */
capture_stopping_ = false;
@@ -584,8 +575,8 @@ void MainWindow::captureCaptureFailed(capture_session *) {
// Don't pop up a dialog to ask for unsaved files etc.
exit(0);
}
-#endif // HAVE_LIBPCAP
}
+#endif // HAVE_LIBPCAP
// Callbacks from cfile.c and file.c via CaptureFile::captureFileCallback