[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[SCM] LibreOffice packaging repository branch, ubuntu-quantal-3.6, updated. libreoffice_3.5.4-5-172-g899d9d2



The following commit has been merged in the ubuntu-quantal-3.6 branch:
commit 2dd198ef0e395a437502b3d66a5dd06601336709
Author: Bjoern Michaelsen <bjoern.michaelsen@canonical.com>
Date:   Tue Aug 21 02:49:33 2012 +0200

    add packagekit patch

diff --git a/changelog b/changelog
index 8523a31..105e128 100644
--- a/changelog
+++ b/changelog
@@ -1,4 +1,4 @@
-libreoffice (1:3.6.0~rc4-0ubuntu2) precise; urgency=low
+libreoffice (1:3.6.0~rc4-0ubuntu3~ppa1) precise; urgency=low
 
   * backport patch to evade fdo#51324 (LP: #1017125) 
   * pure white progress bar is better for now (LP: #1026059)
@@ -12,8 +12,9 @@ libreoffice (1:3.6.0~rc4-0ubuntu2) precise; urgency=low
     - remove obsolete remove-broken-mysqlcon-version-check.diff
     - remove unoapi-test disabling patch, now that we seem to evade lp#1017125
   * reenable reportbuilder for universe ppa builds only (LP: #992232)
+  * add packagekit patch
 
- -- Bjoern Michaelsen <bjoern.michaelsen@canonical.com>  Wed, 08 Aug 2012 15:28:16 +0200
+ -- Bjoern Michaelsen <bjoern.michaelsen@canonical.com>  Tue, 21 Aug 2012 02:46:51 +0200
 
 libreoffice (1:3.6.0~rc4-0ubuntu1) quantal-proposed; urgency=low
 
diff --git a/patches/packagekit.diff b/patches/packagekit.diff
new file mode 100644
index 0000000..f561d25
--- /dev/null
+++ b/patches/packagekit.diff
@@ -0,0 +1,664 @@
+Index: libreoffice-3.6.0~rc4/Repository.mk
+===================================================================
+--- libreoffice-3.6.0~rc4.orig/Repository.mk	2012-07-17 14:02:12.000000000 +0200
++++ libreoffice-3.6.0~rc4/Repository.mk	2012-08-21 03:01:38.128198444 +0200
+@@ -538,6 +538,7 @@
+     kde4be1 \
+     localebe1 \
+     lomenubar \
++    losessioninstall \
+     macbe1 \
+     migrationoo2 \
+     migrationoo3 \
+Index: libreoffice-3.6.0~rc4/offapi/UnoApi_offapi.mk
+===================================================================
+--- libreoffice-3.6.0~rc4.orig/offapi/UnoApi_offapi.mk	2012-07-17 14:02:12.000000000 +0200
++++ libreoffice-3.6.0~rc4/offapi/UnoApi_offapi.mk	2012-08-21 03:01:38.132198444 +0200
+@@ -4261,4 +4261,10 @@
+ 	XDataType \
+ ))
+ 
++$(eval $(call gb_UnoApi_add_idlfiles,offapi,offapi/org/freedesktop/PackageKit,\
++    XSyncDbusSessionHelper \
++    XModify \
++    XQuery \
++))
++
+ # vim: set noet sw=4 ts=4:
+Index: libreoffice-3.6.0~rc4/offapi/org/freedesktop/PackageKit/XModify.idl
+===================================================================
+--- /dev/null	1970-01-01 00:00:00.000000000 +0000
++++ libreoffice-3.6.0~rc4/offapi/org/freedesktop/PackageKit/XModify.idl	2012-08-21 03:01:38.132198444 +0200
+@@ -0,0 +1,104 @@
++/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
++/*
++ * This file is part of the LibreOffice project.
++ *
++ * This Source Code Form is subject to the terms of the Mozilla Public
++ * License, v. 2.0. If a copy of the MPL was not distributed with this
++ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
++ */
++
++#ifndef org_freedesktop_PackageKit_XModify_idl
++#define org_freedesktop_PackageKit_XModify_idl
++
++#include <com/sun/star/uno/XInterface.idl>
++
++module org
++{
++module freedesktop
++{
++module PackageKit
++{
++/**
++ *  The interface used for modifying the package database.
++ */
++interface XModify : com::sun::star::uno::XInterface
++{
++    /**
++     * Installs local package sequence< string > files or service packs.
++     * @since LibreOffice 3.7
++     */
++
++    void InstallPackageFiles( [in] unsigned long xid, [in] sequence< string > files, [in] string interaction);
++
++    /**
++     * Installs sequence< string > packages to provide sequence< string > files.
++     * @since LibreOffice 3.7
++     */
++
++    void InstallProvideFiles( [in] unsigned long xid, [in] sequence< string > files, [in] string interaction);
++
++    /**
++     * Installs sequence< string > packages to provide sequence< string > files.
++     * @since LibreOffice 3.7
++     */
++
++    void InstallCatalogs( [in] unsigned long xid, [in] sequence< string > files, [in] string interaction);
++
++    /**
++     * Installs sequence< string > packages from a configured software source.
++     * @since LibreOffice 3.7
++     */
++
++    void InstallPackageNames( [in] unsigned long xid, [in] sequence< string > packages, [in] string interaction);
++
++    /**
++     * Installs mimetype handlers from a configured software source.
++     * @since LibreOffice 3.7
++     */
++
++    void InstallMimeTypes( [in] unsigned long xid, [in] sequence< string > mime_types, [in] string interaction);
++
++    /**
++     * Installs fontconfig resources ( [in] usually fonts) from a configured software source.
++     * @since LibreOffice 3.7
++     */
++
++    void InstallFontconfigRessources( [in] unsigned long xid, [in] sequence< string > resources, [in] string interaction);
++
++    /**
++     * Installs GStreamer resources ( [in] usually codecs) from a configured software source.
++     * @since LibreOffice 3.7
++     */
++
++    void InstalliGStreamerRessources( [in] unsigned long xid, [in] sequence< string > resources, [in] string interaction);
++
++    /**
++     * Installs resources of a given type from a configured software source.
++     * @since LibreOffice 3.7
++     */
++
++    void InstallRessources( [in] unsigned long xid, [in] sequence< string > types, [in] sequence< string > resources, [in] string interaction);
++
++    /**
++     * Removes sequence< string > packages that provide the given local sequence< string > files.
++     * @since LibreOffice 3.7
++     */
++
++    void RemovePackageByFiles( [in] unsigned long xid, [in] sequence< string > files, [in] string interaction);
++
++    /**
++     * Installs printer drivers from a configured software source.
++     * @since LibreOffice 3.7
++     */
++
++    void InstallPrinterDrivers( [in] unsigned long xid, [in] sequence< string > files, [in] string interaction);
++};
++
++} ; // PackageKit
++} ; // freedesktop
++} ; // org
++
++
++#endif
++
++/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+Index: libreoffice-3.6.0~rc4/offapi/org/freedesktop/PackageKit/XQuery.idl
+===================================================================
+--- /dev/null	1970-01-01 00:00:00.000000000 +0000
++++ libreoffice-3.6.0~rc4/offapi/org/freedesktop/PackageKit/XQuery.idl	2012-08-21 03:01:38.132198444 +0200
+@@ -0,0 +1,48 @@
++/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
++/*
++ * This file is part of the LibreOffice project.
++ *
++ * This Source Code Form is subject to the terms of the Mozilla Public
++ * License, v. 2.0. If a copy of the MPL was not distributed with this
++ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
++ */
++#ifndef org_freedesktop_PakageKit_XQuery_idl
++#define org_freedesktop_PakageKit_XQuery_idl
++
++#include <com/sun/star/uno/XInterface.idl>
++
++module org
++{
++module freedesktop
++{
++module PackageKit
++{
++/**
++ *  The interface used for quering the package database.
++ */
++interface XQuery : com::sun::star::uno::XInterface
++{
++    /**
++     * Installs local package files or service packs.
++     * @since LibreOffice 3.7
++     */
++
++    void IsInstalled([in] string package_name, [in] string interaction, [out] boolean installed);
++
++    /**
++     * Installs packages to provide files.
++     * @since LibreOffice 3.7
++     */
++
++    void SearchFile([in] string file_name, [in] string interaction, [out] boolean installed, [out] string package_name);
++
++};
++
++} ; // PackageKit
++} ; // freedesktop
++} ; // org
++
++
++#endif
++
++/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+Index: libreoffice-3.6.0~rc4/offapi/org/freedesktop/PackageKit/XSyncDbusSessionHelper.idl
+===================================================================
+--- /dev/null	1970-01-01 00:00:00.000000000 +0000
++++ libreoffice-3.6.0~rc4/offapi/org/freedesktop/PackageKit/XSyncDbusSessionHelper.idl	2012-08-21 03:01:38.132198444 +0200
+@@ -0,0 +1,31 @@
++/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
++/*
++ * This file is part of the LibreOffice project.
++ *
++ * This Source Code Form is subject to the terms of the Mozilla Public
++ * License, v. 2.0. If a copy of the MPL was not distributed with this
++ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
++ */
++#ifndef org_freedesktop_PackageKit_XSyncDbusSessionHelper_idl
++#define org_freedesktop_PackageKit_XSyncDbusSessionHelper_idl
++
++#include <org/freedesktop/PackageKit/XModify.idl>
++#include <org/freedesktop/PackageKit/XQuery.idl>
++
++module org {
++module freedesktop {
++module PackageKit {
++
++interface XSyncDbusSessionHelper
++{
++    interface XModify;
++    interface XQuery;
++};
++
++} ; // PackageKit
++} ; // freedesktop
++} ; // org
++
++#endif
++
++/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+Index: libreoffice-3.6.0~rc4/postprocess/packcomponents/makefile.mk
+===================================================================
+--- libreoffice-3.6.0~rc4.orig/postprocess/packcomponents/makefile.mk	2012-08-21 02:59:47.000000000 +0200
++++ libreoffice-3.6.0~rc4/postprocess/packcomponents/makefile.mk	2012-08-21 03:01:38.132198444 +0200
+@@ -96,6 +96,7 @@
+     component/sot/util/sot \
+     component/starmath/util/sm \
+     component/starmath/util/smd \
++    component/shell/source/sessioninstall/losessioninstall \
+     component/svl/source/fsstor/fsstorage \
+     component/svl/source/passwordcontainer/passwordcontainer \
+     component/svl/util/svl \
+Index: libreoffice-3.6.0~rc4/scp2/source/ooo/file_library_ooo.scp
+===================================================================
+--- libreoffice-3.6.0~rc4.orig/scp2/source/ooo/file_library_ooo.scp	2012-08-21 02:59:47.000000000 +0200
++++ libreoffice-3.6.0~rc4/scp2/source/ooo/file_library_ooo.scp	2012-08-21 03:01:38.136198444 +0200
+@@ -94,6 +94,7 @@
+ #endif
+ 
+ SPECIAL_COMPONENT_LIB_FILE(gid_File_Lib_Configmgr, configmgr.uno)
++SPECIAL_COMPONENT_LIB_FILE(gid_File_Lib_Losessioninstall, losessioninstall.uno )
+ 
+ #ifdef WITH_LDAP
+ File gid_File_Lib_Ldapbe2
+Index: libreoffice-3.6.0~rc4/scp2/source/ooo/module_hidden_ooo.scp
+===================================================================
+--- libreoffice-3.6.0~rc4.orig/scp2/source/ooo/module_hidden_ooo.scp	2012-08-21 02:59:47.000000000 +0200
++++ libreoffice-3.6.0~rc4/scp2/source/ooo/module_hidden_ooo.scp	2012-08-21 03:01:38.136198444 +0200
+@@ -324,6 +324,7 @@
+     gid_File_Lib_Textconv_Dict,
+ 	gid_File_Lib_Basprov,
+ 	gid_File_Lib_Configmgr,
++	gid_File_Lib_Losessioninstall,
+ 	gid_File_Lib_Crypto,
+ 	gid_File_Lib_Dlgprov,
+ 	gid_File_Lib_Stringresource,
+Index: libreoffice-3.6.0~rc4/shell/Library_losessioninstall.mk
+===================================================================
+--- /dev/null	1970-01-01 00:00:00.000000000 +0000
++++ libreoffice-3.6.0~rc4/shell/Library_losessioninstall.mk	2012-08-21 03:01:38.136198444 +0200
+@@ -0,0 +1,37 @@
++# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
++#
++# This file is part of the LibreOffice project.
++#
++# This Source Code Form is subject to the terms of the Mozilla Public
++# License, v. 2.0. If a copy of the MPL was not distributed with this
++# file, You can obtain one at http://mozilla.org/MPL/2.0/.
++#
++
++$(eval $(call gb_Library_Library,losessioninstall))
++
++$(eval $(call gb_Library_set_componentfile,losessioninstall,shell/source/sessioninstall/losessioninstall))
++
++$(eval $(call gb_Library_use_api,losessioninstall,\
++    offapi \
++    udkapi \
++))
++
++$(eval $(call gb_Library_use_libraries,losessioninstall,\
++	comphelper \
++	cppu \
++	cppuhelper \
++	sal \
++	$(gb_STDLIBS) \
++))
++
++$(eval $(call gb_Library_use_externals,losessioninstall,\
++    dbus \
++    gio \
++))
++
++$(eval $(call gb_Library_add_exception_objects,losessioninstall,\
++	shell/source/sessioninstall/SyncDbusSessionHelper \
++	shell/source/sessioninstall/services \
++))
++
++# vim:set shiftwidth=4 softtabstop=4 expandtab:
+Index: libreoffice-3.6.0~rc4/shell/Module_shell.mk
+===================================================================
+--- libreoffice-3.6.0~rc4.orig/shell/Module_shell.mk	2012-07-17 14:02:12.000000000 +0200
++++ libreoffice-3.6.0~rc4/shell/Module_shell.mk	2012-08-21 03:01:38.136198444 +0200
+@@ -31,6 +31,7 @@
+ 	InternalUnoApi_localebe \
+ 	Library_desktopbe \
+ 	Library_localebe \
++	Library_losessioninstall \
+ ))
+ 
+ ifeq ($(ENABLE_GCONF),TRUE)
+Index: libreoffice-3.6.0~rc4/shell/source/sessioninstall/SyncDbusSessionHelper.cxx
+===================================================================
+--- /dev/null	1970-01-01 00:00:00.000000000 +0000
++++ libreoffice-3.6.0~rc4/shell/source/sessioninstall/SyncDbusSessionHelper.cxx	2012-08-21 03:01:38.136198444 +0200
+@@ -0,0 +1,113 @@
++/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
++/*
++ * This file is part of the LibreOffice project.
++ *
++ * This Source Code Form is subject to the terms of the Mozilla Public
++ * License, v. 2.0. If a copy of the MPL was not distributed with this
++ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
++ */
++
++#include <SyncDbusSessionHelper.hxx>
++
++#include <comphelper/stlunosequence.hxx>
++#include <gio/gio.h>
++#include <vector>
++#include <boost/shared_ptr.hpp>
++
++using namespace ::com::sun::star::lang;
++using namespace ::com::sun::star::uno;
++using namespace ::comphelper;
++using namespace ::std;;
++using namespace ::rtl;;
++
++namespace
++{
++    struct GVariantDeleter { void operator()(GVariant* pV) { g_variant_unref(pV); } };
++    struct GVariantBuilderDeleter { void operator()(GVariantBuilder* pVB) { g_variant_builder_unref(pVB); } };
++    template <typename T> struct GObjectDeleter { void operator()(T* pO) { g_object_unref(pO); } };
++    class GErrorWrapper
++    {
++        GError* m_pError;
++        public:
++            GErrorWrapper(GError* pError) : m_pError(pError) {};
++            ~GErrorWrapper()
++            {
++                if(!m_pError)
++                    return;
++                OUString sMsg = OUString::createFromAscii(m_pError->message);
++                g_error_free(m_pError);
++                throw RuntimeException(sMsg, NULL);
++            }
++            GError** getRef() { return &m_pError; }
++    };
++    static inline GDBusProxy* lcl_GetPackageKitProxy(const OUString sInterface)
++    {
++        const OString sFullInterface = rtl::OUStringToOString("org.freedesktop.PackageKit." + sInterface, RTL_TEXTENCODING_ASCII_US);
++        GErrorWrapper error(NULL);
++        GDBusProxy* proxy = NULL;
++        proxy = g_dbus_proxy_new_for_bus_sync (G_BUS_TYPE_SESSION,
++                               G_DBUS_PROXY_FLAGS_NONE, NULL,
++                               "org.freedesktop.PackageKit",
++                               "/org/freedesktop/PackageKit",
++                               reinterpret_cast<const gchar*>(sFullInterface.getStr()),
++                               NULL,
++                               error.getRef());
++        if(!proxy)
++            throw RuntimeException(OUString("couldnt get a proxy!"),NULL);
++        return proxy;
++    };
++}
++
++namespace shell { namespace sessioninstall
++{
++    SyncDbusSessionHelper::SyncDbusSessionHelper(Reference<XComponentContext> const&)
++    {
++        g_type_init ();
++    }
++    void SAL_CALL SyncDbusSessionHelper::InstallPackageNames( const ::sal_uInt32 nXid, const Sequence< OUString >& vPackages, const OUString& sInteraction ) throw (RuntimeException)
++    {
++        vector< OString > vPackagesOString;
++        vPackagesOString.reserve(vPackages.getLength());
++        boost::shared_ptr<GVariantBuilder> pBuilder(g_variant_builder_new(G_VARIANT_TYPE ("as")), GVariantBuilderDeleter());
++        for( const OUString* pPackage = stl_begin(vPackages); pPackage != stl_end(vPackages); ++pPackage)
++        {
++            vPackagesOString.push_back(rtl::OUStringToOString(*pPackage, RTL_TEXTENCODING_ASCII_US));
++            g_variant_builder_add(pBuilder.get(), "s", vPackagesOString.back().getStr());
++        }
++
++        const OString sInteractionAscii = OUStringToOString(sInteraction, RTL_TEXTENCODING_ASCII_US);
++        boost::shared_ptr<GDBusProxy> proxy(lcl_GetPackageKitProxy("Modify"), GObjectDeleter<GDBusProxy>());
++        GErrorWrapper error(NULL);
++        g_dbus_proxy_call_sync (proxy.get(),
++                         "InstallPackageNames",
++                         g_variant_new ("(uass)",
++                                sal::static_int_cast<guint32>(nXid),
++                                pBuilder.get(),
++                                sInteractionAscii.getStr()),
++                         G_DBUS_CALL_FLAGS_NONE,
++                         -1, /* timeout */
++                         NULL, /* cancellable */
++                         error.getRef());
++    }
++
++    void SAL_CALL SyncDbusSessionHelper::IsInstalled( const OUString& sPackagename, const OUString& sInteraction, ::sal_Bool& o_isInstalled ) throw (RuntimeException)
++    {
++        const OString sPackagenameAscii = OUStringToOString(sPackagename, RTL_TEXTENCODING_ASCII_US);
++        const OString sInteractionAscii = OUStringToOString(sInteraction, RTL_TEXTENCODING_ASCII_US);
++        boost::shared_ptr<GDBusProxy> proxy(lcl_GetPackageKitProxy("Query"), GObjectDeleter<GDBusProxy>());
++        GErrorWrapper error(NULL);
++        boost::shared_ptr<GVariant> result(g_dbus_proxy_call_sync (proxy.get(),
++                         "IsInstalled",
++                         g_variant_new ("(ss)",
++                                sPackagenameAscii.getStr(),
++                                sInteractionAscii.getStr()),
++                         G_DBUS_CALL_FLAGS_NONE,
++                         -1, /* timeout */
++                         NULL, /* cancellable */
++                         error.getRef()),GVariantDeleter());
++        if(result.get())
++            o_isInstalled = g_variant_get_boolean(g_variant_get_child_value(result.get(),0)) ? sal_True : sal_False;
++    }
++}}
++
++/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+Index: libreoffice-3.6.0~rc4/shell/source/sessioninstall/SyncDbusSessionHelper.hxx
+===================================================================
+--- /dev/null	1970-01-01 00:00:00.000000000 +0000
++++ libreoffice-3.6.0~rc4/shell/source/sessioninstall/SyncDbusSessionHelper.hxx	2012-08-21 03:01:38.136198444 +0200
+@@ -0,0 +1,60 @@
++/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
++/*
++ * This file is part of the LibreOffice project.
++ *
++ * This Source Code Form is subject to the terms of the Mozilla Public
++ * License, v. 2.0. If a copy of the MPL was not distributed with this
++ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
++ */
++
++#ifndef SHELL_SESSIONINSTALL_SYNCDBUSSESSIONHELPER_HXX
++#define SHELL_SESSIONINSTALL_SYNCDBUSSESSIONHELPER_HXX
++
++#include <com/sun/star/lang/XMultiServiceFactory.hpp>
++#include <com/sun/star/uno/XComponentContext.hpp>
++#include <org/freedesktop/PackageKit/XSyncDbusSessionHelper.hpp>
++#include <cppuhelper/implbase1.hxx>
++
++namespace shell { namespace sessioninstall
++{
++    class SyncDbusSessionHelper : public ::cppu::WeakImplHelper1< ::org::freedesktop::PackageKit::XSyncDbusSessionHelper >
++    {
++        public:
++            SyncDbusSessionHelper(::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext> const&);
++            virtual ~SyncDbusSessionHelper() {};
++            // XModify Methods
++            virtual void SAL_CALL InstallPackageNames( ::sal_uInt32 xid, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& packages, const ::rtl::OUString& interaction ) throw (::com::sun::star::uno::RuntimeException);
++
++            virtual void SAL_CALL InstallPackageFiles( ::sal_uInt32 xid, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& files, const ::rtl::OUString& interaction ) throw (::com::sun::star::uno::RuntimeException)
++                { throw ::com::sun::star::uno::RuntimeException(); }; // not implemented
++            virtual void SAL_CALL InstallProvideFiles( ::sal_uInt32 xid, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& files, const ::rtl::OUString& interaction ) throw (::com::sun::star::uno::RuntimeException)
++                { throw ::com::sun::star::uno::RuntimeException(); }; // not implemented
++            virtual void SAL_CALL InstallCatalogs( ::sal_uInt32 xid, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& files, const ::rtl::OUString& interaction ) throw (::com::sun::star::uno::RuntimeException)
++                { throw ::com::sun::star::uno::RuntimeException(); }; // not implemented
++            virtual void SAL_CALL InstallMimeTypes( ::sal_uInt32 xid, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& mime_types, const ::rtl::OUString& interaction ) throw (::com::sun::star::uno::RuntimeException)
++                { throw ::com::sun::star::uno::RuntimeException(); }; // not implemented
++            virtual void SAL_CALL InstallFontconfigRessources( ::sal_uInt32 xid, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& resources, const ::rtl::OUString& interaction ) throw (::com::sun::star::uno::RuntimeException)
++                { throw ::com::sun::star::uno::RuntimeException(); }; // not implemented
++            virtual void SAL_CALL InstalliGStreamerRessources( ::sal_uInt32 xid, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& resources, const ::rtl::OUString& interaction ) throw (::com::sun::star::uno::RuntimeException)
++                { throw ::com::sun::star::uno::RuntimeException(); }; // not implemented
++            virtual void SAL_CALL InstallRessources( ::sal_uInt32 xid, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& types, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& resources, const ::rtl::OUString& interaction ) throw (::com::sun::star::uno::RuntimeException)
++                { throw ::com::sun::star::uno::RuntimeException(); }; // not implemented
++            virtual void SAL_CALL RemovePackageByFiles( ::sal_uInt32 xid, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& files, const ::rtl::OUString& interaction ) throw (::com::sun::star::uno::RuntimeException)
++                { throw ::com::sun::star::uno::RuntimeException(); }; // not implemented
++            virtual void SAL_CALL InstallPrinterDrivers( ::sal_uInt32 xid, const ::com::sun::star::uno::Sequence< ::rtl::OUString >& files, const ::rtl::OUString& interaction ) throw (::com::sun::star::uno::RuntimeException)
++                { throw ::com::sun::star::uno::RuntimeException(); }; // not implemented
++            // XQuery Methods
++            virtual void SAL_CALL IsInstalled( const ::rtl::OUString& package_name, const ::rtl::OUString& interaction, ::sal_Bool& installed ) throw (::com::sun::star::uno::RuntimeException);
++
++            virtual void SAL_CALL SearchFile( const ::rtl::OUString& file_name, const ::rtl::OUString& interaction, ::sal_Bool& installed, ::rtl::OUString& package_name ) throw (::com::sun::star::uno::RuntimeException)
++                { throw ::com::sun::star::uno::RuntimeException(); }; // not implemented
++
++        private:
++            SyncDbusSessionHelper(); // never implemented
++            SyncDbusSessionHelper( const SyncDbusSessionHelper& ); // never implemented
++            SyncDbusSessionHelper& operator=( const SyncDbusSessionHelper& ); // never implemented
++    };
++}}
++
++#endif // SHELL_SESSIONINSTALL_SYNCDBUSSESSIONHELPER_HXX
++/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+Index: libreoffice-3.6.0~rc4/shell/source/sessioninstall/losessioninstall.component
+===================================================================
+--- /dev/null	1970-01-01 00:00:00.000000000 +0000
++++ libreoffice-3.6.0~rc4/shell/source/sessioninstall/losessioninstall.component	2012-08-21 03:01:38.136198444 +0200
+@@ -0,0 +1,15 @@
++<?xml version="1.0" encoding="UTF-8"?>
++<!--
++ * This file is part of the LibreOffice project.
++ *
++ * This Source Code Form is subject to the terms of the Mozilla Public
++ * License, v. 2.0. If a copy of the MPL was not distributed with this
++ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
++ *
++-->
++<component loader="com.sun.star.loader.SharedLibrary"
++    xmlns="http://openoffice.org/2010/uno-components";>
++  <implementation name="org.libreoffice.comp.shell.sessioninstall.SyncDbusSessionHelper">
++    <service name="org.freedesktop.PackageKit.SyncDbusSessionHelper"/>
++  </implementation>
++</component>
+Index: libreoffice-3.6.0~rc4/shell/source/sessioninstall/services.cxx
+===================================================================
+--- /dev/null	1970-01-01 00:00:00.000000000 +0000
++++ libreoffice-3.6.0~rc4/shell/source/sessioninstall/services.cxx	2012-08-21 03:01:38.136198444 +0200
+@@ -0,0 +1,31 @@
++/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
++/*
++ * This file is part of the LibreOffice project.
++ *
++ * This Source Code Form is subject to the terms of the Mozilla Public
++ * License, v. 2.0. If a copy of the MPL was not distributed with this
++ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
++ */
++
++#include <SyncDbusSessionHelper.hxx>
++#include <comphelper/servicedecl.hxx>
++#include <uno/environment.h>
++
++namespace sdecl = ::comphelper::service_decl;
++
++sdecl::class_< ::shell::sessioninstall::SyncDbusSessionHelper> SyncDbusSessionHelperServiceImpl;
++
++const sdecl::ServiceDecl SyncDbusSessionHelperServiceDecl(
++    SyncDbusSessionHelperServiceImpl,
++    "org.libreoffice.comp.shell.sessioninstall.SyncDbusSessionHelper",
++    "org.freedesktop.PackageKit.SyncDbusSessionHelper");
++
++COMPHELPER_SERVICEDECL_EXPORTS1(losessioninstall, SyncDbusSessionHelperServiceDecl);
++extern "C"
++{
++    SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory( sal_Char const* pImplName, ::com::sun::star::lang::XMultiServiceFactory* pServiceManager, ::com::sun::star::registry::XRegistryKey* pRegistryKey )
++        { return losessioninstall_component_getFactory(pImplName, pServiceManager, pRegistryKey); }
++}
++
++
++/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+Index: libreoffice-3.6.0~rc4/svtools/inc/svtools/templdlg.hxx
+===================================================================
+--- libreoffice-3.6.0~rc4.orig/svtools/inc/svtools/templdlg.hxx	2012-07-17 14:02:12.000000000 +0200
++++ libreoffice-3.6.0~rc4/svtools/inc/svtools/templdlg.hxx	2012-08-21 03:01:38.140198445 +0200
+@@ -47,6 +47,7 @@
+     svt::FixedHyperlink aMoreTemplatesLink;
+     FixedLine           aLine;
+     PushButton          aManageBtn;
++    PushButton          aPackageBtn;
+     PushButton          aEditBtn;
+     OKButton            aOKBtn;
+     CancelButton        aCancelBtn;
+@@ -60,6 +61,7 @@
+     DECL_DLLPRIVATE_LINK(           SendFocusHdl_Impl, void* );
+     DECL_DLLPRIVATE_LINK(           OKHdl_Impl, PushButton* );
+     DECL_DLLPRIVATE_LINK(           OrganizerHdl_Impl, void* );
++    DECL_DLLPRIVATE_LINK(           PackageHdl_Impl, void* );
+     DECL_DLLPRIVATE_LINK(           UpdateHdl_Impl, Timer* );
+     DECL_DLLPRIVATE_LINK(           OpenLinkHdl_Impl, void* );
+ 
+Index: libreoffice-3.6.0~rc4/svtools/source/contnr/templwin.cxx
+===================================================================
+--- libreoffice-3.6.0~rc4.orig/svtools/source/contnr/templwin.cxx	2012-07-17 14:02:12.000000000 +0200
++++ libreoffice-3.6.0~rc4/svtools/source/contnr/templwin.cxx	2012-08-21 03:01:38.140198445 +0200
+@@ -70,6 +70,7 @@
+ #include <com/sun/star/script/XTypeConverter.hpp>
+ #include <com/sun/star/system/XSystemShellExecute.hpp>
+ #include <com/sun/star/system/SystemShellExecuteFlags.hpp>
++#include <org/freedesktop/PackageKit/XSyncDbusSessionHelper.hpp>
+ #include <unotools/localedatawrapper.hxx>
+ #include <com/sun/star/container/XNameContainer.hpp>
+ #include <vcl/waitobj.hxx>
+@@ -1425,6 +1426,7 @@
+     aMoreTemplatesLink  ( this, SvtResId( FT_DOCTEMPLATE_LINK ) ),
+     aLine               ( this, SvtResId( FL_DOCTEMPLATE ) ),
+     aManageBtn          ( this, SvtResId( BTN_DOCTEMPLATE_MANAGE ) ),
++    aPackageBtn         ( this, SvtResId( BTN_DOCTEMPLATE_PACKAGE ) ),
+     aEditBtn            ( this, SvtResId( BTN_DOCTEMPLATE_EDIT ) ),
+     aOKBtn              ( this, SvtResId( BTN_DOCTEMPLATE_OPEN ) ),
+     aCancelBtn          ( this, SvtResId( BTN_DOCTEMPLATE_CANCEL ) ),
+@@ -1454,6 +1456,7 @@
+        aMoreTemplatesLink.Hide();
+ 
+     aManageBtn.SetClickHdl( LINK( this, SvtDocumentTemplateDialog, OrganizerHdl_Impl ) );
++    aPackageBtn.SetClickHdl( LINK( this, SvtDocumentTemplateDialog, PackageHdl_Impl ) );
+     Link aLink = LINK( this, SvtDocumentTemplateDialog, OKHdl_Impl );
+     aEditBtn.SetClickHdl( aLink );
+     aOKBtn.SetClickHdl( aLink );
+@@ -1502,6 +1505,9 @@
+     aPos = aHelpBtn.GetPosPixel();
+     aPos.Y() -= nDelta;
+     aHelpBtn.SetPosPixel( aPos );
++    aPos = aPackageBtn.GetPosPixel();
++    aPos.Y() -= nDelta;
++    aPackageBtn.SetPosPixel( aPos );
+ 
+     pImpl->pWin->Show();
+ 
+@@ -1636,6 +1642,21 @@
+     return 0;
+ }
+ 
++IMPL_LINK_NOARG(SvtDocumentTemplateDialog, PackageHdl_Impl)
++{
++    try
++    {
++        Reference< org::freedesktop::PackageKit::XModify > xModify(::comphelper::getProcessServiceFactory()->createInstance("org.freedesktop.PackageKit.SyncDbusSessionHelper"), UNO_QUERY);
++        Sequence< ::rtl::OUString > vPackages(1);
++        vPackages[0] = "libreoffice-templates";
++        ::rtl::OUString sInteraction("");
++        xModify->InstallPackageNames(0, vPackages, sInteraction);
++    }
++    catch(...)
++    { }
++    return 0;
++}
++
+ // ------------------------------------------------------------------------
+ 
+ IMPL_LINK ( SvtDocumentTemplateDialog, UpdateHdl_Impl, Timer*, _pEventSource )
+Index: libreoffice-3.6.0~rc4/svtools/source/contnr/templwin.hrc
+===================================================================
+--- libreoffice-3.6.0~rc4.orig/svtools/source/contnr/templwin.hrc	2012-07-17 14:02:12.000000000 +0200
++++ libreoffice-3.6.0~rc4/svtools/source/contnr/templwin.hrc	2012-08-21 03:01:38.140198445 +0200
+@@ -34,6 +34,7 @@
+ #define BTN_DOCTEMPLATE_CANCEL  14
+ #define BTN_DOCTEMPLATE_HELP    15
+ #define FT_DOCTEMPLATE_LINK     16
++#define BTN_DOCTEMPLATE_PACKAGE 17
+ 
+ #define TI_DOCTEMPLATE_BACK     1
+ #define TI_DOCTEMPLATE_PREV     2
+Index: libreoffice-3.6.0~rc4/svtools/source/contnr/templwin.src
+===================================================================
+--- libreoffice-3.6.0~rc4.orig/svtools/source/contnr/templwin.src	2012-07-17 14:02:12.000000000 +0200
++++ libreoffice-3.6.0~rc4/svtools/source/contnr/templwin.src	2012-08-21 03:01:38.140198445 +0200
+@@ -212,6 +212,13 @@
+         Pos = MAP_APPFONT( 0, 219 );
+         Size = MAP_APPFONT( 320, 8 );
+     };
++    PushButton BTN_DOCTEMPLATE_PACKAGE
++    {
++        HelpID = "svtools:PushButton:DLG_DOCTEMPLATE:BTN_DOCTEMPLATE_PACKAGE";
++        Pos = MAP_APPFONT( 208, 206 );
++        Size = MAP_APPFONT( 106, 14 );
++        Text [ en-US ] = "Install Template Pack";
++    };
+     PushButton BTN_DOCTEMPLATE_MANAGE
+     {
+         HelpID = "svtools:PushButton:DLG_DOCTEMPLATE:BTN_DOCTEMPLATE_MANAGE";
diff --git a/patches/series b/patches/series
index 5ce7e6a..47617a9 100644
--- a/patches/series
+++ b/patches/series
@@ -29,3 +29,4 @@ dont-let-autoextension-interfere-with-kfiledialog.diff
 lp-753627-readd-updated-Ubuntu-brand-palette-colors.diff
 remove-broken-mysqlcon-version-check.diff
 fdo-51324-lp-1017125-rhbz-806236-rhbz-823272-erase-o.diff
+packagekit.diff

-- 
LibreOffice packaging repository


Reply to: