Hello community,

here is the log from the commit of package phonon4qt5-backend-vlc for 
openSUSE:Factory checked in at 2016-05-19 12:14:48
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/phonon4qt5-backend-vlc (Old)
 and      /work/SRC/openSUSE:Factory/.phonon4qt5-backend-vlc.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "phonon4qt5-backend-vlc"

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/phonon4qt5-backend-vlc/phonon4qt5-backend-vlc.changes
    2016-04-06 11:52:40.000000000 +0200
+++ 
/work/SRC/openSUSE:Factory/.phonon4qt5-backend-vlc.new/phonon4qt5-backend-vlc.changes
       2016-05-19 12:14:49.000000000 +0200
@@ -1,0 +2,14 @@
+Mon May  9 09:00:02 UTC 2016 - wba...@tmo.at
+
+- Added fix-build-with-older-phonon.patch to fix building against
+  older phonon versions
+- Also change required phonon4qt5 version back to 4.7.0, it doesn't
+  need a higher one to build successfully
+
+-------------------------------------------------------------------
+Tue Apr 19 20:41:03 UTC 2016 - hrvoje.sen...@gmail.com
+
+- Update to 0.9.0
+  * No changelog provided
+
+-------------------------------------------------------------------

Old:
----
  phonon-backend-vlc-0.8.2.tar.xz

New:
----
  fix-build-with-older-phonon.patch
  phonon-backend-vlc-0.9.0.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ phonon4qt5-backend-vlc.spec ++++++
--- /var/tmp/diff_new_pack.YviMGk/_old  2016-05-19 12:14:49.000000000 +0200
+++ /var/tmp/diff_new_pack.YviMGk/_new  2016-05-19 12:14:49.000000000 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package phonon4qt5-backend-vlc
 #
-# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,15 +17,17 @@
 
 
 Name:           phonon4qt5-backend-vlc
-Version:        0.8.2
+Version:        0.9.0
 Release:        0
 Summary:        Phonon VLC Backend
 License:        LGPL-2.1+
 Group:          Development/Libraries/KDE
 Url:            http://phonon.kde.org/
 %define filename phonon-backend-vlc
-%define _phonon4qt5_version 4.8.2
-Source:         
http://download.kde.org/stable/phonon/%{filename}/%{version}/src/%{filename}-%{version}.tar.xz
+%define _phonon4qt5_version 4.7.0
+Source:         
http://download.kde.org/stable/phonon/%{filename}/%{version}/%{filename}-%{version}.tar.xz
+# PATCH-FIX-UPSTREAM fix-build-with-older-phonon.patch -- Fix build against 
older phonon versions
+Patch:          fix-build-with-older-phonon.patch
 BuildRequires:  alsa-devel
 BuildRequires:  cmake
 BuildRequires:  kf5-filesystem
@@ -50,7 +52,8 @@
 This is the VLC backend for Phonon
 
 %prep
-%setup -q -n %{filename}-%{version}
+%setup -q -n phonon-vlc-%{version}
+%patch -p1
 
 %build
   %cmake_kf5 -d build -- -DPHONON_BUILD_PHONON4QT5=ON

++++++ fix-build-with-older-phonon.patch ++++++
From: Wolfgang Bauer <wba...@tmo.at>
Date: Mon, 09 May 2016 08:45:47 +0000
Subject: Fix build against older phonon versions
X-Git-Url: 
http://quickgit.kde.org/?p=phonon-vlc.git&a=commitdiff&h=340fd9f9dbbb3b4be7a949bbb7e8f74cded6879c
---
Fix build against older phonon versions

Commit 4d6bdb0 introduced a new AudioOutput::setMuted() method for
Phonon 4.9.
While the declaration is conditional in the header file, there is no
version check for the implementation. This broke the build with
Phonon < 4.8.50.

So make the implementation conditional as well, to make phonon-vlc build
fine again with older Phonon versions.

REVIEW: 127858
---


--- a/src/audio/audiooutput.cpp
+++ b/src/audio/audiooutput.cpp
@@ -86,6 +86,7 @@
     }
 }
 
+#if (PHONON_VERSION >= PHONON_VERSION_CHECK(4, 8, 50))
 void AudioOutput::setMuted(bool mute)
 {
     if (mute == m_player->mute()) {
@@ -95,6 +96,7 @@
     }
     m_player->setMute(mute);
 }
