summaryrefslogtreecommitdiff
path: root/ui/qt/rtp_player_dialog.cpp
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2015-10-08 14:56:06 -0700
committerGerald Combs <gerald@wireshark.org>2015-10-09 22:34:30 +0000
commit5bdfb5c36be80511bf814fd6e999985edb75d81d (patch)
tree8fc7ca4578e89e8f27d87e69564d46e0388071af /ui/qt/rtp_player_dialog.cpp
parent626c61c1266ae7b961810dc87c2f75ee409d7c7b (diff)
downloadwireshark-5bdfb5c36be80511bf814fd6e999985edb75d81d.tar.gz
Make sure we can compile without QtMultimedia.
Change-Id: I8db453a735956435fc6e2e4276961adb1f7ed11a Reviewed-on: https://code.wireshark.org/review/10892 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
Diffstat (limited to 'ui/qt/rtp_player_dialog.cpp')
-rw-r--r--ui/qt/rtp_player_dialog.cpp26
1 files changed, 15 insertions, 11 deletions
diff --git a/ui/qt/rtp_player_dialog.cpp b/ui/qt/rtp_player_dialog.cpp
index 1b485df86b..9e0977820e 100644
--- a/ui/qt/rtp_player_dialog.cpp
+++ b/ui/qt/rtp_player_dialog.cpp
@@ -32,7 +32,6 @@
#include "qcustomplot.h"
#include "qt_ui_utils.h"
#include "rtp_audio_stream.h"
-#include "stock_icon.h"
#include "tango_colors.h"
#include <QAudio>
@@ -43,8 +42,13 @@
Q_DECLARE_METATYPE(RtpAudioStream *)
Q_DECLARE_METATYPE(QCPGraph *)
+#else // QT_MULTIMEDIA_LIB
+
+#include <QPushButton>
+
#endif // QT_MULTIMEDIA_LIB
+#include "stock_icon.h"
#include "wireshark_application.h"
// To do:
@@ -159,6 +163,16 @@ RtpPlayerDialog::RtpPlayerDialog(QWidget &parent, CaptureFile &cf) :
#endif // QT_MULTIMEDIA_LIB
}
+QPushButton *RtpPlayerDialog::addPlayerButton(QDialogButtonBox *button_box)
+{
+ if (!button_box) return NULL;
+
+ QPushButton *player_button;
+ player_button = button_box->addButton(tr("Play Streams"), QDialogButtonBox::ApplyRole);
+ player_button->setIcon(StockIcon("media-playback-start"));
+ return player_button;
+}
+
#ifdef QT_MULTIMEDIA_LIB
RtpPlayerDialog::~RtpPlayerDialog()
{
@@ -294,16 +308,6 @@ void RtpPlayerDialog::addRtpStream(struct _rtp_stream_info *rtp_stream)
// RTP_STREAM_DEBUG("adding stream %s to layout, %u packets, start %u", stream_key.toUtf8().constData(), rtp_stream->packet_count, rtp_stream->start_fd->num);
}
-QPushButton *RtpPlayerDialog::addPlayerButton(QDialogButtonBox *button_box)
-{
- if (!button_box) return NULL;
-
- QPushButton *player_button;
- player_button = button_box->addButton(tr("Play Streams"), QDialogButtonBox::ApplyRole);
- player_button->setIcon(StockIcon("media-playback-start"));
- return player_button;
-}
-
void RtpPlayerDialog::showEvent(QShowEvent *)
{
QList<int> split_sizes = ui->splitter->sizes();