Hello community,

here is the log from the commit of package kaffeine.4442 for 
openSUSE:13.1:Update checked in at 2015-12-29 17:05:47
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:13.1:Update/kaffeine.4442 (Old)
 and      /work/SRC/openSUSE:13.1:Update/.kaffeine.4442.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "kaffeine.4442"

Changes:
--------
New Changes file:

--- /dev/null   2015-12-29 16:09:11.912035506 +0100
+++ /work/SRC/openSUSE:13.1:Update/.kaffeine.4442.new/kaffeine.changes  
2015-12-29 17:05:47.000000000 +0100
@@ -0,0 +1,721 @@
+-------------------------------------------------------------------
+Sat Nov 15 14:32:20 UTC 2014 - wba...@tmo.at
+
+- fix ksuseinstall to install libxine2-codecs, libxine1 is not used
+  any more since 12.2 (boo#858018)
+
+-------------------------------------------------------------------
+Wed Aug 21 08:08:50 UTC 2013 - tittiatc...@gmail.com
+
+- fix ksuseinstall does not respect "don't ask again" (bnc# 671578)
+  fix delivered by amolagodb...@gmail.com
+
+-------------------------------------------------------------------
+Thu Apr 19 09:46:10 UTC 2012 - dmuel...@suse.com
+
+- provide/obsolete kaffeine-lang
+
+-------------------------------------------------------------------
+Tue Apr 17 08:43:14 UTC 2012 - dmuel...@suse.com
+
+- fix build for older distros
+
+-------------------------------------------------------------------
+Mon Apr  2 21:31:27 UTC 2012 - dims...@opensuse.org
+
+- Add kaffeine-gcc47.patch: Fix build with gcc 4.7.
+
+-------------------------------------------------------------------
+Tue Feb 28 11:27:56 CET 2012 - jsl...@suse.de
+
+- fix crash on resume
+
+-------------------------------------------------------------------
+Thu Oct 27 00:10:17 UTC 2011 - fi...@opensuse.org
+
+- Desktop menu entry moved to Video Player and TV.
+
+-------------------------------------------------------------------
+Fri Oct  7 10:34:42 UTC 2011 - ctri...@opensuse.org
+
+- Remove patch fix_plasma_startup_error.diff as this causes kaffeine
+  not beeing displayed as an action for audio-cds (bnc#722284)
+
+-------------------------------------------------------------------
+Wed Apr 27 20:23:37 UTC 2011 - asterios.dra...@gmail.com
+
+- Spec file updates:
+  * Fix locales removal if suse_version is not set.
+
+-------------------------------------------------------------------
+Tue Apr 19 21:02:57 UTC 2011 - asterios.dra...@gmail.com
+
+- Update to 1.2.2:
+  * fix crash after removing channels
+- Spec file updates:
+  * Added more descriptions for the patches based on openSUSE Patches
+    Guidelines.
+  * Fixed locales removal for openSUSE < 11.4.
+  * Minor other updates.
+- Fixed, rebased and applied fix_plasma_startup_error.diff patch.
+
+-------------------------------------------------------------------
+Thu Apr  7 16:09:05 UTC 2011 - ms...@novell.com
+
+- Update to 1.2.1:
+  * add search function to epg
+  * implement ATSC support for epg
+  * fix gnome screen saver inhibition
+  * other fixes and improvements
+
+-------------------------------------------------------------------
+Tue Feb 15 20:57:16 UTC 2011 - ctri...@gmx.net
+
+- Add support for more mimetypes (bnc#671581)
+
+-------------------------------------------------------------------
+Tue Feb  8 20:15:43 UTC 2011 - ctri...@gmx.net
+
+- Require libqt4-sql-sqlite (bnc#669793)
+
+-------------------------------------------------------------------
+Mon Jan 31 20:52:54 UTC 2011 - asterios.dra...@gmail.com
+
+- Spec file updates:
+  * Changes based on rpmdevtools templates and spec-cleaner run.
+  * Updates in Buildrequires: and %install sections.
+
+-------------------------------------------------------------------
+Mon Dec 13 06:01:17 UTC 2010 - co...@novell.com
+
+- add build fix for old qt versions
+
+-------------------------------------------------------------------
+Mon Dec 13 05:56:38 UTC 2010 - co...@novell.com
+
+- fix file list for factory
+
+-------------------------------------------------------------------
+Mon Sep 27 23:28:47 UTC 2010 - initialz...@gmail.com
+
+- update to 1.1:
+  * adapt to new shared-mime-info (so that .m2t is assigned to
+    kaffeine again)
+  * workaround issue that video isn't shown without changing tabs
+    when using QT 4.7
+  * recording schedule: fix sorting, improve column and dialog
+    sizes, show a warning about active and pending recordings
+    when closing kaffeine
+  * program guide: remove the "Refresh" button (not necessary
+    anymore)
+  * channel editor: allow sorting by drag and drop 
+
+-------------------------------------------------------------------
+Wed Jul  7 13:41:48 UTC 2010 - initialz...@gmail.com
+ 
+- update to 1.0:
+  * new dependency: libXss
+  * scheduled programs are shown in the program guide
+  * the begin and end margins for recordings are configurable
+  * CICAM is supported
+  * all audio pids are recorded during timeshift
+  * subtitle support (also autoloading) 
+
+-------------------------------------------------------------------
+Wed Jul  7 12:59:53 UTC 2010 - bin...@kde.org
+
+- fix build in KDE:UpdatedApps for <11.3
+
+-------------------------------------------------------------------
+Sat Jun 26 11:47:58 UTC 2010 - cmorv...@yahoo.es
+
+- Add InitialPreference to set it as the default video player
+
+-------------------------------------------------------------------
+Fri Jun 25 09:39:47 UTC 2010 - bein...@opensuse.org
+
+- fix build for <11.3
+
+-------------------------------------------------------------------
+Wed Apr 14 13:14:00 UTC 2010 - llu...@novell.com
+
+- support for on-demand codecs install using ksuseinstall
+
+-------------------------------------------------------------------
+Sun Mar 21 22:08:25 CET 2010 - jsl...@suse.de
+
+- add libqt4-sql-sqlite to Requires
+
+-------------------------------------------------------------------
+Thu Mar 11 16:16:44 UTC 2010 - initialz...@gmail.com
+
+- update to 1.0-pre3:                  
+  * new dependencies: Qt SQLite plugin, xine-lib, libX11
+    (Phonon is no longer needed)                        
+  * added configurable daily or weekly repetition of recording schedule entries
+  * added support for dynamic audio / subtitles streams                        
+  * reworked playlist support                                                  
+  * added DBUS interface and partial MPRIS support                             
+  * added dvd menu button and deinterlace option
+
+-------------------------------------------------------------------
+Sun Oct  4 13:52:50 UTC 2009 - bein...@opensuse.org
+
+- updated translations from SVN
+
+-------------------------------------------------------------------
+Mon Aug 10 07:34:14 CEST 2009 - bein...@opensuse.org
+
+- update to 1.0-pre2:
+   * added screen saver inhibition (using DBUS; org.freedesktop.ScreenSaver)
+   * added basic playlist features: .m3u, .pls, .xspf (+ old 
+     kaffeine format), drag and drop, repeat mode and shuffle
+   * added OSD: various notifications, now and next epg
+   * added DVB-S2 support using S2 API (old API still supported for non-S2 
usage)
+   * improved epg: save and restore events, possibility to schedule programs
+
+-------------------------------------------------------------------
+Sat Jul 25 20:08:41 CEST 2009 - bein...@opensuse.org
+
+- add trunk diff update (revision 1002342)
+
+-------------------------------------------------------------------
+Wed Jun  3 16:14:59 CEST 2009 - bein...@opensuse.org
+
+- copy application icon from oxygen trunk to fix start menu icon
+  on every other/older KDE (bnc#509210)
+
+-------------------------------------------------------------------
+Tue Apr 28 08:32:10 CEST 2009 - bein...@opensuse.org
+
+- fix build
+
+-------------------------------------------------------------------
+Mon Apr 27 20:55:01 CEST 2009 - tittiatc...@gmail.com
+
+- update to 1.0-pre1; This is the pre-release of the KDE4 version
+  and is not really intended yet for end-users
++++ 524 more lines (skipped)
++++ between /dev/null
++++ and /work/SRC/openSUSE:13.1:Update/.kaffeine.4442.new/kaffeine.changes

New:
----
  build-fix.diff
  crash-on-resume-fix.patch
  initial-preference.diff
  kaffeine-1.2.2.tar.bz2
  kaffeine-fixsplitter.patch
  kaffeine-gcc47.patch
  kaffeine-icons.tar.bz2
  kaffeine.changes
  kaffeine.spec
  ksuseinstall.diff
  support_mimetypes_bnc671581.diff

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

Other differences:
------------------
++++++ kaffeine.spec ++++++
#
# spec file for package kaffeine
#
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


Name:           kaffeine
Version:        1.2.2
Release:        0
Summary:        Xine-Based Multimedia Player
License:        GPL-2.0+
Group:          Productivity/Multimedia/Video/Players

Url:            http://kaffeine.kde.org/
# http://sourceforge.net/projects/kaffeine/files/current/kaffeine-1.2.2.tar.gz
Source0:        %{name}-%{version}.tar.bz2
Source1:        %{name}-icons.tar.bz2
# PATCH-FEATURE-OPENSUSE kaffeine-fixsplitter.patch -- GUI improvement (allow 
more flexibly set splitters)
Patch0:         kaffeine-fixsplitter.patch
# PATCH-FEATURE-OPENSUSE ksuseinstall.diff llu...@novell.com -- Support for 
on-demand codecs install using ksuseinstall
Patch2:         ksuseinstall.diff
# PATCH-FIX-OPENSUSE initial-preference.diff cmorv...@yahoo.es -- Add 
InitialPreference to set it as the default video player
Patch3:         initial-preference.diff
# PATCH-FIX-OPENSUSE build-fix.diff -- Build fix for old qt versions
Patch4:         build-fix.diff
# PATCH-FIX-OPENSUSE support_mimetypes_bnc671581.diff bnc#671581 
ctri...@gmx.net -- Support audio/webm and video/x-theora+ogg
Patch5:         support_mimetypes_bnc671581.diff
# PATCH-FIX-UPSTREAM
Patch6:         crash-on-resume-fix.patch
# PATCH-FIX-UPSTREAM kaffeine-gcc47.patch dims...@opensuse.org -- Fix build 
with gcc 4.7
Patch7:         kaffeine-gcc47.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

BuildRequires:  libkde4-devel
%if 0%{?suse_version} > 1120
BuildRequires:  libksuseinstall-devel
%endif
BuildRequires:  libxine-devel
%if 0%{?suse_version}
BuildRequires:  update-desktop-files
%endif
Requires:       libqt4-sql-sqlite
Provides:       kaffeine-lang = %version
Obsoletes:      kaffeine-lang < %version
%kde4_runtime_requires

%description
Kaffeine plays all files and devices supported by Xine. For example,
MPEG files, AVI (if the codec being used is supported by Xine), MP3,
and Ogg Vorbis. It also handles Video CDs, DVDs, and DVB cards.

%prep
%setup -q -b 1
%patch0
%if 0%{?suse_version} > 1120
%patch2
%endif
%patch3
%if 0%{?kde_updatedapps}
%patch4 -p0
%endif
%if 0%{?suse_version} > 1130
%patch5
%endif
%patch6 -p1
%patch7

%build
%cmake_kde4 -d build
%make_jobs

%install
pushd build
%kde4_makeinstall
popd

%if 0%{?suse_version}
# place desktop entry in video and tv
%suse_update_desktop_file -r %{name} Qt KDE AudioVideo Video Player TV
%endif

%kde_post_install

# Removed unneeded locales
%if 0%{?suse_version} && 0%{?suse_version} < 1140
rm -rf %{buildroot}%{_datadir}/locale/ast/LC_MESSAGES/
rm -rf %{buildroot}%{_datadir}/locale/sr@ijekavian/
rm -rf %{buildroot}%{_datadir}/locale/sr@ijekavianlatin/
%endif

%find_lang %{name}

%clean
rm -rf %{buildroot}

%files -f %{name}.lang
%defattr(-,root,root,-)
%doc COPYING COPYING-DOCS Changelog NOTES
%{_kde4_bindir}/kaffeine
%{_kde4_bindir}/kaffeine-xbu
%{_kde4_applicationsdir}/kaffeine.desktop
%{_kde4_iconsdir}/hicolor/*/apps/kaffeine.*
%{_kde4_iconsdir}/oxygen/*/actions/audio-radio-encrypted.*
%{_kde4_iconsdir}/oxygen/*/actions/video-television-encrypted.*
%{_kde4_appsdir}/kaffeine/
%dir %{_kde4_appsdir}/profiles
%{_kde4_appsdir}/profiles/kaffeine.profile.xml
%dir %{_kde4_appsdir}/solid
%dir %{_kde4_appsdir}/solid/actions
%{_kde4_appsdir}/solid/actions/kaffeine_play_audiocd.desktop
%{_kde4_appsdir}/solid/actions/kaffeine_play_dvd.desktop
%{_kde4_appsdir}/solid/actions/kaffeine_play_videocd.desktop

%changelog
++++++ build-fix.diff ++++++
--- src/dvb/dvbchannelui.h      2010-09-01 21:53:54.000000000 +0200
+++ src/dvb/dvbchannelui.h      2010-09-30 19:30:56.486249907 +0200
@@ -21,6 +21,7 @@
 #ifndef DVBCHANNELUI_H
 #define DVBCHANNELUI_H
 
+#include <QSharedDataPointer>
 #include <QTreeView>
 
 class QAbstractProxyModel;
--- src/dvb/dvbmanager.h        2010-09-01 21:53:54.000000000 +0200
+++ src/dvb/dvbmanager.h        2010-09-30 20:14:30.720168393 +0200
@@ -21,6 +21,7 @@
 #ifndef DVBMANAGER_H
 #define DVBMANAGER_H
 
+#include <QSharedDataPointer>
 #include <QDate>
 #include <QMap>
 #include <QPair>
++++++ crash-on-resume-fix.patch ++++++
---
 src/dvb/dvbmanager.cpp |   16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)

--- a/src/dvb/dvbmanager.cpp
+++ b/src/dvb/dvbmanager.cpp
@@ -448,15 +448,17 @@ void DvbManager::deviceAdded(DvbBackendD
 void DvbManager::deviceRemoved(DvbBackendDevice *backendDevice)
 {
        for (int i = 0; i < deviceConfigs.size(); ++i) {
-               if (deviceConfigs.at(i).device->getBackendDevice() == 
backendDevice) {
-                       if (deviceConfigs[i].useCount != 0) {
-                               deviceConfigs[i].useCount = 0;
-                               deviceConfigs[i].prioritizedUseCount = 0;
-                               deviceConfigs[i].device->release();
+               DvbDeviceConfig &it = deviceConfigs[i];
+
+               if (it.device && it.device->getBackendDevice() == 
backendDevice) {
+                       if (it.useCount != 0) {
+                               it.useCount = 0;
+                               it.prioritizedUseCount = 0;
+                               it.device->release();
                        }
 
-                       delete deviceConfigs[i].device;
-                       deviceConfigs[i].device = NULL;
+                       delete it.device;
+                       it.device = NULL;
                        break;
                }
        }
++++++ initial-preference.diff ++++++
Index: src/kaffeine.desktop
===================================================================
--- src/kaffeine.desktop.orig
+++ src/kaffeine.desktop
@@ -97,3 +97,6 @@ X-KDE-HasTempFileOption=true
 #To enable back when doc will be available
 #X-DocPath=kaffeine/index.html
 X-Desktop-File-Install-Version=0.15
+#Lower than Amarok so we don't override for audio.
+#Will break if Amarok ever starts to play video files.
+InitialPreference=4
++++++ kaffeine-fixsplitter.patch ++++++
Index: src/playlist/playlisttab.cpp
===================================================================
--- src/playlist/playlisttab.cpp        (revision 1134989)
+++ src/playlist/playlisttab.cpp        (working copy)
@@ -21,6 +21,7 @@
 #include "playlisttab.h"
 
 #include <QBoxLayout>
+#include <QToolBar>
 #include <QKeyEvent>
 #include <QListView>
 #include <QSplitter>
@@ -447,33 +448,35 @@
        QBoxLayout *sideLayout = new QVBoxLayout(widget);
        sideLayout->setMargin(0);
 
+       QToolBar *ToolBarLayout= new QToolBar();
        QBoxLayout *boxLayout = new QHBoxLayout();
 
        QToolButton *toolButton = new QToolButton(widget);
        toolButton->setDefaultAction(newAction);
        toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
-       boxLayout->addWidget(toolButton);
+       ToolBarLayout->addWidget(toolButton);
 
        toolButton = new QToolButton(widget);
        toolButton->setDefaultAction(renameAction);
        toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
-       boxLayout->addWidget(toolButton);
+       ToolBarLayout->addWidget(toolButton);
 
        toolButton = new QToolButton(widget);
        toolButton->setDefaultAction(removePlaylistAction);
        toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
-       boxLayout->addWidget(toolButton);
+       ToolBarLayout->addWidget(toolButton);
 
        toolButton = new QToolButton(widget);
        toolButton->setDefaultAction(savePlaylistAction);
        toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
-       boxLayout->addWidget(toolButton);
+       ToolBarLayout->addWidget(toolButton);
 
        toolButton = new QToolButton(widget);
        toolButton->setDefaultAction(savePlaylistAsAction);
        toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
-       boxLayout->addWidget(toolButton);
+       ToolBarLayout->addWidget(toolButton);
 
+       boxLayout->addWidget(ToolBarLayout);
        boxLayout->addStretch();
        sideLayout->addLayout(boxLayout);
 
@@ -500,28 +503,30 @@
        sideLayout = new QVBoxLayout(widget);
        sideLayout->setMargin(0);
 
+       ToolBarLayout= new QToolBar();
        boxLayout = new QHBoxLayout();
 
        toolButton = new QToolButton(widget);
        toolButton->setDefaultAction(repeatAction);
        toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
-       boxLayout->addWidget(toolButton);
+       ToolBarLayout->addWidget(toolButton);
 
        toolButton = new QToolButton(widget);
        toolButton->setDefaultAction(randomAction);
        toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
-       boxLayout->addWidget(toolButton);
+       ToolBarLayout->addWidget(toolButton);
 
        toolButton = new QToolButton(widget);
        toolButton->setDefaultAction(removeTrackAction);
        toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
-       boxLayout->addWidget(toolButton);
+       ToolBarLayout->addWidget(toolButton);
 
        toolButton = new QToolButton(widget);
        toolButton->setDefaultAction(clearAction);
        toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
-       boxLayout->addWidget(toolButton);
+       ToolBarLayout->addWidget(toolButton);
 
+       boxLayout->addWidget(ToolBarLayout);
        boxLayout->addStretch();
        sideLayout->addLayout(boxLayout);
 
@@ -616,6 +621,7 @@
        fileWidget->setFilter(MediaWidget::extensionFilter());
        fileWidget->setMode(KFile::Files | KFile::ExistingOnly);
        fileWidgetSplitter->setStretchFactor(1, 1);
+       fileWidget->setMinimumWidth(40);
 
        // KFileWidget creates a KUrlComboBox without layout (!), which steals 
the focus:
        //     kDebug() << QApplication::focusWidget();
++++++ kaffeine-gcc47.patch ++++++
Index: src/dvb/dvbepg.cpp
===================================================================
--- src/dvb/dvbepg.cpp.orig
+++ src/dvb/dvbepg.cpp
@@ -690,15 +690,15 @@ void AtscEpgFilter::processEitSection(co
        // 1980-01-06T000000 minus 15 secs (= UTC - GPS in 2011)
        QDateTime baseDateTime = QDateTime(QDate(1980, 1, 5), QTime(23, 59, 
45), Qt::UTC);
 
-       for (AtscEitSectionEntry entry = eitSection.entries(); (entryCount > 0) 
&& entry.isValid();
-            --entryCount, entry.advance()) {
+       for (AtscEitSectionEntry AESentry = eitSection.entries(); (entryCount > 
0) && AESentry.isValid();
+            --entryCount, AESentry.advance()) {
                DvbEpgEntry epgEntry;
                epgEntry.channel = channel;
-               epgEntry.begin = baseDateTime.addSecs(entry.startTime());
-               epgEntry.duration = QTime().addSecs(entry.duration());
-               epgEntry.title = entry.title();
+               epgEntry.begin = baseDateTime.addSecs(AESentry.startTime());
+               epgEntry.duration = QTime().addSecs(AESentry.duration());
+               epgEntry.title = AESentry.title();
 
-               quint32 id = ((quint32(fakeChannel.networkId) << 16) | 
quint32(entry.eventId()));
+               quint32 id = ((quint32(fakeChannel.networkId) << 16) | 
quint32(AESentry.eventId()));
                DvbSharedEpgEntry entry = epgEntries.value(id);
 
                if (entry.isValid() && (entry->channel == epgEntry.channel) &&
++++++ ksuseinstall.diff ++++++
--- src/CMakeLists.txt  2010/07/07 18:16:03     1.1
+++ src/CMakeLists.txt  2010/07/07 18:17:30
@@ -42,6 +42,7 @@
 
 kde4_add_executable(kaffeine ${kaffeinedvb_SRCS} ${kaffeine_SRCS})
 target_link_libraries(kaffeine ${QT_QTSQL_LIBRARY} ${KDE4_KFILE_LIBS} 
${KDE4_KIO_LIBS} ${KDE4_SOLID_LIBS} ${X11_Xscreensaver_LIB})
+target_link_libraries(kaffeine ksuseinstall)
 install(TARGETS kaffeine ${INSTALL_TARGETS_DEFAULT_ARGS})
 install(FILES scanfile.dvb DESTINATION ${DATA_INSTALL_DIR}/kaffeine)
 install(PROGRAMS kaffeine.desktop DESTINATION ${XDG_APPS_INSTALL_DIR})
--- src/backend-xine/xinecommands.h     2010/07/07 18:15:59     1.1
+++ src/backend-xine/xinecommands.h     2010/07/07 18:16:08
@@ -59,7 +59,8 @@
                UpdateAngles            = 11,
                UpdateMouseTracking     = 12,
                UpdateMouseCursor       = 13,
-               UpdateVideoSize         = 14
+               UpdateVideoSize         = 14,
+               SupportedMimeTypes      = 15
        };
 }
 
@@ -351,6 +352,13 @@
                        reinterpret_cast<const char *>(&videoSize), 
sizeof(videoSize));
        }
 
+       void supportedMimeTypes(const QString& mime)
+       {
+               writer->write(XineCommands::SupportedMimeTypes,
+                       reinterpret_cast<const char *>(mime.constData()),
+                       static_cast<unsigned int>(mime.size()) * sizeof(QChar));
+       }
+
        XinePipeWriterBase *writer;
 };
 
--- src/backend-xine/xinemediawidget.cpp.sav    2010-09-27 16:08:49.648890045 
-0600
+++ src/backend-xine/xinemediawidget.cpp        2010-09-27 16:21:39.342889627 
-0600
@@ -22,12 +22,16 @@
 #include "xinemediawidget_p.h"
 
 #include <QResizeEvent>
+#include <QTimer>
 #include <KDebug>
+#include <KLocale>
 #include <KMessageBox>
 #include <config-kaffeine.h>
 #include <errno.h>
 #include <unistd.h>
 
+#include <ksuseinstall.h>
+
 static QString binInstallPath()
 {
        return QString::fromUtf8(KAFFEINE_BIN_INSTALL_DIR "/");
@@ -213,6 +217,15 @@
 
                        break;
                    }
+               case XineCommands::SupportedMimeTypes: {
+                       QString mime = reader->readString();
+
+                       if (reader->isValid()) {
+                               parent->supportedMimeTypes(mime);
+                       }
+
+                       break;
+                   }
                default:
                        kError() << "unknown command" << command;
                        continue;
@@ -844,6 +857,45 @@
        }
 }
 
+void XineMediaWidget::supportedMimeTypes(const QString &mime)
+{
+        // This is a bit lame, but simply check for a mimetype that the 
crippled package
+        // does not provide.
+        foreach( const QString& item, mime.split( ';' )) {
+            QStringList fields = item.split( ':' );
+            if( fields.count() == 3 ) {
+                if( fields.first() == "audio/mp3" ) {
+                    return; // ok
+                }
+            }
+        }
+        QTimer::singleShot( 0, this, SLOT( installAdditionalCodecs()));
+}
+
+void XineMediaWidget::installAdditionalCodecs()
+{
+        KGuiItem installGuiItem( KStandardGuiItem::yes());
+        installGuiItem.setText( i18nc( "@action:button", "Install" ));
+        if( KMessageBox::warningYesNo( window(),
+            i18n( "Kaffeine currently cannot play some file formats. Do you 
want to install additional support?" ),
+            i18n( "Install Additional Codecs" ),
+            installGuiItem, KStandardGuiItem::no(), "suse_additional_codecs" ) 
!= KMessageBox::Yes )
+            {
+            return;
+            }
+        if( KSUSEInstall::installCapabilities( QStringList() << 
"libxine2-codecs",
+                KSUSEInstall::FullInstallRequired, window()))
+            { // TODO use the items
+            KGuiItem restartNowGuiItem( KStandardGuiItem::yes());
+            restartNowGuiItem.setText( i18nc( "@action:button", "Restart Now" 
));
+            KGuiItem restartLaterGuiItem( KStandardGuiItem::no());
+            restartLaterGuiItem.setText( i18nc( "@action:button", "Restart 
Later" ));
+            KMessageBox::information( window(),
+                i18n( "The necessary support has been successfully installed."
+                        " It may be necessary to restart the application for 
the support to be activated." ));
+            }
+}
+
 void XineMediaWidget::playEncodedUrl(const QByteArray &encodedUrl, StateFlags 
stateFlags)
 {
        ++sequenceNumber;

--- src/backend-xine/xinemediawidget.h.sav      2010-01-31 18:04:50.000000000 
+0100
+++ src/backend-xine/xinemediawidget.h  2010-04-14 14:31:17.301512132 +0200
@@ -127,6 +127,9 @@ public:
 
        Q_DECLARE_FLAGS(DirtyFlags, DirtyFlag)
 
+private slots:
+        void installAdditionalCodecs();
+
 private:
        void mouseMoveEvent(QMouseEvent *event);
        void mousePressEvent(QMouseEvent *event);
@@ -149,6 +152,7 @@ private:
        void updateMouseTracking(bool mouseTrackingEnabled);
        void updateMouseCursor(bool pointingMouseCursor);
        void updateVideoSize(unsigned int videoSize_);
+       void supportedMimeTypes(const QString &mime);
 
        void playEncodedUrl(const QByteArray &encodedUrl, StateFlags stateFlags 
= 0);
        void stateChanged();
--- src/backend-xine/xineapplication.cpp.sav    2010-09-27 16:30:01.619888519 
-0600
+++ src/backend-xine/xineapplication.cpp        2010-09-27 16:39:05.239888392 
-0600
@@ -295,7 +295,11 @@
        xine_config_load(engine,
                QFile::encodeName(KStandardDirs::locateLocal("data", 
"kaffeine/xine-config")));
        xine_init(engine);
-
+       
+       if( char* mimes = xine_get_mime_types( engine )) {
+         parentProcess->supportedMimeTypes( mimes );
+       }
+       
        QVector<const char *> audioDrivers;
        audioDrivers.append("auto");
 
++++++ support_mimetypes_bnc671581.diff ++++++
--- src/kaffeine.desktop        2010-09-01 21:53:54.000000000 +0200
+++ src/kaffeine.desktop_patched        2011-02-15 21:51:59.000000000 +0100
@@ -103,7 +103,7 @@
 GenericName[zh_TW]=媒體播放器
 Categories=Qt;KDE;AudioVideo;Player;
 Icon=kaffeine
-MimeType=application/ogg;application/ram;application/vnd.rn-realmedia;application/x-quicktime-media-link;application/x-shorten;application/xspf+xml;audio/ac3;audio/basic;audio/flac;audio/mp4;audio/mpeg;audio/ogg;audio/vnd.rn-realaudio;audio/x-aiff;audio/x-it;audio/x-m4b;audio/x-matroska;audio/x-mod;audio/x-mpegurl;audio/x-ms-asx;audio/x-ms-wma;audio/x-musepack;audio/x-s3m;audio/x-scpls;audio/x-stm;audio/x-tta;audio/x-voc;audio/x-wav;audio/x-wavpack;audio/x-xm;video/dv;video/mp2t;video/mp4;video/mpeg;video/ogg;video/quicktime;video/vnd.rn-realvideo;video/x-anim;video/x-flic;video/x-flv;video/x-matroska;video/x-mng;video/x-ms-asf;video/x-ms-wmv;video/x-msvideo;video/x-nsv;video/x-ogm+ogg;
+MimeType=application/ogg;application/ram;application/vnd.rn-realmedia;application/x-quicktime-media-link;application/x-shorten;application/xspf+xml;audio/ac3;audio/basic;audio/mp4;audio/mpeg;audio/ogg;audio/vnd.rn-realaudio;audio/x-aiff;audio/x-flac;audio/x-it;audio/x-m4b;audio/x-matroska;audio/x-mod;audio/x-mpegurl;audio/x-ms-asx;audio/x-ms-wma;audio/x-musepack;audio/x-s3m;audio/x-scpls;audio/x-speex;audio/x-stm;audio/x-tta;audio/x-voc;audio/x-wav;audio/x-wavpack;audio/x-xm;video/dv;video/mp2t;video/mp4;video/mpeg;video/ogg;video/quicktime;video/vnd.rn-realvideo;video/x-anim;video/x-flic;video/x-flv;video/x-matroska;video/x-mng;video/x-ms-asf;video/x-ms-wmv;video/x-msvideo;video/x-nsv;video/x-ogm+ogg;video/x-theora+ogg;audio/webm;
 Terminal=false
 Type=Application
 X-KDE-HasTempFileOption=true

Reply via email to