Hi,
I have submitted a patch for review:
https://gerrit.libreoffice.org/3735
To pull it, you can do:
git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/35/3735/1
sfx2: kill tiny qstart_gtk library
Include the source file directly into sfx library,
like we do for Windows and Mac OS X.
notify_file_changed now checks for the sfx library.
Change-Id: I18d47082065371e4d6c670bc636bc7e352d36786
---
M scp2/InstallModule_gnome.mk
M scp2/source/gnome/file_gnome.scp
M scp2/source/gnome/module_gnome.scp
M scp2/source/ooo/file_library_ooo.scp
D sfx2/Library_qstart_gtk.mk
M sfx2/Library_sfx.mk
M sfx2/Module_sfx2.mk
M sfx2/source/appl/shutdownicon.cxx
M sfx2/source/appl/shutdownicon.hxx
M sfx2/source/appl/shutdowniconunx.cxx
10 files changed, 24 insertions(+), 152 deletions(-)
diff --git a/scp2/InstallModule_gnome.mk b/scp2/InstallModule_gnome.mk
index 816f3b2..193fa53 100644
--- a/scp2/InstallModule_gnome.mk
+++ b/scp2/InstallModule_gnome.mk
@@ -17,7 +17,6 @@
ENABLE_GTK \
ENABLE_GTK3 \
ENABLE_LOCKDOWN \
- ENABLE_SYSTRAY_GTK \
))
$(eval $(call gb_InstallModule_add_scpfiles,scp2/gnome,\
diff --git a/scp2/source/gnome/file_gnome.scp b/scp2/source/gnome/file_gnome.scp
index 9f824d8..7790da9 100644
--- a/scp2/source/gnome/file_gnome.scp
+++ b/scp2/source/gnome/file_gnome.scp
@@ -48,12 +48,3 @@
#ifdef ENABLE_GCONF
STD_LIB_FILE( gid_File_Lib_Gconfbe, gconfbe1 )
#endif
-
-#ifdef ENABLE_SYSTRAY_GTK
-File gid_File_Lib_QStart_Gtk
- Name = LIBNAME(qstart_gtk);
- LIB_FILE_BODY;
- Styles = (PACKED);
- Dir = SCP2_OOO_BIN_DIR;
-End
-#endif
diff --git a/scp2/source/gnome/module_gnome.scp b/scp2/source/gnome/module_gnome.scp
index 3a2604d..9f08a80 100644
--- a/scp2/source/gnome/module_gnome.scp
+++ b/scp2/source/gnome/module_gnome.scp
@@ -47,9 +47,6 @@
#ifdef ENABLE_GTK3
gid_File_Lib_Vclplug_Gtk3,
#endif
-#ifdef ENABLE_SYSTRAY_GTK
- gid_File_Lib_QStart_Gtk,
-#endif
#ifdef ENABLE_GNOMEVFS
gid_File_Lib_Gnomevfs, gid_File_Bin_Gnome_Set_Default_Application,
#endif
diff --git a/scp2/source/ooo/file_library_ooo.scp b/scp2/source/ooo/file_library_ooo.scp
index ab3105e..3c20df3 100644
--- a/scp2/source/ooo/file_library_ooo.scp
+++ b/scp2/source/ooo/file_library_ooo.scp
@@ -164,19 +164,6 @@
#endif
-#ifdef UNX
-#ifdef ENABLE_GTK
-#ifdef ENABLE_SYSTRAY_GTK
-File gid_File_Lib_QStart_Gtk
- Name = LIBNAME(qstart_gtk);
- LIB_FILE_BODY;
- Styles = (PACKED);
- Dir = SCP2_OOO_BIN_DIR;
-End
-#endif
-#endif
-#endif
-
File gid_File_Lib_Dbpool
LIB_FILE_BODY;
Styles = (PACKED);
diff --git a/sfx2/Library_qstart_gtk.mk b/sfx2/Library_qstart_gtk.mk
deleted file mode 100644
index 2090658..0000000
--- a/sfx2/Library_qstart_gtk.mk
+++ /dev/null
@@ -1,69 +0,0 @@
-# -*- 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/.
-#
-# This file incorporates work covered by the following license notice:
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed
-# with this work for additional information regarding copyright
-# ownership. The ASF licenses this file to you under the Apache
-# License, Version 2.0 (the "License"); you may not use this file
-# except in compliance with the License. You may obtain a copy of
-# the License at http://www.apache.org/licenses/LICENSE-2.0 .
-#
-
-
-$(eval $(call gb_Library_Library,qstart_gtk))
-
-$(eval $(call gb_Library_set_include,qstart_gtk,\
- $$(INCLUDE) \
- -I$(SRCDIR)/sfx2/inc \
- -I$(SRCDIR)/include/sfx2/ \
-))
-
-$(eval $(call gb_Library_use_sdk_api,qstart_gtk))
-
-$(eval $(call gb_Library_add_defs,qstart_gtk,-DENABLE_QUICKSTART_APPLET))
-
-ifeq ($(ENABLE_SYSTRAY_GTK),TRUE)
-$(eval $(call gb_Library_add_defs,qstart_gtk,-DENABLE_SYSTRAY_GTK))
-endif
-
-$(eval $(call gb_Library_use_libraries,qstart_gtk,\
- comphelper \
- cppu \
- cppuhelper \
- fwe \
- i18nlangtag \
- sal \
- sax \
- sb \
- sot \
- svl \
- svt \
- tk \
- tl \
- ucbhelper \
- utl \
- vcl \
- sfx \
- $(gb_UWINAPI) \
-))
-
-$(eval $(call gb_Library_use_externals,qstart_gtk,\
- boost_headers \
- gio \
- gtk \
- libxml2 \
-))
-
-$(eval $(call gb_Library_add_exception_objects,qstart_gtk,\
- sfx2/source/appl/shutdowniconunx \
-))
-
-# vim: set noet sw=4 ts=4:
diff --git a/sfx2/Library_sfx.mk b/sfx2/Library_sfx.mk
index ef81f31..2188629 100644
--- a/sfx2/Library_sfx.mk
+++ b/sfx2/Library_sfx.mk
@@ -43,14 +43,6 @@
$(if $(filter TRUE,$(ENABLE_CUPS)),-DENABLE_CUPS) \
))
-ifeq ($(ENABLE_SYSTRAY_GTK),TRUE)
-$(eval $(call gb_Library_add_defs,sfx,\
- -DENABLE_QUICKSTART_APPLET \
- -DENABLE_SYSTRAY_GTK \
- -DPLUGIN_NAME=libqstart_gtk$(gb_Library_OOOEXT) \
-))
-endif
-
$(eval $(call gb_Library_use_libraries,sfx,\
basegfx \
comphelper \
@@ -285,9 +277,8 @@
$(eval $(call gb_Library_use_system_darwin_frameworks,sfx,\
Cocoa \
))
-endif
-ifeq ($(OS),WNT)
+else ifeq ($(OS),WNT)
$(eval $(call gb_Library_add_exception_objects,sfx,\
sfx2/source/appl/shutdowniconw32 \
@@ -302,6 +293,22 @@
uuid \
))
+else ifeq ($(ENABLE_SYSTRAY_GTK),TRUE)
+
+$(eval $(call gb_Library_add_defs,sfx,\
+ -DENABLE_QUICKSTART_APPLET \
+ -DENABLE_SYSTRAY_GTK \
+))
+
+$(eval $(call gb_Library_use_externals,sfx,\
+ gio \
+ gtk \
+))
+
+$(eval $(call gb_Library_add_exception_objects,sfx,\
+ sfx2/source/appl/shutdowniconunx \
+))
+
endif
# Runtime dependency for unit-tests
diff --git a/sfx2/Module_sfx2.mk b/sfx2/Module_sfx2.mk
index 07facc6..8b749a1 100644
--- a/sfx2/Module_sfx2.mk
+++ b/sfx2/Module_sfx2.mk
@@ -37,14 +37,6 @@
))
endif
-ifneq (,$(filter LINUX DRAGONFLY OPENBSD FREEBSD NETBSD SOLARIS, $(OS)))
-ifeq ($(ENABLE_SYSTRAY_GTK),TRUE)
-$(eval $(call gb_Module_add_targets,sfx2,\
- Library_qstart_gtk \
-))
-endif
-endif
-
#todo: clean up quickstarter stuff in both libraries
#todo: move standard pool to svl
diff --git a/sfx2/source/appl/shutdownicon.cxx b/sfx2/source/appl/shutdownicon.cxx
index 2fa5ba9..9e17cfa 100644
--- a/sfx2/source/appl/shutdownicon.cxx
+++ b/sfx2/source/appl/shutdownicon.cxx
@@ -80,10 +80,6 @@
# endif
#endif
-#if defined(UNX) && defined(ENABLE_SYSTRAY_GTK) && !defined(PLUGIN_NAME)
-#define PLUGIN_NAME "libqstart_gtklo.so"
-#endif
-
class SfxNotificationListener_Impl : public cppu::WeakImplHelper1< XDispatchResultListener >
{
public:
@@ -138,44 +134,17 @@
*pDeInit = aqua_shutdown_systray;
return true;
# else // UNX
- osl::Module *pPlugin;
- pPlugin = new osl::Module();
-
- oslGenericFunction pTmpInit = NULL;
- oslGenericFunction pTmpDeInit = NULL;
-
-#define DOSTRING( x ) #x
-#define STRING( x ) DOSTRING( x )
-
- if ( pPlugin->loadRelative( &thisModule, OUString (STRING( PLUGIN_NAME ) ) ) )
- {
- pTmpInit = pPlugin->getFunctionSymbol(
- OUString( "plugin_init_sys_tray" ) );
- pTmpDeInit = pPlugin->getFunctionSymbol(
- OUString( "plugin_shutdown_sys_tray" ) );
- }
- if ( !pTmpInit || !pTmpDeInit )
- {
- delete pPlugin;
- pPlugin = NULL;
- }
if ( pModule )
{
- *pModule = pPlugin;
- *pInit = pTmpInit;
- *pDeInit = pTmpDeInit;
+ *pInit = plugin_init_sys_tray;
+ *pDeInit = plugin_shutdown_sys_tray;
}
- else
- {
- bool bRet = pPlugin != NULL;
- delete pPlugin;
- return bRet;
- }
+ return true;
# endif // UNX
#endif // ENABLE_QUICKSTART_APPLET
-#if !defined( ENABLE_QUICKSTART_APPLET ) || defined( UNX )
- // Avoid unreachable code. In the ENABLE_QUICKSTART_APPLET && !UNX
+#if !defined( ENABLE_QUICKSTART_APPLET )
+ // Avoid unreachable code. In the ENABLE_QUICKSTART_APPLET
// case, we have already returned.
if ( pModule )
{
diff --git a/sfx2/source/appl/shutdownicon.hxx b/sfx2/source/appl/shutdownicon.hxx
index 958c59d..52b6846 100644
--- a/sfx2/source/appl/shutdownicon.hxx
+++ b/sfx2/source/appl/shutdownicon.hxx
@@ -35,7 +35,6 @@
#include <osl/module.hxx>
#include <sfx2/sfxuno.hxx>
#include <cppuhelper/compbase4.hxx>
-#include <sfx2/dllapi.h>
class ResMgr;
namespace sfx2
@@ -60,7 +59,7 @@
#define STARTMODULE_URL ".uno:ShowStartModule"
#endif
-class SFX2_DLLPUBLIC ShutdownIcon : public ShutdownIconServiceBase
+class ShutdownIcon : public ShutdownIconServiceBase
{
::osl::Mutex m_aMutex;
bool m_bVeto;
diff --git a/sfx2/source/appl/shutdowniconunx.cxx b/sfx2/source/appl/shutdowniconunx.cxx
index 2d3ecf7..02759d1 100644
--- a/sfx2/source/appl/shutdowniconunx.cxx
+++ b/sfx2/source/appl/shutdowniconunx.cxx
@@ -410,7 +410,7 @@
#endif
}
-void SAL_DLLPUBLIC_EXPORT plugin_shutdown_sys_tray()
+void plugin_shutdown_sys_tray()
{
::SolarMutexGuard aGuard;
if( !pTrayIcon )
--
To view, visit https://gerrit.libreoffice.org/3735
To unsubscribe, visit https://gerrit.libreoffice.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I18d47082065371e4d6c670bc636bc7e352d36786
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Matúš Kukan <matus.kukan@gmail.com>
Context
- [PATCH] sfx2: kill tiny qstart_gtk library · via Code Review
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.