+#endif
 
 int AudioOutput::outputDevice() const
 {

++++++ phonon-backend-vlc-0.8.2.tar.xz -> phonon-backend-vlc-0.9.0.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/.gitignore 
new/phonon-vlc-0.9.0/.gitignore
--- old/phonon-backend-vlc-0.8.2/.gitignore     1970-01-01 01:00:00.000000000 
+0100
+++ new/phonon-vlc-0.9.0/.gitignore     2016-04-18 06:25:24.000000000 +0200
@@ -0,0 +1,12 @@
+.svn
+Makefile
+CMakeTmp
+CMakeCache.txt
+CMakeFiles/
+cmake_install.cmake
+cmake_uninstall.cmake
+lib/
+*.o
+*.so
+*.user
+build
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/.krazy 
new/phonon-vlc-0.9.0/.krazy
--- old/phonon-backend-vlc-0.8.2/.krazy 1970-01-01 01:00:00.000000000 +0100
+++ new/phonon-vlc-0.9.0/.krazy 2016-04-18 06:25:24.000000000 +0200
@@ -0,0 +1,2 @@
+SKIP /build
+SKIP /src/vlc.desktop.cmake
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/CMakeLists.txt 
new/phonon-vlc-0.9.0/CMakeLists.txt
--- old/phonon-backend-vlc-0.8.2/CMakeLists.txt 2014-12-04 10:29:23.000000000 
+0100
+++ new/phonon-vlc-0.9.0/CMakeLists.txt 2016-04-18 06:25:24.000000000 +0200
@@ -1,6 +1,6 @@
+cmake_minimum_required(VERSION 2.8.9)
 project(PhononVLC)
 
-cmake_minimum_required(VERSION 2.6.2 FATAL_ERROR)
 set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
 
 # Phonon
@@ -10,8 +10,8 @@
 
 # LibVLC
 find_package(LIBVLC REQUIRED)
-macro_ensure_version("2.0.1" ${LIBVLC_VERSION} LIBVLC_FOUND)
-macro_log_feature(LIBVLC_FOUND "LibVLC" "VLC C API Library" 
"git://git.videolan.org/vlc.git" TRUE "2.0.1")
+macro_ensure_version("2.1.0" ${LIBVLC_VERSION} LIBVLC_FOUND)
+macro_log_feature(LIBVLC_FOUND "LibVLC" "VLC C API Library" 
"git://git.videolan.org/vlc.git" TRUE "2.1.0")
 
 if(PHONON_FOUND_EXPERIMENTAL)
   add_definitions(-DPHONON_EXPERIMENTAL)
@@ -24,8 +24,8 @@
 include_directories(${PHONON_INCLUDES} ${QT_INCLUDES} ${LIBVLC_INCLUDE_DIR} 
${LIBVLC_INCLUDE_DIR}/vlc/plugins)
 
 set(PHONON_VLC_MAJOR_VERSION "0")
-set(PHONON_VLC_MINOR_VERSION "8")
-set(PHONON_VLC_PATCH_VERSION "2")
+set(PHONON_VLC_MINOR_VERSION "9")
+set(PHONON_VLC_PATCH_VERSION "0")
 set(PHONON_VLC_VERSION 
"${PHONON_VLC_MAJOR_VERSION}.${PHONON_VLC_MINOR_VERSION}.${PHONON_VLC_PATCH_VERSION}")
 add_definitions(-DPHONON_VLC_VERSION="${PHONON_VLC_VERSION}")
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/.gitignore 
new/phonon-vlc-0.9.0/src/.gitignore
--- old/phonon-backend-vlc-0.8.2/src/.gitignore 1970-01-01 01:00:00.000000000 
+0100
+++ new/phonon-vlc-0.9.0/src/.gitignore 2016-04-18 06:25:24.000000000 +0200
@@ -0,0 +1,4 @@
+.svn
+Makefile
+moc_*
+phonon_vlc_*
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/CMakeLists.txt 
new/phonon-vlc-0.9.0/src/CMakeLists.txt
--- old/phonon-backend-vlc-0.8.2/src/CMakeLists.txt     2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/CMakeLists.txt     2016-04-18 06:25:24.000000000 
+0200
@@ -18,7 +18,10 @@
         endif (KDEWIN_FOUND)
 endif (MSVC OR (WIN32 AND "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Intel"))
 
-if(${PHONON_VERSION} VERSION_GREATER "4.6.49") # Pre-release 4.7 starts at 
4.6.50
+if(${PHONON_VERSION} VERSION_GREATER "4.8.50")
+    message(STATUS "Building against Phonon 4.9 API")
+    set(BACKEND_VERSION_DEFINE -DPHONON_BACKEND_VERSION_4_9)
+elseif(${PHONON_VERSION} VERSION_GREATER "4.6.50")
     message(STATUS "Building against Phonon 4.7 API")
     set(BACKEND_VERSION_DEFINE -DPHONON_BACKEND_VERSION_4_7)
 elseif(${PHONON_VERSION} VERSION_GREATER "4.1.99")
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/audio/audiooutput.cpp 
new/phonon-vlc-0.9.0/src/audio/audiooutput.cpp
--- old/phonon-backend-vlc-0.8.2/src/audio/audiooutput.cpp      2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/audio/audiooutput.cpp      2016-04-18 
06:25:24.000000000 +0200
@@ -2,7 +2,7 @@
     Copyright (C) 2007-2008 Tanguy Krotoff <tkrot...@gmail.com>
     Copyright (C) 2008 Lukas Durfina <lukas.durf...@gmail.com>
     Copyright (C) 2009 Fathi Boudra <f...@kde.org>
-    Copyright (C) 2013 Harald Sitter <sit...@kde.org>
+    Copyright (C) 2013-2015 Harald Sitter <sit...@kde.org>
 
     This library is free software; you can redistribute it and/or
     modify it under the terms of the GNU Lesser General Public
@@ -36,6 +36,7 @@
 AudioOutput::AudioOutput(QObject *parent)
     : QObject(parent),
       m_volume(1.0)
+    , m_muted(false)
 {
 }
 
@@ -47,8 +48,13 @@
 {
     Q_UNUSED(mediaObject);
     setOutputDeviceImplementation();
-    if (!PulseSupport::getInstance()->isActive())
+    if (!PulseSupport::getInstance()->isActive()) {
+        connect(m_player, SIGNAL(mutedChanged(bool)),
+                this, SLOT(onMutedChanged(bool)));
+        connect(m_player, SIGNAL(volumeChanged(float)),
+                this, SLOT(onVolumeChanged(float)));
         applyVolume();
+    }
 }
 
 void AudioOutput::handleAddToMedia(Media *media)
@@ -73,10 +79,23 @@
         debug() << "async setting of volume to" << volume;
         m_volume = volume;
         applyVolume();
+
+#if (LIBVLC_VERSION_INT < LIBVLC_VERSION(2, 2, 2, 0))
         emit volumeChanged(m_volume);
+#endif
     }
 }
 
+void AudioOutput::setMuted(bool mute)
+{
+    if (mute == m_player->mute()) {
+        // Make sure we actually have propagated the mutness into the frontend.
+        onMutedChanged(mute);
+        return;
+    }
+    m_player->setMute(mute);
+}
+
 int AudioOutput::outputDevice() const
 {
     return m_device.index();
@@ -177,9 +196,31 @@
         const int newVolume = m_volume * 100;
         m_player->setAudioVolume(newVolume);
 
+#if (LIBVLC_VERSION_INT < LIBVLC_VERSION(2, 2, 2, 0))
+        onMutedChanged(m_volume == 0.0);
+        onVolumeChanged(newVolume);
+#endif
+
         debug() << "Volume changed from" << preVolume << "to" << newVolume;
     }
 }
 
+void AudioOutput::onMutedChanged(bool mute)
+{
+    m_muted = mute;
+    emit mutedChanged(mute);
+#if (PHONON_VERSION < PHONON_VERSION_CHECK(4, 8, 51))
+    // Previously we had no interface signal to communicate mutness, so instead
+    // emit volume.
+    mute ? emit volumeChanged(0.0) : emit volumeChanged(volume());
+#endif
+}
+
+void AudioOutput::onVolumeChanged(float volume)
+{
+    m_volume = volume;
+    emit volumeChanged(volume);
+}
+
 }
 } // Namespace Phonon::VLC
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/audio/audiooutput.h 
new/phonon-vlc-0.9.0/src/audio/audiooutput.h
--- old/phonon-backend-vlc-0.8.2/src/audio/audiooutput.h        2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/audio/audiooutput.h        2016-04-18 
06:25:24.000000000 +0200
@@ -102,9 +102,14 @@
     void setStreamUuid(QString uuid);
 #endif
 
+#if (PHONON_VERSION >= PHONON_VERSION_CHECK(4, 8, 50))
+    void setMuted(bool mute);
+#endif
+
 signals:
     void volumeChanged(qreal volume);
     void audioDeviceFailed();
+    void mutedChanged(bool mute);
 
 private slots:
     /**
@@ -112,6 +117,9 @@
      */
     void applyVolume();
 
+    void onMutedChanged(bool mute);
+    void onVolumeChanged(float volume);
+
 private:
     /**
      * We can only really set the output device once we have a 
libvlc_media_player, which comes
@@ -120,6 +128,7 @@
     void setOutputDeviceImplementation();
 
     qreal m_volume;
+    bool m_muted;
     AudioOutputDevice m_device;
     QString m_streamUuid;
 };
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/backend.cpp 
new/phonon-vlc-0.9.0/src/backend.cpp
--- old/phonon-backend-vlc-0.8.2/src/backend.cpp        2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/backend.cpp        2016-04-18 06:25:24.000000000 
+0200
@@ -103,7 +103,7 @@
             qWarning("WARNING: Setting the user agent for streaming and"
                      " PulseAudio requires you to set 
QCoreApplication::applicationName()");
         }
-#if (LIBVLC_VERSION_INT >= LIBVLC_VERSION(2, 1, 0, 0))
+
         PulseSupport::getInstance()->enable(true);
         const bool pulseActive = PulseSupport::getInstance()->isActive();
         PulseSupport::getInstance()->enable(false);
@@ -131,8 +131,6 @@
                      " QCoreApplication::applicationVersion() and"
                      " QGuiApplication::windowIcon().");
         }
-
-#endif
     } else {
 #ifdef __GNUC__
     #warning TODO - this error message is as useful as a knife at a gun fight
@@ -151,7 +149,7 @@
 
     // Initialise PulseAudio support
     PulseSupport *pulse = PulseSupport::getInstance();
-#if (LIBVLC_VERSION_INT >= LIBVLC_VERSION(2, 2, 0, 0))
+#if (LIBVLC_VERSION_INT < LIBVLC_VERSION(2, 2, 2, 0))
     // VLC 2.2 changed the stream creation order around internally which breaks
     // the Pulseaudio hijacking. Since VLC upstream doesn't feel like giving us
     // any more property control we now consider this feature unsupported. As
@@ -159,8 +157,6 @@
     pulse->enable(true);
     connect(pulse, SIGNAL(objectDescriptionChanged(ObjectDescriptionType)),
             SIGNAL(objectDescriptionChanged(ObjectDescriptionType)));
-#else
-    pulse->enable(false);
 #endif
 
     m_deviceManager = new DeviceManager(this);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/devicemanager.cpp 
new/phonon-vlc-0.9.0/src/devicemanager.cpp
--- old/phonon-backend-vlc-0.8.2/src/devicemanager.cpp  2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/devicemanager.cpp  2016-04-18 06:25:24.000000000 
+0200
@@ -209,12 +209,19 @@
     QList<QByteArray> audioOutBackends = vlcAudioOutBackends();
 
     PulseSupport *pulse = PulseSupport::getInstance();
+#if (PHONON_VERSION < PHONON_VERSION_CHECK(4, 8, 51))
     if (pulse && pulse->isActive()) {
+#else
+    if (pulse && pulse->isUsable()) {
+#endif
         if (audioOutBackends.contains("pulse")) {
             DeviceInfo defaultAudioOutputDevice(tr("Default"), false);
             defaultAudioOutputDevice.setCapabilities(DeviceInfo::AudioOutput);
             defaultAudioOutputDevice.addAccess(DeviceAccess("pulse", 
"default"));
             newDeviceList.append(defaultAudioOutputDevice);
+#if (PHONON_VERSION >= PHONON_VERSION_CHECK(4, 8, 51))
+            pulse->request(true);
+#endif
             return;
         } else {
             pulse->enable(false);
@@ -239,6 +246,35 @@
             continue;
         }
 
+        // FIXME: there is a rather ungodly amount of code duplication going
+        //        on here.
+#if (LIBVLC_VERSION_INT >= LIBVLC_VERSION(2, 2, 0, 0))
+        bool hasDevices = false;
+        VLC_FOREACH(audio_output_device,
+                    device,
+                    libvlc_audio_output_device_list_get(libvlc, soundSystem),
+                    libvlc_audio_output_device_list_release) {
+            QString idName = QString::fromUtf8(device->psz_device);
+            QString longName = QString::fromUtf8(device->psz_description);
+
+            debug() << "found device" << soundSystem << idName << longName;
+
+            DeviceInfo info(longName, true);
+            info.addAccess(DeviceAccess(soundSystem, idName));
+            info.setCapabilities(DeviceInfo::AudioOutput);
+            newDeviceList.append(info);
+
+            hasDevices = true;
+        }
+
+        if (!hasDevices) {
+            debug() << "manually injecting sound system" << soundSystem;
+            DeviceInfo info(QString::fromUtf8(soundSystem), false);
+            info.addAccess(DeviceAccess(soundSystem, ""));
+            info.setCapabilities(DeviceInfo::AudioOutput);
+            newDeviceList.append(info);
+        }
+#else
         const int deviceCount = libvlc_audio_output_device_count(libvlc, 
soundSystem);
 
         for (int i = 0; i < deviceCount; i++) {
@@ -247,10 +283,10 @@
 
             debug() << "found device" << soundSystem << idName << longName;
 
-            DeviceInfo device(longName, true);
-            device.addAccess(DeviceAccess(soundSystem, idName));
-            device.setCapabilities(DeviceInfo::AudioOutput);
-            newDeviceList.append(device);
+            DeviceInfo info(longName, true);
+            info.addAccess(DeviceAccess(soundSystem, idName));
+            info.setCapabilities(DeviceInfo::AudioOutput);
+            newDeviceList.append(info);
         }
 
         // libVLC gives no devices for some sound systems, like OSS
@@ -261,11 +297,12 @@
             //       selection which on systems such as OSX or Windows can
             //       lead to an empty device list as the injected device is
             //       the only available one.
-            DeviceInfo device(QString::fromUtf8(soundSystem), false);
-            device.addAccess(DeviceAccess(soundSystem, ""));
-            device.setCapabilities(DeviceInfo::AudioOutput);
-            newDeviceList.append(device);
+            DeviceInfo info(QString::fromUtf8(soundSystem), false);
+            info.addAccess(DeviceAccess(soundSystem, ""));
+            info.setCapabilities(DeviceInfo::AudioOutput);
+            newDeviceList.append(info);
         }
+#endif
     }
 
     /*
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/mediaobject.cpp 
new/phonon-vlc-0.9.0/src/mediaobject.cpp
--- old/phonon-backend-vlc-0.8.2/src/mediaobject.cpp    2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/mediaobject.cpp    2016-04-18 06:25:24.000000000 
+0200
@@ -4,7 +4,7 @@
     Copyright (C) 2009 Fathi Boudra <f...@kde.org>
     Copyright (C) 2010 Ben Cooksley <sourto...@gmail.com>
     Copyright (C) 2009-2011 vlc-phonon AUTHORS <kde-multime...@kde.org>
-    Copyright (C) 2010-2011 Harald Sitter <sit...@kde.org>
+    Copyright (C) 2010-2015 Harald Sitter <sit...@kde.org>
 
     This library is free software; you can redistribute it and/or
     modify it under the terms of the GNU Lesser General Public
@@ -319,8 +319,11 @@
     case MediaSource::Url:
         debug() << "MediaSource::Url:" << source.url();
         if (source.url().scheme().isEmpty()) {
-            url = "file:///";
-            if (source.url().isRelative())
+            url = "file://";
+            // QUrl considers url.scheme.isEmpty() == url.isRelative(), 
+            // so to be sure the url is not actually absolute we just
+            // check the first character
+            if (!source.url().toString().startsWith('/'))
                 url.append(QFile::encodeName(QDir::currentPath()) + '/');
         }
         url += source.url().toEncoded();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/mediaplayer.cpp 
new/phonon-vlc-0.9.0/src/mediaplayer.cpp
--- old/phonon-backend-vlc-0.8.2/src/mediaplayer.cpp    2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/mediaplayer.cpp    2016-04-18 06:25:24.000000000 
+0200
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2011-2012 Harald Sitter <sit...@kde.org>
+    Copyright (C) 2011-2015 Harald Sitter <sit...@kde.org>
 
     This library is free software; you can redistribute it and/or
     modify it under the terms of the GNU Lesser General Public
@@ -80,6 +80,13 @@
         libvlc_MediaPlayerSnapshotTaken,
         libvlc_MediaPlayerLengthChanged,
         libvlc_MediaPlayerVout
+    #if (LIBVLC_VERSION_INT >= LIBVLC_VERSION(2, 2, 2, 0))
+        , libvlc_MediaPlayerCorked,
+        libvlc_MediaPlayerUncorked,
+        libvlc_MediaPlayerMuted,
+        libvlc_MediaPlayerUnmuted,
+        libvlc_MediaPlayerAudioVolume
+    #endif
     };
     const int eventCount = sizeof(events) / sizeof(*events);
     for (int i = 0; i < eventCount; ++i) {
@@ -89,9 +96,7 @@
     // Deactivate video title overlay (i.e. name of the video displaying
     // at start. Since 2.1 that is handled via the API which in general is more
     // reliable than setting it via libvlc_new (or so I have been told....)
-#if (LIBVLC_VERSION_INT >= LIBVLC_VERSION(2, 1, 0, 0))
     libvlc_media_player_set_video_title_display(m_player, 
libvlc_position_disable, 0);
-#endif
 }
 
 MediaPlayer::~MediaPlayer()
@@ -279,6 +284,32 @@
         break;
     case libvlc_MediaPlayerMediaChanged:
         break;
+#if (LIBVLC_VERSION_INT >= LIBVLC_VERSION(2, 2, 2, 0))
+    case libvlc_MediaPlayerCorked:
+        that->pause();
+        break;
+    case libvlc_MediaPlayerUncorked:
+        that->play();
+        break;
+    case libvlc_MediaPlayerMuted:
+        QMetaObject::invokeMethod(
+                    that, "mutedChanged",
+                    Qt::QueuedConnection,
+                    Q_ARG(bool, true));
+        break;
+    case libvlc_MediaPlayerUnmuted:
+        QMetaObject::invokeMethod(
+                    that, "mutedChanged",
+                    Qt::QueuedConnection,
+                    Q_ARG(bool, false));
+        break;
+    case libvlc_MediaPlayerAudioVolume:
+        QMetaObject::invokeMethod(
+                    that, "volumeChanged",
+                    Qt::QueuedConnection,
+                    Q_ARG(float, event->u.media_player_audio_volume.volume));
+        break;
+#endif
     case libvlc_MediaPlayerForward:
     case libvlc_MediaPlayerBackward:
     case libvlc_MediaPlayerPositionChanged:
@@ -338,6 +369,16 @@
     setVolumeInternal();
 }
 
+bool MediaPlayer::mute() const
+{
+    return libvlc_audio_get_mute(m_player);
+}
+
+void MediaPlayer::setMute(bool mute)
+{
+    libvlc_audio_set_mute(m_player, mute);
+}
+
 void MediaPlayer::setVolumeInternal()
 {
     libvlc_audio_set_volume(m_player, m_volume * m_fadeAmount);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/mediaplayer.h 
new/phonon-vlc-0.9.0/src/mediaplayer.h
--- old/phonon-backend-vlc-0.8.2/src/mediaplayer.h      2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/mediaplayer.h      2016-04-18 06:25:24.000000000 
+0200
@@ -138,6 +138,15 @@
     /// \param volume new volume
     void setAudioVolume(int volume);
 
+    /// \return mutness
+    bool mute() const;
+
+    /**
+     * Mutes
+     * @param mute whether to mute or unmute
+     */
+    void setMute(bool mute);
+
     /// Set the fade percentage, between 0 (muted) and 1.0 (no fade)
     void setAudioFade(qreal fade);
 
@@ -178,6 +187,9 @@
     /** Emitted when the vout availability has changed */
     void hasVideoChanged(bool hasVideo);
 
+    void mutedChanged(bool mute);
+    void volumeChanged(float volume);
+
 private:
     static void event_cb(const libvlc_event_t *event, void *opaque);
     void setVolumeInternal();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/utils/libvlc.cpp 
new/phonon-vlc-0.9.0/src/utils/libvlc.cpp
--- old/phonon-backend-vlc-0.8.2/src/utils/libvlc.cpp   2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/utils/libvlc.cpp   2016-04-18 06:25:24.000000000 
+0200
@@ -81,10 +81,6 @@
     args << "--no-media-library";
     args << "--no-osd";
     args << "--no-stats";
-#if (LIBVLC_VERSION_INT < LIBVLC_VERSION(2, 1, 0, 0))
-    // Replaced by API call, see MediaPlayer::MediaPlayer.
-    args << "--no-video-title-show";
-#endif
     // By default VLC will put a picture-in-picture when making a snapshot.
     // This is unexpected behaviour for us, so we force it off.
     args << "--no-snapshot-preview";
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/phonon-backend-vlc-0.8.2/src/video/mac/vlcmacwidget.h 
new/phonon-vlc-0.9.0/src/video/mac/vlcmacwidget.h
--- old/phonon-backend-vlc-0.8.2/src/video/mac/vlcmacwidget.h   2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/video/mac/vlcmacwidget.h   2016-04-18 
06:25:24.000000000 +0200
@@ -18,7 +18,7 @@
 #ifndef VLCMACWIDGET_H
 #define VLCMACWIDGET_H
 
-#include <QtGui/QMacCocoaViewContainer>
+#include <QMacCocoaViewContainer>
 
 #import <qmaccocoaviewcontainer_mac.h>
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/phonon-backend-vlc-0.8.2/src/video/videomemorystream.h 
new/phonon-vlc-0.9.0/src/video/videomemorystream.h
--- old/phonon-backend-vlc-0.8.2/src/video/videomemorystream.h  2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/video/videomemorystream.h  2016-04-18 
06:25:24.000000000 +0200
@@ -18,6 +18,7 @@
 #ifndef PHONON_VLC_VIDEOMEMORYSTREAM_H
 #define PHONON_VLC_VIDEOMEMORYSTREAM_H
 
+#include <vlc/plugins/vlc_common.h>
 #include <vlc/plugins/vlc_fourcc.h>
 
 namespace Phonon {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/phonon-backend-vlc-0.8.2/src/vlc.desktop.cmake 
new/phonon-vlc-0.9.0/src/vlc.desktop.cmake
--- old/phonon-backend-vlc-0.8.2/src/vlc.desktop.cmake  2014-12-04 
10:29:23.000000000 +0100
+++ new/phonon-vlc-0.9.0/src/vlc.desktop.cmake  2016-04-18 06:25:24.000000000 
+0200
@@ -10,6 +10,7 @@
 InitialPreference=20
 
 Name=VLC
+Name[ast]=VLC
 Name[bg]=VLC
 Name[bs]=VLC
 Name[ca]=VLC
@@ -36,6 +37,7 @@
 Name[nb]=VLC
 Name[nds]=VLC
 Name[nl]=VLC
+Name[nn]=VLC
 Name[pa]=VLC
 Name[pl]=VLC
 Name[pt]=VLC
@@ -83,6 +85,7 @@
 Comment[nb]=Phonon VLC-motor
 Comment[nds]=VLC-Hülpprogramm för Phonon
 Comment[nl]=VLC-backend van Phonon
+Comment[nn]=VLC-motor for Phonon
 Comment[pa]=ਫੋਨੋਨ VLC ਬੈਕਐਂਡ
 Comment[pl]=Silnik VLC dla Phonon
 Comment[pt]=Infra-estrutura do VLC para o Phonon
@@ -96,7 +99,7 @@
 Comment[sr@ijekavianlatin]=VLC kao pozadina Phonona
 Comment[sr@latin]=VLC kao pozadina Phonona
 Comment[sv]=Phonon VLC-gränssnitt
-Comment[tr]=Phonon VLC arkaucu
+Comment[tr]=Phonon VLC arka ucu
 Comment[ug]=Phonon VLC ئارقا ئۇچى
 Comment[uk]=Модуль VLC Phonon
 Comment[x-test]=xxPhonon VLC backendxx


Reply via email to