From dc1efa4424d5cc285911e872e5e1e2505c62a016 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 14 Dec 2011 15:12:20 +0100 Subject: extensions/stardiv considered obsolete --- extensions/stardiv/fontest/fontest.idl | 111 ------------------------------- extensions/stardiv/fontest/makefile.mk | 48 ------------- extensions/stardiv/oinstchk/makefile.mk | 47 ------------- extensions/stardiv/oinstchk/oinstchk.idl | 108 ------------------------------ extensions/stardiv/pgp/makefile.mk | 53 --------------- 5 files changed, 367 deletions(-) delete mode 100644 extensions/stardiv/fontest/fontest.idl delete mode 100644 extensions/stardiv/fontest/makefile.mk delete mode 100644 extensions/stardiv/oinstchk/makefile.mk delete mode 100644 extensions/stardiv/oinstchk/oinstchk.idl delete mode 100644 extensions/stardiv/pgp/makefile.mk diff --git a/extensions/stardiv/fontest/fontest.idl b/extensions/stardiv/fontest/fontest.idl deleted file mode 100644 index c000a5f0470b..000000000000 --- a/extensions/stardiv/fontest/fontest.idl +++ /dev/null @@ -1,111 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ -#ifndef _EXTENSIONS_FONTEST_IDL -#define _EXTENSIONS_FONTEST_IDL - - -#include -#include -#include - -module stardiv -{ - - module extensions - { - - module fontest - { - -/** a flag called "surpressed" changes the action of check and checkWithDialog - @author Berndt Reinhold - @see stardiv::uno::XInterface - */ - [ uik(BF6D5A72-B53B-11d2-A17B00A0-243D2A0B), ident("FonTest", 1.0) ] - interface XFonTest: stardiv::uno::XInterface - { - /** Checks if "StarMath" and "StarBats" fonts are installed. -

- @param bForce: If TRUE check the fonts even if surpressed. - Otherwise check the fonts only if not surpressed. - @see resetSurpressed - @returns TRUE if the fonts are available. Also TRUE if surpressed - is TRUE and bForce is FALSE. Otherwise return FALSE. -

- */ - boolean check([in] boolean bForce); - - /** Same as check but additional shows a dialog if result is FALSE. -

- @param bForce: same as in check - @see check - @see resetSurpressed -

- */ - boolean checkWithDialog([in] boolean bForce); - - /** Shows a dialog if the font "StarBats" or "StarMath" is missing. -

- The dialog shows which font(s) is/are missing and have a checkbox, - that represents the state of the flag surpressed. This dialog is - the only way to set the flag surpressed to TRUE. This method is - not affected by the value of the flag surpressed. - @see resetSurpressed -

- */ - boolean executeDialog(); - - /** Set flag surpressed to FALSE -

- The flag surpressed is stored in the registry. If surpressed is - FALSE the methods check and checkWithDialog ignores the parameter - bForce. if surpressed is TRUE check and checkWithDialog only - perform any action if their parameter bForce is TRUE. otherwise - they simply return TRUE. -

- */ - void resetSurpressed(); - }; - -/*-------------- services ------------------------------------------- - This service is the implementation of the interface XFonTest. - @version 1.0 - @author Berndt Reinhold - */ - - service FonTestService - { - interface XFonTest; - }; - -//------------------------------------------------------------------- - - }; // fontest - }; // extensions -}; // stardiv - -#endif diff --git a/extensions/stardiv/fontest/makefile.mk b/extensions/stardiv/fontest/makefile.mk deleted file mode 100644 index 3ea8d98cfc87..000000000000 --- a/extensions/stardiv/fontest/makefile.mk +++ /dev/null @@ -1,48 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -prjpch= - -PRJ=..$/.. - -PRJNAME=extensions -TARGET=fontestidl -IDLMAP=stardiv$/usrmap.idl -PACKAGE=stardiv$/fontest -ENABLE_EXCEPTIONS=TRUE - - -# --- Settings ----------------------------------------------------- -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -# ------------------------------------------------------------------ -IDLFILES= fontest.idl - -# ------------------------------------------------------------------ -.INCLUDE : target.mk -.INCLUDE : $(PRJ)$/util$/target.pmk - diff --git a/extensions/stardiv/oinstchk/makefile.mk b/extensions/stardiv/oinstchk/makefile.mk deleted file mode 100644 index ea496166956c..000000000000 --- a/extensions/stardiv/oinstchk/makefile.mk +++ /dev/null @@ -1,47 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -prjpch= - -PRJ=..$/.. - -PRJNAME=extensions -TARGET=oinstchkidl -IDLMAP=stardiv$/usrmap.idl -PACKAGE=stardiv$/oinstchk -ENABLE_EXCEPTIONS=TRUE - - -# --- Settings ----------------------------------------------------- -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -# ------------------------------------------------------------------ -IDLFILES= oinstchk.idl - -# ------------------------------------------------------------------ -.INCLUDE : target.mk -.INCLUDE : $(PRJ)$/util$/target.pmk diff --git a/extensions/stardiv/oinstchk/oinstchk.idl b/extensions/stardiv/oinstchk/oinstchk.idl deleted file mode 100644 index 04b3fbcd8a67..000000000000 --- a/extensions/stardiv/oinstchk/oinstchk.idl +++ /dev/null @@ -1,108 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ -#ifndef _INSTALLATION_OINSTCHK_IDL -#define _INSTALLATION_OINSTCHK_IDL - - -#include -#include -#include - -module stardiv -{ - - module installation - { - -/** a flag called "surpressed" changes the action of check and checkWithDialog - @author Berndt Reinhold - @see stardiv::uno::XInterface - */ - - [ uik(BF6D5A72-B53B-11d2-A17B00A0-243D2A0B), ident("OInstChk", 1.0) ] - interface XOInstChk: stardiv::uno::XInterface - { - /** Checks if "StarMath" and "StarBats" fonts are installed. -

- @param bForce: If TRUE check the fonts even if surpressed. - Otherwise check the fonts only if not surpressed. - @see resetSurpressed - @returns TRUE if the fonts are available. Also TRUE if surpressed - is TRUE and bForce is FALSE. Otherwise return FALSE. -

- */ - boolean check([in] boolean bForce); - - /** Same as check but additional shows a dialog if result is FALSE. -

- @param bForce: same as in check - @see check - @see resetSurpressed -

- */ - boolean checkWithDialog([in] boolean bForce); - - /** Shows a dialog if the font "StarBats" or "StarMath" is missing. -

- The dialog shows which font(s) is/are missing and have a checkbox, - that represents the state of the flag surpressed. This dialog is - the only way to set the flag surpressed to TRUE. This method is - not affected by the value of the flag surpressed. - @see resetSurpressed -

- */ - boolean executeDialog(); - - /** Set flag surpressed to FALSE -

- The flag surpressed is stored in the registry. If surpressed is - FALSE the methods check and checkWithDialog ignores the parameter - bForce. if surpressed is TRUE check and checkWithDialog only - perform any action if their parameter bForce is TRUE. otherwise - they simply return TRUE. -

- */ - void resetSurpressed(); - }; - -/*-------------- services ------------------------------------------- - This service is the implementation of the interface XOInstChk. - @version 1.0 - @author Berndt Reinhold - */ - - service OInstChkService - { - interface XOInstChk; - }; - -//------------------------------------------------------------------- - - }; // installation -}; // stardiv - -#endif diff --git a/extensions/stardiv/pgp/makefile.mk b/extensions/stardiv/pgp/makefile.mk deleted file mode 100644 index dbce7d52b388..000000000000 --- a/extensions/stardiv/pgp/makefile.mk +++ /dev/null @@ -1,53 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -prjpch= - -PRJ=..$/.. - -PRJNAME=extensions -TARGET=pgpidl -IDLMAP=stardiv$/usrmap.idl -PACKAGE=stardiv$/extensions$/pgp -ENABLE_EXCEPTIONS=TRUE - -# --- Settings ----------------------------------------------------- - -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -#javauno= - -# --- Files -------------------------------------------------------- - -JARFILES+= usr.jar -IDLFILES= pgp.idl - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk -.INCLUDE : $(PRJ)$/util$/target.pmk - -- cgit From ba1f609d0dd77c5adc2504e90e341c306b5ee8f5 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 14 Dec 2011 19:57:14 +0100 Subject: extensions: convert update stuff to gbuild The updchk is renamed to updatecheckui so it does not collide with updchk.uno. --- Repository.mk | 3 + extensions/AllLangResTarget_upd.mk | 41 ++++++ extensions/AllLangResTarget_updchk.mk | 43 +++++++ extensions/Configuration_updchk.mk | 37 ++++++ extensions/CppunitTest_extensions_test_update.mk | 2 +- extensions/Library_updatecheckui.mk | 51 ++++++++ extensions/Library_updatefeed.mk | 48 +++++++ extensions/Library_updchk.mk | 63 +++++++++ extensions/Module_extensions.mk | 9 ++ extensions/prj/build.lst | 4 +- extensions/prj/makefile.mk | 1 + extensions/source/update/check/Addons.xcu | 26 ---- extensions/source/update/check/Jobs.xcu | 42 ------ extensions/source/update/check/makefile.mk | 142 --------------------- .../update/check/org/openoffice/Office/Addons.xcu | 26 ++++ .../update/check/org/openoffice/Office/Jobs.xcu | 42 ++++++ extensions/source/update/feed/makefile.mk | 72 ----------- extensions/source/update/ui/makefile.mk | 82 ------------ postprocess/packcomponents/makefile.mk | 6 +- postprocess/packregistry/makefile.mk | 4 +- scp2/source/ooo/file_library_ooo.scp | 2 +- solenv/gbuild/Configuration.mk | 5 + 22 files changed, 377 insertions(+), 374 deletions(-) create mode 100644 extensions/AllLangResTarget_upd.mk create mode 100644 extensions/AllLangResTarget_updchk.mk create mode 100644 extensions/Configuration_updchk.mk create mode 100644 extensions/Library_updatecheckui.mk create mode 100644 extensions/Library_updatefeed.mk create mode 100644 extensions/Library_updchk.mk create mode 100644 extensions/prj/makefile.mk delete mode 100644 extensions/source/update/check/Addons.xcu delete mode 100644 extensions/source/update/check/Jobs.xcu delete mode 100644 extensions/source/update/check/makefile.mk create mode 100644 extensions/source/update/check/org/openoffice/Office/Addons.xcu create mode 100644 extensions/source/update/check/org/openoffice/Office/Jobs.xcu delete mode 100644 extensions/source/update/feed/makefile.mk delete mode 100644 extensions/source/update/ui/makefile.mk diff --git a/Repository.mk b/Repository.mk index d2b5c49373ef..815ab70349e2 100644 --- a/Repository.mk +++ b/Repository.mk @@ -224,6 +224,7 @@ $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ tl \ unordf \ unoxml \ + updatecheckui \ utl \ uui \ vbahelper \ @@ -351,6 +352,8 @@ $(eval $(call gb_Helper_register_libraries,UNOLIBS_OOO, \ slideshow \ stocservices \ stringresource \ + updatefeed \ + updchk \ vbaevents \ vbaobj \ vbaswobj \ diff --git a/extensions/AllLangResTarget_upd.mk b/extensions/AllLangResTarget_upd.mk new file mode 100644 index 000000000000..872e49df0aab --- /dev/null +++ b/extensions/AllLangResTarget_upd.mk @@ -0,0 +1,41 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_AllLangResTarget_AllLangResTarget,upd)) + +$(eval $(call gb_AllLangResTarget_add_srs,upd,\ + upd/res \ +)) + +$(eval $(call gb_SrsTarget_SrsTarget,upd/res)) + +$(eval $(call gb_SrsTarget_add_files,upd/res,\ + extensions/source/update/check/updatehdl.src \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/AllLangResTarget_updchk.mk b/extensions/AllLangResTarget_updchk.mk new file mode 100644 index 000000000000..c3cd02cb20a0 --- /dev/null +++ b/extensions/AllLangResTarget_updchk.mk @@ -0,0 +1,43 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_AllLangResTarget_AllLangResTarget,updchk)) + +$(eval $(call gb_AllLangResTarget_set_reslocation,updchk,extensions/source/update/ui)) + +$(eval $(call gb_AllLangResTarget_add_srs,updchk,\ + updchk/res \ +)) + +$(eval $(call gb_SrsTarget_SrsTarget,updchk/res)) + +$(eval $(call gb_SrsTarget_add_files,updchk/res,\ + extensions/source/update/ui/updatecheckui.src \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Configuration_updchk.mk b/extensions/Configuration_updchk.mk new file mode 100644 index 000000000000..2f392228fedf --- /dev/null +++ b/extensions/Configuration_updchk.mk @@ -0,0 +1,37 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +# TODO is this really supposed to be delivered to the officecfg registry? +$(eval $(call gb_Configuration_Configuration_nozip,updchk)) + +$(eval $(call gb_Configuration_add_spool_modules,updchk,extensions/source/update/check,\ + org/openoffice/Office/Jobs-onlineupdate.xcu \ + org/openoffice/Office/Addons-onlineupdate.xcu \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/CppunitTest_extensions_test_update.mk b/extensions/CppunitTest_extensions_test_update.mk index 3db886b0a524..36721e720fc1 100644 --- a/extensions/CppunitTest_extensions_test_update.mk +++ b/extensions/CppunitTest_extensions_test_update.mk @@ -73,7 +73,7 @@ $(eval $(call gb_CppunitTest_add_components,extensions_test_update,\ $(eval $(call gb_CppunitTest_add_old_components,extensions_test_update,\ ucb1 \ ucpfile1 \ - updatefeed \ + component/extensions/source/update/feed/updatefeed \ )) $(eval $(call gb_CppunitTest_set_args,extensions_test_update,\ diff --git a/extensions/Library_updatecheckui.mk b/extensions/Library_updatecheckui.mk new file mode 100644 index 000000000000..825142759352 --- /dev/null +++ b/extensions/Library_updatecheckui.mk @@ -0,0 +1,51 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,updatecheckui)) + +$(eval $(call gb_Library_set_componentfile,updatecheckui,extensions/source/update/ui/updchk)) + +$(eval $(call gb_Library_add_api,updatecheckui,\ + udkapi \ + offapi \ +)) + +$(eval $(call gb_Library_add_linked_libs,updatecheckui,\ + vcl \ + tl \ + comphelper \ + cppuhelper \ + cppu \ + sal \ +)) + +$(eval $(call gb_Library_add_exception_objects,updatecheckui,\ + extensions/source/update/ui/updatecheckui \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_updatefeed.mk b/extensions/Library_updatefeed.mk new file mode 100644 index 000000000000..01374b5f91fe --- /dev/null +++ b/extensions/Library_updatefeed.mk @@ -0,0 +1,48 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,updatefeed)) + +$(eval $(call gb_Library_set_componentfile,updatefeed,extensions/source/update/feed/updatefeed)) + +$(eval $(call gb_Library_add_api,updatefeed,\ + udkapi \ + offapi \ +)) + +$(eval $(call gb_Library_add_linked_libs,updatefeed,\ + cppuhelper \ + cppu \ + sal \ +)) + +$(eval $(call gb_Library_add_exception_objects,updatefeed,\ + extensions/source/update/feed/updatefeed \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_updchk.mk b/extensions/Library_updchk.mk new file mode 100644 index 000000000000..ba6d7364e7b0 --- /dev/null +++ b/extensions/Library_updchk.mk @@ -0,0 +1,63 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,updchk)) + +$(eval $(call gb_Library_set_componentfile,updchk,extensions/source/update/check/updchk.uno)) + +$(eval $(call gb_Library_add_api,updchk,\ + udkapi \ + offapi \ +)) + +$(eval $(call gb_Library_add_linked_libs,updchk,\ + comphelper \ + cppuhelper \ + cppu \ + sal \ +)) + +ifeq ($(OS),WNT) +$(eval $(call gb_Library_add_linked_libs,updchk,\ + ole32 \ + shell32 \ +)) +endif # OS WNT + +$(eval $(call gb_Library_use_external,updchk,curl)) + +$(eval $(call gb_Library_add_exception_objects,updchk,\ + extensions/source/update/check/download \ + extensions/source/update/check/updatecheck \ + extensions/source/update/check/updatecheckconfig \ + extensions/source/update/check/updatecheckjob \ + extensions/source/update/check/updatehdl \ + extensions/source/update/check/updateprotocol \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index cf44b2d8a7db..179170a6a9a6 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -26,6 +26,15 @@ $(eval $(call gb_Module_Module,extensions)) +$(eval $(call gb_Module_add_targets,extensions,\ + AllLangResTarget_upd \ + AllLangResTarget_updchk \ + Configuration_updchk \ + Library_updatecheckui \ + Library_updatefeed \ + Library_updchk \ +)) + $(eval $(call gb_Module_add_check_targets,extensions,\ CppunitTest_extensions_test_update \ )) diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index f29d117d3dc8..cc629f4f4ef8 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -26,10 +26,8 @@ ex extensions\source\logging nmake - all ex_logging ex_in ex extensions\source\config\ldap nmake - all ex_ldap ex_inc NULL ex extensions\source\nsplugin\source nmake - u ex_nsplugin ex_inc NULL ex extensions\source\nsplugin\source nmake - w ex_nsplugin ex_inc NULL -ex extensions\source\update\feed nmake - all ex_updchkfeed ex_inc NULL -ex extensions\source\update\check nmake - all ex_updchk ex_inc NULL -ex extensions\source\update\ui nmake - all ex_updchkui ex_inc NULL ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging ex_ldap ex_propctrlr ex_bib ex_plutil NULL +ex extensions\prj nmake - all ex_prj NULL # Fails at the moment # ex extensions\qa\complex\extensions nmake - all ex_complex ex_util NULL diff --git a/extensions/prj/makefile.mk b/extensions/prj/makefile.mk new file mode 100644 index 000000000000..0997622e00f6 --- /dev/null +++ b/extensions/prj/makefile.mk @@ -0,0 +1 @@ +.INCLUDE : gbuildbridge.mk diff --git a/extensions/source/update/check/Addons.xcu b/extensions/source/update/check/Addons.xcu deleted file mode 100644 index 8794ce858073..000000000000 --- a/extensions/source/update/check/Addons.xcu +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - vnd.sun.star.job:alias=UpdateCheck - - - - - - Check for ~Updates... - - - _self - - - - - - - - - diff --git a/extensions/source/update/check/Jobs.xcu b/extensions/source/update/check/Jobs.xcu deleted file mode 100644 index 840d630698cb..000000000000 --- a/extensions/source/update/check/Jobs.xcu +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - com.sun.star.setup.UpdateCheck - - - - true - - - 0 - - - 604800 - - - - - - false - - - true - - - false - - - - - - - - - - - - - diff --git a/extensions/source/update/check/makefile.mk b/extensions/source/update/check/makefile.mk deleted file mode 100644 index 47da869ea11e..000000000000 --- a/extensions/source/update/check/makefile.mk +++ /dev/null @@ -1,142 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/..$/.. - -PRJNAME=extensions -TARGET=updchk -PACKAGE=org.openoffice.Office - -LIBTARGET=NO -ENABLE_EXCEPTIONS=TRUE - -ABSXCSROOT=$(SOLARXMLDIR) -XCSROOT=.. -DTDDIR=$(ABSXCSROOT) -XSLDIR=$(ABSXCSROOT)$/processing -PROCESSOUT=$(MISC)$/$(TARGET) -PROCESSORDIR=$(SOLARBINDIR) - -# no validation by inspector class -NO_INSPECTION=TRUE - -# --- Settings --- - -.INCLUDE : settings.mk - -# no "lib" prefix -DLLPRE = - -# --- Files --- - -SRS2NAME=$(TARGET) -SRC2FILES=\ - updatehdl.src - -RESLIB2NAME=upd -RESLIB2SRSFILES= $(SRS)$/updchk.srs -RESLIB2DEPN= updatehdl.src updatehdl.hrc - -SLOFILES=\ - $(SLO)$/download.obj \ - $(SLO)$/updatecheck.obj \ - $(SLO)$/updatecheckjob.obj \ - $(SLO)$/updatecheckconfig.obj \ - $(SLO)$/updateprotocol.obj \ - $(SLO)$/updatehdl.obj - -SHL1NOCHECK=TRUE -SHL1TARGET=$(TARGET).uno -SHL1OBJS=$(SLOFILES) -SHL1DEF=$(MISC)$/$(SHL1TARGET).def - -SHL1IMPLIB=i$(SHL1TARGET) -SHL1STDLIBS= \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(CURLLIB) \ - $(SALLIB) \ - $(SHELL32LIB) \ - $(OLE32LIB) - -SHL1VERSIONMAP=$(SOLARENV)/src/component.map -SHL1DEF=$(MISC)$/$(SHL1TARGET).def -DEF1NAME=$(SHL1TARGET) - -PACKAGEDIR=$(subst,.,$/ $(PACKAGE)) -SPOOLDIR=$(MISC)$/registry$/spool - -XCUFILES= \ - Addons.xcu \ - Jobs.xcu - -MYXCUFILES= \ - $(SPOOLDIR)$/$(PACKAGEDIR)$/Addons$/Addons-onlineupdate.xcu \ - $(SPOOLDIR)$/$(PACKAGEDIR)$/Jobs$/Jobs-onlineupdate.xcu - -LOCALIZEDFILES= \ - Addons.xcu \ - Jobs.xcu - -.IF "$(test)" != "" -APP1TARGET=updateprotocoltest -APP1STDLIBS= $(SHL1STDLIBS) -APP1OBJS= \ - $(SLO)$/updateprotocol.obj \ - $(SLO)$/updateprotocoltest.obj - - -.ENDIF # "$(test)" != "" - -# --- Targets --- - -.INCLUDE : target.mk - -ALLTAR : $(MYXCUFILES) - -.IF "$(WITH_LANG)"!="" -XCU_SOURCEDIR:=$(PROCESSOUT)$/merge$/$(PACKAGEDIR) -.ELSE # "$(WITH_LANG)"!="" -XCU_SOURCEDIR:=. -.ENDIF # "$(WITH_LANG)"!="" - -$(SPOOLDIR)$/$(PACKAGEDIR)$/Addons$/Addons-onlineupdate.xcu : $(XCU_SOURCEDIR)$/Addons.xcu - @-$(MKDIRHIER) $(@:d) - @$(COPY) $< $@ - -$(SPOOLDIR)$/$(PACKAGEDIR)$/Jobs$/Jobs-onlineupdate.xcu : $(XCU_SOURCEDIR)$/Jobs.xcu - @-$(MKDIRHIER) $(@:d) - @$(COPY) $< $@ -# @$(PERL) transform.pl < $< > $@ - - -ALLTAR : $(MISC)/updchk.uno.component - -$(MISC)/updchk.uno.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - updchk.uno.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt updchk.uno.component diff --git a/extensions/source/update/check/org/openoffice/Office/Addons.xcu b/extensions/source/update/check/org/openoffice/Office/Addons.xcu new file mode 100644 index 000000000000..8794ce858073 --- /dev/null +++ b/extensions/source/update/check/org/openoffice/Office/Addons.xcu @@ -0,0 +1,26 @@ + + + + + + + + vnd.sun.star.job:alias=UpdateCheck + + + + + + Check for ~Updates... + + + _self + + + + + + + + + diff --git a/extensions/source/update/check/org/openoffice/Office/Jobs.xcu b/extensions/source/update/check/org/openoffice/Office/Jobs.xcu new file mode 100644 index 000000000000..840d630698cb --- /dev/null +++ b/extensions/source/update/check/org/openoffice/Office/Jobs.xcu @@ -0,0 +1,42 @@ + + + + + + + com.sun.star.setup.UpdateCheck + + + + true + + + 0 + + + 604800 + + + + + + false + + + true + + + false + + + + + + + + + + + + + diff --git a/extensions/source/update/feed/makefile.mk b/extensions/source/update/feed/makefile.mk deleted file mode 100644 index 6361f20bdd73..000000000000 --- a/extensions/source/update/feed/makefile.mk +++ /dev/null @@ -1,72 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/..$/.. - -PRJNAME=extensions -TARGET=updatefeed - -LIBTARGET=NO -ENABLE_EXCEPTIONS=TRUE - -# --- Settings --- - -.INCLUDE : settings.mk - -# no "lib" prefix -DLLPRE = - -# --- Files --- - -SLOFILES=\ - $(SLO)$/updatefeed.obj \ - -SHL1NOCHECK=TRUE -SHL1TARGET=$(TARGET).uno -SHL1OBJS=$(SLOFILES) - -SHL1IMPLIB=i$(SHL1TARGET) -SHL1STDLIBS= \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(SALLIB) - -SHL1VERSIONMAP=$(SOLARENV)/src/component.map -SHL1DEF=$(MISC)$/$(SHL1TARGET).def -DEF1NAME=$(SHL1TARGET) - -# --- Targets --- - -.INCLUDE : target.mk - - -ALLTAR : $(MISC)/updatefeed.component - -$(MISC)/updatefeed.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - updatefeed.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt updatefeed.component diff --git a/extensions/source/update/ui/makefile.mk b/extensions/source/update/ui/makefile.mk deleted file mode 100644 index 5ea6994d3d22..000000000000 --- a/extensions/source/update/ui/makefile.mk +++ /dev/null @@ -1,82 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/..$/.. - -PRJNAME=extensions -TARGET=updchkui - -LIBTARGET=NO -ENABLE_EXCEPTIONS=TRUE - -# --- Settings --- - -.INCLUDE : settings.mk - -# --- Files --- - -SLOFILES=\ - $(SLO)$/updatecheckui.obj - -SRS1NAME=$(TARGET) -SRC1FILES=\ - updatecheckui.src - -RESLIB1NAME=updchk -RESLIB1IMAGES=$(PRJ)$/source$/update$/ui -RESLIB1SRSFILES= $(SRS)$/updchkui.srs -RESLIB1DEPN= updatecheckui.src updatecheckui.hrc - -SHL1NOCHECK=TRUE -SHL1TARGET=updchk$(DLLPOSTFIX) -SHL1OBJS=$(SLOFILES) -SHL1DEF=$(MISC)$/$(SHL1TARGET).def - -SHL1IMPLIB=i$(SHL1TARGET) -SHL1STDLIBS= \ - $(COMPHELPERLIB) \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(SALLIB) \ - $(VCLLIB) \ - $(TOOLSLIB) - -SHL1VERSIONMAP=$(SOLARENV)/src/component.map -SHL1DEF=$(MISC)$/$(SHL1TARGET).def -DEF1NAME=$(SHL1TARGET) - -# --- Targets --- - -.INCLUDE : target.mk - - -ALLTAR : $(MISC)/updchk.component - -$(MISC)/updchk.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - updchk.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt updchk.component diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index fe829fa4799f..74dbb16f9d39 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -173,6 +173,9 @@ my_components += \ component/desktop/source/migration/services/migrationoo3 \ component/desktop/source/offacc/offacc \ component/desktop/source/splash/spl \ + component/extensions/source/update/check/updchk.uno \ + component/extensions/source/update/feed/updatefeed \ + component/extensions/source/update/ui/updchk \ dbp \ fpicker \ fps_office \ @@ -183,9 +186,6 @@ my_components += \ syssh \ tvhlp1 \ ucpchelp1 \ - updatefeed \ - updchk \ - updchk.uno \ xmx .ENDIF diff --git a/postprocess/packregistry/makefile.mk b/postprocess/packregistry/makefile.mk index 84cbfa114f59..2041bbda8ee6 100644 --- a/postprocess/packregistry/makefile.mk +++ b/postprocess/packregistry/makefile.mk @@ -356,8 +356,8 @@ MY_FILES_math = \ .IF "$(BUILD_TYPE)" != "$(BUILD_TYPE:s/DESKTOP//)" MY_DEPS_onlineupdate = main MY_FILES_onlineupdate = \ - $(MY_MOD)/org/openoffice/Office/Addons/Addons-onlineupdate.xcu \ - $(MY_MOD)/org/openoffice/Office/Jobs/Jobs-onlineupdate.xcu + $(MY_MOD)/org/openoffice/Office/Addons-onlineupdate.xcu \ + $(MY_MOD)/org/openoffice/Office/Jobs-onlineupdate.xcu .ENDIF MY_DEPS_palm = main diff --git a/scp2/source/ooo/file_library_ooo.scp b/scp2/source/ooo/file_library_ooo.scp index 7b20c242bd32..cf94b1892f2f 100644 --- a/scp2/source/ooo/file_library_ooo.scp +++ b/scp2/source/ooo/file_library_ooo.scp @@ -1475,7 +1475,7 @@ End STD_LIB_FILE( gid_File_Lib_Guesslang, guesslang ) -STD_LIB_FILE( gid_File_Lib_Updchkui , updchk ) +STD_LIB_FILE( gid_File_Lib_Updchkui , updatecheckui ) SPECIAL_COMPONENT_LIB_FILE( gid_File_Lib_Updatefeed , updatefeed.uno ) diff --git a/solenv/gbuild/Configuration.mk b/solenv/gbuild/Configuration.mk index b0134c02e910..0674837c1311 100644 --- a/solenv/gbuild/Configuration.mk +++ b/solenv/gbuild/Configuration.mk @@ -309,6 +309,11 @@ $(call gb_Configuration_get_target,%) : $(call gb_Helper_abbreviate_dirs,\ mkdir -p $(dir $@) && touch $@) +# TODO: ? +define gb_Configuration_Configuration_nozip +$$(eval $$(call gb_Module_register_target,$(call gb_Configuration_get_target,$(1)),$(call gb_Configuration_get_clean_target,$(1)))) +endef + # $(call gb_Configuration_Configuration,zipfile,repo,nodeliver) # cannot use target local variable for REPO because it's needed in prereq # last parameter may be used to turn off delivering of files -- cgit From ec0240cffc35ca74fa874f7b57b4eee787a66f4e Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 14 Dec 2011 20:10:08 +0100 Subject: extensions: convert ole automation bridge to gbuild Of course not tested at all (WNT only) --- Repository.mk | 7 ++ extensions/Library_oleautobridge.mk | 67 ++++++++++++++ extensions/Library_oleautobridge2.mk | 70 +++++++++++++++ extensions/Module_extensions.mk | 9 ++ extensions/prj/build.lst | 1 - extensions/source/ole/makefile.mk | 132 ---------------------------- extensions/source/ole/oleautobridge.uno.dxp | 2 - extensions/source/ole/servreg.cxx | 3 +- postprocess/packcomponents/makefile.mk | 2 +- solenv/gbuild/platform/WNT_INTEL_MSC.mk | 1 + 10 files changed, 157 insertions(+), 137 deletions(-) create mode 100644 extensions/Library_oleautobridge.mk create mode 100644 extensions/Library_oleautobridge2.mk delete mode 100644 extensions/source/ole/makefile.mk delete mode 100644 extensions/source/ole/oleautobridge.uno.dxp diff --git a/Repository.mk b/Repository.mk index 815ab70349e2..49117f8983f3 100644 --- a/Repository.mk +++ b/Repository.mk @@ -362,6 +362,13 @@ $(eval $(call gb_Helper_register_libraries,UNOLIBS_OOO, \ writerfilter_debug \ )) +ifeq ($(OS),WNT) +$(eval $(call gb_Helper_register_libraries,UNOLIBS_OOO, \ + oleautobridge \ + oleautobridge2 \ +)) +endif + $(eval $(call gb_Helper_register_libraries,UNOLIBS_URE, \ binaryurp \ )) diff --git a/extensions/Library_oleautobridge.mk b/extensions/Library_oleautobridge.mk new file mode 100644 index 000000000000..0fda05a62854 --- /dev/null +++ b/extensions/Library_oleautobridge.mk @@ -0,0 +1,67 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,oleautobridge)) + +$(eval $(call gb_Library_set_componentfile,oleautobridge,extensions/source/ole/oleautobridge)) + +$(eval $(call gb_Library_add_api,oleautobridge,\ + udkapi \ + offapi \ +)) + +$(eval $(call gb_Library_set_include,oleautobridge,\ + $(foreach inc,$(ATL_INCLUDE),-I$(inc)) \ + $$(INCLUDE) \ +)) + +$(eval $(call gb_Library_add_linked_libs,oleautobridge,\ + cppuhelper \ + cppu \ + sal \ + advapi32 \ + $(if $(USE_DEBUG_RUNTIME),atlsd,atls) + ole32 \ + oleaut32 \ + uuid \ +)) + +$(eval $(call gb_Library_add_exception_objects,oleautobridge,\ + extensions/source/ole/jscriptclasses \ + extensions/source/ole/ole2uno \ + extensions/source/ole/oledll \ + extensions/source/ole/oleobjw \ + extensions/source/ole/olethread \ + extensions/source/ole/servprov \ + extensions/source/ole/servreg \ + extensions/source/ole/unoobjw \ + extensions/source/ole/unotypewrapper \ + extensions/source/ole/windata \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_oleautobridge2.mk b/extensions/Library_oleautobridge2.mk new file mode 100644 index 000000000000..7cb94c7a50c5 --- /dev/null +++ b/extensions/Library_oleautobridge2.mk @@ -0,0 +1,70 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +# TODO: do we really need 2 of these? +$(eval $(call gb_Library_Library,oleautobridge2)) + +$(eval $(call gb_Library_add_defs,oleautobridge2,\ + -DOWNGUID \ +)) + +$(eval $(call gb_Library_add_api,oleautobridge2,\ + udkapi \ + offapi \ +)) + +$(eval $(call gb_Library_set_include,oleautobridge2,\ + $(foreach inc,$(ATL_INCLUDE),-I$(inc)) \ + $$(INCLUDE) \ +)) + +$(eval $(call gb_Library_add_linked_libs,oleautobridge2,\ + cppuhelper \ + cppu \ + sal \ + advapi32 \ + $(if $(USE_DEBUG_RUNTIME),atlsd,atls) + ole32 \ + oleaut32 \ + uuid \ +)) + +$(eval $(call gb_Library_add_exception_objects,oleautobridge2,\ + extensions/source/ole/jscriptclasses \ + extensions/source/ole/ole2uno \ + extensions/source/ole/oledll \ + extensions/source/ole/oleobjw \ + extensions/source/ole/olethread \ + extensions/source/ole/servprov \ + extensions/source/ole/servreg \ + extensions/source/ole/unoobjw \ + extensions/source/ole/unotypewrapper \ + extensions/source/ole/windata \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index 179170a6a9a6..21a30ab6d044 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -35,6 +35,15 @@ $(eval $(call gb_Module_add_targets,extensions,\ Library_updchk \ )) +ifeq ($(OS),WNT) +ifeq ($(DISABLE_ATL),) +$(eval $(call gb_Module_add_targets,extensions,\ + Library_oleautobridge \ + Library_oleautobridge2 \ +)) +endif +endif + $(eval $(call gb_Module_add_check_targets,extensions,\ CppunitTest_extensions_test_update \ )) diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index cc629f4f4ef8..44f22e90beb5 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -8,7 +8,6 @@ ex extensions\source\plugin\inc\plugin\win get - all ex_piwi ex_inc N ex extensions\source\plugin\inc\plugin\unx get - all ex_piux ex_inc NULL ex extensions\source\activex\msidl nmake - w ex_axmsidl ex_inc NULL ex extensions\source\activex\main nmake - w ex_axmain ex_axmsidl.w ex_inc NULL -ex extensions\source\ole nmake - w ex_ole ex_xmlextr ex_inc NULL ex extensions\source\resource nmake - all ex_resrc ex_inc NULL ex extensions\source\plugin\aqua nmake - u ex_plaqua ex_plbase NULL ex extensions\source\plugin\base nmake - all ex_plbase ex_inc NULL diff --git a/extensions/source/ole/makefile.mk b/extensions/source/ole/makefile.mk deleted file mode 100644 index a9ff68118c58..000000000000 --- a/extensions/source/ole/makefile.mk +++ /dev/null @@ -1,132 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/.. - -# ----------------------------------------------------------------- - -PRJNAME=extensions -TARGET=oleautobridge.uno -TARGET2=oleautobridge2.uno - -ENABLE_EXCEPTIONS=TRUE - -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -LIBTARGET=NO -USE_DEFFILE=YES - -USE_DEFFILE=TRUE - -INCPRE+= $(foreach,i,$(ATL_INCLUDE) -I$(i)) - -# --- Settings ----------------------------------------------------- - -.IF "$(GUI)" == "WNT" && "$(DISABLE_ATL)"=="" - -.IF "$(USE_DEBUG_RUNTIME)"!="" -CDEFS+=-D_DEBUG -.ENDIF # "$(USE_DEBUG_RUNTIME)"!="" - -SLOFILES= \ - $(SLO)$/servreg.obj \ - $(SLO)$/servprov.obj \ - $(SLO)$/unoobjw.obj \ - $(SLO)$/oleobjw.obj \ - $(SLO)$/olethread.obj \ - $(SLO)$/oledll.obj \ - $(SLO)$/jscriptclasses.obj \ - $(SLO)$/ole2uno.obj \ - $(SLO)$/windata.obj \ - $(SLO)$/unotypewrapper.obj - -SECOND_BUILD=OWNGUID -OWNGUID_SLOFILES=$(SLOFILES) -OWNGUIDCDEFS+= -DOWNGUID - -# the original library -SHL1TARGET=$(TARGET) -SHL1STDLIBS=\ - $(SALLIB) \ - $(CPPULIB) \ - $(CPPUHELPERLIB) \ - $(OLE32LIB) \ - $(UUIDLIB) \ - $(ADVAPI32LIB) \ - $(OLEAUT32LIB) - -.IF "$(COM)"=="MSC" -.IF "$(USE_DEBUG_RUNTIME)" != "" - SHL1STDLIBS+= $(ATL_LIB)$/atlsd.lib -.ELSE - SHL1STDLIBS+= $(ATL_LIB)$/atls.lib -.ENDIF -.ENDIF # "$(COM)"=="MSC" - -SHL1LIBS= -SHL1OBJS=$(SLOFILES) - -DEF1NAME=$(SHL1TARGET) -DEF1EXPORTFILE=$(SHL1TARGET).dxp - -# the second library -SHL2TARGET=$(TARGET2) -SHL2STDLIBS=\ - $(SALLIB) \ - $(CPPULIB) \ - $(CPPUHELPERLIB) \ - $(OLE32LIB) \ - $(UUIDLIB) \ - $(ADVAPI32LIB) \ - $(OLEAUT32LIB) - -.IF "$(COM)"=="MSC" -.IF "$(USE_DEBUG_RUNTIME)" != "" - SHL2STDLIBS+= $(ATL_LIB)$/atlsd.lib -.ELSE - SHL2STDLIBS+= $(ATL_LIB)$/atls.lib -.ENDIF -.ENDIF # "$(COM)"=="MSC" - -SHL2LIBS= -SHL2OBJS=$(REAL_OWNGUID_SLOFILES) - -DEF2NAME=$(SHL2TARGET) -DEF2EXPORTFILE=$(TARGET).dxp - -.ENDIF # "$(GUI)" == "WNT" && "$(DISABLE_ATL)"=="" - -#---------------------------------------------------------------- - -.INCLUDE : target.mk - -ALLTAR : $(MISC)/oleautobridge.component - -$(MISC)/oleautobridge.component .ERRREMOVE : \ - $(SOLARENV)/bin/createcomponent.xslt oleautobridge.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt oleautobridge.component diff --git a/extensions/source/ole/oleautobridge.uno.dxp b/extensions/source/ole/oleautobridge.uno.dxp deleted file mode 100644 index 843ff2fc389f..000000000000 --- a/extensions/source/ole/oleautobridge.uno.dxp +++ /dev/null @@ -1,2 +0,0 @@ -component_getFactory @101 -component_canUnload @103 diff --git a/extensions/source/ole/servreg.cxx b/extensions/source/ole/servreg.cxx index 528a66e29337..1b9c02c1bd9f 100644 --- a/extensions/source/ole/servreg.cxx +++ b/extensions/source/ole/servreg.cxx @@ -118,7 +118,8 @@ extern "C" SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory( return pRet; } -extern "C" sal_Bool component_canUnload( TimeValue* libUnused) +extern "C" sal_Bool SAL_DLLPUBLIC_EXPORT +component_canUnload( TimeValue* libUnused) { return globalModuleCount.canUnload( &globalModuleCount, libUnused); } diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index 74dbb16f9d39..9850d3f1647a 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -321,7 +321,7 @@ my_components += \ .IF "$(OS)" == "WNT" && "$(DISABLE_ATL)" == "" my_components += \ emser \ - oleautobridge + component/extensions/source/ole/oleautobridge .END .IF "$(OS)" == "WNT" && "$(ENABLE_DIRECTX)" != "" diff --git a/solenv/gbuild/platform/WNT_INTEL_MSC.mk b/solenv/gbuild/platform/WNT_INTEL_MSC.mk index 45c960905f58..b578e0b313bb 100644 --- a/solenv/gbuild/platform/WNT_INTEL_MSC.mk +++ b/solenv/gbuild/platform/WNT_INTEL_MSC.mk @@ -398,6 +398,7 @@ gb_Library_win32_OLDNAMES := oldnames gb_Library_PLAINLIBS_NONE += \ advapi32 \ + $(if $(USE_DEBUG_RUNTIME),atlsd,atls) \ comdlg32 \ crypt32 \ d3d9 \ -- cgit From aaa2f8f7e1ad4d85e901912d6bbc2ed99ae37a7b Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 14 Dec 2011 20:52:33 +0100 Subject: extensions: convert scanner to gbuild --- Repository.mk | 1 + extensions/AllLangResTarget_san.mk | 44 ++++++++++++++ extensions/Library_scn.mk | 74 +++++++++++++++++++++++ extensions/Module_extensions.mk | 2 + extensions/prj/build.lst | 1 - extensions/source/scanner/exports.dxp | 1 - extensions/source/scanner/makefile.mk | 104 --------------------------------- postprocess/packcomponents/makefile.mk | 2 +- 8 files changed, 122 insertions(+), 107 deletions(-) create mode 100644 extensions/AllLangResTarget_san.mk create mode 100644 extensions/Library_scn.mk delete mode 100644 extensions/source/scanner/exports.dxp delete mode 100644 extensions/source/scanner/makefile.mk diff --git a/Repository.mk b/Repository.mk index 49117f8983f3..65cb29fcbf55 100644 --- a/Repository.mk +++ b/Repository.mk @@ -194,6 +194,7 @@ $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ sc \ scd \ scfilt \ + scn \ scui \ sd \ sdbt \ diff --git a/extensions/AllLangResTarget_san.mk b/extensions/AllLangResTarget_san.mk new file mode 100644 index 000000000000..a866cc9020d3 --- /dev/null +++ b/extensions/AllLangResTarget_san.mk @@ -0,0 +1,44 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_AllLangResTarget_AllLangResTarget,san)) + +$(eval $(call gb_AllLangResTarget_set_reslocation,san,extensions/source/scanner)) + +$(eval $(call gb_AllLangResTarget_add_srs,san,\ + scn/res \ +)) + +$(eval $(call gb_SrsTarget_SrsTarget,scn/res)) + +$(eval $(call gb_SrsTarget_add_files,scn/res,\ + extensions/source/scanner/grid.src \ + extensions/source/scanner/sanedlg.src \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_scn.mk b/extensions/Library_scn.mk new file mode 100644 index 000000000000..6a165d553100 --- /dev/null +++ b/extensions/Library_scn.mk @@ -0,0 +1,74 @@ + +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,scn)) + +$(eval $(call gb_Library_set_componentfile,scn,extensions/source/scanner/scn)) + +$(eval $(call gb_Library_add_api,scn,\ + udkapi \ + offapi \ +)) + +$(eval $(call gb_Library_add_linked_libs,scn,\ + svt \ + vcl \ + tl \ + comphelper \ + cppuhelper \ + cppu \ + sal \ +)) + +$(eval $(call gb_Library_add_exception_objects,scn,\ + extensions/source/scanner/scnserv \ + extensions/source/scanner/scanner \ +)) + +ifeq ($(GUI),WNT) +$(eval $(call gb_Library_add_exception_objects,scn,\ + extensions/source/scanner/scanwin \ +)) +else +ifeq ($(GUI),UNX) +$(eval $(call gb_Library_add_exception_objects,scn,\ + extensions/source/scanner/grid \ + extensions/source/scanner/sane \ + extensions/source/scanner/sanedlg \ + extensions/source/scanner/scanunx \ +)) +ifeq ($(OS),LINUX) +$(eval $(call gb_Library_add_linked_libs,scn,\ + dl \ +)) +endif +endif +endif + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index 21a30ab6d044..fbbb8cc4d1cd 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -27,9 +27,11 @@ $(eval $(call gb_Module_Module,extensions)) $(eval $(call gb_Module_add_targets,extensions,\ + AllLangResTarget_san \ AllLangResTarget_upd \ AllLangResTarget_updchk \ Configuration_updchk \ + Library_scn \ Library_updatecheckui \ Library_updatefeed \ Library_updchk \ diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index 44f22e90beb5..2a9f47c4fca5 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -15,7 +15,6 @@ ex extensions\source\plugin\win nmake - w ex_plwin ex_plba ex extensions\source\plugin\unx nmake - u ex_plunx ex_inc NULL ex extensions\source\plugin\util nmake - all ex_plutil ex_plbase ex_plunx.u ex_plwin.w ex_plaqua.u ex_inc NULL ex extensions\source\macosx\spotlight nmake - u ex_mxspotlight NULL -ex extensions\source\scanner nmake - all ex_scan ex_resrc ex_inc NULL ex extensions\source\bibliography nmake - all ex_bib ex_inc NULL ex extensions\source\xmlextract nmake - all ex_xmlextr ex_inc NULL ex extensions\source\propctrlr nmake - all ex_propctrlr ex_bib ex_inc NULL diff --git a/extensions/source/scanner/exports.dxp b/extensions/source/scanner/exports.dxp deleted file mode 100644 index 70033078921a..000000000000 --- a/extensions/source/scanner/exports.dxp +++ /dev/null @@ -1 +0,0 @@ -component_getFactory diff --git a/extensions/source/scanner/makefile.mk b/extensions/source/scanner/makefile.mk deleted file mode 100644 index 60d1900f0b6b..000000000000 --- a/extensions/source/scanner/makefile.mk +++ /dev/null @@ -1,104 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/.. -PRJNAME=extensions -TARGET=scn -ENABLE_EXCEPTIONS=TRUE -PACKAGE=com$/sun$/star$/scanner -USE_DEFFILE=TRUE - -# --- Settings ----------------------------------------------------- - -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -# --- Files -------------------------------------------------------- - -SLOFILES=\ - $(SLO)$/scnserv.obj \ - $(SLO)$/scanner.obj - -.IF "$(GUI)"=="WNT" -SLOFILES+=\ - $(SLO)$/scanwin.obj -.ENDIF - -.IF "$(GUI)"=="UNX" -SLOFILES+=\ - $(SLO)$/sane.obj \ - $(SLO)$/sanedlg.obj \ - $(SLO)$/scanunx.obj \ - $(SLO)$/grid.obj - -.ENDIF - -SRS1NAME=$(TARGET) -SRC1FILES=\ - sanedlg.src \ - grid.src - -RESLIB1NAME=san -RESLIB1IMAGES=$(PRJ)$/source$/scanner -RESLIB1SRSFILES= $(SRS)$/scn.srs -RESLIB1DEPN= sanedlg.src sanedlg.hrc grid.src grid.hrc - -SHL1TARGET= $(TARGET)$(DLLPOSTFIX) -SHL1STDLIBS=\ - $(CPPULIB) \ - $(CPPUHELPERLIB) \ - $(COMPHELPERLIB) \ - $(SALLIB) \ - $(ONELIB) \ - $(TOOLSLIB) \ - $(VCLLIB) \ - $(SVTOOLLIB) - -.IF "$(GUI)"=="UNX" && "$(OS)"!="FREEBSD" && \ - "$(OS)"!="NETBSD" && "$(OS)"!="OPENBSD" && "$(OS)"!="DRAGONFLY" -SHL1STDLIBS+=$(SVTOOLLIB) -ldl -.ENDIF - -SHL1DEF=$(MISC)$/$(SHL1TARGET).def -SHL1IMPLIB=i$(TARGET) -SHL1LIBS=$(SLB)$/$(TARGET).lib -SHL1VERSIONMAP=$(SOLARENV)/src/component.map - -DEF1NAME=$(SHL1TARGET) -DEF1EXPORTFILE=exports.dxp - - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk - - -ALLTAR : $(MISC)/scn.component - -$(MISC)/scn.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - scn.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt scn.component diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index 9850d3f1647a..d2496ea342dc 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -173,6 +173,7 @@ my_components += \ component/desktop/source/migration/services/migrationoo3 \ component/desktop/source/offacc/offacc \ component/desktop/source/splash/spl \ + component/extensions/source/scanner/scn \ component/extensions/source/update/check/updchk.uno \ component/extensions/source/update/feed/updatefeed \ component/extensions/source/update/ui/updchk \ @@ -182,7 +183,6 @@ my_components += \ log \ pcr \ res \ - scn \ syssh \ tvhlp1 \ ucpchelp1 \ -- cgit From 4b4c583b90d61865de30de1a88074f600654b627 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 14 Dec 2011 20:54:38 +0100 Subject: extensions: convert pcr to gbuild --- Repository.mk | 1 + extensions/AllLangResTarget_pcr.mk | 56 ++++++++++++ extensions/Library_pcr.mk | 121 +++++++++++++++++++++++++ extensions/Module_extensions.mk | 2 + extensions/prj/build.lst | 3 +- extensions/source/propctrlr/makefile.mk | 154 -------------------------------- postprocess/packcomponents/makefile.mk | 2 +- 7 files changed, 182 insertions(+), 157 deletions(-) create mode 100644 extensions/AllLangResTarget_pcr.mk create mode 100644 extensions/Library_pcr.mk delete mode 100644 extensions/source/propctrlr/makefile.mk diff --git a/Repository.mk b/Repository.mk index 65cb29fcbf55..79aea6c12c24 100644 --- a/Repository.mk +++ b/Repository.mk @@ -180,6 +180,7 @@ $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ msworks \ odfflatxml \ offacc \ + pcr \ pdffilter \ placeware \ protocolhandler \ diff --git a/extensions/AllLangResTarget_pcr.mk b/extensions/AllLangResTarget_pcr.mk new file mode 100644 index 000000000000..d091af1a7ecc --- /dev/null +++ b/extensions/AllLangResTarget_pcr.mk @@ -0,0 +1,56 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_AllLangResTarget_AllLangResTarget,pcr)) + +$(eval $(call gb_AllLangResTarget_set_reslocation,pcr,extensions)) + +$(eval $(call gb_AllLangResTarget_add_srs,pcr,\ + pcr/res \ +)) + +$(eval $(call gb_SrsTarget_SrsTarget,pcr/res)) + +$(eval $(call gb_SrsTarget_set_include,pcr/res,\ + -I$(SRCDIR)/extensions/inc \ + $$(INCLUDE) \ +)) + +$(eval $(call gb_SrsTarget_add_files,pcr/res,\ + extensions/source/propctrlr/propres.src \ + extensions/source/propctrlr/formres.src \ + extensions/source/propctrlr/pcrmiscres.src \ + extensions/source/propctrlr/taborder.src \ + extensions/source/propctrlr/fontdialog.src \ + extensions/source/propctrlr/selectlabeldialog.src \ + extensions/source/propctrlr/formlinkdialog.src \ + extensions/source/propctrlr/listselectiondlg.src \ + extensions/source/propctrlr/newdatatype.src \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_pcr.mk b/extensions/Library_pcr.mk new file mode 100644 index 000000000000..5d7d5604fbae --- /dev/null +++ b/extensions/Library_pcr.mk @@ -0,0 +1,121 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,pcr)) + +$(eval $(call gb_Library_set_componentfile,pcr,extensions/source/propctrlr/pcr)) + +$(eval $(call gb_Library_add_api,pcr,\ + udkapi \ + offapi \ +)) + +$(eval $(call gb_Library_set_include,pcr,\ + -I$(SRCDIR)/extensions/inc \ + $$(INCLUDE) \ +)) + +$(eval $(call gb_Library_add_linked_libs,pcr,\ + svx \ + svxcore \ + editeng \ + sfx \ + svt \ + tk \ + vcl \ + svl \ + utl \ + tl \ + dbtools \ + i18nisolang1 \ + comphelper \ + cppuhelper \ + cppu \ + sal \ +)) + +$(eval $(call gb_Library_add_exception_objects,pcr,\ + extensions/source/propctrlr/controlfontdialog \ + extensions/source/propctrlr/fontdialog \ + extensions/source/propctrlr/pcrservices \ + extensions/source/propctrlr/selectlabeldialog \ + extensions/source/propctrlr/propcontroller \ + extensions/source/propctrlr/formcontroller \ + extensions/source/propctrlr/modulepcr \ + extensions/source/propctrlr/cellbindinghelper \ + extensions/source/propctrlr/taborder \ + extensions/source/propctrlr/pcrunodialogs \ + extensions/source/propctrlr/unourl \ + extensions/source/propctrlr/formlinkdialog \ + extensions/source/propctrlr/listselectiondlg \ + extensions/source/propctrlr/browserlistbox \ + extensions/source/propctrlr/stringrepresentation \ + extensions/source/propctrlr/eformshelper \ + extensions/source/propctrlr/xsddatatypes \ + extensions/source/propctrlr/xsdvalidationhelper \ + extensions/source/propctrlr/pushbuttonnavigation \ + extensions/source/propctrlr/sqlcommanddesign \ + extensions/source/propctrlr/composeduiupdate \ + extensions/source/propctrlr/propertycomposer \ + extensions/source/propctrlr/pcrcomponentcontext \ + extensions/source/propctrlr/commoncontrol \ + extensions/source/propctrlr/standardcontrol \ + extensions/source/propctrlr/usercontrol \ + extensions/source/propctrlr/browserline \ + extensions/source/propctrlr/genericpropertyhandler \ + extensions/source/propctrlr/buttonnavigationhandler \ + extensions/source/propctrlr/handlerhelper \ + extensions/source/propctrlr/propertyhandler \ + extensions/source/propctrlr/eventhandler \ + extensions/source/propctrlr/editpropertyhandler \ + extensions/source/propctrlr/eformspropertyhandler \ + extensions/source/propctrlr/cellbindinghandler \ + extensions/source/propctrlr/submissionhandler \ + extensions/source/propctrlr/xsdvalidationpropertyhandler \ + extensions/source/propctrlr/formcomponenthandler \ + extensions/source/propctrlr/formmetadata \ + extensions/source/propctrlr/defaultforminspection \ + extensions/source/propctrlr/formbrowsertools \ + extensions/source/propctrlr/browserpage \ + extensions/source/propctrlr/propertyeditor \ + extensions/source/propctrlr/formstrings \ + extensions/source/propctrlr/pcrstrings \ + extensions/source/propctrlr/browserview \ + extensions/source/propctrlr/pcrcommon \ + extensions/source/propctrlr/newdatatype \ + extensions/source/propctrlr/propeventtranslation \ + extensions/source/propctrlr/objectinspectormodel \ + extensions/source/propctrlr/inspectorhelpwindow \ + extensions/source/propctrlr/defaulthelpprovider \ + extensions/source/propctrlr/MasterDetailLinkDialog \ + extensions/source/propctrlr/inspectormodelbase \ + extensions/source/propctrlr/propertycontrolextender \ + extensions/source/propctrlr/formgeometryhandler \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index fbbb8cc4d1cd..a5505791b0bf 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -27,10 +27,12 @@ $(eval $(call gb_Module_Module,extensions)) $(eval $(call gb_Module_add_targets,extensions,\ + AllLangResTarget_pcr \ AllLangResTarget_san \ AllLangResTarget_upd \ AllLangResTarget_updchk \ Configuration_updchk \ + Library_pcr \ Library_scn \ Library_updatecheckui \ Library_updatefeed \ diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index 2a9f47c4fca5..c0cd9aad2870 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -17,14 +17,13 @@ ex extensions\source\plugin\util nmake - all ex_plutil ex_plb ex extensions\source\macosx\spotlight nmake - u ex_mxspotlight NULL ex extensions\source\bibliography nmake - all ex_bib ex_inc NULL ex extensions\source\xmlextract nmake - all ex_xmlextr ex_inc NULL -ex extensions\source\propctrlr nmake - all ex_propctrlr ex_bib ex_inc NULL ex extensions\source\dbpilots nmake - all ex_dbpilots ex_inc NULL ex extensions\source\abpilot nmake - all ex_abpilot ex_inc NULL ex extensions\source\logging nmake - all ex_logging ex_inc NULL ex extensions\source\config\ldap nmake - all ex_ldap ex_inc NULL ex extensions\source\nsplugin\source nmake - u ex_nsplugin ex_inc NULL ex extensions\source\nsplugin\source nmake - w ex_nsplugin ex_inc NULL -ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging ex_ldap ex_propctrlr ex_bib ex_plutil NULL +ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging ex_ldap ex_bib ex_plutil NULL ex extensions\prj nmake - all ex_prj NULL # Fails at the moment diff --git a/extensions/source/propctrlr/makefile.mk b/extensions/source/propctrlr/makefile.mk deleted file mode 100644 index ebb629ae39c9..000000000000 --- a/extensions/source/propctrlr/makefile.mk +++ /dev/null @@ -1,154 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/.. -PRJINC=..$/inc - -PRJNAME=extensions -TARGET=pcr -USE_DEFFILE=TRUE - -ENABLE_EXCEPTIONS=TRUE -VISIBILITY_HIDDEN=TRUE - -# --- Settings ----------------------------------------------------- - -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -# --- Files -------------------------------------------------------- - -SLOFILES= $(SLO)$/controlfontdialog.obj \ - $(SLO)$/fontdialog.obj \ - $(SLO)$/pcrservices.obj \ - $(SLO)$/selectlabeldialog.obj \ - $(SLO)$/propcontroller.obj \ - $(SLO)$/formcontroller.obj \ - $(SLO)$/modulepcr.obj \ - $(SLO)$/cellbindinghelper.obj \ - $(SLO)$/taborder.obj \ - $(SLO)$/pcrunodialogs.obj \ - $(SLO)$/unourl.obj \ - $(SLO)$/formlinkdialog.obj \ - $(SLO)$/listselectiondlg.obj \ - $(SLO)$/browserlistbox.obj \ - $(SLO)$/stringrepresentation.obj \ - $(SLO)$/eformshelper.obj \ - $(SLO)$/xsddatatypes.obj \ - $(SLO)$/xsdvalidationhelper.obj \ - $(SLO)$/pushbuttonnavigation.obj \ - $(SLO)$/sqlcommanddesign.obj \ - $(SLO)$/composeduiupdate.obj \ - $(SLO)$/propertycomposer.obj \ - $(SLO)$/pcrcomponentcontext.obj \ - $(SLO)$/commoncontrol.obj \ - $(SLO)$/standardcontrol.obj \ - $(SLO)$/usercontrol.obj \ - $(SLO)$/browserline.obj \ - $(SLO)$/genericpropertyhandler.obj \ - $(SLO)$/buttonnavigationhandler.obj \ - $(SLO)$/handlerhelper.obj \ - $(SLO)$/propertyhandler.obj \ - $(SLO)$/eventhandler.obj \ - $(SLO)$/editpropertyhandler.obj \ - $(SLO)$/eformspropertyhandler.obj \ - $(SLO)$/cellbindinghandler.obj \ - $(SLO)$/submissionhandler.obj \ - $(SLO)$/xsdvalidationpropertyhandler.obj \ - $(SLO)$/formcomponenthandler.obj \ - $(SLO)$/formmetadata.obj \ - $(SLO)$/defaultforminspection.obj \ - $(SLO)$/formbrowsertools.obj \ - $(SLO)$/browserpage.obj \ - $(SLO)$/propertyeditor.obj \ - $(SLO)$/formstrings.obj \ - $(SLO)$/pcrstrings.obj \ - $(SLO)$/browserview.obj \ - $(SLO)$/pcrcommon.obj \ - $(SLO)$/newdatatype.obj \ - $(SLO)$/propeventtranslation.obj \ - $(SLO)$/objectinspectormodel.obj \ - $(SLO)$/inspectorhelpwindow.obj \ - $(SLO)$/defaulthelpprovider.obj \ - $(SLO)$/MasterDetailLinkDialog.obj \ - $(SLO)$/inspectormodelbase.obj \ - $(SLO)$/propertycontrolextender.obj \ - $(SLO)$/formgeometryhandler.obj - -SRS1NAME=$(TARGET) -SRC1FILES= propres.src \ - formres.src \ - pcrmiscres.src \ - taborder.src \ - fontdialog.src \ - selectlabeldialog.src \ - formlinkdialog.src \ - listselectiondlg.src \ - newdatatype.src - -RESLIB1NAME=$(TARGET) -RESLIB1IMAGES=$(PRJ)$/res -RESLIB1SRSFILES= $(SRS)$/$(TARGET).srs - -SHL1TARGET= $(TARGET)$(DLLPOSTFIX) -SHL1VERSIONMAP=$(SOLARENV)/src/component.map - -SHL1STDLIBS= \ - $(EDITENGLIB) \ - $(SVXCORELIB) \ - $(SVXLIB) \ - $(SFXLIB) \ - $(SVTOOLLIB)\ - $(TKLIB) \ - $(VCLLIB) \ - $(SVLLIB) \ - $(TOOLSLIB) \ - $(I18NISOLANGLIB) \ - $(DBTOOLSLIB) \ - $(COMPHELPERLIB) \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(UNOTOOLSLIB) \ - $(SALLIB) - -SHL1LIBS= $(SLB)$/$(TARGET).lib -SHL1IMPLIB= i$(TARGET) -SHL1DEPN= $(SHL1LIBS) -SHL1DEF= $(MISC)$/$(SHL1TARGET).def - -DEF1NAME= $(SHL1TARGET) - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk - - -ALLTAR : $(MISC)/pcr.component - -$(MISC)/pcr.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - pcr.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt pcr.component diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index d2496ea342dc..2ffa9775cc87 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -173,6 +173,7 @@ my_components += \ component/desktop/source/migration/services/migrationoo3 \ component/desktop/source/offacc/offacc \ component/desktop/source/splash/spl \ + component/extensions/source/propctrlr/pcr \ component/extensions/source/scanner/scn \ component/extensions/source/update/check/updchk.uno \ component/extensions/source/update/feed/updatefeed \ @@ -181,7 +182,6 @@ my_components += \ fpicker \ fps_office \ log \ - pcr \ res \ syssh \ tvhlp1 \ -- cgit From 9d79b12871522cb9daebf4f6c850e07edcdce08a Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:12:13 +0100 Subject: extensions: merge in Peter Foley's work in update Main improvement is that the unit test is now linked against updchk library. --- Repository.mk | 2 +- extensions/Configuration_updchk.mk | 9 +++- extensions/CppunitTest_extensions_test_update.mk | 16 +++--- extensions/Library_updchk.mk | 7 ++- extensions/source/update/check/transform.pl | 61 ----------------------- extensions/source/update/check/updatecheck.hxx | 36 ++++++------- extensions/source/update/check/updateprotocol.hxx | 2 +- scp2/source/onlineupdate/file_onlineupdate.scp | 2 +- 8 files changed, 43 insertions(+), 92 deletions(-) delete mode 100644 extensions/source/update/check/transform.pl diff --git a/Repository.mk b/Repository.mk index 79aea6c12c24..ff8dccd62bfb 100644 --- a/Repository.mk +++ b/Repository.mk @@ -290,6 +290,7 @@ $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ ucb \ ucpfile \ unopkgapp \ + updchk \ xmlsecurity \ xsec_fw \ xsec_xmlsec \ @@ -355,7 +356,6 @@ $(eval $(call gb_Helper_register_libraries,UNOLIBS_OOO, \ stocservices \ stringresource \ updatefeed \ - updchk \ vbaevents \ vbaobj \ vbaswobj \ diff --git a/extensions/Configuration_updchk.mk b/extensions/Configuration_updchk.mk index 2f392228fedf..d6bcc07f3202 100644 --- a/extensions/Configuration_updchk.mk +++ b/extensions/Configuration_updchk.mk @@ -13,7 +13,7 @@ # License. # # Major Contributor(s): -# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# [ Copyright (C) 2011 Peter Foley (initial developer) ] # # All Rights Reserved. # @@ -27,11 +27,16 @@ # # TODO is this really supposed to be delivered to the officecfg registry? -$(eval $(call gb_Configuration_Configuration_nozip,updchk)) +$(eval $(call gb_Configuration_Configuration,updchk)) $(eval $(call gb_Configuration_add_spool_modules,updchk,extensions/source/update/check,\ org/openoffice/Office/Jobs-onlineupdate.xcu \ org/openoffice/Office/Addons-onlineupdate.xcu \ )) +$(eval $(call gb_Configuration_add_localized_datas,updchk,extensions/source/update/check,\ + org/openoffice/Office/Jobs.xcu \ + org/openoffice/Office/Addons.xcu \ +)) + # vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/CppunitTest_extensions_test_update.mk b/extensions/CppunitTest_extensions_test_update.mk index 36721e720fc1..f0b9a0567bc0 100644 --- a/extensions/CppunitTest_extensions_test_update.mk +++ b/extensions/CppunitTest_extensions_test_update.mk @@ -28,16 +28,11 @@ $(eval $(call gb_CppunitTest_CppunitTest,extensions_test_update)) $(eval $(call gb_CppunitTest_add_exception_objects,extensions_test_update, \ - extensions/source/update/check/download \ - extensions/source/update/check/updatecheck \ - extensions/source/update/check/updatecheckconfig \ - extensions/source/update/check/updatehdl \ - extensions/source/update/check/updateprotocol \ - \ extensions/qa/update/test_update \ )) $(eval $(call gb_CppunitTest_add_linked_libs,extensions_test_update, \ + updchk \ cppu \ cppuhelper \ sal \ @@ -46,6 +41,13 @@ $(eval $(call gb_CppunitTest_add_linked_libs,extensions_test_update, \ $(gb_STDLIBS) \ )) +ifeq ($(OS),WNT) +$(eval $(call gb_CppunitTest_add_linked_libs,extensions_test_update,\ + shell32 \ + ole32 \ +)) +endif + $(eval $(call gb_CppunitTest_use_external,extensions_test_update,curl)) $(eval $(call gb_CppunitTest_set_include,extensions_test_update,\ @@ -67,13 +69,13 @@ $(eval $(call gb_CppunitTest_add_type_rdbs,extensions_test_update,\ $(eval $(call gb_CppunitTest_add_components,extensions_test_update,\ configmgr/source/configmgr \ + extensions/source/update/feed/updatefeed \ unoxml/source/service/unoxml \ )) $(eval $(call gb_CppunitTest_add_old_components,extensions_test_update,\ ucb1 \ ucpfile1 \ - component/extensions/source/update/feed/updatefeed \ )) $(eval $(call gb_CppunitTest_set_args,extensions_test_update,\ diff --git a/extensions/Library_updchk.mk b/extensions/Library_updchk.mk index ba6d7364e7b0..e78f1d0b26f6 100644 --- a/extensions/Library_updchk.mk +++ b/extensions/Library_updchk.mk @@ -14,6 +14,7 @@ # # Major Contributor(s): # [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# [ Copyright (C) 2011 Peter Foley ] # # All Rights Reserved. # @@ -30,13 +31,17 @@ $(eval $(call gb_Library_Library,updchk)) $(eval $(call gb_Library_set_componentfile,updchk,extensions/source/update/check/updchk.uno)) +$(eval $(call gb_Library_set_include,updchk,\ + $$(INCLUDE) \ + -I$(SRCDIR)/extensions/inc \ +)) + $(eval $(call gb_Library_add_api,updchk,\ udkapi \ offapi \ )) $(eval $(call gb_Library_add_linked_libs,updchk,\ - comphelper \ cppuhelper \ cppu \ sal \ diff --git a/extensions/source/update/check/transform.pl b/extensions/source/update/check/transform.pl deleted file mode 100644 index fb452ae0482c..000000000000 --- a/extensions/source/update/check/transform.pl +++ /dev/null @@ -1,61 +0,0 @@ -: -eval 'exec perl -wS $0 ${1+"$@"}' - if 0; - -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -while (<>) { - - if( // ) { - next if( $prop =~ /Text/ || $prop =~ /Bubble/ ); - } - - if( /xml:lang/ ) { - $lang = $_; - $lang =~ s/.*xml:lang=\"//; - $lang =~ s/\".*//; - chomp $lang; - $line = $prop; - $line =~ s/\" oor:type/_$lang\" oor:type/; - print $line; - $line = $_; - $line =~ s/ xml:lang=\".*\"//; - print $line; - $line = $prop; - $line =~ s//; - print $line; - next; - } - - print; -} \ No newline at end of file diff --git a/extensions/source/update/check/updatecheck.hxx b/extensions/source/update/check/updatecheck.hxx index 0f0768919877..d6db5e8e8978 100644 --- a/extensions/source/update/check/updatecheck.hxx +++ b/extensions/source/update/check/updatecheck.hxx @@ -58,7 +58,7 @@ public: virtual void SAL_CALL cancel() = 0; }; -class UpdateCheck : +class SAL_DLLPUBLIC_EXPORT UpdateCheck : public UpdateCheckConfigListener, public IActionListener, public DownloadInteractionHandler, @@ -107,35 +107,35 @@ public: bool hasOfficeUpdate() const { return (m_aUpdateInfo.BuildId.getLength() > 0); } // DownloadInteractionHandler - virtual bool downloadTargetExists(const rtl::OUString& rFileName); - virtual void downloadStalled(const rtl::OUString& rErrorMessage); - virtual void downloadProgressAt(sal_Int8 nProcent); - virtual void downloadStarted(const rtl::OUString& rLocalFileName, sal_Int64 nFileSize); - virtual void downloadFinished(const rtl::OUString& rLocalFileName); + SAL_DLLPUBLIC_EXPORT virtual bool downloadTargetExists(const rtl::OUString& rFileName); + SAL_DLLPUBLIC_EXPORT virtual void downloadStalled(const rtl::OUString& rErrorMessage); + SAL_DLLPUBLIC_EXPORT virtual void downloadProgressAt(sal_Int8 nProcent); + SAL_DLLPUBLIC_EXPORT virtual void downloadStarted(const rtl::OUString& rLocalFileName, sal_Int64 nFileSize); + SAL_DLLPUBLIC_EXPORT virtual void downloadFinished(const rtl::OUString& rLocalFileName); // checks if the download target already exists and asks user what to do next - virtual bool checkDownloadDestination( const rtl::OUString& rFile ); + SAL_DLLPUBLIC_EXPORT virtual bool checkDownloadDestination( const rtl::OUString& rFile ); // Cancels the download action (and resumes checking if enabled) void cancelDownload(); // Returns the XInteractionHandler of the UpdateHandler instance if present (and visible) - com::sun::star::uno::Reference< com::sun::star::task::XInteractionHandler > getInteractionHandler() const; + SAL_DLLPUBLIC_EXPORT com::sun::star::uno::Reference< com::sun::star::task::XInteractionHandler > getInteractionHandler() const; // UpdateCheckConfigListener - virtual void autoCheckStatusChanged(bool enabled); - virtual void autoCheckIntervalChanged(); + SAL_DLLPUBLIC_EXPORT virtual void autoCheckStatusChanged(bool enabled); + SAL_DLLPUBLIC_EXPORT virtual void autoCheckIntervalChanged(); // IActionListener - void cancel(); - void download(); - void install(); - void pause(); - void resume(); - void closeAfterFailure(); + SAL_DLLPUBLIC_EXPORT void cancel(); + SAL_DLLPUBLIC_EXPORT void download(); + SAL_DLLPUBLIC_EXPORT void install(); + SAL_DLLPUBLIC_EXPORT void pause(); + SAL_DLLPUBLIC_EXPORT void resume(); + SAL_DLLPUBLIC_EXPORT void closeAfterFailure(); // rtl::IReference - virtual oslInterlockedCount SAL_CALL acquire() SAL_THROW(()); - virtual oslInterlockedCount SAL_CALL release() SAL_THROW(()); + SAL_DLLPUBLIC_EXPORT virtual oslInterlockedCount SAL_CALL acquire() SAL_THROW(()); + SAL_DLLPUBLIC_EXPORT virtual oslInterlockedCount SAL_CALL release() SAL_THROW(()); private: diff --git a/extensions/source/update/check/updateprotocol.hxx b/extensions/source/update/check/updateprotocol.hxx index 9488373a303e..aae612415a29 100644 --- a/extensions/source/update/check/updateprotocol.hxx +++ b/extensions/source/update/check/updateprotocol.hxx @@ -42,7 +42,7 @@ bool checkForUpdates( ); // The same as above, that does not read the info from bootstrap -bool +SAL_DLLPUBLIC_EXPORT bool checkForUpdates( UpdateInfo& o_rUpdateInfo, const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > & rxContext, diff --git a/scp2/source/onlineupdate/file_onlineupdate.scp b/scp2/source/onlineupdate/file_onlineupdate.scp index 07ab650acc2b..526e6eb8c539 100644 --- a/scp2/source/onlineupdate/file_onlineupdate.scp +++ b/scp2/source/onlineupdate/file_onlineupdate.scp @@ -27,7 +27,7 @@ #include "macros.inc" -SPECIAL_COMPONENT_LIB_FILE( gid_File_Lib_Updchk , updchk.uno ) +SPECIAL_LIB_FILE( gid_File_Lib_Updchk , updchk ) File gid_File_Share_Registry_Onlineupdate_Xcd TXT_FILE_BODY; -- cgit From 48bd7b190ea20b1c718f6c950f21ba3301157d28 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:25:11 +0100 Subject: extensions: merge Peter Foley's work in olebridge --- extensions/Library_oleautobridge.mk | 14 ++++++++++- extensions/Library_oleautobridge2.mk | 41 +++++++++++++++++++++++---------- solenv/gbuild/platform/WNT_INTEL_MSC.mk | 1 - 3 files changed, 42 insertions(+), 14 deletions(-) diff --git a/extensions/Library_oleautobridge.mk b/extensions/Library_oleautobridge.mk index 0fda05a62854..807c9e67480f 100644 --- a/extensions/Library_oleautobridge.mk +++ b/extensions/Library_oleautobridge.mk @@ -14,6 +14,7 @@ # # Major Contributor(s): # [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# [ Copyright (C) 2011 Peter Foley ] # # All Rights Reserved. # @@ -45,12 +46,23 @@ $(eval $(call gb_Library_add_linked_libs,oleautobridge,\ cppu \ sal \ advapi32 \ - $(if $(USE_DEBUG_RUNTIME),atlsd,atls) ole32 \ oleaut32 \ uuid \ )) +ifeq ($(COM),MSC) +ifneq ($(USE_DEBUG_RUNTIME),) +$(eval $(call gb_Library_add_libs,oleautobridge,\ + $(ATL_LIB)/atlsd.lib \ +)) +else +$(eval $(call gb_Library_add_libs,oleautobridge,\ + $(ATL_LIB)/atls.lib \ +)) +endif +endif + $(eval $(call gb_Library_add_exception_objects,oleautobridge,\ extensions/source/ole/jscriptclasses \ extensions/source/ole/ole2uno \ diff --git a/extensions/Library_oleautobridge2.mk b/extensions/Library_oleautobridge2.mk index 7cb94c7a50c5..35db333b28c7 100644 --- a/extensions/Library_oleautobridge2.mk +++ b/extensions/Library_oleautobridge2.mk @@ -14,6 +14,7 @@ # # Major Contributor(s): # [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# [ Copyright (C) 2011 Peter Foley ] # # All Rights Reserved. # @@ -39,6 +40,7 @@ $(eval $(call gb_Library_add_api,oleautobridge2,\ )) $(eval $(call gb_Library_set_include,oleautobridge2,\ + -I$(SRCDIR)/extensions/source/ole \ $(foreach inc,$(ATL_INCLUDE),-I$(inc)) \ $$(INCLUDE) \ )) @@ -48,23 +50,38 @@ $(eval $(call gb_Library_add_linked_libs,oleautobridge2,\ cppu \ sal \ advapi32 \ - $(if $(USE_DEBUG_RUNTIME),atlsd,atls) ole32 \ oleaut32 \ uuid \ )) -$(eval $(call gb_Library_add_exception_objects,oleautobridge2,\ - extensions/source/ole/jscriptclasses \ - extensions/source/ole/ole2uno \ - extensions/source/ole/oledll \ - extensions/source/ole/oleobjw \ - extensions/source/ole/olethread \ - extensions/source/ole/servprov \ - extensions/source/ole/servreg \ - extensions/source/ole/unoobjw \ - extensions/source/ole/unotypewrapper \ - extensions/source/ole/windata \ +ifeq ($(COM),MSC) +ifneq ($(USE_DEBUG_RUNTIME),) +$(eval $(call gb_Library_add_libs,oleautobridge2,\ + $(ATL_LIB)/atlsd.lib \ +)) +else +$(eval $(call gb_Library_add_libs,oleautobridge2,\ + $(ATL_LIB)/atls.lib \ +)) +endif +endif + +$(WORKDIR)/CustomTarget/extensions/source/ole/%.cxx: $(SRCDIR)/extensions/source/ole/%.cxx + mkdir -p $(dir $@) + cp $< $@ + +$(eval $(call gb_Library_add_generated_exception_objects,oleautobridge2,\ + CustomTarget/extensions/source/ole/jscriptclasses \ + CustomTarget/extensions/source/ole/ole2uno \ + CustomTarget/extensions/source/ole/oledll \ + CustomTarget/extensions/source/ole/oleobjw \ + CustomTarget/extensions/source/ole/olethread \ + CustomTarget/extensions/source/ole/servprov \ + CustomTarget/extensions/source/ole/servreg \ + CustomTarget/extensions/source/ole/unoobjw \ + CustomTarget/extensions/source/ole/unotypewrapper \ + CustomTarget/extensions/source/ole/windata \ )) # vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/solenv/gbuild/platform/WNT_INTEL_MSC.mk b/solenv/gbuild/platform/WNT_INTEL_MSC.mk index b578e0b313bb..45c960905f58 100644 --- a/solenv/gbuild/platform/WNT_INTEL_MSC.mk +++ b/solenv/gbuild/platform/WNT_INTEL_MSC.mk @@ -398,7 +398,6 @@ gb_Library_win32_OLDNAMES := oldnames gb_Library_PLAINLIBS_NONE += \ advapi32 \ - $(if $(USE_DEBUG_RUNTIME),atlsd,atls) \ comdlg32 \ crypt32 \ d3d9 \ -- cgit From 21411e321ee8e430a81ec83297a88c3010f5ce8d Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:31:17 +0100 Subject: extensions: merge Peter Foley's work in pcr --- extensions/Library_pcr.mk | 92 ++++++++++++++++++++--------------------- extensions/Module_extensions.mk | 1 + extensions/Package_pcr.mk | 35 ++++++++++++++++ 3 files changed, 82 insertions(+), 46 deletions(-) create mode 100644 extensions/Package_pcr.mk diff --git a/extensions/Library_pcr.mk b/extensions/Library_pcr.mk index 5d7d5604fbae..500d2560f8d5 100644 --- a/extensions/Library_pcr.mk +++ b/extensions/Library_pcr.mk @@ -60,62 +60,62 @@ $(eval $(call gb_Library_add_linked_libs,pcr,\ )) $(eval $(call gb_Library_add_exception_objects,pcr,\ - extensions/source/propctrlr/controlfontdialog \ - extensions/source/propctrlr/fontdialog \ - extensions/source/propctrlr/pcrservices \ - extensions/source/propctrlr/selectlabeldialog \ - extensions/source/propctrlr/propcontroller \ - extensions/source/propctrlr/formcontroller \ - extensions/source/propctrlr/modulepcr \ - extensions/source/propctrlr/cellbindinghelper \ - extensions/source/propctrlr/taborder \ - extensions/source/propctrlr/pcrunodialogs \ - extensions/source/propctrlr/unourl \ - extensions/source/propctrlr/formlinkdialog \ - extensions/source/propctrlr/listselectiondlg \ - extensions/source/propctrlr/browserlistbox \ - extensions/source/propctrlr/stringrepresentation \ - extensions/source/propctrlr/eformshelper \ - extensions/source/propctrlr/xsddatatypes \ - extensions/source/propctrlr/xsdvalidationhelper \ - extensions/source/propctrlr/pushbuttonnavigation \ - extensions/source/propctrlr/sqlcommanddesign \ - extensions/source/propctrlr/composeduiupdate \ - extensions/source/propctrlr/propertycomposer \ - extensions/source/propctrlr/pcrcomponentcontext \ - extensions/source/propctrlr/commoncontrol \ - extensions/source/propctrlr/standardcontrol \ - extensions/source/propctrlr/usercontrol \ + extensions/source/propctrlr/MasterDetailLinkDialog \ extensions/source/propctrlr/browserline \ - extensions/source/propctrlr/genericpropertyhandler \ + extensions/source/propctrlr/browserlistbox \ + extensions/source/propctrlr/browserpage \ + extensions/source/propctrlr/browserview \ extensions/source/propctrlr/buttonnavigationhandler \ - extensions/source/propctrlr/handlerhelper \ - extensions/source/propctrlr/propertyhandler \ - extensions/source/propctrlr/eventhandler \ + extensions/source/propctrlr/cellbindinghandler \ + extensions/source/propctrlr/cellbindinghelper \ + extensions/source/propctrlr/commoncontrol \ + extensions/source/propctrlr/composeduiupdate \ + extensions/source/propctrlr/controlfontdialog \ + extensions/source/propctrlr/defaultforminspection \ + extensions/source/propctrlr/defaulthelpprovider \ extensions/source/propctrlr/editpropertyhandler \ + extensions/source/propctrlr/eformshelper \ extensions/source/propctrlr/eformspropertyhandler \ - extensions/source/propctrlr/cellbindinghandler \ - extensions/source/propctrlr/submissionhandler \ - extensions/source/propctrlr/xsdvalidationpropertyhandler \ + extensions/source/propctrlr/eventhandler \ + extensions/source/propctrlr/fontdialog \ + extensions/source/propctrlr/formbrowsertools \ extensions/source/propctrlr/formcomponenthandler \ + extensions/source/propctrlr/formcontroller \ + extensions/source/propctrlr/formgeometryhandler \ + extensions/source/propctrlr/formlinkdialog \ extensions/source/propctrlr/formmetadata \ - extensions/source/propctrlr/defaultforminspection \ - extensions/source/propctrlr/formbrowsertools \ - extensions/source/propctrlr/browserpage \ - extensions/source/propctrlr/propertyeditor \ extensions/source/propctrlr/formstrings \ - extensions/source/propctrlr/pcrstrings \ - extensions/source/propctrlr/browserview \ - extensions/source/propctrlr/pcrcommon \ - extensions/source/propctrlr/newdatatype \ - extensions/source/propctrlr/propeventtranslation \ - extensions/source/propctrlr/objectinspectormodel \ + extensions/source/propctrlr/genericpropertyhandler \ + extensions/source/propctrlr/handlerhelper \ extensions/source/propctrlr/inspectorhelpwindow \ - extensions/source/propctrlr/defaulthelpprovider \ - extensions/source/propctrlr/MasterDetailLinkDialog \ extensions/source/propctrlr/inspectormodelbase \ + extensions/source/propctrlr/listselectiondlg \ + extensions/source/propctrlr/modulepcr \ + extensions/source/propctrlr/newdatatype \ + extensions/source/propctrlr/objectinspectormodel \ + extensions/source/propctrlr/pcrcommon \ + extensions/source/propctrlr/pcrcomponentcontext \ + extensions/source/propctrlr/pcrservices \ + extensions/source/propctrlr/pcrstrings \ + extensions/source/propctrlr/pcrunodialogs \ + extensions/source/propctrlr/propcontroller \ + extensions/source/propctrlr/propertycomposer \ extensions/source/propctrlr/propertycontrolextender \ - extensions/source/propctrlr/formgeometryhandler \ + extensions/source/propctrlr/propertyeditor \ + extensions/source/propctrlr/propertyhandler \ + extensions/source/propctrlr/propeventtranslation \ + extensions/source/propctrlr/pushbuttonnavigation \ + extensions/source/propctrlr/selectlabeldialog \ + extensions/source/propctrlr/sqlcommanddesign \ + extensions/source/propctrlr/standardcontrol \ + extensions/source/propctrlr/stringrepresentation \ + extensions/source/propctrlr/submissionhandler \ + extensions/source/propctrlr/taborder \ + extensions/source/propctrlr/unourl \ + extensions/source/propctrlr/usercontrol \ + extensions/source/propctrlr/xsddatatypes \ + extensions/source/propctrlr/xsdvalidationhelper \ + extensions/source/propctrlr/xsdvalidationpropertyhandler \ )) # vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index a5505791b0bf..d471c76fe663 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -37,6 +37,7 @@ $(eval $(call gb_Module_add_targets,extensions,\ Library_updatecheckui \ Library_updatefeed \ Library_updchk \ + Package_pcr \ )) ifeq ($(OS),WNT) diff --git a/extensions/Package_pcr.mk b/extensions/Package_pcr.mk new file mode 100644 index 000000000000..db0d91e549d4 --- /dev/null +++ b/extensions/Package_pcr.mk @@ -0,0 +1,35 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Package_Package,pcr,$(SRCDIR)/extensions/source/propctrlr)) + +$(eval $(call gb_Package_add_file,pcr,xml/pcr.xml,pcr.xml)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: -- cgit From 2548d634c762ccc5eeda7f075ffa6ed3408474d2 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 19:46:38 +0100 Subject: extensions: convert nsplugin to gbuild --- Repository.mk | 1 + RepositoryFixes.mk | 2 + extensions/Executable_nsplugin.mk | 82 +++++++++++ extensions/Library_npsoplugin.mk | 104 ++++++++++++++ extensions/Module_extensions.mk | 26 ++++ extensions/WinResTarget_npsoplugin.mk | 35 +++++ extensions/prj/build.lst | 2 - extensions/source/nsplugin/source/exports.dxp | 16 --- extensions/source/nsplugin/source/exports_wnt.dxp | 18 --- extensions/source/nsplugin/source/makefile.mk | 164 ---------------------- extensions/source/nsplugin/source/npsoplugin.def | 21 +++ solenv/gbuild/platform/WNT_INTEL_GCC.mk | 2 + 12 files changed, 273 insertions(+), 200 deletions(-) create mode 100644 extensions/Executable_nsplugin.mk create mode 100644 extensions/Library_npsoplugin.mk create mode 100755 extensions/WinResTarget_npsoplugin.mk delete mode 100644 extensions/source/nsplugin/source/exports.dxp delete mode 100644 extensions/source/nsplugin/source/exports_wnt.dxp delete mode 100644 extensions/source/nsplugin/source/makefile.mk create mode 100755 extensions/source/nsplugin/source/npsoplugin.def diff --git a/Repository.mk b/Repository.mk index ff8dccd62bfb..b897665f060a 100644 --- a/Repository.mk +++ b/Repository.mk @@ -279,6 +279,7 @@ $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ localedata_others \ mcnttype \ neon \ + npsoplugin \ package2 \ reg \ scriptframe \ diff --git a/RepositoryFixes.mk b/RepositoryFixes.mk index 59dd09db0b0b..3267e4c7e3e6 100644 --- a/RepositoryFixes.mk +++ b/RepositoryFixes.mk @@ -55,6 +55,8 @@ gb_Library_FILENAMES := $(patsubst sfx:isfx%,sfx:sfx%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst svt:isvt%,svt:svtool%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst tl:itl%,tl:itools%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst vbahelper:ivbahelper%,vbahelper:vbahelper%,$(gb_Library_FILENAMES)) +gb_Library_FILENAMES := $(patsubst curl:icurl%,curl:libcurl%,$(gb_Library_FILENAMES)) +gb_Library_FILENAMES := $(patsubst npsoplugin:inpsoplugin%,npsoplugin:npsoplugin%,$(gb_Library_FILENAMES)) gb_StaticLibrary_FILENAMES := $(patsubst graphite:graphite%,graphite:graphite_dll%,$(gb_StaticLibrary_FILENAMES)) diff --git a/extensions/Executable_nsplugin.mk b/extensions/Executable_nsplugin.mk new file mode 100644 index 000000000000..439424f2f1d3 --- /dev/null +++ b/extensions/Executable_nsplugin.mk @@ -0,0 +1,82 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Executable_Executable,nsplugin)) + +$(eval $(call gb_Executable_add_api,nsplugin,\ + offapi \ + udkapi \ +)) + +$(eval $(call gb_Executable_add_exception_objects,nsplugin,\ + extensions/source/nsplugin/source/so_closelistener \ + extensions/source/nsplugin/source/so_instance \ + extensions/source/nsplugin/source/so_env \ + extensions/source/nsplugin/source/so_main \ +)) + +$(eval $(call gb_Executable_add_linked_libs,nsplugin,\ + cppu \ + cppuhelper \ + sal \ +)) + +ifeq ($(OS),SOLARIS) +$(eval $(call gb_Executable_add_libs,nsplugin,\ + -lsocket \ + -lnsl \ +)) +endif + +ifeq ($(GUI),WNT) +$(eval $(call gb_Executable_add_ldflags,nsplugin,\ + $(OUTDIR)/lib/pathutils-obj.obj \ +)) + +$(eval $(call gb_Executable_add_exception_objects,nsplugin,\ + extensions/source/nsplugin/source/nsp_windows \ +)) + +$(eval $(call gb_Executable_add_linked_libs,nsplugin,\ + ws2_32 \ + shell32 \ + ole32 \ + kernel32 \ + user32 \ + gdi32 \ + winspool \ + comdlg32 \ + advapi32 \ + oleaut32 \ + uuid \ +)) +endif # WNT + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_npsoplugin.mk b/extensions/Library_npsoplugin.mk new file mode 100644 index 000000000000..e5710fed4fa8 --- /dev/null +++ b/extensions/Library_npsoplugin.mk @@ -0,0 +1,104 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,npsoplugin)) + +ifeq ($(SYSTEM_MOZILLA_HEADERS),YES) +$(eval $(call gb_Library_set_include,npsoplugin,\ + $$(INCLUDE) \ + $(MOZILLA_HEADERS_CFLAGS) +)) +else +$(eval $(call gb_Library_set_include,npsoplugin,\ + -I$(OUTDIR)/inc/npsdk \ + $$(INCLUDE) \ +)) +endif + +ifeq ($(GUI),UNX) + +$(eval $(call gb_Library_add_ldflags,npsoplugin,\ + $(OUTDIR)/lib/npunix.o \ +)) + +$(eval $(call gb_Library_add_libs,npsoplugin,\ + -ldl \ +)) + +$(eval $(call gb_Library_use_external,npsoplugin,gtk)) + +$(eval $(call gb_Library_add_defs,npsoplugin,\ + -DMOZ_X11 \ +)) + +ifeq ($(filter-out LINUX FREEBSD NETBSD OPENBSD DRAGONFLY,$(OS)),) +$(eval $(call gb_Library_add_defs,npsoplugin,\ + -DNP_LINUX \ +)) +endif + +endif # GUI=UNX + +ifeq ($(GUI),WNT) + +$(eval $(call gb_Library_add_ldflags,npsoplugin,\ + $(OUTDIR)/lib/pathutils-obj.obj \ + $(OUTDIR)/lib/npwin.obj \ + /DEF:$(call gb_Helper_convert_native,$(SRCDIR)/extensions/source/nsplugin/source/npsoplugin.def) \ +)) + +$(eval $(call gb_Library_add_linked_libs,npsoplugin,\ + ws2_32 \ + shell32 \ + ole32 \ + kernel32 \ + user32 \ + gdi32 \ + winspool \ + comdlg32 \ + advapi32 \ + oleaut32 \ + uuid \ +)) + +$(eval $(call gb_Library_add_defs,npsoplugin,\ + -DENGLISH \ +)) + +$(eval $(call gb_Library_add_nativeres,npsoplugin,npsoplugin_res)) + +endif # GUI=WNT + +$(eval $(call gb_Library_add_exception_objects,npsoplugin,\ + extensions/source/nsplugin/source/so_env \ + extensions/source/nsplugin/source/npshell \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index d471c76fe663..78830783761b 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -49,6 +49,32 @@ $(eval $(call gb_Module_add_targets,extensions,\ endif endif +ifneq ($(WITH_MOZILLA),NO) + +$(eval $(call gb_Module_add_targets,extensions,\ + Executable_nsplugin \ +)) + +ifeq ($(GUI),WNT) +$(eval $(call gb_Module_add_targets,extensions,\ + Library_npsoplugin \ + WinResTarget_npsoplugin \ +)) +endif # GUI=WNT + +ifeq ($(GUI),UNX) + +ifneq ($(ENABLE_GTK),) +$(eval $(call gb_Module_add_targets,extensions,\ + Library_npsoplugin \ +)) +endif # ENABLE_GTK + +endif # GUI=UNX + +endif # WITH_MOZILLA=YES + + $(eval $(call gb_Module_add_check_targets,extensions,\ CppunitTest_extensions_test_update \ )) diff --git a/extensions/WinResTarget_npsoplugin.mk b/extensions/WinResTarget_npsoplugin.mk new file mode 100755 index 000000000000..bba691713970 --- /dev/null +++ b/extensions/WinResTarget_npsoplugin.mk @@ -0,0 +1,35 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_WinResTarget_WinResTarget,npsoplugin_res)) + +$(eval $(call gb_WinResTarget_add_file,npsoplugin_res,extensions/source/nsplugin/source/nsplugin_oo)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index c0cd9aad2870..e6144e5d14ed 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -21,8 +21,6 @@ ex extensions\source\dbpilots nmake - all ex_dbpilots ex_i ex extensions\source\abpilot nmake - all ex_abpilot ex_inc NULL ex extensions\source\logging nmake - all ex_logging ex_inc NULL ex extensions\source\config\ldap nmake - all ex_ldap ex_inc NULL -ex extensions\source\nsplugin\source nmake - u ex_nsplugin ex_inc NULL -ex extensions\source\nsplugin\source nmake - w ex_nsplugin ex_inc NULL ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging ex_ldap ex_bib ex_plutil NULL ex extensions\prj nmake - all ex_prj NULL diff --git a/extensions/source/nsplugin/source/exports.dxp b/extensions/source/nsplugin/source/exports.dxp deleted file mode 100644 index e8b697289c20..000000000000 --- a/extensions/source/nsplugin/source/exports.dxp +++ /dev/null @@ -1,16 +0,0 @@ -NPP_GetMIMEDescription -NPP_GetValue -NPP_Initialize -NPP_GetJavaClass -NPP_Shutdown -NPP_New -NPP_Destroy -NPP_SetWindow -NPP_NewStream -NPP_WriteReady -NPP_Write -NPP_DestroyStream -NPP_StreamAsFile -NPP_URLNotify -NPP_Print -NPP_Shutdown diff --git a/extensions/source/nsplugin/source/exports_wnt.dxp b/extensions/source/nsplugin/source/exports_wnt.dxp deleted file mode 100644 index a27be8c38300..000000000000 --- a/extensions/source/nsplugin/source/exports_wnt.dxp +++ /dev/null @@ -1,18 +0,0 @@ -NPP_GetMIMEDescription -NPP_Initialize -NPP_Shutdown -NPP_New -NPP_Destroy -NPP_SetWindow -NPP_NewStream -NPP_WriteReady -NPP_Write -NPP_DestroyStream -NPP_StreamAsFile -NPP_URLNotify -NPP_Print -NPP_Shutdown -NP_GetEntryPoints -NP_Initialize -NP_Shutdown -NP_GetMIMEDescription diff --git a/extensions/source/nsplugin/source/makefile.mk b/extensions/source/nsplugin/source/makefile.mk deleted file mode 100644 index 5b7476408a31..000000000000 --- a/extensions/source/nsplugin/source/makefile.mk +++ /dev/null @@ -1,164 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=..$/..$/.. -PRJNAME=extensions -TARGET=npsoplugin - -ENABLE_EXCEPTIONS=TRUE -USE_DEFFILE=TRUE - -# --- Settings ---------------------------------- - -.INCLUDE : settings.mk - -.IF "$(SYSTEM_MOZILLA_HEADERS)" == "YES" -INCPRE+=$(MOZILLA_HEADERS_CFLAGS) -.ELSE -INCPRE=$(SOLARINCDIR)$/npsdk -.ENDIF - -.IF "$(GUI)"=="UNX" - -# not sure about -DMOZ_X11 but otheriwse some struct member don't exist... -CFLAGS+=-DMOZ_X11 - -.IF "$(ENABLE_NSPLUGIN)"=="NO" - -dummy: - @echo Nsplugin disabled, nothing to build - -.ELSE # ENABLE_NSPLUGIN -.IF "$(OS)"=="LINUX" || "$(OS)"=="FREEBSD" || "$(OS)"=="NETBSD" || \ - "$(OS)"=="OPENBSD" || "$(OS)"=="DRAGONFLY" -INC+= -DNP_LINUX -.ENDIF -PKGCONFIG_MODULES=gtk+-2.0 -.INCLUDE: pkg_config.mk -.ENDIF # ENABLE_NSPLUGIN -.ENDIF # "$(GUI)"=="UNX" -.IF "$(GUI)"=="WNT" -INC+= -DENGLISH -.ENDIF - - -# --- Files ------------------------------------- - -SLOFILES= $(SLO)$/npshell.obj \ - $(SLO)$/so_env.obj - -SHL1OBJS= $(SLO)$/npshell.obj \ - $(SLO)$/so_env.obj - -.IF "$(GUI)"=="UNX" -STDLIBS+=$(SOLARLIBDIR)$/npunix.o -SHL1STDLIBS+=$(SOLARLIBDIR)$/npunix.o -.ENDIF #UNX -.IF "$(GUI)"=="WNT" -SHL1OBJS+=$(SOLARLIBDIR)$/pathutils-obj.obj -STDLIBS+=$(SOLARLIBDIR)$/npwin.obj -SHL1STDLIBS+= $(SHELL32LIB) $(SOLARLIBDIR)$/npwin.obj - -.ENDIF - -OBJFILES=\ - $(OBJ)$/so_closelistener.obj\ - $(OBJ)$/so_instance.obj\ - $(OBJ)$/so_env.obj\ - $(OBJ)$/so_main.obj - -# --- Plugin executable ------------------------- -APP1TARGET=nsplugin$(EXEPOSTFIX) -APP1OBJS=$(OBJFILES) - -APP1STDLIBS=\ - $(CPPULIB) \ - $(CPPUHELPERLIB) \ - $(SALLIB) - -.IF "$(OS)"=="SOLARIS" -APP1STDLIBS+= -lsocket -lnsl -.ENDIF - -.IF "$(GUI)"=="WNT" -DEPOBJFILES=$(OBJ)$/nsp_windows.obj -APP1OBJS+=$(OBJ)$/nsp_windows.obj $(SOLARLIBDIR)$/pathutils-obj.obj -APP1STDLIBS+= $(WS2_32LIB) $(SHELL32LIB) $(OLE32LIB) $(KERNEL32LIB) $(USER32LIB) $(GDI32LIB) $(WINSPOOLLIB) $(COMDLG32LIB) $(ADVAPI32LIB) $(OLEAAUT32LIB) $(UUIDLIB) -.ENDIF - -# --- Library ----------------------------------- - -SHL1TARGET=$(TARGET)_so -.IF "$(GUI)"=="WNT" -SHL1STDLIBS+= $(WS2_32LIB) $(SHELL32LIB) $(OLE32LIB) $(KERNEL32LIB) $(USER32LIB) $(GDI32LIB) $(WINSPOOLLIB) $(COMDLG32LIB) $(ADVAPI32LIB) $(OLE32LIB) $(OLEAAUT32LIB) $(UUIDLIB) $(KERNEL32LIB) $(USER32LIB) $(GDI32LIB) $(WINSPOOLLIB) $(COMDLG32LIB) $(ADVAPI32LIB) -.ENDIF - -SHL1DEPN= -SHL1IMPLIB= i$(SHL1TARGET) -SHL1DEF= $(MISC)$/$(SHL1TARGET).def -SHL1RPATH=OOO - -# ----- get some additional keys in versioninfo ------------ -SHL1ADD_VERINFO=nsplugin.rc -SHL1DEPN+=$(SHL1ADD_VERINFO) - -DEF1NAME=$(SHL1TARGET) -.IF "$(GUI)"=="UNX" -DEF1EXPORTFILE=exports.dxp -.ENDIF -.IF "$(GUI)"=="WNT" -DEF1EXPORTFILE=exports_wnt.dxp -.ENDIF - -SHL2OBJS=$(SHL1OBJS) -SHL2STDLIBS=$(SHL1STDLIBS) -SHL2TARGET=$(TARGET) -.IF "$(GUI)"=="WNT" -SHL2STDLIBS+= $(WS2_32LIB) $(SHELL32LIB) $(OLE32LIB) $(KERNEL32LIB) $(USER32LIB) $(GDI32LIB) $(WINSPOOLLIB) $(COMDLG32LIB) $(ADVAPI32LIB) $(OLE32LIB) $(OLEAAUT32LIB) $(UUIDLIB) $(KERNEL32LIB) $(USER32LIB) $(GDI32LIB) $(WINSPOOLLIB) $(COMDLG32LIB) $(ADVAPI32LIB) -.ENDIF - -SHL2DEPN= -SHL2IMPLIB= i$(SHL2TARGET) -SHL2DEF= $(MISC)$/$(SHL2TARGET).def -SHL2RPATH=OOO - -# ----- get some additional keys in versioninfo ------------ -SHL2ADD_VERINFO=nsplugin_oo.rc -SHL2DEPN+=$(SHL2ADD_VERINFO) - -DEF2NAME=$(SHL2TARGET) -.IF "$(GUI)"=="UNX" -DEF2EXPORTFILE=exports.dxp -.ENDIF -.IF "$(GUI)"=="WNT" -DEF2EXPORTFILE=exports_wnt.dxp -.ENDIF - -# --- Targets ---------------------------------- - -.INCLUDE : target.mk - diff --git a/extensions/source/nsplugin/source/npsoplugin.def b/extensions/source/nsplugin/source/npsoplugin.def new file mode 100755 index 000000000000..160072a9f82e --- /dev/null +++ b/extensions/source/nsplugin/source/npsoplugin.def @@ -0,0 +1,21 @@ +LIBRARY "npsoplugin.dll" + +EXPORTS + NPP_GetMIMEDescription + NPP_Initialize + NPP_Shutdown + NPP_New + NPP_Destroy + NPP_SetWindow + NPP_NewStream + NPP_WriteReady + NPP_Write + NPP_DestroyStream + NPP_StreamAsFile + NPP_URLNotify + NPP_Print + NPP_Shutdown + NP_GetEntryPoints + NP_Initialize + NP_Shutdown + NP_GetMIMEDescription diff --git a/solenv/gbuild/platform/WNT_INTEL_GCC.mk b/solenv/gbuild/platform/WNT_INTEL_GCC.mk index 40027a102149..e8fe61670e34 100644 --- a/solenv/gbuild/platform/WNT_INTEL_GCC.mk +++ b/solenv/gbuild/platform/WNT_INTEL_GCC.mk @@ -278,12 +278,14 @@ gb_Library_PLAINLIBS_NONE += \ oleaut32 \ shell32 \ shlwapi \ + urlmon \ user32 \ uuid \ uwinapi \ winmm \ version \ winspool \ + ws2_32 \ gb_Library_LAYER := \ $(foreach lib,$(gb_Library_OOOLIBS),$(lib):OOO) \ -- cgit From d07860029a6912ceb1b47135ba1e8ab9f8232693 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Sat, 17 Dec 2011 22:11:56 +0100 Subject: extensions: nsplugin.rc: kill Oracle cruft --- extensions/source/nsplugin/source/nsplugin.rc | 30 --------------------------- 1 file changed, 30 deletions(-) delete mode 100644 extensions/source/nsplugin/source/nsplugin.rc diff --git a/extensions/source/nsplugin/source/nsplugin.rc b/extensions/source/nsplugin/source/nsplugin.rc deleted file mode 100644 index 34639157d7a4..000000000000 --- a/extensions/source/nsplugin/source/nsplugin.rc +++ /dev/null @@ -1,30 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ -#define ADDITIONAL_VERINFO1 VALUE "FileExtents", "sdc|sds|sda|sdd|sdp|smf|vor|sgl|sdw|sxc|stc|sxd|std|sxi|sti|sxm|sxw|sxg|stw|odt|ott|odm|oth|ods|ots|odg|otg|odp|otp|odf\0"\ - VALUE "FileOpenName", "StarCalc 3.0 - 5.0|StarChart 3.0 - 5.0|StarDraw 3.0 - 5.0|StarImpress 3.0 - 5.0|StarImpress-packed 3.0 - 5.0|StarMath 3.0 - 5.0|StarWriter Template 3.0 - 5.0|StarWriter Global 3.0 - 5.0|StarWriter 3.0 - 5.0|StarOffice 6.0/7 Spreadsheet|StarOffice 6.0/7 Spreadsheet Template|StarOffice 6.0/7 Drawing|StarOffice 6.0/7 Drawing Template|StarOffice 6.0/7 Presentation|StarOffice 6.0/7 Presentation Template|StarOffice 6.0/7 Formula|StarOffice 6.0/7 Text Document|StarOffice 6.0/7 Master Document|StarOffice 6.0/7 Text Document Template|OpenDocument Text|OpenDocument Text Template|OpenDocument Master Document|HTML Document Template|OpenDocument Spreadsheet|OpenDocument Spreadsheet Template|OpenDocument Drawing|OpenDocument Drawing Template|OpenDocument Presentation|OpenDocument Presentation Template|OpenDocument Formula\0" -#define ADDITIONAL_VERINFO2 VALUE "FileDescription", "Oracle Open Office Plug-in handles all its documents" VALUE "ProductName", "Oracle Open Office Plug-in" VALUE "MIMEType", "application/vnd.stardivision.calc|application/vnd.stardivision.chart|application/vnd.stardivision.draw|application/vnd.stardivision.impress|application/vnd.stardivision.impress-packed|application/vnd.stardivision.math|application/vnd.stardivision.writer|application/vnd.stardivision.writer-global|application/vnd.staroffice.writer|application/vnd.sun.xml.calc|application/vnd.sun.xml.calc.template|application/vnd.sun.xml.draw|application/vnd.sun.xml.draw.template|" -#define ADDITIONAL_VERINFO3 "application/vnd.sun.xml.impress|application/vnd.sun.xml.impress.template|application/vnd.sun.xml.math|application/vnd.sun.xml.writer|application/vnd.sun.xml.writer.global|application/vnd.sun.xml.writer.template|application/vnd.oasis.opendocument.text|application/vnd.oasis.opendocument.text-template|application/vnd.oasis.opendocument.text-master|application/vnd.oasis.opendocument.text-web|application/vnd.oasis.opendocument.spreadsheet|application/vnd.oasis.opendocument.spreadsheet-template|application/vnd.oasis.opendocument.graphics|application/vnd.oasis.opendocument.graphics-template|application/vnd.oasis.opendocument.presentation|application/vnd.oasis.opendocument.presentation-template|application/vnd.oasis.opendocument.formula\0" -- cgit From a12ea5554bcd9ddc7d7f1915ed67f0dd86e062b6 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Sat, 17 Dec 2011 22:11:56 +0100 Subject: extensions: nsplugin: use SAL_DLLPUBLIC_EXPORT --- extensions/Executable_nsplugin.mk | 6 +++++ extensions/Library_npsoplugin.mk | 1 - extensions/source/nsplugin/source/npshell.cxx | 28 ++++++++++++------------ extensions/source/nsplugin/source/npsoplugin.def | 21 ------------------ 4 files changed, 20 insertions(+), 36 deletions(-) delete mode 100755 extensions/source/nsplugin/source/npsoplugin.def diff --git a/extensions/Executable_nsplugin.mk b/extensions/Executable_nsplugin.mk index 439424f2f1d3..6b97d46e470e 100644 --- a/extensions/Executable_nsplugin.mk +++ b/extensions/Executable_nsplugin.mk @@ -48,6 +48,12 @@ $(eval $(call gb_Executable_add_linked_libs,nsplugin,\ sal \ )) +ifeq ($(OS),LINUX) +$(eval $(call gb_Executable_add_linked_libs,nsplugin,\ + dl \ +)) +endif + ifeq ($(OS),SOLARIS) $(eval $(call gb_Executable_add_libs,nsplugin,\ -lsocket \ diff --git a/extensions/Library_npsoplugin.mk b/extensions/Library_npsoplugin.mk index e5710fed4fa8..bf5f67e2de33 100644 --- a/extensions/Library_npsoplugin.mk +++ b/extensions/Library_npsoplugin.mk @@ -71,7 +71,6 @@ ifeq ($(GUI),WNT) $(eval $(call gb_Library_add_ldflags,npsoplugin,\ $(OUTDIR)/lib/pathutils-obj.obj \ $(OUTDIR)/lib/npwin.obj \ - /DEF:$(call gb_Helper_convert_native,$(SRCDIR)/extensions/source/nsplugin/source/npsoplugin.def) \ )) $(eval $(call gb_Library_add_linked_libs,npsoplugin,\ diff --git a/extensions/source/nsplugin/source/npshell.cxx b/extensions/source/nsplugin/source/npshell.cxx index 134ee3677e30..76dd7a86ac5b 100644 --- a/extensions/source/nsplugin/source/npshell.cxx +++ b/extensions/source/nsplugin/source/npshell.cxx @@ -361,7 +361,7 @@ MIMETYPE_OASIS_OPENDOCUMENT_PRESENTATION_ASCII ":odp:OpenDocument Presentation;" MIMETYPE_OASIS_OPENDOCUMENT_PRESENTATION_TEMPLATE_ASCII ":otp:OpenDocument Presentation Template;" MIMETYPE_OASIS_OPENDOCUMENT_FORMULA_ASCII ":odf:OpenDocument Formula;" ); -char* +SAL_DLLPUBLIC_EXPORT char* NPP_GetMIMEDescription(void) { debug_fprintf(NSP_LOG_APPEND, "print by Netscape Plugin, NPP_GetMIMEDescription:%s.\n", pMimeTypes); @@ -369,7 +369,7 @@ NPP_GetMIMEDescription(void) } #ifdef UNIX -NPError +SAL_DLLPUBLIC_EXPORT NPError // I am not actually sure wrt this, it ast least compiles with external // npapi.h now... NPP_GetValue(NPP /*instance*/, NPPVariable variable, void *value) @@ -404,7 +404,7 @@ dupMimeType(NPMIMEType type) } #endif // end of UNIX -NPError +SAL_DLLPUBLIC_EXPORT NPError NPP_Initialize(void) { debug_fprintf(NSP_LOG_NEW, "NS Plugin begin initialize.\n"); @@ -419,7 +419,7 @@ NPP_GetJavaClass() } #endif -void +SAL_DLLPUBLIC_EXPORT void NPP_Shutdown(void) { PLUGIN_MSG msg; @@ -435,7 +435,7 @@ NPP_Shutdown(void) #endif } -NPError +SAL_DLLPUBLIC_EXPORT NPError NPP_New(NPMIMEType pluginType, NPP instance, uint16_t mode, @@ -487,7 +487,7 @@ NPP_New(NPMIMEType pluginType, return NPERR_NO_ERROR; } -NPError +SAL_DLLPUBLIC_EXPORT NPError NPP_Destroy(NPP instance, NPSavedData** /*save*/) { debug_fprintf(NSP_LOG_APPEND, "print by Nsplugin, enter NPP_Destroy.\n"); @@ -532,7 +532,7 @@ NPP_Destroy(NPP instance, NPSavedData** /*save*/) } -NPError +SAL_DLLPUBLIC_EXPORT NPError NPP_SetWindow(NPP instance, NPWindow* window) { PluginInstance* This; @@ -626,7 +626,7 @@ NPP_SetWindow(NPP instance, NPWindow* window) } -NPError +SAL_DLLPUBLIC_EXPORT NPError NPP_NewStream(NPP instance, NPMIMEType /*type*/, NPStream* /*stream*/, @@ -648,21 +648,21 @@ int32_t STREAMBUFSIZE = 0X0FFFFFFF; * mode so we can take any size stream in our * write call (since we ignore it) */ -int32_t +SAL_DLLPUBLIC_EXPORT int32_t NPP_WriteReady(NPP /*instance*/, NPStream* /*stream*/) { return STREAMBUFSIZE; } -int32_t +SAL_DLLPUBLIC_EXPORT int32_t NPP_Write(NPP /*instance*/, NPStream* /*stream*/, int32_t /*offset*/, int32_t len, void* /*buffer*/) { return len; /* The number of bytes accepted */ } -NPError +SAL_DLLPUBLIC_EXPORT NPError NPP_DestroyStream(NPP instance, NPStream* /*stream*/, NPError /*reason*/) { if (instance == NULL) @@ -671,7 +671,7 @@ NPP_DestroyStream(NPP instance, NPStream* /*stream*/, NPError /*reason*/) } // save fname to another file with the original file name -void +SAL_DLLPUBLIC_EXPORT void NPP_StreamAsFile(NPP instance, NPStream *stream, const char* fname) { debug_fprintf(NSP_LOG_APPEND, "Into Stream\n"); @@ -812,14 +812,14 @@ NPP_StreamAsFile(NPP instance, NPStream *stream, const char* fname) debug_fprintf(NSP_LOG_APPEND, "NPP_StreamAsFile send SO_SET_WINDOW return failure \n"); } -void +SAL_DLLPUBLIC_EXPORT void NPP_URLNotify(NPP /*instance*/, const char* /*url*/, NPReason /*reason*/, void* /*notifyData*/) { } -void +SAL_DLLPUBLIC_EXPORT void NPP_Print(NPP instance, NPPrint* printInfo) { if(printInfo == NULL) diff --git a/extensions/source/nsplugin/source/npsoplugin.def b/extensions/source/nsplugin/source/npsoplugin.def deleted file mode 100755 index 160072a9f82e..000000000000 --- a/extensions/source/nsplugin/source/npsoplugin.def +++ /dev/null @@ -1,21 +0,0 @@ -LIBRARY "npsoplugin.dll" - -EXPORTS - NPP_GetMIMEDescription - NPP_Initialize - NPP_Shutdown - NPP_New - NPP_Destroy - NPP_SetWindow - NPP_NewStream - NPP_WriteReady - NPP_Write - NPP_DestroyStream - NPP_StreamAsFile - NPP_URLNotify - NPP_Print - NPP_Shutdown - NP_GetEntryPoints - NP_Initialize - NP_Shutdown - NP_GetMIMEDescription -- cgit From be0b58bed550469a195119962d32838ab336083c Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Sat, 17 Dec 2011 22:11:57 +0100 Subject: extensions: move mozilla to RepositoryExternal.mk --- RepositoryExternal.mk | 22 ++++++++++++++++++++++ extensions/Library_npsoplugin.mk | 12 +----------- 2 files changed, 23 insertions(+), 11 deletions(-) diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk index 11896cd801d8..86212220f7ef 100644 --- a/RepositoryExternal.mk +++ b/RepositoryExternal.mk @@ -901,6 +901,28 @@ endef endif # SYSTEM_CURL +ifeq ($(SYSTEM_MOZILLA_HEADERS),YES) + +define gb_LinkTarget__use_mozilla_headers +$(eval $(call gb_LinkTarget_set_include,$(1),\ + $$(INCLUDE) \ + $(MOZILLA_HEADERS_CFLAGS) +)) +endef + +else #!SYSTEM_MOZILLA_HEADERS + +define gb_LinkTarget__use_mozilla_headers +$(eval $(call gb_LinkTarget_set_include,$(1),\ + $$(INCLUDE) \ + -I$(OUTDIR)/inc/npsdk \ +)) +endef + +endif #SYSTEM_MOZILLA_HEADERS +#TODO np_sdk $(eval $(call gb_LinkTarget_add_external_headers,$(1),np_sdk)) + + # MacOSX-only frameworks ############################################ # (in alphabetical order) diff --git a/extensions/Library_npsoplugin.mk b/extensions/Library_npsoplugin.mk index bf5f67e2de33..954ba8655c92 100644 --- a/extensions/Library_npsoplugin.mk +++ b/extensions/Library_npsoplugin.mk @@ -30,17 +30,7 @@ $(eval $(call gb_Library_Library,npsoplugin)) -ifeq ($(SYSTEM_MOZILLA_HEADERS),YES) -$(eval $(call gb_Library_set_include,npsoplugin,\ - $$(INCLUDE) \ - $(MOZILLA_HEADERS_CFLAGS) -)) -else -$(eval $(call gb_Library_set_include,npsoplugin,\ - -I$(OUTDIR)/inc/npsdk \ - $$(INCLUDE) \ -)) -endif +$(eval $(call gb_Library_use_external,npsoplugin,mozilla_headers)) ifeq ($(GUI),UNX) -- cgit From a80a5ab4f6b243b94e89f1720b1c8c58e8611e93 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 22:11:57 +0100 Subject: extensions: convert plugin to gbuild --- Repository.mk | 11 +++ extensions/Executable_pluginapp.bin.mk | 98 ++++++++++++++++++ extensions/Library_pl.mk | 154 +++++++++++++++++++++++++++++ extensions/Module_extensions.mk | 5 + extensions/prj/build.lst | 10 +- extensions/source/plugin/aqua/makefile.mk | 63 ------------ extensions/source/plugin/base/makefile.mk | 65 ------------ extensions/source/plugin/pl.component | 37 +++++++ extensions/source/plugin/unx/makefile.mk | 104 ------------------- extensions/source/plugin/util/makefile.mk | 109 -------------------- extensions/source/plugin/util/makefile.pmk | 48 --------- extensions/source/plugin/util/pl.component | 37 ------- extensions/source/plugin/win/makefile.mk | 58 ----------- postprocess/packcomponents/makefile.mk | 2 +- 14 files changed, 307 insertions(+), 494 deletions(-) create mode 100644 extensions/Executable_pluginapp.bin.mk create mode 100644 extensions/Library_pl.mk delete mode 100644 extensions/source/plugin/aqua/makefile.mk delete mode 100644 extensions/source/plugin/base/makefile.mk create mode 100644 extensions/source/plugin/pl.component delete mode 100644 extensions/source/plugin/unx/makefile.mk delete mode 100644 extensions/source/plugin/util/makefile.mk delete mode 100644 extensions/source/plugin/util/makefile.pmk delete mode 100644 extensions/source/plugin/util/pl.component delete mode 100644 extensions/source/plugin/win/makefile.mk diff --git a/Repository.mk b/Repository.mk index b897665f060a..e065c511684d 100644 --- a/Repository.mk +++ b/Repository.mk @@ -92,6 +92,17 @@ endif endif +ifneq ($(WITH_MOZILLA),NO) +$(eval $(call gb_Helper_register_executables,OOO,\ + nspugin \ + pluginapp.bin \ +)) +$(eval $(call gb_Helper_register_libraries,OOOLIBS, \ + pl \ +)) +endif # WITH_MOZILLA + + $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ PptImporter \ adabas \ diff --git a/extensions/Executable_pluginapp.bin.mk b/extensions/Executable_pluginapp.bin.mk new file mode 100644 index 000000000000..4877eddff2b9 --- /dev/null +++ b/extensions/Executable_pluginapp.bin.mk @@ -0,0 +1,98 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Executable_Executable,pluginapp.bin)) + +$(eval $(call gb_Executable_set_include,pluginapp.bin,\ + $$(INCLUDE) \ + -I$(realpath $(SRCDIR)/extensions/source/plugin/inc) \ +)) + +$(eval $(call gb_Executable_add_api,pluginapp.bin,\ + offapi \ + udkapi \ +)) + +$(eval $(call gb_Executable_add_exception_objects,pluginapp.bin,\ + extensions/source/plugin/unx/npwrap \ + extensions/source/plugin/unx/npnapi \ + extensions/source/plugin/unx/mediator \ + extensions/source/plugin/unx/plugcon \ +)) + +$(eval $(call gb_Executable_add_linked_libs,pluginapp.bin,\ + sal \ +)) + +ifeq ($(OS),SOLARIS) +$(eval $(call gb_Executable_add_libs,pluginapp.bin,\ + -lXm \ + -lXt \ + -lXext \ + -lX11 \ + -ldl \ +)) +else ifeq ($(filter-out FREEBSD NETBSD OPENBSD DRAGONFLY,$(OS)),) +$(eval $(call gb_Executable_add_libs,pluginapp.bin,\ + -lXt \ + -lXext \ + -lX11 \ +)) +else ifeq ($(OS),AIX) +$(eval $(call gb_Executable_add_libs,pluginapp.bin,\ + -lXpm \ + -lXmu \ + -lXt \ + -lXext \ + -lX11 \ + -ldl \ +)) +else +$(eval $(call gb_Executable_add_libs,pluginapp.bin,\ + -lXt \ + -lXext \ + -lX11 \ + -ldl \ +)) +endif + + +ifeq ($(ENABLE_GTK),TRUE) +$(eval $(call gb_Executable_use_external,pluginapp.bin,gtk)) + +ifeq ($(OS),SOLARIS) +$(eval $(call gb_Executable_set_ldflags,pluginapp.bin,\ + -z nodefs \ +)) +endif + +endif + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_pl.mk b/extensions/Library_pl.mk new file mode 100644 index 000000000000..2f6ec5822767 --- /dev/null +++ b/extensions/Library_pl.mk @@ -0,0 +1,154 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,pl)) + +$(eval $(call gb_Library_set_componentfile,pl,extensions/source/plugin/pl)) + +$(eval $(call gb_Library_set_include,pl,\ + $$(INCLUDE) \ + -I$(realpath $(SRCDIR)/extensions/source/plugin/inc) \ + -I$(OUTDIR)/inc/mozilla/plugin \ +)) + +$(eval $(call gb_Library_add_api,pl,\ + offapi \ + udkapi \ +)) + +ifneq ($(SOLAR_JAVA),) + +$(eval $(call gb_Library_set_include,pl,\ + $$(INCLUDE) \ + -I$(OUTDIR)/mozilla/java \ + -I$(OUTDIR)/mozilla/nspr \ +)) + +ifeq ($(GUIBASE),aqua) +$(eval $(call gb_Library_set_include,pl,\ + $$(INCLUDE) \ + -I$(OUTDIR)/npsdk \ +)) +endif # GUIBASE=aqua + +endif # SOLAR_JAVA=YES + +ifeq ($(SYSTEM_MOZILLA),YES) +$(eval $(call gb_Library_add_defs,pl,\ + -DSYSTEM_MOZILLA \ +)) +endif # SYSTEM_MOZILLA=YES + +ifeq ($(OS),SOLARIS) +$(eval $(call gb_Library_add_libs,pl,\ + -lsocket \ +)) +endif # OS=SOLARIS + +ifeq ($(GUI),WNT) +$(eval $(call gb_Library_add_linked_libs,pl,\ + version \ + ole32 \ + advapi32 \ +)) + +$(eval $(call gb_Library_add_exception_objects,pl,\ + extensions/source/plugin/win/winmgr \ + extensions/source/plugin/win/sysplug \ +)) +endif # GUI=WNT + +ifeq ($(GUI),UNX) + +ifeq ($(GUIBASE),aqua) + +$(eval $(call gb_Library_add_exception_objects,pl,\ + extensions/source/plugin/aqua/macmgr \ + extensions/source/plugin/sysplug \ +)) + +$(eval $(call gb_Library_set_include,pl,\ + $$(INCLUDE) \ + -I$(realpath $(FRAMEWORKSHOME)/ApplicationServices.framework/Version/Current/Frameworks/QD.framework/Headers) \ + -I$(realpath $(FRAMEWORKSHOME)/Carbon.framework/Versions/Current/Frameworks/HIToolbox.framework/Versions/Current/Headers) \ +)) + +endif # GUIBASE=aqua + +ifeq ($(ENABLE_GTK),TRUE) +$(eval $(call gb_Library_add_defs,pl,\ + -DENABLE_GTK \ +)) + +$(eval $(call gb_Library_use_external,pl,gtk)) +endif # ENABLE_GTK=TRUE + +$(eval $(call gb_Library_add_exception_objects,pl,\ + extensions/source/plugin/unx/nppapi \ + extensions/source/plugin/unx/sysplug \ + extensions/source/plugin/unx/mediator \ + extensions/source/plugin/unx/plugcon \ + extensions/source/plugin/unx/unxmgr \ +)) + +$(eval $(call gb_Library_add_libs,pl,\ + -lX11 \ +)) + +endif # GUI=UNX + +$(eval $(call gb_Library_add_linked_libs,pl,\ + tk \ + vcl \ + svl \ + utl \ + tl \ + ucbhelper \ + cppuhelper \ + cppu \ + sal \ + salhelper \ + $(gb_STDLIBS) \ +)) + +$(eval $(call gb_Library_add_exception_objects,pl,\ + extensions/source/plugin/base/plctrl \ + extensions/source/plugin/base/service \ + extensions/source/plugin/base/xplugin \ + extensions/source/plugin/base/nfuncs \ + extensions/source/plugin/base/manager \ + extensions/source/plugin/base/context \ + extensions/source/plugin/base/evtlstnr \ + extensions/source/plugin/base/plcom \ + extensions/source/plugin/base/multiplx \ + extensions/source/plugin/base/plmodel \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index 78830783761b..dd7c3359fb54 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -52,6 +52,7 @@ endif ifneq ($(WITH_MOZILLA),NO) $(eval $(call gb_Module_add_targets,extensions,\ + Library_pl \ Executable_nsplugin \ )) @@ -64,6 +65,10 @@ endif # GUI=WNT ifeq ($(GUI),UNX) +$(eval $(call gb_Module_add_targets,extensions,\ + Executable_pluginapp.bin \ +)) + ifneq ($(ENABLE_GTK),) $(eval $(call gb_Module_add_targets,extensions,\ Library_npsoplugin \ diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index e6144e5d14ed..d47b82a57f1a 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -3,17 +3,9 @@ ex extensions : officecfg TRANSLATIONS:translations DESKTOP:rdbmaker svx SANE ex extensions usr1 - all ex_mkout NULL ex extensions\inc nmake - all ex_inc NULL ex extensions\inc\ucbhelper get - all ex_incucbh ex_inc NULL -ex extensions\source\plugin\workben get - all ex_plwkb ex_inc NULL -ex extensions\source\plugin\inc\plugin\win get - all ex_piwi ex_inc NULL -ex extensions\source\plugin\inc\plugin\unx get - all ex_piux ex_inc NULL ex extensions\source\activex\msidl nmake - w ex_axmsidl ex_inc NULL ex extensions\source\activex\main nmake - w ex_axmain ex_axmsidl.w ex_inc NULL ex extensions\source\resource nmake - all ex_resrc ex_inc NULL -ex extensions\source\plugin\aqua nmake - u ex_plaqua ex_plbase NULL -ex extensions\source\plugin\base nmake - all ex_plbase ex_inc NULL -ex extensions\source\plugin\win nmake - w ex_plwin ex_plbase ex_inc NULL -ex extensions\source\plugin\unx nmake - u ex_plunx ex_inc NULL -ex extensions\source\plugin\util nmake - all ex_plutil ex_plbase ex_plunx.u ex_plwin.w ex_plaqua.u ex_inc NULL ex extensions\source\macosx\spotlight nmake - u ex_mxspotlight NULL ex extensions\source\bibliography nmake - all ex_bib ex_inc NULL ex extensions\source\xmlextract nmake - all ex_xmlextr ex_inc NULL @@ -21,7 +13,7 @@ ex extensions\source\dbpilots nmake - all ex_dbpilots ex_i ex extensions\source\abpilot nmake - all ex_abpilot ex_inc NULL ex extensions\source\logging nmake - all ex_logging ex_inc NULL ex extensions\source\config\ldap nmake - all ex_ldap ex_inc NULL -ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging ex_ldap ex_bib ex_plutil NULL +ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging ex_ldap ex_bib NULL ex extensions\prj nmake - all ex_prj NULL # Fails at the moment diff --git a/extensions/source/plugin/aqua/makefile.mk b/extensions/source/plugin/aqua/makefile.mk deleted file mode 100644 index 8d1aaa484d28..000000000000 --- a/extensions/source/plugin/aqua/makefile.mk +++ /dev/null @@ -1,63 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/..$/.. - -PRJNAME=extensions -TARGET=plaqua - -.INCLUDE : ..$/util$/makefile.pmk - -.IF "$(GUIBASE)"!="aqua" || "$(WITH_MOZILLA)"=="NO" - -dummy: - @echo "Nothing to build for GUIBASE $(GUIBASE)." - -.ELSE - -# --- Files -------------------------------------------------------- - -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/plugin -.IF "$(SOLAR_JAVA)" != "" -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/java -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/nspr -INCPRE+=-I$(SOLARINCDIR)$/npsdk -CDEFS+=-DOJI -.ENDIF - -.IF "$(GUIBASE)"=="aqua" -CFLAGSCXX+=$(OBJCXXFLAGS) -.ENDIF # "$(GUIBASE)"=="aqua" - -SLOFILES=\ - $(SLO)$/macmgr.obj \ - $(SLO)$/sysplug.obj - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk - -.ENDIF # $(GUIBASE)==aqua diff --git a/extensions/source/plugin/base/makefile.mk b/extensions/source/plugin/base/makefile.mk deleted file mode 100644 index a7e28f8deae5..000000000000 --- a/extensions/source/plugin/base/makefile.mk +++ /dev/null @@ -1,65 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/..$/.. - -PRJNAME=extensions -TARGET=plbase -TARGETTYPE=GUI -ENABLE_EXCEPTIONS=TRUE - -.INCLUDE : ..$/util$/makefile.pmk - -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/plugin -.IF "$(SOLAR_JAVA)" != "" -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/java -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/nspr -.ENDIF - -.IF "$(WITH_MOZILLA)" != "NO" - -.IF "$(GUIBASE)"=="aqua" -CFLAGSCXX+=$(OBJCXXFLAGS) -.ENDIF # "$(GUIBASE)"=="aqua" - -SLOFILES= \ - $(SLO)$/plctrl.obj \ - $(SLO)$/service.obj \ - $(SLO)$/xplugin.obj \ - $(SLO)$/nfuncs.obj \ - $(SLO)$/manager.obj \ - $(SLO)$/context.obj \ - $(SLO)$/evtlstnr.obj \ - $(SLO)$/plcom.obj \ - $(SLO)$/multiplx.obj \ - $(SLO)$/plmodel.obj - -.ENDIF # $(WITH_MOZILLA) != "NO" - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk - diff --git a/extensions/source/plugin/pl.component b/extensions/source/plugin/pl.component new file mode 100644 index 000000000000..4a9d98f7dc7b --- /dev/null +++ b/extensions/source/plugin/pl.component @@ -0,0 +1,37 @@ + + + + + + + + + + + diff --git a/extensions/source/plugin/unx/makefile.mk b/extensions/source/plugin/unx/makefile.mk deleted file mode 100644 index 9dcdf1ace314..000000000000 --- a/extensions/source/plugin/unx/makefile.mk +++ /dev/null @@ -1,104 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/..$/.. - -PRJNAME=extensions -TARGET=plunx -TARGETTYPE=CUI -ENABLE_EXCEPTIONS=TRUE - -.INCLUDE : ..$/util$/makefile.pmk - -.IF "$(GUIBASE)"=="aqua" -dummy: - @echo "Nothing to build for GUIBASE aqua." - -.ELSE - -# --- Files -------------------------------------------------------- - -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/plugin -.IF "$(SOLAR_JAVA)" != "" -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/java -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/nspr -CDEFS+=-DOJI -.ENDIF - -.IF "$(WITH_MOZILLA)" != "NO" - -SLOFILES=\ - $(SLO)$/nppapi.obj \ - $(SLO)$/sysplug.obj \ - $(SLO)$/mediator.obj \ - $(SLO)$/plugcon.obj \ - $(SLO)$/unxmgr.obj - -OBJFILES=\ - $(OBJ)$/npwrap.obj \ - $(OBJ)$/npnapi.obj \ - $(OBJ)$/mediator.obj \ - $(OBJ)$/plugcon.obj - -APP1TARGET=pluginapp.bin -APP1OBJS=$(OBJFILES) -APP1STDLIBS= $(SALLIB) - -.IF "$(OS)"=="SOLARIS" || "$(OS)"=="SCO" -APP1STDLIBS+=-lXm -lXt $(X11LINK_DYNAMIC) -ldl -.ELSE -.IF "$(OS)"=="FREEBSD" || "$(OS)"=="NETBSD" || "$(OS)"=="OPENBSD" || "$(OS)"=="DRAGONFLY" -APP1STDLIBS+= -lXt -lXext -lX11 -.ELIF "$(OS)"=="AIX" -APP1STDLIBS+= -lXpm -lXmu -lXt $(X11LINK_DYNAMIC) -ldl -.ELSE -APP1STDLIBS+= -lXt $(X11LINK_DYNAMIC) -ldl -.ENDIF -.ENDIF - -.IF "$(ENABLE_GTK)" == "TRUE" -# libs for gtk plugin -APP1STDLIBS+=$(PKGCONFIG_LIBS:s/ -lpangoxft-1.0//) -# hack for faked SO environment -.IF "$(PKGCONFIG_ROOT)"!="" -.IF "$(OS)" == "SOLARIS" -# don't ask, it's ugly -DIRECT :=-z nodefs $(DIRECT) -.ENDIF -.ENDIF # "$(PKGCONFIG_ROOT)"!="" -.ENDIF - - -APP1DEF= $(MISC)$/$(TARGET).def - -.ENDIF # $(WITH_MOZILLA) != "NO" - -.ENDIF # $(GUIBASE)==aqua - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk - diff --git a/extensions/source/plugin/util/makefile.mk b/extensions/source/plugin/util/makefile.mk deleted file mode 100644 index 7b7d047a1779..000000000000 --- a/extensions/source/plugin/util/makefile.mk +++ /dev/null @@ -1,109 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/..$/.. - -PRJNAME=extensions -TARGET=pl -TARGETTYPE=GUI - -# --- Settings ----------------------------------------------------- - -.INCLUDE : settings.mk - -# --- Files -------------------------------------------------------- - -.IF "$(WITH_MOZILLA)" != "NO" - -LIB1TARGET = $(SLB)$/plall.lib -LIB1FILES = \ - $(SLB)$/plbase.lib \ - $(SHL1LINKLIB) - -.IF "$(GUI)" == "UNX" -.IF "$(GUIBASE)"=="aqua" -.IF "$(WITH_MOZILLA)"=="YES" -SHL1LINKLIB = $(SLB)$/plaqua.lib -.ENDIF -.ELSE -SHL1LINKLIB = $(SLB)$/plunx.lib -.ENDIF # $(GUIBASE)==aqua -.IF "$(OS)" == "SOLARIS" -SHL1OWNLIBS = -lsocket -.ENDIF # SOLARIS -.ENDIF # UNX - -.IF "$(GUI)" == "WNT" -SHL1LINKLIB = $(SLB)$/plwin.lib -SHL1OWNLIBS = \ - $(VERSIONLIB) \ - $(OLE32LIB) \ - $(ADVAPI32LIB) -.ENDIF # WNT - -SHL1TARGET= $(TARGET)$(DLLPOSTFIX) -SHL1IMPLIB= i$(TARGET) - -SHL1VERSIONMAP=$(SOLARENV)/src/component.map -SHL1DEF=$(MISC)$/$(SHL1TARGET).def -DEF1NAME=$(SHL1TARGET) - -SHL1LIBS=$(LIB1TARGET) - -SHL1STDLIBS+= \ - $(TKLIB) \ - $(VCLLIB) \ - $(SVLLIB) \ - $(UNOTOOLSLIB) \ - $(TOOLSLIB) \ - $(UCBHELPERLIB) \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(SALLIB) \ - $(SALHELPERLIB) - -.IF "$(GUIBASE)"=="unx" -SHL1STDLIBS+=$(X11LINK_DYNAMIC) -.ENDIF - -SHL1STDLIBS+=$(SHL1OWNLIBS) - -.ENDIF # $(WITH_MOZILLA) != "NO" - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk - - - - -ALLTAR : $(MISC)/pl.component - -$(MISC)/pl.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - pl.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt pl.component diff --git a/extensions/source/plugin/util/makefile.pmk b/extensions/source/plugin/util/makefile.pmk deleted file mode 100644 index 0f06ea2a50ce..000000000000 --- a/extensions/source/plugin/util/makefile.pmk +++ /dev/null @@ -1,48 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -NOUNODOC=true - -.INCLUDE : settings.mk - -.IF "$(SYSTEM_MOZILLA)" == "YES" -CFLAGS+=-DSYSTEM_MOZILLA -PKGCONFIG_MODULES+=$(MOZ_FLAVOUR)-plugin -.ENDIF - -.IF "$(GUIBASE)" == "unx" && "$(ENABLE_GTK)" == "TRUE" -CDEFS+=-DENABLE_GTK -PKGCONFIG_MODULES+=gtk+-2.0 gthread-2.0 -.ENDIF - -.IF "$(GUIBASE)" == "aqua" -CFLAGS += -I$(FRAMEWORKSHOME)/ApplicationServices.framework/Versions/Current/Frameworks/QD.framework/Headers\ - -I$(FRAMEWORKSHOME)/Carbon.framework/Versions/Current/Frameworks/HIToolbox.framework/Versions/Current/Headers -.ENDIF - -.IF "$(PKGCONFIG_MODULES)" != "" -.INCLUDE : pkg_config.mk -.ENDIF diff --git a/extensions/source/plugin/util/pl.component b/extensions/source/plugin/util/pl.component deleted file mode 100644 index 4a9d98f7dc7b..000000000000 --- a/extensions/source/plugin/util/pl.component +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - - - - - diff --git a/extensions/source/plugin/win/makefile.mk b/extensions/source/plugin/win/makefile.mk deleted file mode 100644 index 7f676ac16748..000000000000 --- a/extensions/source/plugin/win/makefile.mk +++ /dev/null @@ -1,58 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=..$/..$/.. - -PRJNAME=extensions -TARGET=plwin -ENABLE_EXCEPTIONS=TRUE - -# --- Settings ----------------------------------------------------- -.IF "$(GUI)" == "WNT" - -.INCLUDE : ..$/util$/makefile.pmk - -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/plugin -.IF "$(SOLAR_JAVA)" != "" -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/java -INCPRE+=-I$(SOLARINCDIR)$/mozilla$/nspr -CDEFS+=-DOJI -.ENDIF - -# --- Types ------------------------------------- - -.IF "$(WITH_MOZILLA)" != "NO" -SLOFILES = $(SLO)$/winmgr.obj \ - $(SLO)$/sysplug.obj -.ENDIF # $(WITH_MOZILLA) != "NO" - -.ENDIF - -# ------------------------------------------------------------------ - -.INCLUDE : target.mk - diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index 2ffa9775cc87..c9e7a2df68f6 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -272,7 +272,7 @@ my_components += ldapbe2 .END .IF "$(WITH_MOZILLA)" != "NO" -my_components += pl +my_components += component/extensions/source/plugin/pl .END .IF "$(ENABLE_XMLSEC)" == "YES" -- cgit From fc75a113718cbab1f6a06743085f2d3d3dd0725a Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Sat, 17 Dec 2011 22:11:57 +0100 Subject: extensions: tweaks to the plugin makefiles --- extensions/Executable_pluginapp.bin.mk | 3 +- extensions/Library_pl.mk | 30 +- extensions/source/plugin/aqua/sysplug.cxx | 812 ------------------------------ extensions/source/plugin/aqua/sysplug.mm | 812 ++++++++++++++++++++++++++++++ 4 files changed, 832 insertions(+), 825 deletions(-) delete mode 100644 extensions/source/plugin/aqua/sysplug.cxx create mode 100644 extensions/source/plugin/aqua/sysplug.mm diff --git a/extensions/Executable_pluginapp.bin.mk b/extensions/Executable_pluginapp.bin.mk index 4877eddff2b9..b67d9e304a70 100644 --- a/extensions/Executable_pluginapp.bin.mk +++ b/extensions/Executable_pluginapp.bin.mk @@ -32,7 +32,7 @@ $(eval $(call gb_Executable_Executable,pluginapp.bin)) $(eval $(call gb_Executable_set_include,pluginapp.bin,\ $$(INCLUDE) \ - -I$(realpath $(SRCDIR)/extensions/source/plugin/inc) \ + -I$(SRCDIR)/extensions/source/plugin/inc \ )) $(eval $(call gb_Executable_add_api,pluginapp.bin,\ @@ -87,6 +87,7 @@ endif ifeq ($(ENABLE_GTK),TRUE) $(eval $(call gb_Executable_use_external,pluginapp.bin,gtk)) +# the orignal dmakefile said: don't ask, it's ugly ifeq ($(OS),SOLARIS) $(eval $(call gb_Executable_set_ldflags,pluginapp.bin,\ -z nodefs \ diff --git a/extensions/Library_pl.mk b/extensions/Library_pl.mk index 2f6ec5822767..8329ac8a5a09 100644 --- a/extensions/Library_pl.mk +++ b/extensions/Library_pl.mk @@ -34,7 +34,7 @@ $(eval $(call gb_Library_set_componentfile,pl,extensions/source/plugin/pl)) $(eval $(call gb_Library_set_include,pl,\ $$(INCLUDE) \ - -I$(realpath $(SRCDIR)/extensions/source/plugin/inc) \ + -I$(SRCDIR)/extensions/source/plugin/inc \ -I$(OUTDIR)/inc/mozilla/plugin \ )) @@ -51,6 +51,10 @@ $(eval $(call gb_Library_set_include,pl,\ -I$(OUTDIR)/mozilla/nspr \ )) +$(eval $(call gb_Library_add_defs,pl,\ + -DOJI \ +)) + ifeq ($(GUIBASE),aqua) $(eval $(call gb_Library_set_include,pl,\ $$(INCLUDE) \ @@ -91,13 +95,15 @@ ifeq ($(GUIBASE),aqua) $(eval $(call gb_Library_add_exception_objects,pl,\ extensions/source/plugin/aqua/macmgr \ - extensions/source/plugin/sysplug \ +)) +$(eval $(call gb_Library_add_objcxxobjects,pl,\ + extensions/source/plugin/aqua/sysplug \ )) $(eval $(call gb_Library_set_include,pl,\ $$(INCLUDE) \ - -I$(realpath $(FRAMEWORKSHOME)/ApplicationServices.framework/Version/Current/Frameworks/QD.framework/Headers) \ - -I$(realpath $(FRAMEWORKSHOME)/Carbon.framework/Versions/Current/Frameworks/HIToolbox.framework/Versions/Current/Headers) \ + -I$(FRAMEWORKSHOME)/ApplicationServices.framework/Version/Current/Frameworks/QD.framework/Headers \ + -I$(FRAMEWORKSHOME)/Carbon.framework/Versions/Current/Frameworks/HIToolbox.framework/Versions/Current/Headers \ )) endif # GUIBASE=aqua @@ -111,10 +117,10 @@ $(eval $(call gb_Library_use_external,pl,gtk)) endif # ENABLE_GTK=TRUE $(eval $(call gb_Library_add_exception_objects,pl,\ - extensions/source/plugin/unx/nppapi \ - extensions/source/plugin/unx/sysplug \ extensions/source/plugin/unx/mediator \ + extensions/source/plugin/unx/nppapi \ extensions/source/plugin/unx/plugcon \ + extensions/source/plugin/unx/sysplug \ extensions/source/plugin/unx/unxmgr \ )) @@ -139,16 +145,16 @@ $(eval $(call gb_Library_add_linked_libs,pl,\ )) $(eval $(call gb_Library_add_exception_objects,pl,\ - extensions/source/plugin/base/plctrl \ - extensions/source/plugin/base/service \ - extensions/source/plugin/base/xplugin \ - extensions/source/plugin/base/nfuncs \ - extensions/source/plugin/base/manager \ extensions/source/plugin/base/context \ extensions/source/plugin/base/evtlstnr \ - extensions/source/plugin/base/plcom \ + extensions/source/plugin/base/manager \ extensions/source/plugin/base/multiplx \ + extensions/source/plugin/base/nfuncs \ + extensions/source/plugin/base/plcom \ + extensions/source/plugin/base/plctrl \ extensions/source/plugin/base/plmodel \ + extensions/source/plugin/base/service \ + extensions/source/plugin/base/xplugin \ )) # vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/source/plugin/aqua/sysplug.cxx b/extensions/source/plugin/aqua/sysplug.cxx deleted file mode 100644 index 415ca936c46f..000000000000 --- a/extensions/source/plugin/aqua/sysplug.cxx +++ /dev/null @@ -1,812 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ -#include - -#include -#include -#include -#include - -#include - -extern NPNetscapeFuncs aNPNFuncs; - -#include - -using namespace plugstringhelper; - -using ::rtl::OUString; -using ::rtl::OUStringToOString; - -#if OSL_DEBUG_LEVEL > 1 -void TRACE( char const * s ); -void TRACEN( char const * s, long n ); -#else -#define TRACE(x) -#define TRACEN(x,n) -#endif - -struct FakeEventRecord : public EventRecord -{ - FakeEventRecord() - { - memset( this, 0, sizeof(EventRecord) ); - ::GetGlobalMouse( &where ); - when = ::TickCount(); - modifiers = ::GetCurrentEventKeyModifiers(); - } -}; - - -@interface OOoPluginView : NSView -{ - XPlugin_Impl* m_pImpl; - MacPluginComm* m_pCom; -} --(id)initWithInstance: (XPlugin_Impl*)i_pImpl pluginComm: (MacPluginComm*)i_pCom frame: (NSRect)i_aRect; --(void)drawRect: (NSRect)i_aRect; --(BOOL)isOpaque; --(BOOL)isFlipped; - -// NSResponder --(void)mouseMoved: (NSEvent*)i_pEvent; --(void)mouseDown: (NSEvent*)i_pEvent; --(void)mouseDragged: (NSEvent*)i_pEvent; --(void)mouseUp: (NSEvent*)i_pEvent; --(void)rightMouseDown: (NSEvent*)i_pEvent; --(void)rightMouseDragged: (NSEvent*)i_pEvent; --(void)rightMouseUp: (NSEvent*)i_pEvent; --(void)otherMouseDown: (NSEvent*)i_pEvent; --(void)otherMouseDragged: (NSEvent*)i_pEvent; --(void)otherMouseUp: (NSEvent*)i_pEvent; --(void)mouseEntered: (NSEvent*)i_pEvent; --(void)mouseExited: (NSEvent*)i_pEvent; -@end - -@implementation OOoPluginView --(id)initWithInstance: (XPlugin_Impl*)i_pImpl pluginComm: (MacPluginComm*)i_pCom frame: (NSRect) i_aRect -{ - if( (self = [super initWithFrame: i_aRect]) ) - { - m_pImpl = i_pImpl; - m_pCom = i_pCom; - } - return self; -} - --(void)drawRect: (NSRect) i_aRect -{ - m_pCom->drawView( m_pImpl ); -} - --(BOOL)isOpaque -{ - return NO; -} - --(BOOL)isFlipped -{ - return YES; -} - -// NSResponder --(void)mouseMoved: (NSEvent*)i_pEvent -{ - FakeEventRecord aRec; - aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)mouseDown: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = mouseDown; - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)mouseDragged: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)mouseUp: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = mouseUp; - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)rightMouseDown: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = mouseDown; - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)rightMouseDragged: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)rightMouseUp: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = mouseUp; - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)otherMouseDown: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = mouseDown; - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)otherMouseDragged: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)otherMouseUp: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = mouseUp; - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)mouseEntered: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - --(void)mouseExited: (NSEvent*)i_pEvent; -{ - FakeEventRecord aRec; - aRec.what = aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent - m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); -} - -@end - -//-------------------------------------------------------------------------------------------------- -MacPluginComm::MacPluginComm( const rtl::OUString& i_rMimetype, const rtl::OUString& i_rBundle, NSView* i_pParent ) - : PluginComm( OUStringToOString( i_rBundle, RTL_TEXTENCODING_UTF8 ) ), - m_xBundle( NULL ), - m_hPlugLib( NULL ), - m_pNullTimer( NULL ) -{ - // initialize plugin function table - memset( &m_aNPPfuncs, 0, sizeof( m_aNPPfuncs ) ); - - // load the bundle - CFURLRef xURL = createURL( i_rBundle ); - m_xBundle = CFBundleCreate( NULL, xURL ); - CFRelease( xURL ); - if( m_xBundle ) - { - // ask the plugin library - // first get its location - CFURLRef xLibURL = CFBundleCopyExecutableURL( m_xBundle ); - if( xLibURL ) - { - // get the file system path - rtl::OUString aModuleURL( CFURLtoOSLURL( xLibURL ) ); - CFRelease( xLibURL ); - m_hPlugLib = osl_loadModule( aModuleURL.pData, SAL_LOADMODULE_DEFAULT ); - #if OSL_DEBUG_LEVEL > 1 - if( ! m_hPlugLib ) - fprintf( stderr, "module %s could not be loaded\n", OUStringToOString( aModuleURL, RTL_TEXTENCODING_UTF8 ).getStr() ); - #endif - } - #if OSL_DEBUG_LEVEL > 1 - else - fprintf( stderr, "bundle %s has no exectutable URL\n", OUStringToOString( i_rBundle, RTL_TEXTENCODING_UTF8 ).getStr() ); - #endif - } - else - { - #if OSL_DEBUG_LEVEL > 1 - fprintf( stderr, "bundle %s could not be loaded\n", OUStringToOString( i_rBundle, RTL_TEXTENCODING_UTF8 ).getStr() ); - #endif - } - - DBG_ASSERT( m_xBundle && m_hPlugLib, "loading plugin bundle failed!" ); - - - m_aNPPfuncs.size = sizeof( m_aNPPfuncs ); - m_aNPPfuncs.version = 0; - - - m_eCall = eNP_Initialize; - execute(); -} - -//-------------------------------------------------------------------------------------------------- -MacPluginComm::~MacPluginComm() -{ - if( m_hPlugLib ) - { - // NPP_Shutdown(); - NPError (*pShutdown)(); - if( retrieveFunction( "NP_Shutdown", (void**)&pShutdown ) ) - { - NPError nErr = (*pShutdown)(); (void)nErr; - DBG_ASSERT( nErr == NPERR_NO_ERROR, "NP_Shutdown() failed!" ); - } - osl_unloadModule( m_hPlugLib ); - } - if( m_xBundle ) - CFRelease( m_xBundle ); -} - -//-------------------------------------------------------------------------------------------------- -sal_Bool MacPluginComm::retrieveFunction( const char* i_pName, void** o_ppFunc ) const -{ - if( ! m_hPlugLib || ! o_ppFunc ) - return sal_False; - - *o_ppFunc = (void*)osl_getAsciiFunctionSymbol( m_hPlugLib, i_pName ); - - if( ! *o_ppFunc && m_xBundle ) - { - rtl::OUString aName( OUString::createFromAscii( *i_pName == '_' ? i_pName+1 : i_pName ) ); - CFStringRef xName = createString( aName ); - if( xName ) - { - *o_ppFunc = CFBundleGetFunctionPointerForName( m_xBundle, xName ); - CFRelease( xName ); - } - } - - return (*o_ppFunc != NULL); -} - -IMPL_LINK( MacPluginComm, NullTimerHdl, void*, EMPTYARG ) -{ - // note: this is a Timer handler, we are already protected by the SolarMutex - - FakeEventRecord aRec; - aRec.what = nullEvent; - aRec.where.h = aRec.where.v = 20000; - - for( std::list< XPlugin_Impl* >::iterator it = m_aNullEventClients.begin(); - it != m_aNullEventClients.end(); ++it ) - { - SysPlugData& rPlugData( (*it)->getSysPlugData() ); - if( rPlugData.m_pPlugView ) // for safety do not dispatch null events before first NPP_SetWindow - (*m_aNPPfuncs.event)( (*it)->getNPPInstance(), &aRec ); - } - - return 0; -} - -//-------------------------------------------------------------------------------------------------- - -long MacPluginComm::doIt() -{ - long nRet = 0; - switch( m_eCall ) - { - case eNP_Initialize: - { - TRACE( "eNP_Initialize" ); - NPError (*pInit)( NPNetscapeFuncs* ); - if( retrieveFunction( "NP_Initialize", (void**)&pInit ) ) - { - nRet = (*pInit)( &aNPNFuncs ); - - NPError nErr = NPERR_NO_ERROR; - NPError (*pEntry)( NPPluginFuncs* ); - retrieveFunction( "NP_GetEntryPoints", (void**)&pEntry ); - nErr = (*pEntry)( &m_aNPPfuncs ); - - DBG_ASSERT( nErr == NPERR_NO_ERROR, "NP_GetEntryPoints() failed!" ); - } - else - { - nRet = NPERR_GENERIC_ERROR; - } - DBG_ASSERT( nRet == NPERR_NO_ERROR, "### NP_Initialize() failed!" ); - } - break; - case eNPP_Destroy: - if( m_aNullEventClients.empty() ) - delete m_pNullTimer, m_pNullTimer = NULL; - - TRACE( "eNPP_Destroy" ); - nRet = (m_aNPPfuncs.destroy - ? (*m_aNPPfuncs.destroy)( - (NPP)m_aArgs[0], - (NPSavedData**)m_aArgs[1] ) - : NPERR_GENERIC_ERROR); - break; - case eNPP_DestroyStream: - TRACE( "eNPP_DestroyStream" ); - nRet = (m_aNPPfuncs.destroystream - ? (*m_aNPPfuncs.destroystream)( - (NPP)m_aArgs[0], - (NPStream*)m_aArgs[1], - (NPError)(sal_IntPtr)m_aArgs[2] ) - : NPERR_GENERIC_ERROR); - break; - case eNPP_New: - TRACE( "eNPP_New" ); - nRet = (m_aNPPfuncs.newp - ? (*m_aNPPfuncs.newp)( - (NPMIMEType)m_aArgs[0], - (NPP)m_aArgs[1], - (uint16_t)(sal_IntPtr)m_aArgs[2], - (int16_t)(sal_IntPtr)m_aArgs[3], - (char**)m_aArgs[4], - (char**)m_aArgs[5], - (NPSavedData*)m_aArgs[6] ) - : NPERR_GENERIC_ERROR); - - if( ! m_pNullTimer && m_aNPPfuncs.event ) - { - m_pNullTimer = new AutoTimer(); - m_pNullTimer->SetTimeout( 50 ); - m_pNullTimer->SetTimeoutHdl( LINK( this, MacPluginComm, NullTimerHdl ) ); - m_pNullTimer->Start(); - } - - break; - case eNPP_NewStream: - TRACE( "eNPP_NewStream" ); - nRet = (m_aNPPfuncs.newstream - ? (*m_aNPPfuncs.newstream)( - (NPP)m_aArgs[0], - (NPMIMEType)m_aArgs[1], - (NPStream*)m_aArgs[2], - (NPBool)(sal_IntPtr)m_aArgs[3], - (uint16_t*)m_aArgs[4] ) - : NPERR_GENERIC_ERROR); - break; - case eNPP_Print: - TRACE( "eNPP_Print" ); - if (m_aNPPfuncs.print) - (*m_aNPPfuncs.print)( - (NPP)m_aArgs[0], - (NPPrint*)m_aArgs[1] ); - break; - case eNPP_SetWindow: - { - TRACE( "eNPP_SetWindow" ); - nRet = (m_aNPPfuncs.setwindow - ? (*m_aNPPfuncs.setwindow)( - (NPP)m_aArgs[0], - (NPWindow*)m_aArgs[1] ) - : NPERR_GENERIC_ERROR); - - break; - } - case eNPP_HandleEvent: - { - TRACE( "eNPP_HandleEvent" ); - nRet = (m_aNPPfuncs.event - ? (*m_aNPPfuncs.event)( - (NPP)m_aArgs[0], - m_aArgs[1] ) - : NPERR_GENERIC_ERROR); - - break; - } - case eNPP_StreamAsFile: - TRACE( "eNPP_StreamAsFile" ); - if (m_aNPPfuncs.asfile) - (*m_aNPPfuncs.asfile)( - (NPP)m_aArgs[0], - (NPStream*)m_aArgs[1], - (char*)m_aArgs[2] ); - break; - case eNPP_URLNotify: - TRACE( "eNPP_URLNotify" ); - if (m_aNPPfuncs.urlnotify) - (*m_aNPPfuncs.urlnotify)( - (NPP)m_aArgs[0], - (char*)m_aArgs[1], - (NPReason)(sal_IntPtr)m_aArgs[2], - m_aArgs[3] ); - break; - case eNPP_Write: - TRACEN( "eNPP_Write n=", (int32_t)m_aArgs[3] ); - nRet = (m_aNPPfuncs.write - ? (*m_aNPPfuncs.write)( - (NPP)m_aArgs[0], - (NPStream*)m_aArgs[1], - (int32_t)m_aArgs[2], - (int32_t)m_aArgs[3], - m_aArgs[4] ) - : 0); - break; - case eNPP_WriteReady: - TRACE( "eNPP_WriteReady" ); - nRet = (m_aNPPfuncs.writeready - ? (*m_aNPPfuncs.writeready)( - (NPP)m_aArgs[0], - (NPStream*)m_aArgs[1] ) - : 0); - break; - case eNPP_GetValue: - TRACE( "eNPP_GetValue" ); - nRet = (m_aNPPfuncs.getvalue - ? (*m_aNPPfuncs.getvalue)( - (NPP)m_aArgs[0], - (NPPVariable)(int)m_aArgs[1], - m_aArgs[2] ) - : NPERR_GENERIC_ERROR); - break; - case eNPP_SetValue: - TRACE( "eNPP_SetValue" ); - nRet = (m_aNPPfuncs.setvalue - ? (*m_aNPPfuncs.setvalue)( - (NPP)m_aArgs[0], - (NPNVariable)(int)m_aArgs[1], - m_aArgs[2] ) - : NPERR_GENERIC_ERROR); - break; - case eNPP_Shutdown: - { - TRACE( "eNPP_Shutdown" ); - NPP_ShutdownUPP pFunc; - if (retrieveFunction( "NPP_Shutdown", (void**)&pFunc )) - (*pFunc)(); - } - break; - case eNPP_Initialize: - TRACE( "eNPP_Initialize" ); - OSL_FAIL( "NPP_Initialize: not implemented!" ); - break; - case eNPP_GetJavaClass: - TRACE( "eNPP_GetJavaClass" ); - OSL_FAIL( "NPP_GetJavaClass: not implemented!" ); - break; - } - return nRet; -} - -//-------------------------------------------------------------------------------------------------- -NPError MacPluginComm::NPP_Destroy( XPlugin_Impl* i_pImpl, NPSavedData** save ) -{ - // remove from NullEvent timer - m_aNullEventClients.remove( i_pImpl ); - - NPError nErr = NPP_Destroy( i_pImpl->getNPPInstance(), save ); - - // release plugin view - SysPlugData& rPlugData( i_pImpl->getSysPlugData() ); - if( rPlugData.m_pPlugView ) - { - [rPlugData.m_pPlugView removeFromSuperview]; - [rPlugData.m_pPlugView release]; - rPlugData.m_pPlugView = nil; - } - - return nErr; -} - - -NPError MacPluginComm::NPP_Destroy( NPP instance, NPSavedData** save ) -{ - DBG_ASSERT( m_aNPPfuncs.destroy, "### NPP_Destroy(): null pointer in NPP functions table!" ); - m_eCall = eNPP_Destroy; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)save; - return (NPError)execute(); -} - -//-------------------------------------------------------------------------------------------------- -NPError MacPluginComm::NPP_DestroyStream( NPP instance, NPStream* stream, NPError reason ) -{ - DBG_ASSERT( m_aNPPfuncs.destroystream, "### NPP_DestroyStream(): null pointer in NPP functions table!" ); - m_eCall = eNPP_DestroyStream; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)stream; - m_aArgs[2] = (void*)reason; - return (NPError)execute(); -} - -//-------------------------------------------------------------------------------------------------- -NPError MacPluginComm::NPP_New( NPMIMEType pluginType, NPP instance, uint16_t mode, int16_t argc, - char* argn[], char* argv[], NPSavedData *saved ) -{ - XPlugin_Impl* pImpl = XPluginManager_Impl::getXPluginFromNPP( instance ); - DBG_ASSERT( pImpl, "no instance found" ); - - if( pImpl ) // sanity check - m_aNullEventClients.push_back( pImpl ); - - DBG_ASSERT( m_aNPPfuncs.newp, "### NPP_New(): null pointer in NPP functions table!" ); - #if OSL_DEBUG_LEVEL > 1 - fprintf( stderr, "NPP_New( %s. %p, %d, %d", - pluginType, instance, (int)mode, (int)argc ); - for( int16_t i = 0; i < argc; i++ ) - fprintf( stderr, "\n%s = %s", argn[i], argv[i] ); - fprintf( stderr, ", %p )\n", saved ); - #endif - m_eCall = eNPP_New; - m_aArgs[0] = (void*)pluginType; - m_aArgs[1] = (void*)instance; - m_aArgs[2] = (void*)mode; - m_aArgs[3] = (void*)argc; - m_aArgs[4] = (void*)argn; - m_aArgs[5] = (void*)argv; - m_aArgs[6] = (void*)saved; - - return (NPError)execute(); -} - -//-------------------------------------------------------------------------------------------------- -NPError MacPluginComm::NPP_NewStream( NPP instance, NPMIMEType type, NPStream* stream, - NPBool seekable, uint16_t* stype ) -{ - DBG_ASSERT( m_aNPPfuncs.newstream, "### NPP_NewStream(): null pointer in NPP functions table!" ); - m_eCall = eNPP_NewStream; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)type; - m_aArgs[2] = (void*)stream; - m_aArgs[3] = (void*)seekable; - m_aArgs[4] = (void*)stype; - return (NPError)execute(); -} - -//-------------------------------------------------------------------------------------------------- -void MacPluginComm::NPP_Print( NPP instance, NPPrint* platformPrint ) -{ - DBG_ASSERT( m_aNPPfuncs.print, "### NPP_Print(): null pointer in NPP functions table!" ); - m_eCall = eNPP_Print; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)platformPrint; - execute(); -} - -//-------------------------------------------------------------------------------------------------- -NPError MacPluginComm::NPP_SetWindow( NPP instance, NPWindow* window ) -{ - DBG_ASSERT( m_aNPPfuncs.setwindow, "### NPP_SetWindow(): null pointer in NPP functions table!" ); - m_eCall = eNPP_SetWindow; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)window; - return (NPError)execute(); -} - -//-------------------------------------------------------------------------------------------------- -NPError MacPluginComm::NPP_HandleEvent( NPP instance, void* event ) -{ - DBG_ASSERT( m_aNPPfuncs.event, "### NPP_HandleEvent(): null pointer in NPP functions table!" ); - m_eCall = eNPP_HandleEvent; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = event; - return (NPError)execute(); -} - -//-------------------------------------------------------------------------------------------------- -void MacPluginComm::NPP_StreamAsFile( NPP instance, NPStream* stream, const char* fname ) -{ - DBG_ASSERT( m_aNPPfuncs.asfile, "### NPP_StreamAsFile(): null pointer in NPP functions table!" ); - m_eCall = eNPP_StreamAsFile; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)stream; - m_aArgs[2] = (void*)fname; - execute(); -} - -//-------------------------------------------------------------------------------------------------- -void MacPluginComm::NPP_URLNotify( NPP instance, const char* url, NPReason reason, void* notifyData ) -{ - DBG_ASSERT( m_aNPPfuncs.urlnotify, "### NPP_URLNotify(): null pointer in NPP functions table!" ); - m_eCall = eNPP_URLNotify; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)url; - m_aArgs[2] = (void*)reason; - m_aArgs[3] = notifyData; - execute(); -} - -//-------------------------------------------------------------------------------------------------- -int32_t MacPluginComm::NPP_Write( NPP instance, NPStream* stream, int32_t offset, int32_t len, void* buffer ) -{ - DBG_ASSERT( m_aNPPfuncs.write, "### NPP_Write(): null pointer in NPP functions table!" ); - m_eCall = eNPP_Write; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)stream; - m_aArgs[2] = (void*)offset; - m_aArgs[3] = (void*)len; - m_aArgs[4] = buffer; - return (NPError)execute(); -} - -//-------------------------------------------------------------------------------------------------- -int32_t MacPluginComm::NPP_WriteReady( NPP instance, NPStream* stream ) -{ - DBG_ASSERT( m_aNPPfuncs.writeready, "### NPP_WriteReady(): null pointer in NPP functions table!" ); - m_eCall = eNPP_WriteReady; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)stream; - return execute(); -} - -//-------------------------------------------------------------------------------------------------- -NPError MacPluginComm::NPP_GetValue( NPP instance, NPPVariable variable, void *ret_value ) -{ - DBG_ASSERT( m_aNPPfuncs.getvalue, "### NPP_GetValue(): null pointer in NPP functions table!" ); - m_eCall = eNPP_GetValue; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)variable; - m_aArgs[2] = ret_value; - return (NPError)execute(); -} - -//-------------------------------------------------------------------------------------------------- -NPError MacPluginComm::NPP_SetValue( NPP instance, NPNVariable variable, void *set_value ) -{ - DBG_ASSERT( m_aNPPfuncs.setvalue, "### NPP_SetValue(): null pointer in NPP functions table!" ); - m_eCall = eNPP_SetValue; - m_aArgs[0] = (void*)instance; - m_aArgs[1] = (void*)variable; - m_aArgs[2] = set_value; - return (NPError)execute(); -} - -//-------------------------------------------------------------------------------------------------- -void * MacPluginComm::NPP_GetJavaClass() -{ - OSL_FAIL( "no java class available!" ); - return 0; -} - -//-------------------------------------------------------------------------------------------------- -NPError MacPluginComm::NPP_Initialize() -{ - return NPERR_NO_ERROR; -} - -//-------------------------------------------------------------------------------------------------- -void MacPluginComm::NPP_Shutdown() -{ - m_eCall = eNPP_Shutdown; - execute(); -} - -//-------------------------------------------------------------------------------------------------- -NPError MacPluginComm::NPP_SetWindow( XPlugin_Impl* i_pImpl ) -{ - // update window NPWindow from view - SysPlugData& rPlugData( i_pImpl->getSysPlugData() ); - - // update plug view - NSRect aPlugRect = [rPlugData.m_pParentView frame]; - aPlugRect.origin.x = aPlugRect.origin.y = 0; - if( ! rPlugData.m_pPlugView ) - { - rPlugData.m_pPlugView = [[OOoPluginView alloc] initWithInstance: i_pImpl pluginComm: this frame: aPlugRect]; - [rPlugData.m_pParentView addSubview: rPlugData.m_pPlugView]; - } - else - [rPlugData.m_pPlugView setFrame: aPlugRect]; - - NPWindow* pNPWin = i_pImpl->getNPWindow(); - NSWindow* pWin = [rPlugData.m_pPlugView window]; - NSRect aWinRect = [pWin frame]; - NSRect aBounds = [rPlugData.m_pPlugView frame]; - NSRect aVisibleBounds = [rPlugData.m_pPlugView visibleRect]; - - #if OSL_DEBUG_LEVEL > 1 - fprintf( stderr, "visible bounds = %d+%d+%dx%d\n", - (int)aVisibleBounds.origin.x, (int)aVisibleBounds.origin.y, - (int)aVisibleBounds.size.width, (int)aVisibleBounds.size.height ); - #endif - - NSPoint aViewOrigin = [rPlugData.m_pPlugView convertPoint: NSZeroPoint toView: nil]; - // save view origin so we can notice movement of the view in drawView - // in case of a moved view we need to reset the port/context - rPlugData.m_aLastPlugViewOrigin = aViewOrigin; - - // convert view origin to topdown coordinates - aViewOrigin.y = aWinRect.size.height - aViewOrigin.y; - - // same for clipping - NSPoint aClipOrigin = [rPlugData.m_pPlugView convertPoint: aVisibleBounds.origin toView: nil]; - aClipOrigin.y = aWinRect.size.height - aClipOrigin.y; - - #if OSL_DEBUG_LEVEL > 1 - fprintf( stderr, "view origin: %d+%d, clip origin = %d+%d\n", - (int)aViewOrigin.x, (int)aViewOrigin.y, - (int)aClipOrigin.x, (int)aClipOrigin.y ); - #endif - - pNPWin->x = aViewOrigin.x; - pNPWin->y = aViewOrigin.y; - pNPWin->width = aBounds.size.width; - pNPWin->height = aBounds.size.height; - pNPWin->clipRect.left = aClipOrigin.x; - pNPWin->clipRect.top = aClipOrigin.y; - pNPWin->clipRect.right = aClipOrigin.x + aVisibleBounds.size.width; - pNPWin->clipRect.bottom = aClipOrigin.y + aVisibleBounds.size.height; - - if( rPlugData.m_nDrawingModel == 1 ) - { - rPlugData.m_aCGContext.window = reinterpret_cast([pWin windowRef]); - pNPWin->window = &rPlugData.m_aCGContext; - rPlugData.m_aCGContext.context = reinterpret_cast([[pWin graphicsContext] graphicsPort]); - #if OSL_DEBUG_LEVEL > 1 - fprintf( stderr, "window is %p, context is %p\n", - rPlugData.m_aCGContext.window, rPlugData.m_aCGContext.context ); - #endif - } - else - { - rPlugData.m_aNPPort.port = GetWindowPort( reinterpret_cast([pWin windowRef]) ); - rPlugData.m_aNPPort.portx = aClipOrigin.x; - rPlugData.m_aNPPort.porty = aClipOrigin.y; - pNPWin->window = &rPlugData.m_aNPPort; - #if OSL_DEBUG_LEVEL > 1 - fprintf( stderr, "port is %p at (%d,%d)\n", - rPlugData.m_aNPPort.port, (int)rPlugData.m_aNPPort.portx, (int)rPlugData.m_aNPPort.porty ); - #endif - } - - if( pNPWin->width == 0 || pNPWin->height == 0 || [rPlugData.m_pPlugView isHiddenOrHasHiddenAncestor] ) - rPlugData.m_bSetWindowOnDraw = true; - - NPError nErr = NPP_SetWindow( i_pImpl->getNPPInstance(), i_pImpl->getNPWindow() ); - - return nErr; -} - -void MacPluginComm::drawView( XPlugin_Impl* i_pImpl ) -{ - SysPlugData& rPlugData( i_pImpl->getSysPlugData() ); - - // check if the view was moved since the last SetWindow - NSPoint aViewOrigin = [rPlugData.m_pPlugView convertPoint: NSZeroPoint toView: nil]; - if( rPlugData.m_bSetWindowOnDraw || - aViewOrigin.x != rPlugData.m_aLastPlugViewOrigin.x || - aViewOrigin.y != rPlugData.m_aLastPlugViewOrigin.y ) - { - NPP_SetWindow( i_pImpl ); - rPlugData.m_bSetWindowOnDraw = false; - } - - // send a paint event - NSWindow* pWin = [rPlugData.m_pPlugView window]; - FakeEventRecord aRec; - aRec.what = updateEvt; - aRec.message = (uint32_t)[pWin windowRef]; - this->NPP_HandleEvent( i_pImpl->getNPPInstance(), &aRec ); -} - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/plugin/aqua/sysplug.mm b/extensions/source/plugin/aqua/sysplug.mm new file mode 100644 index 000000000000..415ca936c46f --- /dev/null +++ b/extensions/source/plugin/aqua/sysplug.mm @@ -0,0 +1,812 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#include + +#include +#include +#include +#include + +#include + +extern NPNetscapeFuncs aNPNFuncs; + +#include + +using namespace plugstringhelper; + +using ::rtl::OUString; +using ::rtl::OUStringToOString; + +#if OSL_DEBUG_LEVEL > 1 +void TRACE( char const * s ); +void TRACEN( char const * s, long n ); +#else +#define TRACE(x) +#define TRACEN(x,n) +#endif + +struct FakeEventRecord : public EventRecord +{ + FakeEventRecord() + { + memset( this, 0, sizeof(EventRecord) ); + ::GetGlobalMouse( &where ); + when = ::TickCount(); + modifiers = ::GetCurrentEventKeyModifiers(); + } +}; + + +@interface OOoPluginView : NSView +{ + XPlugin_Impl* m_pImpl; + MacPluginComm* m_pCom; +} +-(id)initWithInstance: (XPlugin_Impl*)i_pImpl pluginComm: (MacPluginComm*)i_pCom frame: (NSRect)i_aRect; +-(void)drawRect: (NSRect)i_aRect; +-(BOOL)isOpaque; +-(BOOL)isFlipped; + +// NSResponder +-(void)mouseMoved: (NSEvent*)i_pEvent; +-(void)mouseDown: (NSEvent*)i_pEvent; +-(void)mouseDragged: (NSEvent*)i_pEvent; +-(void)mouseUp: (NSEvent*)i_pEvent; +-(void)rightMouseDown: (NSEvent*)i_pEvent; +-(void)rightMouseDragged: (NSEvent*)i_pEvent; +-(void)rightMouseUp: (NSEvent*)i_pEvent; +-(void)otherMouseDown: (NSEvent*)i_pEvent; +-(void)otherMouseDragged: (NSEvent*)i_pEvent; +-(void)otherMouseUp: (NSEvent*)i_pEvent; +-(void)mouseEntered: (NSEvent*)i_pEvent; +-(void)mouseExited: (NSEvent*)i_pEvent; +@end + +@implementation OOoPluginView +-(id)initWithInstance: (XPlugin_Impl*)i_pImpl pluginComm: (MacPluginComm*)i_pCom frame: (NSRect) i_aRect +{ + if( (self = [super initWithFrame: i_aRect]) ) + { + m_pImpl = i_pImpl; + m_pCom = i_pCom; + } + return self; +} + +-(void)drawRect: (NSRect) i_aRect +{ + m_pCom->drawView( m_pImpl ); +} + +-(BOOL)isOpaque +{ + return NO; +} + +-(BOOL)isFlipped +{ + return YES; +} + +// NSResponder +-(void)mouseMoved: (NSEvent*)i_pEvent +{ + FakeEventRecord aRec; + aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)mouseDown: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = mouseDown; + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)mouseDragged: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)mouseUp: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = mouseUp; + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)rightMouseDown: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = mouseDown; + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)rightMouseDragged: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)rightMouseUp: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = mouseUp; + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)otherMouseDown: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = mouseDown; + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)otherMouseDragged: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)otherMouseUp: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = mouseUp; + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)mouseEntered: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +-(void)mouseExited: (NSEvent*)i_pEvent; +{ + FakeEventRecord aRec; + aRec.what = aRec.what = osEvt + 18; // NPEventType_AdjustCursorEvent + m_pCom->NPP_HandleEvent( m_pImpl->getNPPInstance(), &aRec ); +} + +@end + +//-------------------------------------------------------------------------------------------------- +MacPluginComm::MacPluginComm( const rtl::OUString& i_rMimetype, const rtl::OUString& i_rBundle, NSView* i_pParent ) + : PluginComm( OUStringToOString( i_rBundle, RTL_TEXTENCODING_UTF8 ) ), + m_xBundle( NULL ), + m_hPlugLib( NULL ), + m_pNullTimer( NULL ) +{ + // initialize plugin function table + memset( &m_aNPPfuncs, 0, sizeof( m_aNPPfuncs ) ); + + // load the bundle + CFURLRef xURL = createURL( i_rBundle ); + m_xBundle = CFBundleCreate( NULL, xURL ); + CFRelease( xURL ); + if( m_xBundle ) + { + // ask the plugin library + // first get its location + CFURLRef xLibURL = CFBundleCopyExecutableURL( m_xBundle ); + if( xLibURL ) + { + // get the file system path + rtl::OUString aModuleURL( CFURLtoOSLURL( xLibURL ) ); + CFRelease( xLibURL ); + m_hPlugLib = osl_loadModule( aModuleURL.pData, SAL_LOADMODULE_DEFAULT ); + #if OSL_DEBUG_LEVEL > 1 + if( ! m_hPlugLib ) + fprintf( stderr, "module %s could not be loaded\n", OUStringToOString( aModuleURL, RTL_TEXTENCODING_UTF8 ).getStr() ); + #endif + } + #if OSL_DEBUG_LEVEL > 1 + else + fprintf( stderr, "bundle %s has no exectutable URL\n", OUStringToOString( i_rBundle, RTL_TEXTENCODING_UTF8 ).getStr() ); + #endif + } + else + { + #if OSL_DEBUG_LEVEL > 1 + fprintf( stderr, "bundle %s could not be loaded\n", OUStringToOString( i_rBundle, RTL_TEXTENCODING_UTF8 ).getStr() ); + #endif + } + + DBG_ASSERT( m_xBundle && m_hPlugLib, "loading plugin bundle failed!" ); + + + m_aNPPfuncs.size = sizeof( m_aNPPfuncs ); + m_aNPPfuncs.version = 0; + + + m_eCall = eNP_Initialize; + execute(); +} + +//-------------------------------------------------------------------------------------------------- +MacPluginComm::~MacPluginComm() +{ + if( m_hPlugLib ) + { + // NPP_Shutdown(); + NPError (*pShutdown)(); + if( retrieveFunction( "NP_Shutdown", (void**)&pShutdown ) ) + { + NPError nErr = (*pShutdown)(); (void)nErr; + DBG_ASSERT( nErr == NPERR_NO_ERROR, "NP_Shutdown() failed!" ); + } + osl_unloadModule( m_hPlugLib ); + } + if( m_xBundle ) + CFRelease( m_xBundle ); +} + +//-------------------------------------------------------------------------------------------------- +sal_Bool MacPluginComm::retrieveFunction( const char* i_pName, void** o_ppFunc ) const +{ + if( ! m_hPlugLib || ! o_ppFunc ) + return sal_False; + + *o_ppFunc = (void*)osl_getAsciiFunctionSymbol( m_hPlugLib, i_pName ); + + if( ! *o_ppFunc && m_xBundle ) + { + rtl::OUString aName( OUString::createFromAscii( *i_pName == '_' ? i_pName+1 : i_pName ) ); + CFStringRef xName = createString( aName ); + if( xName ) + { + *o_ppFunc = CFBundleGetFunctionPointerForName( m_xBundle, xName ); + CFRelease( xName ); + } + } + + return (*o_ppFunc != NULL); +} + +IMPL_LINK( MacPluginComm, NullTimerHdl, void*, EMPTYARG ) +{ + // note: this is a Timer handler, we are already protected by the SolarMutex + + FakeEventRecord aRec; + aRec.what = nullEvent; + aRec.where.h = aRec.where.v = 20000; + + for( std::list< XPlugin_Impl* >::iterator it = m_aNullEventClients.begin(); + it != m_aNullEventClients.end(); ++it ) + { + SysPlugData& rPlugData( (*it)->getSysPlugData() ); + if( rPlugData.m_pPlugView ) // for safety do not dispatch null events before first NPP_SetWindow + (*m_aNPPfuncs.event)( (*it)->getNPPInstance(), &aRec ); + } + + return 0; +} + +//-------------------------------------------------------------------------------------------------- + +long MacPluginComm::doIt() +{ + long nRet = 0; + switch( m_eCall ) + { + case eNP_Initialize: + { + TRACE( "eNP_Initialize" ); + NPError (*pInit)( NPNetscapeFuncs* ); + if( retrieveFunction( "NP_Initialize", (void**)&pInit ) ) + { + nRet = (*pInit)( &aNPNFuncs ); + + NPError nErr = NPERR_NO_ERROR; + NPError (*pEntry)( NPPluginFuncs* ); + retrieveFunction( "NP_GetEntryPoints", (void**)&pEntry ); + nErr = (*pEntry)( &m_aNPPfuncs ); + + DBG_ASSERT( nErr == NPERR_NO_ERROR, "NP_GetEntryPoints() failed!" ); + } + else + { + nRet = NPERR_GENERIC_ERROR; + } + DBG_ASSERT( nRet == NPERR_NO_ERROR, "### NP_Initialize() failed!" ); + } + break; + case eNPP_Destroy: + if( m_aNullEventClients.empty() ) + delete m_pNullTimer, m_pNullTimer = NULL; + + TRACE( "eNPP_Destroy" ); + nRet = (m_aNPPfuncs.destroy + ? (*m_aNPPfuncs.destroy)( + (NPP)m_aArgs[0], + (NPSavedData**)m_aArgs[1] ) + : NPERR_GENERIC_ERROR); + break; + case eNPP_DestroyStream: + TRACE( "eNPP_DestroyStream" ); + nRet = (m_aNPPfuncs.destroystream + ? (*m_aNPPfuncs.destroystream)( + (NPP)m_aArgs[0], + (NPStream*)m_aArgs[1], + (NPError)(sal_IntPtr)m_aArgs[2] ) + : NPERR_GENERIC_ERROR); + break; + case eNPP_New: + TRACE( "eNPP_New" ); + nRet = (m_aNPPfuncs.newp + ? (*m_aNPPfuncs.newp)( + (NPMIMEType)m_aArgs[0], + (NPP)m_aArgs[1], + (uint16_t)(sal_IntPtr)m_aArgs[2], + (int16_t)(sal_IntPtr)m_aArgs[3], + (char**)m_aArgs[4], + (char**)m_aArgs[5], + (NPSavedData*)m_aArgs[6] ) + : NPERR_GENERIC_ERROR); + + if( ! m_pNullTimer && m_aNPPfuncs.event ) + { + m_pNullTimer = new AutoTimer(); + m_pNullTimer->SetTimeout( 50 ); + m_pNullTimer->SetTimeoutHdl( LINK( this, MacPluginComm, NullTimerHdl ) ); + m_pNullTimer->Start(); + } + + break; + case eNPP_NewStream: + TRACE( "eNPP_NewStream" ); + nRet = (m_aNPPfuncs.newstream + ? (*m_aNPPfuncs.newstream)( + (NPP)m_aArgs[0], + (NPMIMEType)m_aArgs[1], + (NPStream*)m_aArgs[2], + (NPBool)(sal_IntPtr)m_aArgs[3], + (uint16_t*)m_aArgs[4] ) + : NPERR_GENERIC_ERROR); + break; + case eNPP_Print: + TRACE( "eNPP_Print" ); + if (m_aNPPfuncs.print) + (*m_aNPPfuncs.print)( + (NPP)m_aArgs[0], + (NPPrint*)m_aArgs[1] ); + break; + case eNPP_SetWindow: + { + TRACE( "eNPP_SetWindow" ); + nRet = (m_aNPPfuncs.setwindow + ? (*m_aNPPfuncs.setwindow)( + (NPP)m_aArgs[0], + (NPWindow*)m_aArgs[1] ) + : NPERR_GENERIC_ERROR); + + break; + } + case eNPP_HandleEvent: + { + TRACE( "eNPP_HandleEvent" ); + nRet = (m_aNPPfuncs.event + ? (*m_aNPPfuncs.event)( + (NPP)m_aArgs[0], + m_aArgs[1] ) + : NPERR_GENERIC_ERROR); + + break; + } + case eNPP_StreamAsFile: + TRACE( "eNPP_StreamAsFile" ); + if (m_aNPPfuncs.asfile) + (*m_aNPPfuncs.asfile)( + (NPP)m_aArgs[0], + (NPStream*)m_aArgs[1], + (char*)m_aArgs[2] ); + break; + case eNPP_URLNotify: + TRACE( "eNPP_URLNotify" ); + if (m_aNPPfuncs.urlnotify) + (*m_aNPPfuncs.urlnotify)( + (NPP)m_aArgs[0], + (char*)m_aArgs[1], + (NPReason)(sal_IntPtr)m_aArgs[2], + m_aArgs[3] ); + break; + case eNPP_Write: + TRACEN( "eNPP_Write n=", (int32_t)m_aArgs[3] ); + nRet = (m_aNPPfuncs.write + ? (*m_aNPPfuncs.write)( + (NPP)m_aArgs[0], + (NPStream*)m_aArgs[1], + (int32_t)m_aArgs[2], + (int32_t)m_aArgs[3], + m_aArgs[4] ) + : 0); + break; + case eNPP_WriteReady: + TRACE( "eNPP_WriteReady" ); + nRet = (m_aNPPfuncs.writeready + ? (*m_aNPPfuncs.writeready)( + (NPP)m_aArgs[0], + (NPStream*)m_aArgs[1] ) + : 0); + break; + case eNPP_GetValue: + TRACE( "eNPP_GetValue" ); + nRet = (m_aNPPfuncs.getvalue + ? (*m_aNPPfuncs.getvalue)( + (NPP)m_aArgs[0], + (NPPVariable)(int)m_aArgs[1], + m_aArgs[2] ) + : NPERR_GENERIC_ERROR); + break; + case eNPP_SetValue: + TRACE( "eNPP_SetValue" ); + nRet = (m_aNPPfuncs.setvalue + ? (*m_aNPPfuncs.setvalue)( + (NPP)m_aArgs[0], + (NPNVariable)(int)m_aArgs[1], + m_aArgs[2] ) + : NPERR_GENERIC_ERROR); + break; + case eNPP_Shutdown: + { + TRACE( "eNPP_Shutdown" ); + NPP_ShutdownUPP pFunc; + if (retrieveFunction( "NPP_Shutdown", (void**)&pFunc )) + (*pFunc)(); + } + break; + case eNPP_Initialize: + TRACE( "eNPP_Initialize" ); + OSL_FAIL( "NPP_Initialize: not implemented!" ); + break; + case eNPP_GetJavaClass: + TRACE( "eNPP_GetJavaClass" ); + OSL_FAIL( "NPP_GetJavaClass: not implemented!" ); + break; + } + return nRet; +} + +//-------------------------------------------------------------------------------------------------- +NPError MacPluginComm::NPP_Destroy( XPlugin_Impl* i_pImpl, NPSavedData** save ) +{ + // remove from NullEvent timer + m_aNullEventClients.remove( i_pImpl ); + + NPError nErr = NPP_Destroy( i_pImpl->getNPPInstance(), save ); + + // release plugin view + SysPlugData& rPlugData( i_pImpl->getSysPlugData() ); + if( rPlugData.m_pPlugView ) + { + [rPlugData.m_pPlugView removeFromSuperview]; + [rPlugData.m_pPlugView release]; + rPlugData.m_pPlugView = nil; + } + + return nErr; +} + + +NPError MacPluginComm::NPP_Destroy( NPP instance, NPSavedData** save ) +{ + DBG_ASSERT( m_aNPPfuncs.destroy, "### NPP_Destroy(): null pointer in NPP functions table!" ); + m_eCall = eNPP_Destroy; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)save; + return (NPError)execute(); +} + +//-------------------------------------------------------------------------------------------------- +NPError MacPluginComm::NPP_DestroyStream( NPP instance, NPStream* stream, NPError reason ) +{ + DBG_ASSERT( m_aNPPfuncs.destroystream, "### NPP_DestroyStream(): null pointer in NPP functions table!" ); + m_eCall = eNPP_DestroyStream; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)stream; + m_aArgs[2] = (void*)reason; + return (NPError)execute(); +} + +//-------------------------------------------------------------------------------------------------- +NPError MacPluginComm::NPP_New( NPMIMEType pluginType, NPP instance, uint16_t mode, int16_t argc, + char* argn[], char* argv[], NPSavedData *saved ) +{ + XPlugin_Impl* pImpl = XPluginManager_Impl::getXPluginFromNPP( instance ); + DBG_ASSERT( pImpl, "no instance found" ); + + if( pImpl ) // sanity check + m_aNullEventClients.push_back( pImpl ); + + DBG_ASSERT( m_aNPPfuncs.newp, "### NPP_New(): null pointer in NPP functions table!" ); + #if OSL_DEBUG_LEVEL > 1 + fprintf( stderr, "NPP_New( %s. %p, %d, %d", + pluginType, instance, (int)mode, (int)argc ); + for( int16_t i = 0; i < argc; i++ ) + fprintf( stderr, "\n%s = %s", argn[i], argv[i] ); + fprintf( stderr, ", %p )\n", saved ); + #endif + m_eCall = eNPP_New; + m_aArgs[0] = (void*)pluginType; + m_aArgs[1] = (void*)instance; + m_aArgs[2] = (void*)mode; + m_aArgs[3] = (void*)argc; + m_aArgs[4] = (void*)argn; + m_aArgs[5] = (void*)argv; + m_aArgs[6] = (void*)saved; + + return (NPError)execute(); +} + +//-------------------------------------------------------------------------------------------------- +NPError MacPluginComm::NPP_NewStream( NPP instance, NPMIMEType type, NPStream* stream, + NPBool seekable, uint16_t* stype ) +{ + DBG_ASSERT( m_aNPPfuncs.newstream, "### NPP_NewStream(): null pointer in NPP functions table!" ); + m_eCall = eNPP_NewStream; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)type; + m_aArgs[2] = (void*)stream; + m_aArgs[3] = (void*)seekable; + m_aArgs[4] = (void*)stype; + return (NPError)execute(); +} + +//-------------------------------------------------------------------------------------------------- +void MacPluginComm::NPP_Print( NPP instance, NPPrint* platformPrint ) +{ + DBG_ASSERT( m_aNPPfuncs.print, "### NPP_Print(): null pointer in NPP functions table!" ); + m_eCall = eNPP_Print; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)platformPrint; + execute(); +} + +//-------------------------------------------------------------------------------------------------- +NPError MacPluginComm::NPP_SetWindow( NPP instance, NPWindow* window ) +{ + DBG_ASSERT( m_aNPPfuncs.setwindow, "### NPP_SetWindow(): null pointer in NPP functions table!" ); + m_eCall = eNPP_SetWindow; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)window; + return (NPError)execute(); +} + +//-------------------------------------------------------------------------------------------------- +NPError MacPluginComm::NPP_HandleEvent( NPP instance, void* event ) +{ + DBG_ASSERT( m_aNPPfuncs.event, "### NPP_HandleEvent(): null pointer in NPP functions table!" ); + m_eCall = eNPP_HandleEvent; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = event; + return (NPError)execute(); +} + +//-------------------------------------------------------------------------------------------------- +void MacPluginComm::NPP_StreamAsFile( NPP instance, NPStream* stream, const char* fname ) +{ + DBG_ASSERT( m_aNPPfuncs.asfile, "### NPP_StreamAsFile(): null pointer in NPP functions table!" ); + m_eCall = eNPP_StreamAsFile; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)stream; + m_aArgs[2] = (void*)fname; + execute(); +} + +//-------------------------------------------------------------------------------------------------- +void MacPluginComm::NPP_URLNotify( NPP instance, const char* url, NPReason reason, void* notifyData ) +{ + DBG_ASSERT( m_aNPPfuncs.urlnotify, "### NPP_URLNotify(): null pointer in NPP functions table!" ); + m_eCall = eNPP_URLNotify; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)url; + m_aArgs[2] = (void*)reason; + m_aArgs[3] = notifyData; + execute(); +} + +//-------------------------------------------------------------------------------------------------- +int32_t MacPluginComm::NPP_Write( NPP instance, NPStream* stream, int32_t offset, int32_t len, void* buffer ) +{ + DBG_ASSERT( m_aNPPfuncs.write, "### NPP_Write(): null pointer in NPP functions table!" ); + m_eCall = eNPP_Write; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)stream; + m_aArgs[2] = (void*)offset; + m_aArgs[3] = (void*)len; + m_aArgs[4] = buffer; + return (NPError)execute(); +} + +//-------------------------------------------------------------------------------------------------- +int32_t MacPluginComm::NPP_WriteReady( NPP instance, NPStream* stream ) +{ + DBG_ASSERT( m_aNPPfuncs.writeready, "### NPP_WriteReady(): null pointer in NPP functions table!" ); + m_eCall = eNPP_WriteReady; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)stream; + return execute(); +} + +//-------------------------------------------------------------------------------------------------- +NPError MacPluginComm::NPP_GetValue( NPP instance, NPPVariable variable, void *ret_value ) +{ + DBG_ASSERT( m_aNPPfuncs.getvalue, "### NPP_GetValue(): null pointer in NPP functions table!" ); + m_eCall = eNPP_GetValue; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)variable; + m_aArgs[2] = ret_value; + return (NPError)execute(); +} + +//-------------------------------------------------------------------------------------------------- +NPError MacPluginComm::NPP_SetValue( NPP instance, NPNVariable variable, void *set_value ) +{ + DBG_ASSERT( m_aNPPfuncs.setvalue, "### NPP_SetValue(): null pointer in NPP functions table!" ); + m_eCall = eNPP_SetValue; + m_aArgs[0] = (void*)instance; + m_aArgs[1] = (void*)variable; + m_aArgs[2] = set_value; + return (NPError)execute(); +} + +//-------------------------------------------------------------------------------------------------- +void * MacPluginComm::NPP_GetJavaClass() +{ + OSL_FAIL( "no java class available!" ); + return 0; +} + +//-------------------------------------------------------------------------------------------------- +NPError MacPluginComm::NPP_Initialize() +{ + return NPERR_NO_ERROR; +} + +//-------------------------------------------------------------------------------------------------- +void MacPluginComm::NPP_Shutdown() +{ + m_eCall = eNPP_Shutdown; + execute(); +} + +//-------------------------------------------------------------------------------------------------- +NPError MacPluginComm::NPP_SetWindow( XPlugin_Impl* i_pImpl ) +{ + // update window NPWindow from view + SysPlugData& rPlugData( i_pImpl->getSysPlugData() ); + + // update plug view + NSRect aPlugRect = [rPlugData.m_pParentView frame]; + aPlugRect.origin.x = aPlugRect.origin.y = 0; + if( ! rPlugData.m_pPlugView ) + { + rPlugData.m_pPlugView = [[OOoPluginView alloc] initWithInstance: i_pImpl pluginComm: this frame: aPlugRect]; + [rPlugData.m_pParentView addSubview: rPlugData.m_pPlugView]; + } + else + [rPlugData.m_pPlugView setFrame: aPlugRect]; + + NPWindow* pNPWin = i_pImpl->getNPWindow(); + NSWindow* pWin = [rPlugData.m_pPlugView window]; + NSRect aWinRect = [pWin frame]; + NSRect aBounds = [rPlugData.m_pPlugView frame]; + NSRect aVisibleBounds = [rPlugData.m_pPlugView visibleRect]; + + #if OSL_DEBUG_LEVEL > 1 + fprintf( stderr, "visible bounds = %d+%d+%dx%d\n", + (int)aVisibleBounds.origin.x, (int)aVisibleBounds.origin.y, + (int)aVisibleBounds.size.width, (int)aVisibleBounds.size.height ); + #endif + + NSPoint aViewOrigin = [rPlugData.m_pPlugView convertPoint: NSZeroPoint toView: nil]; + // save view origin so we can notice movement of the view in drawView + // in case of a moved view we need to reset the port/context + rPlugData.m_aLastPlugViewOrigin = aViewOrigin; + + // convert view origin to topdown coordinates + aViewOrigin.y = aWinRect.size.height - aViewOrigin.y; + + // same for clipping + NSPoint aClipOrigin = [rPlugData.m_pPlugView convertPoint: aVisibleBounds.origin toView: nil]; + aClipOrigin.y = aWinRect.size.height - aClipOrigin.y; + + #if OSL_DEBUG_LEVEL > 1 + fprintf( stderr, "view origin: %d+%d, clip origin = %d+%d\n", + (int)aViewOrigin.x, (int)aViewOrigin.y, + (int)aClipOrigin.x, (int)aClipOrigin.y ); + #endif + + pNPWin->x = aViewOrigin.x; + pNPWin->y = aViewOrigin.y; + pNPWin->width = aBounds.size.width; + pNPWin->height = aBounds.size.height; + pNPWin->clipRect.left = aClipOrigin.x; + pNPWin->clipRect.top = aClipOrigin.y; + pNPWin->clipRect.right = aClipOrigin.x + aVisibleBounds.size.width; + pNPWin->clipRect.bottom = aClipOrigin.y + aVisibleBounds.size.height; + + if( rPlugData.m_nDrawingModel == 1 ) + { + rPlugData.m_aCGContext.window = reinterpret_cast([pWin windowRef]); + pNPWin->window = &rPlugData.m_aCGContext; + rPlugData.m_aCGContext.context = reinterpret_cast([[pWin graphicsContext] graphicsPort]); + #if OSL_DEBUG_LEVEL > 1 + fprintf( stderr, "window is %p, context is %p\n", + rPlugData.m_aCGContext.window, rPlugData.m_aCGContext.context ); + #endif + } + else + { + rPlugData.m_aNPPort.port = GetWindowPort( reinterpret_cast([pWin windowRef]) ); + rPlugData.m_aNPPort.portx = aClipOrigin.x; + rPlugData.m_aNPPort.porty = aClipOrigin.y; + pNPWin->window = &rPlugData.m_aNPPort; + #if OSL_DEBUG_LEVEL > 1 + fprintf( stderr, "port is %p at (%d,%d)\n", + rPlugData.m_aNPPort.port, (int)rPlugData.m_aNPPort.portx, (int)rPlugData.m_aNPPort.porty ); + #endif + } + + if( pNPWin->width == 0 || pNPWin->height == 0 || [rPlugData.m_pPlugView isHiddenOrHasHiddenAncestor] ) + rPlugData.m_bSetWindowOnDraw = true; + + NPError nErr = NPP_SetWindow( i_pImpl->getNPPInstance(), i_pImpl->getNPWindow() ); + + return nErr; +} + +void MacPluginComm::drawView( XPlugin_Impl* i_pImpl ) +{ + SysPlugData& rPlugData( i_pImpl->getSysPlugData() ); + + // check if the view was moved since the last SetWindow + NSPoint aViewOrigin = [rPlugData.m_pPlugView convertPoint: NSZeroPoint toView: nil]; + if( rPlugData.m_bSetWindowOnDraw || + aViewOrigin.x != rPlugData.m_aLastPlugViewOrigin.x || + aViewOrigin.y != rPlugData.m_aLastPlugViewOrigin.y ) + { + NPP_SetWindow( i_pImpl ); + rPlugData.m_bSetWindowOnDraw = false; + } + + // send a paint event + NSWindow* pWin = [rPlugData.m_pPlugView window]; + FakeEventRecord aRec; + aRec.what = updateEvt; + aRec.message = (uint32_t)[pWin windowRef]; + this->NPP_HandleEvent( i_pImpl->getNPPInstance(), &aRec ); +} + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ -- cgit From bee2690663cff923d1aa67b2b8e561ee6ca7457c Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 22:29:19 +0100 Subject: extensions: convert spotlight to gbuild --- extensions/Library_OOoSpotlightImporter.mk | 52 ++++++++++++++ extensions/Module_extensions.mk | 6 ++ extensions/Zip_mdibundle.mk | 40 +++++++++++ extensions/prj/build.lst | 1 - extensions/source/macosx/spotlight/delzip | 0 extensions/source/macosx/spotlight/makefile.mk | 99 -------------------------- 6 files changed, 98 insertions(+), 100 deletions(-) create mode 100644 extensions/Library_OOoSpotlightImporter.mk create mode 100644 extensions/Zip_mdibundle.mk delete mode 100644 extensions/source/macosx/spotlight/delzip delete mode 100644 extensions/source/macosx/spotlight/makefile.mk diff --git a/extensions/Library_OOoSpotlightImporter.mk b/extensions/Library_OOoSpotlightImporter.mk new file mode 100644 index 000000000000..4a622331e3e6 --- /dev/null +++ b/extensions/Library_OOoSpotlightImporter.mk @@ -0,0 +1,52 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,OOoSpotlightImporter)) + +$(eval $(call gb_Library_add_objcobjects,OOoSpotlightImporter,\ + extensions/source/macosx/spotlight/GetMetadataForFile \ + extensions/source/macosx/spotlight/OOoContentDataParser \ + extensions/source/macosx/spotlight/OOoMetaDataParser \ + extensions/source/macosx/spotlight/OOoSpotlightImporter \ + extensions/source/macosx/spotlight/ioapi \ + extensions/source/macosx/spotlight/main \ + extensions/source/macosx/spotlight/unzip \ +)) + +$(eval $(call gb_Library_add_ldflags,OOoSpotlightImporter,\ + -framework CoreFoundation \ + -framework Foundation \ + -framework CoreServices \ + -bundle \ +)) + +$(eval $(call gb_Library_use_external,OOoSpotlightImporter,zlib)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index dd7c3359fb54..02e4ae4c43e3 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -79,6 +79,12 @@ endif # GUI=UNX endif # WITH_MOZILLA=YES +ifeq ($(OS),MACOSX) +$(eval $(call gb_Module_add_targets,extensions,\ + Library_OOoSpotlightImporter \ + Zip_mdibundle \ +)) +endif # OS=MACOSX $(eval $(call gb_Module_add_check_targets,extensions,\ CppunitTest_extensions_test_update \ diff --git a/extensions/Zip_mdibundle.mk b/extensions/Zip_mdibundle.mk new file mode 100644 index 000000000000..56e9b727c151 --- /dev/null +++ b/extensions/Zip_mdibundle.mk @@ -0,0 +1,40 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +MDISRC := $(SRCDIR)/extensions/source/macosx/spotlight/mdimporter + +$(eval $(call gb_Zip_Zip,mdibundle,$(WORKDIR)/Zip/mdibundle)) + +$(eval $(call gb_Zip_add_file,mdibundle,schema.xml,$(MDISRC)/schema.xml)) +$(eval $(call gb_Zip_add_file,mdibundle,Info.plist,$(MDISRC)/Info.plist)) +$(eval $(call gb_Zip_add_file,mdibundle,en.lproj/schema.strings,$(MDISRC)/en.lproj/schema.strings)) +$(eval $(call gb_Zip_add_file,mdibundle,OOoSpotlightImporter,$(OUTDIR)/bin/OOoSpotlightImporter)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index d47b82a57f1a..7d5e500019eb 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -6,7 +6,6 @@ ex extensions\inc\ucbhelper get - all ex_incucbh ex_in ex extensions\source\activex\msidl nmake - w ex_axmsidl ex_inc NULL ex extensions\source\activex\main nmake - w ex_axmain ex_axmsidl.w ex_inc NULL ex extensions\source\resource nmake - all ex_resrc ex_inc NULL -ex extensions\source\macosx\spotlight nmake - u ex_mxspotlight NULL ex extensions\source\bibliography nmake - all ex_bib ex_inc NULL ex extensions\source\xmlextract nmake - all ex_xmlextr ex_inc NULL ex extensions\source\dbpilots nmake - all ex_dbpilots ex_inc NULL diff --git a/extensions/source/macosx/spotlight/delzip b/extensions/source/macosx/spotlight/delzip deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/extensions/source/macosx/spotlight/makefile.mk b/extensions/source/macosx/spotlight/makefile.mk deleted file mode 100644 index e7b15150bd03..000000000000 --- a/extensions/source/macosx/spotlight/makefile.mk +++ /dev/null @@ -1,99 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=../../.. -PRJNAME=extensions -TARGET=spotlightplugin - -# --- Settings ---------------------------------- -.INCLUDE : settings.mk - -.IF "$(OS)"!="MACOSX" -dummy: - @echo Not using Mac OS X - nothing to build -.ENDIF - -# --- Files ------------------------------------- - -# ... object files ............................ -SLOFILES= \ - $(SLO)$/ioapi.obj \ - $(SLO)$/unzip.obj \ - $(SLO)$/main.obj \ - $(SLO)$/GetMetadataForFile.obj \ - $(SLO)$/OOoContentDataParser.obj \ - $(SLO)$/OOoMetaDataParser.obj \ - $(SLO)$/OOoSpotlightImporter.obj \ - -BUNDLE = $(MISC)$/OOoSpotlightImporter.mdimporter -CONTENTS = $(BUNDLE)$/Contents -RESOURCES = $(CONTENTS)$/Resources -MACOS = $(CONTENTS)$/MacOS - -BUNDLELIBS= -framework CoreFoundation \ - -framework Foundation \ - -framework CoreServices \ - $(ZLIB3RDLIB) - -plistfiles = $(CONTENTS)$/Info.plist -binaries = $(MACOS)$/OOoSpotlightImporter -resources = $(RESOURCES)/en.lproj/schema.strings \ - $(RESOURCES)/schema.xml - -ZIPFLAGS = -r -ZIP1TARGET = mdibundle -ZIP1DIR = $(CONTENTS) -ZIP1LIST = * - - -# --- Targets ---------------------------------- - -.INCLUDE : target.mk - -.IF "$(ZIP1TARGETN)"!="" -$(ZIP1TARGETN) : $(plistfiles) $(binaries) $(resources) - -.ENDIF # "$(ZIP1TARGETN)"!="" - -# Info.plist is just versioned and copied into the bundle -$(CONTENTS)$/%.plist : mdimporter/%.plist - $(MKDIRHIER) $(@:d) - $(COPY) "$<" "$@" - -$(MACOS)$/OOoSpotlightImporter: $(SLOFILES) - $(MKDIRHIER) $(@:d) - $(CC) -o $(MACOS)$/OOoSpotlightImporter $(SLOFILES:s/.obj/.o/) $(EXTRA_LINKFLAGS) $(BUNDLELIBS) -bundle -# we have to change the zlib install name, otherwise the plugin will not work - .IF "$(SYSTEM_ZLIB)"=="NO" - install_name_tool -change @executable_path/libz.1.dylib @executable_path/../../../../MacOS/libz.1.dylib $(MACOS)$/OOoSpotlightImporter - .ENDIF - -#the resources are just copied -$(RESOURCES)$/% : mdimporter/% - $(MKDIRHIER) $(@:d) - $(COPY) "$<" "$@" - -- cgit From 67d72f4c2d9163dcef8b6fc51368fdeed6af201b Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Sat, 17 Dec 2011 23:17:45 +0100 Subject: extensions: tweak spotlight makefiles --- Repository.mk | 8 ++++++++ extensions/Zip_mdibundle.mk | 10 ++++------ 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/Repository.mk b/Repository.mk index e065c511684d..42960c6f46bd 100644 --- a/Repository.mk +++ b/Repository.mk @@ -103,6 +103,14 @@ $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ endif # WITH_MOZILLA +ifeq ($(OS),MACOSX) + +$(eval $(call gb_Helper_register_libraries,NONE, \ + OOoSpotlightImporter \ +)) + +endif + $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ PptImporter \ adabas \ diff --git a/extensions/Zip_mdibundle.mk b/extensions/Zip_mdibundle.mk index 56e9b727c151..b6ebf08ee021 100644 --- a/extensions/Zip_mdibundle.mk +++ b/extensions/Zip_mdibundle.mk @@ -28,13 +28,11 @@ # instead of those above. # -MDISRC := $(SRCDIR)/extensions/source/macosx/spotlight/mdimporter - $(eval $(call gb_Zip_Zip,mdibundle,$(WORKDIR)/Zip/mdibundle)) -$(eval $(call gb_Zip_add_file,mdibundle,schema.xml,$(MDISRC)/schema.xml)) -$(eval $(call gb_Zip_add_file,mdibundle,Info.plist,$(MDISRC)/Info.plist)) -$(eval $(call gb_Zip_add_file,mdibundle,en.lproj/schema.strings,$(MDISRC)/en.lproj/schema.strings)) -$(eval $(call gb_Zip_add_file,mdibundle,OOoSpotlightImporter,$(OUTDIR)/bin/OOoSpotlightImporter)) +$(eval $(call gb_Zip_add_file,mdibundle,schema.xml,$(SRCDIR)/extensions/source/macosx/spotlight/mdimporter/schema.xml)) +$(eval $(call gb_Zip_add_file,mdibundle,Info.plist,$(SRCDIR)/extensions/source/macosx/spotlight/mdimporter/Info.plist)) +$(eval $(call gb_Zip_add_file,mdibundle,en.lproj/schema.strings,$(SRCDIR)/extensions/source/macosx/spotlight/mdimporter/en.lproj/schema.strings)) +$(eval $(call gb_Zip_add_file,mdibundle,MacOS/OOoSpotlightImporter,$(OUTDIR)/lib/libOOoSpotlightImporter.dylib)) # vim:set shiftwidth=4 softtabstop=4 expandtab: -- cgit From 87612dadc166fb078074e50796cc864dc981b483 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 23:33:32 +0100 Subject: extensions: convert ldap to gbuild --- Repository.mk | 6 ++ extensions/Library_ldapbe2.mk | 86 ++++++++++++++++++++++++ extensions/Module_extensions.mk | 6 ++ extensions/prj/build.lst | 3 +- extensions/source/config/ldap/exports.dxp | 1 - extensions/source/config/ldap/makefile.mk | 105 ------------------------------ postprocess/packcomponents/makefile.mk | 2 +- 7 files changed, 100 insertions(+), 109 deletions(-) create mode 100644 extensions/Library_ldapbe2.mk delete mode 100644 extensions/source/config/ldap/exports.dxp delete mode 100644 extensions/source/config/ldap/makefile.mk diff --git a/Repository.mk b/Repository.mk index 42960c6f46bd..221e6ac9ed77 100644 --- a/Repository.mk +++ b/Repository.mk @@ -391,6 +391,12 @@ $(eval $(call gb_Helper_register_libraries,UNOLIBS_OOO, \ )) endif +ifeq ($(WITH_LDAP),YES) +$(eval $(call gb_Helper_register_libraries,UNOLIBS_OOO, \ + ldapbe2 \ +)) +endif + $(eval $(call gb_Helper_register_libraries,UNOLIBS_URE, \ binaryurp \ )) diff --git a/extensions/Library_ldapbe2.mk b/extensions/Library_ldapbe2.mk new file mode 100644 index 000000000000..87cb3ad99286 --- /dev/null +++ b/extensions/Library_ldapbe2.mk @@ -0,0 +1,86 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,ldapbe2)) + +$(eval $(call gb_Library_set_componentfile,ldapbe2,extensions/source/config/ldap/ldapbe2)) + +$(eval $(call gb_Library_add_api,ldapbe2,\ + offapi \ + udkapi \ +)) + +ifeq ($(LDAPSDKINCLUDES),) +ifneq ($(WITH_OPENLDAP),YES) +ifeq ($(SYSTEM_MOZILLA),YES) +$(eval $(call gb_Library_set_include,ldapbe2,\ + $$(INCLUDE) \ + $(MOZ_LDAP_CFLAGS) \ +)) +else # SYSTEM_MOZILLA=NO +$(eval $(call gb_Library_set_include,ldapbe2,\ + $$(INCLUDE) \ + -I$(OUTDIR)/inc/mozilla \ +)) +endif # SYSTEM_MOZILLA=YES +else # WITH_OPENLDAP=YES +$(eval $(call gb_Library_add_defs,ldapbe2,\ + -DWITH_OPENLDAP \ + -DLDAP_DEPRECATED \ +)) +endif # WITH_OPENLDAP=NO +endif # LDAPSDKINCLUDES= + +$(eval $(call gb_Library_add_exception_objects,ldapbe2,\ + extensions/source/config/ldap/componentdef \ + extensions/source/config/ldap/ldapaccess \ + extensions/source/config/ldap/ldapuserprofilebe \ +)) + +$(eval $(call gb_Library_add_linked_libs,ldapbe2,\ + cppuhelper \ + cppu \ + salhelper \ + sal \ +)) + +ifeq ($(OS),FREEBSD) +$(eval $(call gb_Library_add_libs,ldapbe2,\ + -lcompat \ +)) +ifneq ($(WITH_OPENLDAP),YES) +$(eval $(call gb_Library_add_libs,ldapbe2,\ + -Wl,-Bstatic + -llber50 \ +)) +endif # WITH_OPENLDAP=NO +endif # OS=FREEBSD + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index 02e4ae4c43e3..caaa8fb62404 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -86,6 +86,12 @@ $(eval $(call gb_Module_add_targets,extensions,\ )) endif # OS=MACOSX +ifeq ($(WITH_LDAP),YES) +$(eval $(call gb_Module_add_targets,extensions,\ + Library_ldapbe2 \ +)) +endif # WITH_LDAP=YES + $(eval $(call gb_Module_add_check_targets,extensions,\ CppunitTest_extensions_test_update \ )) diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index 7d5e500019eb..eb8585cf7404 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -11,8 +11,7 @@ ex extensions\source\xmlextract nmake - all ex_xmlextr ex_in ex extensions\source\dbpilots nmake - all ex_dbpilots ex_inc NULL ex extensions\source\abpilot nmake - all ex_abpilot ex_inc NULL ex extensions\source\logging nmake - all ex_logging ex_inc NULL -ex extensions\source\config\ldap nmake - all ex_ldap ex_inc NULL -ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging ex_ldap ex_bib NULL +ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging ex_bib NULL ex extensions\prj nmake - all ex_prj NULL # Fails at the moment diff --git a/extensions/source/config/ldap/exports.dxp b/extensions/source/config/ldap/exports.dxp deleted file mode 100644 index 70033078921a..000000000000 --- a/extensions/source/config/ldap/exports.dxp +++ /dev/null @@ -1 +0,0 @@ -component_getFactory diff --git a/extensions/source/config/ldap/makefile.mk b/extensions/source/config/ldap/makefile.mk deleted file mode 100644 index d35e2428ca31..000000000000 --- a/extensions/source/config/ldap/makefile.mk +++ /dev/null @@ -1,105 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=..$/..$/.. - -PRJNAME=extensions -TARGET=ldapbe -ENABLE_EXCEPTIONS=TRUE - -# Version -LDAP_MAJOR=2 - -# --- Settings --- - -.INCLUDE : settings.mk -DLLPRE = - -.IF "$(WITH_LDAP)" != "YES" -@all: - @echo "LDAP disabled." -.ENDIF - -.IF "$(LDAPSDKINCLUDES)" == "" - -.IF "$(SYSTEM_MOZILLA)" == "YES" && "$(WITH_OPENLDAP)" != "YES" -LDAPSDKINCLUDES = $(MOZ_LDAP_CFLAGS) -.ELSE -LDAPSDKINCLUDES = -I$(SOLARINCDIR)$/mozilla -.ENDIF -.ENDIF - -.IF "$(WITH_OPENLDAP)" == "YES" -CFLAGS += -DWITH_OPENLDAP -DLDAP_DEPRECATED -.ENDIF - -SOLARINC+= $(LDAPSDKINCLUDES) -# --- Files --- - - -SLOFILES=\ - $(SLO)$/ldapuserprofilebe.obj \ - $(SLO)$/ldapaccess.obj \ - $(SLO)$/componentdef.obj - -LIB1TARGET=$(SLB)$/_$(TARGET).lib -LIB1OBJFILES=$(SLOFILES) - -SHL1TARGET=$(TARGET)$(LDAP_MAJOR).uno -SHL1DEF=$(MISC)$/$(SHL1TARGET).def -SHL1LIBS=$(LIB1TARGET) -SHL1IMPLIB=i$(SHL1TARGET) -SHL1STDLIBS= \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(SALHELPERLIB) \ - $(SALLIB) -.IF "$(OS)"=="FREEBSD" -SHL1STDLIBS+=-lcompat -# workaround for FreeBSD, which needs -llber50, too -.IF "$(WITH_OPENLDAP)" != "YES" -SHL1STDLIBS+=-Wl,-Bstatic -llber50 -.ENDIF -.ENDIF - -DEF1NAME=$(SHL1TARGET) -DEF1EXPORTFILE=exports.dxp -DEF1DES=Configuration: LDAP User Profile Backend - -# --- Targets --- - -.INCLUDE : target.mk -.INCLUDE : $(PRJ)$/util$/target.pmk - - -ALLTAR : $(MISC)/ldapbe2.component - -$(MISC)/ldapbe2.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - ldapbe2.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt ldapbe2.component diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index c9e7a2df68f6..36bcee6091c1 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -268,7 +268,7 @@ my_components += \ .END .IF "$(WITH_LDAP)" == "YES" -my_components += ldapbe2 +my_components += component/extensions/source/config/ldap/ldapbe2 .END .IF "$(WITH_MOZILLA)" != "NO" -- cgit From ac8733d8bed779b40af1606afe5c753676abc68b Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 23:47:32 +0100 Subject: extensions: convert bibliography to gbuild --- Repository.mk | 1 + extensions/AllLangResTarget_bib.mk | 53 ++++++++++++++++ extensions/Library_bib.mk | 75 +++++++++++++++++++++++ extensions/Module_extensions.mk | 3 + extensions/Package_bib.mk | 35 +++++++++++ extensions/prj/build.lst | 3 +- extensions/source/bibliography/makefile.mk | 98 ------------------------------ postprocess/packcomponents/makefile.mk | 2 +- 8 files changed, 169 insertions(+), 101 deletions(-) create mode 100644 extensions/AllLangResTarget_bib.mk create mode 100644 extensions/Library_bib.mk create mode 100644 extensions/Package_bib.mk delete mode 100644 extensions/source/bibliography/makefile.mk diff --git a/Repository.mk b/Repository.mk index 221e6ac9ed77..c689d3428ed0 100644 --- a/Repository.mk +++ b/Repository.mk @@ -120,6 +120,7 @@ $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ animcore \ basctl \ basebmp \ + bib \ canvastools \ communi \ date \ diff --git a/extensions/AllLangResTarget_bib.mk b/extensions/AllLangResTarget_bib.mk new file mode 100644 index 000000000000..36b22c392b1f --- /dev/null +++ b/extensions/AllLangResTarget_bib.mk @@ -0,0 +1,53 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_AllLangResTarget_AllLangResTarget,bib)) + +$(eval $(call gb_AllLangResTarget_add_srs,bib,bib/res)) + +$(eval $(call gb_SrsTarget_SrsTarget,bib/res)) + +$(eval $(call gb_SrsTarget_set_include,bib/res,\ + $$(INCLUDE) \ + -I$(realpath $(SRCDIR)/extensions/inc) \ +)) + +$(eval $(call gb_SrsTarget_add_files,bib/res,\ + extensions/source/bibliography/bib.src \ + extensions/source/bibliography/datman.src \ + extensions/source/bibliography/sections.src \ + extensions/source/bibliography/toolbar.src \ +)) + +$(eval $(call gb_SrsTarget_add_templates,bib/res,\ + extensions/source/bibliography/bib.hrc \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_bib.mk b/extensions/Library_bib.mk new file mode 100644 index 000000000000..3a9c0107a568 --- /dev/null +++ b/extensions/Library_bib.mk @@ -0,0 +1,75 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,bib)) + +$(eval $(call gb_Library_set_componentfile,bib,extensions/source/bibliography/bib)) + +$(eval $(call gb_Library_set_include,bib,\ + $$(INCLUDE) \ + -I$(realpath $(SRCDIR)/extensions/inc) \ +)) + +$(eval $(call gb_Library_add_api,bib,\ + offapi \ + udkapi \ +)) + +$(eval $(call gb_Library_add_exception_objects,bib,\ + extensions/source/bibliography/bibbeam \ + extensions/source/bibliography/bibconfig \ + extensions/source/bibliography/bibcont \ + extensions/source/bibliography/bibload \ + extensions/source/bibliography/bibmod \ + extensions/source/bibliography/bibview \ + extensions/source/bibliography/datman \ + extensions/source/bibliography/formcontrolcontainer \ + extensions/source/bibliography/framectr \ + extensions/source/bibliography/general \ + extensions/source/bibliography/loadlisteneradapter \ + extensions/source/bibliography/toolbar \ +)) + +$(eval $(call gb_Library_add_linked_libs,bib,\ + dbtools \ + sot \ + svt \ + svl \ + tk \ + vcl \ + utl \ + tl \ + comphelper \ + cppuhelper \ + cppu \ + sal \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index caaa8fb62404..ebf6d26d19ad 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -27,16 +27,19 @@ $(eval $(call gb_Module_Module,extensions)) $(eval $(call gb_Module_add_targets,extensions,\ + AllLangResTarget_bib \ AllLangResTarget_pcr \ AllLangResTarget_san \ AllLangResTarget_upd \ AllLangResTarget_updchk \ Configuration_updchk \ + Library_bib \ Library_pcr \ Library_scn \ Library_updatecheckui \ Library_updatefeed \ Library_updchk \ + Package_bib \ Package_pcr \ )) diff --git a/extensions/Package_bib.mk b/extensions/Package_bib.mk new file mode 100644 index 000000000000..46b9c3c37818 --- /dev/null +++ b/extensions/Package_bib.mk @@ -0,0 +1,35 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Package_Package,bib,$(SRCDIR)/extensions/source/bibliography/uiconfig/sbibliography/menubar)) + +$(eval $(call gb_Package_add_file,bib,xml/uiconfig/modules/sbibliography/menubar/menubar.xml,menubar.xml)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index eb8585cf7404..2a76f92db053 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -6,12 +6,11 @@ ex extensions\inc\ucbhelper get - all ex_incucbh ex_in ex extensions\source\activex\msidl nmake - w ex_axmsidl ex_inc NULL ex extensions\source\activex\main nmake - w ex_axmain ex_axmsidl.w ex_inc NULL ex extensions\source\resource nmake - all ex_resrc ex_inc NULL -ex extensions\source\bibliography nmake - all ex_bib ex_inc NULL ex extensions\source\xmlextract nmake - all ex_xmlextr ex_inc NULL ex extensions\source\dbpilots nmake - all ex_dbpilots ex_inc NULL ex extensions\source\abpilot nmake - all ex_abpilot ex_inc NULL ex extensions\source\logging nmake - all ex_logging ex_inc NULL -ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging ex_bib NULL +ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging NULL ex extensions\prj nmake - all ex_prj NULL # Fails at the moment diff --git a/extensions/source/bibliography/makefile.mk b/extensions/source/bibliography/makefile.mk deleted file mode 100644 index b681c6c90b19..000000000000 --- a/extensions/source/bibliography/makefile.mk +++ /dev/null @@ -1,98 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/.. - -PRJNAME=extensions -TARGET=bib -ENABLE_EXCEPTIONS=TRUE - -# --- Settings ----------------------------------------------------- - -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -# --- Files -------------------------------------------------------- - -SLOFILES= $(SLO)$/formcontrolcontainer.obj \ - $(SLO)$/loadlisteneradapter.obj \ - $(SLO)$/bibconfig.obj \ - $(SLO)$/bibcont.obj \ - $(SLO)$/bibload.obj \ - $(SLO)$/bibmod.obj \ - $(SLO)$/general.obj \ - $(SLO)$/framectr.obj \ - $(SLO)$/bibview.obj \ - $(SLO)$/bibbeam.obj \ - $(SLO)$/toolbar.obj \ - $(SLO)$/datman.obj \ - - -SRS1NAME=$(TARGET) -SRC1FILES= bib.src \ - datman.src \ - sections.src \ - toolbar.src - -RESLIB1NAME=bib -RESLIB1SRSFILES= $(SRS)$/bib.srs -RESLIB1DEPN= bib.src bib.hrc - - -SHL1STDLIBS= \ - $(SOTLIB) \ - $(SVTOOLLIB) \ - $(TKLIB) \ - $(VCLLIB) \ - $(SVLLIB) \ - $(UNOTOOLSLIB) \ - $(TOOLSLIB) \ - $(DBTOOLSLIB) \ - $(COMPHELPERLIB) \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(SALLIB) - - -SHL1TARGET= $(TARGET)$(DLLPOSTFIX) -SHL1LIBS= $(SLB)$/$(TARGET).lib -SHL1IMPLIB= i$(TARGET) -SHL1DEPN= $(SHL1LIBS) -SHL1DEF= $(MISC)$/$(SHL1TARGET).def -SHL1VERSIONMAP=$(SOLARENV)/src/component.map -DEF1NAME= $(SHL1TARGET) - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk - - -ALLTAR : $(MISC)/bib.component - -$(MISC)/bib.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - bib.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt bib.component diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index 36bcee6091c1..1a52db095ccd 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -166,13 +166,13 @@ my_components = \ .IF "$(BUILD_TYPE)" != "$(BUILD_TYPE:s/DESKTOP//)" my_components += \ abp \ - bib \ component/desktop/source/deployment/deployment \ component/desktop/source/deployment/gui/deploymentgui \ component/desktop/source/migration/services/migrationoo2 \ component/desktop/source/migration/services/migrationoo3 \ component/desktop/source/offacc/offacc \ component/desktop/source/splash/spl \ + component/extensions/source/bibliography/bib \ component/extensions/source/propctrlr/pcr \ component/extensions/source/scanner/scn \ component/extensions/source/update/check/updchk.uno \ -- cgit From 2e6705a7287cdd046ed73e4e81dddd9b87d9279e Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 23:58:52 +0100 Subject: extensions: convert logging to gbuild --- Repository.mk | 1 + extensions/Library_log.mk | 64 ++++++++++++++++++++++++++ extensions/Module_extensions.mk | 1 + extensions/prj/build.lst | 3 +- extensions/source/logging/makefile.mk | 84 ---------------------------------- postprocess/packcomponents/makefile.mk | 2 +- 6 files changed, 68 insertions(+), 87 deletions(-) create mode 100644 extensions/Library_log.mk delete mode 100644 extensions/source/logging/makefile.mk diff --git a/Repository.mk b/Repository.mk index c689d3428ed0..67f6f87d7981 100644 --- a/Repository.mk +++ b/Repository.mk @@ -192,6 +192,7 @@ $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ iti \ lng \ lnth \ + log \ lwpft \ MacOSXSpell \ merged \ diff --git a/extensions/Library_log.mk b/extensions/Library_log.mk new file mode 100644 index 000000000000..fc7c2d349535 --- /dev/null +++ b/extensions/Library_log.mk @@ -0,0 +1,64 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,log)) + +$(eval $(call gb_Library_set_componentfile,log,extensions/source/logging/log)) + +$(eval $(call gb_Library_add_api,log,\ + offapi \ + udkapi \ +)) + +$(eval $(call gb_Library_add_noexception_objects,log,\ + extensions/source/logging/log_module \ + extensions/source/logging/logrecord \ +)) + +$(eval $(call gb_Library_add_exception_objects,log,\ + extensions/source/logging/consolehandler \ + extensions/source/logging/csvformatter \ + extensions/source/logging/filehandler \ + extensions/source/logging/log_services \ + extensions/source/logging/logger \ + extensions/source/logging/loggerconfig \ + extensions/source/logging/loghandler \ + extensions/source/logging/plaintextformatter \ +)) + +$(eval $(call gb_Library_add_linked_libs,log,\ + comphelper \ + cppuhelper \ + cppu \ + sal \ + $(gb_STDLIBS) \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index ebf6d26d19ad..c7d364105ddd 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -34,6 +34,7 @@ $(eval $(call gb_Module_add_targets,extensions,\ AllLangResTarget_updchk \ Configuration_updchk \ Library_bib \ + Library_log \ Library_pcr \ Library_scn \ Library_updatecheckui \ diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index 2a76f92db053..d95b30d34e71 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -9,8 +9,7 @@ ex extensions\source\resource nmake - all ex_resrc ex_inc ex extensions\source\xmlextract nmake - all ex_xmlextr ex_inc NULL ex extensions\source\dbpilots nmake - all ex_dbpilots ex_inc NULL ex extensions\source\abpilot nmake - all ex_abpilot ex_inc NULL -ex extensions\source\logging nmake - all ex_logging ex_inc NULL -ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots ex_logging NULL +ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots NULL ex extensions\prj nmake - all ex_prj NULL # Fails at the moment diff --git a/extensions/source/logging/makefile.mk b/extensions/source/logging/makefile.mk deleted file mode 100644 index 1436576e89ba..000000000000 --- a/extensions/source/logging/makefile.mk +++ /dev/null @@ -1,84 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=..$/.. -PRJNAME=extensions -TARGET=log - -# --- Settings ---------------------------------- - -.INCLUDE : settings.mk - -# --- Files ------------------------------------- - -# ... object files ............................ -EXCEPTIONSFILES= \ - $(SLO)$/consolehandler.obj \ - $(SLO)$/csvformatter.obj \ - $(SLO)$/filehandler.obj \ - $(SLO)$/log_services.obj \ - $(SLO)$/logger.obj \ - $(SLO)$/loggerconfig.obj \ - $(SLO)$/loghandler.obj \ - $(SLO)$/plaintextformatter.obj \ - -SLOFILES= \ - $(EXCEPTIONSFILES) \ - $(SLO)$/log_module.obj \ - $(SLO)$/logrecord.obj \ - -# --- library ----------------------------------- - -LIB1TARGET=$(SLB)$/$(TARGET)_t.lib -LIB1FILES=\ - $(SLB)$/$(TARGET).lib - -SHL1TARGET=$(TARGET)$(DLLPOSTFIX) - -SHL1STDLIBS= \ - $(COMPHELPERLIB) \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(SALLIB) - -SHL1LIBS=$(LIB1TARGET) -SHL1DEF=$(MISC)$/$(SHL1TARGET).def -DEF1NAME=$(SHL1TARGET) -SHL1VERSIONMAP=$(SOLARENV)/src/component.map - -# --- Targets ---------------------------------- - -.INCLUDE : target.mk - - -ALLTAR : $(MISC)/log.component - -$(MISC)/log.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - log.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt log.component diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index 1a52db095ccd..a03dd331d454 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -173,6 +173,7 @@ my_components += \ component/desktop/source/offacc/offacc \ component/desktop/source/splash/spl \ component/extensions/source/bibliography/bib \ + component/extensions/source/logging/log \ component/extensions/source/propctrlr/pcr \ component/extensions/source/scanner/scn \ component/extensions/source/update/check/updchk.uno \ @@ -181,7 +182,6 @@ my_components += \ dbp \ fpicker \ fps_office \ - log \ res \ syssh \ tvhlp1 \ -- cgit From ead4cd1fa535f1bdbda4c99217e727903f058e50 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sun, 18 Dec 2011 00:13:28 +0100 Subject: extensions: convert dbpilots to gbuild --- Repository.mk | 1 + extensions/AllLangResTarget_dbp.mk | 50 +++++++++++++++ extensions/Library_dbp.mk | 77 +++++++++++++++++++++++ extensions/Module_extensions.mk | 2 + extensions/prj/build.lst | 3 +- extensions/source/dbpilots/makefile.mk | 111 --------------------------------- postprocess/packcomponents/makefile.mk | 2 +- 7 files changed, 132 insertions(+), 114 deletions(-) create mode 100644 extensions/AllLangResTarget_dbp.mk create mode 100644 extensions/Library_dbp.mk delete mode 100644 extensions/source/dbpilots/makefile.mk diff --git a/Repository.mk b/Repository.mk index 67f6f87d7981..26a8f9a83ecc 100644 --- a/Repository.mk +++ b/Repository.mk @@ -145,6 +145,7 @@ $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ dba \ dbaxml \ dbmm \ + dbp \ dbtools \ dbu \ deploymentmisc \ diff --git a/extensions/AllLangResTarget_dbp.mk b/extensions/AllLangResTarget_dbp.mk new file mode 100644 index 000000000000..657694af7e22 --- /dev/null +++ b/extensions/AllLangResTarget_dbp.mk @@ -0,0 +1,50 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_AllLangResTarget_AllLangResTarget,dbp)) + +$(eval $(call gb_AllLangResTarget_add_srs,dbp,dbp/res)) + +$(eval $(call gb_SrsTarget_SrsTarget,dbp/res)) + +$(eval $(call gb_SrsTarget_set_include,dbp/res,\ + $$(INCLUDE) \ + -I$(realpath $(SRCDIR)/extensions/inc) \ +)) + +$(eval $(call gb_SrsTarget_add_files,dbp/res,\ + extensions/source/dbpilots/commonpagesdbp.src \ + extensions/source/dbpilots/dbpilots.src \ + extensions/source/dbpilots/gridpages.src \ + extensions/source/dbpilots/groupboxpages.src \ + extensions/source/dbpilots/listcombopages.src \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_dbp.mk b/extensions/Library_dbp.mk new file mode 100644 index 000000000000..c7fd685cc3ce --- /dev/null +++ b/extensions/Library_dbp.mk @@ -0,0 +1,77 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,dbp)) + +$(eval $(call gb_Library_set_componentfile,dbp,extensions/source/dbpilots/dbp)) + +$(eval $(call gb_Library_set_include,dbp,\ + $$(INCLUDE) \ + -I$(realpath $(SRCDIR)/extensions/inc) \ + -I$(realpath $(SRCDIR)/extensions/source/inc) \ +)) + +$(eval $(call gb_Library_add_defs,dbp,\ + -DCOMPMOD_NAMESPACE=dbp \ +)) + +$(eval $(call gb_Library_add_api,dbp,\ + offapi \ + udkapi \ +)) + +$(eval $(call gb_Library_add_exception_objects,dbp,\ + extensions/source/dbpilots/commonpagesdbp \ + extensions/source/dbpilots/controlwizard \ + extensions/source/dbpilots/dbpservices \ + extensions/source/dbpilots/dbptools \ + extensions/source/dbpilots/gridwizard \ + extensions/source/dbpilots/groupboxwiz \ + extensions/source/dbpilots/listcombowizard \ + extensions/source/dbpilots/moduledbp \ + extensions/source/dbpilots/optiongrouplayouter \ + extensions/source/dbpilots/wizardservices \ +)) + +$(eval $(call gb_Library_add_linked_libs,dbp,\ + svt \ + vcl \ + tl \ + svl \ + sfx \ + dbtools \ + utl \ + comphelper \ + cppuhelper \ + cppu \ + sal \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index c7d364105ddd..12c47f90104f 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -28,12 +28,14 @@ $(eval $(call gb_Module_Module,extensions)) $(eval $(call gb_Module_add_targets,extensions,\ AllLangResTarget_bib \ + AllLangResTarget_dbp \ AllLangResTarget_pcr \ AllLangResTarget_san \ AllLangResTarget_upd \ AllLangResTarget_updchk \ Configuration_updchk \ Library_bib \ + Library_dbp \ Library_log \ Library_pcr \ Library_scn \ diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index d95b30d34e71..338c79061e28 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -7,9 +7,8 @@ ex extensions\source\activex\msidl nmake - w ex_axmsidl ex_in ex extensions\source\activex\main nmake - w ex_axmain ex_axmsidl.w ex_inc NULL ex extensions\source\resource nmake - all ex_resrc ex_inc NULL ex extensions\source\xmlextract nmake - all ex_xmlextr ex_inc NULL -ex extensions\source\dbpilots nmake - all ex_dbpilots ex_inc NULL ex extensions\source\abpilot nmake - all ex_abpilot ex_inc NULL -ex extensions\util nmake - all ex_util ex_abpilot ex_dbpilots NULL +ex extensions\util nmake - all ex_util ex_abpilot NULL ex extensions\prj nmake - all ex_prj NULL # Fails at the moment diff --git a/extensions/source/dbpilots/makefile.mk b/extensions/source/dbpilots/makefile.mk deleted file mode 100644 index e37ab0a546ac..000000000000 --- a/extensions/source/dbpilots/makefile.mk +++ /dev/null @@ -1,111 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/.. -PRJINC=..$/inc - -PRJNAME=extensions -TARGET=dbp -ENABLE_EXCEPTIONS=TRUE -VISIBILITY_HIDDEN=TRUE - -# --- Settings ----------------------------------------------------- - -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -# --- defines ------------------------------------------------------ - -CDEFS+=-DCOMPMOD_NAMESPACE=dbp - -# --- Files -------------------------------------------------------- - -CXXFILES= dbptools.cxx \ - gridwizard.cxx \ - listcombowizard.cxx \ - optiongrouplayouter.cxx \ - commonpagesdbp.cxx \ - groupboxwiz.cxx \ - wizardservices.cxx \ - controlwizard.cxx \ - moduledbp.cxx \ - dbpservices.cxx - -SLOFILES= $(SLO)$/dbptools.obj \ - $(SLO)$/gridwizard.obj \ - $(SLO)$/listcombowizard.obj \ - $(SLO)$/optiongrouplayouter.obj \ - $(SLO)$/commonpagesdbp.obj \ - $(SLO)$/groupboxwiz.obj \ - $(SLO)$/wizardservices.obj \ - $(SLO)$/controlwizard.obj \ - $(SLO)$/moduledbp.obj \ - $(SLO)$/dbpservices.obj - - -SRS1NAME=$(TARGET) -SRC1FILES= gridpages.src \ - commonpagesdbp.src \ - dbpilots.src \ - groupboxpages.src \ - listcombopages.src - -RESLIB1NAME=dbp -RESLIB1SRSFILES= $(SRS)$/dbp.srs - -SHL1TARGET= $(TARGET)$(DLLPOSTFIX) -SHL1VERSIONMAP=$(SOLARENV)/src/component.map - -SHL1STDLIBS= \ - $(SVTOOLLIB) \ - $(VCLLIB) \ - $(TOOLSLIB) \ - $(SVLLIB) \ - $(SFXLIB) \ - $(DBTOOLSLIB) \ - $(UNOTOOLSLIB) \ - $(COMPHELPERLIB) \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(SALLIB) - -SHL1LIBS= $(SLB)$/$(TARGET).lib -SHL1IMPLIB= i$(TARGET) -SHL1DEPN= $(SHL1LIBS) -SHL1DEF= $(MISC)$/$(SHL1TARGET).def - -DEF1NAME= $(SHL1TARGET) - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk - -ALLTAR : $(MISC)/dbp.component - -$(MISC)/dbp.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - dbp.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt dbp.component diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index a03dd331d454..1865bfdfcb40 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -173,13 +173,13 @@ my_components += \ component/desktop/source/offacc/offacc \ component/desktop/source/splash/spl \ component/extensions/source/bibliography/bib \ + component/extensions/source/dbpilots/dbp \ component/extensions/source/logging/log \ component/extensions/source/propctrlr/pcr \ component/extensions/source/scanner/scn \ component/extensions/source/update/check/updchk.uno \ component/extensions/source/update/feed/updatefeed \ component/extensions/source/update/ui/updchk \ - dbp \ fpicker \ fps_office \ res \ -- cgit From bc4fda7310c25b202b0e65a16bbc6f600931cbe4 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sun, 18 Dec 2011 00:23:55 +0100 Subject: extensions: convert abpilot to gbuild --- Repository.mk | 1 + extensions/AllLangResTarget_abp.mk | 48 ++++++++++++++ extensions/Library_abp.mk | 91 ++++++++++++++++++++++++++ extensions/Module_extensions.mk | 2 + extensions/prj/build.lst | 3 +- extensions/source/abpilot/exports.dxp | 1 - extensions/source/abpilot/makefile.mk | 115 --------------------------------- postprocess/packcomponents/makefile.mk | 2 +- 8 files changed, 144 insertions(+), 119 deletions(-) create mode 100644 extensions/AllLangResTarget_abp.mk create mode 100644 extensions/Library_abp.mk delete mode 100644 extensions/source/abpilot/exports.dxp delete mode 100644 extensions/source/abpilot/makefile.mk diff --git a/Repository.mk b/Repository.mk index 26a8f9a83ecc..adc87e2dbcc2 100644 --- a/Repository.mk +++ b/Repository.mk @@ -113,6 +113,7 @@ endif $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ PptImporter \ + abp \ adabas \ adabasui \ agg \ diff --git a/extensions/AllLangResTarget_abp.mk b/extensions/AllLangResTarget_abp.mk new file mode 100644 index 000000000000..30371f93a648 --- /dev/null +++ b/extensions/AllLangResTarget_abp.mk @@ -0,0 +1,48 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_AllLangResTarget_AllLangResTarget,abp)) + +$(eval $(call gb_AllLangResTarget_set_reslocation,abp,extensions/res)) + +$(eval $(call gb_AllLangResTarget_add_srs,abp,abp/res)) + +$(eval $(call gb_SrsTarget_SrsTarget,abp/res)) + +$(eval $(call gb_SrsTarget_set_include,abp/res,\ + $$(INCLUDE) \ + -I$(realpath $(SRCDIR)/extensions/inc) \ +)) + +$(eval $(call gb_SrsTarget_add_files,abp/res,\ + extensions/source/abpilot/abspilot.src \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_abp.mk b/extensions/Library_abp.mk new file mode 100644 index 000000000000..411c2d823ccf --- /dev/null +++ b/extensions/Library_abp.mk @@ -0,0 +1,91 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,abp)) + +$(eval $(call gb_Library_set_componentfile,abp,extensions/source/abpilot/abp)) + +$(eval $(call gb_Library_set_include,abp,\ + $$(INCLUDE) \ + -I$(realpath $(SRCDIR)/extensions/inc) \ + -I$(realpath $(SRCDIR)/extensions/source/inc) \ +)) + +ifneq ($(WITH_MOZILLA),NO) +ifneq ($(SYSTEM_MOZILLA),YES) +$(eval $(call gb_Library_add_defs,abp,\ + -DWITH_MOZILLA \ +)) +endif +endif + +$(eval $(call gb_Library_add_defs,abp,\ + -DCOMPMOD_NAMESPACE=abp \ + -DCOMPMOD_RESPREFIX=abp \ +)) + +$(eval $(call gb_Library_add_api,abp,\ + offapi \ + udkapi \ +)) + +$(eval $(call gb_Library_add_exception_objects,abp,\ + extensions/source/abpilot/abpfinalpage \ + extensions/source/abpilot/abpservices \ + extensions/source/abpilot/abspage \ + extensions/source/abpilot/abspilot \ + extensions/source/abpilot/admininvokationimpl \ + extensions/source/abpilot/admininvokationpage \ + extensions/source/abpilot/datasourcehandling \ + extensions/source/abpilot/fieldmappingimpl \ + extensions/source/abpilot/fieldmappingpage \ + extensions/source/abpilot/moduleabp \ + extensions/source/abpilot/tableselectionpage \ + extensions/source/abpilot/typeselectionpage \ + extensions/source/abpilot/unodialogabp \ +)) + +$(eval $(call gb_Library_add_linked_libs,abp,\ + comphelper \ + cppuhelper \ + cppu \ + sal \ + sfx \ + svl \ + svt \ + svxcore \ + svx \ + tk \ + tl \ + utl \ + vcl \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index 12c47f90104f..4bd1aa12574a 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -27,6 +27,7 @@ $(eval $(call gb_Module_Module,extensions)) $(eval $(call gb_Module_add_targets,extensions,\ + AllLangResTarget_abp \ AllLangResTarget_bib \ AllLangResTarget_dbp \ AllLangResTarget_pcr \ @@ -34,6 +35,7 @@ $(eval $(call gb_Module_add_targets,extensions,\ AllLangResTarget_upd \ AllLangResTarget_updchk \ Configuration_updchk \ + Library_abp \ Library_bib \ Library_dbp \ Library_log \ diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index 338c79061e28..e6bf64aa3120 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -7,8 +7,7 @@ ex extensions\source\activex\msidl nmake - w ex_axmsidl ex_in ex extensions\source\activex\main nmake - w ex_axmain ex_axmsidl.w ex_inc NULL ex extensions\source\resource nmake - all ex_resrc ex_inc NULL ex extensions\source\xmlextract nmake - all ex_xmlextr ex_inc NULL -ex extensions\source\abpilot nmake - all ex_abpilot ex_inc NULL -ex extensions\util nmake - all ex_util ex_abpilot NULL +ex extensions\util nmake - all ex_util NULL ex extensions\prj nmake - all ex_prj NULL # Fails at the moment diff --git a/extensions/source/abpilot/exports.dxp b/extensions/source/abpilot/exports.dxp deleted file mode 100644 index 70033078921a..000000000000 --- a/extensions/source/abpilot/exports.dxp +++ /dev/null @@ -1 +0,0 @@ -component_getFactory diff --git a/extensions/source/abpilot/makefile.mk b/extensions/source/abpilot/makefile.mk deleted file mode 100644 index 7f84828247bb..000000000000 --- a/extensions/source/abpilot/makefile.mk +++ /dev/null @@ -1,115 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/.. -PRJINC=..$/inc - -PRJNAME=extensions -TARGET=abp -USE_DEFFILE=TRUE -VISIBILITY_HIDDEN=TRUE - -# --- Settings ----------------------------------------------------- - -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -# --- defines ------------------------------------------------------ - -CDEFS+=-DCOMPMOD_NAMESPACE=abp -CDEFS+=-DCOMPMOD_RESPREFIX=abp - -# --- Files -------------------------------------------------------- - -EXCEPTIONSFILES= \ - $(SLO)$/abpfinalpage.obj \ - $(SLO)$/abpservices.obj \ - $(SLO)$/abspage.obj \ - $(SLO)$/abspilot.obj \ - $(SLO)$/admininvokationimpl.obj \ - $(SLO)$/admininvokationpage.obj \ - $(SLO)$/datasourcehandling.obj \ - $(SLO)$/fieldmappingimpl.obj \ - $(SLO)$/fieldmappingpage.obj \ - $(SLO)$/moduleabp.obj \ - $(SLO)$/tableselectionpage.obj \ - $(SLO)$/typeselectionpage.obj \ - $(SLO)$/unodialogabp.obj \ - -SLOFILES= \ - $(EXCEPTIONSFILES) - - -.IF "$(WITH_MOZILLA)" != "NO" -.IF "$(SYSTEM_MOZILLA)" != "YES" -CDEFS+=-DWITH_MOZILLA -.ENDIF -.ENDIF - -SRS1NAME=$(TARGET) -SRC1FILES= abspilot.src - -RESLIB1NAME=abp -RESLIB1IMAGES=$(PRJ)$/res -RESLIB1SRSFILES= $(SRS)$/abp.srs - -SHL1TARGET= $(TARGET)$(DLLPOSTFIX) -SHL1VERSIONMAP=$(SOLARENV)/src/component.map - -SHL1STDLIBS= \ - $(COMPHELPERLIB) \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(SALLIB) \ - $(SFXLIB) \ - $(SVLLIB) \ - $(SVTLIB) \ - $(SVTOOLLIB) \ - $(SVXCORELIB) \ - $(SVXLIB) \ - $(TKLIB) \ - $(TOOLSLIB) \ - $(UNOTOOLSLIB) \ - $(VCLLIB) \ - -SHL1LIBS= $(SLB)$/$(TARGET).lib -SHL1IMPLIB= i$(TARGET) -SHL1DEPN= $(SHL1LIBS) -SHL1DEF= $(MISC)$/$(SHL1TARGET).def - -DEF1NAME= $(SHL1TARGET) -DEF1EXPORTFILE= exports.dxp - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk - -ALLTAR : $(MISC)/abp.component - -$(MISC)/abp.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - abp.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt abp.component diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index 1865bfdfcb40..1dfc4c9c40df 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -165,13 +165,13 @@ my_components = \ .IF "$(BUILD_TYPE)" != "$(BUILD_TYPE:s/DESKTOP//)" my_components += \ - abp \ component/desktop/source/deployment/deployment \ component/desktop/source/deployment/gui/deploymentgui \ component/desktop/source/migration/services/migrationoo2 \ component/desktop/source/migration/services/migrationoo3 \ component/desktop/source/offacc/offacc \ component/desktop/source/splash/spl \ + component/extensions/source/abpilot/abp \ component/extensions/source/bibliography/bib \ component/extensions/source/dbpilots/dbp \ component/extensions/source/logging/log \ -- cgit From 42506a1cfdad85ead9620b363de99d7475a8fb08 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sun, 18 Dec 2011 00:47:43 +0100 Subject: extensions: convert resource, xmlextract to gbuild --- Repository.mk | 2 + extensions/Library_res.mk | 56 +++++++++++++++++++++ extensions/Library_xmx.mk | 54 ++++++++++++++++++++ extensions/Module_extensions.mk | 2 + extensions/prj/build.lst | 2 - extensions/source/resource/exports.dxp | 1 - extensions/source/resource/makefile.mk | 86 -------------------------------- extensions/source/xmlextract/makefile.mk | 73 --------------------------- postprocess/packcomponents/makefile.mk | 5 +- 9 files changed, 117 insertions(+), 164 deletions(-) create mode 100644 extensions/Library_res.mk create mode 100644 extensions/Library_xmx.mk delete mode 100644 extensions/source/resource/exports.dxp delete mode 100644 extensions/source/resource/makefile.mk delete mode 100644 extensions/source/xmlextract/makefile.mk diff --git a/Repository.mk b/Repository.mk index adc87e2dbcc2..e7169f919ef9 100644 --- a/Repository.mk +++ b/Repository.mk @@ -208,6 +208,7 @@ $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ placeware \ protocolhandler \ qstart_gtk \ + res \ resourcemodel \ rpt \ rptui \ @@ -268,6 +269,7 @@ $(eval $(call gb_Helper_register_libraries,OOOLIBS, \ xcr \ xmlfa \ xmlfd \ + xmx \ xo \ xof \ xsltdlg \ diff --git a/extensions/Library_res.mk b/extensions/Library_res.mk new file mode 100644 index 000000000000..322197cbdbbf --- /dev/null +++ b/extensions/Library_res.mk @@ -0,0 +1,56 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,res)) + +$(eval $(call gb_Library_set_componentfile,res,extensions/source/resource/res)) + +$(eval $(call gb_Library_add_api,res,\ + udkapi \ + offapi \ +)) + +$(eval $(call gb_Library_add_linked_libs,res,\ + vcl \ + tl \ + comphelper \ + cppu \ + cppuhelper \ + sal \ + $(gb_STDLIBS) \ +)) + +$(eval $(call gb_Library_add_exception_objects,res,\ + extensions/source/resource/ResourceIndexAccess \ + extensions/source/resource/oooresourceloader \ + extensions/source/resource/resourceservices \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_xmx.mk b/extensions/Library_xmx.mk new file mode 100644 index 000000000000..1d4ccd501362 --- /dev/null +++ b/extensions/Library_xmx.mk @@ -0,0 +1,54 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,xmx)) + +$(eval $(call gb_Library_set_componentfile,xmx,extensions/source/xmlextract/xmx)) + +$(eval $(call gb_Library_add_api,xmx,\ + offapi \ + udkapi \ +)) + +$(eval $(call gb_Library_add_exception_objects,xmx,\ + extensions/source/xmlextract/xmxtrct \ + extensions/source/xmlextract/xmxuno \ +)) + +$(eval $(call gb_Library_add_linked_libs,xmx,\ + sot \ + utl \ + tl \ + cppuhelper \ + cppu \ + sal \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index 4bd1aa12574a..6865f53cf555 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -40,10 +40,12 @@ $(eval $(call gb_Module_add_targets,extensions,\ Library_dbp \ Library_log \ Library_pcr \ + Library_res \ Library_scn \ Library_updatecheckui \ Library_updatefeed \ Library_updchk \ + Library_xmx \ Package_bib \ Package_pcr \ )) diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index e6bf64aa3120..0e7e855aa6ef 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -5,8 +5,6 @@ ex extensions\inc nmake - all ex_inc NULL ex extensions\inc\ucbhelper get - all ex_incucbh ex_inc NULL ex extensions\source\activex\msidl nmake - w ex_axmsidl ex_inc NULL ex extensions\source\activex\main nmake - w ex_axmain ex_axmsidl.w ex_inc NULL -ex extensions\source\resource nmake - all ex_resrc ex_inc NULL -ex extensions\source\xmlextract nmake - all ex_xmlextr ex_inc NULL ex extensions\util nmake - all ex_util NULL ex extensions\prj nmake - all ex_prj NULL diff --git a/extensions/source/resource/exports.dxp b/extensions/source/resource/exports.dxp deleted file mode 100644 index 70033078921a..000000000000 --- a/extensions/source/resource/exports.dxp +++ /dev/null @@ -1 +0,0 @@ -component_getFactory diff --git a/extensions/source/resource/makefile.mk b/extensions/source/resource/makefile.mk deleted file mode 100644 index 4839ec0b7ca2..000000000000 --- a/extensions/source/resource/makefile.mk +++ /dev/null @@ -1,86 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=..$/.. - -PRJNAME=extensions -TARGET=res -LIBTARGET=NO -USE_LDUMP2=TRUE -USE_DEFFILE=TRUE -ENABLE_EXCEPTIONS=TRUE - -# --- Settings ----------------------------------------------------- - -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -# --- Files -------------------------------------------------------- - -SLOFILES= \ - $(SLO)$/ResourceIndexAccess.obj \ - $(SLO)$/oooresourceloader.obj \ - $(SLO)$/resourceservices.obj - -LIB1TARGET= $(SLB)$/$(TARGET).lib -LIB1OBJFILES= $(SLOFILES) - -SHL1TARGET= $(TARGET)$(DLLPOSTFIX) - -SHL1STDLIBS= \ - $(COMPHELPERLIB) \ - $(CPPULIB) \ - $(CPPUHELPERLIB) \ - $(SALLIB) \ - $(VCLLIB) \ - $(TOOLSLIB) - -SHL1DEPN= -SHL1IMPLIB= ires -SHL1LIBS= $(LIB1TARGET) -SHL1DEF= $(MISC)$/$(SHL1TARGET).def - -SHL1DEF=$(MISC)$/$(SHL1TARGET).def -SHL1IMPLIB=i$(TARGET) -SHL1LIBS=$(SLB)$/$(TARGET).lib -SHL1VERSIONMAP=$(SOLARENV)/src/component.map - -DEF1NAME= $(SHL1TARGET) -DEF1EXPORTFILE= exports.dxp - - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk -.INCLUDE : $(PRJ)$/util$/target.pmk - - -ALLTAR : $(MISC)/res.component - -$(MISC)/res.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - res.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt res.component diff --git a/extensions/source/xmlextract/makefile.mk b/extensions/source/xmlextract/makefile.mk deleted file mode 100644 index fa54df738b58..000000000000 --- a/extensions/source/xmlextract/makefile.mk +++ /dev/null @@ -1,73 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=..$/.. -PRJNAME=extensions -TARGET=xmx - -ENABLE_EXCEPTIONS=TRUE -USE_DEFFILE=TRUE - -# --- Settings ---------------------------------- - -.INCLUDE : $(PRJ)$/util$/makefile.pmk - -# --- Files ------------------------------------- - -SLOFILES= $(SLO)$/xmxuno.obj \ - $(SLO)$/xmxtrct.obj - -# --- Library ----------------------------------- - -SHL1TARGET=$(TARGET)$(DLLPOSTFIX) -SHL1IMPLIB= i$(SHL1TARGET) - -SHL1VERSIONMAP=$(SOLARENV)/src/component.map -SHL1DEF=$(MISC)$/$(SHL1TARGET).def -DEF1NAME=$(SHL1TARGET) - -SHL1STDLIBS=\ - $(SOTLIB) \ - $(UNOTOOLSLIB) \ - $(TOOLSLIB) \ - $(CPPUHELPERLIB) \ - $(CPPULIB) \ - $(SALLIB) - -SHL1LIBS= $(SLB)$/$(TARGET).lib - -# --- Targets ---------------------------------- - -.INCLUDE : target.mk - -ALLTAR : $(MISC)/xmx.component - -$(MISC)/xmx.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ - xmx.component - $(XSLTPROC) --nonet --stringparam uri \ - '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ - $(SOLARENV)/bin/createcomponent.xslt xmx.component diff --git a/postprocess/packcomponents/makefile.mk b/postprocess/packcomponents/makefile.mk index 1dfc4c9c40df..4b8c290abd23 100644 --- a/postprocess/packcomponents/makefile.mk +++ b/postprocess/packcomponents/makefile.mk @@ -176,17 +176,18 @@ my_components += \ component/extensions/source/dbpilots/dbp \ component/extensions/source/logging/log \ component/extensions/source/propctrlr/pcr \ + component/extensions/source/resource/res \ component/extensions/source/scanner/scn \ component/extensions/source/update/check/updchk.uno \ component/extensions/source/update/feed/updatefeed \ component/extensions/source/update/ui/updchk \ + component/extensions/source/xmlextract/xmx \ fpicker \ fps_office \ - res \ syssh \ tvhlp1 \ ucpchelp1 \ - xmx + .ENDIF .IF "$(DISABLE_PYTHON)" != "TRUE" -- cgit From 1841baf54f053c54969d0164185e2366f9efb3fd Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sun, 18 Dec 2011 01:28:13 +0100 Subject: extensions: convert activex to gbuild --- Repository.mk | 2 + extensions/Library_so_activex.mk | 91 ++ extensions/Library_so_activex_x64.mk | 90 ++ extensions/Module_extensions.mk | 22 +- extensions/WinResTarget_activex.mk | 46 + extensions/prj/build.lst | 2 - extensions/source/activex/README.txt | 33 + extensions/source/activex/SOActionsApproval.cxx | 32 + extensions/source/activex/SOActionsApproval.h | 83 ++ extensions/source/activex/SOActionsApproval.rgs | 24 + extensions/source/activex/SOActiveX.cxx | 1153 ++++++++++++++++++++ extensions/source/activex/SOActiveX.h | 178 +++ extensions/source/activex/SOActiveX.rgs | 33 + extensions/source/activex/SOComWindowPeer.cxx | 31 + extensions/source/activex/SOComWindowPeer.h | 136 +++ extensions/source/activex/SOComWindowPeer.rgs | 23 + .../source/activex/SODispatchInterceptor.cxx | 225 ++++ extensions/source/activex/SODispatchInterceptor.h | 158 +++ .../source/activex/SODispatchInterceptor.rgs | 23 + extensions/source/activex/StdAfx2.cxx | 21 + extensions/source/activex/StdAfx2.h | 45 + extensions/source/activex/com_uno_helper.h | 26 + extensions/source/activex/example.html | 26 + extensions/source/activex/main/README.txt | 33 - .../source/activex/main/SOActionsApproval.cpp | 32 - extensions/source/activex/main/SOActionsApproval.h | 83 -- .../source/activex/main/SOActionsApproval.rgs | 24 - extensions/source/activex/main/SOActiveX.cpp | 1153 -------------------- extensions/source/activex/main/SOActiveX.h | 178 --- extensions/source/activex/main/SOActiveX.rgs | 33 - extensions/source/activex/main/SOComWindowPeer.cpp | 31 - extensions/source/activex/main/SOComWindowPeer.h | 136 --- extensions/source/activex/main/SOComWindowPeer.rgs | 23 - .../source/activex/main/SODispatchInterceptor.cpp | 225 ---- .../source/activex/main/SODispatchInterceptor.h | 158 --- .../source/activex/main/SODispatchInterceptor.rgs | 23 - extensions/source/activex/main/StdAfx2.cpp | 21 - extensions/source/activex/main/StdAfx2.h | 45 - extensions/source/activex/main/com_uno_helper.h | 26 - extensions/source/activex/main/example.html | 26 - extensions/source/activex/main/makefile.mk | 157 --- extensions/source/activex/main/resource.h | 28 - extensions/source/activex/main/so_activex.cpp | 685 ------------ extensions/source/activex/main/so_activex.def | 13 - extensions/source/activex/main/so_activex.rc | 113 -- extensions/source/activex/msidl/makefile.mk | 62 -- extensions/source/activex/msidl/so_activex.idl | 210 ---- extensions/source/activex/resource.h | 28 + extensions/source/activex/so_activex.cxx | 685 ++++++++++++ extensions/source/activex/so_activex.def | 13 + extensions/source/activex/so_activex.idl | 210 ++++ extensions/source/activex/so_activex.rc | 111 ++ 52 files changed, 3546 insertions(+), 3522 deletions(-) create mode 100644 extensions/Library_so_activex.mk create mode 100644 extensions/Library_so_activex_x64.mk create mode 100644 extensions/WinResTarget_activex.mk create mode 100644 extensions/source/activex/README.txt create mode 100644 extensions/source/activex/SOActionsApproval.cxx create mode 100644 extensions/source/activex/SOActionsApproval.h create mode 100644 extensions/source/activex/SOActionsApproval.rgs create mode 100644 extensions/source/activex/SOActiveX.cxx create mode 100644 extensions/source/activex/SOActiveX.h create mode 100644 extensions/source/activex/SOActiveX.rgs create mode 100644 extensions/source/activex/SOComWindowPeer.cxx create mode 100644 extensions/source/activex/SOComWindowPeer.h create mode 100644 extensions/source/activex/SOComWindowPeer.rgs create mode 100644 extensions/source/activex/SODispatchInterceptor.cxx create mode 100644 extensions/source/activex/SODispatchInterceptor.h create mode 100644 extensions/source/activex/SODispatchInterceptor.rgs create mode 100644 extensions/source/activex/StdAfx2.cxx create mode 100644 extensions/source/activex/StdAfx2.h create mode 100644 extensions/source/activex/com_uno_helper.h create mode 100644 extensions/source/activex/example.html delete mode 100644 extensions/source/activex/main/README.txt delete mode 100644 extensions/source/activex/main/SOActionsApproval.cpp delete mode 100644 extensions/source/activex/main/SOActionsApproval.h delete mode 100644 extensions/source/activex/main/SOActionsApproval.rgs delete mode 100644 extensions/source/activex/main/SOActiveX.cpp delete mode 100644 extensions/source/activex/main/SOActiveX.h delete mode 100644 extensions/source/activex/main/SOActiveX.rgs delete mode 100644 extensions/source/activex/main/SOComWindowPeer.cpp delete mode 100644 extensions/source/activex/main/SOComWindowPeer.h delete mode 100644 extensions/source/activex/main/SOComWindowPeer.rgs delete mode 100644 extensions/source/activex/main/SODispatchInterceptor.cpp delete mode 100644 extensions/source/activex/main/SODispatchInterceptor.h delete mode 100644 extensions/source/activex/main/SODispatchInterceptor.rgs delete mode 100644 extensions/source/activex/main/StdAfx2.cpp delete mode 100644 extensions/source/activex/main/StdAfx2.h delete mode 100644 extensions/source/activex/main/com_uno_helper.h delete mode 100644 extensions/source/activex/main/example.html delete mode 100644 extensions/source/activex/main/makefile.mk delete mode 100644 extensions/source/activex/main/resource.h delete mode 100644 extensions/source/activex/main/so_activex.cpp delete mode 100644 extensions/source/activex/main/so_activex.def delete mode 100644 extensions/source/activex/main/so_activex.rc delete mode 100644 extensions/source/activex/msidl/makefile.mk delete mode 100644 extensions/source/activex/msidl/so_activex.idl create mode 100644 extensions/source/activex/resource.h create mode 100644 extensions/source/activex/so_activex.cxx create mode 100644 extensions/source/activex/so_activex.def create mode 100644 extensions/source/activex/so_activex.idl create mode 100644 extensions/source/activex/so_activex.rc diff --git a/Repository.mk b/Repository.mk index e7169f919ef9..4f2e8e6362fd 100644 --- a/Repository.mk +++ b/Repository.mk @@ -328,6 +328,8 @@ $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ dnd \ dtrans \ ftransl \ + so_activex \ + so_activex_x64 \ sysdtrans \ )) endif diff --git a/extensions/Library_so_activex.mk b/extensions/Library_so_activex.mk new file mode 100644 index 000000000000..732b2713e077 --- /dev/null +++ b/extensions/Library_so_activex.mk @@ -0,0 +1,91 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,so_activex)) + +$(SRCDIR)/extensions/source/activex/so_activex.cxx: $(WORKDIR)/CustomTarget/so_activex/so_activex.tlb + +$(WORKDIR)/CustomTarget/so_activex/so_activex.tlb: $(SRCDIR)/extensions/source/activex/so_activex.idl + mkdir -p $(WORKDIR)/CustomTarget/so_activex + midl.exe -out $(call gb_Helper_convert_native,$(WORKDIR)/CustomTarget/so_activex) -Oicf $(call gb_Helper_convert_native,$<) \ + $(foreach i,$(SOLARINC_FOR_BUILD), $(patsubst -I,/I,$(i))) + +$(eval $(call gb_Library_set_include,so_activex,\ + $$(INCLUDE) \ + -I$(WORKDIR)/CustomTarget/so_activex \ + $(foreach i,$(ATL_INCLUDE), -I$(i)) \ +)) + +$(eval $(call gb_Library_add_api,so_activex,\ + offapi \ + udkapi \ +)) + +$(eval $(call gb_Library_add_nativeres,so_activex,activex_res)) + +$(eval $(call gb_Library_add_exception_objects,so_activex,\ + extensions/source/activex/so_activex \ + extensions/source/activex/SOActiveX \ + extensions/source/activex/SOComWindowPeer \ + extensions/source/activex/SODispatchInterceptor \ + extensions/source/activex/SOActionsApproval \ + extensions/source/activex/StdAfx2 \ +)) + +$(eval $(call gb_Library_add_ldflags,so_activex,\ + /DEF:$(call gb_Helper_convert_native,$(SRCDIR)/extensions/source/activex/so_activex.def) \ +)) + +$(eval $(call gb_Library_add_linked_libs,so_activex,\ + uuid \ + advapi32 \ + ole32 \ + oleaut32 \ + gdi32 \ + urlmon \ + shlwapi \ +)) + +ifneq ($(USE_DEBUG_RUNTIME),) +$(eval $(call gb_Library_add_libs,so_activex,\ + $(ATL_LIB)/atlsd.lib \ +)) +else +$(eval $(call gb_Library_add_libs,so_activex,\ + $(ATL_LIB)/atls.lib \ +)) +endif + +$(call gb_Library_get_clean_target,so_activex): idlclean + +idlclean: + rm -rf $(WORKDIR)/CustomTarget/so_activex + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_so_activex_x64.mk b/extensions/Library_so_activex_x64.mk new file mode 100644 index 000000000000..eab054d1dae1 --- /dev/null +++ b/extensions/Library_so_activex_x64.mk @@ -0,0 +1,90 @@ +# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_Library_Library,so_activex_x64)) + +$(eval $(call gb_Library_set_x64,so_activex_x64,YES)) + +$(SRCDIR)/extensions/source/activex/so_activex.cxx: $(WORKDIR)/CustomTarget/so_activex/so_activex.tlb + +$(eval $(call gb_Library_set_include,so_activex_x64,\ + $$(INCLUDE) \ + -I$(realpath $(SRCDIR)/extensions/source/activex) \ + -I$(WORKDIR)/CustomTarget/so_activex \ + $(foreach i,$(ATL_INCLUDE), -I$(i)) \ +)) + +$(eval $(call gb_Library_add_api,so_activex_x64,\ + offapi \ + udkapi \ +)) + +$(eval $(call gb_Library_add_nativeres,so_activex_x64,activex_res)) + +$(WORKDIR)/extensions/source/activex/%.cxx: $(SRCDIR)/extensions/source/activex/%.cxx + mkdir -p $(dir $@) + cp $< $@ + +$(eval $(call gb_Library_add_x64_generated_exception_objects,so_activex_x64,\ + extensions/source/activex/so_activex \ + extensions/source/activex/SOActiveX \ + extensions/source/activex/SOComWindowPeer \ + extensions/source/activex/SODispatchInterceptor \ + extensions/source/activex/SOActionsApproval \ + extensions/source/activex/StdAfx2 \ +)) + +$(eval $(call gb_Library_add_ldflags,so_activex_x64,\ + /DEF:$(call gb_Helper_convert_native,$(SRCDIR)/extensions/source/activex/so_activex.def) \ +)) + +$(eval $(call gb_Library_add_linked_libs,so_activex_x64,\ + uuid \ + advapi32 \ + ole32 \ + oleaut32 \ + gdi32 \ + urlmon \ + shlwapi \ +)) + +ifneq ($(USE_DEBUG_RUNTIME),) +$(eval $(call gb_Library_add_libs,so_activex_x64,\ + $(ATL_LIB)/amd64/atlsd.lib \ +)) +else +$(eval $(call gb_Library_add_libs,so_activex_x64,\ + $(ATL_LIB)/amd64/atls.lib \ +)) +endif + +$(call gb_Library_get_clean_target,so_activex_x64): idlclean + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index 6865f53cf555..348b95eeca95 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -13,6 +13,7 @@ # # Major Contributor(s): # Copyright (C) 2011 Jan Holesovsky (initial developer) +# Copyright (C) 2011 Peter Foley # # All Rights Reserved. # @@ -51,13 +52,30 @@ $(eval $(call gb_Module_add_targets,extensions,\ )) ifeq ($(OS),WNT) + +ifeq ($(COM),MSC) +ifneq ($(DISABLE_ACTIVEX),TRUE) +$(eval $(call gb_Module_add_targets,extensions,\ + WinResTarget_activex \ + Library_so_activex \ +)) + +ifeq ($(BUILD_X64),TRUE) +$(eval $(call gb_Module_add_targets,extensions,\ + Library_so_activex_x64 \ +)) +endif # BUILD_X64 +endif # DISABLE_ACTIVEX +endif # COM=MSC + ifeq ($(DISABLE_ATL),) $(eval $(call gb_Module_add_targets,extensions,\ Library_oleautobridge \ Library_oleautobridge2 \ )) -endif -endif +endif # DISABLE_ATL + +endif # WNT ifneq ($(WITH_MOZILLA),NO) diff --git a/extensions/WinResTarget_activex.mk b/extensions/WinResTarget_activex.mk new file mode 100644 index 000000000000..0487bc2f3cbc --- /dev/null +++ b/extensions/WinResTarget_activex.mk @@ -0,0 +1,46 @@ +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Peter Foley +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_WinResTarget_WinResTarget,activex_res)) + +ifneq ($(PRODUCT),) +$(eval $(call gb_WinResTarget_set_defs,activex_res,\ + $$(DEFS) \ + -DPRODUCT \ +)) +endif + +$(eval $(call gb_WinResTarget_add_file,activex_res,extensions/source/activex/so_activex)) + +$(SRCDIR)/extensions/source/activex/so_activex.rc: $(WORKDIR)/CustomTarget/so_activex/so_activex.tlb + +$(eval $(call gb_WinResTarget_set_defs,activex_res,\ + $$(DEFS) \ + -DMISC=$(call gb_Helper_convert_native,$(WORKDIR)/CustomTarget/so_activex) \ +)) diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index 0e7e855aa6ef..df4ba361d372 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -3,8 +3,6 @@ ex extensions : officecfg TRANSLATIONS:translations DESKTOP:rdbmaker svx SANE ex extensions usr1 - all ex_mkout NULL ex extensions\inc nmake - all ex_inc NULL ex extensions\inc\ucbhelper get - all ex_incucbh ex_inc NULL -ex extensions\source\activex\msidl nmake - w ex_axmsidl ex_inc NULL -ex extensions\source\activex\main nmake - w ex_axmain ex_axmsidl.w ex_inc NULL ex extensions\util nmake - all ex_util NULL ex extensions\prj nmake - all ex_prj NULL diff --git a/extensions/source/activex/README.txt b/extensions/source/activex/README.txt new file mode 100644 index 000000000000..9d647987aaa7 --- /dev/null +++ b/extensions/source/activex/README.txt @@ -0,0 +1,33 @@ + Description. + +The StarOffice ActiveX control shows an example of access to UNO through COM technology. +It requires a properly installed StarOffice version 6.0/6.1 or OpenOffice 1.0. +This is a Lite ActiveX control so it can be used only in containers that +allows to use such controls. + +Pressing to any link to staroffice document should activate the control. +So the document will be opened in ReadOnly mode. + +Also it can be activated with an tag from a html-page. +Without any parameters for an object tag a new writer document will be +opened for editing. Possible parameters are + src - full URL to the file that should be edited/viewed; + it can contain "private:factory/..." URLs to open new documents + for edit, for example "private:factory/swriter" + readonly - the default value is "true", in case it is set to any other + value the document is opened for editing + +As any ActiveX control this one should be registered. +To let MSIE register it itself the "CODEBASE" parameter +for the "OBJECT" tag should be specified +with an URL to the library "so_activex.dll". +The example of registration with "OBJECT" tag is in example.html. + +Also it can be done using regsvr32 application. +To do it please write +\System32\regsvr32 so_activex.dll + +To unregister the control please use /u option: +\system32\regsvr32 so_activex.dll /u + + diff --git a/extensions/source/activex/SOActionsApproval.cxx b/extensions/source/activex/SOActionsApproval.cxx new file mode 100644 index 000000000000..e0ce5c5da58e --- /dev/null +++ b/extensions/source/activex/SOActionsApproval.cxx @@ -0,0 +1,32 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// SOActionsApproval.cpp : Implementation of CHelpApp and DLL registration. + +#include "stdafx2.h" + +#include "so_activex.h" +#include "SOActionsApproval.h" +#include + +///////////////////////////////////////////////////////////////////////////// +// + +STDMETHODIMP SOActionsApproval::InterfaceSupportsErrorInfo(REFIID riid) +{ + static const IID* arr[] = + { + &IID_ISOActionsApproval, + }; + + for (int i=0;i= 1300) + if (InlineIsEqualGUID(*arr[i],riid)) +#else + if (::ATL::InlineIsEqualGUID(*arr[i],riid)) +#endif + return S_OK; + } + return S_FALSE; +} + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/SOActionsApproval.h b/extensions/source/activex/SOActionsApproval.h new file mode 100644 index 000000000000..a5570312864d --- /dev/null +++ b/extensions/source/activex/SOActionsApproval.h @@ -0,0 +1,83 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// SOActionsApproval.h: Definition of the SOActionsApproval class +// +////////////////////////////////////////////////////////////////////// + +#if !defined __SODOCUMENTEVENTLISTENER_H_ +#define __SODOCUMENTEVENTLISTENER_H_ + +#if _MSC_VER > 1000 +#pragma once +#endif // _MSC_VER > 1000 + +#include "resource.h" // main symbols +#include +#include +#include + +#if defined(_MSC_VER) && (_MSC_VER >= 1300) +#undef _DEBUG +#endif + +#include + +#include "so_activex.h" + +///////////////////////////////////////////////////////////////////////////// +// SOActionsApproval + +class SOActionsApproval : + public IDispatchImpl, + public ISupportErrorInfo, + public CComObjectRoot, + public CComCoClass +{ +public: + SOActionsApproval() {} + virtual ~SOActionsApproval() {} + +BEGIN_COM_MAP(SOActionsApproval) + COM_INTERFACE_ENTRY(IDispatch) + COM_INTERFACE_ENTRY(ISOActionsApproval) + COM_INTERFACE_ENTRY(ISupportErrorInfo) +END_COM_MAP() +DECLARE_NOT_AGGREGATABLE(SOActionsApproval) +// Remove the comment from the line above if you don't want your object to +// support aggregation. + +DECLARE_REGISTRY_RESOURCEID(IDR_SODOCUMENTEVENTLISTENER) + +// ISupportsErrorInfo + STDMETHOD(InterfaceSupportsErrorInfo)(REFIID riid); + +// ISOActionsApproval + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE approveAction( + /* [in] */ long nActionID, + /* [retval][out] */ boolean *pbApproval) + { + // only PreventClose is approved + USES_CONVERSION; + *pbApproval = ( nActionID == 1 ); + + return S_OK; + } + + virtual /* [helpstring][id][propget] */ HRESULT STDMETHODCALLTYPE get_Bridge_implementedInterfaces( + /* [retval][out] */ SAFEARRAY __RPC_FAR * __RPC_FAR *pVal) + { + *pVal = SafeArrayCreateVector( VT_BSTR, 0, 1 ); + + if( !*pVal ) + return E_FAIL; + + long ix = 0; + CComBSTR aInterface( OLESTR( "com.sun.star.embed.XActionsApproval" ) ); + SafeArrayPutElement( *pVal, &ix, aInterface ); + + return S_OK; + } +}; + +#endif // __SODOCUMENTEVENTLISTENER_H_ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/SOActionsApproval.rgs b/extensions/source/activex/SOActionsApproval.rgs new file mode 100644 index 000000000000..543320813948 --- /dev/null +++ b/extensions/source/activex/SOActionsApproval.rgs @@ -0,0 +1,24 @@ +HKCR +{ +9F3697AC-7A18-4335-AF0A-65FAC2C35CC1 + so_activex.SOActionsApproval.1 = s 'SOActionsApproval Class' + { + CLSID = s '{9F3697AC-7A18-4335-AF0A-65FAC2C35CC1}' + } + so_activex.SOActionsApproval = s 'SOActionsApproval Class' + { + CLSID = s '{9F3697AC-7A18-4335-AF0A-65FAC2C35CC1}' + } + NoRemove CLSID + { + ForceRemove {9F3697AC-7A18-4335-AF0A-65FAC2C35CC1} = s 'SOActionsApproval Class' + { + ProgID = s 'so_activex.SOActionsApproval.1' + VersionIndependentProgID = s 'so_activex.SOActionsApproval' + InprocServer32 = s '%MODULE%' + { + val ThreadingModel = s 'both' + } + } + } +} diff --git a/extensions/source/activex/SOActiveX.cxx b/extensions/source/activex/SOActiveX.cxx new file mode 100644 index 000000000000..f95e42772185 --- /dev/null +++ b/extensions/source/activex/SOActiveX.cxx @@ -0,0 +1,1153 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// SOActiveX.cpp : Implementation of CSOActiveX + +#pragma warning (disable:4505) + // permanently suppress "unreferenced local function has been removed" warning + +#pragma warning (push,1) +#pragma warning (disable:4265) + +#include "stdafx2.h" +#include "so_activex.h" +#include "SOActiveX.h" +#include "SOComWindowPeer.h" +#include "SODispatchInterceptor.h" +#include "SOActionsApproval.h" + +#pragma warning (pop) + +#define STAROFFICE_WINDOWCLASS "SOParentWindow" + + +///////////////////////////////////////////////////////////////////////////// + +void OutputError_Impl( HWND hw, HRESULT ErrorCode ) +{ + void* sMessage; + FormatMessageA( + FORMAT_MESSAGE_ALLOCATE_BUFFER | + FORMAT_MESSAGE_FROM_SYSTEM, + NULL, + ErrorCode, + MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), // Default language + (LPTSTR) &sMessage, + 0, + NULL + ); + ::MessageBoxA( hw, (LPCTSTR)sMessage, NULL, MB_OK | MB_ICONINFORMATION ); + LocalFree( sMessage ); +} + +HRESULT ExecuteFunc( IDispatch* idispUnoObject, + OLECHAR* sFuncName, + CComVariant* params, + unsigned int count, + CComVariant* pResult ) +{ + if( !idispUnoObject ) + return E_FAIL; + + DISPID id; + HRESULT hr = idispUnoObject->GetIDsOfNames( IID_NULL, &sFuncName, 1, LOCALE_USER_DEFAULT, &id); + if( !SUCCEEDED( hr ) ) return hr; + + DISPPARAMS dispparams= { params, 0, count, 0}; + + // DEBUG + EXCEPINFO myInfo; + hr = idispUnoObject->Invoke( id, IID_NULL,LOCALE_USER_DEFAULT, DISPATCH_METHOD, + &dispparams, pResult, &myInfo, 0); + + // for debugging purposes + // USES_CONVERSION; + // if ( !SUCCEEDED( hr ) ) + // ::MessageBox( NULL, OLE2A( myInfo.bstrDescription ), OLE2A( myInfo.bstrSource ), MB_OK | MB_ICONINFORMATION ); + + return hr; +} + +HRESULT GetIDispByFunc( IDispatch* idispUnoObject, + OLECHAR* sFuncName, + CComVariant* params, + unsigned int count, + CComPtr& pdispResult ) +{ + if( !idispUnoObject ) + return E_FAIL; + + CComVariant result; + HRESULT hr = ExecuteFunc( idispUnoObject, sFuncName, params, count, &result ); + if( !SUCCEEDED( hr ) ) return hr; + + if( result.vt != VT_DISPATCH || result.pdispVal == NULL ) + return E_FAIL; + + pdispResult = CComPtr( result.pdispVal ); + + return S_OK; +} + +HRESULT PutPropertiesToIDisp( IDispatch* pdispObject, + OLECHAR** sMemberNames, + CComVariant* pVariant, + unsigned int count ) +{ + for( unsigned int ind = 0; ind < count; ind++ ) + { + DISPID id; + HRESULT hr = pdispObject->GetIDsOfNames( IID_NULL, &sMemberNames[ind], 1, LOCALE_USER_DEFAULT, &id ); + if( !SUCCEEDED( hr ) ) return hr; + + hr = CComDispatchDriver::PutProperty( pdispObject, id, &pVariant[ind] ); + if( !SUCCEEDED( hr ) ) return hr; + } + + return S_OK; +} + +HRESULT GetPropertiesFromIDisp( IDispatch* pdispObject, + OLECHAR** sMemberNames, + CComVariant* pVariant, + unsigned int count ) +{ + for( unsigned int ind = 0; ind < count; ind++ ) + { + DISPID id; + HRESULT hr = pdispObject->GetIDsOfNames( IID_NULL, &sMemberNames[ind], 1, LOCALE_USER_DEFAULT, &id ); + if( !SUCCEEDED( hr ) ) return hr; + + hr = CComDispatchDriver::GetProperty( pdispObject, id, &pVariant[ind] ); + if( !SUCCEEDED( hr ) ) return hr; + } + + return S_OK; +} +///////////////////////////////////////////////////////////////////////////// +// CSOActiveX + +CSOActiveX::CSOActiveX() +: mCookie(0) +, mCurFileUrl( L"private:factory/swriter" ) +, mbLoad( FALSE ) +, mParentWin( NULL ) +, mOffWin( NULL ) +, mbViewOnly( TRUE ) +, mpDispatchInterceptor( NULL ) +, mnVersion( SO_NOT_DETECTED ) +, mbReadyForActivation( FALSE ) +, mbDrawLocked( FALSE ) +{ + CLSID clsFactory = {0x82154420,0x0FBF,0x11d4,{0x83, 0x13,0x00,0x50,0x04,0x52,0x6A,0xB4}}; + HRESULT hr = CoCreateInstance( clsFactory, NULL, CLSCTX_ALL, __uuidof(IDispatch), (void**)&mpDispFactory); + if( !SUCCEEDED( hr ) ) + OutputError_Impl( NULL, hr ); + + mPWinClass.style = CS_HREDRAW|CS_VREDRAW; + mPWinClass.lpfnWndProc = ::DefWindowProc; + mPWinClass.cbClsExtra = 0; + mPWinClass.cbWndExtra = 0; + mPWinClass.hInstance = (HINSTANCE) GetModuleHandle(NULL); //myInstance; + mPWinClass.hIcon = NULL; + mPWinClass.hCursor = NULL; + mPWinClass.hbrBackground = (HBRUSH) COLOR_BACKGROUND; + mPWinClass.lpszMenuName = NULL; + mPWinClass.lpszClassName = STAROFFICE_WINDOWCLASS; + + RegisterClass(&mPWinClass); +} + +CSOActiveX::~CSOActiveX() +{ + Cleanup(); + +} + +HRESULT CSOActiveX::Cleanup() +{ + CComVariant dummyResult; + + if( mpDispatchInterceptor ) + { + if( mpDispFrame ) + { + // remove dispatch interceptor + CComQIPtr< IDispatch, &IID_IDispatch > pIDispDispInter( mpDispatchInterceptor ); + CComVariant aVariant( pIDispDispInter ); + ExecuteFunc( mpDispFrame, + L"releaseDispatchProviderInterceptor", + &aVariant, + 1, + &dummyResult ); + } + + mpDispatchInterceptor->ClearParent(); + mpDispatchInterceptor->Release(); + mpDispatchInterceptor = NULL; + } + + mpDispTempFile = CComPtr< IDispatch >(); + mbReadyForActivation = FALSE; + + if( mpInstanceLocker ) + { + ExecuteFunc( mpInstanceLocker, L"dispose", NULL, 0, &dummyResult ); + mpInstanceLocker = CComPtr< IDispatch >(); + } + + if( mpDispFrame ) + { + BOOL bCloserActivated = FALSE; + + CComPtr pDispDocumentCloser; + CComVariant aDocCloser( L"com.sun.star.embed.DocumentCloser" ); + HRESULT hr = GetIDispByFunc( mpDispFactory, + L"createInstance", + &aDocCloser, + 1, + pDispDocumentCloser ); + if ( SUCCEEDED( hr ) && pDispDocumentCloser ) + { + SAFEARRAY FAR* pInitFrame = SafeArrayCreateVector( VT_VARIANT, 0, 1 ); + long nInitInd = 0; + CComVariant pFrameVariant( mpDispFrame ); + SafeArrayPutElement( pInitFrame, &nInitInd, &pFrameVariant ); + CComVariant aVarInitFrame; + aVarInitFrame.vt = VT_ARRAY | VT_VARIANT; aVarInitFrame.parray = pInitFrame; + hr = ExecuteFunc( pDispDocumentCloser, L"initialize", &aVarInitFrame, 1, &dummyResult ); + if( SUCCEEDED( hr ) ) + { + // the following call will let the closing happen + hr = ExecuteFunc( pDispDocumentCloser, L"dispose", NULL, 0, &dummyResult ); + bCloserActivated = SUCCEEDED( hr ); + } + } + + if ( !bCloserActivated ) + { + CComVariant aPropVar; + aPropVar.vt = VT_BOOL; aPropVar.boolVal = VARIANT_TRUE; + if ( !SUCCEEDED( ExecuteFunc( mpDispFrame, L"close", &aPropVar, 1, &dummyResult ) ) ) + ExecuteFunc( mpDispFrame, L"dispose", NULL, 0, &dummyResult ); + } + + mpDispFrame = CComPtr< IDispatch >(); + } + + if( ::IsWindow( mOffWin ) ) + ::DestroyWindow( mOffWin ); + + TerminateOffice(); + + return S_OK; +} + +HRESULT CSOActiveX::TerminateOffice() +{ + // create desktop + CComPtr pdispDesktop; + CComVariant aDesktopServiceName( L"com.sun.star.frame.Desktop" ); + + HRESULT hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aDesktopServiceName, 1, pdispDesktop ); + if( !pdispDesktop || !SUCCEEDED( hr ) ) return hr; + + // create tree of frames + CComPtr pdispChildren; + hr = GetIDispByFunc( pdispDesktop, L"getFrames", NULL, 0, pdispChildren ); + if( !pdispChildren || !SUCCEEDED( hr ) ) return hr; + + CComVariant aFrames; + CComVariant nFlag( 4 ); + hr = ExecuteFunc( pdispChildren, L"queryFrames", &nFlag, 1, &aFrames ); + if ( SUCCEEDED( hr ) ) + { + if ( ( aFrames.vt == ( VT_ARRAY | VT_DISPATCH ) || aFrames.vt == ( VT_ARRAY | VT_VARIANT ) ) + && ( !aFrames.parray || aFrames.parray->cDims == 1 && aFrames.parray->rgsabound[0].cElements == 0 ) ) + { + // there is no frames open + // TODO: check whether the frames are hidden if they are open? + CComVariant dummyResult; + hr = ExecuteFunc( pdispDesktop, L"terminate", NULL, 0, &dummyResult ); + } + } + + return hr; +} + +STDMETHODIMP CSOActiveX::InitNew () +{ + mnVersion = GetVersionConnected(); + mbLoad = TRUE; + return S_OK; +} + +STDMETHODIMP CSOActiveX::Load ( LPSTREAM /*pStm*/ ) +{ + mnVersion = GetVersionConnected(); + mbLoad = TRUE; + + // may be later? + // for now just ignore + + return S_OK; +} + +STDMETHODIMP CSOActiveX::Load( LPPROPERTYBAG pPropBag, LPERRORLOG /*pErrorLog*/ ) +{ + mnVersion = GetVersionConnected(); + + IPropertyBag2* pPropBag2; + HRESULT hr = pPropBag->QueryInterface( IID_IPropertyBag2, (void**)&pPropBag2 ); + //ATLASSERT( hr >= 0 ); + + if( !SUCCEEDED( hr ) ) + return hr; + + unsigned long aNum; + hr = pPropBag2->CountProperties( &aNum ); + //ATLASSERT( hr >= 0 ); + if( !SUCCEEDED( hr ) ) + return hr; + + PROPBAG2* aPropNames = new PROPBAG2[aNum]; + unsigned long aReaded; + + hr = pPropBag2->GetPropertyInfo( 0, + aNum, + aPropNames, + &aReaded ); + //ATLASSERT( hr >= 0 ); + if( !SUCCEEDED( hr ) ) + { + delete[] aPropNames; + return hr; + } + + CComVariant* aVal = new CComVariant[aNum]; + HRESULT* hvs = new HRESULT[aNum]; + hr = pPropBag2->Read( aNum, + aPropNames, + NULL, + aVal, + hvs ); + //ATLASSERT( hr >= 0 ); + if( !SUCCEEDED( hr ) ) + { + delete[] hvs; + delete[] aVal; + delete[] aPropNames; + return hr; + } + + USES_CONVERSION; + for( unsigned long ind = 0; ind < aNum; ind++ ) + { + // all information from the 'object' tag is in strings + if( aVal[ind].vt == VT_BSTR && !strcmp( OLE2T( aPropNames[ind].pstrName ), "src" ) ) + { + mCurFileUrl = wcsdup( aVal[ind].bstrVal ); + } + else if( aVal[ind].vt == VT_BSTR + && !strcmp( OLE2T( aPropNames[ind].pstrName ), "readonly" ) ) + { + if( !strcmp( OLE2T( aVal[ind].bstrVal ), "true" ) ) + { + // the default value + mbViewOnly = TRUE; + } + else + { + mbViewOnly = FALSE; + } + } + } + + delete[] hvs; + delete[] aVal; + delete[] aPropNames; + + if( !mpDispFactory ) + return hr; + + mbReadyForActivation = FALSE; + hr = CBindStatusCallback::Download( this, &CSOActiveX::CallbackCreateXInputStream, mCurFileUrl, m_spClientSite, FALSE ); + if ( hr == MK_S_ASYNCHRONOUS ) + hr = S_OK; + + if ( !SUCCEEDED( hr ) ) + { + // trigger initialization without stream + mbLoad = TRUE; + + Invalidate(); + UpdateWindow(); + } + + return hr; +} + +HRESULT CSOActiveX::GetUnoStruct( OLECHAR* sStructName, CComPtr& pdispResult ) +{ + CComVariant aComStruct( sStructName ); + return GetIDispByFunc( mpDispFactory, L"Bridge_GetStruct", &aComStruct, 1, pdispResult ); +} + +HRESULT CSOActiveX::GetUrlStruct( OLECHAR* sUrl, CComPtr& pdispUrl ) +{ + HRESULT hr = GetUnoStruct( L"com.sun.star.util.URL", pdispUrl ); + if( !SUCCEEDED( hr ) ) return hr; + + OLECHAR* sURLMemberName = L"Complete"; + DISPID nURLID; + hr = pdispUrl->GetIDsOfNames( IID_NULL, &sURLMemberName, 1, LOCALE_USER_DEFAULT, &nURLID ); + if( !SUCCEEDED( hr ) ) return hr; + CComVariant aComUrl( sUrl ); + hr = CComDispatchDriver::PutProperty( pdispUrl, nURLID, &aComUrl ); + if( !SUCCEEDED( hr ) ) return hr; + + CComPtr pdispTransformer; + CComVariant aServiceName( L"com.sun.star.util.URLTransformer" ); + hr = GetIDispByFunc( mpDispFactory, + L"createInstance", + &aServiceName, + 1, + pdispTransformer ); + if( !SUCCEEDED( hr ) ) return hr; + + CComVariant dummyResult; + CComVariant aParam[2]; + aParam[1].ppdispVal = &pdispUrl; + aParam[1].vt = VT_DISPATCH | VT_BYREF; + aParam[0] = CComVariant( L"file:///" ); + + hr = ExecuteFunc( pdispTransformer, L"parseSmart", aParam, 2, &dummyResult ); + if( !SUCCEEDED( hr ) || dummyResult.vt != VT_BOOL || !dummyResult.boolVal ) return hr; + + return S_OK; +} + +HRESULT CSOActiveX::SetLayoutManagerProps() +{ + if ( !mpDispFrame ) + return E_FAIL; + + CComVariant pVarLayoutMgr; + OLECHAR* sLMPropName = L"LayoutManager"; + HRESULT hr = GetPropertiesFromIDisp( mpDispFrame, &sLMPropName, &pVarLayoutMgr, 1 ); + if( pVarLayoutMgr.vt != VT_DISPATCH || pVarLayoutMgr.pdispVal == NULL ) + return E_FAIL; + + CComPtr pdispLM( pVarLayoutMgr.pdispVal ); + + + if( !SUCCEEDED( hr ) || !pdispLM ) + return E_FAIL; + + OLECHAR* sATName = L"AutomaticToolbars"; + CComVariant pATProp; + pATProp.vt = VT_BOOL; pATProp.boolVal = VARIANT_FALSE ; + hr = PutPropertiesToIDisp( pdispLM, &sATName, &pATProp, 1 ); + + return hr; +} + +HRESULT CSOActiveX::CreateFrameOldWay( HWND hwnd, int width, int height ) +{ + if( !mpDispFactory ) + return E_FAIL; + + // create window handle holder + CComPtr< CComObject< SOComWindowPeer > > pPeerToSend = new CComObject(); + pPeerToSend->SetHWNDInternally( hwnd ); + CComQIPtr< IDispatch, &IID_IDispatch > pIDispToSend( pPeerToSend ); + + // create rectangle structure + CComPtr pdispRectangle; + HRESULT hr = GetUnoStruct( L"com.sun.star.awt.Rectangle", pdispRectangle ); + if( !SUCCEEDED( hr ) ) return hr; + + OLECHAR* sRectMemberNames[4] = { L"X", + L"Y", + L"Width", + L"Height" }; + CComVariant pRectVariant[4]; + pRectVariant[0] = pRectVariant[1] = pRectVariant[2] = pRectVariant[3] = CComVariant( 0 ); + + hr = PutPropertiesToIDisp( pdispRectangle, sRectMemberNames, pRectVariant, 4 ); + if( !SUCCEEDED( hr ) ) return hr; + + // create WindowDescriptor structure + CComPtr pdispWinDescr; + hr = GetUnoStruct( L"com.sun.star.awt.WindowDescriptor", pdispWinDescr ); + if( !SUCCEEDED( hr ) ) return hr; + + // fill in descriptor with info + OLECHAR* sDescriptorMemberNames[6] = { L"Type", + L"WindowServiceName", + L"ParentIndex", + L"Parent", + L"Bounds", + L"WindowAttributes" }; + CComVariant pDescriptorVar[6]; + pDescriptorVar[0] = CComVariant( 0 ); + pDescriptorVar[1] = CComVariant( L"workwindow" ); + pDescriptorVar[2] = CComVariant( 1 ); + pDescriptorVar[3] = CComVariant( pIDispToSend ); + pDescriptorVar[4] = CComVariant( pdispRectangle ); + pDescriptorVar[5] = CComVariant( 33 ); + hr = PutPropertiesToIDisp( pdispWinDescr, sDescriptorMemberNames, pDescriptorVar, 6 ); + if( !SUCCEEDED( hr ) ) return hr; + + // create XToolkit instance + CComPtr pdispToolkit; + CComVariant aServiceName( L"com.sun.star.awt.Toolkit" ); + hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aServiceName, 1, pdispToolkit ); + if( !SUCCEEDED( hr ) ) return hr; + + // create window with toolkit + CComVariant aWinDescr( pdispWinDescr ); + hr = GetIDispByFunc( pdispToolkit, L"createWindow", &aWinDescr, 1, mpDispWin ); + if( !SUCCEEDED( hr ) ) return hr; + + // create frame + aServiceName = CComVariant( L"com.sun.star.frame.Task" ); + hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aServiceName, 1, mpDispFrame ); + if( !SUCCEEDED( hr ) || !mpDispFrame ) + { + // the interface com.sun.star.frame.Task is removed in 6.1 + // but the interface com.sun.star.frame.Frame has some bugs in 6.0 + aServiceName = CComVariant( L"com.sun.star.frame.Frame" ); + hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aServiceName, 1, mpDispFrame ); + if( !SUCCEEDED( hr ) ) return hr; + } + + // initialize frame + CComVariant dummyResult; + CComVariant aDispWin( mpDispWin ); + hr = ExecuteFunc( mpDispFrame, L"initialize", &aDispWin, 1, &dummyResult ); + if( !SUCCEEDED( hr ) ) return hr; + + // set some properties to the layout manager, ignore errors for now + SetLayoutManagerProps(); + + // create desktop + CComPtr pdispDesktop; + aServiceName = CComVariant( L"com.sun.star.frame.Desktop" ); + hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aServiceName, 1, pdispDesktop ); + if( !SUCCEEDED( hr ) ) return hr; + + // create tree of frames + CComPtr pdispChildren; + hr = GetIDispByFunc( pdispDesktop, L"getFrames", NULL, 0, pdispChildren ); + if( !SUCCEEDED( hr ) ) return hr; + + // insert new frame into desctop hierarchy + CComVariant aDispFrame( mpDispFrame ); + hr = ExecuteFunc( pdispChildren, L"append", &aDispFrame, 1, &dummyResult ); + if( !SUCCEEDED( hr ) ) return hr; + + // initialize window + CComVariant aTransparent( (long)0xFFFFFFFF ); + hr = ExecuteFunc( mpDispWin, L"setBackground", &aTransparent, 1, &dummyResult ); + if( !SUCCEEDED( hr ) ) return hr; + + CComVariant aTrue( TRUE ); + hr = ExecuteFunc( mpDispWin, L"setVisible", &aTrue, 1, &dummyResult ); + if( !SUCCEEDED( hr ) ) return hr; + + CComVariant aPosArgs[5]; + aPosArgs[4] = CComVariant( 0 ); + aPosArgs[3] = CComVariant( 0 ); + aPosArgs[2] = CComVariant( width ); + aPosArgs[1] = CComVariant( height ); + aPosArgs[0] = CComVariant( 12 ); + hr = ExecuteFunc( mpDispWin, L"setPosSize", aPosArgs, 5, &dummyResult ); + if( !SUCCEEDED( hr ) ) return hr; + + // create frame locker if there is such service + aServiceName = CComVariant( L"com.sun.star.embed.InstanceLocker" ); + hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aServiceName, 1, mpInstanceLocker ); + if( SUCCEEDED( hr ) && mpInstanceLocker ) + { + SAFEARRAY FAR* pInitVals = SafeArrayCreateVector( VT_VARIANT, 0, 3 ); + + // the first sequence element + long nInitInd = 0; + CComVariant pFrameVariant( mpDispFrame ); + SafeArrayPutElement( pInitVals, &nInitInd, &pFrameVariant ); + + // the second sequence element + nInitInd = 1; + CComVariant pStrArr( 1L ); + SafeArrayPutElement( pInitVals, &nInitInd, &pStrArr ); + + // the third sequence element + nInitInd = 2; + CComPtr pdispValueObj; + hr = GetIDispByFunc( mpDispFactory, L"Bridge_GetValueObject", NULL, 0, pdispValueObj ); + if( !SUCCEEDED( hr ) || !pdispValueObj ) return hr; + + CComVariant aValueArgs[2]; + aValueArgs[1] = CComVariant( L"com.sun.star.embed.XActionsApproval" ); + CComPtr< CComObject< SOActionsApproval > > pApproval( new CComObject() ); + aValueArgs[0] = CComVariant ( pApproval ); + + hr = ExecuteFunc( pdispValueObj, L"Set", aValueArgs, 2, &dummyResult ); + if( !SUCCEEDED( hr ) ) return hr; + + CComVariant aValueObj( pdispValueObj ); + SafeArrayPutElement( pInitVals, &nInitInd, &aValueObj ); + + // execute initialize() + CComVariant aVarInitVals; + aVarInitVals.vt = VT_ARRAY | VT_VARIANT; aVarInitVals.parray = pInitVals; + hr = ExecuteFunc( mpInstanceLocker, L"initialize", &aVarInitVals, 1, &dummyResult ); + if( !SUCCEEDED( hr ) ) return hr; + } + + return S_OK; +} + +HRESULT CSOActiveX::CallLoadComponentFromURL1PBool( OLECHAR* sUrl, OLECHAR* sArgName, BOOL sArgVal ) +{ + SAFEARRAY FAR* pPropVals = SafeArrayCreateVector( VT_DISPATCH, 0, 1 ); + long ix = 0; + CComPtr pdispPropVal; + HRESULT hr = GetUnoStruct( L"com.sun.star.beans.PropertyValue", pdispPropVal ); + if( !SUCCEEDED( hr ) ) return hr; + + OLECHAR* sPropMemberNames[2] = { L"Name", L"Value" }; + CComVariant pPropVar[2]; + pPropVar[0] = CComVariant( sArgName ); + pPropVar[1].vt = VT_BOOL; pPropVar[1].boolVal = sArgVal ? VARIANT_TRUE : VARIANT_FALSE ; + hr = PutPropertiesToIDisp( pdispPropVal, sPropMemberNames, pPropVar, 2 ); + if( !SUCCEEDED( hr ) ) return hr; + + SafeArrayPutElement( pPropVals, &ix, pdispPropVal ); + + CComVariant aDispArgs[4]; + aDispArgs[3] = CComVariant( sUrl ); + aDispArgs[2] = CComVariant( L"_self" ); + aDispArgs[1] = CComVariant( 0 ); + // aDispArgs[0] = CComVariant( pPropVals ); such constructor is not defined ??! + aDispArgs[0].vt = VT_ARRAY | VT_DISPATCH; aDispArgs[0].parray = pPropVals; + + CComVariant dummyResult; + hr = ExecuteFunc( mpDispFrame, L"loadComponentFromURL", aDispArgs, 4, &dummyResult ); + if( !SUCCEEDED( hr ) ) return hr; + + return S_OK; +} + +HRESULT CSOActiveX::CallDispatchMethod( OLECHAR* sUrl, + CComVariant* aArgNames, + CComVariant* aArgVals, + unsigned int count ) +{ + CComPtr pdispURL; + HRESULT hr = GetUrlStruct( sUrl, pdispURL ); + if( !SUCCEEDED( hr ) ) return hr; + + CComPtr pdispXDispatch; + CComVariant aArgs[3]; + aArgs[2] = CComVariant( pdispURL ); + aArgs[1] = CComVariant( L"" ); + aArgs[0] = CComVariant( (int)0 ); + hr = GetIDispByFunc( mpDispFrame, + L"queryDispatch", + aArgs, + 3, + pdispXDispatch ); + if( !SUCCEEDED( hr ) ) return hr; + + SAFEARRAY FAR* pPropVals = SafeArrayCreateVector( VT_DISPATCH, 0, count ); + for( long ix = 0; ix < (long)count; ix ++ ) + { + CComPtr pdispPropVal; + hr = GetUnoStruct( L"com.sun.star.beans.PropertyValue", pdispPropVal ); + if( !SUCCEEDED( hr ) ) return hr; + + OLECHAR* sPropMemberNames[2] = { L"Name", L"Value" }; + CComVariant pPropVar[2]; + pPropVar[0] = aArgNames[ix]; + pPropVar[1] = aArgVals[ix]; + hr = PutPropertiesToIDisp( pdispPropVal, sPropMemberNames, pPropVar, 2 ); + if( !SUCCEEDED( hr ) ) return hr; + + SafeArrayPutElement( pPropVals, &ix, pdispPropVal ); + } + + CComVariant aDispArgs[2]; + aDispArgs[1] = CComVariant( pdispURL ); + // aDispArgs[0] = CComVariant( pPropVals ); such constructor is not defined ??! + aDispArgs[0].vt = VT_ARRAY | VT_DISPATCH; aDispArgs[0].parray = pPropVals; + + CComVariant dummyResult; + hr = ExecuteFunc( pdispXDispatch, L"dispatch", aDispArgs, 2, &dummyResult ); + if( !SUCCEEDED( hr ) ) return hr; + + return S_OK; +} + +void CSOActiveX::CallbackCreateXInputStream( CBindStatusCallback* /*pbsc*/, BYTE* pBytes, DWORD dwSize ) +{ + if ( mbReadyForActivation ) + return; + + BOOL bSuccess = FALSE; + BOOL bFinishDownload = FALSE; + if ( !pBytes ) + { + // means the download is finished, dwSize contains hresult + bFinishDownload = TRUE; + if ( SUCCEEDED( dwSize ) ) + bSuccess = TRUE; + } + else + { + HRESULT hr = S_OK; + + if ( !mpDispTempFile ) + { + CComVariant aServiceName( L"com.sun.star.io.TempFile" ); + hr = GetIDispByFunc( mpDispFactory, + L"createInstance", + &aServiceName, + 1, + mpDispTempFile ); + } + + if( SUCCEEDED( hr ) && mpDispTempFile ) + { + SAFEARRAY FAR* pDataArray = SafeArrayCreateVector( VT_I1, 0, dwSize ); + + if ( pDataArray ) + { + hr = SafeArrayLock( pDataArray ); + if ( SUCCEEDED( hr ) ) + { + for( DWORD ix = 0; ix < dwSize; ix++ ) + ((BYTE*)(pDataArray->pvData))[ix] = pBytes[ix]; + hr = SafeArrayUnlock( pDataArray ); + if ( SUCCEEDED( hr ) ) + { + CComVariant aArgs[1]; + aArgs[0].vt = VT_ARRAY | VT_I1; aArgs[0].parray = pDataArray; + CComVariant dummyResult; + hr = ExecuteFunc( mpDispTempFile, L"writeBytes", aArgs, 1, &dummyResult ); + if( SUCCEEDED( hr ) ) + bSuccess = TRUE; + } + } + } + } + } + + if ( !bSuccess ) + { + // the download failed, let StarOffice download + bFinishDownload = TRUE; + mpDispTempFile = CComPtr< IDispatch >(); + } + + if ( bFinishDownload ) + { + // trigger the loading now + mbLoad = TRUE; + mbReadyForActivation = TRUE; + + Invalidate(); + UpdateWindow(); + } +} + +HRESULT CSOActiveX::LoadURLToFrame( ) +{ + CComVariant aArgNames[4] = { L"ReadOnly", L"ViewOnly", L"AsTemplate", L"InputStream" }; + CComVariant aArgVals[4]; + unsigned int nCount = 3; // the 4-th argument is used only if the stream can be retrieved + + aArgVals[0].vt = VT_BOOL; aArgVals[0].boolVal = mbViewOnly ? VARIANT_TRUE : VARIANT_FALSE; + aArgVals[1].vt = VT_BOOL; aArgVals[1].boolVal = mbViewOnly ? VARIANT_TRUE : VARIANT_FALSE; + aArgVals[2].vt = VT_BOOL; aArgVals[2].boolVal = VARIANT_FALSE; + + if ( mpDispTempFile ) + { + aArgVals[3] = CComVariant( mpDispTempFile ); + nCount = 4; + } + + HRESULT hr = CallDispatchMethod( mCurFileUrl, aArgNames, aArgVals, nCount ); + if( !SUCCEEDED( hr ) ) return hr; + + CComVariant aBarName( L"MenuBarVisible" ); + CComVariant aBarVis; + aBarVis.vt = VT_BOOL; aBarVis.boolVal = VARIANT_FALSE; + hr = CallDispatchMethod( L"slot:6661", &aBarName, &aBarVis, 1 ); + // does not work for some documents, but it is no error + // if( !SUCCEEDED( hr ) ) return hr; + + // try to get the model and set the presetation specific property, the setting will fail for other document formats + CComPtr pdispController; + hr = GetIDispByFunc( mpDispFrame, L"getController", NULL, 0, pdispController ); + if ( SUCCEEDED( hr ) && pdispController ) + { + CComPtr pdispModel; + hr = GetIDispByFunc( pdispController, L"getModel", NULL, 0, pdispModel ); + if ( SUCCEEDED( hr ) && pdispModel ) + { + CComPtr pdispPres; + hr = GetIDispByFunc( pdispModel, L"getPresentation", NULL, 0, pdispPres ); + if ( SUCCEEDED( hr ) && pdispPres ) + { + // this is a presentation + // let the slide show be shown in the document window + OLECHAR* pPropName = L"IsFullScreen"; + CComVariant pPresProp; + pPresProp.vt = VT_BOOL; pPresProp.boolVal = VARIANT_FALSE ; + hr = PutPropertiesToIDisp( pdispPres, &pPropName, &pPresProp, 1 ); + + // start the slide show + if ( SUCCEEDED( hr ) ) + { + CComVariant dummyResult; + ExecuteFunc( pdispPres, L"Start", NULL, 0, &dummyResult ); + } + } + } + } + + // create dispatch interceptor + mpDispatchInterceptor = new CComObject< SODispatchInterceptor >(); + mpDispatchInterceptor->AddRef(); + mpDispatchInterceptor->SetParent( this ); + CComQIPtr< IDispatch, &IID_IDispatch > pIDispDispInter( mpDispatchInterceptor ); + + // register dispatch interceptor in the frame + CComVariant aDispVariant( pIDispDispInter ); + CComVariant dummyResult; + hr = ExecuteFunc( mpDispFrame, + L"registerDispatchProviderInterceptor", + &aDispVariant, + 1, + &dummyResult ); + + if( !SUCCEEDED( hr ) ) return hr; + + return S_OK; +} + +SOVersion CSOActiveX::GetVersionConnected() +{ + SOVersion bResult = SO_NOT_DETECTED; + if( mpDispFactory ) + { + // create ConfigurationProvider instance + CComPtr pdispConfProv; + CComVariant aServiceName( L"com.sun.star.configuration.ConfigurationProvider" ); + HRESULT hr = GetIDispByFunc( mpDispFactory, + L"createInstance", + &aServiceName, + 1, + pdispConfProv ); + + if( SUCCEEDED( hr ) && pdispConfProv ) + { + CComPtr pdispConfAccess; + + SAFEARRAY* pInitParams = SafeArrayCreateVector( VT_VARIANT, 0, 1 ); + + if( pInitParams ) + { + long ix = 0; + CComVariant aConfPath( L"org.openoffice.Setup" ); + SafeArrayPutElement( pInitParams, &ix, &aConfPath ); + + CComVariant aArgs[2]; + aArgs[1] = CComVariant( L"com.sun.star.configuration.ConfigurationAccess" ); + aArgs[0].vt = VT_ARRAY | VT_VARIANT; aArgs[0].parray = pInitParams; + + hr = GetIDispByFunc( pdispConfProv, + L"createInstanceWithArguments", + aArgs, + 2, + pdispConfAccess ); + + if( SUCCEEDED( hr ) && pdispConfAccess ) + { + CComVariant aOfficeName; + + CComVariant aProductName( L"Product/ooName" ); + hr = ExecuteFunc( pdispConfAccess, + L"getByHierarchicalName", + &aProductName, + 1, + &aOfficeName ); + + if( SUCCEEDED( hr ) && aOfficeName.vt == VT_BSTR ) + { + CComVariant aOfficeVersion; + + CComVariant aProductVersion( L"Product/ooSetupVersion" ); + hr = ExecuteFunc( pdispConfAccess, + L"getByHierarchicalName", + &aProductVersion, + 1, + &aOfficeVersion ); + + if( SUCCEEDED( hr ) && aOfficeVersion.vt == VT_BSTR ) + { + USES_CONVERSION; + if( !strcmp( OLE2T( aOfficeName.bstrVal ), "StarOffice" ) ) + { + if( !strncmp( OLE2T( aOfficeVersion.bstrVal ), "6.1", 3 ) ) + bResult = SO_61; + else if( !strncmp( OLE2T( aOfficeVersion.bstrVal ), "6.0", 3 ) ) + bResult = SO_60; + else if( !strncmp( OLE2T( aOfficeVersion.bstrVal ), "5.2", 3 ) ) + bResult = SO_52; + else + bResult = SO_UNKNOWN; + } + else // OpenOffice + { + if( !strncmp( OLE2T( aOfficeVersion.bstrVal ), "1.1", 3 ) ) + bResult = OO_11; + else if( !strncmp( OLE2T( aOfficeVersion.bstrVal ), "1.0", 3 ) ) + bResult = OO_10; + else + bResult = OO_UNKNOWN; + } + } + } + } + } + } + } + + return bResult; +} + +class LockingGuard +{ + BOOL& mbLocked; +public: + LockingGuard( BOOL& bLocked ) + : mbLocked( bLocked ) + { + mbLocked = TRUE; + } + + ~LockingGuard() + { + mbLocked = FALSE; + } +}; + +HRESULT CSOActiveX::OnDrawAdvanced( ATL_DRAWINFO& di ) +{ + // This method is called only in main thread, no need to lock it + + // Get read of reentrance problems + if ( mbDrawLocked ) + return S_OK; + LockingGuard aGuard( mbDrawLocked ); + + if( m_spInPlaceSite && mCurFileUrl && mbReadyForActivation ) + { + HWND hwnd; + HRESULT hr = m_spInPlaceSite->GetWindow( &hwnd ); + if( !SUCCEEDED( hr ) ) return hr; + + if( mParentWin != hwnd || !mOffWin ) + { + if( mpDispFrame ) + { + CComVariant dummyResult; + CComVariant aPropVar; + aPropVar.vt = VT_BOOL; aPropVar.boolVal = VARIANT_FALSE; + HRESULT hr = ExecuteFunc( mpDispFrame, L"close", &aPropVar, 1, &dummyResult ); + (void)hr; + mpDispFrame = CComPtr(); + } + + mParentWin = hwnd; + mOffWin = CreateWindow( + STAROFFICE_WINDOWCLASS, + "OfficeContainer", + WS_CHILD | WS_CLIPCHILDREN | WS_BORDER, + di.prcBounds->left, + di.prcBounds->top, + di.prcBounds->right - di.prcBounds->left, + di.prcBounds->bottom - di.prcBounds->top, + mParentWin, + NULL, + NULL, + NULL ); + + ::ShowWindow( mOffWin, SW_SHOW ); + } + else + { + RECT aRect; + ::GetWindowRect( mOffWin, &aRect ); + + if( aRect.left != di.prcBounds->left || aRect.top != di.prcBounds->top + || aRect.right != di.prcBounds->right || aRect.bottom != di.prcBounds->bottom ) + { + // on this state the office window should exist already + ::SetWindowPos( mOffWin, + HWND_TOP, + di.prcBounds->left, + di.prcBounds->top, + di.prcBounds->right - di.prcBounds->left, + di.prcBounds->bottom - di.prcBounds->top, + SWP_NOZORDER ); + + CComVariant aPosArgs[5]; + aPosArgs[4] = CComVariant( 0 ); + aPosArgs[3] = CComVariant( 0 ); + aPosArgs[2] = CComVariant( int(di.prcBounds->right - di.prcBounds->left) ); + aPosArgs[1] = CComVariant( int(di.prcBounds->bottom - di.prcBounds->top) ); + aPosArgs[0] = CComVariant( 12 ); + CComVariant dummyResult; + hr = ExecuteFunc( mpDispWin, L"setPosSize", aPosArgs, 5, &dummyResult ); + if( !SUCCEEDED( hr ) ) return hr; + } + } + + if( !mnVersion ) + { + OutputError_Impl( mOffWin, CS_E_INVALID_VERSION ); + return E_FAIL; + } + + if( ! mpDispFrame ) + { + hr = CreateFrameOldWay( mOffWin, + di.prcBounds->right - di.prcBounds->left, + di.prcBounds->bottom - di.prcBounds->top ); + + if( !SUCCEEDED( hr ) ) + { + // if the frame can not be opened do not try any more + mbReadyForActivation = FALSE; + OutputError_Impl( mOffWin, STG_E_ABNORMALAPIEXIT ); + return hr; + } + } + + if( mbLoad ) + { + hr = LoadURLToFrame(); + mbLoad = FALSE; + + if( !SUCCEEDED( hr ) ) + { + // if the document can not be opened do not try any more + mbReadyForActivation = FALSE; + + OutputError_Impl( mOffWin, STG_E_ABNORMALAPIEXIT ); + + return hr; + } + } + } + else + { + // activate the fallback + CComControl::OnDrawAdvanced( di ); + } + + return S_OK; +} + +HRESULT CSOActiveX::OnDraw( ATL_DRAWINFO& di ) +{ + // fallback that is activated by the parent class + if ( di.hdcDraw ) + FillRect( di.hdcDraw, (RECT*)di.prcBounds, (HBRUSH)COLOR_BACKGROUND ); + + return S_OK; +} + +STDMETHODIMP CSOActiveX::SetClientSite( IOleClientSite* aClientSite ) +{ + HRESULT hr = IOleObjectImpl::SetClientSite( aClientSite ); + + if( !aClientSite ) + { + //ATLASSERT( mWebBrowser2 ); + if( mWebBrowser2 ) + AtlUnadvise( mWebBrowser2, DIID_DWebBrowserEvents2, mCookie ); + return hr; + } + + CComPtr aContainer; + m_spClientSite->GetContainer( &aContainer ); +// ATLASSERT( aContainer ); + + if( SUCCEEDED( hr ) && aContainer ) + { + CComQIPtr aServiceProvider( aContainer ); + //ATLASSERT( aServiceProvider ); + + if( aServiceProvider ) + { + aServiceProvider->QueryService( SID_SInternetExplorer, + IID_IWebBrowser, + (void**)&mWebBrowser2 ); +// ATLASSERT( mWebBrowser2 ); + if( mWebBrowser2 ) + AtlAdvise( mWebBrowser2, GetUnknown(), DIID_DWebBrowserEvents2, &mCookie ); + } + } + + return hr; +} + +STDMETHODIMP CSOActiveX::Invoke(DISPID dispidMember, + REFIID riid, + LCID lcid, + WORD wFlags, + DISPPARAMS* pDispParams, + VARIANT* pvarResult, + EXCEPINFO* pExcepInfo, + UINT* puArgErr) +{ + if (riid != IID_NULL) + return DISP_E_UNKNOWNINTERFACE; + + if (!pDispParams) + return DISP_E_PARAMNOTOPTIONAL; + + if ( dispidMember == DISPID_ONQUIT ) + Cleanup(); + + IDispatchImpl::Invoke( + dispidMember, riid, lcid, wFlags, pDispParams, + pvarResult, pExcepInfo, puArgErr); + + return S_OK; +} + +HRESULT CSOActiveX::GetURL( const OLECHAR* url, + const OLECHAR* target ) +{ + CComVariant aEmpty1, aEmpty2, aEmpty3; + CComVariant aUrl( url ); + CComVariant aTarget; + if ( target ) + aTarget = CComVariant( target ); + + return mWebBrowser2->Navigate2( &aUrl, + &aEmpty1, + &aTarget, + &aEmpty2, + &aEmpty3 ); +} + + +// --------------------------------------------------------------------------- + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/SOActiveX.h b/extensions/source/activex/SOActiveX.h new file mode 100644 index 000000000000..fea95d09c9b9 --- /dev/null +++ b/extensions/source/activex/SOActiveX.h @@ -0,0 +1,178 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// SOActiveX.h : Declaration of the CSOActiveX + +#ifndef __SOACTIVEX_H_ +#define __SOACTIVEX_H_ + +#include "resource.h" // main symbols + +#pragma warning (disable:4505) + // permanently suppress "unreferenced local function has been removed" warning + +#pragma warning (push,1) +#pragma warning (disable:4265) + +#include +#include +#include + +#if defined(_MSC_VER) && (_MSC_VER >= 1300) +#undef _DEBUG +#endif +#include + +#include "so_activex.h" + +#pragma warning (pop) + +class SODispatchInterceptor; + +enum SOVersion { + SO_NOT_DETECTED = 0, + SO_52, + SO_60, + SO_61, + SO_UNKNOWN, + OO_10, + OO_11, + OO_UNKNOWN +}; + +///////////////////////////////////////////////////////////////////////////// +// CSOActiveX +class ATL_NO_VTABLE CSOActiveX : + public CComObjectRootEx, + public IDispatchImpl, + public CComControl, + public IPersistStreamInitImpl, + public IOleControlImpl, + public IOleObjectImpl, + public IOleInPlaceActiveObjectImpl, + public IViewObjectExImpl, + public IOleInPlaceObjectWindowlessImpl, +// public IConnectionPointContainerImpl, + public CComCoClass, +// public CProxy_ItryPluginEvents< CSOActiveX >, + public IPersistPropertyBagImpl< CSOActiveX >, + public IProvideClassInfo2Impl< &CLSID_SOActiveX, + &DIID__ISOActiveXEvents, + &LIBID_SO_ACTIVEXLib >, + public IObjectSafetyImpl< CSOActiveX, + INTERFACESAFE_FOR_UNTRUSTED_DATA > +{ +protected: + CComPtr mWebBrowser2; + DWORD mCookie; + + CComPtr mpDispFactory; + CComPtr mpDispFrame; + CComPtr mpInstanceLocker; + CComPtr mpDispWin; + OLECHAR* mCurFileUrl; + BOOL mbLoad; + BOOL mbViewOnly; + WNDCLASS mPWinClass; + HWND mParentWin; + HWND mOffWin; + + SODispatchInterceptor* mpDispatchInterceptor; + SOVersion mnVersion; + + BOOL mbReadyForActivation; + CComPtr mpDispTempFile; + + BOOL mbDrawLocked; + +public: + CSOActiveX(); + ~CSOActiveX(); + +DECLARE_REGISTRY_RESOURCEID(IDR_SOACTIVEX) + +DECLARE_PROTECT_FINAL_CONSTRUCT() + +BEGIN_COM_MAP(CSOActiveX) + COM_INTERFACE_ENTRY(ISOActiveX) + COM_INTERFACE_ENTRY(IDispatch) + COM_INTERFACE_ENTRY(IViewObjectEx) + COM_INTERFACE_ENTRY(IViewObject2) + COM_INTERFACE_ENTRY(IViewObject) + COM_INTERFACE_ENTRY(IOleInPlaceObjectWindowless) + COM_INTERFACE_ENTRY(IOleInPlaceObject) + COM_INTERFACE_ENTRY2(IOleWindow, IOleInPlaceObjectWindowless) + COM_INTERFACE_ENTRY(IOleInPlaceActiveObject) + COM_INTERFACE_ENTRY(IOleControl) + COM_INTERFACE_ENTRY(IOleObject) + COM_INTERFACE_ENTRY(IPersistStreamInit) + COM_INTERFACE_ENTRY2(IPersist, IPersistStreamInit) +// COM_INTERFACE_ENTRY(IConnectionPointContainer) + COM_INTERFACE_ENTRY(IProvideClassInfo) + COM_INTERFACE_ENTRY(IProvideClassInfo2) + COM_INTERFACE_ENTRY(IPersistPropertyBag) + COM_INTERFACE_ENTRY(IObjectSafety) +END_COM_MAP() + +BEGIN_PROP_MAP(CSOActiveX) + PROP_DATA_ENTRY("_cx", m_sizeExtent.cx, VT_UI4) + PROP_DATA_ENTRY("_cy", m_sizeExtent.cy, VT_UI4) + // Example entries + // PROP_ENTRY("Property Description", dispid, clsid) + // PROP_PAGE(CLSID_StockColorPage) +END_PROP_MAP() + +BEGIN_CONNECTION_POINT_MAP(CSOActiveX) +END_CONNECTION_POINT_MAP() + +BEGIN_MSG_MAP(CSOActiveX) + CHAIN_MSG_MAP(CComControl) + DEFAULT_REFLECTION_HANDLER() +END_MSG_MAP() +// Handler prototypes: +// LRESULT MessageHandler(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled); +// LRESULT CommandHandler(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled); +// LRESULT NotifyHandler(int idCtrl, LPNMHDR pnmh, BOOL& bHandled); + + + +// IViewObjectEx + DECLARE_VIEW_STATUS(VIEWSTATUS_SOLIDBKGND | VIEWSTATUS_OPAQUE) + +// ISOActiveX +public: + + STDMETHOD(SetClientSite)( IOleClientSite* aClientSite ); + STDMETHOD(Invoke)( DISPID dispidMember, + REFIID riid, + LCID lcid, + WORD wFlags, + DISPPARAMS* pDispParams, + VARIANT* pvarResult, + EXCEPINFO* pExcepInfo, + UINT* puArgErr); + STDMETHOD(Load) ( LPPROPERTYBAG pPropBag, LPERRORLOG pErrorLog ); + STDMETHOD(Load) ( LPSTREAM pStm ); + STDMETHOD(InitNew) (); + HRESULT OnDrawAdvanced(ATL_DRAWINFO& di); + HRESULT OnDraw(ATL_DRAWINFO& di); + + HRESULT SetLayoutManagerProps(); + HRESULT CreateFrameOldWay( HWND hwnd, int width, int height ); + HRESULT GetUnoStruct( OLECHAR* sStructName, CComPtr& pdispResult ); + HRESULT LoadURLToFrame(); + HRESULT CallDispatchMethod( OLECHAR* sUrl, CComVariant* sArgNames, CComVariant* sArgVal, unsigned int count ); + HRESULT CallLoadComponentFromURL1PBool( OLECHAR* sUrl, OLECHAR* sArgName, BOOL sArgVal ); + HRESULT GetUrlStruct( OLECHAR* sUrl, CComPtr& pdispUrl ); + HRESULT Cleanup(); + HRESULT TerminateOffice(); + HRESULT GetURL( const OLECHAR* url, + const OLECHAR* target ); + + void CallbackCreateXInputStream( CBindStatusCallback* pbsc, BYTE* pBytes, DWORD dwSize ); + + + SOVersion GetVersionConnected(); +}; + +#endif //__SOACTIVEX_H_ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/SOActiveX.rgs b/extensions/source/activex/SOActiveX.rgs new file mode 100644 index 000000000000..d3814df3b241 --- /dev/null +++ b/extensions/source/activex/SOActiveX.rgs @@ -0,0 +1,33 @@ +HKCR +{ + so_activex.SOActiveX.1 = s 'SOActiveX Class' + { + CLSID = s '{67F2A879-82D5-4A6D-8CC5-FFB3C114B69D}' + } + so_activex.SOActiveX = s 'SOActiveX Class' + { + CLSID = s '{67F2A879-82D5-4A6D-8CC5-FFB3C114B69D}' + CurVer = s 'so_activex.SOActiveX.1' + } + NoRemove CLSID + { + ForceRemove {67F2A879-82D5-4A6D-8CC5-FFB3C114B69D} = s 'SOActiveX Class' + { + ProgID = s 'so_activex.SOActiveX.1' + VersionIndependentProgID = s 'so_activex.SOActiveX' + ForceRemove 'Programmable' + InprocServer32 = s '%MODULE%' + { + val ThreadingModel = s 'Apartment' + } + ForceRemove 'Control' + ForceRemove 'ToolboxBitmap32' = s '%MODULE%, 101' + 'MiscStatus' = s '0' + { + '1' = s '131473' + } + 'TypeLib' = s '{61FA3F13-8061-4796-B055-3697ED28CB38}' + 'Version' = s '1.0' + } + } +} diff --git a/extensions/source/activex/SOComWindowPeer.cxx b/extensions/source/activex/SOComWindowPeer.cxx new file mode 100644 index 000000000000..7fb56dbdfd32 --- /dev/null +++ b/extensions/source/activex/SOComWindowPeer.cxx @@ -0,0 +1,31 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// SOComWindowPeer.cpp : Implementation of CHelpApp and DLL registration. + +#include "stdafx2.h" +#include "so_activex.h" +#include "SOComWindowPeer.h" +#include + +///////////////////////////////////////////////////////////////////////////// +// + +STDMETHODIMP SOComWindowPeer::InterfaceSupportsErrorInfo(REFIID riid) +{ + static const IID* arr[] = + { + &IID_ISOComWindowPeer, + }; + + for (int i=0;i= 1300) + if (InlineIsEqualGUID(*arr[i],riid)) +#else + if (::ATL::InlineIsEqualGUID(*arr[i],riid)) +#endif + return S_OK; + } + return S_FALSE; +} + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/SOComWindowPeer.h b/extensions/source/activex/SOComWindowPeer.h new file mode 100644 index 000000000000..c819e17a81ea --- /dev/null +++ b/extensions/source/activex/SOComWindowPeer.h @@ -0,0 +1,136 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// SOComWindowPeer.h: Definition of the SOComWindowPeer class +// +////////////////////////////////////////////////////////////////////// + +#if !defined __SOCOMWINDOWPEER_H_ +#define __SOCOMWINDOWPEER_H_ + +#if _MSC_VER > 1000 +#pragma once +#endif // _MSC_VER > 1000 + +#include "resource.h" // main symbols +#include +#include +#include + +#if defined(_MSC_VER) && (_MSC_VER >= 1300) +#undef _DEBUG +#endif +#include + +#include "so_activex.h" + +///////////////////////////////////////////////////////////////////////////// +// SOComWindowPeer + +class SOComWindowPeer : + public IDispatchImpl, + public ISupportErrorInfo, + public CComObjectRoot, + public CComCoClass +{ + HWND m_hwnd; +public: + SOComWindowPeer() : m_hwnd( NULL ) {} + virtual ~SOComWindowPeer() { } + +BEGIN_COM_MAP(SOComWindowPeer) + COM_INTERFACE_ENTRY(IDispatch) + COM_INTERFACE_ENTRY(ISOComWindowPeer) + COM_INTERFACE_ENTRY(ISupportErrorInfo) +END_COM_MAP() +DECLARE_NOT_AGGREGATABLE(SOComWindowPeer) +// Remove the comment from the line above if you don't want your object to +// support aggregation. + +DECLARE_REGISTRY_RESOURCEID(IDR_SOCOMWINDOWPEER) + +// ISupportsErrorInfo + STDMETHOD(InterfaceSupportsErrorInfo)(REFIID riid); + +// ISOComWindowPeer + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE getWindowHandle( + /* [in] */ SAFEARRAY __RPC_FAR * /*procId*/, + /* [in] */ short /*s*/, + /* [retval][out] */ long __RPC_FAR *ret) + { + *ret = HandleToLong( m_hwnd ); + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE getToolkit( + /* [retval][out] */ IDispatch __RPC_FAR *__RPC_FAR *retVal) + { + *retVal = NULL; + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE setPointer( + /* [in] */ IDispatch __RPC_FAR* /*xPointer*/) + { + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE setBackground( + /* [in] */ int /*nColor*/) + { + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE invalidate( + /* [in] */ short /*__MIDL_0015*/) + { + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE invalidateRect( + /* [in] */ IDispatch __RPC_FAR* /*aRect*/, + /* [in] */ short /*nFlags*/) + { + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE dispose( void) + { + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE addEventListener( + /* [in] */ IDispatch __RPC_FAR* /*xListener*/) + { + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE removeEventListener( + /* [in] */ IDispatch __RPC_FAR* /*xListener*/) + { + return S_OK; + } + + virtual /* [helpstring][id][propget] */ HRESULT STDMETHODCALLTYPE get_Bridge_implementedInterfaces( + /* [retval][out] */ SAFEARRAY __RPC_FAR * __RPC_FAR *pVal) + { + *pVal = SafeArrayCreateVector( VT_BSTR, 0, 2 ); + + if( !*pVal ) + return E_FAIL; + + long ix = 0; + CComBSTR aInterface( OLESTR( "com.sun.star.awt.XSystemDependentWindowPeer" ) ); + SafeArrayPutElement( *pVal, &ix, aInterface ); + + ix = 1; + aInterface = CComBSTR( OLESTR( "com.sun.star.awt.XWindowPeer" ) ); + SafeArrayPutElement( *pVal, &ix, aInterface ); + + return S_OK; + } + + void SetHWNDInternally( HWND hwnd ) { m_hwnd = hwnd; } +}; + +#endif // __SOCOMWINDOWPEER_H_ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/SOComWindowPeer.rgs b/extensions/source/activex/SOComWindowPeer.rgs new file mode 100644 index 000000000000..42e985a31a1b --- /dev/null +++ b/extensions/source/activex/SOComWindowPeer.rgs @@ -0,0 +1,23 @@ +HKCR +{ + so_activex.SOComWindowPeer.1 = s 'SOComWindowPeer Class' + { + CLSID = s '{EE51BD3E-8BB6-4FB8-B319-F65B1BE3B21D}' + } + so_activex.SOComWindowPeer = s 'SOComWindowPeer Class' + { + CLSID = s '{EE51BD3E-8BB6-4FB8-B319-F65B1BE3B21D}' + } + NoRemove CLSID + { + ForceRemove {EE51BD3E-8BB6-4FB8-B319-F65B1BE3B21D} = s 'SOComWindowPeer Class' + { + ProgID = s 'so_activex.SOComWindowPeer.1' + VersionIndependentProgID = s 'so_activex.SOComWindowPeer' + InprocServer32 = s '%MODULE%' + { + val ThreadingModel = s 'both' + } + } + } +} diff --git a/extensions/source/activex/SODispatchInterceptor.cxx b/extensions/source/activex/SODispatchInterceptor.cxx new file mode 100644 index 000000000000..dcddf0d86b0c --- /dev/null +++ b/extensions/source/activex/SODispatchInterceptor.cxx @@ -0,0 +1,225 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// SODispatchInterceptor.cpp : Implementation of CHelpApp and DLL registration. + +#include "stdio.h" +#include "stdafx2.h" +#include "so_activex.h" +#include "SOActiveX.h" +#include "SODispatchInterceptor.h" +#include "com_uno_helper.h" +#include + +///////////////////////////////////////////////////////////////////////////// +// + +STDMETHODIMP SODispatchInterceptor::InterfaceSupportsErrorInfo(REFIID riid) +{ + static const IID* arr[] = + { + &IID_ISODispatchInterceptor, + }; + + for (int i=0;i= 1300) + if (InlineIsEqualGUID(*arr[i],riid)) +#else + if (::ATL::InlineIsEqualGUID(*arr[i],riid)) +#endif + return S_OK; + } + return S_FALSE; +} + +STDMETHODIMP SODispatchInterceptor::queryDispatch( IDispatch FAR* aURL, + BSTR aTargetFrameName, + long nSearchFlags, + IDispatch FAR* FAR* retVal ) +{ + if ( !aURL || !retVal ) return E_FAIL; + + CComVariant aTargetUrl; + OLECHAR* sURLMemberName = L"Complete"; + DISPID nURLID; + HRESULT hr = aURL->GetIDsOfNames( IID_NULL, &sURLMemberName, 1, LOCALE_USER_DEFAULT, &nURLID ); + if( !SUCCEEDED( hr ) ) return hr; + + hr = CComDispatchDriver::GetProperty( aURL, nURLID, &aTargetUrl ); + if( !SUCCEEDED( hr ) ) return hr; + + if( aTargetUrl.vt != VT_BSTR ) return E_FAIL; + + USES_CONVERSION; + if( !strncmp( OLE2T( aTargetUrl.bstrVal ), ".uno:OpenHyperlink", 18 ) ) + { + CComQIPtr< IDispatch, &IID_IDispatch > pIDisp( this ); + if( pIDisp ) + { + this->AddRef(); + *retVal = pIDisp; + } + } + else + { + if( !m_xSlave ) + { + *retVal = NULL; + return S_OK; + } + + CComVariant aResult; + CComVariant aArgs[3]; + aArgs[0] = CComVariant( nSearchFlags ); + aArgs[1] = CComVariant( aTargetFrameName ); + aArgs[2] = CComVariant( aURL ); + + hr = ExecuteFunc( m_xSlave, L"queryDispatch", aArgs, 3, &aResult ); + if( !SUCCEEDED( hr ) || aResult.vt != VT_DISPATCH || aResult.pdispVal == NULL ) + { + *retVal = NULL; + return S_OK; + } + + *retVal = aResult.pdispVal; + + CComQIPtr< IUnknown, &IID_IUnknown > pIUnk( *retVal ); + if( pIUnk ) + (*retVal)->AddRef(); + } + + return S_OK; +} + +STDMETHODIMP SODispatchInterceptor::queryDispatches( SAFEARRAY FAR* aDescripts, SAFEARRAY FAR* FAR* retVal) +{ + if ( !aDescripts || !retVal || SafeArrayGetDim( aDescripts ) != 1 ) + return E_FAIL; + + long nLB, nUB; + + HRESULT hr = SafeArrayGetLBound( aDescripts, 1, &nLB ); + if( !SUCCEEDED( hr ) ) return hr; + + hr = SafeArrayGetUBound( aDescripts, 1, &nUB ); + if( !SUCCEEDED( hr ) ) return hr; + if( nUB < nLB ) return E_FAIL; + + *retVal = SafeArrayCreateVector( VT_DISPATCH, 0, nUB - nLB ); + + for ( long ind = nLB; ind <= nUB; ind ++ ) + { + CComPtr pElem; + SafeArrayGetElement( aDescripts, &ind, pElem ); + if( pElem ) + { + OLECHAR* pMemberNames[3] = { L"FeatureURL", L"FrameName", L"SearchFlags" }; + CComVariant pValues[3]; + hr = GetPropertiesFromIDisp( pElem, pMemberNames, pValues, 3 ); + if( !SUCCEEDED( hr ) ) return hr; + if( pValues[0].vt != VT_DISPATCH || pValues[0].pdispVal == NULL + || pValues[1].vt != VT_BSTR || pValues[2].vt != VT_I4 ) + return E_FAIL; + + CComPtr aRes; + hr = queryDispatch( pValues[0].pdispVal, pValues[1].bstrVal, pValues[2].lVal, &aRes ); + SafeArrayPutElement( *retVal, &ind, aRes ); + } + } + + return S_OK; +} + + +STDMETHODIMP SODispatchInterceptor::dispatch( IDispatch FAR* aURL, SAFEARRAY FAR* aArgs) +{ + // get url from aURL + OLECHAR* pUrlName = L"Complete"; + CComVariant pValue; + HRESULT hr = GetPropertiesFromIDisp( aURL, &pUrlName, &pValue, 1 ); + if( !SUCCEEDED( hr ) ) return hr; + if( pValue.vt != VT_BSTR || pValue.bstrVal == NULL ) + return E_FAIL; + + USES_CONVERSION; + if( !strncmp( OLE2T( pValue.bstrVal ), ".uno:OpenHyperlink", 18 ) ) + { + long nLB = 0, nUB = 0; + // long nDim = SafeArrayGetDim( aArgs ); + + hr = SafeArrayGetLBound( aArgs, 1, &nLB ); + if( !SUCCEEDED( hr ) ) return hr; + + hr = SafeArrayGetUBound( aArgs, 1, &nUB ); + if( !SUCCEEDED( hr ) ) return hr; + if( nUB < nLB ) return E_FAIL; + + for ( long ind = nLB; ind <= nUB; ind ++ ) + { + CComVariant pVarElem; + SafeArrayGetElement( aArgs, &ind, &pVarElem ); + if( pVarElem.vt == VT_DISPATCH && pVarElem.pdispVal != NULL ) + { + OLECHAR* pMemberNames[2] = { L"Name", L"Value" }; + CComVariant pValues[2]; + hr = GetPropertiesFromIDisp( pVarElem.pdispVal, pMemberNames, pValues, 2 ); + if( !SUCCEEDED( hr ) ) return hr; + + if( pValues[0].vt == VT_BSTR && pValues[1].vt == VT_BSTR ) + { + USES_CONVERSION; + if( !strncmp( OLE2T( pValues[0].bstrVal ), "URL", 3 ) ) + { + EnterCriticalSection( &mMutex ); + if( m_xParentControl ) + { + // call GetUrl to the browser instance + m_xParentControl->GetURL( pValues[1].bstrVal, L"_self" ); + } + LeaveCriticalSection( &mMutex ); + + break; + } + } + } + } + } + + return S_OK; +} + +STDMETHODIMP SODispatchInterceptor::addStatusListener( IDispatch FAR* /*xControl*/, IDispatch FAR* /*aURL*/) +{ + // not implemented + return S_OK; +} + +STDMETHODIMP SODispatchInterceptor::removeStatusListener( IDispatch FAR* /*xControl*/, IDispatch FAR* /*aURL*/) +{ + // not implemented + return S_OK; +} + +STDMETHODIMP SODispatchInterceptor::getInterceptedURLs( SAFEARRAY FAR* FAR* pVal ) +{ + *pVal = SafeArrayCreateVector( VT_BSTR, 0, 3 ); + + if( !*pVal ) + return E_FAIL; + + long ix = 0; + CComBSTR aPattern( OLESTR( "ftp://*" ) ); + SafeArrayPutElement( *pVal, &ix, aPattern ); + + ix = 1; + aPattern = CComBSTR( OLESTR( "http://*" ) ); + SafeArrayPutElement( *pVal, &ix, aPattern ); + + ix = 2; + aPattern = CComBSTR( OLESTR( "file://*" ) ); + SafeArrayPutElement( *pVal, &ix, aPattern ); + + return S_OK; +} + + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/SODispatchInterceptor.h b/extensions/source/activex/SODispatchInterceptor.h new file mode 100644 index 000000000000..538b12f24d2e --- /dev/null +++ b/extensions/source/activex/SODispatchInterceptor.h @@ -0,0 +1,158 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// SODispatchInterceptor.h: Definition of the SODispatchInterceptor class +// +////////////////////////////////////////////////////////////////////// + +#if !defined __SODISPATCHINTERCEPTOR_H_ +#define __SODISPATCHINTERCEPTOR_H_ + +#if _MSC_VER > 1000 +#pragma once +#endif // _MSC_VER > 1000 + +#include "resource.h" // main symbols +#include +#include +#include + +#if defined(_MSC_VER) && (_MSC_VER >= 1300) +#undef _DEBUG +#endif +#include + +#include "so_activex.h" + +class CSOActiveX; + +///////////////////////////////////////////////////////////////////////////// +// SODispatchInterceptor + +class SODispatchInterceptor : + public IDispatchImpl, + public ISupportErrorInfo, + public CComObjectRoot, + public CComCoClass +{ + CComPtr m_xMaster; + CComPtr m_xSlave; + CSOActiveX* m_xParentControl; + CRITICAL_SECTION mMutex; +public: + SODispatchInterceptor() : m_xParentControl( NULL ) { InitializeCriticalSection(&mMutex); } + virtual ~SODispatchInterceptor() { ATLASSERT( !m_xParentControl ); DeleteCriticalSection(&mMutex); } + +BEGIN_COM_MAP(SODispatchInterceptor) + COM_INTERFACE_ENTRY(IDispatch) + COM_INTERFACE_ENTRY(ISODispatchInterceptor) + COM_INTERFACE_ENTRY(ISupportErrorInfo) +END_COM_MAP() +DECLARE_NOT_AGGREGATABLE(SODispatchInterceptor) +// Remove the comment from the line above if you don't want your object to +// support aggregation. + +DECLARE_REGISTRY_RESOURCEID(IDR_SODISPATCHINTERCEPTOR) + + void SetParent( CSOActiveX* pParent ) + { + ATLASSERT( !m_xParentControl ); + EnterCriticalSection( &mMutex ); + m_xParentControl = pParent; + LeaveCriticalSection( &mMutex ); + } + + void ClearParent() + { + EnterCriticalSection( &mMutex ); + m_xParentControl = NULL; + LeaveCriticalSection( &mMutex ); + } + +// ISupportsErrorInfo + STDMETHOD(InterfaceSupportsErrorInfo)(REFIID riid); + +// ISODispatchInterceptor + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE getSlaveDispatchProvider( + /* [retval][out] */ IDispatch __RPC_FAR *__RPC_FAR *retVal) + { + *retVal = m_xSlave; + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE setSlaveDispatchProvider( + /* [in] */ IDispatch __RPC_FAR *xNewDispatchProvider) + { + m_xSlave = xNewDispatchProvider; + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE getMasterDispatchProvider( + /* [retval][out] */ IDispatch __RPC_FAR *__RPC_FAR *retVal) + { + *retVal = m_xMaster; + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE setMasterDispatchProvider( + /* [in] */ IDispatch __RPC_FAR *xNewSupplier) + { + m_xMaster = xNewSupplier; + return S_OK; + } + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE queryDispatch( + /* [in] */ IDispatch __RPC_FAR *aURL, + /* [in] */ BSTR aTargetFrameName, + /* [in] */ long nSearchFlags, + /* [retval][out] */ IDispatch __RPC_FAR *__RPC_FAR *retVal); + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE queryDispatches( + /* [in] */ SAFEARRAY __RPC_FAR * aDescripts, + /* [retval][out] */ SAFEARRAY __RPC_FAR * __RPC_FAR *retVal); + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE dispatch( + /* [in] */ IDispatch __RPC_FAR *aURL, + /* [in] */ SAFEARRAY __RPC_FAR * aArgs); + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE addStatusListener( + /* [in] */ IDispatch __RPC_FAR *xControl, + /* [in] */ IDispatch __RPC_FAR *aURL); + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE removeStatusListener( + /* [in] */ IDispatch __RPC_FAR *xControl, + /* [in] */ IDispatch __RPC_FAR *aURL); + + virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE getInterceptedURLs( + /* [retval][out] */ SAFEARRAY __RPC_FAR * __RPC_FAR *pVal); + + virtual /* [helpstring][id][propget] */ HRESULT STDMETHODCALLTYPE get_Bridge_implementedInterfaces( + /* [retval][out] */ SAFEARRAY __RPC_FAR * __RPC_FAR *pVal) + { + *pVal = SafeArrayCreateVector( VT_BSTR, 0, 4 ); + + if( !*pVal ) + return E_FAIL; + + long ix = 0; + CComBSTR aInterface( OLESTR( "com.sun.star.frame.XDispatchProviderInterceptor" ) ); + SafeArrayPutElement( *pVal, &ix, aInterface ); + + ix = 1; + aInterface = CComBSTR( OLESTR( "com.sun.star.frame.XDispatchProvider" ) ); + SafeArrayPutElement( *pVal, &ix, aInterface ); + + ix = 2; + aInterface = CComBSTR( OLESTR( "com.sun.star.frame.XDispatch" ) ); + SafeArrayPutElement( *pVal, &ix, aInterface ); + + ix = 3; + aInterface = CComBSTR( OLESTR( "com.sun.star.frame.XInterceptorInfo" ) ); + SafeArrayPutElement( *pVal, &ix, aInterface ); + + return S_OK; + } +}; + +#endif // __SODISPATCHINTERCEPTOR_H_ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/SODispatchInterceptor.rgs b/extensions/source/activex/SODispatchInterceptor.rgs new file mode 100644 index 000000000000..19fe0b5f0e4c --- /dev/null +++ b/extensions/source/activex/SODispatchInterceptor.rgs @@ -0,0 +1,23 @@ +HKCR +{ + so_activex.SODispatchInterceptor.1 = s 'SODispatchInterceptor Class' + { + CLSID = s '{C5D6D568-57DA-4D6C-819A-451CB565E682}' + } + so_activex.SODispatchInterceptor = s 'SODispatchInterceptor Class' + { + CLSID = s '{C5D6D568-57DA-4D6C-819A-451CB565E682}' + } + NoRemove CLSID + { + ForceRemove {C5D6D568-57DA-4D6C-819A-451CB565E682} = s 'SODispatchInterceptor Class' + { + ProgID = s 'so_activex.SODispatchInterceptor.1' + VersionIndependentProgID = s 'so_activex.SODispatchInterceptor' + InprocServer32 = s '%MODULE%' + { + val ThreadingModel = s 'both' + } + } + } +} diff --git a/extensions/source/activex/StdAfx2.cxx b/extensions/source/activex/StdAfx2.cxx new file mode 100644 index 000000000000..f1cf88d10d14 --- /dev/null +++ b/extensions/source/activex/StdAfx2.cxx @@ -0,0 +1,21 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// stdafx1.cpp : source file that includes just the standard includes +// stdafx1.pch will be the pre-compiled header +// stdafx1.obj will contain the pre-compiled type information + +#ifdef __MINGW32__ +#define _INIT_ATL_COMMON_VARS +#endif +#include "stdafx2.h" + +#ifdef _ATL_STATIC_REGISTRY +#include +#include +#endif + +#if defined(_MSC_VER) && (_MSC_VER >= 1300) +#undef _DEBUG +#endif +#include + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/StdAfx2.h b/extensions/source/activex/StdAfx2.h new file mode 100644 index 000000000000..5c540b0ba329 --- /dev/null +++ b/extensions/source/activex/StdAfx2.h @@ -0,0 +1,45 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// stdafx1.h : include file for standard system include files, +// or project specific include files that are used frequently, +// but are changed infrequently + +#if !defined(AFX_STDAFX_H__C1799EA0_62CC_44DE_A2DD_C9F0410FF7F1__INCLUDED_) +#define AFX_STDAFX_H__C1799EA0_62CC_44DE_A2DD_C9F0410FF7F1__INCLUDED_ + +#if _MSC_VER > 1000 +#pragma once +#endif // _MSC_VER > 1000 + +#define STRICT +#ifndef _WIN32_WINNT +#define _WIN32_WINNT 0x0400 +#endif +#define _ATL_APARTMENT_THREADED +#define _ATL_STATIC_REGISTRY + +#pragma warning (disable:4505) + // globally disable "unreferenced local function has been removed" + +#pragma warning (push,1) +#pragma warning (disable:4548) + // expression before comma has no effect; expected expression with side-effect +#pragma warning (disable:4555) + // expression has no effect; expected expression with side-effect + +#define min(a, b) (((a) < (b)) ? (a) : (b)) +#include + +//You may derive a class from CComModule and use it if you want to override +//something, but do not change the name of _Module +extern CComModule _Module; +#include +#include + +#pragma warning (pop) + +//{{AFX_INSERT_LOCATION}} +// Microsoft Visual C++ will insert additional declarations immediately before the previous line. + +#endif // !defined(AFX_STDAFX_H__C1799EA0_62CC_44DE_A2DD_C9F0410FF7F1__INCLUDED) + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/com_uno_helper.h b/extensions/source/activex/com_uno_helper.h new file mode 100644 index 000000000000..230fc63a6e77 --- /dev/null +++ b/extensions/source/activex/com_uno_helper.h @@ -0,0 +1,26 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +#include "stdafx2.h" + +HRESULT ExecuteFunc( IDispatch* idispUnoObject, + OLECHAR* sFuncName, + CComVariant* params, + unsigned int count, + CComVariant* pResult ); + +HRESULT GetIDispByFunc( IDispatch* idispUnoObject, + OLECHAR* sFuncName, + CComVariant* params, + unsigned int count, + CComPtr& pdispResult ); + +HRESULT PutPropertiesToIDisp( IDispatch* pdispObject, + OLECHAR** sMemberNames, + CComVariant* pVariant, + unsigned int count ); + +HRESULT GetPropertiesFromIDisp( IDispatch* pdispObject, + OLECHAR** sMemberNames, + CComVariant* pVariant, + unsigned int count ); + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/example.html b/extensions/source/activex/example.html new file mode 100644 index 000000000000..3efee1f75a03 --- /dev/null +++ b/extensions/source/activex/example.html @@ -0,0 +1,26 @@ + + +Document Title + + + +
+First you should edit the example.html file!!! +
+
+ + + + + + + +
+ + + diff --git a/extensions/source/activex/main/README.txt b/extensions/source/activex/main/README.txt deleted file mode 100644 index 9d647987aaa7..000000000000 --- a/extensions/source/activex/main/README.txt +++ /dev/null @@ -1,33 +0,0 @@ - Description. - -The StarOffice ActiveX control shows an example of access to UNO through COM technology. -It requires a properly installed StarOffice version 6.0/6.1 or OpenOffice 1.0. -This is a Lite ActiveX control so it can be used only in containers that -allows to use such controls. - -Pressing to any link to staroffice document should activate the control. -So the document will be opened in ReadOnly mode. - -Also it can be activated with an tag from a html-page. -Without any parameters for an object tag a new writer document will be -opened for editing. Possible parameters are - src - full URL to the file that should be edited/viewed; - it can contain "private:factory/..." URLs to open new documents - for edit, for example "private:factory/swriter" - readonly - the default value is "true", in case it is set to any other - value the document is opened for editing - -As any ActiveX control this one should be registered. -To let MSIE register it itself the "CODEBASE" parameter -for the "OBJECT" tag should be specified -with an URL to the library "so_activex.dll". -The example of registration with "OBJECT" tag is in example.html. - -Also it can be done using regsvr32 application. -To do it please write -\System32\regsvr32 so_activex.dll - -To unregister the control please use /u option: -\system32\regsvr32 so_activex.dll /u - - diff --git a/extensions/source/activex/main/SOActionsApproval.cpp b/extensions/source/activex/main/SOActionsApproval.cpp deleted file mode 100644 index e0ce5c5da58e..000000000000 --- a/extensions/source/activex/main/SOActionsApproval.cpp +++ /dev/null @@ -1,32 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// SOActionsApproval.cpp : Implementation of CHelpApp and DLL registration. - -#include "stdafx2.h" - -#include "so_activex.h" -#include "SOActionsApproval.h" -#include - -///////////////////////////////////////////////////////////////////////////// -// - -STDMETHODIMP SOActionsApproval::InterfaceSupportsErrorInfo(REFIID riid) -{ - static const IID* arr[] = - { - &IID_ISOActionsApproval, - }; - - for (int i=0;i= 1300) - if (InlineIsEqualGUID(*arr[i],riid)) -#else - if (::ATL::InlineIsEqualGUID(*arr[i],riid)) -#endif - return S_OK; - } - return S_FALSE; -} - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/SOActionsApproval.h b/extensions/source/activex/main/SOActionsApproval.h deleted file mode 100644 index a5570312864d..000000000000 --- a/extensions/source/activex/main/SOActionsApproval.h +++ /dev/null @@ -1,83 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// SOActionsApproval.h: Definition of the SOActionsApproval class -// -////////////////////////////////////////////////////////////////////// - -#if !defined __SODOCUMENTEVENTLISTENER_H_ -#define __SODOCUMENTEVENTLISTENER_H_ - -#if _MSC_VER > 1000 -#pragma once -#endif // _MSC_VER > 1000 - -#include "resource.h" // main symbols -#include -#include -#include - -#if defined(_MSC_VER) && (_MSC_VER >= 1300) -#undef _DEBUG -#endif - -#include - -#include "so_activex.h" - -///////////////////////////////////////////////////////////////////////////// -// SOActionsApproval - -class SOActionsApproval : - public IDispatchImpl, - public ISupportErrorInfo, - public CComObjectRoot, - public CComCoClass -{ -public: - SOActionsApproval() {} - virtual ~SOActionsApproval() {} - -BEGIN_COM_MAP(SOActionsApproval) - COM_INTERFACE_ENTRY(IDispatch) - COM_INTERFACE_ENTRY(ISOActionsApproval) - COM_INTERFACE_ENTRY(ISupportErrorInfo) -END_COM_MAP() -DECLARE_NOT_AGGREGATABLE(SOActionsApproval) -// Remove the comment from the line above if you don't want your object to -// support aggregation. - -DECLARE_REGISTRY_RESOURCEID(IDR_SODOCUMENTEVENTLISTENER) - -// ISupportsErrorInfo - STDMETHOD(InterfaceSupportsErrorInfo)(REFIID riid); - -// ISOActionsApproval - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE approveAction( - /* [in] */ long nActionID, - /* [retval][out] */ boolean *pbApproval) - { - // only PreventClose is approved - USES_CONVERSION; - *pbApproval = ( nActionID == 1 ); - - return S_OK; - } - - virtual /* [helpstring][id][propget] */ HRESULT STDMETHODCALLTYPE get_Bridge_implementedInterfaces( - /* [retval][out] */ SAFEARRAY __RPC_FAR * __RPC_FAR *pVal) - { - *pVal = SafeArrayCreateVector( VT_BSTR, 0, 1 ); - - if( !*pVal ) - return E_FAIL; - - long ix = 0; - CComBSTR aInterface( OLESTR( "com.sun.star.embed.XActionsApproval" ) ); - SafeArrayPutElement( *pVal, &ix, aInterface ); - - return S_OK; - } -}; - -#endif // __SODOCUMENTEVENTLISTENER_H_ - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/SOActionsApproval.rgs b/extensions/source/activex/main/SOActionsApproval.rgs deleted file mode 100644 index 543320813948..000000000000 --- a/extensions/source/activex/main/SOActionsApproval.rgs +++ /dev/null @@ -1,24 +0,0 @@ -HKCR -{ -9F3697AC-7A18-4335-AF0A-65FAC2C35CC1 - so_activex.SOActionsApproval.1 = s 'SOActionsApproval Class' - { - CLSID = s '{9F3697AC-7A18-4335-AF0A-65FAC2C35CC1}' - } - so_activex.SOActionsApproval = s 'SOActionsApproval Class' - { - CLSID = s '{9F3697AC-7A18-4335-AF0A-65FAC2C35CC1}' - } - NoRemove CLSID - { - ForceRemove {9F3697AC-7A18-4335-AF0A-65FAC2C35CC1} = s 'SOActionsApproval Class' - { - ProgID = s 'so_activex.SOActionsApproval.1' - VersionIndependentProgID = s 'so_activex.SOActionsApproval' - InprocServer32 = s '%MODULE%' - { - val ThreadingModel = s 'both' - } - } - } -} diff --git a/extensions/source/activex/main/SOActiveX.cpp b/extensions/source/activex/main/SOActiveX.cpp deleted file mode 100644 index f95e42772185..000000000000 --- a/extensions/source/activex/main/SOActiveX.cpp +++ /dev/null @@ -1,1153 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// SOActiveX.cpp : Implementation of CSOActiveX - -#pragma warning (disable:4505) - // permanently suppress "unreferenced local function has been removed" warning - -#pragma warning (push,1) -#pragma warning (disable:4265) - -#include "stdafx2.h" -#include "so_activex.h" -#include "SOActiveX.h" -#include "SOComWindowPeer.h" -#include "SODispatchInterceptor.h" -#include "SOActionsApproval.h" - -#pragma warning (pop) - -#define STAROFFICE_WINDOWCLASS "SOParentWindow" - - -///////////////////////////////////////////////////////////////////////////// - -void OutputError_Impl( HWND hw, HRESULT ErrorCode ) -{ - void* sMessage; - FormatMessageA( - FORMAT_MESSAGE_ALLOCATE_BUFFER | - FORMAT_MESSAGE_FROM_SYSTEM, - NULL, - ErrorCode, - MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), // Default language - (LPTSTR) &sMessage, - 0, - NULL - ); - ::MessageBoxA( hw, (LPCTSTR)sMessage, NULL, MB_OK | MB_ICONINFORMATION ); - LocalFree( sMessage ); -} - -HRESULT ExecuteFunc( IDispatch* idispUnoObject, - OLECHAR* sFuncName, - CComVariant* params, - unsigned int count, - CComVariant* pResult ) -{ - if( !idispUnoObject ) - return E_FAIL; - - DISPID id; - HRESULT hr = idispUnoObject->GetIDsOfNames( IID_NULL, &sFuncName, 1, LOCALE_USER_DEFAULT, &id); - if( !SUCCEEDED( hr ) ) return hr; - - DISPPARAMS dispparams= { params, 0, count, 0}; - - // DEBUG - EXCEPINFO myInfo; - hr = idispUnoObject->Invoke( id, IID_NULL,LOCALE_USER_DEFAULT, DISPATCH_METHOD, - &dispparams, pResult, &myInfo, 0); - - // for debugging purposes - // USES_CONVERSION; - // if ( !SUCCEEDED( hr ) ) - // ::MessageBox( NULL, OLE2A( myInfo.bstrDescription ), OLE2A( myInfo.bstrSource ), MB_OK | MB_ICONINFORMATION ); - - return hr; -} - -HRESULT GetIDispByFunc( IDispatch* idispUnoObject, - OLECHAR* sFuncName, - CComVariant* params, - unsigned int count, - CComPtr& pdispResult ) -{ - if( !idispUnoObject ) - return E_FAIL; - - CComVariant result; - HRESULT hr = ExecuteFunc( idispUnoObject, sFuncName, params, count, &result ); - if( !SUCCEEDED( hr ) ) return hr; - - if( result.vt != VT_DISPATCH || result.pdispVal == NULL ) - return E_FAIL; - - pdispResult = CComPtr( result.pdispVal ); - - return S_OK; -} - -HRESULT PutPropertiesToIDisp( IDispatch* pdispObject, - OLECHAR** sMemberNames, - CComVariant* pVariant, - unsigned int count ) -{ - for( unsigned int ind = 0; ind < count; ind++ ) - { - DISPID id; - HRESULT hr = pdispObject->GetIDsOfNames( IID_NULL, &sMemberNames[ind], 1, LOCALE_USER_DEFAULT, &id ); - if( !SUCCEEDED( hr ) ) return hr; - - hr = CComDispatchDriver::PutProperty( pdispObject, id, &pVariant[ind] ); - if( !SUCCEEDED( hr ) ) return hr; - } - - return S_OK; -} - -HRESULT GetPropertiesFromIDisp( IDispatch* pdispObject, - OLECHAR** sMemberNames, - CComVariant* pVariant, - unsigned int count ) -{ - for( unsigned int ind = 0; ind < count; ind++ ) - { - DISPID id; - HRESULT hr = pdispObject->GetIDsOfNames( IID_NULL, &sMemberNames[ind], 1, LOCALE_USER_DEFAULT, &id ); - if( !SUCCEEDED( hr ) ) return hr; - - hr = CComDispatchDriver::GetProperty( pdispObject, id, &pVariant[ind] ); - if( !SUCCEEDED( hr ) ) return hr; - } - - return S_OK; -} -///////////////////////////////////////////////////////////////////////////// -// CSOActiveX - -CSOActiveX::CSOActiveX() -: mCookie(0) -, mCurFileUrl( L"private:factory/swriter" ) -, mbLoad( FALSE ) -, mParentWin( NULL ) -, mOffWin( NULL ) -, mbViewOnly( TRUE ) -, mpDispatchInterceptor( NULL ) -, mnVersion( SO_NOT_DETECTED ) -, mbReadyForActivation( FALSE ) -, mbDrawLocked( FALSE ) -{ - CLSID clsFactory = {0x82154420,0x0FBF,0x11d4,{0x83, 0x13,0x00,0x50,0x04,0x52,0x6A,0xB4}}; - HRESULT hr = CoCreateInstance( clsFactory, NULL, CLSCTX_ALL, __uuidof(IDispatch), (void**)&mpDispFactory); - if( !SUCCEEDED( hr ) ) - OutputError_Impl( NULL, hr ); - - mPWinClass.style = CS_HREDRAW|CS_VREDRAW; - mPWinClass.lpfnWndProc = ::DefWindowProc; - mPWinClass.cbClsExtra = 0; - mPWinClass.cbWndExtra = 0; - mPWinClass.hInstance = (HINSTANCE) GetModuleHandle(NULL); //myInstance; - mPWinClass.hIcon = NULL; - mPWinClass.hCursor = NULL; - mPWinClass.hbrBackground = (HBRUSH) COLOR_BACKGROUND; - mPWinClass.lpszMenuName = NULL; - mPWinClass.lpszClassName = STAROFFICE_WINDOWCLASS; - - RegisterClass(&mPWinClass); -} - -CSOActiveX::~CSOActiveX() -{ - Cleanup(); - -} - -HRESULT CSOActiveX::Cleanup() -{ - CComVariant dummyResult; - - if( mpDispatchInterceptor ) - { - if( mpDispFrame ) - { - // remove dispatch interceptor - CComQIPtr< IDispatch, &IID_IDispatch > pIDispDispInter( mpDispatchInterceptor ); - CComVariant aVariant( pIDispDispInter ); - ExecuteFunc( mpDispFrame, - L"releaseDispatchProviderInterceptor", - &aVariant, - 1, - &dummyResult ); - } - - mpDispatchInterceptor->ClearParent(); - mpDispatchInterceptor->Release(); - mpDispatchInterceptor = NULL; - } - - mpDispTempFile = CComPtr< IDispatch >(); - mbReadyForActivation = FALSE; - - if( mpInstanceLocker ) - { - ExecuteFunc( mpInstanceLocker, L"dispose", NULL, 0, &dummyResult ); - mpInstanceLocker = CComPtr< IDispatch >(); - } - - if( mpDispFrame ) - { - BOOL bCloserActivated = FALSE; - - CComPtr pDispDocumentCloser; - CComVariant aDocCloser( L"com.sun.star.embed.DocumentCloser" ); - HRESULT hr = GetIDispByFunc( mpDispFactory, - L"createInstance", - &aDocCloser, - 1, - pDispDocumentCloser ); - if ( SUCCEEDED( hr ) && pDispDocumentCloser ) - { - SAFEARRAY FAR* pInitFrame = SafeArrayCreateVector( VT_VARIANT, 0, 1 ); - long nInitInd = 0; - CComVariant pFrameVariant( mpDispFrame ); - SafeArrayPutElement( pInitFrame, &nInitInd, &pFrameVariant ); - CComVariant aVarInitFrame; - aVarInitFrame.vt = VT_ARRAY | VT_VARIANT; aVarInitFrame.parray = pInitFrame; - hr = ExecuteFunc( pDispDocumentCloser, L"initialize", &aVarInitFrame, 1, &dummyResult ); - if( SUCCEEDED( hr ) ) - { - // the following call will let the closing happen - hr = ExecuteFunc( pDispDocumentCloser, L"dispose", NULL, 0, &dummyResult ); - bCloserActivated = SUCCEEDED( hr ); - } - } - - if ( !bCloserActivated ) - { - CComVariant aPropVar; - aPropVar.vt = VT_BOOL; aPropVar.boolVal = VARIANT_TRUE; - if ( !SUCCEEDED( ExecuteFunc( mpDispFrame, L"close", &aPropVar, 1, &dummyResult ) ) ) - ExecuteFunc( mpDispFrame, L"dispose", NULL, 0, &dummyResult ); - } - - mpDispFrame = CComPtr< IDispatch >(); - } - - if( ::IsWindow( mOffWin ) ) - ::DestroyWindow( mOffWin ); - - TerminateOffice(); - - return S_OK; -} - -HRESULT CSOActiveX::TerminateOffice() -{ - // create desktop - CComPtr pdispDesktop; - CComVariant aDesktopServiceName( L"com.sun.star.frame.Desktop" ); - - HRESULT hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aDesktopServiceName, 1, pdispDesktop ); - if( !pdispDesktop || !SUCCEEDED( hr ) ) return hr; - - // create tree of frames - CComPtr pdispChildren; - hr = GetIDispByFunc( pdispDesktop, L"getFrames", NULL, 0, pdispChildren ); - if( !pdispChildren || !SUCCEEDED( hr ) ) return hr; - - CComVariant aFrames; - CComVariant nFlag( 4 ); - hr = ExecuteFunc( pdispChildren, L"queryFrames", &nFlag, 1, &aFrames ); - if ( SUCCEEDED( hr ) ) - { - if ( ( aFrames.vt == ( VT_ARRAY | VT_DISPATCH ) || aFrames.vt == ( VT_ARRAY | VT_VARIANT ) ) - && ( !aFrames.parray || aFrames.parray->cDims == 1 && aFrames.parray->rgsabound[0].cElements == 0 ) ) - { - // there is no frames open - // TODO: check whether the frames are hidden if they are open? - CComVariant dummyResult; - hr = ExecuteFunc( pdispDesktop, L"terminate", NULL, 0, &dummyResult ); - } - } - - return hr; -} - -STDMETHODIMP CSOActiveX::InitNew () -{ - mnVersion = GetVersionConnected(); - mbLoad = TRUE; - return S_OK; -} - -STDMETHODIMP CSOActiveX::Load ( LPSTREAM /*pStm*/ ) -{ - mnVersion = GetVersionConnected(); - mbLoad = TRUE; - - // may be later? - // for now just ignore - - return S_OK; -} - -STDMETHODIMP CSOActiveX::Load( LPPROPERTYBAG pPropBag, LPERRORLOG /*pErrorLog*/ ) -{ - mnVersion = GetVersionConnected(); - - IPropertyBag2* pPropBag2; - HRESULT hr = pPropBag->QueryInterface( IID_IPropertyBag2, (void**)&pPropBag2 ); - //ATLASSERT( hr >= 0 ); - - if( !SUCCEEDED( hr ) ) - return hr; - - unsigned long aNum; - hr = pPropBag2->CountProperties( &aNum ); - //ATLASSERT( hr >= 0 ); - if( !SUCCEEDED( hr ) ) - return hr; - - PROPBAG2* aPropNames = new PROPBAG2[aNum]; - unsigned long aReaded; - - hr = pPropBag2->GetPropertyInfo( 0, - aNum, - aPropNames, - &aReaded ); - //ATLASSERT( hr >= 0 ); - if( !SUCCEEDED( hr ) ) - { - delete[] aPropNames; - return hr; - } - - CComVariant* aVal = new CComVariant[aNum]; - HRESULT* hvs = new HRESULT[aNum]; - hr = pPropBag2->Read( aNum, - aPropNames, - NULL, - aVal, - hvs ); - //ATLASSERT( hr >= 0 ); - if( !SUCCEEDED( hr ) ) - { - delete[] hvs; - delete[] aVal; - delete[] aPropNames; - return hr; - } - - USES_CONVERSION; - for( unsigned long ind = 0; ind < aNum; ind++ ) - { - // all information from the 'object' tag is in strings - if( aVal[ind].vt == VT_BSTR && !strcmp( OLE2T( aPropNames[ind].pstrName ), "src" ) ) - { - mCurFileUrl = wcsdup( aVal[ind].bstrVal ); - } - else if( aVal[ind].vt == VT_BSTR - && !strcmp( OLE2T( aPropNames[ind].pstrName ), "readonly" ) ) - { - if( !strcmp( OLE2T( aVal[ind].bstrVal ), "true" ) ) - { - // the default value - mbViewOnly = TRUE; - } - else - { - mbViewOnly = FALSE; - } - } - } - - delete[] hvs; - delete[] aVal; - delete[] aPropNames; - - if( !mpDispFactory ) - return hr; - - mbReadyForActivation = FALSE; - hr = CBindStatusCallback::Download( this, &CSOActiveX::CallbackCreateXInputStream, mCurFileUrl, m_spClientSite, FALSE ); - if ( hr == MK_S_ASYNCHRONOUS ) - hr = S_OK; - - if ( !SUCCEEDED( hr ) ) - { - // trigger initialization without stream - mbLoad = TRUE; - - Invalidate(); - UpdateWindow(); - } - - return hr; -} - -HRESULT CSOActiveX::GetUnoStruct( OLECHAR* sStructName, CComPtr& pdispResult ) -{ - CComVariant aComStruct( sStructName ); - return GetIDispByFunc( mpDispFactory, L"Bridge_GetStruct", &aComStruct, 1, pdispResult ); -} - -HRESULT CSOActiveX::GetUrlStruct( OLECHAR* sUrl, CComPtr& pdispUrl ) -{ - HRESULT hr = GetUnoStruct( L"com.sun.star.util.URL", pdispUrl ); - if( !SUCCEEDED( hr ) ) return hr; - - OLECHAR* sURLMemberName = L"Complete"; - DISPID nURLID; - hr = pdispUrl->GetIDsOfNames( IID_NULL, &sURLMemberName, 1, LOCALE_USER_DEFAULT, &nURLID ); - if( !SUCCEEDED( hr ) ) return hr; - CComVariant aComUrl( sUrl ); - hr = CComDispatchDriver::PutProperty( pdispUrl, nURLID, &aComUrl ); - if( !SUCCEEDED( hr ) ) return hr; - - CComPtr pdispTransformer; - CComVariant aServiceName( L"com.sun.star.util.URLTransformer" ); - hr = GetIDispByFunc( mpDispFactory, - L"createInstance", - &aServiceName, - 1, - pdispTransformer ); - if( !SUCCEEDED( hr ) ) return hr; - - CComVariant dummyResult; - CComVariant aParam[2]; - aParam[1].ppdispVal = &pdispUrl; - aParam[1].vt = VT_DISPATCH | VT_BYREF; - aParam[0] = CComVariant( L"file:///" ); - - hr = ExecuteFunc( pdispTransformer, L"parseSmart", aParam, 2, &dummyResult ); - if( !SUCCEEDED( hr ) || dummyResult.vt != VT_BOOL || !dummyResult.boolVal ) return hr; - - return S_OK; -} - -HRESULT CSOActiveX::SetLayoutManagerProps() -{ - if ( !mpDispFrame ) - return E_FAIL; - - CComVariant pVarLayoutMgr; - OLECHAR* sLMPropName = L"LayoutManager"; - HRESULT hr = GetPropertiesFromIDisp( mpDispFrame, &sLMPropName, &pVarLayoutMgr, 1 ); - if( pVarLayoutMgr.vt != VT_DISPATCH || pVarLayoutMgr.pdispVal == NULL ) - return E_FAIL; - - CComPtr pdispLM( pVarLayoutMgr.pdispVal ); - - - if( !SUCCEEDED( hr ) || !pdispLM ) - return E_FAIL; - - OLECHAR* sATName = L"AutomaticToolbars"; - CComVariant pATProp; - pATProp.vt = VT_BOOL; pATProp.boolVal = VARIANT_FALSE ; - hr = PutPropertiesToIDisp( pdispLM, &sATName, &pATProp, 1 ); - - return hr; -} - -HRESULT CSOActiveX::CreateFrameOldWay( HWND hwnd, int width, int height ) -{ - if( !mpDispFactory ) - return E_FAIL; - - // create window handle holder - CComPtr< CComObject< SOComWindowPeer > > pPeerToSend = new CComObject(); - pPeerToSend->SetHWNDInternally( hwnd ); - CComQIPtr< IDispatch, &IID_IDispatch > pIDispToSend( pPeerToSend ); - - // create rectangle structure - CComPtr pdispRectangle; - HRESULT hr = GetUnoStruct( L"com.sun.star.awt.Rectangle", pdispRectangle ); - if( !SUCCEEDED( hr ) ) return hr; - - OLECHAR* sRectMemberNames[4] = { L"X", - L"Y", - L"Width", - L"Height" }; - CComVariant pRectVariant[4]; - pRectVariant[0] = pRectVariant[1] = pRectVariant[2] = pRectVariant[3] = CComVariant( 0 ); - - hr = PutPropertiesToIDisp( pdispRectangle, sRectMemberNames, pRectVariant, 4 ); - if( !SUCCEEDED( hr ) ) return hr; - - // create WindowDescriptor structure - CComPtr pdispWinDescr; - hr = GetUnoStruct( L"com.sun.star.awt.WindowDescriptor", pdispWinDescr ); - if( !SUCCEEDED( hr ) ) return hr; - - // fill in descriptor with info - OLECHAR* sDescriptorMemberNames[6] = { L"Type", - L"WindowServiceName", - L"ParentIndex", - L"Parent", - L"Bounds", - L"WindowAttributes" }; - CComVariant pDescriptorVar[6]; - pDescriptorVar[0] = CComVariant( 0 ); - pDescriptorVar[1] = CComVariant( L"workwindow" ); - pDescriptorVar[2] = CComVariant( 1 ); - pDescriptorVar[3] = CComVariant( pIDispToSend ); - pDescriptorVar[4] = CComVariant( pdispRectangle ); - pDescriptorVar[5] = CComVariant( 33 ); - hr = PutPropertiesToIDisp( pdispWinDescr, sDescriptorMemberNames, pDescriptorVar, 6 ); - if( !SUCCEEDED( hr ) ) return hr; - - // create XToolkit instance - CComPtr pdispToolkit; - CComVariant aServiceName( L"com.sun.star.awt.Toolkit" ); - hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aServiceName, 1, pdispToolkit ); - if( !SUCCEEDED( hr ) ) return hr; - - // create window with toolkit - CComVariant aWinDescr( pdispWinDescr ); - hr = GetIDispByFunc( pdispToolkit, L"createWindow", &aWinDescr, 1, mpDispWin ); - if( !SUCCEEDED( hr ) ) return hr; - - // create frame - aServiceName = CComVariant( L"com.sun.star.frame.Task" ); - hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aServiceName, 1, mpDispFrame ); - if( !SUCCEEDED( hr ) || !mpDispFrame ) - { - // the interface com.sun.star.frame.Task is removed in 6.1 - // but the interface com.sun.star.frame.Frame has some bugs in 6.0 - aServiceName = CComVariant( L"com.sun.star.frame.Frame" ); - hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aServiceName, 1, mpDispFrame ); - if( !SUCCEEDED( hr ) ) return hr; - } - - // initialize frame - CComVariant dummyResult; - CComVariant aDispWin( mpDispWin ); - hr = ExecuteFunc( mpDispFrame, L"initialize", &aDispWin, 1, &dummyResult ); - if( !SUCCEEDED( hr ) ) return hr; - - // set some properties to the layout manager, ignore errors for now - SetLayoutManagerProps(); - - // create desktop - CComPtr pdispDesktop; - aServiceName = CComVariant( L"com.sun.star.frame.Desktop" ); - hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aServiceName, 1, pdispDesktop ); - if( !SUCCEEDED( hr ) ) return hr; - - // create tree of frames - CComPtr pdispChildren; - hr = GetIDispByFunc( pdispDesktop, L"getFrames", NULL, 0, pdispChildren ); - if( !SUCCEEDED( hr ) ) return hr; - - // insert new frame into desctop hierarchy - CComVariant aDispFrame( mpDispFrame ); - hr = ExecuteFunc( pdispChildren, L"append", &aDispFrame, 1, &dummyResult ); - if( !SUCCEEDED( hr ) ) return hr; - - // initialize window - CComVariant aTransparent( (long)0xFFFFFFFF ); - hr = ExecuteFunc( mpDispWin, L"setBackground", &aTransparent, 1, &dummyResult ); - if( !SUCCEEDED( hr ) ) return hr; - - CComVariant aTrue( TRUE ); - hr = ExecuteFunc( mpDispWin, L"setVisible", &aTrue, 1, &dummyResult ); - if( !SUCCEEDED( hr ) ) return hr; - - CComVariant aPosArgs[5]; - aPosArgs[4] = CComVariant( 0 ); - aPosArgs[3] = CComVariant( 0 ); - aPosArgs[2] = CComVariant( width ); - aPosArgs[1] = CComVariant( height ); - aPosArgs[0] = CComVariant( 12 ); - hr = ExecuteFunc( mpDispWin, L"setPosSize", aPosArgs, 5, &dummyResult ); - if( !SUCCEEDED( hr ) ) return hr; - - // create frame locker if there is such service - aServiceName = CComVariant( L"com.sun.star.embed.InstanceLocker" ); - hr = GetIDispByFunc( mpDispFactory, L"createInstance", &aServiceName, 1, mpInstanceLocker ); - if( SUCCEEDED( hr ) && mpInstanceLocker ) - { - SAFEARRAY FAR* pInitVals = SafeArrayCreateVector( VT_VARIANT, 0, 3 ); - - // the first sequence element - long nInitInd = 0; - CComVariant pFrameVariant( mpDispFrame ); - SafeArrayPutElement( pInitVals, &nInitInd, &pFrameVariant ); - - // the second sequence element - nInitInd = 1; - CComVariant pStrArr( 1L ); - SafeArrayPutElement( pInitVals, &nInitInd, &pStrArr ); - - // the third sequence element - nInitInd = 2; - CComPtr pdispValueObj; - hr = GetIDispByFunc( mpDispFactory, L"Bridge_GetValueObject", NULL, 0, pdispValueObj ); - if( !SUCCEEDED( hr ) || !pdispValueObj ) return hr; - - CComVariant aValueArgs[2]; - aValueArgs[1] = CComVariant( L"com.sun.star.embed.XActionsApproval" ); - CComPtr< CComObject< SOActionsApproval > > pApproval( new CComObject() ); - aValueArgs[0] = CComVariant ( pApproval ); - - hr = ExecuteFunc( pdispValueObj, L"Set", aValueArgs, 2, &dummyResult ); - if( !SUCCEEDED( hr ) ) return hr; - - CComVariant aValueObj( pdispValueObj ); - SafeArrayPutElement( pInitVals, &nInitInd, &aValueObj ); - - // execute initialize() - CComVariant aVarInitVals; - aVarInitVals.vt = VT_ARRAY | VT_VARIANT; aVarInitVals.parray = pInitVals; - hr = ExecuteFunc( mpInstanceLocker, L"initialize", &aVarInitVals, 1, &dummyResult ); - if( !SUCCEEDED( hr ) ) return hr; - } - - return S_OK; -} - -HRESULT CSOActiveX::CallLoadComponentFromURL1PBool( OLECHAR* sUrl, OLECHAR* sArgName, BOOL sArgVal ) -{ - SAFEARRAY FAR* pPropVals = SafeArrayCreateVector( VT_DISPATCH, 0, 1 ); - long ix = 0; - CComPtr pdispPropVal; - HRESULT hr = GetUnoStruct( L"com.sun.star.beans.PropertyValue", pdispPropVal ); - if( !SUCCEEDED( hr ) ) return hr; - - OLECHAR* sPropMemberNames[2] = { L"Name", L"Value" }; - CComVariant pPropVar[2]; - pPropVar[0] = CComVariant( sArgName ); - pPropVar[1].vt = VT_BOOL; pPropVar[1].boolVal = sArgVal ? VARIANT_TRUE : VARIANT_FALSE ; - hr = PutPropertiesToIDisp( pdispPropVal, sPropMemberNames, pPropVar, 2 ); - if( !SUCCEEDED( hr ) ) return hr; - - SafeArrayPutElement( pPropVals, &ix, pdispPropVal ); - - CComVariant aDispArgs[4]; - aDispArgs[3] = CComVariant( sUrl ); - aDispArgs[2] = CComVariant( L"_self" ); - aDispArgs[1] = CComVariant( 0 ); - // aDispArgs[0] = CComVariant( pPropVals ); such constructor is not defined ??! - aDispArgs[0].vt = VT_ARRAY | VT_DISPATCH; aDispArgs[0].parray = pPropVals; - - CComVariant dummyResult; - hr = ExecuteFunc( mpDispFrame, L"loadComponentFromURL", aDispArgs, 4, &dummyResult ); - if( !SUCCEEDED( hr ) ) return hr; - - return S_OK; -} - -HRESULT CSOActiveX::CallDispatchMethod( OLECHAR* sUrl, - CComVariant* aArgNames, - CComVariant* aArgVals, - unsigned int count ) -{ - CComPtr pdispURL; - HRESULT hr = GetUrlStruct( sUrl, pdispURL ); - if( !SUCCEEDED( hr ) ) return hr; - - CComPtr pdispXDispatch; - CComVariant aArgs[3]; - aArgs[2] = CComVariant( pdispURL ); - aArgs[1] = CComVariant( L"" ); - aArgs[0] = CComVariant( (int)0 ); - hr = GetIDispByFunc( mpDispFrame, - L"queryDispatch", - aArgs, - 3, - pdispXDispatch ); - if( !SUCCEEDED( hr ) ) return hr; - - SAFEARRAY FAR* pPropVals = SafeArrayCreateVector( VT_DISPATCH, 0, count ); - for( long ix = 0; ix < (long)count; ix ++ ) - { - CComPtr pdispPropVal; - hr = GetUnoStruct( L"com.sun.star.beans.PropertyValue", pdispPropVal ); - if( !SUCCEEDED( hr ) ) return hr; - - OLECHAR* sPropMemberNames[2] = { L"Name", L"Value" }; - CComVariant pPropVar[2]; - pPropVar[0] = aArgNames[ix]; - pPropVar[1] = aArgVals[ix]; - hr = PutPropertiesToIDisp( pdispPropVal, sPropMemberNames, pPropVar, 2 ); - if( !SUCCEEDED( hr ) ) return hr; - - SafeArrayPutElement( pPropVals, &ix, pdispPropVal ); - } - - CComVariant aDispArgs[2]; - aDispArgs[1] = CComVariant( pdispURL ); - // aDispArgs[0] = CComVariant( pPropVals ); such constructor is not defined ??! - aDispArgs[0].vt = VT_ARRAY | VT_DISPATCH; aDispArgs[0].parray = pPropVals; - - CComVariant dummyResult; - hr = ExecuteFunc( pdispXDispatch, L"dispatch", aDispArgs, 2, &dummyResult ); - if( !SUCCEEDED( hr ) ) return hr; - - return S_OK; -} - -void CSOActiveX::CallbackCreateXInputStream( CBindStatusCallback* /*pbsc*/, BYTE* pBytes, DWORD dwSize ) -{ - if ( mbReadyForActivation ) - return; - - BOOL bSuccess = FALSE; - BOOL bFinishDownload = FALSE; - if ( !pBytes ) - { - // means the download is finished, dwSize contains hresult - bFinishDownload = TRUE; - if ( SUCCEEDED( dwSize ) ) - bSuccess = TRUE; - } - else - { - HRESULT hr = S_OK; - - if ( !mpDispTempFile ) - { - CComVariant aServiceName( L"com.sun.star.io.TempFile" ); - hr = GetIDispByFunc( mpDispFactory, - L"createInstance", - &aServiceName, - 1, - mpDispTempFile ); - } - - if( SUCCEEDED( hr ) && mpDispTempFile ) - { - SAFEARRAY FAR* pDataArray = SafeArrayCreateVector( VT_I1, 0, dwSize ); - - if ( pDataArray ) - { - hr = SafeArrayLock( pDataArray ); - if ( SUCCEEDED( hr ) ) - { - for( DWORD ix = 0; ix < dwSize; ix++ ) - ((BYTE*)(pDataArray->pvData))[ix] = pBytes[ix]; - hr = SafeArrayUnlock( pDataArray ); - if ( SUCCEEDED( hr ) ) - { - CComVariant aArgs[1]; - aArgs[0].vt = VT_ARRAY | VT_I1; aArgs[0].parray = pDataArray; - CComVariant dummyResult; - hr = ExecuteFunc( mpDispTempFile, L"writeBytes", aArgs, 1, &dummyResult ); - if( SUCCEEDED( hr ) ) - bSuccess = TRUE; - } - } - } - } - } - - if ( !bSuccess ) - { - // the download failed, let StarOffice download - bFinishDownload = TRUE; - mpDispTempFile = CComPtr< IDispatch >(); - } - - if ( bFinishDownload ) - { - // trigger the loading now - mbLoad = TRUE; - mbReadyForActivation = TRUE; - - Invalidate(); - UpdateWindow(); - } -} - -HRESULT CSOActiveX::LoadURLToFrame( ) -{ - CComVariant aArgNames[4] = { L"ReadOnly", L"ViewOnly", L"AsTemplate", L"InputStream" }; - CComVariant aArgVals[4]; - unsigned int nCount = 3; // the 4-th argument is used only if the stream can be retrieved - - aArgVals[0].vt = VT_BOOL; aArgVals[0].boolVal = mbViewOnly ? VARIANT_TRUE : VARIANT_FALSE; - aArgVals[1].vt = VT_BOOL; aArgVals[1].boolVal = mbViewOnly ? VARIANT_TRUE : VARIANT_FALSE; - aArgVals[2].vt = VT_BOOL; aArgVals[2].boolVal = VARIANT_FALSE; - - if ( mpDispTempFile ) - { - aArgVals[3] = CComVariant( mpDispTempFile ); - nCount = 4; - } - - HRESULT hr = CallDispatchMethod( mCurFileUrl, aArgNames, aArgVals, nCount ); - if( !SUCCEEDED( hr ) ) return hr; - - CComVariant aBarName( L"MenuBarVisible" ); - CComVariant aBarVis; - aBarVis.vt = VT_BOOL; aBarVis.boolVal = VARIANT_FALSE; - hr = CallDispatchMethod( L"slot:6661", &aBarName, &aBarVis, 1 ); - // does not work for some documents, but it is no error - // if( !SUCCEEDED( hr ) ) return hr; - - // try to get the model and set the presetation specific property, the setting will fail for other document formats - CComPtr pdispController; - hr = GetIDispByFunc( mpDispFrame, L"getController", NULL, 0, pdispController ); - if ( SUCCEEDED( hr ) && pdispController ) - { - CComPtr pdispModel; - hr = GetIDispByFunc( pdispController, L"getModel", NULL, 0, pdispModel ); - if ( SUCCEEDED( hr ) && pdispModel ) - { - CComPtr pdispPres; - hr = GetIDispByFunc( pdispModel, L"getPresentation", NULL, 0, pdispPres ); - if ( SUCCEEDED( hr ) && pdispPres ) - { - // this is a presentation - // let the slide show be shown in the document window - OLECHAR* pPropName = L"IsFullScreen"; - CComVariant pPresProp; - pPresProp.vt = VT_BOOL; pPresProp.boolVal = VARIANT_FALSE ; - hr = PutPropertiesToIDisp( pdispPres, &pPropName, &pPresProp, 1 ); - - // start the slide show - if ( SUCCEEDED( hr ) ) - { - CComVariant dummyResult; - ExecuteFunc( pdispPres, L"Start", NULL, 0, &dummyResult ); - } - } - } - } - - // create dispatch interceptor - mpDispatchInterceptor = new CComObject< SODispatchInterceptor >(); - mpDispatchInterceptor->AddRef(); - mpDispatchInterceptor->SetParent( this ); - CComQIPtr< IDispatch, &IID_IDispatch > pIDispDispInter( mpDispatchInterceptor ); - - // register dispatch interceptor in the frame - CComVariant aDispVariant( pIDispDispInter ); - CComVariant dummyResult; - hr = ExecuteFunc( mpDispFrame, - L"registerDispatchProviderInterceptor", - &aDispVariant, - 1, - &dummyResult ); - - if( !SUCCEEDED( hr ) ) return hr; - - return S_OK; -} - -SOVersion CSOActiveX::GetVersionConnected() -{ - SOVersion bResult = SO_NOT_DETECTED; - if( mpDispFactory ) - { - // create ConfigurationProvider instance - CComPtr pdispConfProv; - CComVariant aServiceName( L"com.sun.star.configuration.ConfigurationProvider" ); - HRESULT hr = GetIDispByFunc( mpDispFactory, - L"createInstance", - &aServiceName, - 1, - pdispConfProv ); - - if( SUCCEEDED( hr ) && pdispConfProv ) - { - CComPtr pdispConfAccess; - - SAFEARRAY* pInitParams = SafeArrayCreateVector( VT_VARIANT, 0, 1 ); - - if( pInitParams ) - { - long ix = 0; - CComVariant aConfPath( L"org.openoffice.Setup" ); - SafeArrayPutElement( pInitParams, &ix, &aConfPath ); - - CComVariant aArgs[2]; - aArgs[1] = CComVariant( L"com.sun.star.configuration.ConfigurationAccess" ); - aArgs[0].vt = VT_ARRAY | VT_VARIANT; aArgs[0].parray = pInitParams; - - hr = GetIDispByFunc( pdispConfProv, - L"createInstanceWithArguments", - aArgs, - 2, - pdispConfAccess ); - - if( SUCCEEDED( hr ) && pdispConfAccess ) - { - CComVariant aOfficeName; - - CComVariant aProductName( L"Product/ooName" ); - hr = ExecuteFunc( pdispConfAccess, - L"getByHierarchicalName", - &aProductName, - 1, - &aOfficeName ); - - if( SUCCEEDED( hr ) && aOfficeName.vt == VT_BSTR ) - { - CComVariant aOfficeVersion; - - CComVariant aProductVersion( L"Product/ooSetupVersion" ); - hr = ExecuteFunc( pdispConfAccess, - L"getByHierarchicalName", - &aProductVersion, - 1, - &aOfficeVersion ); - - if( SUCCEEDED( hr ) && aOfficeVersion.vt == VT_BSTR ) - { - USES_CONVERSION; - if( !strcmp( OLE2T( aOfficeName.bstrVal ), "StarOffice" ) ) - { - if( !strncmp( OLE2T( aOfficeVersion.bstrVal ), "6.1", 3 ) ) - bResult = SO_61; - else if( !strncmp( OLE2T( aOfficeVersion.bstrVal ), "6.0", 3 ) ) - bResult = SO_60; - else if( !strncmp( OLE2T( aOfficeVersion.bstrVal ), "5.2", 3 ) ) - bResult = SO_52; - else - bResult = SO_UNKNOWN; - } - else // OpenOffice - { - if( !strncmp( OLE2T( aOfficeVersion.bstrVal ), "1.1", 3 ) ) - bResult = OO_11; - else if( !strncmp( OLE2T( aOfficeVersion.bstrVal ), "1.0", 3 ) ) - bResult = OO_10; - else - bResult = OO_UNKNOWN; - } - } - } - } - } - } - } - - return bResult; -} - -class LockingGuard -{ - BOOL& mbLocked; -public: - LockingGuard( BOOL& bLocked ) - : mbLocked( bLocked ) - { - mbLocked = TRUE; - } - - ~LockingGuard() - { - mbLocked = FALSE; - } -}; - -HRESULT CSOActiveX::OnDrawAdvanced( ATL_DRAWINFO& di ) -{ - // This method is called only in main thread, no need to lock it - - // Get read of reentrance problems - if ( mbDrawLocked ) - return S_OK; - LockingGuard aGuard( mbDrawLocked ); - - if( m_spInPlaceSite && mCurFileUrl && mbReadyForActivation ) - { - HWND hwnd; - HRESULT hr = m_spInPlaceSite->GetWindow( &hwnd ); - if( !SUCCEEDED( hr ) ) return hr; - - if( mParentWin != hwnd || !mOffWin ) - { - if( mpDispFrame ) - { - CComVariant dummyResult; - CComVariant aPropVar; - aPropVar.vt = VT_BOOL; aPropVar.boolVal = VARIANT_FALSE; - HRESULT hr = ExecuteFunc( mpDispFrame, L"close", &aPropVar, 1, &dummyResult ); - (void)hr; - mpDispFrame = CComPtr(); - } - - mParentWin = hwnd; - mOffWin = CreateWindow( - STAROFFICE_WINDOWCLASS, - "OfficeContainer", - WS_CHILD | WS_CLIPCHILDREN | WS_BORDER, - di.prcBounds->left, - di.prcBounds->top, - di.prcBounds->right - di.prcBounds->left, - di.prcBounds->bottom - di.prcBounds->top, - mParentWin, - NULL, - NULL, - NULL ); - - ::ShowWindow( mOffWin, SW_SHOW ); - } - else - { - RECT aRect; - ::GetWindowRect( mOffWin, &aRect ); - - if( aRect.left != di.prcBounds->left || aRect.top != di.prcBounds->top - || aRect.right != di.prcBounds->right || aRect.bottom != di.prcBounds->bottom ) - { - // on this state the office window should exist already - ::SetWindowPos( mOffWin, - HWND_TOP, - di.prcBounds->left, - di.prcBounds->top, - di.prcBounds->right - di.prcBounds->left, - di.prcBounds->bottom - di.prcBounds->top, - SWP_NOZORDER ); - - CComVariant aPosArgs[5]; - aPosArgs[4] = CComVariant( 0 ); - aPosArgs[3] = CComVariant( 0 ); - aPosArgs[2] = CComVariant( int(di.prcBounds->right - di.prcBounds->left) ); - aPosArgs[1] = CComVariant( int(di.prcBounds->bottom - di.prcBounds->top) ); - aPosArgs[0] = CComVariant( 12 ); - CComVariant dummyResult; - hr = ExecuteFunc( mpDispWin, L"setPosSize", aPosArgs, 5, &dummyResult ); - if( !SUCCEEDED( hr ) ) return hr; - } - } - - if( !mnVersion ) - { - OutputError_Impl( mOffWin, CS_E_INVALID_VERSION ); - return E_FAIL; - } - - if( ! mpDispFrame ) - { - hr = CreateFrameOldWay( mOffWin, - di.prcBounds->right - di.prcBounds->left, - di.prcBounds->bottom - di.prcBounds->top ); - - if( !SUCCEEDED( hr ) ) - { - // if the frame can not be opened do not try any more - mbReadyForActivation = FALSE; - OutputError_Impl( mOffWin, STG_E_ABNORMALAPIEXIT ); - return hr; - } - } - - if( mbLoad ) - { - hr = LoadURLToFrame(); - mbLoad = FALSE; - - if( !SUCCEEDED( hr ) ) - { - // if the document can not be opened do not try any more - mbReadyForActivation = FALSE; - - OutputError_Impl( mOffWin, STG_E_ABNORMALAPIEXIT ); - - return hr; - } - } - } - else - { - // activate the fallback - CComControl::OnDrawAdvanced( di ); - } - - return S_OK; -} - -HRESULT CSOActiveX::OnDraw( ATL_DRAWINFO& di ) -{ - // fallback that is activated by the parent class - if ( di.hdcDraw ) - FillRect( di.hdcDraw, (RECT*)di.prcBounds, (HBRUSH)COLOR_BACKGROUND ); - - return S_OK; -} - -STDMETHODIMP CSOActiveX::SetClientSite( IOleClientSite* aClientSite ) -{ - HRESULT hr = IOleObjectImpl::SetClientSite( aClientSite ); - - if( !aClientSite ) - { - //ATLASSERT( mWebBrowser2 ); - if( mWebBrowser2 ) - AtlUnadvise( mWebBrowser2, DIID_DWebBrowserEvents2, mCookie ); - return hr; - } - - CComPtr aContainer; - m_spClientSite->GetContainer( &aContainer ); -// ATLASSERT( aContainer ); - - if( SUCCEEDED( hr ) && aContainer ) - { - CComQIPtr aServiceProvider( aContainer ); - //ATLASSERT( aServiceProvider ); - - if( aServiceProvider ) - { - aServiceProvider->QueryService( SID_SInternetExplorer, - IID_IWebBrowser, - (void**)&mWebBrowser2 ); -// ATLASSERT( mWebBrowser2 ); - if( mWebBrowser2 ) - AtlAdvise( mWebBrowser2, GetUnknown(), DIID_DWebBrowserEvents2, &mCookie ); - } - } - - return hr; -} - -STDMETHODIMP CSOActiveX::Invoke(DISPID dispidMember, - REFIID riid, - LCID lcid, - WORD wFlags, - DISPPARAMS* pDispParams, - VARIANT* pvarResult, - EXCEPINFO* pExcepInfo, - UINT* puArgErr) -{ - if (riid != IID_NULL) - return DISP_E_UNKNOWNINTERFACE; - - if (!pDispParams) - return DISP_E_PARAMNOTOPTIONAL; - - if ( dispidMember == DISPID_ONQUIT ) - Cleanup(); - - IDispatchImpl::Invoke( - dispidMember, riid, lcid, wFlags, pDispParams, - pvarResult, pExcepInfo, puArgErr); - - return S_OK; -} - -HRESULT CSOActiveX::GetURL( const OLECHAR* url, - const OLECHAR* target ) -{ - CComVariant aEmpty1, aEmpty2, aEmpty3; - CComVariant aUrl( url ); - CComVariant aTarget; - if ( target ) - aTarget = CComVariant( target ); - - return mWebBrowser2->Navigate2( &aUrl, - &aEmpty1, - &aTarget, - &aEmpty2, - &aEmpty3 ); -} - - -// --------------------------------------------------------------------------- - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/SOActiveX.h b/extensions/source/activex/main/SOActiveX.h deleted file mode 100644 index fea95d09c9b9..000000000000 --- a/extensions/source/activex/main/SOActiveX.h +++ /dev/null @@ -1,178 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// SOActiveX.h : Declaration of the CSOActiveX - -#ifndef __SOACTIVEX_H_ -#define __SOACTIVEX_H_ - -#include "resource.h" // main symbols - -#pragma warning (disable:4505) - // permanently suppress "unreferenced local function has been removed" warning - -#pragma warning (push,1) -#pragma warning (disable:4265) - -#include -#include -#include - -#if defined(_MSC_VER) && (_MSC_VER >= 1300) -#undef _DEBUG -#endif -#include - -#include "so_activex.h" - -#pragma warning (pop) - -class SODispatchInterceptor; - -enum SOVersion { - SO_NOT_DETECTED = 0, - SO_52, - SO_60, - SO_61, - SO_UNKNOWN, - OO_10, - OO_11, - OO_UNKNOWN -}; - -///////////////////////////////////////////////////////////////////////////// -// CSOActiveX -class ATL_NO_VTABLE CSOActiveX : - public CComObjectRootEx, - public IDispatchImpl, - public CComControl, - public IPersistStreamInitImpl, - public IOleControlImpl, - public IOleObjectImpl, - public IOleInPlaceActiveObjectImpl, - public IViewObjectExImpl, - public IOleInPlaceObjectWindowlessImpl, -// public IConnectionPointContainerImpl, - public CComCoClass, -// public CProxy_ItryPluginEvents< CSOActiveX >, - public IPersistPropertyBagImpl< CSOActiveX >, - public IProvideClassInfo2Impl< &CLSID_SOActiveX, - &DIID__ISOActiveXEvents, - &LIBID_SO_ACTIVEXLib >, - public IObjectSafetyImpl< CSOActiveX, - INTERFACESAFE_FOR_UNTRUSTED_DATA > -{ -protected: - CComPtr mWebBrowser2; - DWORD mCookie; - - CComPtr mpDispFactory; - CComPtr mpDispFrame; - CComPtr mpInstanceLocker; - CComPtr mpDispWin; - OLECHAR* mCurFileUrl; - BOOL mbLoad; - BOOL mbViewOnly; - WNDCLASS mPWinClass; - HWND mParentWin; - HWND mOffWin; - - SODispatchInterceptor* mpDispatchInterceptor; - SOVersion mnVersion; - - BOOL mbReadyForActivation; - CComPtr mpDispTempFile; - - BOOL mbDrawLocked; - -public: - CSOActiveX(); - ~CSOActiveX(); - -DECLARE_REGISTRY_RESOURCEID(IDR_SOACTIVEX) - -DECLARE_PROTECT_FINAL_CONSTRUCT() - -BEGIN_COM_MAP(CSOActiveX) - COM_INTERFACE_ENTRY(ISOActiveX) - COM_INTERFACE_ENTRY(IDispatch) - COM_INTERFACE_ENTRY(IViewObjectEx) - COM_INTERFACE_ENTRY(IViewObject2) - COM_INTERFACE_ENTRY(IViewObject) - COM_INTERFACE_ENTRY(IOleInPlaceObjectWindowless) - COM_INTERFACE_ENTRY(IOleInPlaceObject) - COM_INTERFACE_ENTRY2(IOleWindow, IOleInPlaceObjectWindowless) - COM_INTERFACE_ENTRY(IOleInPlaceActiveObject) - COM_INTERFACE_ENTRY(IOleControl) - COM_INTERFACE_ENTRY(IOleObject) - COM_INTERFACE_ENTRY(IPersistStreamInit) - COM_INTERFACE_ENTRY2(IPersist, IPersistStreamInit) -// COM_INTERFACE_ENTRY(IConnectionPointContainer) - COM_INTERFACE_ENTRY(IProvideClassInfo) - COM_INTERFACE_ENTRY(IProvideClassInfo2) - COM_INTERFACE_ENTRY(IPersistPropertyBag) - COM_INTERFACE_ENTRY(IObjectSafety) -END_COM_MAP() - -BEGIN_PROP_MAP(CSOActiveX) - PROP_DATA_ENTRY("_cx", m_sizeExtent.cx, VT_UI4) - PROP_DATA_ENTRY("_cy", m_sizeExtent.cy, VT_UI4) - // Example entries - // PROP_ENTRY("Property Description", dispid, clsid) - // PROP_PAGE(CLSID_StockColorPage) -END_PROP_MAP() - -BEGIN_CONNECTION_POINT_MAP(CSOActiveX) -END_CONNECTION_POINT_MAP() - -BEGIN_MSG_MAP(CSOActiveX) - CHAIN_MSG_MAP(CComControl) - DEFAULT_REFLECTION_HANDLER() -END_MSG_MAP() -// Handler prototypes: -// LRESULT MessageHandler(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled); -// LRESULT CommandHandler(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled); -// LRESULT NotifyHandler(int idCtrl, LPNMHDR pnmh, BOOL& bHandled); - - - -// IViewObjectEx - DECLARE_VIEW_STATUS(VIEWSTATUS_SOLIDBKGND | VIEWSTATUS_OPAQUE) - -// ISOActiveX -public: - - STDMETHOD(SetClientSite)( IOleClientSite* aClientSite ); - STDMETHOD(Invoke)( DISPID dispidMember, - REFIID riid, - LCID lcid, - WORD wFlags, - DISPPARAMS* pDispParams, - VARIANT* pvarResult, - EXCEPINFO* pExcepInfo, - UINT* puArgErr); - STDMETHOD(Load) ( LPPROPERTYBAG pPropBag, LPERRORLOG pErrorLog ); - STDMETHOD(Load) ( LPSTREAM pStm ); - STDMETHOD(InitNew) (); - HRESULT OnDrawAdvanced(ATL_DRAWINFO& di); - HRESULT OnDraw(ATL_DRAWINFO& di); - - HRESULT SetLayoutManagerProps(); - HRESULT CreateFrameOldWay( HWND hwnd, int width, int height ); - HRESULT GetUnoStruct( OLECHAR* sStructName, CComPtr& pdispResult ); - HRESULT LoadURLToFrame(); - HRESULT CallDispatchMethod( OLECHAR* sUrl, CComVariant* sArgNames, CComVariant* sArgVal, unsigned int count ); - HRESULT CallLoadComponentFromURL1PBool( OLECHAR* sUrl, OLECHAR* sArgName, BOOL sArgVal ); - HRESULT GetUrlStruct( OLECHAR* sUrl, CComPtr& pdispUrl ); - HRESULT Cleanup(); - HRESULT TerminateOffice(); - HRESULT GetURL( const OLECHAR* url, - const OLECHAR* target ); - - void CallbackCreateXInputStream( CBindStatusCallback* pbsc, BYTE* pBytes, DWORD dwSize ); - - - SOVersion GetVersionConnected(); -}; - -#endif //__SOACTIVEX_H_ - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/SOActiveX.rgs b/extensions/source/activex/main/SOActiveX.rgs deleted file mode 100644 index d3814df3b241..000000000000 --- a/extensions/source/activex/main/SOActiveX.rgs +++ /dev/null @@ -1,33 +0,0 @@ -HKCR -{ - so_activex.SOActiveX.1 = s 'SOActiveX Class' - { - CLSID = s '{67F2A879-82D5-4A6D-8CC5-FFB3C114B69D}' - } - so_activex.SOActiveX = s 'SOActiveX Class' - { - CLSID = s '{67F2A879-82D5-4A6D-8CC5-FFB3C114B69D}' - CurVer = s 'so_activex.SOActiveX.1' - } - NoRemove CLSID - { - ForceRemove {67F2A879-82D5-4A6D-8CC5-FFB3C114B69D} = s 'SOActiveX Class' - { - ProgID = s 'so_activex.SOActiveX.1' - VersionIndependentProgID = s 'so_activex.SOActiveX' - ForceRemove 'Programmable' - InprocServer32 = s '%MODULE%' - { - val ThreadingModel = s 'Apartment' - } - ForceRemove 'Control' - ForceRemove 'ToolboxBitmap32' = s '%MODULE%, 101' - 'MiscStatus' = s '0' - { - '1' = s '131473' - } - 'TypeLib' = s '{61FA3F13-8061-4796-B055-3697ED28CB38}' - 'Version' = s '1.0' - } - } -} diff --git a/extensions/source/activex/main/SOComWindowPeer.cpp b/extensions/source/activex/main/SOComWindowPeer.cpp deleted file mode 100644 index 7fb56dbdfd32..000000000000 --- a/extensions/source/activex/main/SOComWindowPeer.cpp +++ /dev/null @@ -1,31 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// SOComWindowPeer.cpp : Implementation of CHelpApp and DLL registration. - -#include "stdafx2.h" -#include "so_activex.h" -#include "SOComWindowPeer.h" -#include - -///////////////////////////////////////////////////////////////////////////// -// - -STDMETHODIMP SOComWindowPeer::InterfaceSupportsErrorInfo(REFIID riid) -{ - static const IID* arr[] = - { - &IID_ISOComWindowPeer, - }; - - for (int i=0;i= 1300) - if (InlineIsEqualGUID(*arr[i],riid)) -#else - if (::ATL::InlineIsEqualGUID(*arr[i],riid)) -#endif - return S_OK; - } - return S_FALSE; -} - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/SOComWindowPeer.h b/extensions/source/activex/main/SOComWindowPeer.h deleted file mode 100644 index c819e17a81ea..000000000000 --- a/extensions/source/activex/main/SOComWindowPeer.h +++ /dev/null @@ -1,136 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// SOComWindowPeer.h: Definition of the SOComWindowPeer class -// -////////////////////////////////////////////////////////////////////// - -#if !defined __SOCOMWINDOWPEER_H_ -#define __SOCOMWINDOWPEER_H_ - -#if _MSC_VER > 1000 -#pragma once -#endif // _MSC_VER > 1000 - -#include "resource.h" // main symbols -#include -#include -#include - -#if defined(_MSC_VER) && (_MSC_VER >= 1300) -#undef _DEBUG -#endif -#include - -#include "so_activex.h" - -///////////////////////////////////////////////////////////////////////////// -// SOComWindowPeer - -class SOComWindowPeer : - public IDispatchImpl, - public ISupportErrorInfo, - public CComObjectRoot, - public CComCoClass -{ - HWND m_hwnd; -public: - SOComWindowPeer() : m_hwnd( NULL ) {} - virtual ~SOComWindowPeer() { } - -BEGIN_COM_MAP(SOComWindowPeer) - COM_INTERFACE_ENTRY(IDispatch) - COM_INTERFACE_ENTRY(ISOComWindowPeer) - COM_INTERFACE_ENTRY(ISupportErrorInfo) -END_COM_MAP() -DECLARE_NOT_AGGREGATABLE(SOComWindowPeer) -// Remove the comment from the line above if you don't want your object to -// support aggregation. - -DECLARE_REGISTRY_RESOURCEID(IDR_SOCOMWINDOWPEER) - -// ISupportsErrorInfo - STDMETHOD(InterfaceSupportsErrorInfo)(REFIID riid); - -// ISOComWindowPeer - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE getWindowHandle( - /* [in] */ SAFEARRAY __RPC_FAR * /*procId*/, - /* [in] */ short /*s*/, - /* [retval][out] */ long __RPC_FAR *ret) - { - *ret = HandleToLong( m_hwnd ); - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE getToolkit( - /* [retval][out] */ IDispatch __RPC_FAR *__RPC_FAR *retVal) - { - *retVal = NULL; - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE setPointer( - /* [in] */ IDispatch __RPC_FAR* /*xPointer*/) - { - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE setBackground( - /* [in] */ int /*nColor*/) - { - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE invalidate( - /* [in] */ short /*__MIDL_0015*/) - { - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE invalidateRect( - /* [in] */ IDispatch __RPC_FAR* /*aRect*/, - /* [in] */ short /*nFlags*/) - { - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE dispose( void) - { - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE addEventListener( - /* [in] */ IDispatch __RPC_FAR* /*xListener*/) - { - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE removeEventListener( - /* [in] */ IDispatch __RPC_FAR* /*xListener*/) - { - return S_OK; - } - - virtual /* [helpstring][id][propget] */ HRESULT STDMETHODCALLTYPE get_Bridge_implementedInterfaces( - /* [retval][out] */ SAFEARRAY __RPC_FAR * __RPC_FAR *pVal) - { - *pVal = SafeArrayCreateVector( VT_BSTR, 0, 2 ); - - if( !*pVal ) - return E_FAIL; - - long ix = 0; - CComBSTR aInterface( OLESTR( "com.sun.star.awt.XSystemDependentWindowPeer" ) ); - SafeArrayPutElement( *pVal, &ix, aInterface ); - - ix = 1; - aInterface = CComBSTR( OLESTR( "com.sun.star.awt.XWindowPeer" ) ); - SafeArrayPutElement( *pVal, &ix, aInterface ); - - return S_OK; - } - - void SetHWNDInternally( HWND hwnd ) { m_hwnd = hwnd; } -}; - -#endif // __SOCOMWINDOWPEER_H_ - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/SOComWindowPeer.rgs b/extensions/source/activex/main/SOComWindowPeer.rgs deleted file mode 100644 index 42e985a31a1b..000000000000 --- a/extensions/source/activex/main/SOComWindowPeer.rgs +++ /dev/null @@ -1,23 +0,0 @@ -HKCR -{ - so_activex.SOComWindowPeer.1 = s 'SOComWindowPeer Class' - { - CLSID = s '{EE51BD3E-8BB6-4FB8-B319-F65B1BE3B21D}' - } - so_activex.SOComWindowPeer = s 'SOComWindowPeer Class' - { - CLSID = s '{EE51BD3E-8BB6-4FB8-B319-F65B1BE3B21D}' - } - NoRemove CLSID - { - ForceRemove {EE51BD3E-8BB6-4FB8-B319-F65B1BE3B21D} = s 'SOComWindowPeer Class' - { - ProgID = s 'so_activex.SOComWindowPeer.1' - VersionIndependentProgID = s 'so_activex.SOComWindowPeer' - InprocServer32 = s '%MODULE%' - { - val ThreadingModel = s 'both' - } - } - } -} diff --git a/extensions/source/activex/main/SODispatchInterceptor.cpp b/extensions/source/activex/main/SODispatchInterceptor.cpp deleted file mode 100644 index dcddf0d86b0c..000000000000 --- a/extensions/source/activex/main/SODispatchInterceptor.cpp +++ /dev/null @@ -1,225 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// SODispatchInterceptor.cpp : Implementation of CHelpApp and DLL registration. - -#include "stdio.h" -#include "stdafx2.h" -#include "so_activex.h" -#include "SOActiveX.h" -#include "SODispatchInterceptor.h" -#include "com_uno_helper.h" -#include - -///////////////////////////////////////////////////////////////////////////// -// - -STDMETHODIMP SODispatchInterceptor::InterfaceSupportsErrorInfo(REFIID riid) -{ - static const IID* arr[] = - { - &IID_ISODispatchInterceptor, - }; - - for (int i=0;i= 1300) - if (InlineIsEqualGUID(*arr[i],riid)) -#else - if (::ATL::InlineIsEqualGUID(*arr[i],riid)) -#endif - return S_OK; - } - return S_FALSE; -} - -STDMETHODIMP SODispatchInterceptor::queryDispatch( IDispatch FAR* aURL, - BSTR aTargetFrameName, - long nSearchFlags, - IDispatch FAR* FAR* retVal ) -{ - if ( !aURL || !retVal ) return E_FAIL; - - CComVariant aTargetUrl; - OLECHAR* sURLMemberName = L"Complete"; - DISPID nURLID; - HRESULT hr = aURL->GetIDsOfNames( IID_NULL, &sURLMemberName, 1, LOCALE_USER_DEFAULT, &nURLID ); - if( !SUCCEEDED( hr ) ) return hr; - - hr = CComDispatchDriver::GetProperty( aURL, nURLID, &aTargetUrl ); - if( !SUCCEEDED( hr ) ) return hr; - - if( aTargetUrl.vt != VT_BSTR ) return E_FAIL; - - USES_CONVERSION; - if( !strncmp( OLE2T( aTargetUrl.bstrVal ), ".uno:OpenHyperlink", 18 ) ) - { - CComQIPtr< IDispatch, &IID_IDispatch > pIDisp( this ); - if( pIDisp ) - { - this->AddRef(); - *retVal = pIDisp; - } - } - else - { - if( !m_xSlave ) - { - *retVal = NULL; - return S_OK; - } - - CComVariant aResult; - CComVariant aArgs[3]; - aArgs[0] = CComVariant( nSearchFlags ); - aArgs[1] = CComVariant( aTargetFrameName ); - aArgs[2] = CComVariant( aURL ); - - hr = ExecuteFunc( m_xSlave, L"queryDispatch", aArgs, 3, &aResult ); - if( !SUCCEEDED( hr ) || aResult.vt != VT_DISPATCH || aResult.pdispVal == NULL ) - { - *retVal = NULL; - return S_OK; - } - - *retVal = aResult.pdispVal; - - CComQIPtr< IUnknown, &IID_IUnknown > pIUnk( *retVal ); - if( pIUnk ) - (*retVal)->AddRef(); - } - - return S_OK; -} - -STDMETHODIMP SODispatchInterceptor::queryDispatches( SAFEARRAY FAR* aDescripts, SAFEARRAY FAR* FAR* retVal) -{ - if ( !aDescripts || !retVal || SafeArrayGetDim( aDescripts ) != 1 ) - return E_FAIL; - - long nLB, nUB; - - HRESULT hr = SafeArrayGetLBound( aDescripts, 1, &nLB ); - if( !SUCCEEDED( hr ) ) return hr; - - hr = SafeArrayGetUBound( aDescripts, 1, &nUB ); - if( !SUCCEEDED( hr ) ) return hr; - if( nUB < nLB ) return E_FAIL; - - *retVal = SafeArrayCreateVector( VT_DISPATCH, 0, nUB - nLB ); - - for ( long ind = nLB; ind <= nUB; ind ++ ) - { - CComPtr pElem; - SafeArrayGetElement( aDescripts, &ind, pElem ); - if( pElem ) - { - OLECHAR* pMemberNames[3] = { L"FeatureURL", L"FrameName", L"SearchFlags" }; - CComVariant pValues[3]; - hr = GetPropertiesFromIDisp( pElem, pMemberNames, pValues, 3 ); - if( !SUCCEEDED( hr ) ) return hr; - if( pValues[0].vt != VT_DISPATCH || pValues[0].pdispVal == NULL - || pValues[1].vt != VT_BSTR || pValues[2].vt != VT_I4 ) - return E_FAIL; - - CComPtr aRes; - hr = queryDispatch( pValues[0].pdispVal, pValues[1].bstrVal, pValues[2].lVal, &aRes ); - SafeArrayPutElement( *retVal, &ind, aRes ); - } - } - - return S_OK; -} - - -STDMETHODIMP SODispatchInterceptor::dispatch( IDispatch FAR* aURL, SAFEARRAY FAR* aArgs) -{ - // get url from aURL - OLECHAR* pUrlName = L"Complete"; - CComVariant pValue; - HRESULT hr = GetPropertiesFromIDisp( aURL, &pUrlName, &pValue, 1 ); - if( !SUCCEEDED( hr ) ) return hr; - if( pValue.vt != VT_BSTR || pValue.bstrVal == NULL ) - return E_FAIL; - - USES_CONVERSION; - if( !strncmp( OLE2T( pValue.bstrVal ), ".uno:OpenHyperlink", 18 ) ) - { - long nLB = 0, nUB = 0; - // long nDim = SafeArrayGetDim( aArgs ); - - hr = SafeArrayGetLBound( aArgs, 1, &nLB ); - if( !SUCCEEDED( hr ) ) return hr; - - hr = SafeArrayGetUBound( aArgs, 1, &nUB ); - if( !SUCCEEDED( hr ) ) return hr; - if( nUB < nLB ) return E_FAIL; - - for ( long ind = nLB; ind <= nUB; ind ++ ) - { - CComVariant pVarElem; - SafeArrayGetElement( aArgs, &ind, &pVarElem ); - if( pVarElem.vt == VT_DISPATCH && pVarElem.pdispVal != NULL ) - { - OLECHAR* pMemberNames[2] = { L"Name", L"Value" }; - CComVariant pValues[2]; - hr = GetPropertiesFromIDisp( pVarElem.pdispVal, pMemberNames, pValues, 2 ); - if( !SUCCEEDED( hr ) ) return hr; - - if( pValues[0].vt == VT_BSTR && pValues[1].vt == VT_BSTR ) - { - USES_CONVERSION; - if( !strncmp( OLE2T( pValues[0].bstrVal ), "URL", 3 ) ) - { - EnterCriticalSection( &mMutex ); - if( m_xParentControl ) - { - // call GetUrl to the browser instance - m_xParentControl->GetURL( pValues[1].bstrVal, L"_self" ); - } - LeaveCriticalSection( &mMutex ); - - break; - } - } - } - } - } - - return S_OK; -} - -STDMETHODIMP SODispatchInterceptor::addStatusListener( IDispatch FAR* /*xControl*/, IDispatch FAR* /*aURL*/) -{ - // not implemented - return S_OK; -} - -STDMETHODIMP SODispatchInterceptor::removeStatusListener( IDispatch FAR* /*xControl*/, IDispatch FAR* /*aURL*/) -{ - // not implemented - return S_OK; -} - -STDMETHODIMP SODispatchInterceptor::getInterceptedURLs( SAFEARRAY FAR* FAR* pVal ) -{ - *pVal = SafeArrayCreateVector( VT_BSTR, 0, 3 ); - - if( !*pVal ) - return E_FAIL; - - long ix = 0; - CComBSTR aPattern( OLESTR( "ftp://*" ) ); - SafeArrayPutElement( *pVal, &ix, aPattern ); - - ix = 1; - aPattern = CComBSTR( OLESTR( "http://*" ) ); - SafeArrayPutElement( *pVal, &ix, aPattern ); - - ix = 2; - aPattern = CComBSTR( OLESTR( "file://*" ) ); - SafeArrayPutElement( *pVal, &ix, aPattern ); - - return S_OK; -} - - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/SODispatchInterceptor.h b/extensions/source/activex/main/SODispatchInterceptor.h deleted file mode 100644 index 538b12f24d2e..000000000000 --- a/extensions/source/activex/main/SODispatchInterceptor.h +++ /dev/null @@ -1,158 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// SODispatchInterceptor.h: Definition of the SODispatchInterceptor class -// -////////////////////////////////////////////////////////////////////// - -#if !defined __SODISPATCHINTERCEPTOR_H_ -#define __SODISPATCHINTERCEPTOR_H_ - -#if _MSC_VER > 1000 -#pragma once -#endif // _MSC_VER > 1000 - -#include "resource.h" // main symbols -#include -#include -#include - -#if defined(_MSC_VER) && (_MSC_VER >= 1300) -#undef _DEBUG -#endif -#include - -#include "so_activex.h" - -class CSOActiveX; - -///////////////////////////////////////////////////////////////////////////// -// SODispatchInterceptor - -class SODispatchInterceptor : - public IDispatchImpl, - public ISupportErrorInfo, - public CComObjectRoot, - public CComCoClass -{ - CComPtr m_xMaster; - CComPtr m_xSlave; - CSOActiveX* m_xParentControl; - CRITICAL_SECTION mMutex; -public: - SODispatchInterceptor() : m_xParentControl( NULL ) { InitializeCriticalSection(&mMutex); } - virtual ~SODispatchInterceptor() { ATLASSERT( !m_xParentControl ); DeleteCriticalSection(&mMutex); } - -BEGIN_COM_MAP(SODispatchInterceptor) - COM_INTERFACE_ENTRY(IDispatch) - COM_INTERFACE_ENTRY(ISODispatchInterceptor) - COM_INTERFACE_ENTRY(ISupportErrorInfo) -END_COM_MAP() -DECLARE_NOT_AGGREGATABLE(SODispatchInterceptor) -// Remove the comment from the line above if you don't want your object to -// support aggregation. - -DECLARE_REGISTRY_RESOURCEID(IDR_SODISPATCHINTERCEPTOR) - - void SetParent( CSOActiveX* pParent ) - { - ATLASSERT( !m_xParentControl ); - EnterCriticalSection( &mMutex ); - m_xParentControl = pParent; - LeaveCriticalSection( &mMutex ); - } - - void ClearParent() - { - EnterCriticalSection( &mMutex ); - m_xParentControl = NULL; - LeaveCriticalSection( &mMutex ); - } - -// ISupportsErrorInfo - STDMETHOD(InterfaceSupportsErrorInfo)(REFIID riid); - -// ISODispatchInterceptor - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE getSlaveDispatchProvider( - /* [retval][out] */ IDispatch __RPC_FAR *__RPC_FAR *retVal) - { - *retVal = m_xSlave; - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE setSlaveDispatchProvider( - /* [in] */ IDispatch __RPC_FAR *xNewDispatchProvider) - { - m_xSlave = xNewDispatchProvider; - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE getMasterDispatchProvider( - /* [retval][out] */ IDispatch __RPC_FAR *__RPC_FAR *retVal) - { - *retVal = m_xMaster; - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE setMasterDispatchProvider( - /* [in] */ IDispatch __RPC_FAR *xNewSupplier) - { - m_xMaster = xNewSupplier; - return S_OK; - } - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE queryDispatch( - /* [in] */ IDispatch __RPC_FAR *aURL, - /* [in] */ BSTR aTargetFrameName, - /* [in] */ long nSearchFlags, - /* [retval][out] */ IDispatch __RPC_FAR *__RPC_FAR *retVal); - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE queryDispatches( - /* [in] */ SAFEARRAY __RPC_FAR * aDescripts, - /* [retval][out] */ SAFEARRAY __RPC_FAR * __RPC_FAR *retVal); - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE dispatch( - /* [in] */ IDispatch __RPC_FAR *aURL, - /* [in] */ SAFEARRAY __RPC_FAR * aArgs); - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE addStatusListener( - /* [in] */ IDispatch __RPC_FAR *xControl, - /* [in] */ IDispatch __RPC_FAR *aURL); - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE removeStatusListener( - /* [in] */ IDispatch __RPC_FAR *xControl, - /* [in] */ IDispatch __RPC_FAR *aURL); - - virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE getInterceptedURLs( - /* [retval][out] */ SAFEARRAY __RPC_FAR * __RPC_FAR *pVal); - - virtual /* [helpstring][id][propget] */ HRESULT STDMETHODCALLTYPE get_Bridge_implementedInterfaces( - /* [retval][out] */ SAFEARRAY __RPC_FAR * __RPC_FAR *pVal) - { - *pVal = SafeArrayCreateVector( VT_BSTR, 0, 4 ); - - if( !*pVal ) - return E_FAIL; - - long ix = 0; - CComBSTR aInterface( OLESTR( "com.sun.star.frame.XDispatchProviderInterceptor" ) ); - SafeArrayPutElement( *pVal, &ix, aInterface ); - - ix = 1; - aInterface = CComBSTR( OLESTR( "com.sun.star.frame.XDispatchProvider" ) ); - SafeArrayPutElement( *pVal, &ix, aInterface ); - - ix = 2; - aInterface = CComBSTR( OLESTR( "com.sun.star.frame.XDispatch" ) ); - SafeArrayPutElement( *pVal, &ix, aInterface ); - - ix = 3; - aInterface = CComBSTR( OLESTR( "com.sun.star.frame.XInterceptorInfo" ) ); - SafeArrayPutElement( *pVal, &ix, aInterface ); - - return S_OK; - } -}; - -#endif // __SODISPATCHINTERCEPTOR_H_ - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/SODispatchInterceptor.rgs b/extensions/source/activex/main/SODispatchInterceptor.rgs deleted file mode 100644 index 19fe0b5f0e4c..000000000000 --- a/extensions/source/activex/main/SODispatchInterceptor.rgs +++ /dev/null @@ -1,23 +0,0 @@ -HKCR -{ - so_activex.SODispatchInterceptor.1 = s 'SODispatchInterceptor Class' - { - CLSID = s '{C5D6D568-57DA-4D6C-819A-451CB565E682}' - } - so_activex.SODispatchInterceptor = s 'SODispatchInterceptor Class' - { - CLSID = s '{C5D6D568-57DA-4D6C-819A-451CB565E682}' - } - NoRemove CLSID - { - ForceRemove {C5D6D568-57DA-4D6C-819A-451CB565E682} = s 'SODispatchInterceptor Class' - { - ProgID = s 'so_activex.SODispatchInterceptor.1' - VersionIndependentProgID = s 'so_activex.SODispatchInterceptor' - InprocServer32 = s '%MODULE%' - { - val ThreadingModel = s 'both' - } - } - } -} diff --git a/extensions/source/activex/main/StdAfx2.cpp b/extensions/source/activex/main/StdAfx2.cpp deleted file mode 100644 index f1cf88d10d14..000000000000 --- a/extensions/source/activex/main/StdAfx2.cpp +++ /dev/null @@ -1,21 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// stdafx1.cpp : source file that includes just the standard includes -// stdafx1.pch will be the pre-compiled header -// stdafx1.obj will contain the pre-compiled type information - -#ifdef __MINGW32__ -#define _INIT_ATL_COMMON_VARS -#endif -#include "stdafx2.h" - -#ifdef _ATL_STATIC_REGISTRY -#include -#include -#endif - -#if defined(_MSC_VER) && (_MSC_VER >= 1300) -#undef _DEBUG -#endif -#include - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/StdAfx2.h b/extensions/source/activex/main/StdAfx2.h deleted file mode 100644 index 5c540b0ba329..000000000000 --- a/extensions/source/activex/main/StdAfx2.h +++ /dev/null @@ -1,45 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// stdafx1.h : include file for standard system include files, -// or project specific include files that are used frequently, -// but are changed infrequently - -#if !defined(AFX_STDAFX_H__C1799EA0_62CC_44DE_A2DD_C9F0410FF7F1__INCLUDED_) -#define AFX_STDAFX_H__C1799EA0_62CC_44DE_A2DD_C9F0410FF7F1__INCLUDED_ - -#if _MSC_VER > 1000 -#pragma once -#endif // _MSC_VER > 1000 - -#define STRICT -#ifndef _WIN32_WINNT -#define _WIN32_WINNT 0x0400 -#endif -#define _ATL_APARTMENT_THREADED -#define _ATL_STATIC_REGISTRY - -#pragma warning (disable:4505) - // globally disable "unreferenced local function has been removed" - -#pragma warning (push,1) -#pragma warning (disable:4548) - // expression before comma has no effect; expected expression with side-effect -#pragma warning (disable:4555) - // expression has no effect; expected expression with side-effect - -#define min(a, b) (((a) < (b)) ? (a) : (b)) -#include - -//You may derive a class from CComModule and use it if you want to override -//something, but do not change the name of _Module -extern CComModule _Module; -#include -#include - -#pragma warning (pop) - -//{{AFX_INSERT_LOCATION}} -// Microsoft Visual C++ will insert additional declarations immediately before the previous line. - -#endif // !defined(AFX_STDAFX_H__C1799EA0_62CC_44DE_A2DD_C9F0410FF7F1__INCLUDED) - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/com_uno_helper.h b/extensions/source/activex/main/com_uno_helper.h deleted file mode 100644 index 230fc63a6e77..000000000000 --- a/extensions/source/activex/main/com_uno_helper.h +++ /dev/null @@ -1,26 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -#include "stdafx2.h" - -HRESULT ExecuteFunc( IDispatch* idispUnoObject, - OLECHAR* sFuncName, - CComVariant* params, - unsigned int count, - CComVariant* pResult ); - -HRESULT GetIDispByFunc( IDispatch* idispUnoObject, - OLECHAR* sFuncName, - CComVariant* params, - unsigned int count, - CComPtr& pdispResult ); - -HRESULT PutPropertiesToIDisp( IDispatch* pdispObject, - OLECHAR** sMemberNames, - CComVariant* pVariant, - unsigned int count ); - -HRESULT GetPropertiesFromIDisp( IDispatch* pdispObject, - OLECHAR** sMemberNames, - CComVariant* pVariant, - unsigned int count ); - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/example.html b/extensions/source/activex/main/example.html deleted file mode 100644 index 3efee1f75a03..000000000000 --- a/extensions/source/activex/main/example.html +++ /dev/null @@ -1,26 +0,0 @@ - - -Document Title - - - -
-First you should edit the example.html file!!! -
-
- - - - - - - -
- - - diff --git a/extensions/source/activex/main/makefile.mk b/extensions/source/activex/main/makefile.mk deleted file mode 100644 index ea70b66d0f0f..000000000000 --- a/extensions/source/activex/main/makefile.mk +++ /dev/null @@ -1,157 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=..$/..$/.. -PRJNAME=extensions -TARGET=so_activex - -use_shl_versions= - -# --- Settings ---------------------------------- -.INCLUDE : settings.mk - -.IF "$(GUI)$(COM)" == "WNTMSC" && "$(DISABLE_ACTIVEX)"=="" - -VERSIONOBJ= -LIBTARGET=NO -USE_DEFFILE=YES -UWINAPILIB= - -.IF "$(BUILD_X64)"!="" -USE_DEFFILE_X64=TRUE -.ENDIF - -INCPRE+=$(foreach,i,$(ATL_INCLUDE) -I$(i)) \ - -I$(MISC) \ - -# --- Files ------------------------------------- - - -.IF "$(PRODUCT)"!="" -RC+=-DPRODUCT -.ENDIF - -RCFILES=\ - $(TARGET).rc -RCDEPN=$(MISC)$/envsettings.h - -SLOFILES=\ - $(SLO)$/so_activex.obj \ - $(SLO)$/SOActiveX.obj \ - $(SLO)$/SOComWindowPeer.obj \ - $(SLO)$/SODispatchInterceptor.obj \ - $(SLO)$/SOActionsApproval.obj \ - $(SLO)$/StdAfx2.obj - -SHL1TARGET=$(TARGET) -SHL1STDLIBS=\ - $(UUIDLIB) \ - $(ADVAPI32LIB) \ - $(OLE32LIB) \ - $(OLEAUT32LIB) \ - $(GDI32LIB) \ - $(URLMONLIB) \ - $(SHLWAPILIB) - -.IF "$(COM)" == "MSC" -.IF "$(USE_DEBUG_RUNTIME)" != "" - SHL1STDLIBS+= $(ATL_LIB)$/atlsd.lib -.ELSE - SHL1STDLIBS+= $(ATL_LIB)$/atls.lib -.ENDIF -.ENDIF - - -# $(KERNEL32LIB) \ -# rpcndr.lib \ -# rpcns4.lib \ -# rpcrt4.lib - -#$(KERNEL32LIB) rpcndr.lib rpcns4.lib rpcrt4.lib - -SHL1OBJS=$(SLOFILES) - -SHL1LIBS= -SHL1DEF=$(TARGET).def -SHL1RES=$(RES)$/$(TARGET).res - -.ENDIF - -.IF "$(BUILD_X64)"!="" -# -------------------- x64 ----------------------- - -CDEFS_X64+:=$(foreach,i,$(CDEFS) $(subst,-D_X86_=1, $i)) -LIBTARGET_X64=NO -USE_DEFFILE_X64=YES -UWINAPILIB_X64= - -SLOFILES_X64= \ - $(SLO_X64)$/so_activex.obj \ - $(SLO_X64)$/SOActiveX.obj \ - $(SLO_X64)$/SOComWindowPeer.obj \ - $(SLO_X64)$/SODispatchInterceptor.obj \ - $(SLO_X64)$/SOActionsApproval.obj \ - $(SLO_X64)$/StdAfx2.obj - -SHL1TARGET_X64=$(TARGET) - -SHL1STDLIBS_X64+=\ - $(UUIDLIB_X64) \ - $(ADVAPI32LIB_X64) \ - $(OLE32LIB_X64) \ - $(OLEAUT32LIB_X64) \ - $(GDI32LIB_X64) \ - $(URLMONLIB_X64) \ - $(SHLWAPILIB_X64) \ - $(KERNEL32LIB_X64) \ - $(USER32LIB_X64) \ - $(MSVCRT_X64) \ - $(MSVCPRT_X64) \ - $(OLDNAMESLIB_X64) - -SHL1OBJS_X64=$(SLOFILES_X64) -SHL1DEF_X64=$(TARGET).def - -.IF "$(USE_DEBUG_RUNTIME)" != "" -SHL1STDLIBS_X64+= $(ATL_LIB)$/amd64$/atlsd.lib -.ELSE -SHL1STDLIBS_X64+= $(ATL_LIB)$/amd64$/atls.lib -.ENDIF - -.ENDIF # "$(BUILD_X64)"!="" - -# --- Targets ---------------------------------- - -.INCLUDE : set_wntx64.mk -VERSIONOBJ_X64= -.INCLUDE : target.mk -.INCLUDE : tg_wntx64.mk - -$(MISC)$/envsettings.h : makefile.mk - -$(RM) $@ -# it looks wrong; but rc likes it that way... - echo "#define MISC .\..\$(INPATH)\misc" > $@ diff --git a/extensions/source/activex/main/resource.h b/extensions/source/activex/main/resource.h deleted file mode 100644 index fe74853c6d15..000000000000 --- a/extensions/source/activex/main/resource.h +++ /dev/null @@ -1,28 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -//{{NO_DEPENDENCIES}} -// Microsoft Developer Studio generated include file. -// Used by so_activex.rc -// -#define IDS_PROJNAME 100 -#define IDB_SOACTIVEX 101 -#define IDR_SOACTIVEX 102 -#define IDB_SOCOMWINDOWPEER 103 -#define IDR_SOCOMWINDOWPEER 104 -#define IDB_SODISPATCHINTERCEPTOR 105 -#define IDR_SODISPATCHINTERCEPTOR 106 -#define IDB_SODOCUMENTEVENTLISTENER 107 -#define IDR_SODOCUMENTEVENTLISTENER 108 - - -// Next default values for new objects -// -#ifdef APSTUDIO_INVOKED -#ifndef APSTUDIO_READONLY_SYMBOLS -#define _APS_NEXT_RESOURCE_VALUE 201 -#define _APS_NEXT_COMMAND_VALUE 32768 -#define _APS_NEXT_CONTROL_VALUE 201 -#define _APS_NEXT_SYMED_VALUE 107 -#endif -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/so_activex.cpp b/extensions/source/activex/main/so_activex.cpp deleted file mode 100644 index 94dd0ccdcf1c..000000000000 --- a/extensions/source/activex/main/so_activex.cpp +++ /dev/null @@ -1,685 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -// so_activex.cpp : Implementation of DLL Exports. - - -// Note: Proxy/Stub Information -// To build a separate proxy/stub DLL, -// run nmake -f so_activexps.mk in the project directory. - -#include "stdio.h" -#include "stdafx2.h" -#include "resource.h" -#include -#include "so_activex.h" - -#include "so_activex_i.c" -#include "SOActiveX.h" - -#include - -CComModule _Module; - -BEGIN_OBJECT_MAP(ObjectMap) -OBJECT_ENTRY(CLSID_SOActiveX, CSOActiveX) -END_OBJECT_MAP() - - -#define X64_LIB_NAME "so_activex_x64.dll" -#define X32_LIB_NAME "so_activex.dll" - -// to provide windows xp as build systems for mingw we need to define KEY_WOW64_64KEY -// in mingw 3.13 KEY_WOW64_64KEY isn't available < Win2003 systems. -// Also defined in setup_native\source\win32\customactions\reg64\reg64.cxx,source\win32\customactions\shellextensions\shellextensions.cxx and -// extensions\source\activex\main\so_activex.cpp -#ifndef KEY_WOW64_64KEY - #define KEY_WOW64_64KEY (0x0100) -#endif -#ifndef KEY_WOW64_32KEY - #define KEY_WOW64_32KEY (0x0200) -#endif - -const REGSAM n64KeyAccess = KEY_ALL_ACCESS | KEY_WOW64_64KEY; -const REGSAM n32KeyAccess = KEY_ALL_ACCESS; - -#ifdef _AMD64_ -const BOOL bX64 = TRUE; -#define REG_DELETE_KEY_A( key, aPath, nKeyAccess ) RegDeleteKeyExA( key, aPath, nKeyAccess, 0 ) -#else -const BOOL bX64 = FALSE; -#define REG_DELETE_KEY_A( key, aPath, nKeyAccess ) RegDeleteKeyA( key, aPath ) -#endif - -// MinGW doesn't know anything about RegDeleteKeyExA if WINVER < 0x0502. -extern "C" { -WINADVAPI LONG WINAPI RegDeleteKeyExA(HKEY,LPCSTR,REGSAM,DWORD); -} - -///////////////////////////////////////////////////////////////////////////// -// DLL Entry Point - -extern "C" -BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID /*lpReserved*/) -{ - if (dwReason == DLL_PROCESS_ATTACH) - { - _Module.Init(ObjectMap, hInstance, &LIBID_SO_ACTIVEXLib); - DisableThreadLibraryCalls(hInstance); - } - else if (dwReason == DLL_PROCESS_DETACH) - _Module.Term(); - return TRUE; // ok -} - -///////////////////////////////////////////////////////////////////////////// -// Used to determine whether the DLL can be unloaded by OLE - -STDAPI DllCanUnloadNow(void) -{ - return (_Module.GetLockCount()==0) ? S_OK : S_FALSE; -} - -///////////////////////////////////////////////////////////////////////////// -// Returns a class factory to create an object of the requested type - -STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv) -{ - return _Module.GetClassObject(rclsid, riid, ppv); -} - -///////////////////////////////////////////////////////////////////////////// -// DllRegisterServer - Adds entries to the system registry - -// for now database component and chart are always installed -#define SUPPORTED_EXT_NUM 30 -const char* aFileExt[] = { ".vor", - ".sds", ".sda", ".sdd", ".sdp", ".sdc", ".sdw", ".smf", - ".stw", ".stc", ".sti", ".std", - ".sxw", ".sxc", ".sxi", ".sxd", ".sxg", ".sxm", - ".ott", ".otg", ".otp", ".ots", ".otf", - ".odt", ".oth", ".odm", ".odg", ".odp", ".ods", ".odf"}; -const char* aMimeType[] = { - "application/vnd.stardivision.writer", - - "application/vnd.stardivision.chart", - "application/vnd.stardivision.draw", - "application/vnd.stardivision.impress", - "application/vnd.stardivision.impress-packed", - "application/vnd.stardivision.calc", - "application/vnd.stardivision.writer", - "application/vnd.stardivision.math", - - MIMETYPE_VND_SUN_XML_WRITER_TEMPLATE_ASCII, - MIMETYPE_VND_SUN_XML_CALC_TEMPLATE_ASCII, - MIMETYPE_VND_SUN_XML_IMPRESS_TEMPLATE_ASCII, - MIMETYPE_VND_SUN_XML_DRAW_TEMPLATE_ASCII, - - MIMETYPE_VND_SUN_XML_WRITER_ASCII, - MIMETYPE_VND_SUN_XML_CALC_ASCII, - MIMETYPE_VND_SUN_XML_IMPRESS_ASCII, - MIMETYPE_VND_SUN_XML_DRAW_ASCII, - MIMETYPE_VND_SUN_XML_WRITER_GLOBAL_ASCII, - MIMETYPE_VND_SUN_XML_MATH_ASCII, - - MIMETYPE_OASIS_OPENDOCUMENT_TEXT_TEMPLATE_ASCII, - MIMETYPE_OASIS_OPENDOCUMENT_DRAWING_TEMPLATE_ASCII, - MIMETYPE_OASIS_OPENDOCUMENT_PRESENTATION_TEMPLATE_ASCII, - MIMETYPE_OASIS_OPENDOCUMENT_SPREADSHEET_TEMPLATE_ASCII, - MIMETYPE_OASIS_OPENDOCUMENT_FORMULA_TEMPLATE_ASCII, - - MIMETYPE_OASIS_OPENDOCUMENT_TEXT_ASCII, - MIMETYPE_OASIS_OPENDOCUMENT_TEXT_WEB_ASCII, - MIMETYPE_OASIS_OPENDOCUMENT_TEXT_GLOBAL_ASCII, - MIMETYPE_OASIS_OPENDOCUMENT_DRAWING_ASCII, - MIMETYPE_OASIS_OPENDOCUMENT_PRESENTATION_ASCII, - MIMETYPE_OASIS_OPENDOCUMENT_SPREADSHEET_ASCII, - MIMETYPE_OASIS_OPENDOCUMENT_FORMULA_ASCII }; - -const int nForModes[] = { 16, - 1, 2, 4, 4, 8, 16, 32, - 16, 8, 4, 2, - 16, 8, 4, 2, 16, 32, - 16, 2, 4, 8, 32, - 16, 16, 16, 2, 4, 8, 32 }; - -const char* aClassID = "{67F2A879-82D5-4A6D-8CC5-FFB3C114B69D}"; -const char* aTypeLib = "{61FA3F13-8061-4796-B055-3697ED28CB38}"; - -// ISOComWindowPeer interface information -const char* aInterIDWinPeer = "{BF5D10F3-8A10-4A0B-B150-2B6AA2D7E118}"; -const char* aProxyStubWinPeer = "{00020424-0000-0000-C000-000000000046}"; - -// ISODispatchInterceptor interface information -const char* aInterIDDispInt = "{9337694C-B27D-4384-95A4-9D8E0EABC9E5}"; -const char* aProxyStubDispInt = "{00020424-0000-0000-C000-000000000046}"; - -// ISOActionsApproval interface information -const char* aInterIDActApprove = "{029E9F1E-2B3F-4297-9160-8197DE7ED54F}"; -const char* aProxyStubActApprove = "{00020424-0000-0000-C000-000000000046}"; - -// The following prefix is required for HKEY_LOCAL_MACHINE and HKEY_CURRENT_USER ( not for HKEY_CLASSES_ROOT ) -const char* aLocalPrefix = "Software\\Classes\\"; - -BOOL createKey( HKEY hkey, - const char* aKeyToCreate, - REGSAM nKeyAccess, - const char* aValue = NULL, - const char* aChildName = NULL, - const char* aChildValue = NULL ) -{ - HKEY hkey1; - - return ( ERROR_SUCCESS == RegCreateKeyExA( hkey, aKeyToCreate, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) - && ( !aValue || ERROR_SUCCESS == RegSetValueExA( hkey1, - "", - 0, - REG_SZ, - (const BYTE*)aValue, - strlen( aValue ) ) ) - && ( !aChildName || ERROR_SUCCESS == RegSetValueExA( hkey1, - aChildName, - 0, - REG_SZ, - (const BYTE*)aChildValue, - strlen( aChildValue ) ) ) - && ERROR_SUCCESS == RegCloseKey( hkey1 ) ); - -} - -STDAPI DllUnregisterServerNative( int nMode, BOOL bForAllUsers, BOOL bFor64Bit ); -STDAPI DllRegisterServerNative_Impl( int nMode, BOOL bForAllUsers, REGSAM nKeyAccess, const char* pProgramPath, const char* pLibName ) -{ - BOOL aResult = FALSE; - - HKEY hkey = NULL; - HKEY hkey1 = NULL; - HKEY hkey2 = NULL; - HKEY hkey3 = NULL; - HKEY hkey4 = NULL; - char aSubKey[513]; - int ind; - const char* aPrefix = aLocalPrefix; // bForAllUsers ? "" : aLocalPrefix; - - char pActiveXPath[1124]; - char pActiveXPath101[1124]; - - - // In case SO7 is installed for this user he can have local registry entries that will prevent him from - // using SO8 ActiveX control. The fix is just to clean up the local entries related to ActiveX control. - // Unfortunately it can be done only for the user who installs the office. - if ( bForAllUsers ) - DllUnregisterServerNative( nMode, sal_False, sal_False ); - - if ( pProgramPath && strlen( pProgramPath ) < 1024 ) - { - sprintf( pActiveXPath, "%s\\%s", pProgramPath, pLibName ); - sprintf( pActiveXPath101, "%s\\%s, 101", pProgramPath, pLibName ); - - { - wsprintfA( aSubKey, "%sCLSID\\%s", aPrefix, aClassID ); - aResult = - ( ERROR_SUCCESS == RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey , NULL ) - && ERROR_SUCCESS == RegSetValueExA( hkey, "", 0, REG_SZ, (const BYTE*)"SOActiveX Class", 17 ) - && createKey( hkey, "Control", nKeyAccess ) - && createKey( hkey, "EnableFullPage", nKeyAccess ) - && createKey( hkey, "InprocServer32", nKeyAccess, pActiveXPath, "ThreadingModel", "Apartment" ) - && createKey( hkey, "MiscStatus", nKeyAccess, "0" ) - && createKey( hkey, "MiscStatus\\1", nKeyAccess, "131473" ) - && createKey( hkey, "ProgID", nKeyAccess, "so_activex.SOActiveX.1" ) - && createKey( hkey, "Programmable", nKeyAccess ) - && createKey( hkey, "ToolboxBitmap32", nKeyAccess, pActiveXPath101 ) - && createKey( hkey, "TypeLib", nKeyAccess, aTypeLib ) - && createKey( hkey, "Version", nKeyAccess, "1.0" ) - && createKey( hkey, "VersionIndependentProgID", nKeyAccess, "so_activex.SOActiveX" ) - && ERROR_SUCCESS == RegCloseKey( hkey ) - && ERROR_SUCCESS == RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aPrefix, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey , NULL ) - && createKey( hkey, "so_activex.SOActiveX", nKeyAccess, "SOActiveX Class" ) - && ERROR_SUCCESS == RegCreateKeyExA( hkey, "so_activex.SOActiveX", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) - && createKey( hkey1, "CLSID", nKeyAccess, aClassID ) - && createKey( hkey1, "CurVer", nKeyAccess, "so_activex.SOActiveX.1" ) - && ERROR_SUCCESS == RegCloseKey( hkey1 ) - && createKey( hkey, "so_activex.SOActiveX.1", nKeyAccess, "SOActiveX Class" ) - && ERROR_SUCCESS == RegCreateKeyExA( hkey, "so_activex.SOActiveX.1", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) - && createKey( hkey1, "CLSID", nKeyAccess, aClassID ) - && ERROR_SUCCESS == RegCloseKey( hkey1 ) - && ERROR_SUCCESS == RegCreateKeyExA( hkey, "TypeLib", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) - && ERROR_SUCCESS == RegCreateKeyExA( hkey1, aTypeLib, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey2 , NULL ) - && createKey( hkey2, "1.0", nKeyAccess, "wrap_activex 1.0 Type Library" ) - && ERROR_SUCCESS == RegCreateKeyExA( hkey2, "1.0", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey3 , NULL ) - && ERROR_SUCCESS == RegCreateKeyExA( hkey3, "0", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey4 , NULL ) - && createKey( hkey4, "win32", nKeyAccess, pActiveXPath ) - && ERROR_SUCCESS == RegCloseKey( hkey4 ) - && createKey( hkey3, "FLAGS", nKeyAccess, "0" ) - && createKey( hkey3, "HELPDIR", nKeyAccess, pProgramPath ) - && ERROR_SUCCESS == RegCloseKey( hkey3 ) - && ERROR_SUCCESS == RegCloseKey( hkey2 ) - && ERROR_SUCCESS == RegCloseKey( hkey1 ) - && ERROR_SUCCESS == RegCreateKeyExA( hkey, "Interface", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) - && createKey( hkey1, aInterIDWinPeer, nKeyAccess, "ISOComWindowPeer" ) - && ERROR_SUCCESS == RegCreateKeyExA( hkey1, aInterIDWinPeer, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey2 , NULL ) - && createKey( hkey2, "ProxyStubClsid", nKeyAccess, aProxyStubWinPeer ) - && createKey( hkey2, "ProxyStubClsid32", nKeyAccess, aProxyStubWinPeer ) - && createKey( hkey2, "TypeLib", nKeyAccess, aTypeLib, "Version", "1.0" ) - && ERROR_SUCCESS == RegCloseKey( hkey2 ) - && createKey( hkey1, aInterIDActApprove, nKeyAccess, "ISOActionsApproval" ) - && ERROR_SUCCESS == RegCreateKeyExA( hkey1, aInterIDActApprove, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey2 , NULL ) - && createKey( hkey2, "ProxyStubClsid", nKeyAccess, aProxyStubActApprove ) - && createKey( hkey2, "ProxyStubClsid32", nKeyAccess, aProxyStubActApprove ) - && createKey( hkey2, "TypeLib", nKeyAccess, aTypeLib, "Version", "1.0" ) - && ERROR_SUCCESS == RegCloseKey( hkey2 ) - && createKey( hkey1, aInterIDDispInt, nKeyAccess, "ISODispatchInterceptor" ) - && ERROR_SUCCESS == RegCreateKeyExA( hkey1, aInterIDDispInt, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey2 , NULL ) - && createKey( hkey2, "ProxyStubClsid", nKeyAccess, aProxyStubDispInt ) - && createKey( hkey2, "ProxyStubClsid32", nKeyAccess, aProxyStubDispInt ) - && createKey( hkey2, "TypeLib", nKeyAccess, aTypeLib, "Version", "1.0" ) - && ERROR_SUCCESS == RegCloseKey( hkey2 ) - && ERROR_SUCCESS == RegCloseKey( hkey1 ) - && ERROR_SUCCESS == RegCloseKey( hkey ) ); - - hkey = hkey1 = hkey2 = hkey3 = hkey4 = NULL; - } - } - - for( ind = 0; ind < SUPPORTED_EXT_NUM && aResult; ind++ ) - { - if( nForModes[ind] & nMode ) - { - wsprintfA( aSubKey, "%sMIME\\DataBase\\Content Type\\%s", aPrefix, aMimeType[ind] ); - if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) -// || ERROR_SUCCESS != RegSetValueExA(hkey, "Extension", 0, REG_SZ, -// (const BYTE *)aFileExt[ind], strlen( aFileExt[ind] ) ) - || ERROR_SUCCESS != RegSetValueExA(hkey, "CLSID", 0, REG_SZ, - (const BYTE *)aClassID, strlen(aClassID)) ) - aResult = FALSE; - - if( hkey ) - RegCloseKey(hkey),hkey= NULL; - -/* - wsprintfA( aSubKey, "%s%s", aPrefix, aFileExt[ind] ); - if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) - || ERROR_SUCCESS != RegSetValueExA(hkey, "Content Type", 0, REG_SZ, - (const BYTE *)aMimeType[ind], strlen( aMimeType[ind] ) ) ) - aResult = FALSE; - if( hkey ) - RegCloseKey(hkey),hkey= NULL; -*/ - } - } - - wsprintfA( aSubKey, "%sCLSID\\%s", aPrefix, aClassID ); - if ( aResult && ERROR_SUCCESS == RegOpenKeyExA(bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, nKeyAccess, &hkey) ) - { - for( ind = 0; ind < SUPPORTED_EXT_NUM; ind++ ) - { - wsprintfA( aSubKey, "EnableFullPage\\%s", aFileExt[ind] ); - if ( ERROR_SUCCESS != RegCreateKeyExA( hkey, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) ) - aResult = FALSE; - - if ( hkey1 ) - RegCloseKey(hkey1),hkey1= NULL; - } - } - else - aResult = FALSE; - - if ( hkey ) - RegCloseKey(hkey),hkey= NULL; - - return aResult; -} - -STDAPI DllRegisterServerNative( int nMode, BOOL bForAllUsers, BOOL bFor64Bit, const char* pProgramPath ) -{ - HRESULT hr = S_OK; - if ( bFor64Bit ) - hr = DllRegisterServerNative_Impl( nMode, bForAllUsers, n64KeyAccess, pProgramPath, X64_LIB_NAME ); - - if ( SUCCEEDED( hr ) ) - hr = DllRegisterServerNative_Impl( nMode, bForAllUsers, n32KeyAccess, pProgramPath, X32_LIB_NAME ); - - return hr; -} - - -///////////////////////////////////////////////////////////////////////////// -// DllUnregisterServer - Removes entries from the system registry -HRESULT DeleteKeyTree( HKEY hkey, const char* pPath, REGSAM nKeyAccess ) -{ - HKEY hkey1 = NULL; - - char pSubKeyName[256]; - // first delete the subkeys - while( ERROR_SUCCESS == RegOpenKeyExA( hkey, pPath, 0, nKeyAccess, &hkey1) - && ERROR_SUCCESS == RegEnumKeyA( hkey1, 0, pSubKeyName, 256 ) - && ERROR_SUCCESS == DeleteKeyTree( hkey1, pSubKeyName, nKeyAccess ) ) - { - RegCloseKey( hkey1 ),hkey1= NULL; - } - - if ( hkey1 ) - RegCloseKey( hkey1 ),hkey1= NULL; - - // delete the key itself - return REG_DELETE_KEY_A( hkey, pPath, nKeyAccess & ( KEY_WOW64_64KEY | KEY_WOW64_32KEY ) ); -} - -STDAPI DllUnregisterServerNative_Impl( int nMode, BOOL bForAllUsers, REGSAM nKeyAccess ) -{ - HKEY hkey = NULL; - BOOL fErr = FALSE; - char aSubKey[513]; - const char* aPrefix = aLocalPrefix; // bForAllUsers ? "" : aLocalPrefix; - - for( int ind = 0; ind < SUPPORTED_EXT_NUM; ind++ ) - { - if( nForModes[ind] & nMode ) - { - DWORD nSubKeys = 0, nValues = 0; - wsprintfA( aSubKey, "%sMIME\\DataBase\\Content Type\\%s", aPrefix, aMimeType[ind] ); - if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) ) - fErr = TRUE; - else - { - if ( ERROR_SUCCESS != RegDeleteValue( hkey, "CLSID" ) ) - fErr = TRUE; - - if ( ERROR_SUCCESS != RegQueryInfoKey( hkey, NULL, NULL, NULL, - &nSubKeys, NULL, NULL, - &nValues, NULL, NULL, NULL, NULL ) ) - { - RegCloseKey( hkey ), hkey = NULL; - fErr = TRUE; - } - else - { - RegCloseKey( hkey ), hkey = NULL; - if ( !nSubKeys && !nValues ) - DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ); - } - } - - wsprintfA( aSubKey, "%s%s", aPrefix, aFileExt[ind] ); - if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) ) - fErr = TRUE; - else - { - if ( ERROR_SUCCESS != RegQueryInfoKey( hkey, NULL, NULL, NULL, - &nSubKeys, NULL, NULL, - &nValues, NULL, NULL, NULL, NULL ) ) - { - RegCloseKey( hkey ), hkey = NULL; - fErr = TRUE; - } - else - { - RegCloseKey( hkey ), hkey = NULL; - if ( !nSubKeys && !nValues ) - DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ); - } - } - } - } - - wsprintfA( aSubKey, "%sCLSID\\%s", aPrefix, aClassID ); - if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) - fErr = TRUE; - - wsprintfA( aSubKey, "%sso_activex.SOActiveX", aPrefix ); - if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) - fErr = TRUE; - - wsprintfA( aSubKey, "%sso_activex.SOActiveX.1", aPrefix ); - if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) - fErr = TRUE; - - wsprintfA( aSubKey, "%s\\TypeLib\\%s", aPrefix, aTypeLib ); - if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) - fErr = TRUE; - - wsprintfA( aSubKey, "%s\\Interface\\%s", aPrefix, aInterIDWinPeer ); - if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) - fErr = TRUE; - - wsprintfA( aSubKey, "%s\\Interface\\%s", aPrefix, aInterIDDispInt ); - if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) - fErr = TRUE; - - wsprintfA( aSubKey, "%s\\Interface\\%s", aPrefix, aInterIDActApprove ); - if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) - fErr = TRUE; - - return !fErr; -} - -STDAPI DllUnregisterServerNative( int nMode, BOOL bForAllUsers, BOOL bFor64Bit ) -{ - HRESULT hr = DllUnregisterServerNative_Impl( nMode, bForAllUsers, n32KeyAccess ); - if ( SUCCEEDED( hr ) && bFor64Bit ) - hr = DllUnregisterServerNative_Impl( nMode, bForAllUsers, n64KeyAccess ); - - return hr; -} - - -///////////////////////////////////////////////////////////////////////////// -// DllRegisterServerDoc - Adds entries to the system registry - -#define SUPPORTED_MSEXT_NUM 7 -const char* aMSFileExt[] = { ".dot", ".doc", ".xlt", ".xls", ".pot", ".ppt", ".pps" }; -const char* aMSMimeType[] = { "application/msword", - "application/msword", - "application/msexcell", - "application/msexcell", - "application/mspowerpoint", - "application/mspowerpoint", - "application/mspowerpoint" }; -const int nForMSModes[] = { 1, 1, 2, 2, 4, 4, 4 }; - -STDAPI DllUnregisterServerDoc( int nMode, BOOL bForAllUsers, BOOL bFor64Bit ); -STDAPI DllRegisterServerDoc_Impl( int nMode, BOOL bForAllUsers, REGSAM nKeyAccess ) -{ - BOOL aResult = TRUE; - - HKEY hkey = NULL; - HKEY hkey1 = NULL; - char aSubKey[513]; - int ind; - const char* aPrefix = aLocalPrefix; // bForAllUsers ? "" : aLocalPrefix; - - // In case SO7 is installed for this user he can have local registry entries that will prevent him from - // using SO8 ActiveX control. The fix is just to clean up the local entries related to ActiveX control. - // Unfortunately it can be done only for the user who installs the office. - if ( bForAllUsers ) - DllUnregisterServerDoc( nMode, sal_False, sal_False ); - - for( ind = 0; ind < SUPPORTED_MSEXT_NUM && aResult; ind++ ) - { - if( nForMSModes[ind] & nMode ) - { - wsprintfA( aSubKey, "%sMIME\\DataBase\\Content Type\\%s", aPrefix, aMSMimeType[ind] ); - if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) - || ERROR_SUCCESS != RegSetValueExA(hkey, "Extension", 0, REG_SZ, - (const BYTE *)aMSFileExt[ind], strlen( aMSFileExt[ind] ) ) - || ERROR_SUCCESS != RegSetValueExA(hkey, "CLSID", 0, REG_SZ, - (const BYTE *)aClassID, strlen(aClassID)) ) - aResult = FALSE; - - if( hkey ) - RegCloseKey(hkey),hkey= NULL; - - wsprintfA( aSubKey, "%s%s", aPrefix, aMSFileExt[ind] ); - if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) - || ERROR_SUCCESS != RegSetValueExA(hkey, "Content Type", 0, REG_SZ, - (const BYTE *)aMSMimeType[ind], strlen( aMSMimeType[ind] ) ) ) - aResult = FALSE; - - if( hkey ) - RegCloseKey(hkey),hkey= NULL; - } - } - - wsprintfA( aSubKey, "%sCLSID\\%s", aPrefix, aClassID ); - if ( aResult && ERROR_SUCCESS == RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey , NULL ) - && createKey( hkey, "EnableFullPage", nKeyAccess ) ) - { - for( ind = 0; ind < SUPPORTED_MSEXT_NUM; ind++ ) - { - if( nForMSModes[ind] & nMode ) - { - wsprintfA( aSubKey, "EnableFullPage\\%s", aMSFileExt[ind] ); - if ( ERROR_SUCCESS != RegCreateKeyExA( hkey, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) ) - aResult = FALSE; - - if ( hkey1 ) - RegCloseKey(hkey1),hkey1= NULL; - } - } - } - else - aResult = FALSE; - - if ( hkey ) - RegCloseKey(hkey),hkey= NULL; - - return aResult; -} - -STDAPI DllRegisterServerDoc( int nMode, BOOL bForAllUsers, BOOL bFor64Bit ) -{ - HRESULT hr = S_OK; - if ( bFor64Bit ) - hr = DllRegisterServerDoc_Impl( nMode, bForAllUsers, n64KeyAccess ); - - if ( SUCCEEDED( hr ) ) - hr = DllRegisterServerDoc_Impl( nMode, bForAllUsers, n32KeyAccess ); - - return hr; -} - - -///////////////////////////////////////////////////////////////////////////// -// DllUnregisterServerDoc - Removes entries from the system registry - -STDAPI DllUnregisterServerDoc_Impl( int nMode, BOOL bForAllUsers, REGSAM nKeyAccess ) -{ - HKEY hkey = NULL; - BOOL fErr = FALSE; - char aSubKey[513]; - const char* aPrefix = aLocalPrefix; // bForAllUsers ? "" : aLocalPrefix; - - for( int ind = 0; ind < SUPPORTED_MSEXT_NUM; ind++ ) - { - if( nForMSModes[ind] & nMode ) - { - DWORD nSubKeys = 0, nValues = 0; - - wsprintfA( aSubKey, "%sMIME\\DataBase\\Content Type\\%s", aPrefix, aMSMimeType[ind] ); - if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) ) - fErr = TRUE; - else - { - if ( ERROR_SUCCESS != RegDeleteValue( hkey, "Extension" ) ) - fErr = TRUE; - - if ( ERROR_SUCCESS != RegDeleteValue( hkey, "CLSID" ) ) - fErr = TRUE; - - if ( ERROR_SUCCESS != RegQueryInfoKey( hkey, NULL, NULL, NULL, - &nSubKeys, NULL, NULL, - &nValues, NULL, NULL, NULL, NULL ) ) - { - RegCloseKey( hkey ), hkey = NULL; - fErr = TRUE; - } - else - { - RegCloseKey( hkey ), hkey = NULL; - if ( !nSubKeys && !nValues ) - DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ); - } - } - - wsprintfA( aSubKey, "%s%s", aPrefix, aMSFileExt[ind] ); - if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) ) - fErr = TRUE; - else - { - if ( ERROR_SUCCESS != RegDeleteValue( hkey, "Content Type" ) ) - fErr = TRUE; - - if ( ERROR_SUCCESS != RegQueryInfoKey( hkey, NULL, NULL, NULL, - &nSubKeys, NULL, NULL, - &nValues, NULL, NULL, NULL, NULL ) ) - { - RegCloseKey( hkey ), hkey = NULL; - fErr = TRUE; - } - else - { - RegCloseKey( hkey ), hkey = NULL; - if ( !nSubKeys && !nValues ) - DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ); - } - } - } - } - - return !fErr; -} - -STDAPI DllUnregisterServerDoc( int nMode, BOOL bForAllUsers, BOOL bFor64Bit ) -{ - HRESULT hr = S_OK; - if ( bFor64Bit ) - hr = DllUnregisterServerDoc_Impl( nMode, bForAllUsers, n64KeyAccess ); - - if ( SUCCEEDED( hr ) ) - hr = DllUnregisterServerDoc_Impl( nMode, bForAllUsers, n32KeyAccess ); - - return hr; -} - -///////////////////////////////////////////////////////////////////////////// -// DllRegisterServer - regsvr32 entry point - -STDAPI DllRegisterServer( void ) -{ - char pProgramPath[1024]; - HRESULT aResult = E_FAIL; - - HMODULE aCurModule = GetModuleHandleA( bX64 ? X64_LIB_NAME : X32_LIB_NAME ); - DWORD nLibNameLen = strlen( bX64 ? X64_LIB_NAME : X32_LIB_NAME ); - - if( aCurModule ) - { - DWORD nLen = GetModuleFileNameA( aCurModule, pProgramPath, 1024 ); - if ( nLen && nLen > nLibNameLen + 1 ) - { - pProgramPath[ nLen - nLibNameLen - 1 ] = 0; - aResult = DllRegisterServerNative( 31, TRUE, bX64, pProgramPath ); - if( SUCCEEDED( aResult ) ) - aResult = DllRegisterServerDoc( 31, TRUE, bX64 ); - else - { - aResult = DllRegisterServerNative( 31, FALSE, bX64, pProgramPath ); - if( SUCCEEDED( aResult ) ) - aResult = DllRegisterServerDoc( 31, FALSE, bX64 ); - } - } - } - - return aResult; -} - -///////////////////////////////////////////////////////////////////////////// -// DllUnregisterServer - regsvr32 entry point - -STDAPI DllUnregisterServer( void ) -{ - DllUnregisterServerDoc( 63, FALSE, bX64 ); - DllUnregisterServerNative( 63, FALSE, bX64 ); - DllUnregisterServerDoc( 63, TRUE, bX64 ); - return DllUnregisterServerNative( 63, TRUE, bX64 ); -} - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/main/so_activex.def b/extensions/source/activex/main/so_activex.def deleted file mode 100644 index e3d56b070dad..000000000000 --- a/extensions/source/activex/main/so_activex.def +++ /dev/null @@ -1,13 +0,0 @@ -; iervp.def : Declares the module parameters. - -LIBRARY "so_activex.dll" - -EXPORTS - DllCanUnloadNow @1 PRIVATE - DllGetClassObject @2 PRIVATE - DllRegisterServer @3 PRIVATE - DllUnregisterServer @4 PRIVATE - DllRegisterServerNative @5 PRIVATE - DllRegisterServerDoc @6 PRIVATE - DllUnregisterServerNative @7 PRIVATE - DllUnregisterServerDoc @8 PRIVATE diff --git a/extensions/source/activex/main/so_activex.rc b/extensions/source/activex/main/so_activex.rc deleted file mode 100644 index 2370a5162187..000000000000 --- a/extensions/source/activex/main/so_activex.rc +++ /dev/null @@ -1,113 +0,0 @@ -//Microsoft Developer Studio generated resource script. -// -#include "resource.h" - -#define APSTUDIO_READONLY_SYMBOLS -///////////////////////////////////////////////////////////////////////////// -// -// Generated from the TEXTINCLUDE 2 resource. -// -#if defined(_MSC_VER) && (_MSC_VER < 1500) -#include "winres.h" -#else -#define WINVER 0x0500 -#include -#define LB_ADDSTRING (WM_USER+1) -#define CB_ADDSTRING (WM_USER+3) -#define IDC_STATIC (-1) -#endif - -///////////////////////////////////////////////////////////////////////////// -#undef APSTUDIO_READONLY_SYMBOLS - -///////////////////////////////////////////////////////////////////////////// -// Russian resources - -//#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_RUS) -//#ifdef _WIN32 -//LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT -//#pragma code_page(1251) -//#endif //_WIN32 - -///////////////////////////////////////////////////////////////////////////// -// -// Bitmap -// - -//IDB_SOACTIVEX BITMAP DISCARDABLE "soacti.bmp" - - -///////////////////////////////////////////////////////////////////////////// -// -// REGISTRY -// - -IDR_SOACTIVEX REGISTRY DISCARDABLE "SOActiveX.rgs" -IDR_SOCOMWINDOWPEER REGISTRY DISCARDABLE "SOComWindowPeer.rgs" -IDR_SODISPATCHINTERCEPTOR REGISTRY DISCARDABLE "SODispatchInterceptor.rgs" -//#endif // Russian resources -///////////////////////////////////////////////////////////////////////////// - - -///////////////////////////////////////////////////////////////////////////// -// English (U.S.) resources - -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) -#ifdef _WIN32 -LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US -#pragma code_page(1252) -#endif //_WIN32 - -#ifdef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// TEXTINCLUDE -// - -1 TEXTINCLUDE DISCARDABLE -BEGIN - "resource.h\0" -END - -2 TEXTINCLUDE DISCARDABLE -BEGIN - "#include ""winres.h""\r\n" - "\0" -END - -3 TEXTINCLUDE DISCARDABLE -BEGIN - "1 TYPELIB ""so_activex.tlb""\r\n" - "\0" -END - -#endif // APSTUDIO_INVOKED - -///////////////////////////////////////////////////////////////////////////// -// -// String Table -// - -STRINGTABLE DISCARDABLE -BEGIN - IDS_PROJNAME "so_activex" -END - -#endif // English (U.S.) resources -///////////////////////////////////////////////////////////////////////////// - - - -#ifndef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// Generated from the TEXTINCLUDE 3 resource. -// - -#include "envsettings.h" - -1 TYPELIB MISC\so_activex.tlb - -///////////////////////////////////////////////////////////////////////////// -#endif // not APSTUDIO_INVOKED - diff --git a/extensions/source/activex/msidl/makefile.mk b/extensions/source/activex/msidl/makefile.mk deleted file mode 100644 index be9103ead216..000000000000 --- a/extensions/source/activex/msidl/makefile.mk +++ /dev/null @@ -1,62 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=..$/..$/.. -PRJNAME=extensions -TARGET=msidl - -# --- Settings ---------------------------------- - -.INCLUDE : settings.mk - -.IF "$(GUI)$(COM)" == "WNTMSC" && "$(DISABLE_ACTIVEX)"=="" - -# --- Targets ---------------------------------- - -ALL : $(MISC)$/activex_component - -MTL=midl.exe -MTL_PROJ= - -SOURCE=so_activex.idl - -MTL_SWITCHES=-tlb $(MISC)$/so_activex.tlb -h $(MISC)$/so_activex.h -iid $(MISC)$/so_activex_i.c -dlldata $(MISC)$/so_activex_dll.c -proxy $(MISC)$/so_activex_p.c -Oicf - -.IF "$(COM)"=="GCC" -MTL_SWITCHES+=-cpp_cmd gcc -cpp_opt "-x c -E -D__stdcall= -D_stdcall= -nostdinc -I $(shell @cygpath -w $(PSDK_HOME)/include)" - -$(MISC)$/activex_component : $(SOURCE) - $(MTL) $(MTL_SWITCHES) -I $(shell @cygpath -w $(PSDK_HOME)/include|sed 's#\\#\\\\#g') $(SOURCE) -.ELSE -$(MISC)$/activex_component : $(SOURCE) - $(WRAPCMD) $(MTL) $(MTL_SWITCHES) $(INCLUDE) $(SOURCE) && $(TOUCH) $@ -.ENDIF - -.ENDIF - -.INCLUDE : target.mk - diff --git a/extensions/source/activex/msidl/so_activex.idl b/extensions/source/activex/msidl/so_activex.idl deleted file mode 100644 index d1a7d9936eed..000000000000 --- a/extensions/source/activex/msidl/so_activex.idl +++ /dev/null @@ -1,210 +0,0 @@ -// so_activex.idl : IDL source for so_activex.dll -// - -// This file will be processed by the MIDL tool to -// produce the type library (so_activex.tlb) and marshalling code. - -import "oaidl.idl"; -import "ocidl.idl"; -#include "olectl.h" - - - [ - object, - uuid(DACF7E3F-626B-4BF9-964B-F4910C843711), - dual, - helpstring("ISOActiveX Interface"), - pointer_default(unique) - ] - interface ISOActiveX : IDispatch - { - }; - -[ - object, - uuid(BF5D10F3-8A10-4A0B-B150-2B6AA2D7E118), - dual, - helpstring("ISOComWindowPeer Interface"), - pointer_default(unique) -] -interface ISOComWindowPeer : IDispatch -{ - [id(1), helpstring("method getWindowHandle")] - HRESULT getWindowHandle( [in] SAFEARRAY(VARIANT) procId, - [in] short s, - [out,retval] long* ret); - - [id(2), helpstring("method getToolkit")] - HRESULT getToolkit( [out,retval] IDispatch** retVal ); - - [id(3), helpstring("method setPointer")] - HRESULT setPointer( [in] IDispatch* xPointer ); - - [id(4), helpstring("method setBackground")] - HRESULT setBackground( [in] int nColor ); - - [id(5), helpstring("method invalidate")] - HRESULT invalidate( [in] short ); - - [id(6), helpstring("method invalidateRect")] - HRESULT invalidateRect( [in] IDispatch* aRect, [in] short nFlags ); - - [id(7), helpstring("method dispose")] - HRESULT dispose(); - - [id(8), helpstring("method addEventListener")] - HRESULT addEventListener( [in] IDispatch* xListener ); - - [id(9), helpstring("method removeEventListener")] - HRESULT removeEventListener( [in] IDispatch* xListener ); - - [propget, id(10), helpstring("property_implementedInterfaces")] - HRESULT Bridge_implementedInterfaces([out, retval] SAFEARRAY(BSTR) *pVal); -}; - -[ - object, - uuid(9337694C-B27D-4384-95A4-9D8E0EABC9E5), - dual, - helpstring("ISODispatchInterceptor Interface"), - pointer_default(unique) -] -interface ISODispatchInterceptor : IDispatch -{ -//com.sun.star.frame.XDispatchProviderInterceptor - - [id(1), helpstring("method getSlaveDispatchProvider")] - HRESULT getSlaveDispatchProvider( [out,retval] IDispatch** retVal ); - - [id(2), helpstring("method setSlaveDispatchProvider")] - HRESULT setSlaveDispatchProvider( [in] IDispatch* xNewDispatchProvider ); - - [id(3), helpstring("method getMasterDispatchProvider")] - HRESULT getMasterDispatchProvider( [out,retval] IDispatch** retVal ); - - [id(4), helpstring("method setMasterDispatchProvider")] - HRESULT setMasterDispatchProvider( [in] IDispatch* xNewSupplier ); - -// com.sun.star.frame.XDispatchProvider - - [id(5), helpstring("method queryDispatch")] - HRESULT queryDispatch( [in] IDispatch* aURL, - [in] BSTR aTargetFrameName, - [in] long nSearchFlags, - [out,retval] IDispatch** retVal ); - - [id(6), helpstring("method queryDispatches")] - HRESULT queryDispatches( [in] SAFEARRAY(IDispatch*) aDescripts, - [out,retval] SAFEARRAY(VARIANT)* retVal ); - - -// com.sun.star.frame.XDispatch - - [id(7), helpstring("method dispatch")] - HRESULT dispatch( [in] IDispatch* aURL, - [in] SAFEARRAY(VARIANT) aArgs ); - - [id(8), helpstring("method addStatusListener")] - HRESULT addStatusListener( [in] IDispatch* xControl, - [in] IDispatch* aURL ); - - [id(9), helpstring("method removeStatusListener")] - HRESULT removeStatusListener( [in] IDispatch* xControl, - [in] IDispatch* aURL ); - -// com.sun.star.frame.XInterceptorInfo - - - [id(10), helpstring("method getInterceptedURLs")] - HRESULT getInterceptedURLs( [out,retval] SAFEARRAY(BSTR)* pVal ); - -// the common UNO-COM staff - [propget, id(11), helpstring("property_implementedInterfaces")] - HRESULT Bridge_implementedInterfaces([out, retval] SAFEARRAY(BSTR) *pVal); - -}; - - - - -[ - object, - uuid(029E9F1E-2B3F-4297-9160-8197DE7ED54F), - dual, - helpstring("ISOActionsApproval Interface"), - pointer_default(unique) -] -interface ISOActionsApproval : IDispatch -{ -//com.sun.star.embed.XActionsApproval - - [id(1), helpstring("method approveAction")] - HRESULT approveAction( [in] long aActionID, - [out,retval] boolean* pbApproval ); - -// the common UNO-COM staff - [propget, id(2), helpstring("property_implementedInterfaces")] - HRESULT Bridge_implementedInterfaces([out, retval] SAFEARRAY(BSTR) *pVal); -}; - - - -[ - uuid(61FA3F13-8061-4796-B055-3697ED28CB38), - version(1.0), - helpstring("so_activex 1.0 Type Library") -] -library SO_ACTIVEXLib -{ - importlib("stdole32.tlb"); - importlib("stdole2.tlb"); - - [ - uuid(7F760565-5719-4F04-BA86-112C474B10EA), - helpstring("_ISOActiveXEvents Interface") - ] - dispinterface _ISOActiveXEvents - { - properties: - methods: - }; - - [ - uuid(67F2A879-82D5-4A6D-8CC5-FFB3C114B69D), - helpstring("SOActiveX Class") - ] - coclass SOActiveX - { - [default] interface ISOActiveX; - [default, source] dispinterface _ISOActiveXEvents; - }; - - [ - uuid(EE51BD3E-8BB6-4FB8-B319-F65B1BE3B21D), - helpstring("SOComWindowPeer Class") - ] - coclass SOComWindowPeer - { - [default] interface ISOComWindowPeer; - }; - - [ - uuid(C5D6D568-57DA-4D6C-819A-451CB565E682), - helpstring("SODispatchInterceptor Class") - ] - coclass SODispatchInterceptor - { - [default] interface ISODispatchInterceptor; - }; - - [ - uuid(9F3697AC-7A18-4335-AF0A-65FAC2C35CC1), - helpstring("SOActionsApproval Class") - ] - coclass SOActionsApproval - { - [default] interface ISOActionsApproval; - }; - -}; - diff --git a/extensions/source/activex/resource.h b/extensions/source/activex/resource.h new file mode 100644 index 000000000000..fe74853c6d15 --- /dev/null +++ b/extensions/source/activex/resource.h @@ -0,0 +1,28 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +//{{NO_DEPENDENCIES}} +// Microsoft Developer Studio generated include file. +// Used by so_activex.rc +// +#define IDS_PROJNAME 100 +#define IDB_SOACTIVEX 101 +#define IDR_SOACTIVEX 102 +#define IDB_SOCOMWINDOWPEER 103 +#define IDR_SOCOMWINDOWPEER 104 +#define IDB_SODISPATCHINTERCEPTOR 105 +#define IDR_SODISPATCHINTERCEPTOR 106 +#define IDB_SODOCUMENTEVENTLISTENER 107 +#define IDR_SODOCUMENTEVENTLISTENER 108 + + +// Next default values for new objects +// +#ifdef APSTUDIO_INVOKED +#ifndef APSTUDIO_READONLY_SYMBOLS +#define _APS_NEXT_RESOURCE_VALUE 201 +#define _APS_NEXT_COMMAND_VALUE 32768 +#define _APS_NEXT_CONTROL_VALUE 201 +#define _APS_NEXT_SYMED_VALUE 107 +#endif +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/so_activex.cxx b/extensions/source/activex/so_activex.cxx new file mode 100644 index 000000000000..94dd0ccdcf1c --- /dev/null +++ b/extensions/source/activex/so_activex.cxx @@ -0,0 +1,685 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// so_activex.cpp : Implementation of DLL Exports. + + +// Note: Proxy/Stub Information +// To build a separate proxy/stub DLL, +// run nmake -f so_activexps.mk in the project directory. + +#include "stdio.h" +#include "stdafx2.h" +#include "resource.h" +#include +#include "so_activex.h" + +#include "so_activex_i.c" +#include "SOActiveX.h" + +#include + +CComModule _Module; + +BEGIN_OBJECT_MAP(ObjectMap) +OBJECT_ENTRY(CLSID_SOActiveX, CSOActiveX) +END_OBJECT_MAP() + + +#define X64_LIB_NAME "so_activex_x64.dll" +#define X32_LIB_NAME "so_activex.dll" + +// to provide windows xp as build systems for mingw we need to define KEY_WOW64_64KEY +// in mingw 3.13 KEY_WOW64_64KEY isn't available < Win2003 systems. +// Also defined in setup_native\source\win32\customactions\reg64\reg64.cxx,source\win32\customactions\shellextensions\shellextensions.cxx and +// extensions\source\activex\main\so_activex.cpp +#ifndef KEY_WOW64_64KEY + #define KEY_WOW64_64KEY (0x0100) +#endif +#ifndef KEY_WOW64_32KEY + #define KEY_WOW64_32KEY (0x0200) +#endif + +const REGSAM n64KeyAccess = KEY_ALL_ACCESS | KEY_WOW64_64KEY; +const REGSAM n32KeyAccess = KEY_ALL_ACCESS; + +#ifdef _AMD64_ +const BOOL bX64 = TRUE; +#define REG_DELETE_KEY_A( key, aPath, nKeyAccess ) RegDeleteKeyExA( key, aPath, nKeyAccess, 0 ) +#else +const BOOL bX64 = FALSE; +#define REG_DELETE_KEY_A( key, aPath, nKeyAccess ) RegDeleteKeyA( key, aPath ) +#endif + +// MinGW doesn't know anything about RegDeleteKeyExA if WINVER < 0x0502. +extern "C" { +WINADVAPI LONG WINAPI RegDeleteKeyExA(HKEY,LPCSTR,REGSAM,DWORD); +} + +///////////////////////////////////////////////////////////////////////////// +// DLL Entry Point + +extern "C" +BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID /*lpReserved*/) +{ + if (dwReason == DLL_PROCESS_ATTACH) + { + _Module.Init(ObjectMap, hInstance, &LIBID_SO_ACTIVEXLib); + DisableThreadLibraryCalls(hInstance); + } + else if (dwReason == DLL_PROCESS_DETACH) + _Module.Term(); + return TRUE; // ok +} + +///////////////////////////////////////////////////////////////////////////// +// Used to determine whether the DLL can be unloaded by OLE + +STDAPI DllCanUnloadNow(void) +{ + return (_Module.GetLockCount()==0) ? S_OK : S_FALSE; +} + +///////////////////////////////////////////////////////////////////////////// +// Returns a class factory to create an object of the requested type + +STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv) +{ + return _Module.GetClassObject(rclsid, riid, ppv); +} + +///////////////////////////////////////////////////////////////////////////// +// DllRegisterServer - Adds entries to the system registry + +// for now database component and chart are always installed +#define SUPPORTED_EXT_NUM 30 +const char* aFileExt[] = { ".vor", + ".sds", ".sda", ".sdd", ".sdp", ".sdc", ".sdw", ".smf", + ".stw", ".stc", ".sti", ".std", + ".sxw", ".sxc", ".sxi", ".sxd", ".sxg", ".sxm", + ".ott", ".otg", ".otp", ".ots", ".otf", + ".odt", ".oth", ".odm", ".odg", ".odp", ".ods", ".odf"}; +const char* aMimeType[] = { + "application/vnd.stardivision.writer", + + "application/vnd.stardivision.chart", + "application/vnd.stardivision.draw", + "application/vnd.stardivision.impress", + "application/vnd.stardivision.impress-packed", + "application/vnd.stardivision.calc", + "application/vnd.stardivision.writer", + "application/vnd.stardivision.math", + + MIMETYPE_VND_SUN_XML_WRITER_TEMPLATE_ASCII, + MIMETYPE_VND_SUN_XML_CALC_TEMPLATE_ASCII, + MIMETYPE_VND_SUN_XML_IMPRESS_TEMPLATE_ASCII, + MIMETYPE_VND_SUN_XML_DRAW_TEMPLATE_ASCII, + + MIMETYPE_VND_SUN_XML_WRITER_ASCII, + MIMETYPE_VND_SUN_XML_CALC_ASCII, + MIMETYPE_VND_SUN_XML_IMPRESS_ASCII, + MIMETYPE_VND_SUN_XML_DRAW_ASCII, + MIMETYPE_VND_SUN_XML_WRITER_GLOBAL_ASCII, + MIMETYPE_VND_SUN_XML_MATH_ASCII, + + MIMETYPE_OASIS_OPENDOCUMENT_TEXT_TEMPLATE_ASCII, + MIMETYPE_OASIS_OPENDOCUMENT_DRAWING_TEMPLATE_ASCII, + MIMETYPE_OASIS_OPENDOCUMENT_PRESENTATION_TEMPLATE_ASCII, + MIMETYPE_OASIS_OPENDOCUMENT_SPREADSHEET_TEMPLATE_ASCII, + MIMETYPE_OASIS_OPENDOCUMENT_FORMULA_TEMPLATE_ASCII, + + MIMETYPE_OASIS_OPENDOCUMENT_TEXT_ASCII, + MIMETYPE_OASIS_OPENDOCUMENT_TEXT_WEB_ASCII, + MIMETYPE_OASIS_OPENDOCUMENT_TEXT_GLOBAL_ASCII, + MIMETYPE_OASIS_OPENDOCUMENT_DRAWING_ASCII, + MIMETYPE_OASIS_OPENDOCUMENT_PRESENTATION_ASCII, + MIMETYPE_OASIS_OPENDOCUMENT_SPREADSHEET_ASCII, + MIMETYPE_OASIS_OPENDOCUMENT_FORMULA_ASCII }; + +const int nForModes[] = { 16, + 1, 2, 4, 4, 8, 16, 32, + 16, 8, 4, 2, + 16, 8, 4, 2, 16, 32, + 16, 2, 4, 8, 32, + 16, 16, 16, 2, 4, 8, 32 }; + +const char* aClassID = "{67F2A879-82D5-4A6D-8CC5-FFB3C114B69D}"; +const char* aTypeLib = "{61FA3F13-8061-4796-B055-3697ED28CB38}"; + +// ISOComWindowPeer interface information +const char* aInterIDWinPeer = "{BF5D10F3-8A10-4A0B-B150-2B6AA2D7E118}"; +const char* aProxyStubWinPeer = "{00020424-0000-0000-C000-000000000046}"; + +// ISODispatchInterceptor interface information +const char* aInterIDDispInt = "{9337694C-B27D-4384-95A4-9D8E0EABC9E5}"; +const char* aProxyStubDispInt = "{00020424-0000-0000-C000-000000000046}"; + +// ISOActionsApproval interface information +const char* aInterIDActApprove = "{029E9F1E-2B3F-4297-9160-8197DE7ED54F}"; +const char* aProxyStubActApprove = "{00020424-0000-0000-C000-000000000046}"; + +// The following prefix is required for HKEY_LOCAL_MACHINE and HKEY_CURRENT_USER ( not for HKEY_CLASSES_ROOT ) +const char* aLocalPrefix = "Software\\Classes\\"; + +BOOL createKey( HKEY hkey, + const char* aKeyToCreate, + REGSAM nKeyAccess, + const char* aValue = NULL, + const char* aChildName = NULL, + const char* aChildValue = NULL ) +{ + HKEY hkey1; + + return ( ERROR_SUCCESS == RegCreateKeyExA( hkey, aKeyToCreate, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) + && ( !aValue || ERROR_SUCCESS == RegSetValueExA( hkey1, + "", + 0, + REG_SZ, + (const BYTE*)aValue, + strlen( aValue ) ) ) + && ( !aChildName || ERROR_SUCCESS == RegSetValueExA( hkey1, + aChildName, + 0, + REG_SZ, + (const BYTE*)aChildValue, + strlen( aChildValue ) ) ) + && ERROR_SUCCESS == RegCloseKey( hkey1 ) ); + +} + +STDAPI DllUnregisterServerNative( int nMode, BOOL bForAllUsers, BOOL bFor64Bit ); +STDAPI DllRegisterServerNative_Impl( int nMode, BOOL bForAllUsers, REGSAM nKeyAccess, const char* pProgramPath, const char* pLibName ) +{ + BOOL aResult = FALSE; + + HKEY hkey = NULL; + HKEY hkey1 = NULL; + HKEY hkey2 = NULL; + HKEY hkey3 = NULL; + HKEY hkey4 = NULL; + char aSubKey[513]; + int ind; + const char* aPrefix = aLocalPrefix; // bForAllUsers ? "" : aLocalPrefix; + + char pActiveXPath[1124]; + char pActiveXPath101[1124]; + + + // In case SO7 is installed for this user he can have local registry entries that will prevent him from + // using SO8 ActiveX control. The fix is just to clean up the local entries related to ActiveX control. + // Unfortunately it can be done only for the user who installs the office. + if ( bForAllUsers ) + DllUnregisterServerNative( nMode, sal_False, sal_False ); + + if ( pProgramPath && strlen( pProgramPath ) < 1024 ) + { + sprintf( pActiveXPath, "%s\\%s", pProgramPath, pLibName ); + sprintf( pActiveXPath101, "%s\\%s, 101", pProgramPath, pLibName ); + + { + wsprintfA( aSubKey, "%sCLSID\\%s", aPrefix, aClassID ); + aResult = + ( ERROR_SUCCESS == RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey , NULL ) + && ERROR_SUCCESS == RegSetValueExA( hkey, "", 0, REG_SZ, (const BYTE*)"SOActiveX Class", 17 ) + && createKey( hkey, "Control", nKeyAccess ) + && createKey( hkey, "EnableFullPage", nKeyAccess ) + && createKey( hkey, "InprocServer32", nKeyAccess, pActiveXPath, "ThreadingModel", "Apartment" ) + && createKey( hkey, "MiscStatus", nKeyAccess, "0" ) + && createKey( hkey, "MiscStatus\\1", nKeyAccess, "131473" ) + && createKey( hkey, "ProgID", nKeyAccess, "so_activex.SOActiveX.1" ) + && createKey( hkey, "Programmable", nKeyAccess ) + && createKey( hkey, "ToolboxBitmap32", nKeyAccess, pActiveXPath101 ) + && createKey( hkey, "TypeLib", nKeyAccess, aTypeLib ) + && createKey( hkey, "Version", nKeyAccess, "1.0" ) + && createKey( hkey, "VersionIndependentProgID", nKeyAccess, "so_activex.SOActiveX" ) + && ERROR_SUCCESS == RegCloseKey( hkey ) + && ERROR_SUCCESS == RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aPrefix, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey , NULL ) + && createKey( hkey, "so_activex.SOActiveX", nKeyAccess, "SOActiveX Class" ) + && ERROR_SUCCESS == RegCreateKeyExA( hkey, "so_activex.SOActiveX", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) + && createKey( hkey1, "CLSID", nKeyAccess, aClassID ) + && createKey( hkey1, "CurVer", nKeyAccess, "so_activex.SOActiveX.1" ) + && ERROR_SUCCESS == RegCloseKey( hkey1 ) + && createKey( hkey, "so_activex.SOActiveX.1", nKeyAccess, "SOActiveX Class" ) + && ERROR_SUCCESS == RegCreateKeyExA( hkey, "so_activex.SOActiveX.1", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) + && createKey( hkey1, "CLSID", nKeyAccess, aClassID ) + && ERROR_SUCCESS == RegCloseKey( hkey1 ) + && ERROR_SUCCESS == RegCreateKeyExA( hkey, "TypeLib", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) + && ERROR_SUCCESS == RegCreateKeyExA( hkey1, aTypeLib, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey2 , NULL ) + && createKey( hkey2, "1.0", nKeyAccess, "wrap_activex 1.0 Type Library" ) + && ERROR_SUCCESS == RegCreateKeyExA( hkey2, "1.0", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey3 , NULL ) + && ERROR_SUCCESS == RegCreateKeyExA( hkey3, "0", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey4 , NULL ) + && createKey( hkey4, "win32", nKeyAccess, pActiveXPath ) + && ERROR_SUCCESS == RegCloseKey( hkey4 ) + && createKey( hkey3, "FLAGS", nKeyAccess, "0" ) + && createKey( hkey3, "HELPDIR", nKeyAccess, pProgramPath ) + && ERROR_SUCCESS == RegCloseKey( hkey3 ) + && ERROR_SUCCESS == RegCloseKey( hkey2 ) + && ERROR_SUCCESS == RegCloseKey( hkey1 ) + && ERROR_SUCCESS == RegCreateKeyExA( hkey, "Interface", 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) + && createKey( hkey1, aInterIDWinPeer, nKeyAccess, "ISOComWindowPeer" ) + && ERROR_SUCCESS == RegCreateKeyExA( hkey1, aInterIDWinPeer, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey2 , NULL ) + && createKey( hkey2, "ProxyStubClsid", nKeyAccess, aProxyStubWinPeer ) + && createKey( hkey2, "ProxyStubClsid32", nKeyAccess, aProxyStubWinPeer ) + && createKey( hkey2, "TypeLib", nKeyAccess, aTypeLib, "Version", "1.0" ) + && ERROR_SUCCESS == RegCloseKey( hkey2 ) + && createKey( hkey1, aInterIDActApprove, nKeyAccess, "ISOActionsApproval" ) + && ERROR_SUCCESS == RegCreateKeyExA( hkey1, aInterIDActApprove, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey2 , NULL ) + && createKey( hkey2, "ProxyStubClsid", nKeyAccess, aProxyStubActApprove ) + && createKey( hkey2, "ProxyStubClsid32", nKeyAccess, aProxyStubActApprove ) + && createKey( hkey2, "TypeLib", nKeyAccess, aTypeLib, "Version", "1.0" ) + && ERROR_SUCCESS == RegCloseKey( hkey2 ) + && createKey( hkey1, aInterIDDispInt, nKeyAccess, "ISODispatchInterceptor" ) + && ERROR_SUCCESS == RegCreateKeyExA( hkey1, aInterIDDispInt, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey2 , NULL ) + && createKey( hkey2, "ProxyStubClsid", nKeyAccess, aProxyStubDispInt ) + && createKey( hkey2, "ProxyStubClsid32", nKeyAccess, aProxyStubDispInt ) + && createKey( hkey2, "TypeLib", nKeyAccess, aTypeLib, "Version", "1.0" ) + && ERROR_SUCCESS == RegCloseKey( hkey2 ) + && ERROR_SUCCESS == RegCloseKey( hkey1 ) + && ERROR_SUCCESS == RegCloseKey( hkey ) ); + + hkey = hkey1 = hkey2 = hkey3 = hkey4 = NULL; + } + } + + for( ind = 0; ind < SUPPORTED_EXT_NUM && aResult; ind++ ) + { + if( nForModes[ind] & nMode ) + { + wsprintfA( aSubKey, "%sMIME\\DataBase\\Content Type\\%s", aPrefix, aMimeType[ind] ); + if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) +// || ERROR_SUCCESS != RegSetValueExA(hkey, "Extension", 0, REG_SZ, +// (const BYTE *)aFileExt[ind], strlen( aFileExt[ind] ) ) + || ERROR_SUCCESS != RegSetValueExA(hkey, "CLSID", 0, REG_SZ, + (const BYTE *)aClassID, strlen(aClassID)) ) + aResult = FALSE; + + if( hkey ) + RegCloseKey(hkey),hkey= NULL; + +/* + wsprintfA( aSubKey, "%s%s", aPrefix, aFileExt[ind] ); + if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) + || ERROR_SUCCESS != RegSetValueExA(hkey, "Content Type", 0, REG_SZ, + (const BYTE *)aMimeType[ind], strlen( aMimeType[ind] ) ) ) + aResult = FALSE; + if( hkey ) + RegCloseKey(hkey),hkey= NULL; +*/ + } + } + + wsprintfA( aSubKey, "%sCLSID\\%s", aPrefix, aClassID ); + if ( aResult && ERROR_SUCCESS == RegOpenKeyExA(bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, nKeyAccess, &hkey) ) + { + for( ind = 0; ind < SUPPORTED_EXT_NUM; ind++ ) + { + wsprintfA( aSubKey, "EnableFullPage\\%s", aFileExt[ind] ); + if ( ERROR_SUCCESS != RegCreateKeyExA( hkey, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) ) + aResult = FALSE; + + if ( hkey1 ) + RegCloseKey(hkey1),hkey1= NULL; + } + } + else + aResult = FALSE; + + if ( hkey ) + RegCloseKey(hkey),hkey= NULL; + + return aResult; +} + +STDAPI DllRegisterServerNative( int nMode, BOOL bForAllUsers, BOOL bFor64Bit, const char* pProgramPath ) +{ + HRESULT hr = S_OK; + if ( bFor64Bit ) + hr = DllRegisterServerNative_Impl( nMode, bForAllUsers, n64KeyAccess, pProgramPath, X64_LIB_NAME ); + + if ( SUCCEEDED( hr ) ) + hr = DllRegisterServerNative_Impl( nMode, bForAllUsers, n32KeyAccess, pProgramPath, X32_LIB_NAME ); + + return hr; +} + + +///////////////////////////////////////////////////////////////////////////// +// DllUnregisterServer - Removes entries from the system registry +HRESULT DeleteKeyTree( HKEY hkey, const char* pPath, REGSAM nKeyAccess ) +{ + HKEY hkey1 = NULL; + + char pSubKeyName[256]; + // first delete the subkeys + while( ERROR_SUCCESS == RegOpenKeyExA( hkey, pPath, 0, nKeyAccess, &hkey1) + && ERROR_SUCCESS == RegEnumKeyA( hkey1, 0, pSubKeyName, 256 ) + && ERROR_SUCCESS == DeleteKeyTree( hkey1, pSubKeyName, nKeyAccess ) ) + { + RegCloseKey( hkey1 ),hkey1= NULL; + } + + if ( hkey1 ) + RegCloseKey( hkey1 ),hkey1= NULL; + + // delete the key itself + return REG_DELETE_KEY_A( hkey, pPath, nKeyAccess & ( KEY_WOW64_64KEY | KEY_WOW64_32KEY ) ); +} + +STDAPI DllUnregisterServerNative_Impl( int nMode, BOOL bForAllUsers, REGSAM nKeyAccess ) +{ + HKEY hkey = NULL; + BOOL fErr = FALSE; + char aSubKey[513]; + const char* aPrefix = aLocalPrefix; // bForAllUsers ? "" : aLocalPrefix; + + for( int ind = 0; ind < SUPPORTED_EXT_NUM; ind++ ) + { + if( nForModes[ind] & nMode ) + { + DWORD nSubKeys = 0, nValues = 0; + wsprintfA( aSubKey, "%sMIME\\DataBase\\Content Type\\%s", aPrefix, aMimeType[ind] ); + if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) ) + fErr = TRUE; + else + { + if ( ERROR_SUCCESS != RegDeleteValue( hkey, "CLSID" ) ) + fErr = TRUE; + + if ( ERROR_SUCCESS != RegQueryInfoKey( hkey, NULL, NULL, NULL, + &nSubKeys, NULL, NULL, + &nValues, NULL, NULL, NULL, NULL ) ) + { + RegCloseKey( hkey ), hkey = NULL; + fErr = TRUE; + } + else + { + RegCloseKey( hkey ), hkey = NULL; + if ( !nSubKeys && !nValues ) + DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ); + } + } + + wsprintfA( aSubKey, "%s%s", aPrefix, aFileExt[ind] ); + if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) ) + fErr = TRUE; + else + { + if ( ERROR_SUCCESS != RegQueryInfoKey( hkey, NULL, NULL, NULL, + &nSubKeys, NULL, NULL, + &nValues, NULL, NULL, NULL, NULL ) ) + { + RegCloseKey( hkey ), hkey = NULL; + fErr = TRUE; + } + else + { + RegCloseKey( hkey ), hkey = NULL; + if ( !nSubKeys && !nValues ) + DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ); + } + } + } + } + + wsprintfA( aSubKey, "%sCLSID\\%s", aPrefix, aClassID ); + if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) + fErr = TRUE; + + wsprintfA( aSubKey, "%sso_activex.SOActiveX", aPrefix ); + if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) + fErr = TRUE; + + wsprintfA( aSubKey, "%sso_activex.SOActiveX.1", aPrefix ); + if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) + fErr = TRUE; + + wsprintfA( aSubKey, "%s\\TypeLib\\%s", aPrefix, aTypeLib ); + if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) + fErr = TRUE; + + wsprintfA( aSubKey, "%s\\Interface\\%s", aPrefix, aInterIDWinPeer ); + if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) + fErr = TRUE; + + wsprintfA( aSubKey, "%s\\Interface\\%s", aPrefix, aInterIDDispInt ); + if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) + fErr = TRUE; + + wsprintfA( aSubKey, "%s\\Interface\\%s", aPrefix, aInterIDActApprove ); + if( ERROR_SUCCESS != DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ) ) + fErr = TRUE; + + return !fErr; +} + +STDAPI DllUnregisterServerNative( int nMode, BOOL bForAllUsers, BOOL bFor64Bit ) +{ + HRESULT hr = DllUnregisterServerNative_Impl( nMode, bForAllUsers, n32KeyAccess ); + if ( SUCCEEDED( hr ) && bFor64Bit ) + hr = DllUnregisterServerNative_Impl( nMode, bForAllUsers, n64KeyAccess ); + + return hr; +} + + +///////////////////////////////////////////////////////////////////////////// +// DllRegisterServerDoc - Adds entries to the system registry + +#define SUPPORTED_MSEXT_NUM 7 +const char* aMSFileExt[] = { ".dot", ".doc", ".xlt", ".xls", ".pot", ".ppt", ".pps" }; +const char* aMSMimeType[] = { "application/msword", + "application/msword", + "application/msexcell", + "application/msexcell", + "application/mspowerpoint", + "application/mspowerpoint", + "application/mspowerpoint" }; +const int nForMSModes[] = { 1, 1, 2, 2, 4, 4, 4 }; + +STDAPI DllUnregisterServerDoc( int nMode, BOOL bForAllUsers, BOOL bFor64Bit ); +STDAPI DllRegisterServerDoc_Impl( int nMode, BOOL bForAllUsers, REGSAM nKeyAccess ) +{ + BOOL aResult = TRUE; + + HKEY hkey = NULL; + HKEY hkey1 = NULL; + char aSubKey[513]; + int ind; + const char* aPrefix = aLocalPrefix; // bForAllUsers ? "" : aLocalPrefix; + + // In case SO7 is installed for this user he can have local registry entries that will prevent him from + // using SO8 ActiveX control. The fix is just to clean up the local entries related to ActiveX control. + // Unfortunately it can be done only for the user who installs the office. + if ( bForAllUsers ) + DllUnregisterServerDoc( nMode, sal_False, sal_False ); + + for( ind = 0; ind < SUPPORTED_MSEXT_NUM && aResult; ind++ ) + { + if( nForMSModes[ind] & nMode ) + { + wsprintfA( aSubKey, "%sMIME\\DataBase\\Content Type\\%s", aPrefix, aMSMimeType[ind] ); + if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) + || ERROR_SUCCESS != RegSetValueExA(hkey, "Extension", 0, REG_SZ, + (const BYTE *)aMSFileExt[ind], strlen( aMSFileExt[ind] ) ) + || ERROR_SUCCESS != RegSetValueExA(hkey, "CLSID", 0, REG_SZ, + (const BYTE *)aClassID, strlen(aClassID)) ) + aResult = FALSE; + + if( hkey ) + RegCloseKey(hkey),hkey= NULL; + + wsprintfA( aSubKey, "%s%s", aPrefix, aMSFileExt[ind] ); + if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) + || ERROR_SUCCESS != RegSetValueExA(hkey, "Content Type", 0, REG_SZ, + (const BYTE *)aMSMimeType[ind], strlen( aMSMimeType[ind] ) ) ) + aResult = FALSE; + + if( hkey ) + RegCloseKey(hkey),hkey= NULL; + } + } + + wsprintfA( aSubKey, "%sCLSID\\%s", aPrefix, aClassID ); + if ( aResult && ERROR_SUCCESS == RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey , NULL ) + && createKey( hkey, "EnableFullPage", nKeyAccess ) ) + { + for( ind = 0; ind < SUPPORTED_MSEXT_NUM; ind++ ) + { + if( nForMSModes[ind] & nMode ) + { + wsprintfA( aSubKey, "EnableFullPage\\%s", aMSFileExt[ind] ); + if ( ERROR_SUCCESS != RegCreateKeyExA( hkey, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey1 , NULL ) ) + aResult = FALSE; + + if ( hkey1 ) + RegCloseKey(hkey1),hkey1= NULL; + } + } + } + else + aResult = FALSE; + + if ( hkey ) + RegCloseKey(hkey),hkey= NULL; + + return aResult; +} + +STDAPI DllRegisterServerDoc( int nMode, BOOL bForAllUsers, BOOL bFor64Bit ) +{ + HRESULT hr = S_OK; + if ( bFor64Bit ) + hr = DllRegisterServerDoc_Impl( nMode, bForAllUsers, n64KeyAccess ); + + if ( SUCCEEDED( hr ) ) + hr = DllRegisterServerDoc_Impl( nMode, bForAllUsers, n32KeyAccess ); + + return hr; +} + + +///////////////////////////////////////////////////////////////////////////// +// DllUnregisterServerDoc - Removes entries from the system registry + +STDAPI DllUnregisterServerDoc_Impl( int nMode, BOOL bForAllUsers, REGSAM nKeyAccess ) +{ + HKEY hkey = NULL; + BOOL fErr = FALSE; + char aSubKey[513]; + const char* aPrefix = aLocalPrefix; // bForAllUsers ? "" : aLocalPrefix; + + for( int ind = 0; ind < SUPPORTED_MSEXT_NUM; ind++ ) + { + if( nForMSModes[ind] & nMode ) + { + DWORD nSubKeys = 0, nValues = 0; + + wsprintfA( aSubKey, "%sMIME\\DataBase\\Content Type\\%s", aPrefix, aMSMimeType[ind] ); + if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) ) + fErr = TRUE; + else + { + if ( ERROR_SUCCESS != RegDeleteValue( hkey, "Extension" ) ) + fErr = TRUE; + + if ( ERROR_SUCCESS != RegDeleteValue( hkey, "CLSID" ) ) + fErr = TRUE; + + if ( ERROR_SUCCESS != RegQueryInfoKey( hkey, NULL, NULL, NULL, + &nSubKeys, NULL, NULL, + &nValues, NULL, NULL, NULL, NULL ) ) + { + RegCloseKey( hkey ), hkey = NULL; + fErr = TRUE; + } + else + { + RegCloseKey( hkey ), hkey = NULL; + if ( !nSubKeys && !nValues ) + DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ); + } + } + + wsprintfA( aSubKey, "%s%s", aPrefix, aMSFileExt[ind] ); + if ( ERROR_SUCCESS != RegCreateKeyExA( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, 0, NULL, REG_OPTION_NON_VOLATILE, nKeyAccess, NULL, &hkey, NULL ) ) + fErr = TRUE; + else + { + if ( ERROR_SUCCESS != RegDeleteValue( hkey, "Content Type" ) ) + fErr = TRUE; + + if ( ERROR_SUCCESS != RegQueryInfoKey( hkey, NULL, NULL, NULL, + &nSubKeys, NULL, NULL, + &nValues, NULL, NULL, NULL, NULL ) ) + { + RegCloseKey( hkey ), hkey = NULL; + fErr = TRUE; + } + else + { + RegCloseKey( hkey ), hkey = NULL; + if ( !nSubKeys && !nValues ) + DeleteKeyTree( bForAllUsers ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER, aSubKey, nKeyAccess ); + } + } + } + } + + return !fErr; +} + +STDAPI DllUnregisterServerDoc( int nMode, BOOL bForAllUsers, BOOL bFor64Bit ) +{ + HRESULT hr = S_OK; + if ( bFor64Bit ) + hr = DllUnregisterServerDoc_Impl( nMode, bForAllUsers, n64KeyAccess ); + + if ( SUCCEEDED( hr ) ) + hr = DllUnregisterServerDoc_Impl( nMode, bForAllUsers, n32KeyAccess ); + + return hr; +} + +///////////////////////////////////////////////////////////////////////////// +// DllRegisterServer - regsvr32 entry point + +STDAPI DllRegisterServer( void ) +{ + char pProgramPath[1024]; + HRESULT aResult = E_FAIL; + + HMODULE aCurModule = GetModuleHandleA( bX64 ? X64_LIB_NAME : X32_LIB_NAME ); + DWORD nLibNameLen = strlen( bX64 ? X64_LIB_NAME : X32_LIB_NAME ); + + if( aCurModule ) + { + DWORD nLen = GetModuleFileNameA( aCurModule, pProgramPath, 1024 ); + if ( nLen && nLen > nLibNameLen + 1 ) + { + pProgramPath[ nLen - nLibNameLen - 1 ] = 0; + aResult = DllRegisterServerNative( 31, TRUE, bX64, pProgramPath ); + if( SUCCEEDED( aResult ) ) + aResult = DllRegisterServerDoc( 31, TRUE, bX64 ); + else + { + aResult = DllRegisterServerNative( 31, FALSE, bX64, pProgramPath ); + if( SUCCEEDED( aResult ) ) + aResult = DllRegisterServerDoc( 31, FALSE, bX64 ); + } + } + } + + return aResult; +} + +///////////////////////////////////////////////////////////////////////////// +// DllUnregisterServer - regsvr32 entry point + +STDAPI DllUnregisterServer( void ) +{ + DllUnregisterServerDoc( 63, FALSE, bX64 ); + DllUnregisterServerNative( 63, FALSE, bX64 ); + DllUnregisterServerDoc( 63, TRUE, bX64 ); + return DllUnregisterServerNative( 63, TRUE, bX64 ); +} + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/activex/so_activex.def b/extensions/source/activex/so_activex.def new file mode 100644 index 000000000000..e3d56b070dad --- /dev/null +++ b/extensions/source/activex/so_activex.def @@ -0,0 +1,13 @@ +; iervp.def : Declares the module parameters. + +LIBRARY "so_activex.dll" + +EXPORTS + DllCanUnloadNow @1 PRIVATE + DllGetClassObject @2 PRIVATE + DllRegisterServer @3 PRIVATE + DllUnregisterServer @4 PRIVATE + DllRegisterServerNative @5 PRIVATE + DllRegisterServerDoc @6 PRIVATE + DllUnregisterServerNative @7 PRIVATE + DllUnregisterServerDoc @8 PRIVATE diff --git a/extensions/source/activex/so_activex.idl b/extensions/source/activex/so_activex.idl new file mode 100644 index 000000000000..d1a7d9936eed --- /dev/null +++ b/extensions/source/activex/so_activex.idl @@ -0,0 +1,210 @@ +// so_activex.idl : IDL source for so_activex.dll +// + +// This file will be processed by the MIDL tool to +// produce the type library (so_activex.tlb) and marshalling code. + +import "oaidl.idl"; +import "ocidl.idl"; +#include "olectl.h" + + + [ + object, + uuid(DACF7E3F-626B-4BF9-964B-F4910C843711), + dual, + helpstring("ISOActiveX Interface"), + pointer_default(unique) + ] + interface ISOActiveX : IDispatch + { + }; + +[ + object, + uuid(BF5D10F3-8A10-4A0B-B150-2B6AA2D7E118), + dual, + helpstring("ISOComWindowPeer Interface"), + pointer_default(unique) +] +interface ISOComWindowPeer : IDispatch +{ + [id(1), helpstring("method getWindowHandle")] + HRESULT getWindowHandle( [in] SAFEARRAY(VARIANT) procId, + [in] short s, + [out,retval] long* ret); + + [id(2), helpstring("method getToolkit")] + HRESULT getToolkit( [out,retval] IDispatch** retVal ); + + [id(3), helpstring("method setPointer")] + HRESULT setPointer( [in] IDispatch* xPointer ); + + [id(4), helpstring("method setBackground")] + HRESULT setBackground( [in] int nColor ); + + [id(5), helpstring("method invalidate")] + HRESULT invalidate( [in] short ); + + [id(6), helpstring("method invalidateRect")] + HRESULT invalidateRect( [in] IDispatch* aRect, [in] short nFlags ); + + [id(7), helpstring("method dispose")] + HRESULT dispose(); + + [id(8), helpstring("method addEventListener")] + HRESULT addEventListener( [in] IDispatch* xListener ); + + [id(9), helpstring("method removeEventListener")] + HRESULT removeEventListener( [in] IDispatch* xListener ); + + [propget, id(10), helpstring("property_implementedInterfaces")] + HRESULT Bridge_implementedInterfaces([out, retval] SAFEARRAY(BSTR) *pVal); +}; + +[ + object, + uuid(9337694C-B27D-4384-95A4-9D8E0EABC9E5), + dual, + helpstring("ISODispatchInterceptor Interface"), + pointer_default(unique) +] +interface ISODispatchInterceptor : IDispatch +{ +//com.sun.star.frame.XDispatchProviderInterceptor + + [id(1), helpstring("method getSlaveDispatchProvider")] + HRESULT getSlaveDispatchProvider( [out,retval] IDispatch** retVal ); + + [id(2), helpstring("method setSlaveDispatchProvider")] + HRESULT setSlaveDispatchProvider( [in] IDispatch* xNewDispatchProvider ); + + [id(3), helpstring("method getMasterDispatchProvider")] + HRESULT getMasterDispatchProvider( [out,retval] IDispatch** retVal ); + + [id(4), helpstring("method setMasterDispatchProvider")] + HRESULT setMasterDispatchProvider( [in] IDispatch* xNewSupplier ); + +// com.sun.star.frame.XDispatchProvider + + [id(5), helpstring("method queryDispatch")] + HRESULT queryDispatch( [in] IDispatch* aURL, + [in] BSTR aTargetFrameName, + [in] long nSearchFlags, + [out,retval] IDispatch** retVal ); + + [id(6), helpstring("method queryDispatches")] + HRESULT queryDispatches( [in] SAFEARRAY(IDispatch*) aDescripts, + [out,retval] SAFEARRAY(VARIANT)* retVal ); + + +// com.sun.star.frame.XDispatch + + [id(7), helpstring("method dispatch")] + HRESULT dispatch( [in] IDispatch* aURL, + [in] SAFEARRAY(VARIANT) aArgs ); + + [id(8), helpstring("method addStatusListener")] + HRESULT addStatusListener( [in] IDispatch* xControl, + [in] IDispatch* aURL ); + + [id(9), helpstring("method removeStatusListener")] + HRESULT removeStatusListener( [in] IDispatch* xControl, + [in] IDispatch* aURL ); + +// com.sun.star.frame.XInterceptorInfo + + + [id(10), helpstring("method getInterceptedURLs")] + HRESULT getInterceptedURLs( [out,retval] SAFEARRAY(BSTR)* pVal ); + +// the common UNO-COM staff + [propget, id(11), helpstring("property_implementedInterfaces")] + HRESULT Bridge_implementedInterfaces([out, retval] SAFEARRAY(BSTR) *pVal); + +}; + + + + +[ + object, + uuid(029E9F1E-2B3F-4297-9160-8197DE7ED54F), + dual, + helpstring("ISOActionsApproval Interface"), + pointer_default(unique) +] +interface ISOActionsApproval : IDispatch +{ +//com.sun.star.embed.XActionsApproval + + [id(1), helpstring("method approveAction")] + HRESULT approveAction( [in] long aActionID, + [out,retval] boolean* pbApproval ); + +// the common UNO-COM staff + [propget, id(2), helpstring("property_implementedInterfaces")] + HRESULT Bridge_implementedInterfaces([out, retval] SAFEARRAY(BSTR) *pVal); +}; + + + +[ + uuid(61FA3F13-8061-4796-B055-3697ED28CB38), + version(1.0), + helpstring("so_activex 1.0 Type Library") +] +library SO_ACTIVEXLib +{ + importlib("stdole32.tlb"); + importlib("stdole2.tlb"); + + [ + uuid(7F760565-5719-4F04-BA86-112C474B10EA), + helpstring("_ISOActiveXEvents Interface") + ] + dispinterface _ISOActiveXEvents + { + properties: + methods: + }; + + [ + uuid(67F2A879-82D5-4A6D-8CC5-FFB3C114B69D), + helpstring("SOActiveX Class") + ] + coclass SOActiveX + { + [default] interface ISOActiveX; + [default, source] dispinterface _ISOActiveXEvents; + }; + + [ + uuid(EE51BD3E-8BB6-4FB8-B319-F65B1BE3B21D), + helpstring("SOComWindowPeer Class") + ] + coclass SOComWindowPeer + { + [default] interface ISOComWindowPeer; + }; + + [ + uuid(C5D6D568-57DA-4D6C-819A-451CB565E682), + helpstring("SODispatchInterceptor Class") + ] + coclass SODispatchInterceptor + { + [default] interface ISODispatchInterceptor; + }; + + [ + uuid(9F3697AC-7A18-4335-AF0A-65FAC2C35CC1), + helpstring("SOActionsApproval Class") + ] + coclass SOActionsApproval + { + [default] interface ISOActionsApproval; + }; + +}; + diff --git a/extensions/source/activex/so_activex.rc b/extensions/source/activex/so_activex.rc new file mode 100644 index 000000000000..adba0ee79f8c --- /dev/null +++ b/extensions/source/activex/so_activex.rc @@ -0,0 +1,111 @@ +//Microsoft Developer Studio generated resource script. +// +#include "resource.h" + +#define APSTUDIO_READONLY_SYMBOLS +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 2 resource. +// +#if defined(_MSC_VER) && (_MSC_VER < 1500) +#include "winres.h" +#else +#define WINVER 0x0500 +#include +#define LB_ADDSTRING (WM_USER+1) +#define CB_ADDSTRING (WM_USER+3) +#define IDC_STATIC (-1) +#endif + +///////////////////////////////////////////////////////////////////////////// +#undef APSTUDIO_READONLY_SYMBOLS + +///////////////////////////////////////////////////////////////////////////// +// Russian resources + +//#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_RUS) +//#ifdef _WIN32 +//LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT +//#pragma code_page(1251) +//#endif //_WIN32 + +///////////////////////////////////////////////////////////////////////////// +// +// Bitmap +// + +//IDB_SOACTIVEX BITMAP DISCARDABLE "soacti.bmp" + + +///////////////////////////////////////////////////////////////////////////// +// +// REGISTRY +// + +IDR_SOACTIVEX REGISTRY DISCARDABLE "SOActiveX.rgs" +IDR_SOCOMWINDOWPEER REGISTRY DISCARDABLE "SOComWindowPeer.rgs" +IDR_SODISPATCHINTERCEPTOR REGISTRY DISCARDABLE "SODispatchInterceptor.rgs" +//#endif // Russian resources +///////////////////////////////////////////////////////////////////////////// + + +///////////////////////////////////////////////////////////////////////////// +// English (U.S.) resources + +#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) +#ifdef _WIN32 +LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US +#pragma code_page(1252) +#endif //_WIN32 + +#ifdef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// TEXTINCLUDE +// + +1 TEXTINCLUDE DISCARDABLE +BEGIN + "resource.h\0" +END + +2 TEXTINCLUDE DISCARDABLE +BEGIN + "#include ""winres.h""\r\n" + "\0" +END + +3 TEXTINCLUDE DISCARDABLE +BEGIN + "1 TYPELIB ""so_activex.tlb""\r\n" + "\0" +END + +#endif // APSTUDIO_INVOKED + +///////////////////////////////////////////////////////////////////////////// +// +// String Table +// + +STRINGTABLE DISCARDABLE +BEGIN + IDS_PROJNAME "so_activex" +END + +#endif // English (U.S.) resources +///////////////////////////////////////////////////////////////////////////// + + + +#ifndef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 3 resource. +// + +1 TYPELIB MISC\so_activex.tlb + +///////////////////////////////////////////////////////////////////////////// +#endif // not APSTUDIO_INVOKED + -- cgit From c439bc7a4aa0a4e01e0d01e09c5869619240c040 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Sun, 18 Dec 2011 01:42:41 +0100 Subject: extensions: tweak activex makefiles --- extensions/Library_so_activex.mk | 11 ++++++----- extensions/Library_so_activex_x64.mk | 17 ++++++++--------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/extensions/Library_so_activex.mk b/extensions/Library_so_activex.mk index 732b2713e077..f4d0d2f4f90e 100644 --- a/extensions/Library_so_activex.mk +++ b/extensions/Library_so_activex.mk @@ -37,6 +37,12 @@ $(WORKDIR)/CustomTarget/so_activex/so_activex.tlb: $(SRCDIR)/extensions/source/a midl.exe -out $(call gb_Helper_convert_native,$(WORKDIR)/CustomTarget/so_activex) -Oicf $(call gb_Helper_convert_native,$<) \ $(foreach i,$(SOLARINC_FOR_BUILD), $(patsubst -I,/I,$(i))) +$(call gb_Library_get_clean_target,so_activex) : extensions_activex_idlclean + +.PHONY: extensions_activex_idlclean +extensions_activex_idlclean: + rm -rf $(WORKDIR)/CustomTarget/so_activex + $(eval $(call gb_Library_set_include,so_activex,\ $$(INCLUDE) \ -I$(WORKDIR)/CustomTarget/so_activex \ @@ -83,9 +89,4 @@ $(eval $(call gb_Library_add_libs,so_activex,\ )) endif -$(call gb_Library_get_clean_target,so_activex): idlclean - -idlclean: - rm -rf $(WORKDIR)/CustomTarget/so_activex - # vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Library_so_activex_x64.mk b/extensions/Library_so_activex_x64.mk index eab054d1dae1..f7cfa0b2a257 100644 --- a/extensions/Library_so_activex_x64.mk +++ b/extensions/Library_so_activex_x64.mk @@ -48,17 +48,18 @@ $(eval $(call gb_Library_add_api,so_activex_x64,\ $(eval $(call gb_Library_add_nativeres,so_activex_x64,activex_res)) -$(WORKDIR)/extensions/source/activex/%.cxx: $(SRCDIR)/extensions/source/activex/%.cxx +$(WORKDIR)/CustomTarget/extensions/source/activex/%.cxx : \ + $(SRCDIR)/extensions/source/activex/%.cxx mkdir -p $(dir $@) cp $< $@ $(eval $(call gb_Library_add_x64_generated_exception_objects,so_activex_x64,\ - extensions/source/activex/so_activex \ - extensions/source/activex/SOActiveX \ - extensions/source/activex/SOComWindowPeer \ - extensions/source/activex/SODispatchInterceptor \ - extensions/source/activex/SOActionsApproval \ - extensions/source/activex/StdAfx2 \ + CustomTarget/extensions/source/activex/so_activex \ + CustomTarget/extensions/source/activex/SOActiveX \ + CustomTarget/extensions/source/activex/SOComWindowPeer \ + CustomTarget/extensions/source/activex/SODispatchInterceptor \ + CustomTarget/extensions/source/activex/SOActionsApproval \ + CustomTarget/extensions/source/activex/StdAfx2 \ )) $(eval $(call gb_Library_add_ldflags,so_activex_x64,\ @@ -85,6 +86,4 @@ $(eval $(call gb_Library_add_libs,so_activex_x64,\ )) endif -$(call gb_Library_get_clean_target,so_activex_x64): idlclean - # vim:set shiftwidth=4 softtabstop=4 expandtab: -- cgit From eb2939e19075f9c4cd79cf468b1c4b6200623db9 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sun, 18 Dec 2011 01:46:03 +0100 Subject: gbuild: MSVC: add support for building x64 libraries The committer wants to state that he has no opinion on the content of this commit due to total ignorance of the problem area. --- solenv/gbuild/Library.mk | 2 ++ solenv/gbuild/LinkTarget.mk | 14 ++++++++++++++ solenv/gbuild/platform/WNT_INTEL_MSC.mk | 13 ++++++------- 3 files changed, 22 insertions(+), 7 deletions(-) diff --git a/solenv/gbuild/Library.mk b/solenv/gbuild/Library.mk index 82daae1d97a6..0de2876c89ec 100644 --- a/solenv/gbuild/Library.mk +++ b/solenv/gbuild/Library.mk @@ -120,6 +120,7 @@ $(eval $(foreach method,\ add_asmobject \ add_asmobjects \ add_exception_objects \ + add_x64_generated_exception_objects \ add_noexception_objects \ add_generated_cobjects \ add_generated_cxxobjects \ @@ -139,6 +140,7 @@ $(eval $(foreach method,\ set_include \ add_ldflags \ set_ldflags \ + set_x64 \ add_libs \ set_library_path_flags \ add_api \ diff --git a/solenv/gbuild/LinkTarget.mk b/solenv/gbuild/LinkTarget.mk index c094bb424b54..94fcca6e13c2 100644 --- a/solenv/gbuild/LinkTarget.mk +++ b/solenv/gbuild/LinkTarget.mk @@ -416,6 +416,7 @@ $(call gb_LinkTarget_get_headers_target,%) : $(call gb_LinkTarget_get_external_h # on clean. # - TARGETTYPE is the type of linktarget as some platforms need very different # command to link different targettypes. +# - LIBRARY_X64 is only relevent for building a x64 library on windows. # # Since most variables are set on the linktarget and not on the object, the # object learns about these setting via GNU makes scoping of target variables. @@ -465,6 +466,7 @@ $(call gb_LinkTarget_get_target,$(1)) : LINKED_LIBS := $(call gb_LinkTarget_get_target,$(1)) : LINKED_STATIC_LIBS := $(call gb_LinkTarget_get_target,$(1)) : LIBS := $(call gb_LinkTarget_get_target,$(1)) : TARGETTYPE := +$(call gb_LinkTarget_get_target,$(1)) : LIBRARY_X64 := $(call gb_LinkTarget_get_headers_target,$(1)) \ $(call gb_LinkTarget_get_target,$(1)) : PDBFILE := $(call gb_LinkTarget_get_target,$(1)) : EXTRAOBJECTLISTS := @@ -489,6 +491,7 @@ $(call gb_LinkTarget_get_dep_target,$(1)) : DEFS := $$(gb_LinkTarget_DEFAULTDEFS $(call gb_LinkTarget_get_dep_target,$(1)) : INCLUDE := $$(gb_LinkTarget_INCLUDE) $(call gb_LinkTarget_get_dep_target,$(1)) : INCLUDE_STL := $$(gb_LinkTarget_INCLUDE_STL) $(call gb_LinkTarget_get_dep_target,$(1)) : TARGETTYPE := +$(call gb_LinkTarget_get_dep_target,$(1)) : LIBRARY_X64 := $(call gb_LinkTarget_get_dep_target,$(1)) : EXTRAOBJECTLISTS := endif @@ -869,6 +872,12 @@ define gb_LinkTarget_add_exception_objects $(foreach obj,$(2),$(call gb_LinkTarget_add_exception_object,$(1),$(obj))) endef +#only useful for building x64 libraries on windows +define gb_LinkTarget_add_x64_generated_exception_objects +$(foreach obj,$(2),$(call gb_LinkTarget_add_generated_exception_object,$(1),$(obj))) +$(foreach obj,$(2),$(eval $(call gb_GenCxxObject_get_target,$(obj)) : CXXOBJECT_X64 := YES)) +endef + define gb_LinkTarget_add_generated_cobjects $(foreach obj,$(2),$(call gb_LinkTarget_add_generated_c_object,$(1),$(obj),$(3))) endef @@ -890,6 +899,11 @@ $(call gb_LinkTarget_get_target,$(1)) \ $(call gb_LinkTarget_get_dep_target,$(1)) : TARGETTYPE := $(2) endef +define gb_LinkTarget_set_x64 +$(call gb_LinkTarget_get_target,$(1)) \ +$(call gb_LinkTarget_get_dep_target,$(1)) : LIBRARY_X64 := $(2) +endef + define gb_LinkTarget_set_dlltarget $(call gb_LinkTarget_get_clean_target,$(1)) \ $(call gb_LinkTarget_get_target,$(1)) : DLLTARGET := $(2) diff --git a/solenv/gbuild/platform/WNT_INTEL_MSC.mk b/solenv/gbuild/platform/WNT_INTEL_MSC.mk index 45c960905f58..1e068ffe8ee4 100644 --- a/solenv/gbuild/platform/WNT_INTEL_MSC.mk +++ b/solenv/gbuild/platform/WNT_INTEL_MSC.mk @@ -75,9 +75,7 @@ gb_RCDEFS := \ gb_RCFLAGS := \ -V -# FIXME: When porting to Windows64, we should use only: -# /c /Cp -gb_AFLAGS := /c /Cp /coff /safeseh +gb_AFLAGS := /c /Cp gb_CFLAGS := \ -Gd \ @@ -207,7 +205,6 @@ gb_LinkTarget_NOEXCEPTIONFLAGS := \ -DEXCEPTIONS_OFF \ gb_LinkTarget_LDFLAGS := \ - -MACHINE:IX86 \ -MANIFEST \ $(patsubst %,-LIBPATH:%,$(filter-out .,$(subst ;, ,$(subst \,/,$(ILIB))))) \ @@ -302,13 +299,14 @@ define gb_CxxObject__command $(call gb_Output_announce,$(2),$(true),CXX,3) $(call gb_Helper_abbreviate_dirs_native,\ mkdir -p $(dir $(1)) $(dir $(4)) && \ - $(gb_CXX) \ + $(if $(filter YES,$(CXXOBJECT_X64)), $(CXX_X64_BINARY), $(gb_CXX)) \ $(DEFS) \ $(T_CXXFLAGS) \ -Fd$(PDBFILE) \ $(gb_COMPILERDEPFLAGS) \ -I$(realpath $(dir $(3))) \ $(INCLUDE_STL) $(INCLUDE) \ + $(if $(filter YES,$(CXXOBJECT_X64)), -U_X86_ -D_AMD64_,) \ -c $(realpath $(3)) \ -Fo$(1)) $(call gb_create_deps,$(1),$(4),$(realpath $(3))) endef @@ -353,11 +351,13 @@ $(call gb_Helper_abbreviate_dirs_native,\ $(foreach object,$(ASMOBJECTS),$(call gb_AsmObject_get_target,$(object))) \ $(foreach extraobjectlist,$(EXTRAOBJECTLISTS),$(shell cat $(extraobjectlist))) \ $(NATIVERES))) && \ - $(gb_LINK) \ + $(if $(filter YES,$(LIBRARY_X64)), $(LINK_X64_BINARY), $(gb_LINK)) \ $(if $(filter Library CppunitTest,$(TARGETTYPE)),$(gb_Library_TARGETTYPEFLAGS)) \ $(if $(filter StaticLibrary,$(TARGETTYPE)),$(gb_StaticLibrary_TARGETTYPEFLAGS)) \ $(if $(filter Executable,$(TARGETTYPE)),$(gb_Executable_TARGETTYPEFLAGS)) \ $(if $(filter YES,$(TARGETGUI)), -SUBSYSTEM:WINDOWS, -SUBSYSTEM:CONSOLE) \ + $(if $(filter YES,$(LIBRARY_X64)), -MACHINE:X64, -MACHINE:IX86) \ + $(if $(filter YES,$(LIBRARY_X64)), -LIBPATH:$(COMPATH)/lib/amd64 -LIBPATH:$(WINDOWS_SDK_HOME)/lib/x64,) \ $(T_LDFLAGS) \ $(if $(gb_PRODUCT),,-NODEFAULTLIB) \ @$${RESPONSEFILE} \ @@ -377,7 +377,6 @@ gb_Windows_PE_TARGETTYPEFLAGS := \ -opt:noref \ -incremental:no \ -debug \ - -safeseh \ -nxcompat \ -dynamicbase \ -- cgit From c7210a27424f5f82e1c90b94c711fb9170ccffb3 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sun, 18 Dec 2011 02:04:02 +0100 Subject: extensions: remove obsolete dmake stuff --- RepositoryModule_ooo.mk | 1 + extensions/inc/makefile.mk | 39 ------------------------------- extensions/prj/build.lst | 5 ---- extensions/prj/d.lst | 55 -------------------------------------------- extensions/util/makefile.mk | 39 ------------------------------- extensions/util/makefile.pmk | 29 ----------------------- extensions/util/target.pmk | 35 ---------------------------- 7 files changed, 1 insertion(+), 202 deletions(-) delete mode 100644 extensions/inc/makefile.mk delete mode 100644 extensions/util/makefile.mk delete mode 100644 extensions/util/makefile.pmk delete mode 100644 extensions/util/target.pmk diff --git a/RepositoryModule_ooo.mk b/RepositoryModule_ooo.mk index 7a2d68db9521..6389d155144c 100644 --- a/RepositoryModule_ooo.mk +++ b/RepositoryModule_ooo.mk @@ -47,6 +47,7 @@ $(eval $(call gb_Module_add_moduledirs,ooo,\ dtrans \ editeng \ eventattacher \ + extensions \ fileaccess \ filter \ forms \ diff --git a/extensions/inc/makefile.mk b/extensions/inc/makefile.mk deleted file mode 100644 index 82d75bea7f8b..000000000000 --- a/extensions/inc/makefile.mk +++ /dev/null @@ -1,39 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -PRJ=.. - -PRJNAME=extensions -TARGET=inc - -# --- Settings ----------------------------------------------------- - -.INCLUDE : settings.mk - -# --- Files -------------------------------------------------------- -# --- Targets ------------------------------------------------------- - -.INCLUDE : target.mk diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst index df4ba361d372..06f2e2de9a66 100644 --- a/extensions/prj/build.lst +++ b/extensions/prj/build.lst @@ -1,9 +1,4 @@ ex extensions : officecfg TRANSLATIONS:translations DESKTOP:rdbmaker svx SANE:sane TWAIN:twain np_sdk offapi stoc ZLIB:zlib CURL:curl LIBXSLT:libxslt CPPUNIT:cppunit NULL - -ex extensions usr1 - all ex_mkout NULL -ex extensions\inc nmake - all ex_inc NULL -ex extensions\inc\ucbhelper get - all ex_incucbh ex_inc NULL -ex extensions\util nmake - all ex_util NULL ex extensions\prj nmake - all ex_prj NULL # Fails at the moment diff --git a/extensions/prj/d.lst b/extensions/prj/d.lst index 01025ae00c68..e69de29bb2d1 100644 --- a/extensions/prj/d.lst +++ b/extensions/prj/d.lst @@ -1,55 +0,0 @@ -mkdir: %COMMON_DEST%\bin\hid -mkdir: %_DEST%\xml\uiconfig -mkdir: %_DEST%\xml\uiconfig\modules -mkdir: %_DEST%\xml\uiconfig\modules\sbibliography -mkdir: %_DEST%\xml\uiconfig\modules\sbibliography\menubar -mkdir: %_DEST%\bin\odf4ms -mkdir: %_DEST%\bin\so - -..\%COMMON_OUTDIR%\misc\*.hid %COMMON_DEST%\bin\hid\*.hid -..\%__SRC%\bin\*.dll %_DEST%\bin\*.dll -..\%__SRC%\lib\lib*.so %_DEST%\lib -..\%__SRC%\lib\ldapbe2.uno.so %_DEST%\lib\ldapbe2.uno.so -..\%__SRC%\lib\updchk.uno.so %_DEST%\lib\updchk.uno.so -..\%__SRC%\lib\updatefeed.uno.so %_DEST%\lib\updatefeed.uno.so -..\%__SRC%\bin\oleautobridge2.uno.dll %_DEST%\bin\odf4ms\oleautobridge.uno.dll -..\%__SRC%\lib\*.dylib %_DEST%\lib\*.dylib -..\%__SRC%\bin\pluginapp.bin %_DEST%\bin\pluginapp.bin -..\%__SRC%\bin\*.res %_DEST%\bin\*.res -..\%__SRC%\bin\nsplugin.exe %_DEST%\bin\nsplugin.exe -..\%__SRC%\bin\nsplugin %_DEST%\bin\nsplugin -..\%__SRC%\bin\npsoplugin.dll %_DEST%\bin\npsoplugin.dll -..\%__SRC%\bin\npsoplugin_so.dll %_DEST%\bin\so\npsoplugin.dll -..\%__SRC%\bin\x64\so_activex.dll %_DEST%\bin\so_activex_x64.dll -..\%__SRC%\bin\mdibundle.zip %_DEST%\bin\mdibundle.zip -..\%__SRC%\misc\oleautobridge.component %_DEST%\xml\oleautobridge.component - -..\source\bibliography\uiconfig\sbibliography\menubar\*.xml %_DEST%\xml\uiconfig\modules\sbibliography\menubar\*.xml - -..\source\propctrlr\pcr.xml %_DEST%\xml\pcr.xml - -mkdir: %_DEST%\xml\registry\spool -mkdir: %_DEST%\xml\registry\spool\org -mkdir: %_DEST%\xml\registry\spool\org\openoffice -mkdir: %_DEST%\xml\registry\spool\org\openoffice\Office\Addons -mkdir: %_DEST%\xml\registry\spool\org\openoffice\Office\Jobs -mkdir: %_DEST%\xml\registry\spool\org\openoffice\Office\Logging - -..\%__SRC%\misc\registry\spool\org\openoffice\Office\Addons\*.xcu %_DEST%\xml\registry\spool\org\openoffice\Office\Addons -..\%__SRC%\misc\registry\spool\org\openoffice\Office\Jobs\*.xcu %_DEST%\xml\registry\spool\org\openoffice\Office\Jobs -..\%__SRC%\misc\registry\spool\org\openoffice\Office\Logging\*.xcu %_DEST%\xml\registry\spool\org\openoffice\Office\Logging - -..\%__SRC%\bin\*.oxt %_DEST%\pck\* -..\%__SRC%\misc\abp.component %_DEST%\xml\abp.component -..\%__SRC%\misc\bib.component %_DEST%\xml\bib.component -..\%__SRC%\misc\dbp.component %_DEST%\xml\dbp.component -..\%__SRC%\misc\ldapbe2.component %_DEST%\xml\ldapbe2.component -..\%__SRC%\misc\log.component %_DEST%\xml\log.component -..\%__SRC%\misc\pcr.component %_DEST%\xml\pcr.component -..\%__SRC%\misc\pl.component %_DEST%\xml\pl.component -..\%__SRC%\misc\res.component %_DEST%\xml\res.component -..\%__SRC%\misc\scn.component %_DEST%\xml\scn.component -..\%__SRC%\misc\updatefeed.component %_DEST%\xml\updatefeed.component -..\%__SRC%\misc\updchk.component %_DEST%\xml\updchk.component -..\%__SRC%\misc\updchk.uno.component %_DEST%\xml\updchk.uno.component -..\%__SRC%\misc\xmx.component %_DEST%\xml\xmx.component diff --git a/extensions/util/makefile.mk b/extensions/util/makefile.mk deleted file mode 100644 index af6b1ec8c600..000000000000 --- a/extensions/util/makefile.mk +++ /dev/null @@ -1,39 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=.. -PRJNAME=extensions -TARGET=ext -GEN_HID=TRUE -GEN_HID_OTHER=TRUE - -# --- Settings ---------------------------------- - -.INCLUDE : settings.mk - -.INCLUDE : target.mk - diff --git a/extensions/util/makefile.pmk b/extensions/util/makefile.pmk deleted file mode 100644 index b80a9c7bd3c2..000000000000 --- a/extensions/util/makefile.pmk +++ /dev/null @@ -1,29 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -.INCLUDE : settings.mk - diff --git a/extensions/util/target.pmk b/extensions/util/target.pmk deleted file mode 100644 index c7c1de9c2563..000000000000 --- a/extensions/util/target.pmk +++ /dev/null @@ -1,35 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* -ALLSLO: $(SLOFILES) - -SOSHL: $(SHL1TARGETN) - -WHOLEPRJ: - cd $(PRJ)$/prj - make debug linkinc prjpch compinc - @echo "READY" - -- cgit From f55b5ef370f6e477e2540636aa3b24f9b8de5a09 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sun, 18 Dec 2011 02:10:12 +0100 Subject: extensions: add to tail_build --- Module_tail_build.mk | 1 + postprocess/prj/build.lst | 2 +- tail_build/prj/build.lst | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 9b0dc4c68af3..30c9e0363941 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -33,6 +33,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ dbaccess \ desktop \ eventattacher \ + extensions \ fileaccess \ filter \ forms \ diff --git a/postprocess/prj/build.lst b/postprocess/prj/build.lst index 50f4f60a998d..af13689d64e0 100644 --- a/postprocess/prj/build.lst +++ b/postprocess/prj/build.lst @@ -1,4 +1,4 @@ -po postprocess :: accessibility BINFILTER:binfilter configmgr CRASHREP:crashrep CT2N:ct2n dtrans embeddedobj embedserv EPM:epm DESKTOP:extensions extras DESKTOP:fpicker HELP:helpcontent2 io LIBRSVG:librsvg ODK:odk officecfg psprint_config remotebridges scaddins scp2 DESKTOP:setup_native sysui testtools ucb UnoControls ure wizards MORE_FONTS:more_fonts DICTIONARIES:dictionaries PYUNO:pyuno readlicense_oo DESKTOP:unodevtools JFREEREPORT:jfreereport REPORTBUILDER:reportbuilder LANGUAGETOOL:languagetool SDEXT:sdext MYSQLC:mysqlc NLPSOLVER:nlpsolver STLPORT:stlport LIBXSLT:libxslt smoketest tail_build NULL +po postprocess :: accessibility BINFILTER:binfilter configmgr CRASHREP:crashrep CT2N:ct2n dtrans embeddedobj embedserv EPM:epm extras DESKTOP:fpicker HELP:helpcontent2 io LIBRSVG:librsvg ODK:odk officecfg psprint_config remotebridges scaddins scp2 DESKTOP:setup_native sysui testtools ucb UnoControls ure wizards MORE_FONTS:more_fonts DICTIONARIES:dictionaries PYUNO:pyuno readlicense_oo DESKTOP:unodevtools JFREEREPORT:jfreereport REPORTBUILDER:reportbuilder LANGUAGETOOL:languagetool SDEXT:sdext MYSQLC:mysqlc NLPSOLVER:nlpsolver STLPORT:stlport LIBXSLT:libxslt smoketest tail_build NULL po postprocess usr1 - all po_mkout NULL po postprocess\checkxml nmake - all po_checkxml NULL po postprocess\packconfig nmake - all po_packconfig po_checkxml NULL diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index 19d0cc5bd1f5..c32aef296083 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SAXON:saxon TRANSLATIONS:translations XPDF:xpdf avmedia basegfx basic bridges canvas comphelper configmgr connectivity cppcanvas cppu cppuhelper DESKTOP:fpicker javaunohelper jurt jvmaccess offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax sfx2 solenv soltools sot stoc svl svtools svx sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib avmedia basegfx basic bridges canvas comphelper connectivity cppcanvas cppu cppuhelper DESKTOP:fpicker javaunohelper jurt jvmaccess np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax sfx2 solenv soltools sot stoc svl svtools svx sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From e1d34f15cc82b4e9b10eca0e8efb50793080f1b6 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Mon, 19 Dec 2011 15:26:33 +0100 Subject: extensions: what is all this realpath stuff doing? --- extensions/AllLangResTarget_abp.mk | 2 +- extensions/AllLangResTarget_bib.mk | 6 +----- extensions/AllLangResTarget_dbp.mk | 2 +- extensions/CppunitTest_extensions_test_update.mk | 2 +- extensions/Library_abp.mk | 4 ++-- extensions/Library_bib.mk | 2 +- extensions/Library_dbp.mk | 4 ++-- extensions/Library_so_activex_x64.mk | 2 +- 8 files changed, 10 insertions(+), 14 deletions(-) diff --git a/extensions/AllLangResTarget_abp.mk b/extensions/AllLangResTarget_abp.mk index 30371f93a648..cda588efb24d 100644 --- a/extensions/AllLangResTarget_abp.mk +++ b/extensions/AllLangResTarget_abp.mk @@ -38,7 +38,7 @@ $(eval $(call gb_SrsTarget_SrsTarget,abp/res)) $(eval $(call gb_SrsTarget_set_include,abp/res,\ $$(INCLUDE) \ - -I$(realpath $(SRCDIR)/extensions/inc) \ + -I$(SRCDIR)/extensions/inc \ )) $(eval $(call gb_SrsTarget_add_files,abp/res,\ diff --git a/extensions/AllLangResTarget_bib.mk b/extensions/AllLangResTarget_bib.mk index 36b22c392b1f..bcc5d1e10e8f 100644 --- a/extensions/AllLangResTarget_bib.mk +++ b/extensions/AllLangResTarget_bib.mk @@ -36,7 +36,7 @@ $(eval $(call gb_SrsTarget_SrsTarget,bib/res)) $(eval $(call gb_SrsTarget_set_include,bib/res,\ $$(INCLUDE) \ - -I$(realpath $(SRCDIR)/extensions/inc) \ + -I$(SRCDIR)/extensions/inc \ )) $(eval $(call gb_SrsTarget_add_files,bib/res,\ @@ -46,8 +46,4 @@ $(eval $(call gb_SrsTarget_add_files,bib/res,\ extensions/source/bibliography/toolbar.src \ )) -$(eval $(call gb_SrsTarget_add_templates,bib/res,\ - extensions/source/bibliography/bib.hrc \ -)) - # vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/AllLangResTarget_dbp.mk b/extensions/AllLangResTarget_dbp.mk index 657694af7e22..88cc38992b4c 100644 --- a/extensions/AllLangResTarget_dbp.mk +++ b/extensions/AllLangResTarget_dbp.mk @@ -36,7 +36,7 @@ $(eval $(call gb_SrsTarget_SrsTarget,dbp/res)) $(eval $(call gb_SrsTarget_set_include,dbp/res,\ $$(INCLUDE) \ - -I$(realpath $(SRCDIR)/extensions/inc) \ + -I$(SRCDIR)/extensions/inc \ )) $(eval $(call gb_SrsTarget_add_files,dbp/res,\ diff --git a/extensions/CppunitTest_extensions_test_update.mk b/extensions/CppunitTest_extensions_test_update.mk index f0b9a0567bc0..7ada5af2f06d 100644 --- a/extensions/CppunitTest_extensions_test_update.mk +++ b/extensions/CppunitTest_extensions_test_update.mk @@ -52,7 +52,7 @@ $(eval $(call gb_CppunitTest_use_external,extensions_test_update,curl)) $(eval $(call gb_CppunitTest_set_include,extensions_test_update,\ $$(INCLUDE) \ - -I$(realpath $(SRCDIR)/extensions/inc) \ + -I$(SRCDIR)/extensions/inc \ -I$(OUTDIR)/inc \ )) diff --git a/extensions/Library_abp.mk b/extensions/Library_abp.mk index 411c2d823ccf..8460cf81b066 100644 --- a/extensions/Library_abp.mk +++ b/extensions/Library_abp.mk @@ -34,8 +34,8 @@ $(eval $(call gb_Library_set_componentfile,abp,extensions/source/abpilot/abp)) $(eval $(call gb_Library_set_include,abp,\ $$(INCLUDE) \ - -I$(realpath $(SRCDIR)/extensions/inc) \ - -I$(realpath $(SRCDIR)/extensions/source/inc) \ + -I$(SRCDIR)/extensions/inc \ + -I$(SRCDIR)/extensions/source/inc \ )) ifneq ($(WITH_MOZILLA),NO) diff --git a/extensions/Library_bib.mk b/extensions/Library_bib.mk index 3a9c0107a568..27d311f306e4 100644 --- a/extensions/Library_bib.mk +++ b/extensions/Library_bib.mk @@ -34,7 +34,7 @@ $(eval $(call gb_Library_set_componentfile,bib,extensions/source/bibliography/bi $(eval $(call gb_Library_set_include,bib,\ $$(INCLUDE) \ - -I$(realpath $(SRCDIR)/extensions/inc) \ + -I$(SRCDIR)/extensions/inc \ )) $(eval $(call gb_Library_add_api,bib,\ diff --git a/extensions/Library_dbp.mk b/extensions/Library_dbp.mk index c7fd685cc3ce..dc7f55b5d907 100644 --- a/extensions/Library_dbp.mk +++ b/extensions/Library_dbp.mk @@ -34,8 +34,8 @@ $(eval $(call gb_Library_set_componentfile,dbp,extensions/source/dbpilots/dbp)) $(eval $(call gb_Library_set_include,dbp,\ $$(INCLUDE) \ - -I$(realpath $(SRCDIR)/extensions/inc) \ - -I$(realpath $(SRCDIR)/extensions/source/inc) \ + -I$(SRCDIR)/extensions/inc \ + -I$(SRCDIR)/extensions/source/inc \ )) $(eval $(call gb_Library_add_defs,dbp,\ diff --git a/extensions/Library_so_activex_x64.mk b/extensions/Library_so_activex_x64.mk index f7cfa0b2a257..43176723b406 100644 --- a/extensions/Library_so_activex_x64.mk +++ b/extensions/Library_so_activex_x64.mk @@ -36,7 +36,7 @@ $(SRCDIR)/extensions/source/activex/so_activex.cxx: $(WORKDIR)/CustomTarget/so_a $(eval $(call gb_Library_set_include,so_activex_x64,\ $$(INCLUDE) \ - -I$(realpath $(SRCDIR)/extensions/source/activex) \ + -I$(SRCDIR)/extensions/source/activex \ -I$(WORKDIR)/CustomTarget/so_activex \ $(foreach i,$(ATL_INCLUDE), -I$(i)) \ )) -- cgit From b882f15d4af447cafac43ae5357be596fd12f84e Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Mon, 19 Dec 2011 15:30:17 +0100 Subject: extensions: chmod a-x *.mk --- extensions/WinResTarget_npsoplugin.mk | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 extensions/WinResTarget_npsoplugin.mk diff --git a/extensions/WinResTarget_npsoplugin.mk b/extensions/WinResTarget_npsoplugin.mk old mode 100755 new mode 100644 -- cgit From a705718a7d95c8e1abc22fcc57ddb84e5b18aa0a Mon Sep 17 00:00:00 2001 From: Matúš Kukan Date: Mon, 19 Dec 2011 20:52:02 +0100 Subject: gbuild: register ws2_32 also for MSVC --- solenv/gbuild/platform/WNT_INTEL_MSC.mk | 1 + 1 file changed, 1 insertion(+) diff --git a/solenv/gbuild/platform/WNT_INTEL_MSC.mk b/solenv/gbuild/platform/WNT_INTEL_MSC.mk index 1e068ffe8ee4..de562a787bd6 100644 --- a/solenv/gbuild/platform/WNT_INTEL_MSC.mk +++ b/solenv/gbuild/platform/WNT_INTEL_MSC.mk @@ -426,6 +426,7 @@ gb_Library_PLAINLIBS_NONE += \ version \ winmm \ winspool \ + ws2_32 \ gb_Library_LAYER := \ $(foreach lib,$(gb_Library_OOOLIBS),$(lib):OOO) \ -- cgit From 4ee82ce8aeb36673301b631e94f80f725eecc362 Mon Sep 17 00:00:00 2001 From: Matúš Kukan Date: Mon, 19 Dec 2011 20:58:22 +0100 Subject: extensions: nsplugin: tweak linked libraries --- extensions/Executable_nsplugin.mk | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/extensions/Executable_nsplugin.mk b/extensions/Executable_nsplugin.mk index 6b97d46e470e..49b8761aacea 100644 --- a/extensions/Executable_nsplugin.mk +++ b/extensions/Executable_nsplugin.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # @@ -46,21 +46,15 @@ $(eval $(call gb_Executable_add_linked_libs,nsplugin,\ cppu \ cppuhelper \ sal \ + $(if $(filter $(GUI),UNX), \ + dl \ + ) \ + $(if $(filter $(OS),SOLARIS), \ + nsl \ + socket \ + ) \ )) -ifeq ($(OS),LINUX) -$(eval $(call gb_Executable_add_linked_libs,nsplugin,\ - dl \ -)) -endif - -ifeq ($(OS),SOLARIS) -$(eval $(call gb_Executable_add_libs,nsplugin,\ - -lsocket \ - -lnsl \ -)) -endif - ifeq ($(GUI),WNT) $(eval $(call gb_Executable_add_ldflags,nsplugin,\ $(OUTDIR)/lib/pathutils-obj.obj \ @@ -85,4 +79,4 @@ $(eval $(call gb_Executable_add_linked_libs,nsplugin,\ )) endif # WNT -# vim:set shiftwidth=4 softtabstop=4 expandtab: +# vim: set noet sw=4 ts=4: -- cgit From 6716631b35c9ceca9bbe3b5c31b9e5ae810b6920 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Mon, 19 Dec 2011 22:09:48 +0100 Subject: extensions: d'oh, i've pasted C++ emacs modelines in makefiles --- extensions/AllLangResTarget_abp.mk | 2 +- extensions/AllLangResTarget_bib.mk | 2 +- extensions/AllLangResTarget_dbp.mk | 2 +- extensions/AllLangResTarget_pcr.mk | 2 +- extensions/AllLangResTarget_san.mk | 2 +- extensions/AllLangResTarget_upd.mk | 2 +- extensions/AllLangResTarget_updchk.mk | 2 +- extensions/Configuration_updchk.mk | 2 +- extensions/CppunitTest_extensions_test_update.mk | 1 + extensions/Executable_nsplugin.mk | 2 +- extensions/Executable_pluginapp.bin.mk | 2 +- extensions/Library_OOoSpotlightImporter.mk | 2 +- extensions/Library_abp.mk | 2 +- extensions/Library_bib.mk | 2 +- extensions/Library_dbp.mk | 2 +- extensions/Library_ldapbe2.mk | 2 +- extensions/Library_log.mk | 2 +- extensions/Library_npsoplugin.mk | 2 +- extensions/Library_oleautobridge.mk | 2 +- extensions/Library_oleautobridge2.mk | 2 +- extensions/Library_pcr.mk | 2 +- extensions/Library_pl.mk | 2 +- extensions/Library_res.mk | 2 +- extensions/Library_scn.mk | 3 +-- extensions/Library_so_activex.mk | 2 +- extensions/Library_so_activex_x64.mk | 2 +- extensions/Library_updatecheckui.mk | 2 +- extensions/Library_updatefeed.mk | 2 +- extensions/Library_updchk.mk | 2 +- extensions/Library_xmx.mk | 2 +- extensions/Package_bib.mk | 2 +- extensions/Package_pcr.mk | 2 +- extensions/WinResTarget_activex.mk | 3 +++ extensions/WinResTarget_npsoplugin.mk | 2 +- extensions/Zip_mdibundle.mk | 2 +- 35 files changed, 37 insertions(+), 34 deletions(-) diff --git a/extensions/AllLangResTarget_abp.mk b/extensions/AllLangResTarget_abp.mk index cda588efb24d..7da6d415e6e3 100644 --- a/extensions/AllLangResTarget_abp.mk +++ b/extensions/AllLangResTarget_abp.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/AllLangResTarget_bib.mk b/extensions/AllLangResTarget_bib.mk index bcc5d1e10e8f..78b06773f8dc 100644 --- a/extensions/AllLangResTarget_bib.mk +++ b/extensions/AllLangResTarget_bib.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/AllLangResTarget_dbp.mk b/extensions/AllLangResTarget_dbp.mk index 88cc38992b4c..d4d4e3053736 100644 --- a/extensions/AllLangResTarget_dbp.mk +++ b/extensions/AllLangResTarget_dbp.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/AllLangResTarget_pcr.mk b/extensions/AllLangResTarget_pcr.mk index d091af1a7ecc..87ce2c6eaefe 100644 --- a/extensions/AllLangResTarget_pcr.mk +++ b/extensions/AllLangResTarget_pcr.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/AllLangResTarget_san.mk b/extensions/AllLangResTarget_san.mk index a866cc9020d3..2301f6cf7b55 100644 --- a/extensions/AllLangResTarget_san.mk +++ b/extensions/AllLangResTarget_san.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/AllLangResTarget_upd.mk b/extensions/AllLangResTarget_upd.mk index 872e49df0aab..7c1190fd7f5b 100644 --- a/extensions/AllLangResTarget_upd.mk +++ b/extensions/AllLangResTarget_upd.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/AllLangResTarget_updchk.mk b/extensions/AllLangResTarget_updchk.mk index c3cd02cb20a0..8f956a2a47dd 100644 --- a/extensions/AllLangResTarget_updchk.mk +++ b/extensions/AllLangResTarget_updchk.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Configuration_updchk.mk b/extensions/Configuration_updchk.mk index d6bcc07f3202..1b3cbd350022 100644 --- a/extensions/Configuration_updchk.mk +++ b/extensions/Configuration_updchk.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/CppunitTest_extensions_test_update.mk b/extensions/CppunitTest_extensions_test_update.mk index 7ada5af2f06d..a81b5856735e 100644 --- a/extensions/CppunitTest_extensions_test_update.mk +++ b/extensions/CppunitTest_extensions_test_update.mk @@ -1,3 +1,4 @@ +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Executable_nsplugin.mk b/extensions/Executable_nsplugin.mk index 49b8761aacea..e328a5ca8bf0 100644 --- a/extensions/Executable_nsplugin.mk +++ b/extensions/Executable_nsplugin.mk @@ -79,4 +79,4 @@ $(eval $(call gb_Executable_add_linked_libs,nsplugin,\ )) endif # WNT -# vim: set noet sw=4 ts=4: +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Executable_pluginapp.bin.mk b/extensions/Executable_pluginapp.bin.mk index b67d9e304a70..1c3b4fc2d6dc 100644 --- a/extensions/Executable_pluginapp.bin.mk +++ b/extensions/Executable_pluginapp.bin.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_OOoSpotlightImporter.mk b/extensions/Library_OOoSpotlightImporter.mk index 4a622331e3e6..639b381bea81 100644 --- a/extensions/Library_OOoSpotlightImporter.mk +++ b/extensions/Library_OOoSpotlightImporter.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_abp.mk b/extensions/Library_abp.mk index 8460cf81b066..8e69ebecb3dc 100644 --- a/extensions/Library_abp.mk +++ b/extensions/Library_abp.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_bib.mk b/extensions/Library_bib.mk index 27d311f306e4..dd09e0b1f87d 100644 --- a/extensions/Library_bib.mk +++ b/extensions/Library_bib.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_dbp.mk b/extensions/Library_dbp.mk index dc7f55b5d907..0bbe08635585 100644 --- a/extensions/Library_dbp.mk +++ b/extensions/Library_dbp.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_ldapbe2.mk b/extensions/Library_ldapbe2.mk index 87cb3ad99286..6f676196452c 100644 --- a/extensions/Library_ldapbe2.mk +++ b/extensions/Library_ldapbe2.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_log.mk b/extensions/Library_log.mk index fc7c2d349535..d12296e806e3 100644 --- a/extensions/Library_log.mk +++ b/extensions/Library_log.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_npsoplugin.mk b/extensions/Library_npsoplugin.mk index 954ba8655c92..f542f59445fd 100644 --- a/extensions/Library_npsoplugin.mk +++ b/extensions/Library_npsoplugin.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_oleautobridge.mk b/extensions/Library_oleautobridge.mk index 807c9e67480f..106daf838c59 100644 --- a/extensions/Library_oleautobridge.mk +++ b/extensions/Library_oleautobridge.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_oleautobridge2.mk b/extensions/Library_oleautobridge2.mk index 35db333b28c7..012b99a22251 100644 --- a/extensions/Library_oleautobridge2.mk +++ b/extensions/Library_oleautobridge2.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_pcr.mk b/extensions/Library_pcr.mk index 500d2560f8d5..9b4837ac0819 100644 --- a/extensions/Library_pcr.mk +++ b/extensions/Library_pcr.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_pl.mk b/extensions/Library_pl.mk index 8329ac8a5a09..6c07b0f1f7fd 100644 --- a/extensions/Library_pl.mk +++ b/extensions/Library_pl.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_res.mk b/extensions/Library_res.mk index 322197cbdbbf..1fc857aa798f 100644 --- a/extensions/Library_res.mk +++ b/extensions/Library_res.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_scn.mk b/extensions/Library_scn.mk index 6a165d553100..37184d420f61 100644 --- a/extensions/Library_scn.mk +++ b/extensions/Library_scn.mk @@ -1,5 +1,4 @@ - -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_so_activex.mk b/extensions/Library_so_activex.mk index f4d0d2f4f90e..292b7e130a90 100644 --- a/extensions/Library_so_activex.mk +++ b/extensions/Library_so_activex.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_so_activex_x64.mk b/extensions/Library_so_activex_x64.mk index 43176723b406..dfee1b85f833 100644 --- a/extensions/Library_so_activex_x64.mk +++ b/extensions/Library_so_activex_x64.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_updatecheckui.mk b/extensions/Library_updatecheckui.mk index 825142759352..c336738bce42 100644 --- a/extensions/Library_updatecheckui.mk +++ b/extensions/Library_updatecheckui.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_updatefeed.mk b/extensions/Library_updatefeed.mk index 01374b5f91fe..00a42c49b723 100644 --- a/extensions/Library_updatefeed.mk +++ b/extensions/Library_updatefeed.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_updchk.mk b/extensions/Library_updchk.mk index e78f1d0b26f6..a16f2a2e6160 100644 --- a/extensions/Library_updchk.mk +++ b/extensions/Library_updchk.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Library_xmx.mk b/extensions/Library_xmx.mk index 1d4ccd501362..dfef71dd21dd 100644 --- a/extensions/Library_xmx.mk +++ b/extensions/Library_xmx.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Package_bib.mk b/extensions/Package_bib.mk index 46b9c3c37818..5b7eb7769a7b 100644 --- a/extensions/Package_bib.mk +++ b/extensions/Package_bib.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Package_pcr.mk b/extensions/Package_pcr.mk index db0d91e549d4..48f46302e904 100644 --- a/extensions/Package_pcr.mk +++ b/extensions/Package_pcr.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/WinResTarget_activex.mk b/extensions/WinResTarget_activex.mk index 0487bc2f3cbc..fd7879cb6652 100644 --- a/extensions/WinResTarget_activex.mk +++ b/extensions/WinResTarget_activex.mk @@ -1,3 +1,4 @@ +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # @@ -44,3 +45,5 @@ $(eval $(call gb_WinResTarget_set_defs,activex_res,\ $$(DEFS) \ -DMISC=$(call gb_Helper_convert_native,$(WORKDIR)/CustomTarget/so_activex) \ )) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/WinResTarget_npsoplugin.mk b/extensions/WinResTarget_npsoplugin.mk index bba691713970..33926b34d64f 100644 --- a/extensions/WinResTarget_npsoplugin.mk +++ b/extensions/WinResTarget_npsoplugin.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # diff --git a/extensions/Zip_mdibundle.mk b/extensions/Zip_mdibundle.mk index b6ebf08ee021..0d1619fb791a 100644 --- a/extensions/Zip_mdibundle.mk +++ b/extensions/Zip_mdibundle.mk @@ -1,4 +1,4 @@ -# -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- # # Version: MPL 1.1 / GPLv3+ / LGPLv3+ # -- cgit From 7d4acd97fa55032a9c6ecb4d8eb6d999d4336c2e Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 16:49:28 -0500 Subject: add svx to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 30c9e0363941..48740a42e581 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -54,6 +54,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ sd \ slideshow \ starmath \ + svx \ sw \ swext \ unoxml \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index c32aef296083..39d52a75bd55 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib avmedia basegfx basic bridges canvas comphelper connectivity cppcanvas cppu cppuhelper DESKTOP:fpicker javaunohelper jurt jvmaccess np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax sfx2 solenv soltools sot stoc svl svtools svx sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib avmedia basegfx basic bridges canvas comphelper connectivity cppcanvas cppu cppuhelper drawinglayer editeng DESKTOP:fpicker javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax sfx2 solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From 4d053e9b8014ad13b140edc3c1aaca9ed7ec98ec Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 16:53:06 -0500 Subject: add drawinglayer to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 48740a42e581..d0e145829c03 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -32,6 +32,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ cui \ dbaccess \ desktop \ + drawinglayer \ eventattacher \ extensions \ fileaccess \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index 39d52a75bd55..291035ccbdbe 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib avmedia basegfx basic bridges canvas comphelper connectivity cppcanvas cppu cppuhelper drawinglayer editeng DESKTOP:fpicker javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax sfx2 solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib avmedia basegfx basic bridges canvas comphelper connectivity cppcanvas cppu cppuhelper editeng DESKTOP:fpicker javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax sfx2 solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From 34e0cda7f8b2c6cf61871e72ab7948944216993c Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:09:19 -0500 Subject: add avmedia to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index d0e145829c03..145c0088e656 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -26,6 +26,7 @@ $(eval $(call gb_Module_Module,tail_end)) $(eval $(call gb_Module_add_moduledirs,tail_end,\ animations \ + avmedia \ basctl \ bean \ chart2 \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index 291035ccbdbe..05c56e08834b 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib avmedia basegfx basic bridges canvas comphelper connectivity cppcanvas cppu cppuhelper editeng DESKTOP:fpicker javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax sfx2 solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges canvas comphelper connectivity cppcanvas cppu cppuhelper editeng DESKTOP:fpicker javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax sfx2 solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From e3d8b007042b541b714b25be5a0b835fd0ce24ea Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:15:07 -0500 Subject: add sfx2 to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 145c0088e656..0a67eb8cbb45 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -54,6 +54,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ sccomp \ scripting \ sd \ + sfx2 \ slideshow \ starmath \ svx \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index 05c56e08834b..ab5777b41a75 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges canvas comphelper connectivity cppcanvas cppu cppuhelper editeng DESKTOP:fpicker javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax sfx2 solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NATIVE:idl NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges canvas comphelper connectivity cppcanvas cppu cppuhelper editeng DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From 118aa11cd70c0201e714ac35f408d849abd46858 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:18:06 -0500 Subject: add cppcanvas to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 0a67eb8cbb45..50651e917b64 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -30,6 +30,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ basctl \ bean \ chart2 \ + cppcanvas \ cui \ dbaccess \ desktop \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index ab5777b41a75..76a67339ef28 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NATIVE:idl NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges canvas comphelper connectivity cppcanvas cppu cppuhelper editeng DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NATIVE:idl NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges canvas comphelper connectivity cppu cppuhelper editeng DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From 37fbc0a00982be908f7b5ea5e7151a48043df9df Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:21:39 -0500 Subject: add scaddins to tail_build --- Module_tail_build.mk | 1 + postprocess/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 50651e917b64..d50c4187fa8c 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -52,6 +52,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ padmin \ reportdesign \ sc \ + scaddins \ sccomp \ scripting \ sd \ diff --git a/postprocess/prj/build.lst b/postprocess/prj/build.lst index af13689d64e0..d188780f8b00 100644 --- a/postprocess/prj/build.lst +++ b/postprocess/prj/build.lst @@ -1,4 +1,4 @@ -po postprocess :: accessibility BINFILTER:binfilter configmgr CRASHREP:crashrep CT2N:ct2n dtrans embeddedobj embedserv EPM:epm extras DESKTOP:fpicker HELP:helpcontent2 io LIBRSVG:librsvg ODK:odk officecfg psprint_config remotebridges scaddins scp2 DESKTOP:setup_native sysui testtools ucb UnoControls ure wizards MORE_FONTS:more_fonts DICTIONARIES:dictionaries PYUNO:pyuno readlicense_oo DESKTOP:unodevtools JFREEREPORT:jfreereport REPORTBUILDER:reportbuilder LANGUAGETOOL:languagetool SDEXT:sdext MYSQLC:mysqlc NLPSOLVER:nlpsolver STLPORT:stlport LIBXSLT:libxslt smoketest tail_build NULL +po postprocess :: accessibility BINFILTER:binfilter configmgr CRASHREP:crashrep CT2N:ct2n dtrans embeddedobj embedserv EPM:epm extras DESKTOP:fpicker HELP:helpcontent2 io LIBRSVG:librsvg ODK:odk officecfg psprint_config remotebridges scp2 DESKTOP:setup_native sysui testtools ucb UnoControls ure wizards MORE_FONTS:more_fonts DICTIONARIES:dictionaries PYUNO:pyuno readlicense_oo DESKTOP:unodevtools JFREEREPORT:jfreereport REPORTBUILDER:reportbuilder LANGUAGETOOL:languagetool SDEXT:sdext MYSQLC:mysqlc NLPSOLVER:nlpsolver STLPORT:stlport LIBXSLT:libxslt smoketest tail_build NULL po postprocess usr1 - all po_mkout NULL po postprocess\checkxml nmake - all po_checkxml NULL po postprocess\packconfig nmake - all po_packconfig po_checkxml NULL -- cgit From 36b0431d37755ca2c55384998d56dcd294833644 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:26:42 -0500 Subject: add canvas to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index d50c4187fa8c..2fb304feda29 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -29,6 +29,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ avmedia \ basctl \ bean \ + canvas \ chart2 \ cppcanvas \ cui \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index 76a67339ef28..c4e5ca69e20c 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NATIVE:idl NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges canvas comphelper connectivity cppu cppuhelper editeng DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NATIVE:idl NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges comphelper connectivity cppu cppuhelper editeng DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From 529653fe4708b27006377ca6cc1f4a09d5138cb6 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:28:25 -0500 Subject: add editeng to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 2fb304feda29..f796905c45e6 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -36,6 +36,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ dbaccess \ desktop \ drawinglayer \ + editeng \ eventattacher \ extensions \ fileaccess \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index c4e5ca69e20c..f0ec491c73e2 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NATIVE:idl NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges comphelper connectivity cppu cppuhelper editeng DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NATIVE:idl NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From 457ec785870856f4dd284e3ca7d38bd8ac3c927d Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:36:35 -0500 Subject: add xmloff to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index f796905c45e6..155883017fa5 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -71,6 +71,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ writerfilter \ writerperfect \ xmerge \ + xmloff \ xmlsecurity \ )) diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index f0ec491c73e2..5fcaf4695da9 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NATIVE:idl NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk linguistic np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmloff xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NATIVE:idl NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From e12f8d4a632cf2d63e5e918e1c7549f70faeed51 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:40:01 -0500 Subject: add dtrans to tail_build --- Module_tail_build.mk | 1 + postprocess/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 155883017fa5..9344cf66caa9 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -35,6 +35,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ cui \ dbaccess \ desktop \ + dtrans \ drawinglayer \ editeng \ eventattacher \ diff --git a/postprocess/prj/build.lst b/postprocess/prj/build.lst index d188780f8b00..92dff0cdd208 100644 --- a/postprocess/prj/build.lst +++ b/postprocess/prj/build.lst @@ -1,4 +1,4 @@ -po postprocess :: accessibility BINFILTER:binfilter configmgr CRASHREP:crashrep CT2N:ct2n dtrans embeddedobj embedserv EPM:epm extras DESKTOP:fpicker HELP:helpcontent2 io LIBRSVG:librsvg ODK:odk officecfg psprint_config remotebridges scp2 DESKTOP:setup_native sysui testtools ucb UnoControls ure wizards MORE_FONTS:more_fonts DICTIONARIES:dictionaries PYUNO:pyuno readlicense_oo DESKTOP:unodevtools JFREEREPORT:jfreereport REPORTBUILDER:reportbuilder LANGUAGETOOL:languagetool SDEXT:sdext MYSQLC:mysqlc NLPSOLVER:nlpsolver STLPORT:stlport LIBXSLT:libxslt smoketest tail_build NULL +po postprocess :: accessibility BINFILTER:binfilter configmgr CRASHREP:crashrep CT2N:ct2n embeddedobj embedserv EPM:epm extras DESKTOP:fpicker HELP:helpcontent2 io LIBRSVG:librsvg ODK:odk officecfg psprint_config remotebridges scp2 DESKTOP:setup_native sysui testtools ucb UnoControls ure wizards MORE_FONTS:more_fonts DICTIONARIES:dictionaries PYUNO:pyuno readlicense_oo DESKTOP:unodevtools JFREEREPORT:jfreereport REPORTBUILDER:reportbuilder LANGUAGETOOL:languagetool SDEXT:sdext MYSQLC:mysqlc NLPSOLVER:nlpsolver STLPORT:stlport LIBXSLT:libxslt smoketest tail_build NULL po postprocess usr1 - all po_mkout NULL po postprocess\checkxml nmake - all po_checkxml NULL po postprocess\packconfig nmake - all po_packconfig po_checkxml NULL -- cgit From c20b8e269b94fcf0b2ecbc817dabcc6eec488593 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Sat, 17 Dec 2011 18:43:20 -0500 Subject: add idl to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 9344cf66caa9..ef026fd29c92 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -45,6 +45,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ forms \ formula \ hwpfilter \ + idl \ lingucomponent \ linguistic \ lotuswordpro \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index 5fcaf4695da9..5c4e3b84867c 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NATIVE:idl NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From c44cc4d1312fcc180cb3c5df0062aabb44625ded Mon Sep 17 00:00:00 2001 From: Matúš Kukan Date: Tue, 20 Dec 2011 19:33:07 +0100 Subject: reportdesign: remove unnecessary includes from svx --- reportdesign/source/ui/dlg/CondFormat.cxx | 3 --- reportdesign/source/ui/dlg/DateTime.cxx | 2 -- reportdesign/source/ui/dlg/GroupsSorting.cxx | 6 +----- reportdesign/source/ui/dlg/Navigator.cxx | 2 -- reportdesign/source/ui/dlg/PageNumber.cxx | 2 -- 5 files changed, 1 insertion(+), 14 deletions(-) diff --git a/reportdesign/source/ui/dlg/CondFormat.cxx b/reportdesign/source/ui/dlg/CondFormat.cxx index 9fd7e79bc671..6078904eab5b 100644 --- a/reportdesign/source/ui/dlg/CondFormat.cxx +++ b/reportdesign/source/ui/dlg/CondFormat.cxx @@ -44,9 +44,6 @@ #include /** === end UNO includes === **/ -#include -#include - #include #include diff --git a/reportdesign/source/ui/dlg/DateTime.cxx b/reportdesign/source/ui/dlg/DateTime.cxx index 563d24f356ef..e197c661e4ac 100644 --- a/reportdesign/source/ui/dlg/DateTime.cxx +++ b/reportdesign/source/ui/dlg/DateTime.cxx @@ -34,8 +34,6 @@ #include "ModuleHelper.hxx" #include "helpids.hrc" #include -#include -#include #include #include #include "UITools.hxx" diff --git a/reportdesign/source/ui/dlg/GroupsSorting.cxx b/reportdesign/source/ui/dlg/GroupsSorting.cxx index 2c6f10f1c06f..b3bf2ac0f048 100644 --- a/reportdesign/source/ui/dlg/GroupsSorting.cxx +++ b/reportdesign/source/ui/dlg/GroupsSorting.cxx @@ -29,6 +29,7 @@ #include "GroupsSorting.hrc" #include #include +#include #include #include #include @@ -40,11 +41,6 @@ #include "rptui_slotid.hrc" #include "ModuleHelper.hxx" #include "helpids.hrc" - -#include -#include -#include - #include "GroupExchange.hxx" #include "UITools.hxx" #include "UndoActions.hxx" diff --git a/reportdesign/source/ui/dlg/Navigator.cxx b/reportdesign/source/ui/dlg/Navigator.cxx index 98272cd03380..37a7734266dd 100644 --- a/reportdesign/source/ui/dlg/Navigator.cxx +++ b/reportdesign/source/ui/dlg/Navigator.cxx @@ -40,8 +40,6 @@ #include #include #include -#include -#include #include "helpids.hrc" #include "RptResId.hrc" #include "rptui_slotid.hrc" diff --git a/reportdesign/source/ui/dlg/PageNumber.cxx b/reportdesign/source/ui/dlg/PageNumber.cxx index 7b6b077d6d07..cfc3ef7cb0b2 100644 --- a/reportdesign/source/ui/dlg/PageNumber.cxx +++ b/reportdesign/source/ui/dlg/PageNumber.cxx @@ -35,8 +35,6 @@ #include "RptDef.hxx" #include "helpids.hrc" #include -#include -#include #include "UITools.hxx" #include "uistrings.hrc" #include "ReportController.hxx" -- cgit From 1db544cc34dd74ba3dd70f46d56c376b177dcd0c Mon Sep 17 00:00:00 2001 From: Matúš Kukan Date: Tue, 20 Dec 2011 19:35:11 +0100 Subject: svx: add globlmn.hrc as target from OUTDIR for other modules to depend on --- svx/AllLangResTarget_svx.mk | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/svx/AllLangResTarget_svx.mk b/svx/AllLangResTarget_svx.mk index d030b534baf3..f2c9f856c27f 100644 --- a/svx/AllLangResTarget_svx.mk +++ b/svx/AllLangResTarget_svx.mk @@ -98,14 +98,17 @@ $(eval $(call gb_SrsTarget_add_files,svx/res,\ svx/source/unodraw/unodraw.src \ )) -$(call gb_SrsPartTarget_get_target,svx/source/fmcomp/gridctrl.src) : $(WORKDIR)/inc/svx/globlmn.hrc -$(call gb_SrsPartTarget_get_target,svx/source/form/fmexpl.src) : $(WORKDIR)/inc/svx/globlmn.hrc -$(call gb_SrsPartTarget_get_target,svx/source/form/datanavi.src) : $(WORKDIR)/inc/svx/globlmn.hrc -$(call gb_SrsPartTarget_get_target,svx/source/form/formshell.src) : $(WORKDIR)/inc/svx/globlmn.hrc -$(call gb_SrsTarget_get_clean_target,svx/res) : $(WORKDIR)/inc/svx/globlmn.hrc_clean +$(call gb_SrsPartTarget_get_target,svx/source/fmcomp/gridctrl.src) : $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsPartTarget_get_target,svx/source/form/fmexpl.src) : $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsPartTarget_get_target,svx/source/form/datanavi.src) : $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsPartTarget_get_target,svx/source/form/formshell.src) : $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsTarget_get_clean_target,svx/res) : $(OUTDIR)/inc/svx/globlmn.hrc_clean # hack !!! # just a temporary - globlmn.hrc about to be removed! + +$(OUTDIR)/inc/svx/globlmn.hrc: $(WORKDIR)/inc/svx/globlmn.hrc + ifeq ($(strip $(WITH_LANG)),) $(WORKDIR)/inc/svx/globlmn.hrc : $(realpath $(SRCDIR)/svx/inc/globlmn_tmpl.hrc) echo copying $@ @@ -130,10 +133,11 @@ $(WORKDIR)/inc/svx/globlmn.hrc : $(realpath $(SRCDIR)/svx/inc/globlmn_tmpl.hrc) $(call gb_Deliver_deliver, $@, $(OUTDIR)/inc/svx/globlmn.hrc) endif -.PHONY : $(WORKDIR)/inc/svx/globlmn.hrc_clean -$(WORKDIR)/inc/svx/globlmn.hrc_clean : +.PHONY : $(OUTDIR)/inc/svx/globlmn.hrc_clean +$(OUTDIR)/inc/svx/globlmn.hrc_clean : rm -f $(WORKDIR)/inc/svx/lastrun.mk \ - $(WORKDIR)/inc/svx/globlmn.hrc + $(WORKDIR)/inc/svx/globlmn.hrc \ + $(OUTDIR)/inc/svx/globlmn.hrc \ # vim: set noet sw=4 ts=4: -- cgit From 032df7e9bfafeb93925959626b79eeee3cec17a4 Mon Sep 17 00:00:00 2001 From: Matúš Kukan Date: Tue, 20 Dec 2011 19:38:30 +0100 Subject: gbuild: these targets depend on svx/globlmn.hrc --- basctl/AllLangResTarget_basctl.mk | 2 ++ reportdesign/AllLangResTarget_rpt.mk | 2 ++ reportdesign/AllLangResTarget_rptui.mk | 2 ++ sc/AllLangResTarget_sc.mk | 2 ++ sd/AllLangResTarget_sd.mk | 2 ++ starmath/AllLangResTarget_sm.mk | 2 ++ sw/AllLangResTarget_sw.mk | 2 ++ 7 files changed, 14 insertions(+) diff --git a/basctl/AllLangResTarget_basctl.mk b/basctl/AllLangResTarget_basctl.mk index 1611f9a506e2..7e588d199e50 100644 --- a/basctl/AllLangResTarget_basctl.mk +++ b/basctl/AllLangResTarget_basctl.mk @@ -54,4 +54,6 @@ $(eval $(call gb_SrsTarget_add_files,basctl/res,\ basctl/source/dlged/managelang.src \ )) +$(call gb_SrsTarget_get_target,basctl/res) :| $(OUTDIR)/inc/svx/globlmn.hrc + # vim: set noet sw=4 ts=4: diff --git a/reportdesign/AllLangResTarget_rpt.mk b/reportdesign/AllLangResTarget_rpt.mk index 55aeeb0d9e9a..76baa19770df 100644 --- a/reportdesign/AllLangResTarget_rpt.mk +++ b/reportdesign/AllLangResTarget_rpt.mk @@ -45,4 +45,6 @@ $(eval $(call gb_SrsTarget_add_files,reportdesign/res,\ reportdesign/source/core/resource/strings.src \ )) +$(call gb_SrsTarget_get_target,reportdesign/res) :| $(OUTDIR)/inc/svx/globlmn.hrc + # vim: set noet sw=4 ts=4: diff --git a/reportdesign/AllLangResTarget_rptui.mk b/reportdesign/AllLangResTarget_rptui.mk index c41b5b8fdee2..23edf347feb2 100644 --- a/reportdesign/AllLangResTarget_rptui.mk +++ b/reportdesign/AllLangResTarget_rptui.mk @@ -54,4 +54,6 @@ $(eval $(call gb_SrsTarget_add_files,reportdesign/rptui,\ reportdesign/source/ui/report/report.src \ )) +$(call gb_SrsTarget_get_target,reportdesign/rptui) :| $(OUTDIR)/inc/svx/globlmn.hrc + # vim: set noet sw=4 ts=4: diff --git a/sc/AllLangResTarget_sc.mk b/sc/AllLangResTarget_sc.mk index 22f3c76278e4..ce5915b3f919 100644 --- a/sc/AllLangResTarget_sc.mk +++ b/sc/AllLangResTarget_sc.mk @@ -105,4 +105,6 @@ $(eval $(call gb_SrsTarget_add_files,sc/res,\ sc/source/core/src/compiler.src \ )) +$(call gb_SrsTarget_get_target,sc/res) :| $(OUTDIR)/inc/svx/globlmn.hrc + # vim: set noet sw=4 ts=4: diff --git a/sd/AllLangResTarget_sd.mk b/sd/AllLangResTarget_sd.mk index 64f8f3cd0d0e..25eab89e4bc5 100644 --- a/sd/AllLangResTarget_sd.mk +++ b/sd/AllLangResTarget_sd.mk @@ -107,4 +107,6 @@ $(eval $(call gb_SrsTarget_add_templates,sd/res,\ sd/source/ui/app/toolbox2_tmpl.src \ )) +$(call gb_SrsTarget_get_target,sd/res) :| $(OUTDIR)/inc/svx/globlmn.hrc + # vim: set noet sw=4 ts=4: diff --git a/starmath/AllLangResTarget_sm.mk b/starmath/AllLangResTarget_sm.mk index c4089add0c87..a1f31a4d11a8 100644 --- a/starmath/AllLangResTarget_sm.mk +++ b/starmath/AllLangResTarget_sm.mk @@ -48,4 +48,6 @@ $(eval $(call gb_SrsTarget_add_files,sm/res,\ starmath/source/toolbox.src \ )) +$(call gb_SrsTarget_get_target,sm/res) :| $(OUTDIR)/inc/svx/globlmn.hrc + # vim: set noet sw=4 ts=4: diff --git a/sw/AllLangResTarget_sw.mk b/sw/AllLangResTarget_sw.mk index cd5a4bc8af4b..43386be25fbf 100644 --- a/sw/AllLangResTarget_sw.mk +++ b/sw/AllLangResTarget_sw.mk @@ -188,4 +188,6 @@ $(eval $(call gb_SrsTarget_add_files,sw/res,\ sw/source/ui/wrtsh/wrtsh.src \ )) +$(call gb_SrsTarget_get_target,sw/res) :| $(OUTDIR)/inc/svx/globlmn.hrc + # vim: set noet sw=4 ts=4: -- cgit From a029a486868d936d5d4609f6c5b9875406f83536 Mon Sep 17 00:00:00 2001 From: Matúš Kukan Date: Tue, 20 Dec 2011 20:01:23 +0100 Subject: add basic to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index ef026fd29c92..764b9fc2de8c 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -28,6 +28,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ animations \ avmedia \ basctl \ + basic \ bean \ canvas \ chart2 \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index 5c4e3b84867c..87ca96dd7a1c 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx basic bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal salhelper sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From 166f974c858546330fd98bd38e09c9cbfa124d82 Mon Sep 17 00:00:00 2001 From: Matúš Kukan Date: Wed, 21 Dec 2011 10:48:29 +0100 Subject: extensions: bin unused files --- extensions/inc/appsettings.hxx | 45 --- .../source/unoactivex/main/initwindowpeer.cxx | 87 ----- extensions/util/hidother.src | 428 --------------------- 3 files changed, 560 deletions(-) delete mode 100644 extensions/inc/appsettings.hxx delete mode 100644 extensions/source/unoactivex/main/initwindowpeer.cxx delete mode 100644 extensions/util/hidother.src diff --git a/extensions/inc/appsettings.hxx b/extensions/inc/appsettings.hxx deleted file mode 100644 index 8622db0bd77e..000000000000 --- a/extensions/inc/appsettings.hxx +++ /dev/null @@ -1,45 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ -#ifndef _APPSETTINGS_HXX -#define _APPSETTINGS_HXX - -#include - -#ifdef __cplusplus -extern "C" { -#endif - -XNameContainer* getApplicationSettings(); - -#ifdef __cplusplus -} -#endif - -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/unoactivex/main/initwindowpeer.cxx b/extensions/source/unoactivex/main/initwindowpeer.cxx deleted file mode 100644 index f2ae4cc713a2..000000000000 --- a/extensions/source/unoactivex/main/initwindowpeer.cxx +++ /dev/null @@ -1,87 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - - - -#include "initwindowpeer.hxx" - -using namespace ::com::sun::star; - - -uno::Any SAL_CALL InitWindowPeer::getWindowHandle( const uno::Sequence< sal_Int8 >& ProcessId, sal_Int16 SystemType ) - throw ( uno::RuntimeException ) -{ - uno::Any aRes; - sal_Int32 nHwnd = (sal_Int32)m_hwnd; - aRes <<= nHwnd; - return aRes; -} - - -uno::Reference< awt::XToolkit > SAL_CALL InitWindowPeer::getToolkit() - throw ( uno::RuntimeException ) -{ - return uno::Reference< awt::XToolkit >(); -} - -void SAL_CALL InitWindowPeer::setPointer( const uno::Reference< awt::XPointer >& Pointer ) - throw ( uno::RuntimeException ) -{ -} - -void SAL_CALL InitWindowPeer::setBackground( sal_Int32 Color ) - throw ( uno::RuntimeException ) -{ -} - -void SAL_CALL InitWindowPeer::invalidate( sal_Int16 Flags ) - throw ( uno::RuntimeException ) -{ -} - -void SAL_CALL InitWindowPeer::invalidateRect( const awt::Rectangle& Rect, sal_Int16 Flags ) - throw ( uno::RuntimeException ) -{ -} - -void SAL_CALL InitWindowPeer::dispose() - throw ( uno::RuntimeException ) -{ -} - -void SAL_CALL InitWindowPeer::addEventListener( const uno::Reference< lang::XEventListener >& xListener ) - throw ( uno::RuntimeException ) -{ -} - -void SAL_CALL InitWindowPeer::removeEventListener( const uno::Reference< lang::XEventListener >& aListener ) - throw ( uno::RuntimeException ) -{ -} - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/util/hidother.src b/extensions/util/hidother.src deleted file mode 100644 index cfe1db5de2a0..000000000000 --- a/extensions/util/hidother.src +++ /dev/null @@ -1,428 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -#include "../inc/abpilot.hrc" -#include "../inc/bibliography.hrc" -#include "../inc/dbpilots.hrc" -#include "../inc/propctrlr.hrc" -#include "../inc/update.hrc" - -hidspecial HID_ABSPILOT { HelpId = HID_ABSPILOT; } -hidspecial HID_ABSPILOT_CANCEL { HelpId = HID_ABSPILOT_CANCEL; } -hidspecial HID_ABSPILOT_FINISH { HelpId = HID_ABSPILOT_FINISH; } -hidspecial HID_ABSPILOT_NEXT { HelpId = HID_ABSPILOT_NEXT; } -hidspecial HID_ABSPILOT_PREVIOUS { HelpId = HID_ABSPILOT_PREVIOUS; } - -hidspecial HID_BIB_ADDRESS_POS { HelpId = HID_BIB_ADDRESS_POS; } -hidspecial HID_BIB_ANNOTE_POS { HelpId = HID_BIB_ANNOTE_POS; } -hidspecial HID_BIB_AUTHORITYTYPE_POS { HelpId = HID_BIB_AUTHORITYTYPE_POS; } -hidspecial HID_BIB_AUTHOR_POS { HelpId = HID_BIB_AUTHOR_POS; } -hidspecial HID_BIB_BOOKTITLE_POS { HelpId = HID_BIB_BOOKTITLE_POS; } -hidspecial HID_BIB_CHANGESOURCE { HelpId = HID_BIB_CHANGESOURCE; } -hidspecial HID_BIB_CHAPTER_POS { HelpId = HID_BIB_CHAPTER_POS; } -hidspecial HID_BIB_CONTROL_PAGE { HelpId = HID_BIB_CONTROL_PAGE; } -hidspecial HID_BIB_CONTROL_PARENT { HelpId = HID_BIB_CONTROL_PARENT; } -hidspecial HID_BIB_CUSTOM1_POS { HelpId = HID_BIB_CUSTOM1_POS; } -hidspecial HID_BIB_CUSTOM2_POS { HelpId = HID_BIB_CUSTOM2_POS; } -hidspecial HID_BIB_CUSTOM3_POS { HelpId = HID_BIB_CUSTOM3_POS; } -hidspecial HID_BIB_CUSTOM4_POS { HelpId = HID_BIB_CUSTOM4_POS; } -hidspecial HID_BIB_CUSTOM5_POS { HelpId = HID_BIB_CUSTOM5_POS; } -hidspecial HID_BIB_DB_GRIDCTRL { HelpId = HID_BIB_DB_GRIDCTRL; } -hidspecial HID_BIB_DB_TBX { HelpId = HID_BIB_DB_TBX; } -hidspecial HID_BIB_DELETE_RECORD { HelpId = HID_BIB_DELETE_RECORD; } -hidspecial HID_BIB_EDITION_POS { HelpId = HID_BIB_EDITION_POS; } -hidspecial HID_BIB_EDITOR_POS { HelpId = HID_BIB_EDITOR_POS; } -hidspecial HID_BIB_HOWPUBLISHED_POS { HelpId = HID_BIB_HOWPUBLISHED_POS; } -hidspecial HID_BIB_IDENTIFIER_POS { HelpId = HID_BIB_IDENTIFIER_POS; } -hidspecial HID_BIB_INSERT_RECORD { HelpId = HID_BIB_INSERT_RECORD; } -hidspecial HID_BIB_INSTITUTION_POS { HelpId = HID_BIB_INSTITUTION_POS; } -hidspecial HID_BIB_ISBN_POS { HelpId = HID_BIB_ISBN_POS; } -hidspecial HID_BIB_JOURNAL_POS { HelpId = HID_BIB_JOURNAL_POS; } -hidspecial HID_BIB_MAPPINGDLG { HelpId = HID_BIB_MAPPINGDLG; } -hidspecial HID_BIB_MONTH_POS { HelpId = HID_BIB_MONTH_POS; } -hidspecial HID_BIB_NOTE_POS { HelpId = HID_BIB_NOTE_POS; } -hidspecial HID_BIB_NUMBER_POS { HelpId = HID_BIB_NUMBER_POS; } -hidspecial HID_BIB_ORGANIZATIONS_POS { HelpId = HID_BIB_ORGANIZATIONS_POS; } -hidspecial HID_BIB_PAGES_POS { HelpId = HID_BIB_PAGES_POS; } -hidspecial HID_BIB_PUBLISHER_POS { HelpId = HID_BIB_PUBLISHER_POS; } -hidspecial HID_BIB_REPORTTYPE_POS { HelpId = HID_BIB_REPORTTYPE_POS; } -hidspecial HID_BIB_SCHOOL_POS { HelpId = HID_BIB_SCHOOL_POS; } -hidspecial HID_BIB_SERIES_POS { HelpId = HID_BIB_SERIES_POS; } -hidspecial HID_BIB_TBX_AUTOFILTER { HelpId = HID_BIB_TBX_AUTOFILTER; } -hidspecial HID_BIB_TBX_SEARCH { HelpId = HID_BIB_TBX_SEARCH; } -hidspecial HID_BIB_TBX_TABLE { HelpId = HID_BIB_TBX_TABLE; } -hidspecial HID_BIB_TITLE_POS { HelpId = HID_BIB_TITLE_POS; } -hidspecial HID_BIB_URL_POS { HelpId = HID_BIB_URL_POS; } -hidspecial HID_BIB_VOLUME_POS { HelpId = HID_BIB_VOLUME_POS; } -hidspecial HID_BIB_YEAR_POS { HelpId = HID_BIB_YEAR_POS; } - -hidspecial HID_CHECK_FOR_UPD_CANCEL { HelpId = HID_CHECK_FOR_UPD_CANCEL; } -hidspecial HID_CHECK_FOR_UPD_CLOSE { HelpId = HID_CHECK_FOR_UPD_CLOSE; } -hidspecial HID_CHECK_FOR_UPD_DESCRIPTION { HelpId = HID_CHECK_FOR_UPD_DESCRIPTION; } -hidspecial HID_CHECK_FOR_UPD_DLG { HelpId = HID_CHECK_FOR_UPD_DLG; } -hidspecial HID_CHECK_FOR_UPD_DOWNLOAD { HelpId = HID_CHECK_FOR_UPD_DOWNLOAD; } -hidspecial HID_CHECK_FOR_UPD_DOWNLOAD2 { HelpId = HID_CHECK_FOR_UPD_DOWNLOAD2; } -hidspecial HID_CHECK_FOR_UPD_INSTALL { HelpId = HID_CHECK_FOR_UPD_INSTALL; } -hidspecial HID_CHECK_FOR_UPD_PAUSE { HelpId = HID_CHECK_FOR_UPD_PAUSE; } -hidspecial HID_CHECK_FOR_UPD_RESUME { HelpId = HID_CHECK_FOR_UPD_RESUME; } -hidspecial HID_CHECK_FOR_UPD_STATUS { HelpId = HID_CHECK_FOR_UPD_STATUS; } - -hidspecial HID_DLG_DBCHANGE { HelpId = HID_DLG_DBCHANGE; } -hidspecial HID_DLG_MAPPING { HelpId = HID_DLG_MAPPING; } - -hidspecial HID_EVT_ACTIONPERFORMED { HelpId = HID_EVT_ACTIONPERFORMED; } -hidspecial HID_EVT_ADJUSTMENTVALUECHANGED { HelpId = HID_EVT_ADJUSTMENTVALUECHANGED; } -hidspecial HID_EVT_AFTERUPDATE { HelpId = HID_EVT_AFTERUPDATE; } -hidspecial HID_EVT_APPROVEACTIONPERFORMED { HelpId = HID_EVT_APPROVEACTIONPERFORMED; } -hidspecial HID_EVT_APPROVEPARAMETER { HelpId = HID_EVT_APPROVEPARAMETER; } -hidspecial HID_EVT_APPROVERESETTED { HelpId = HID_EVT_APPROVERESETTED; } -hidspecial HID_EVT_APPROVEROWCHANGE { HelpId = HID_EVT_APPROVEROWCHANGE; } -hidspecial HID_EVT_BEFOREUPDATE { HelpId = HID_EVT_BEFOREUPDATE; } -hidspecial HID_EVT_CHANGED { HelpId = HID_EVT_CHANGED; } -hidspecial HID_EVT_CONFIRMDELETE { HelpId = HID_EVT_CONFIRMDELETE; } -hidspecial HID_EVT_ERROROCCURRED { HelpId = HID_EVT_ERROROCCURRED; } -hidspecial HID_EVT_FOCUSGAINED { HelpId = HID_EVT_FOCUSGAINED; } -hidspecial HID_EVT_FOCUSLOST { HelpId = HID_EVT_FOCUSLOST; } -hidspecial HID_EVT_ITEMSTATECHANGED { HelpId = HID_EVT_ITEMSTATECHANGED; } -hidspecial HID_EVT_KEYTYPED { HelpId = HID_EVT_KEYTYPED; } -hidspecial HID_EVT_KEYUP { HelpId = HID_EVT_KEYUP; } -hidspecial HID_EVT_LOADED { HelpId = HID_EVT_LOADED; } -hidspecial HID_EVT_MOUSEDRAGGED { HelpId = HID_EVT_MOUSEDRAGGED; } -hidspecial HID_EVT_MOUSEENTERED { HelpId = HID_EVT_MOUSEENTERED; } -hidspecial HID_EVT_MOUSEEXITED { HelpId = HID_EVT_MOUSEEXITED; } -hidspecial HID_EVT_MOUSEMOVED { HelpId = HID_EVT_MOUSEMOVED; } -hidspecial HID_EVT_MOUSEPRESSED { HelpId = HID_EVT_MOUSEPRESSED; } -hidspecial HID_EVT_MOUSERELEASED { HelpId = HID_EVT_MOUSERELEASED; } -hidspecial HID_EVT_POSITIONED { HelpId = HID_EVT_POSITIONED; } -hidspecial HID_EVT_POSITIONING { HelpId = HID_EVT_POSITIONING; } -hidspecial HID_EVT_RELOADED { HelpId = HID_EVT_RELOADED; } -hidspecial HID_EVT_RELOADING { HelpId = HID_EVT_RELOADING; } -hidspecial HID_EVT_RESETTED { HelpId = HID_EVT_RESETTED; } -hidspecial HID_EVT_ROWCHANGE { HelpId = HID_EVT_ROWCHANGE; } -hidspecial HID_EVT_SUBMITTED { HelpId = HID_EVT_SUBMITTED; } -hidspecial HID_EVT_TEXTCHANGED { HelpId = HID_EVT_TEXTCHANGED; } -hidspecial HID_EVT_UNLOADED { HelpId = HID_EVT_UNLOADED; } -hidspecial HID_EVT_UNLOADING { HelpId = HID_EVT_UNLOADING; } - -hidspecial HID_FIELDLINK_DETAIL_COLUMN { HelpId = HID_FIELDLINK_DETAIL_COLUMN; } -hidspecial HID_FIELDLINK_MASTER_COLUMN { HelpId = HID_FIELDLINK_MASTER_COLUMN; } - -hidspecial HID_GRIDWIZARD_CANCEL { HelpId = HID_GRIDWIZARD_CANCEL; } -hidspecial HID_GRIDWIZARD_FINISH { HelpId = HID_GRIDWIZARD_FINISH; } -hidspecial HID_GRIDWIZARD_NEXT { HelpId = HID_GRIDWIZARD_NEXT; } -hidspecial HID_GRIDWIZARD_PREVIOUS { HelpId = HID_GRIDWIZARD_PREVIOUS; }; -hidspecial HID_GROUPWIZARD_CANCEL { HelpId = HID_GROUPWIZARD_CANCEL; } -hidspecial HID_GROUPWIZARD_FINISH { HelpId = HID_GROUPWIZARD_FINISH; } -hidspecial HID_GROUPWIZARD_NEXT { HelpId = HID_GROUPWIZARD_NEXT; } -hidspecial HID_GROUPWIZARD_PREVIOUS { HelpId = HID_GROUPWIZARD_PREVIOUS; } - -hidspecial HID_LISTWIZARD_CANCEL { HelpId = HID_LISTWIZARD_CANCEL; } -hidspecial HID_LISTWIZARD_FINISH { HelpId = HID_LISTWIZARD_FINISH; } -hidspecial HID_LISTWIZARD_NEXT { HelpId = HID_LISTWIZARD_NEXT; } -hidspecial HID_LISTWIZARD_PREVIOUS { HelpId = HID_LISTWIZARD_PREVIOUS; } - -hidspecial HID_PROP_ALIGN { HelpId = HID_PROP_ALIGN; } -hidspecial HID_PROP_ALLOW_ADDITIONS { HelpId = HID_PROP_ALLOW_ADDITIONS; } -hidspecial HID_PROP_ALLOW_DELETIONS { HelpId = HID_PROP_ALLOW_DELETIONS; } -hidspecial HID_PROP_ALLOW_EDITS { HelpId = HID_PROP_ALLOW_EDITS; } -hidspecial HID_PROP_ANCHOR_TYPE { HelpId = HID_PROP_ANCHOR_TYPE; } -hidspecial HID_PROP_AUTOCOMPLETE { HelpId = HID_PROP_AUTOCOMPLETE; } -hidspecial HID_PROP_AUTOLINEBREAK { HelpId = HID_PROP_AUTOLINEBREAK; } -hidspecial HID_PROP_BACKGROUNDCOLOR { HelpId = HID_PROP_BACKGROUNDCOLOR; } -hidspecial HID_PROP_BINDING_NAME { HelpId = HID_PROP_BINDING_NAME; } -hidspecial HID_PROP_BIND_EXPRESSION { HelpId = HID_PROP_BIND_EXPRESSION; } -hidspecial HID_PROP_BLOCKINCREMENT { HelpId = HID_PROP_BLOCKINCREMENT; } -hidspecial HID_PROP_BORDER { HelpId = HID_PROP_BORDER; } -hidspecial HID_PROP_BORDERCOLOR { HelpId = HID_PROP_BORDERCOLOR; } -hidspecial HID_PROP_BOUNDCOLUMN { HelpId = HID_PROP_BOUNDCOLUMN; } -hidspecial HID_PROP_BOUND_CELL { HelpId = HID_PROP_BOUND_CELL; } -hidspecial HID_PROP_BUTTONTYPE { HelpId = HID_PROP_BUTTONTYPE; } -hidspecial HID_PROP_CELL_EXCHANGE_TYPE { HelpId = HID_PROP_CELL_EXCHANGE_TYPE; } -hidspecial HID_PROP_CLASSID { HelpId = HID_PROP_CLASSID; } -hidspecial HID_PROP_CONTROLLABEL { HelpId = HID_PROP_CONTROLLABEL; } -hidspecial HID_PROP_CONTROLSOURCE { HelpId = HID_PROP_CONTROLSOURCE; } -hidspecial HID_PROP_CURRENCYSYMBOL { HelpId = HID_PROP_CURRENCYSYMBOL; } -hidspecial HID_PROP_CURRSYM_POSITION { HelpId = HID_PROP_CURRSYM_POSITION; } -hidspecial HID_PROP_CURSORSOURCE { HelpId = HID_PROP_CURSORSOURCE; } -hidspecial HID_PROP_CURSORSOURCETYPE { HelpId = HID_PROP_CURSORSOURCETYPE; } -hidspecial HID_PROP_CURSORTYPE { HelpId = HID_PROP_CURSORTYPE; } -hidspecial HID_PROP_CYCLE { HelpId = HID_PROP_CYCLE; } -hidspecial HID_PROP_DATAENTRY { HelpId = HID_PROP_DATAENTRY; } -hidspecial HID_PROP_DATASOURCE { HelpId = HID_PROP_DATASOURCE; } -hidspecial HID_PROP_DATE { HelpId = HID_PROP_DATE; } -hidspecial HID_PROP_DATEFORMAT { HelpId = HID_PROP_DATEFORMAT; } -hidspecial HID_PROP_DATEMAX { HelpId = HID_PROP_DATEMAX; } -hidspecial HID_PROP_DATEMIN { HelpId = HID_PROP_DATEMIN; } -hidspecial HID_PROP_DECIMAL_ACCURACY { HelpId = HID_PROP_DECIMAL_ACCURACY; } -hidspecial HID_PROP_DECORATION { HelpId = HID_PROP_DECORATION; } -hidspecial HID_PROP_DEFAULTVALUE { HelpId = HID_PROP_DEFAULTVALUE; } -hidspecial HID_PROP_DEFAULT_BUTTON { HelpId = HID_PROP_DEFAULT_BUTTON; } -hidspecial HID_PROP_DEFAULT_DATE { HelpId = HID_PROP_DEFAULT_DATE; } -hidspecial HID_PROP_DEFAULT_LONG_VALUE { HelpId = HID_PROP_DEFAULT_LONG_VALUE; } -hidspecial HID_PROP_DEFAULT_SCROLLVALUE { HelpId = HID_PROP_DEFAULT_SCROLLVALUE; } -hidspecial HID_PROP_DEFAULT_SELECT_SEQ { HelpId = HID_PROP_DEFAULT_SELECT_SEQ; } -hidspecial HID_PROP_DEFAULT_SPINVALUE { HelpId = HID_PROP_DEFAULT_SPINVALUE; } -hidspecial HID_PROP_DEFAULT_STATE { HelpId = HID_PROP_DEFAULT_STATE; } -hidspecial HID_PROP_DEFAULT_TIME { HelpId = HID_PROP_DEFAULT_TIME; } -hidspecial HID_PROP_DIRTY { HelpId = HID_PROP_DIRTY; } -hidspecial HID_PROP_DROPDOWN { HelpId = HID_PROP_DROPDOWN; } -hidspecial HID_PROP_ECHO_CHAR { HelpId = HID_PROP_ECHO_CHAR; } -hidspecial HID_PROP_EDITABLE { HelpId = HID_PROP_EDITABLE; } -hidspecial HID_PROP_EDITMASK { HelpId = HID_PROP_EDITMASK; } -hidspecial HID_PROP_EFFECTIVEDEFAULT { HelpId = HID_PROP_EFFECTIVEDEFAULT; } -hidspecial HID_PROP_EFFECTIVEMAX { HelpId = HID_PROP_EFFECTIVEMAX; } -hidspecial HID_PROP_EFFECTIVEMIN { HelpId = HID_PROP_EFFECTIVEMIN; } -hidspecial HID_PROP_EMPTY_IS_NULL { HelpId = HID_PROP_EMPTY_IS_NULL; } -hidspecial HID_PROP_ENABLED { HelpId = HID_PROP_ENABLED; } -hidspecial HID_PROP_ENABLE_VISIBLE { HelpId = HID_PROP_ENABLE_VISIBLE; } -hidspecial HID_PROP_ESCAPE_PROCESSING { HelpId = HID_PROP_ESCAPE_PROCESSING; } -hidspecial HID_PROP_FILLCOLOR { HelpId = HID_PROP_FILLCOLOR; } -hidspecial HID_PROP_FILTER { HelpId = HID_PROP_FILTER; } -hidspecial HID_PROP_FILTERPROPOSAL { HelpId = HID_PROP_FILTERPROPOSAL; } -hidspecial HID_PROP_FOCUSONCLICK { HelpId = HID_PROP_FOCUSONCLICK; } -hidspecial HID_PROP_FONT { HelpId = HID_PROP_FONT; } -hidspecial HID_PROP_FORMATKEY { HelpId = HID_PROP_FORMATKEY; } -hidspecial HID_PROP_GROUPBOX { HelpId = HID_PROP_GROUPBOX; } -hidspecial HID_PROP_GROUP_NAME { HelpId = HID_PROP_GROUP_NAME; } -hidspecial HID_PROP_HEIGHT { HelpId = HID_PROP_HEIGHT; } -hidspecial HID_PROP_HELPTEXT { HelpId = HID_PROP_HELPTEXT; } -hidspecial HID_PROP_HELPURL { HelpId = HID_PROP_HELPURL; } -hidspecial HID_PROP_HIDDEN_VALUE { HelpId = HID_PROP_HIDDEN_VALUE; } -hidspecial HID_PROP_HIDEINACTIVESELECTION { HelpId = HID_PROP_HIDEINACTIVESELECTION; } -hidspecial HID_PROP_HSCROLL { HelpId = HID_PROP_HSCROLL; } -hidspecial HID_PROP_ICONSIZE { HelpId = HID_PROP_ICONSIZE; } -hidspecial HID_PROP_IMAGEPOSITION { HelpId = HID_PROP_IMAGEPOSITION; } -hidspecial HID_PROP_IMAGE_URL { HelpId = HID_PROP_IMAGE_URL; } -hidspecial HID_PROP_INPUT_REQUIRED { HelpId = HID_PROP_INPUT_REQUIRED; } -hidspecial HID_PROP_INVOKES_STOP_NOT_EDITING { HelpId = HID_PROP_INVOKES_STOP_NOT_EDITING; } -hidspecial HID_PROP_LABEL { HelpId = HID_PROP_LABEL; } -hidspecial HID_PROP_LEFT { HelpId = HID_PROP_LEFT; } -hidspecial HID_PROP_LINECOLOR { HelpId = HID_PROP_LINECOLOR; } -hidspecial HID_PROP_LINECOUNT { HelpId = HID_PROP_LINECOUNT; } -hidspecial HID_PROP_LINEEND_FORMAT { HelpId = HID_PROP_LINEEND_FORMAT; } -hidspecial HID_PROP_LINEINCREMENT { HelpId = HID_PROP_LINEINCREMENT; } -hidspecial HID_PROP_LISTINDEX { HelpId = HID_PROP_LISTINDEX; } -hidspecial HID_PROP_LISTSOURCE { HelpId = HID_PROP_LISTSOURCE; } -hidspecial HID_PROP_LISTSOURCETYPE { HelpId = HID_PROP_LISTSOURCETYPE; } -hidspecial HID_PROP_LIST_BINDING { HelpId = HID_PROP_LIST_BINDING; } -hidspecial HID_PROP_LIST_CELL_RANGE { HelpId = HID_PROP_LIST_CELL_RANGE; } -hidspecial HID_PROP_LITERALMASK { HelpId = HID_PROP_LITERALMASK; } -hidspecial HID_PROP_LOCKED { HelpId = HID_PROP_LOCKED; } -hidspecial HID_PROP_MASTERFIELDS { HelpId = HID_PROP_MASTERFIELDS; } -hidspecial HID_PROP_MAXTEXTLEN { HelpId = HID_PROP_MAXTEXTLEN; } -hidspecial HID_PROP_MULTILINE { HelpId = HID_PROP_MULTILINE; } -hidspecial HID_PROP_MULTISELECTION { HelpId = HID_PROP_MULTISELECTION; } -hidspecial HID_PROP_NAME { HelpId = HID_PROP_NAME; } -hidspecial HID_PROP_NAVIGATION { HelpId = HID_PROP_NAVIGATION; } -hidspecial HID_PROP_NAVIGATIONBAR { HelpId = HID_PROP_NAVIGATIONBAR; } -hidspecial HID_PROP_NOLABEL { HelpId = HID_PROP_NOLABEL; } -hidspecial HID_PROP_OLDVALUE { HelpId = HID_PROP_OLDVALUE; } -hidspecial HID_PROP_ORIENTATION { HelpId = HID_PROP_ORIENTATION; } -hidspecial HID_PROP_POSITIONX { HelpId = HID_PROP_POSITIONX; } -hidspecial HID_PROP_POSITIONY { HelpId = HID_PROP_POSITIONY; } -hidspecial HID_PROP_PRINTABLE { HelpId = HID_PROP_PRINTABLE; } -hidspecial HID_PROP_PROGRESSVALUE { HelpId = HID_PROP_PROGRESSVALUE; } -hidspecial HID_PROP_PROGRESSVALUE_MAX { HelpId = HID_PROP_PROGRESSVALUE_MAX; } -hidspecial HID_PROP_PROGRESSVALUE_MIN { HelpId = HID_PROP_PROGRESSVALUE_MIN; } -hidspecial HID_PROP_PUSHBUTTONTYPE { HelpId = HID_PROP_PUSHBUTTONTYPE; } -hidspecial HID_PROP_READONLY { HelpId = HID_PROP_READONLY; } -hidspecial HID_PROP_RECORDMARKER { HelpId = HID_PROP_RECORDMARKER; } -hidspecial HID_PROP_REFVALUE { HelpId = HID_PROP_REFVALUE; } -hidspecial HID_PROP_REPEAT { HelpId = HID_PROP_REPEAT; } -hidspecial HID_PROP_REPEAT_DELAY { HelpId = HID_PROP_REPEAT_DELAY; } -hidspecial HID_PROP_REQUIRED { HelpId = HID_PROP_REQUIRED; } -hidspecial HID_PROP_RIGHT { HelpId = HID_PROP_RIGHT; } -hidspecial HID_PROP_ROOT_DISPLAYED { HelpId = HID_PROP_ROOT_DISPLAYED; } -hidspecial HID_PROP_ROWHEIGHT { HelpId = HID_PROP_ROWHEIGHT; } -hidspecial HID_PROP_ROW_HEIGHT { HelpId = HID_PROP_ROW_HEIGHT; } -hidspecial HID_PROP_SCALEIMAGE { HelpId = HID_PROP_SCALEIMAGE; } -hidspecial HID_PROP_SCROLLVALUE { HelpId = HID_PROP_SCROLLVALUE; } -hidspecial HID_PROP_SCROLLVALUEMIN { HelpId = HID_PROP_SCROLLVALUE_MIN; } -hidspecial HID_PROP_SCROLLVALUE_MAX { HelpId = HID_PROP_SCROLLVALUE_MAX; } -hidspecial HID_PROP_SCROLLVALUE_MIN { HelpId = HID_PROP_SCROLLVALUE_MIN; } -hidspecial HID_PROP_SEARCHING { HelpId = HID_PROP_SEARCHING; } -hidspecial HID_PROP_SELECTEDITEMS { HelpId = HID_PROP_SELECTEDITEMS; } -hidspecial HID_PROP_SELECTION_TYPE { HelpId = HID_PROP_SELECTION_TYPE; } -hidspecial HID_PROP_SHOWS_HANDLES { HelpId = HID_PROP_SHOWS_HANDLES; } -hidspecial HID_PROP_SHOWS_ROOT_HANDLES { HelpId = HID_PROP_SHOWS_ROOT_HANDLES; } -hidspecial HID_PROP_SHOWTHOUSANDSEP { HelpId = HID_PROP_SHOWTHOUSANDSEP; } -hidspecial HID_PROP_SHOW_FILTERSORT { HelpId = HID_PROP_SHOW_FILTERSORT; } -hidspecial HID_PROP_SHOW_NAVIGATION { HelpId = HID_PROP_SHOW_NAVIGATION; } -hidspecial HID_PROP_SHOW_POSITION { HelpId = HID_PROP_SHOW_POSITION; } -hidspecial HID_PROP_SHOW_RECORDACTIONS { HelpId = HID_PROP_SHOW_RECORDACTIONS; } -hidspecial HID_PROP_SHOW_SCROLLBARS { HelpId = HID_PROP_SHOW_SCROLLBARS; } -hidspecial HID_PROP_SLAVEFIELDS { HelpId = HID_PROP_SLAVEFIELDS; } -hidspecial HID_PROP_SORT_CRITERIA { HelpId = HID_PROP_SORT_CRITERIA; } -hidspecial HID_PROP_SPIN { HelpId = HID_PROP_SPIN; } -hidspecial HID_PROP_SPININCREMENT { HelpId = HID_PROP_SPININCREMENT; } -hidspecial HID_PROP_SPINVALUE { HelpId = HID_PROP_SPINVALUE; } -hidspecial HID_PROP_SPINVALUE_MAX { HelpId = HID_PROP_SPINVALUE_MAX; } -hidspecial HID_PROP_SPINVALUE_MIN { HelpId = HID_PROP_SPINVALUE_MIN; } -hidspecial HID_PROP_STATE { HelpId = HID_PROP_STATE; } -hidspecial HID_PROP_STEP { HelpId = HID_PROP_STEP; } -hidspecial HID_PROP_STRICTFORMAT { HelpId = HID_PROP_STRICTFORMAT; } -hidspecial HID_PROP_STRINGITEMLIST { HelpId = HID_PROP_STRINGITEMLIST; } -hidspecial HID_PROP_SUBMISSION_ID { HelpId = HID_PROP_SUBMISSION_ID; } -hidspecial HID_PROP_SUBMIT_ACTION { HelpId = HID_PROP_SUBMIT_ACTION; } -hidspecial HID_PROP_SUBMIT_ENCODING { HelpId = HID_PROP_SUBMIT_ENCODING; } -hidspecial HID_PROP_SUBMIT_METHOD { HelpId = HID_PROP_SUBMIT_METHOD; } -hidspecial HID_PROP_SUBMIT_TARGET { HelpId = HID_PROP_SUBMIT_TARGET; } -hidspecial HID_PROP_SYMBOLCOLOR { HelpId = HID_PROP_SYMBOLCOLOR; } -hidspecial HID_PROP_TABINDEX { HelpId = HID_PROP_TABINDEX; } -hidspecial HID_PROP_TABORDER_CONTROLS { HelpId = HID_PROP_TABORDER_CONTROLS; } -hidspecial HID_PROP_TABSTOP { HelpId = HID_PROP_TABSTOP; } -hidspecial HID_PROP_TAG { HelpId = HID_PROP_TAG; } -hidspecial HID_PROP_TARGET_FRAME { HelpId = HID_PROP_TARGET_FRAME; } -hidspecial HID_PROP_TARGET_URL { HelpId = HID_PROP_TARGET_URL; } -hidspecial HID_PROP_TEXT { HelpId = HID_PROP_TEXT; } -hidspecial HID_PROP_TEXTTYPE { HelpId = HID_PROP_TEXTTYPE; } -hidspecial HID_PROP_TIME { HelpId = HID_PROP_TIME; } -hidspecial HID_PROP_TIMEFORMAT { HelpId = HID_PROP_TIMEFORMAT; } -hidspecial HID_PROP_TIMEMAX { HelpId = HID_PROP_TIMEMAX; } -hidspecial HID_PROP_TIMEMIN { HelpId = HID_PROP_TIMEMIN; } -hidspecial HID_PROP_TITLE { HelpId = HID_PROP_TITLE; } -hidspecial HID_PROP_TOGGLE { HelpId = HID_PROP_TOGGLE; } -hidspecial HID_PROP_TRISTATE { HelpId = HID_PROP_TRISTATE; } -hidspecial HID_PROP_UNCHECKEDREFVALUE { HelpId = HID_PROP_UNCHECKEDREFVALUE; } -hidspecial HID_PROP_UNIQUE { HelpId = HID_PROP_UNIQUE; } -hidspecial HID_PROP_VALUE { HelpId = HID_PROP_VALUE; } -hidspecial HID_PROP_VALUEMAX { HelpId = HID_PROP_VALUEMAX; } -hidspecial HID_PROP_VALUEMIN { HelpId = HID_PROP_VALUEMIN; } -hidspecial HID_PROP_VALUESTEP { HelpId = HID_PROP_VALUESTEP; } -hidspecial HID_PROP_VERTICAL_ALIGN { HelpId = HID_PROP_VERTICAL_ALIGN; } -hidspecial HID_PROP_VISIBLESIZE { HelpId = HID_PROP_VISIBLESIZE; } -hidspecial HID_PROP_VISUALEFFECT { HelpId = HID_PROP_VISUALEFFECT; } -hidspecial HID_PROP_VSCROLL { HelpId = HID_PROP_VSCROLL; } -hidspecial HID_PROP_WHEEL_BEHAVIOR { HelpId = HID_PROP_WHEEL_BEHAVIOR; } -hidspecial HID_PROP_WIDTH { HelpId = HID_PROP_WIDTH; } -hidspecial HID_PROP_WORDBREAK { HelpId = HID_PROP_WORDBREAK; } -hidspecial HID_PROP_WRITING_MODE { HelpId = HID_PROP_WRITING_MODE; } -hidspecial HID_PROP_XML_DATA_MODEL { HelpId = HID_PROP_XML_DATA_MODEL; } -hidspecial HID_PROP_XSD_CALCULATION { HelpId = HID_PROP_XSD_CALCULATION; } -hidspecial HID_PROP_XSD_CONSTRAINT { HelpId = HID_PROP_XSD_CONSTRAINT; } -hidspecial HID_PROP_XSD_DATA_TYPE { HelpId = HID_PROP_XSD_DATA_TYPE; } -hidspecial HID_PROP_XSD_FRACTION_DIGITS { HelpId = HID_PROP_XSD_FRACTION_DIGITS; } -hidspecial HID_PROP_XSD_LENGTH { HelpId = HID_PROP_XSD_LENGTH; } -hidspecial HID_PROP_XSD_MAX_EXCLUSIVE { HelpId = HID_PROP_XSD_MAX_EXCLUSIVE; } -hidspecial HID_PROP_XSD_MAX_INCLUSIVE { HelpId = HID_PROP_XSD_MAX_INCLUSIVE; } -hidspecial HID_PROP_XSD_MAX_LENGTH { HelpId = HID_PROP_XSD_MAX_LENGTH; } -hidspecial HID_PROP_XSD_MIN_EXCLUSIVE { HelpId = HID_PROP_XSD_MIN_EXCLUSIVE; } -hidspecial HID_PROP_XSD_MIN_INCLUSIVE { HelpId = HID_PROP_XSD_MIN_INCLUSIVE; } -hidspecial HID_PROP_XSD_MIN_LENGTH { HelpId = HID_PROP_XSD_MIN_LENGTH; } -hidspecial HID_PROP_XSD_PATTERN { HelpId = HID_PROP_XSD_PATTERN; } -hidspecial HID_PROP_XSD_READONLY { HelpId = HID_PROP_XSD_READONLY; } -hidspecial HID_PROP_XSD_RELEVANT { HelpId = HID_PROP_XSD_RELEVANT; } -hidspecial HID_PROP_XSD_REQUIRED { HelpId = HID_PROP_XSD_REQUIRED; } -hidspecial HID_PROP_XSD_TOTAL_DIGITS { HelpId = HID_PROP_XSD_TOTAL_DIGITS; } -hidspecial HID_PROP_XSD_WHITESPACES { HelpId = HID_PROP_XSD_WHITESPACES; } - -hidspecial HID_SELECTION_TLB { HelpId = HID_SELECTION_TLB; } - -hidspecial UID_ABSPILOT_HELP { HelpId = UID_ABSPILOT_HELP; } -hidspecial UID_BIB_FRAME_WINDOW { HelpId = UID_BIB_FRAME_WINDOW;} - -hidspecial UID_BRWEVT_ACTIONPERFORMED { HelpId = UID_BRWEVT_ACTIONPERFORMED; } -hidspecial UID_BRWEVT_ADJUSTMENTVALUECHANGED { HelpId = UID_BRWEVT_ADJUSTMENTVALUECHANGED; } -hidspecial UID_BRWEVT_AFTERUPDATE { HelpId = UID_BRWEVT_AFTERUPDATE; } -hidspecial UID_BRWEVT_APPROVEACTIONPERFORMED { HelpId = UID_BRWEVT_APPROVEACTIONPERFORMED; } -hidspecial UID_BRWEVT_APPROVEPARAMETER { HelpId = UID_BRWEVT_APPROVEPARAMETER; } -hidspecial UID_BRWEVT_APPROVERESETTED { HelpId = UID_BRWEVT_APPROVERESETTED; } -hidspecial UID_BRWEVT_APPROVEROWCHANGE { HelpId = UID_BRWEVT_APPROVEROWCHANGE; } -hidspecial UID_BRWEVT_BEFOREUPDATE { HelpId = UID_BRWEVT_BEFOREUPDATE; } -hidspecial UID_BRWEVT_CHANGED { HelpId = UID_BRWEVT_CHANGED; } -hidspecial UID_BRWEVT_CONFIRMDELETE { HelpId = UID_BRWEVT_CONFIRMDELETE; } -hidspecial UID_BRWEVT_ERROROCCURRED { HelpId = UID_BRWEVT_ERROROCCURRED; } -hidspecial UID_BRWEVT_FOCUSGAINED { HelpId = UID_BRWEVT_FOCUSGAINED; } -hidspecial UID_BRWEVT_FOCUSLOST { HelpId = UID_BRWEVT_FOCUSLOST; } -hidspecial UID_BRWEVT_ITEMSTATECHANGED { HelpId = UID_BRWEVT_ITEMSTATECHANGED; } -hidspecial UID_BRWEVT_KEYTYPED { HelpId = UID_BRWEVT_KEYTYPED; } -hidspecial UID_BRWEVT_KEYUP { HelpId = UID_BRWEVT_KEYUP; } -hidspecial UID_BRWEVT_LOADED { HelpId = UID_BRWEVT_LOADED; } -hidspecial UID_BRWEVT_MOUSEDRAGGED { HelpId = UID_BRWEVT_MOUSEDRAGGED; } -hidspecial UID_BRWEVT_MOUSEENTERED { HelpId = UID_BRWEVT_MOUSEENTERED; } -hidspecial UID_BRWEVT_MOUSEEXITED { HelpId = UID_BRWEVT_MOUSEEXITED; } -hidspecial UID_BRWEVT_MOUSEMOVED { HelpId = UID_BRWEVT_MOUSEMOVED; } -hidspecial UID_BRWEVT_MOUSEPRESSED { HelpId = UID_BRWEVT_MOUSEPRESSED; } -hidspecial UID_BRWEVT_MOUSERELEASED { HelpId = UID_BRWEVT_MOUSERELEASED; } -hidspecial UID_BRWEVT_POSITIONED { HelpId = UID_BRWEVT_POSITIONED; } -hidspecial UID_BRWEVT_POSITIONING { HelpId = UID_BRWEVT_POSITIONING; } -hidspecial UID_BRWEVT_RELOADED { HelpId = UID_BRWEVT_RELOADED; } -hidspecial UID_BRWEVT_RELOADING { HelpId = UID_BRWEVT_RELOADING; } -hidspecial UID_BRWEVT_RESETTED { HelpId = UID_BRWEVT_RESETTED; } -hidspecial UID_BRWEVT_ROWCHANGE { HelpId = UID_BRWEVT_ROWCHANGE; } -hidspecial UID_BRWEVT_SUBMITTED { HelpId = UID_BRWEVT_SUBMITTED; } -hidspecial UID_BRWEVT_TEXTCHANGED { HelpId = UID_BRWEVT_TEXTCHANGED; } -hidspecial UID_BRWEVT_UNLOADED { HelpId = UID_BRWEVT_UNLOADED; } -hidspecial UID_BRWEVT_UNLOADING { HelpId = UID_BRWEVT_UNLOADING; } - -hidspecial UID_EVT_MACRODLG { HelpId = UID_EVT_MACRODLG; } - -hidspecial UID_FIELDLINK_DETAIL1 { HelpId = UID_FIELDLINK_DETAIL1; } -hidspecial UID_FIELDLINK_DETAIL2 { HelpId = UID_FIELDLINK_DETAIL2; } -hidspecial UID_FIELDLINK_DETAIL3 { HelpId = UID_FIELDLINK_DETAIL3; } -hidspecial UID_FIELDLINK_DETAIL4 { HelpId = UID_FIELDLINK_DETAIL4; } -hidspecial UID_FIELDLINK_MASTER1 { HelpId = UID_FIELDLINK_MASTER1; } -hidspecial UID_FIELDLINK_MASTER2 { HelpId = UID_FIELDLINK_MASTER2; } -hidspecial UID_FIELDLINK_MASTER3 { HelpId = UID_FIELDLINK_MASTER3; } -hidspecial UID_FIELDLINK_MASTER4 { HelpId = UID_FIELDLINK_MASTER4; } - -hidspecial UID_PROP_ADD_DATA_TYPE { HelpId = UID_PROP_ADD_DATA_TYPE; } -hidspecial UID_PROP_DLG_ATTR_DATASOURCE { HelpId = UID_PROP_DLG_ATTR_DATASOURCE; } -hidspecial UID_PROP_DLG_ATTR_DATASOURCE { HelpId = UID_PROP_DLG_ATTR_DATASOURCE; } -hidspecial UID_PROP_DLG_ATTR_TARGET_URL { HelpId = UID_PROP_DLG_ATTR_TARGET_URL; } -hidspecial UID_PROP_DLG_ATTR_TARGET_URL { HelpId = UID_PROP_DLG_ATTR_TARGET_URL; } -hidspecial UID_PROP_DLG_BACKGROUNDCOLOR { HelpId = UID_PROP_DLG_BACKGROUNDCOLOR; } -hidspecial UID_PROP_DLG_BACKGROUNDCOLOR { HelpId = UID_PROP_DLG_BACKGROUNDCOLOR; } -hidspecial UID_PROP_DLG_BIND_EXPRESSION { HelpId = UID_PROP_DLG_BIND_EXPRESSION; } -hidspecial UID_PROP_DLG_BORDERCOLOR { HelpId = UID_PROP_DLG_BORDERCOLOR; } -hidspecial UID_PROP_DLG_CONTROLLABEL { HelpId = UID_PROP_DLG_CONTROLLABEL; } -hidspecial UID_PROP_DLG_CONTROLLABEL { HelpId = UID_PROP_DLG_CONTROLLABEL; } -hidspecial UID_PROP_DLG_FILLCOLOR { HelpId = UID_PROP_DLG_FILLCOLOR; } -hidspecial UID_PROP_DLG_FILLCOLOR { HelpId = UID_PROP_DLG_FILLCOLOR; } -hidspecial UID_PROP_DLG_FILTER { HelpId = UID_PROP_DLG_FILTER; } -hidspecial UID_PROP_DLG_FONT_TYPE { HelpId = UID_PROP_DLG_FONT_TYPE; } -hidspecial UID_PROP_DLG_FONT_TYPE { HelpId = UID_PROP_DLG_FONT_TYPE; } -hidspecial UID_PROP_DLG_FORMLINKFIELDS { HelpId = UID_PROP_DLG_FORMLINKFIELDS; } -hidspecial UID_PROP_DLG_IMAGE_URL { HelpId = UID_PROP_DLG_IMAGE_URL; } -hidspecial UID_PROP_DLG_IMAGE_URL { HelpId = UID_PROP_DLG_IMAGE_URL; } -hidspecial UID_PROP_DLG_NUMBER_FORMAT { HelpId = UID_PROP_DLG_NUMBER_FORMAT; } -hidspecial UID_PROP_DLG_NUMBER_FORMAT { HelpId = UID_PROP_DLG_NUMBER_FORMAT; } -hidspecial UID_PROP_DLG_ORDER { HelpId = UID_PROP_DLG_ORDER; } -hidspecial UID_PROP_DLG_SELECTION { HelpId = UID_PROP_DLG_SELECTION; } -hidspecial UID_PROP_DLG_SQLCOMMAND { HelpId = UID_PROP_DLG_SQLCOMMAND; } -hidspecial UID_PROP_DLG_SYMBOLCOLOR { HelpId = UID_PROP_DLG_SYMBOLCOLOR; } -hidspecial UID_PROP_DLG_TABINDEX { HelpId = UID_PROP_DLG_TABINDEX; } -hidspecial UID_PROP_DLG_XSD_CALCULATION { HelpId = UID_PROP_DLG_XSD_CALCULATION; } -hidspecial UID_PROP_DLG_XSD_CONSTRAINT { HelpId = UID_PROP_DLG_XSD_CONSTRAINT; } -hidspecial UID_PROP_DLG_XSD_READONLY { HelpId = UID_PROP_DLG_XSD_READONLY; } -hidspecial UID_PROP_DLG_XSD_RELEVANT { HelpId = UID_PROP_DLG_XSD_RELEVANT; } -hidspecial UID_PROP_DLG_XSD_REQUIRED { HelpId = UID_PROP_DLG_XSD_REQUIRED; } -hidspecial UID_PROP_REMOVE_DATA_TYPE { HelpId = UID_PROP_REMOVE_DATA_TYPE; } -hidspecial HID_FM_PROPDLG_TABCTR { HelpId = HID_FM_PROPDLG_TABCTR; } -hidspecial HID_FM_PROPDLG_TAB_GENERAL { HelpId = HID_FM_PROPDLG_TAB_GENERAL; } -hidspecial HID_FM_PROPDLG_TAB_DATA { HelpId = HID_FM_PROPDLG_TAB_DATA; } -hidspecial HID_FM_PROPDLG_TAB_EVT { HelpId = HID_FM_PROPDLG_TAB_EVT; } -- cgit From 6c6055750dd4c0ddcff06fcf5b6d93d576245633 Mon Sep 17 00:00:00 2001 From: Matúš Kukan Date: Mon, 19 Dec 2011 16:37:06 +0100 Subject: move onlinecheck.cxx from sal to extensions --- extensions/Library_updchk.mk | 5 ++ extensions/source/update/check/onlinecheck.cxx | 69 ++++++++++++++++++++++ extensions/source/update/check/updatecheck.cxx | 33 ++--------- sal/systools/win32/onlineupdate/makefile.mk | 78 ------------------------- sal/systools/win32/onlineupdate/onlinecheck.cxx | 69 ---------------------- sal/systools/win32/onlineupdate/onlinecheck.dxp | 28 --------- 6 files changed, 79 insertions(+), 203 deletions(-) create mode 100644 extensions/source/update/check/onlinecheck.cxx delete mode 100755 sal/systools/win32/onlineupdate/makefile.mk delete mode 100644 sal/systools/win32/onlineupdate/onlinecheck.cxx delete mode 100644 sal/systools/win32/onlineupdate/onlinecheck.dxp diff --git a/extensions/Library_updchk.mk b/extensions/Library_updchk.mk index a16f2a2e6160..c5286de8e08d 100644 --- a/extensions/Library_updchk.mk +++ b/extensions/Library_updchk.mk @@ -51,6 +51,11 @@ ifeq ($(OS),WNT) $(eval $(call gb_Library_add_linked_libs,updchk,\ ole32 \ shell32 \ + wininet \ +)) + +$(eval $(call gb_Library_add_exception_objects,updchk,\ + extensions/source/update/check/onlinecheck \ )) endif # OS WNT diff --git a/extensions/source/update/check/onlinecheck.cxx b/extensions/source/update/check/onlinecheck.cxx new file mode 100644 index 000000000000..0a765399cce3 --- /dev/null +++ b/extensions/source/update/check/onlinecheck.cxx @@ -0,0 +1,69 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifdef _MSC_VER +#pragma warning( disable: 4668 ) +#endif + +#include +#include + +#define WIN32_LEAN_AND_MEAN +#include +#include + +#ifdef UNICODE +#define _UNICODE +#endif +#include + +// #i71984 +extern "C" bool SAL_CALL WNT_hasInternetConnection() +{ + DWORD dwFlags; + TCHAR szConnectionName[1024]; + +#ifndef __MINGW32__ + __try { +#endif + BOOL fIsConnected = InternetGetConnectedStateEx( + &dwFlags, + szConnectionName, + SAL_N_ELEMENTS(szConnectionName), + 0 ); + + return fIsConnected ? true : false; + +#ifndef __MINGW32__ + } __except( EXCEPTION_EXECUTE_HANDLER ) { + return false; + } +#endif +} + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/extensions/source/update/check/updatecheck.cxx b/extensions/source/update/check/updatecheck.cxx index 66acb883033a..d0b204a3be3a 100644 --- a/extensions/source/update/check/updatecheck.cxx +++ b/extensions/source/update/check/updatecheck.cxx @@ -85,6 +85,7 @@ namespace uno = com::sun::star::uno ; #define PROPERTY_DEFAULT_TEXT UNISTRING("DefaultText") #define PROPERTY_SHOW_MENUICON UNISTRING("MenuIconVisible") +extern "C" bool SAL_CALL WNT_hasInternetConnection(); //------------------------------------------------------------------------------ // Returns the URL of the release note for the given position @@ -267,9 +268,11 @@ private: /* Used to avoid dialup login windows (on platforms we know how to double this) */ inline bool hasInternetConnection() const { - if(m_pHasInternetConnection != NULL ) - return (sal_True == m_pHasInternetConnection()); +#ifdef WNT + return WNT_hasInternetConnection(); +#else return true; +#endif } /* Creates a new instance of UpdateInformationProvider and returns this instance */ @@ -295,10 +298,6 @@ protected: osl::Condition& m_aCondition; private: - -// const - OnlineCheckFunc m_pHasInternetConnection; - const uno::Reference m_xContext; uno::Reference m_xProvider; }; @@ -373,30 +372,8 @@ private: UpdateCheckThread::UpdateCheckThread( osl::Condition& rCondition, const uno::Reference& xContext ) : m_aCondition(rCondition), - m_pHasInternetConnection(NULL), m_xContext(xContext) { - -#ifdef WNT - rtl::OUString aPath; - if( osl_getExecutableFile(&aPath.pData) == osl_Process_E_None ) - { - sal_uInt32 lastIndex = aPath.lastIndexOf('/'); - if ( lastIndex > 0 ) - { - aPath = aPath.copy( 0, lastIndex+1 ); - aPath += UNISTRING( "onlinecheck" ); - } - - if ( m_aModule.load(aPath) ) - { - m_pHasInternetConnection = - reinterpret_cast < OnlineCheckFunc > ( - m_aModule.getFunctionSymbol( UNISTRING("hasInternetConnection"))); - } - } -#endif - createSuspended(); // actually run the thread diff --git a/sal/systools/win32/onlineupdate/makefile.mk b/sal/systools/win32/onlineupdate/makefile.mk deleted file mode 100755 index 027ddef11192..000000000000 --- a/sal/systools/win32/onlineupdate/makefile.mk +++ /dev/null @@ -1,78 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=..$/..$/.. -PRJNAME=sal -TARGET=onlinecheck - -USE_DEFFILE=TRUE -LIBTARGET=NO - -# --- Settings ---------------------------------- - -.INCLUDE : settings.mk - -CFLAGS+= $(LFS_CFLAGS) -CXXFLAGS+= $(LFS_CFLAGS) - -# --- Targets ---------------------------------- - -.IF "$(GUI)"=="WNT" - -.IF "$(COMEX)"=="9" -.IF "$(PSDK_HOME)"!="" -# Since the 02/2003 PSDK the "new" linker is needed here. -LINK=$(WRAPCMD) "$(PSDK_HOME)$/Bin$/Win64$/LINK.EXE" -.ENDIF -.ENDIF - -SLOFILES=\ - $(SLO)$/onlinecheck.obj - - -SHL1TARGET=$(TARGET) -SHL1IMPLIB=$(SHL1TARGET) -SHL1DEF=$(MISC)/$(SHL1TARGET).def -DEF1NAME=$(SHL1TARGET) -DEF1EXPORTFILE=$(SHL1TARGET).dxp - -DEF1DEPN=\ - $(DEF1EXPORTFILE)\ - makefile.mk - -SHL1OBJS=$(SLOFILES) - -SHL1STDLIBS=\ - $(KERNEL32LIB)\ - $(LIBCMT)\ - $(WININETLIB) - - -.ENDIF - -.INCLUDE : target.mk - diff --git a/sal/systools/win32/onlineupdate/onlinecheck.cxx b/sal/systools/win32/onlineupdate/onlinecheck.cxx deleted file mode 100644 index d3bbdc3f7b19..000000000000 --- a/sal/systools/win32/onlineupdate/onlinecheck.cxx +++ /dev/null @@ -1,69 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -#ifdef _MSC_VER -#pragma warning( disable: 4668 ) -#endif - -#include -#include - -#define WIN32_LEAN_AND_MEAN -#include -#include - -#ifdef UNICODE -#define _UNICODE -#endif -#include - -// #i71984 -extern "C" sal_Bool SAL_CALL hasInternetConnection() -{ - DWORD dwFlags; - TCHAR szConnectionName[1024]; - -#ifndef __MINGW32__ - __try { -#endif - BOOL fIsConnected = InternetGetConnectedStateEx( - &dwFlags, - szConnectionName, - SAL_N_ELEMENTS(szConnectionName), - 0 ); - - return fIsConnected ? sal_True : sal_False; - -#ifndef __MINGW32__ - } __except( EXCEPTION_EXECUTE_HANDLER ) { - return sal_False; - } -#endif -} - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sal/systools/win32/onlineupdate/onlinecheck.dxp b/sal/systools/win32/onlineupdate/onlinecheck.dxp deleted file mode 100644 index 7d3a3cac01fd..000000000000 --- a/sal/systools/win32/onlineupdate/onlinecheck.dxp +++ /dev/null @@ -1,28 +0,0 @@ -;************************************************************************* -; -; DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -; -; Copyright 2000, 2010 Oracle and/or its affiliates. -; -; OpenOffice.org - a multi-platform office productivity suite -; -; This file is part of OpenOffice.org. -; -; OpenOffice.org is free software: you can redistribute it and/or modify -; it under the terms of the GNU Lesser General Public License version 3 -; only, as published by the Free Software Foundation. -; -; OpenOffice.org is distributed in the hope that it will be useful, -; but WITHOUT ANY WARRANTY; without even the implied warranty of -; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -; GNU Lesser General Public License version 3 for more details -; (a copy is included in the LICENSE file that accompanied this code). -; -; You should have received a copy of the GNU Lesser General Public License -; version 3 along with OpenOffice.org. If not, see -; -; for a copy of the LGPLv3 License. -; -;************************************************************************* - -hasInternetConnection -- cgit From ba507c41ba991b72da34da58b6a5d61bc1a7822e Mon Sep 17 00:00:00 2001 From: Matúš Kukan Date: Wed, 21 Dec 2011 13:22:52 +0100 Subject: gbuild: WNT: register wininet library --- solenv/gbuild/platform/WNT_INTEL_GCC.mk | 1 + solenv/gbuild/platform/WNT_INTEL_MSC.mk | 1 + 2 files changed, 2 insertions(+) diff --git a/solenv/gbuild/platform/WNT_INTEL_GCC.mk b/solenv/gbuild/platform/WNT_INTEL_GCC.mk index e8fe61670e34..ac7e4be29ec9 100644 --- a/solenv/gbuild/platform/WNT_INTEL_GCC.mk +++ b/solenv/gbuild/platform/WNT_INTEL_GCC.mk @@ -284,6 +284,7 @@ gb_Library_PLAINLIBS_NONE += \ uwinapi \ winmm \ version \ + wininet \ winspool \ ws2_32 \ diff --git a/solenv/gbuild/platform/WNT_INTEL_MSC.mk b/solenv/gbuild/platform/WNT_INTEL_MSC.mk index de562a787bd6..638aade3e573 100644 --- a/solenv/gbuild/platform/WNT_INTEL_MSC.mk +++ b/solenv/gbuild/platform/WNT_INTEL_MSC.mk @@ -424,6 +424,7 @@ gb_Library_PLAINLIBS_NONE += \ uuid \ uwinapi \ version \ + wininet \ winmm \ winspool \ ws2_32 \ -- cgit From 489adacb7cef9a63a9326a55f5265bef937c4267 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 21 Dec 2011 16:52:30 +0100 Subject: Repository.mk: for libraries it's PLAINLIBS_NONE --- Repository.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Repository.mk b/Repository.mk index 4f2e8e6362fd..cbc08893f0af 100644 --- a/Repository.mk +++ b/Repository.mk @@ -105,7 +105,7 @@ endif # WITH_MOZILLA ifeq ($(OS),MACOSX) -$(eval $(call gb_Helper_register_libraries,NONE, \ +$(eval $(call gb_Helper_register_libraries,PLAINLIBS_NONE, \ OOoSpotlightImporter \ )) -- cgit From 79b252a56db8f1c2159d3269de415ffe2f2d9bb1 Mon Sep 17 00:00:00 2001 From: Peter Foley Date: Wed, 21 Dec 2011 19:37:48 -0500 Subject: add framework to tail_build --- Module_tail_build.mk | 1 + tail_build/prj/build.lst | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 764b9fc2de8c..df73553cc81f 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -45,6 +45,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\ filter \ forms \ formula \ + framework \ hwpfilter \ idl \ lingucomponent \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index 87ca96dd7a1c..f1ef4f84c1c1 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker framework javaunohelper jurt jvmaccess jvmfwk np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal salhelper sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucbhelper udkapi unoil unotools ure vcl xmlhelp xmlscript xsltml NULL +tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker javaunohelper jurt jvmaccess jvmfwk np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal salhelper sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucb ucbhelper udkapi unoil unotools ure vcl xmlhelp xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From a8bdde191c83b3cbdd7647a46ed0701d573f886c Mon Sep 17 00:00:00 2001 From: Norbert Thiebaud Date: Wed, 4 Jan 2012 01:30:44 -0600 Subject: fix sanedlg.hrc dep issue due to gbuildification of extensions --- extensions/AllLangResTarget_san.mk | 44 ------------------------------- extensions/AllLangResTarget_scn.mk | 49 +++++++++++++++++++++++++++++++++++ extensions/Module_extensions.mk | 2 +- scp2/source/ooo/file_resource_ooo.scp | 2 +- 4 files changed, 51 insertions(+), 46 deletions(-) delete mode 100644 extensions/AllLangResTarget_san.mk create mode 100644 extensions/AllLangResTarget_scn.mk diff --git a/extensions/AllLangResTarget_san.mk b/extensions/AllLangResTarget_san.mk deleted file mode 100644 index 2301f6cf7b55..000000000000 --- a/extensions/AllLangResTarget_san.mk +++ /dev/null @@ -1,44 +0,0 @@ -# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- -# -# Version: MPL 1.1 / GPLv3+ / LGPLv3+ -# -# The contents of this file are subject to the Mozilla Public License Version -# 1.1 (the "License"); you may not use this file except in compliance with -# the License or as specified alternatively below. You may obtain a copy of -# the License at http://www.mozilla.org/MPL/ -# -# Software distributed under the License is distributed on an "AS IS" basis, -# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License -# for the specific language governing rights and limitations under the -# License. -# -# Major Contributor(s): -# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] -# -# All Rights Reserved. -# -# For minor contributions see the git repository. -# -# Alternatively, the contents of this file may be used under the terms of -# either the GNU General Public License Version 3 or later (the "GPLv3+"), or -# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), -# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable -# instead of those above. -# - -$(eval $(call gb_AllLangResTarget_AllLangResTarget,san)) - -$(eval $(call gb_AllLangResTarget_set_reslocation,san,extensions/source/scanner)) - -$(eval $(call gb_AllLangResTarget_add_srs,san,\ - scn/res \ -)) - -$(eval $(call gb_SrsTarget_SrsTarget,scn/res)) - -$(eval $(call gb_SrsTarget_add_files,scn/res,\ - extensions/source/scanner/grid.src \ - extensions/source/scanner/sanedlg.src \ -)) - -# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/AllLangResTarget_scn.mk b/extensions/AllLangResTarget_scn.mk new file mode 100644 index 000000000000..8b8dde4fdb03 --- /dev/null +++ b/extensions/AllLangResTarget_scn.mk @@ -0,0 +1,49 @@ +# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*- +# +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# Major Contributor(s): +# [ Copyright (C) 2011 Red Hat, Inc., Michael Stahl (initial developer) ] +# +# All Rights Reserved. +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the "GPLv3+"), or +# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +# + +$(eval $(call gb_AllLangResTarget_AllLangResTarget,scn)) + +$(eval $(call gb_AllLangResTarget_set_reslocation,scn,extensions/source/scanner)) + +$(eval $(call gb_AllLangResTarget_add_srs,scn,\ + scn/res \ +)) + +$(eval $(call gb_SrsTarget_SrsTarget,scn/res)) + +$(eval $(call gb_SrsTarget_set_include,scn/res,\ + $$(INCLUDE) \ + -I$(SRCDIR)/extensions/source/scanner \ +)) + +$(eval $(call gb_SrsTarget_add_files,scn/res,\ + extensions/source/scanner/grid.src \ + extensions/source/scanner/sanedlg.src \ +)) + +# vim:set shiftwidth=4 softtabstop=4 expandtab: diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk index 348b95eeca95..62caaf6dafe5 100644 --- a/extensions/Module_extensions.mk +++ b/extensions/Module_extensions.mk @@ -32,7 +32,7 @@ $(eval $(call gb_Module_add_targets,extensions,\ AllLangResTarget_bib \ AllLangResTarget_dbp \ AllLangResTarget_pcr \ - AllLangResTarget_san \ + AllLangResTarget_scn \ AllLangResTarget_upd \ AllLangResTarget_updchk \ Configuration_updchk \ diff --git a/scp2/source/ooo/file_resource_ooo.scp b/scp2/source/ooo/file_resource_ooo.scp index 6a23a9f8ef77..311dd9fe158c 100644 --- a/scp2/source/ooo/file_resource_ooo.scp +++ b/scp2/source/ooo/file_resource_ooo.scp @@ -68,7 +68,7 @@ STD_RES_FILE( gid_File_Res_Pdffilter, pdffilter) #ifdef UNX -STD_RES_FILE( gid_File_Res_San, san ) +STD_RES_FILE( gid_File_Res_San, scn ) #endif -- cgit From ec7c098a28b900110413ab97ab522686d94c3d40 Mon Sep 17 00:00:00 2001 From: Norbert Thiebaud Date: Wed, 4 Jan 2012 01:31:26 -0600 Subject: afms is a dep of tail_build by virtue of ps_print now being in tail_build --- tail_build/prj/build.lst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index f1ef4f84c1c1..0c1f24dff34a 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker javaunohelper jurt jvmaccess jvmfwk np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal salhelper sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucb ucbhelper udkapi unoil unotools ure vcl xmlhelp xmlscript xsltml NULL +tb tail_build : AFMS:afms APACHE_COMMONS:apache-commons BSH:beanshell BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CURL:curl HUNSPELL:hunspell HYPHEN:hyphen ICU:icu DESKTOP:l10ntools LIBCDR:libcdr LIBEXTTEXTCAT:libexttextcat LIBXML2:libxml2 LIBXMLSEC:libxmlsec LIBXSLT:libxslt LIBWPG:libwpg LIBWPS:libwps LIBWPD:libwpd LIBVISIO:libvisio LPSOLVE:lpsolve MDDS:mdds MYTHES:mythes NEON:neon NSS:nss OPENSSL:openssl PYTHON:python REDLAND:redland SANE:sane SAXON:saxon TRANSLATIONS:translations TWAIN:twain XPDF:xpdf ZLIB:zlib basegfx bridges comphelper connectivity cppu cppuhelper DESKTOP:fpicker javaunohelper jurt jvmaccess jvmfwk np_sdk offapi officecfg oovbaapi qadevOOo DESKTOP:rdbmaker readlicense_oo rhino ridljar sal salhelper sax shell solenv soltools sot stoc svl svtools sysui test toolkit tools ucb ucbhelper udkapi unoil unotools ure vcl xmlhelp xmlscript xsltml NULL tb tail_build\prj nmake - all tb_prj NULL -- cgit From 1c6f4e6ff73034cf312662c4bda31bccd36c966b Mon Sep 17 00:00:00 2001 From: Norbert Thiebaud Date: Wed, 4 Jan 2012 01:48:49 -0600 Subject: fix dep to svx/globlmn.hrc inside of tail_build --- basctl/AllLangResTarget_basctl.mk | 2 +- dbaccess/AllLangResTarget_dbu.mk | 2 +- dbaccess/AllLangResTarget_dbui.mk | 2 +- reportdesign/AllLangResTarget_rpt.mk | 2 +- reportdesign/AllLangResTarget_rptui.mk | 2 +- sc/AllLangResTarget_sc.mk | 2 +- sd/AllLangResTarget_sd.mk | 2 +- starmath/AllLangResTarget_sm.mk | 2 +- sw/AllLangResTarget_sw.mk | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) diff --git a/basctl/AllLangResTarget_basctl.mk b/basctl/AllLangResTarget_basctl.mk index 7e588d199e50..fee9fc007f03 100644 --- a/basctl/AllLangResTarget_basctl.mk +++ b/basctl/AllLangResTarget_basctl.mk @@ -54,6 +54,6 @@ $(eval $(call gb_SrsTarget_add_files,basctl/res,\ basctl/source/dlged/managelang.src \ )) -$(call gb_SrsTarget_get_target,basctl/res) :| $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsTemplateTarget_get_target,basctl/res) : $(call gb_Package_get_target,svx_globlmn_hrc) # vim: set noet sw=4 ts=4: diff --git a/dbaccess/AllLangResTarget_dbu.mk b/dbaccess/AllLangResTarget_dbu.mk index 15b6806005c6..177bfa307a01 100644 --- a/dbaccess/AllLangResTarget_dbu.mk +++ b/dbaccess/AllLangResTarget_dbu.mk @@ -90,6 +90,6 @@ $(eval $(call gb_SrsTarget_add_templates,dbaccess/dbu,\ dbaccess/source/ui/inc/toolbox_tmpl.hrc \ )) -$(call gb_SrsTarget_get_target,dbaccess/dbu) :| $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsTemplateTarget_get_target,dbaccess/dbu) : $(call gb_Package_get_target,svx_globlmn_hrc) # vim: set noet sw=4 ts=4: diff --git a/dbaccess/AllLangResTarget_dbui.mk b/dbaccess/AllLangResTarget_dbui.mk index 7478fc2c4474..f17c96c506d6 100644 --- a/dbaccess/AllLangResTarget_dbui.mk +++ b/dbaccess/AllLangResTarget_dbui.mk @@ -92,6 +92,6 @@ $(eval $(call gb_SrsTarget_add_templates,dbaccess/dbui,\ dbaccess/source/ui/inc/toolbox_tmpl.hrc \ )) -$(call gb_SrsTarget_get_target,dbaccess/dbui) :| $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsTemplateTarget_get_target,dbaccess/dbui) : $(call gb_Package_get_target,svx_globlmn_hrc) # vim: set noet sw=4 ts=4: diff --git a/reportdesign/AllLangResTarget_rpt.mk b/reportdesign/AllLangResTarget_rpt.mk index 76baa19770df..71e2116fc24b 100644 --- a/reportdesign/AllLangResTarget_rpt.mk +++ b/reportdesign/AllLangResTarget_rpt.mk @@ -45,6 +45,6 @@ $(eval $(call gb_SrsTarget_add_files,reportdesign/res,\ reportdesign/source/core/resource/strings.src \ )) -$(call gb_SrsTarget_get_target,reportdesign/res) :| $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsTemplateTarget_get_target,reportdesign/res) : $(call gb_Package_get_target,svx_globlmn_hrc) # vim: set noet sw=4 ts=4: diff --git a/reportdesign/AllLangResTarget_rptui.mk b/reportdesign/AllLangResTarget_rptui.mk index 23edf347feb2..18674e0825bd 100644 --- a/reportdesign/AllLangResTarget_rptui.mk +++ b/reportdesign/AllLangResTarget_rptui.mk @@ -54,6 +54,6 @@ $(eval $(call gb_SrsTarget_add_files,reportdesign/rptui,\ reportdesign/source/ui/report/report.src \ )) -$(call gb_SrsTarget_get_target,reportdesign/rptui) :| $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsTemplateTarget_get_target,reportdesign/rptui) : $(call gb_Package_get_target,svx_globlmn_hrc) # vim: set noet sw=4 ts=4: diff --git a/sc/AllLangResTarget_sc.mk b/sc/AllLangResTarget_sc.mk index ce5915b3f919..57228996e9e4 100644 --- a/sc/AllLangResTarget_sc.mk +++ b/sc/AllLangResTarget_sc.mk @@ -105,6 +105,6 @@ $(eval $(call gb_SrsTarget_add_files,sc/res,\ sc/source/core/src/compiler.src \ )) -$(call gb_SrsTarget_get_target,sc/res) :| $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsTemplateTarget_get_target,sc/res) : $(call gb_Package_get_target,svx_globlmn_hrc) # vim: set noet sw=4 ts=4: diff --git a/sd/AllLangResTarget_sd.mk b/sd/AllLangResTarget_sd.mk index 25eab89e4bc5..fd2225b4515d 100644 --- a/sd/AllLangResTarget_sd.mk +++ b/sd/AllLangResTarget_sd.mk @@ -107,6 +107,6 @@ $(eval $(call gb_SrsTarget_add_templates,sd/res,\ sd/source/ui/app/toolbox2_tmpl.src \ )) -$(call gb_SrsTarget_get_target,sd/res) :| $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsTemplateTarget_get_target,sd/res) : $(call gb_Package_get_target,svx_globlmn_hrc) # vim: set noet sw=4 ts=4: diff --git a/starmath/AllLangResTarget_sm.mk b/starmath/AllLangResTarget_sm.mk index a1f31a4d11a8..3cfda797c2ce 100644 --- a/starmath/AllLangResTarget_sm.mk +++ b/starmath/AllLangResTarget_sm.mk @@ -48,6 +48,6 @@ $(eval $(call gb_SrsTarget_add_files,sm/res,\ starmath/source/toolbox.src \ )) -$(call gb_SrsTarget_get_target,sm/res) :| $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsTemplateTarget_get_target,sm/res) : $(call gb_Package_get_target,svx_globlmn_hrc) # vim: set noet sw=4 ts=4: diff --git a/sw/AllLangResTarget_sw.mk b/sw/AllLangResTarget_sw.mk index 43386be25fbf..5bb50abdcfd7 100644 --- a/sw/AllLangResTarget_sw.mk +++ b/sw/AllLangResTarget_sw.mk @@ -188,6 +188,6 @@ $(eval $(call gb_SrsTarget_add_files,sw/res,\ sw/source/ui/wrtsh/wrtsh.src \ )) -$(call gb_SrsTarget_get_target,sw/res) :| $(OUTDIR)/inc/svx/globlmn.hrc +$(call gb_SrsTemplateTarget_get_target,sw/res) :| $(call gb_Package_get_target,svx_globlmn_hrc) # vim: set noet sw=4 ts=4: -- cgit From ca6959e676984befb58b5510e9bdccc6d5fc4a7e Mon Sep 17 00:00:00 2001 From: Norbert Thiebaud Date: Wed, 4 Jan 2012 01:33:58 -0600 Subject: add PLAINLIBS_NONE in the LAYER --- solenv/gbuild/platform/macosx.mk | 1 + 1 file changed, 1 insertion(+) diff --git a/solenv/gbuild/platform/macosx.mk b/solenv/gbuild/platform/macosx.mk index ef82a823a8a8..bd92908ba770 100644 --- a/solenv/gbuild/platform/macosx.mk +++ b/solenv/gbuild/platform/macosx.mk @@ -284,6 +284,7 @@ gb_Library_LAYER := \ $(foreach lib,$(gb_Library_OOOLIBS),$(lib):OOO) \ $(foreach lib,$(gb_Library_PLAINLIBS_URE),$(lib):URELIB) \ $(foreach lib,$(gb_Library_PLAINLIBS_OOO),$(lib):OOO) \ + $(foreach lib,$(gb_Library_PLAINLIBS_NONE),$(lib):NONE) \ $(foreach lib,$(gb_Library_RTLIBS),$(lib):OOO) \ $(foreach lib,$(gb_Library_RTVERLIBS),$(lib):URELIB) \ $(foreach lib,$(gb_Library_UNOLIBS_URE),$(lib):URELIB) \ -- cgit From 381bed81e43d7fdd541115e0ab4213b0609e7ac0 Mon Sep 17 00:00:00 2001 From: Norbert Thiebaud Date: Wed, 4 Jan 2012 01:50:57 -0600 Subject: Hack to get OOoSpotlightImporter building: FIXME this is prolly not correct --- extensions/Library_OOoSpotlightImporter.mk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/extensions/Library_OOoSpotlightImporter.mk b/extensions/Library_OOoSpotlightImporter.mk index 639b381bea81..f8a4c3c39707 100644 --- a/extensions/Library_OOoSpotlightImporter.mk +++ b/extensions/Library_OOoSpotlightImporter.mk @@ -44,8 +44,9 @@ $(eval $(call gb_Library_add_ldflags,OOoSpotlightImporter,\ -framework CoreFoundation \ -framework Foundation \ -framework CoreServices \ - -bundle \ )) +# -bundle \ + $(eval $(call gb_Library_use_external,OOoSpotlightImporter,zlib)) -- cgit From 81151f6861eeb24c356f6fb544a78e4459070bf3 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 4 Jan 2012 16:02:54 +0100 Subject: gbuild: macosx.mk: enable -fobjc-exceptions Add it to gb_OBJCFLAGS, just like in old solenv/inc/unxmacx.mk. --- solenv/gbuild/platform/macosx.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/solenv/gbuild/platform/macosx.mk b/solenv/gbuild/platform/macosx.mk index bd92908ba770..114dd16a7e85 100644 --- a/solenv/gbuild/platform/macosx.mk +++ b/solenv/gbuild/platform/macosx.mk @@ -84,7 +84,7 @@ endif # (see toolkit module for a case where it is necessary to do it this way) gb_OBJCXXFLAGS := -x objective-c++ -fobjc-exceptions -gb_OBJCFLAGS := -x objective-c +gb_OBJCFLAGS := -x objective-c -fobjc-exceptions gb_LinkTarget_LDFLAGS := \ -Wl,-syslibroot,$(gb_SDKDIR) \ -- cgit From 0dd3e081fbea5b917d4635de9b5cf15db217063c Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 4 Jan 2012 21:29:11 +0100 Subject: gbuild: macosx.mk: add gb_Library_Bundle ...and use it to build OOoSpotlightImporter. This isn't particularly elegant, but then again, why the heck does dyld have different dynamic library types in the first place? --- extensions/Library_OOoSpotlightImporter.mk | 4 +--- solenv/gbuild/platform/macosx.mk | 13 +++++++++++-- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/extensions/Library_OOoSpotlightImporter.mk b/extensions/Library_OOoSpotlightImporter.mk index f8a4c3c39707..336cf4d93624 100644 --- a/extensions/Library_OOoSpotlightImporter.mk +++ b/extensions/Library_OOoSpotlightImporter.mk @@ -28,7 +28,7 @@ # instead of those above. # -$(eval $(call gb_Library_Library,OOoSpotlightImporter)) +$(eval $(call gb_Library_Bundle,OOoSpotlightImporter)) $(eval $(call gb_Library_add_objcobjects,OOoSpotlightImporter,\ extensions/source/macosx/spotlight/GetMetadataForFile \ @@ -45,8 +45,6 @@ $(eval $(call gb_Library_add_ldflags,OOoSpotlightImporter,\ -framework Foundation \ -framework CoreServices \ )) -# -bundle \ - $(eval $(call gb_Library_use_external,OOoSpotlightImporter,zlib)) diff --git a/solenv/gbuild/platform/macosx.mk b/solenv/gbuild/platform/macosx.mk index 114dd16a7e85..7b2517b13fa8 100644 --- a/solenv/gbuild/platform/macosx.mk +++ b/solenv/gbuild/platform/macosx.mk @@ -187,6 +187,7 @@ $(call gb_Helper_abbreviate_dirs,\ DYLIB_FILE=`$(gb_MKTEMP)` && \ $(PERL) $(SOLARENV)/bin/macosx-dylib-link-list.pl \ $(if $(filter Executable,$(TARGETTYPE)),$(gb_Executable_TARGETTYPEFLAGS)) \ + $(if $(filter Bundle,$(TARGETTYPE)),$(gb_Bundle_TARGETTYPEFLAGS)) \ $(if $(filter Library CppunitTest,$(TARGETTYPE)),$(gb_Library_TARGETTYPEFLAGS)) \ $(if $(filter Library,$(TARGETTYPE)),$(gb_Library_LTOFLAGS)) \ $(subst \d,$$,$(RPATH)) \ @@ -194,6 +195,7 @@ $(call gb_Helper_abbreviate_dirs,\ $(patsubst lib%.dylib,-l%,$(foreach lib,$(LINKED_LIBS),$(call gb_Library_get_filename,$(lib)))) > $${DYLIB_FILE} && \ $(gb_CXX) \ $(if $(filter Executable,$(TARGETTYPE)),$(gb_Executable_TARGETTYPEFLAGS)) \ + $(if $(filter Bundle,$(TARGETTYPE)),$(gb_Bundle_TARGETTYPEFLAGS)) \ $(if $(filter Library CppunitTest,$(TARGETTYPE)),$(gb_Library_TARGETTYPEFLAGS)) \ $(if $(filter Library,$(TARGETTYPE)),$(gb_Library_LTOFLAGS)) \ $(subst \d,$$,$(RPATH)) \ @@ -214,7 +216,7 @@ $(call gb_Helper_abbreviate_dirs,\ $(if $(filter Executable,$(TARGETTYPE)), \ $(PERL) $(SOLARENV)/bin/macosx-change-install-names.pl Executable \ $(LAYER) $(1) &&) \ - $(if $(filter Library CppunitTest,$(TARGETTYPE)),\ + $(if $(filter Library Bundle CppunitTest,$(TARGETTYPE)),\ $(PERL) $(SOLARENV)/bin/macosx-change-install-names.pl Library $(LAYER) $(if $(SOVERSION),$(1).$(SOVERSION),$(1)) && \ ln -sf $(1) $(patsubst %.dylib,%.jnilib,$(1)) &&) \ rm -f $${DYLIB_FILE}) @@ -237,7 +239,7 @@ endef define gb_LinkTarget__command $(call gb_Output_announce,$(2),$(true),LNK,4) -$(if $(filter Library CppunitTest Executable,$(TARGETTYPE)),$(call gb_LinkTarget__command_dynamiclink,$(1),$(2))) +$(if $(filter Library Bundle CppunitTest Executable,$(TARGETTYPE)),$(call gb_LinkTarget__command_dynamiclink,$(1),$(2))) $(if $(filter StaticLibrary,$(TARGETTYPE)),$(call gb_LinkTarget__command_staticlink,$(1))) endef @@ -246,6 +248,7 @@ endef gb_Library_DEFS := gb_Library_TARGETTYPEFLAGS := -dynamiclib -single_module +gb_Bundle_TARGETTYPEFLAGS := -bundle gb_Library_SYSPRE := lib gb_Library_UNOVERPRE := $(gb_Library_SYSPRE)uno_ gb_Library_PLAINEXT := .dylib @@ -305,6 +308,12 @@ endef gb_Library__set_soversion_script_platform = $(gb_Library__set_soversion_script) +# bundle is a special kind of library that exists only on Darwin/OSX +# set the TARGETTYPE to Bundle +define gb_Library_Bundle +$(call gb_Library_Library,$(1)) +$(call gb_LinkTarget_set_targettype,$(call gb_Library_get_linktargetname,$(1)),Bundle) +endef # StaticLibrary class -- cgit From 7e5b321535977ccddc6703c0ad4e5d25af797654 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Fri, 6 Jan 2012 19:44:33 +0100 Subject: gbuild: macosx.mk: Bundles have no install_name --- solenv/gbuild/platform/macosx.mk | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/solenv/gbuild/platform/macosx.mk b/solenv/gbuild/platform/macosx.mk index 7b2517b13fa8..e693ecf7ba80 100644 --- a/solenv/gbuild/platform/macosx.mk +++ b/solenv/gbuild/platform/macosx.mk @@ -309,10 +309,12 @@ endef gb_Library__set_soversion_script_platform = $(gb_Library__set_soversion_script) # bundle is a special kind of library that exists only on Darwin/OSX -# set the TARGETTYPE to Bundle +# set the TARGETTYPE to Bundle, and clear install_name(RPATH) define gb_Library_Bundle $(call gb_Library_Library,$(1)) $(call gb_LinkTarget_set_targettype,$(call gb_Library_get_linktargetname,$(1)),Bundle) +$(call gb_LinkTarget_get_target,$(call gb_Library_get_linktargetname,$(1))) : \ + RPATH := endef # StaticLibrary class -- cgit