Repository.mk | 1 filter/Executable_svg2odf.mk | 47 ++++++++++++++++++++++++ filter/Library_svgfilter.mk | 5 ++ filter/Module_filter.mk | 1 filter/inc/filter/dllapi.h | 49 ++++++++++++++++++++++++++ filter/source/svg/svgreader.hxx | 6 ++- framework/source/uielement/toolbarmanager.cxx | 22 +---------- 7 files changed, 110 insertions(+), 21 deletions(-)
New commits: commit 2a63c47b5b60551d44ee20983fd422d502e29be4 Author: Jan Holesovsky <ke...@suse.cz> Date: Sat Apr 14 15:35:12 2012 +0200 Build svg2odf tool to be able to test the svg import. diff --git a/Repository.mk b/Repository.mk index e46f6b1..f0c5965 100644 --- a/Repository.mk +++ b/Repository.mk @@ -47,6 +47,7 @@ $(eval $(call gb_Helper_register_executables,NONE, \ saxparser \ so_checksum \ sp2bv \ + svg2odf \ svidl \ typesconfig \ xml2cmp \ diff --git a/filter/Executable_svg2odf.mk b/filter/Executable_svg2odf.mk new file mode 100644 index 0000000..794edb9 --- /dev/null +++ b/filter/Executable_svg2odf.mk @@ -0,0 +1,47 @@ +# -*- Mode: makefile-gmake; 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 Jan Holesovsky <ke...@suse.cz>, SUSE +# (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_Executable_Executable,svg2odf)) + +$(eval $(call gb_Executable_set_targettype_gui,svg2odf,YES)) + +$(eval $(call gb_Executable_use_api,svg2odf,\ + offapi \ + udkapi \ +)) + +$(eval $(call gb_Executable_use_libraries,svg2odf,\ + svgfilter \ + $(gb_STDLIBS) \ +)) + +$(eval $(call gb_Executable_add_cxxobjects,svg2odf,\ + filter/source/svg/test/svg2odf \ + filter/source/svg/test/odfserializer \ +)) + +# vim: set ts=4 sw=4 et: diff --git a/filter/Library_svgfilter.mk b/filter/Library_svgfilter.mk index b5ebe23..c37938f 100644 --- a/filter/Library_svgfilter.mk +++ b/filter/Library_svgfilter.mk @@ -27,6 +27,11 @@ $(eval $(call gb_Library_add_defs,svgfilter,\ -DUSE_MODERN_SPIRIT \ )) +$(eval $(call gb_Library_set_include,svgfilter,\ + $$(INCLUDE) \ + -I$(SRCDIR)/filter/inc \ +)) + $(eval $(call gb_Library_use_api,svgfilter,\ udkapi \ offapi \ diff --git a/filter/Module_filter.mk b/filter/Module_filter.mk index 9bcfe3b..03f13e2 100644 --- a/filter/Module_filter.mk +++ b/filter/Module_filter.mk @@ -27,6 +27,7 @@ $(eval $(call gb_Module_add_targets,filter,\ AllLangResTarget_xsltdlg \ Configuration_filter \ CustomTarget_svg \ + Executable_svg2odf \ Library_PptImporter \ Library_egi \ Library_eme \ diff --git a/filter/inc/filter/dllapi.h b/filter/inc/filter/dllapi.h new file mode 100644 index 0000000..16ff305 --- /dev/null +++ b/filter/inc/filter/dllapi.h @@ -0,0 +1,49 @@ +/* -*- 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 + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef _FILTER_DLLAPI_H +#define _FILTER_DLLAPI_H + +#include "sal/config.h" +#include "sal/types.h" + +#if defined FILTER_DLLIMPLEMENTATION +#define FILTER_DLLPUBLIC SAL_DLLPUBLIC_EXPORT +#else +#define FILTER_DLLPUBLIC SAL_DLLPUBLIC_IMPORT +#endif + +#if defined UNX && ! defined MACOS +#define FILTER_PLUGIN_PUBLIC FILTER_DLLPUBLIC +#else +#define FILTER_PLUGIN_PUBLIC SAL_DLLPRIVATE +#endif + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/filter/source/svg/svgreader.hxx b/filter/source/svg/svgreader.hxx index 67318f3..ec250bc 100644 --- a/filter/source/svg/svgreader.hxx +++ b/filter/source/svg/svgreader.hxx @@ -27,6 +27,8 @@ #ifndef INCLUDED_SVGREADER_HXX #define INCLUDED_SVGREADER_HXX +#include <filter/dllapi.h> + #include <com/sun/star/uno/XComponentContext.hpp> #include <com/sun/star/lang/XMultiServiceFactory.hpp> #include <com/sun/star/xml/sax/XDocumentHandler.hpp> @@ -42,11 +44,11 @@ class SVGReader const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XDocumentHandler > m_xDocumentHandler; public: - SVGReader( const com::sun::star::uno::Reference<com::sun::star::lang::XMultiServiceFactory>& xServiceFactory, + FILTER_DLLPUBLIC SVGReader( const com::sun::star::uno::Reference<com::sun::star::lang::XMultiServiceFactory>& xServiceFactory, const com::sun::star::uno::Reference< com::sun::star::io::XInputStream >& xInputStream, const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XDocumentHandler >& xDocumentHandler ); - sal_Bool parseAndConvert(); + FILTER_DLLPUBLIC sal_Bool parseAndConvert(); }; } // namespace svgi commit bca961b855c638bb6863a663972121d4414c64a7 Author: Jan Holesovsky <ke...@suse.cz> Date: Sat Apr 14 10:58:32 2012 +0200 Simplify the construction of the '>>' menu. diff --git a/framework/source/uielement/toolbarmanager.cxx b/framework/source/uielement/toolbarmanager.cxx index 4fe4712..e3e5950 100644 --- a/framework/source/uielement/toolbarmanager.cxx +++ b/framework/source/uielement/toolbarmanager.cxx @@ -1872,25 +1872,9 @@ IMPL_LINK( ToolBarManager, MenuButton, ToolBox*, pToolBar ) if ( m_bDisposed ) return 1; - PopupMenu * pMenu = GetToolBarCustomMenu(pToolBar); - if (pMenu) - { - sal_uInt16 nObsoleteItems = 6; - sal_uInt16 positionInMenu; - sal_uInt32 obsoleteItems[] = { MENUITEM_TOOLBAR_CLOSE , - MENUITEM_TOOLBAR_VISIBLEBUTTON , - MENUITEM_TOOLBAR_CUSTOMIZETOOLBAR, - MENUITEM_TOOLBAR_LOCKTOOLBARPOSITION, - MENUITEM_TOOLBAR_DOCKTOOLBAR, - MENUITEM_TOOLBAR_DOCKALLTOOLBAR - }; - for( int i = 0 ; i < nObsoleteItems ; i++ ) - { - positionInMenu = pMenu->GetItemPos( obsoleteItems[i] ); - if ( positionInMenu != MENU_ITEM_NOTFOUND ) - pMenu->RemoveItem( positionInMenu ); - } - } + pToolBar->UpdateCustomMenu(); + // remove all entries that do not come from the toolbar itself (fdo#38276) + ImplClearPopupMenu( pToolBar ); return 0; } _______________________________________________ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits