Commit 1181f464 authored by Ludovic Fauvet's avatar Ludovic Fauvet
Browse files

Add support for pause and stop in the media.

parent 273057c5
......@@ -126,3 +126,13 @@ void InputMedia::play()
{
Media::play();
}
void InputMedia::pause()
{
Media::pause();
}
void InputMedia::stop()
{
Media::stop();
}
......@@ -65,6 +65,8 @@ public:
QImage& getImage();
virtual void play();
virtual void pause();
virtual void stop();
void setDrawable( WId handle );
private:
......
......@@ -27,7 +27,7 @@ Media::Media(LibVLCpp::Instance* instance, const QString& mrl )
: m_instance( NULL ), m_vlcMedia( NULL ), m_vlcMediaPlayer( NULL ),
m_mrl( mrl ), m_instanceOwned( false )
{
if ( instance == NULL )
if ( !instance )
{
char const *vlc_argv[] =
{
......@@ -92,7 +92,7 @@ void Media::setupMedia()
void Media::play()
{
if ( m_vlcMediaPlayer == NULL )
if ( !m_vlcMediaPlayer )
setupMedia();
m_vlcMediaPlayer->play();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment