Skip to content
Snippets Groups Projects
Commit de4d6d51 authored by Steve Lhomme's avatar Steve Lhomme Committed by Hugo Beauzée-Luyssen
Browse files

QtPlayer example: fix compilation with newer Qt/libvlc


Cherry-picked from 0ade21ad, with the
libvlc 4.0 part removed.

Signed-off-by: default avatarAlexandre Janniaux <alexandre.janniaux@gmail.com>
parent e69264f8
No related branches found
No related tags found
2 merge requests!3533Backport MR 3236 to 3.0.x,!896QtPlayer example: backport patches from master
......@@ -11,6 +11,12 @@
#define qtu( i ) ((i).toUtf8().constData())
#include <QtGui>
#include <QMessageBox>
#include <QMenuBar>
#include <QAction>
#include <QHBoxLayout>
#include <QVBoxLayout>
#include <QFileDialog>
Mwindow::Mwindow() {
vlcPlayer = NULL;
......@@ -142,7 +148,7 @@ void Mwindow::openFile() {
#elif defined(Q_OS_UNIX)
libvlc_media_player_set_xwindow(vlcPlayer, videoWidget->winId());
#elif defined(Q_OS_WIN)
libvlc_media_player_set_hwnd(vlcPlayer, videoWidget->winId());
libvlc_media_player_set_hwnd(vlcPlayer, (HWND)videoWidget->winId());
#endif
/* And start playback */
......
......@@ -9,6 +9,10 @@
#define PLAYER
#include <QtGui>
#include <QMainWindow>
#include <QPushButton>
#include <QSlider>
#include <QWidget>
#include <vlc/vlc.h>
class Mwindow : public QMainWindow {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment