[Libreoffice-commits] .: 3 commits - framework/inc salhelper/CppunitTest_salhelper_testapi.mk salhelper/qa scripting/examples
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Wed Oct 10 02:03:17 PDT 2012
framework/inc/queries.h | 44 ++++++----
salhelper/CppunitTest_salhelper_testapi.mk | 2
salhelper/qa/makefile.mk | 43 ---------
salhelper/qa/version.map | 24 -----
scripting/examples/javascript/Highlight/parcel-descriptor.xml | 4
5 files changed, 30 insertions(+), 87 deletions(-)
New commits:
commit 168bd09c6bf2e27b108325899c995bc330f7f640
Author: Caolán McNamara <caolanm at redhat.com>
Date: Wed Oct 10 10:02:29 2012 +0100
try and make mingw32 build
Change-Id: I64c884b6d14c7112a88c7741ef7688108ec80ffe
diff --git a/salhelper/CppunitTest_salhelper_testapi.mk b/salhelper/CppunitTest_salhelper_testapi.mk
index ae80042..606827a 100644
--- a/salhelper/CppunitTest_salhelper_testapi.mk
+++ b/salhelper/CppunitTest_salhelper_testapi.mk
@@ -27,7 +27,7 @@ $(eval $(call gb_CppunitTest_set_include,salhelper_testapi,\
$(eval $(call gb_CppunitTest_use_libraries,salhelper_testapi,\
salhelper \
sal \
- $(gb_STDLIBS) \
+ $(gb_UWINAPI) \
))
# vim: set noet sw=4 ts=4:
diff --git a/salhelper/qa/makefile.mk b/salhelper/qa/makefile.mk
deleted file mode 100644
index c359a46..0000000
--- a/salhelper/qa/makefile.mk
+++ /dev/null
@@ -1,43 +0,0 @@
-#
-# This file is part of the LibreOffice project.
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-#
-# This file incorporates work covered by the following license notice:
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed
-# with this work for additional information regarding copyright
-# ownership. The ASF licenses this file to you under the Apache
-# License, Version 2.0 (the "License"); you may not use this file
-# except in compliance with the License. You may obtain a copy of
-# the License at http://www.apache.org/licenses/LICENSE-2.0 .
-#
-
-PRJ := ..
-PRJNAME := salhelper
-TARGET := qa
-
-ENABLE_EXCEPTIONS := TRUE
-
-.INCLUDE: settings.mk
-
-CFLAGSCXX += $(CPPUNIT_CFLAGS)
-
-SHL1TARGET = $(TARGET)
-SHL1OBJS = $(SLO)$/test_api.obj
-SHL1STDLIBS = $(CPPUNITLIB) $(SALLIB) $(SALHELPERLIB)
-SHL1IMPLIB = i$(SHL1TARGET)
-SHL1VERSIONMAP = version.map
-DEF1NAME = $(SHL1TARGET)
-
-SLOFILES = $(SHL1OBJS)
-
-.INCLUDE: target.mk
-
-ALLTAR: test
-
-test .PHONY: $(SHL1TARGETN)
- cd $(SHL1TARGETN:d) && $(TESTSHL2) $(SHL1TARGETN:f)
diff --git a/salhelper/qa/version.map b/salhelper/qa/version.map
deleted file mode 100644
index 878fdc5..0000000
--- a/salhelper/qa/version.map
+++ /dev/null
@@ -1,24 +0,0 @@
-#
-# This file is part of the LibreOffice project.
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-#
-# This file incorporates work covered by the following license notice:
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed
-# with this work for additional information regarding copyright
-# ownership. The ASF licenses this file to you under the Apache
-# License, Version 2.0 (the "License"); you may not use this file
-# except in compliance with the License. You may obtain a copy of
-# the License at http://www.apache.org/licenses/LICENSE-2.0 .
-#
-
-UDK_3_0_0 {
- global:
- registerAllTestFunction;
- local:
- *;
-};
commit 77cb1ca382520f52b9a87d13f8a1a511e5554946
Author: Caolán McNamara <caolanm at redhat.com>
Date: Wed Oct 10 09:48:42 2012 +0100
Fix "Content is not allowed in prolog" warning
One of the javascript examples parcel-descriptor.xml ended up with a c++
comment instead of a xml comment
Change-Id: Ie63a30e19de2caae08e9a489b6592e1046037416
diff --git a/scripting/examples/javascript/Highlight/parcel-descriptor.xml b/scripting/examples/javascript/Highlight/parcel-descriptor.xml
index 9c42a72..e6d6bb7 100644
--- a/scripting/examples/javascript/Highlight/parcel-descriptor.xml
+++ b/scripting/examples/javascript/Highlight/parcel-descriptor.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-/*
+<!--
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
@@ -15,7 +15,7 @@
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
+-->
<parcel language="JavaScript" xmlns:parcel="scripting.dtd">
<script language="JavaScript">
<locale lang="en">
commit a999422d4c83fa32abf0adee7286b9f6fdffa3e9
Author: Caolán McNamara <caolanm at redhat.com>
Date: Wed Oct 10 09:35:55 2012 +0100
loplugin: unused O[U]Strings and misleading else placement
Change-Id: Ifa11ada39c8d4ca29e3c90db18e5bbe618634131
diff --git a/framework/inc/queries.h b/framework/inc/queries.h
index bba7c18..97d12fa 100644
--- a/framework/inc/queries.h
+++ b/framework/inc/queries.h
@@ -249,20 +249,30 @@ class QueryAnalyzer
// Analyze query ...
// Try to find base of it and safe it for faster access as enum value!
- sal_Int32 nToken = 0;
- ::rtl::OUString sParam ;
- ::rtl::OUString sBase = sNewQuery.getToken( 0, SEPERATOR_QUERYPARAM, nToken );
-
- if( sBase.equalsIgnoreAsciiCase( BASE_QUERY_ALL ) == sal_True ) m_eQuery = E_ALL ; else
- if( sBase.equalsIgnoreAsciiCase( BASE_QUERY_WRITER ) == sal_True ) m_eQuery = E_WRITER ; else
- if( sBase.equalsIgnoreAsciiCase( BASE_QUERY_WEB ) == sal_True ) m_eQuery = E_WEB ; else
- if( sBase.equalsIgnoreAsciiCase( BASE_QUERY_GLOBAL ) == sal_True ) m_eQuery = E_GLOBAL ; else
- if( sBase.equalsIgnoreAsciiCase( BASE_QUERY_CHART ) == sal_True ) m_eQuery = E_CHART ; else
- if( sBase.equalsIgnoreAsciiCase( BASE_QUERY_CALC ) == sal_True ) m_eQuery = E_CALC ; else
- if( sBase.equalsIgnoreAsciiCase( BASE_QUERY_IMPRESS ) == sal_True ) m_eQuery = E_IMPRESS ; else
- if( sBase.equalsIgnoreAsciiCase( BASE_QUERY_DRAW ) == sal_True ) m_eQuery = E_DRAW ; else
- if( sBase.equalsIgnoreAsciiCase( BASE_QUERY_MATH ) == sal_True ) m_eQuery = E_MATH ; else
- if( sBase.equalsIgnoreAsciiCase( BASE_QUERY_GRAPHICS ) == sal_True ) m_eQuery = E_GRAPHICS ;
+ sal_Int32 nToken = 0;
+ OUString sParam;
+ OUString sBase = sNewQuery.getToken( 0, SEPERATOR_QUERYPARAM, nToken );
+
+ if (sBase.equalsIgnoreAsciiCase(BASE_QUERY_ALL))
+ m_eQuery = E_ALL;
+ else if( sBase.equalsIgnoreAsciiCase(BASE_QUERY_WRITER))
+ m_eQuery = E_WRITER;
+ else if( sBase.equalsIgnoreAsciiCase(BASE_QUERY_WEB))
+ m_eQuery = E_WEB;
+ else if( sBase.equalsIgnoreAsciiCase(BASE_QUERY_GLOBAL))
+ m_eQuery = E_GLOBAL;
+ else if( sBase.equalsIgnoreAsciiCase(BASE_QUERY_CHART))
+ m_eQuery = E_CHART;
+ else if( sBase.equalsIgnoreAsciiCase(BASE_QUERY_CALC))
+ m_eQuery = E_CALC;
+ else if( sBase.equalsIgnoreAsciiCase(BASE_QUERY_IMPRESS))
+ m_eQuery = E_IMPRESS;
+ else if( sBase.equalsIgnoreAsciiCase(BASE_QUERY_DRAW))
+ m_eQuery = E_DRAW;
+ else if( sBase.equalsIgnoreAsciiCase(BASE_QUERY_MATH))
+ m_eQuery = E_MATH;
+ else if( sBase.equalsIgnoreAsciiCase(BASE_QUERY_GRAPHICS))
+ m_eQuery = E_GRAPHICS;
// Try to get additional parameters ...
while( nToken >= 0 )
@@ -296,7 +306,7 @@ class QueryAnalyzer
if( sParam.compareTo( QUERYPARAM_IFLAGS, QUERYPARAM_IFLAGS.getLength() ) == 0 )
{
sal_Int32 nSubToken = 0;
- ::rtl::OUString sParamName = sParam.getToken( 0, SEPERATOR_QUERYPARAMVALUE, nSubToken );
+ sParam.getToken( 0, SEPERATOR_QUERYPARAMVALUE, nSubToken );
if( nSubToken > 0 )
{
m_nIFlags = sParam.getToken( 0, SEPERATOR_QUERYPARAMVALUE, nSubToken ).toInt32();
@@ -307,7 +317,7 @@ class QueryAnalyzer
if( sParam.compareTo( QUERYPARAM_EFLAGS, QUERYPARAM_EFLAGS.getLength() ) == 0 )
{
sal_Int32 nSubToken = 0;
- ::rtl::OUString sParamName = sParam.getToken( 0, SEPERATOR_QUERYPARAMVALUE, nSubToken );
+ sParam.getToken( 0, SEPERATOR_QUERYPARAMVALUE, nSubToken );
if( nSubToken > 0 )
{
m_nEFlags = sParam.getToken( 0, SEPERATOR_QUERYPARAMVALUE, nSubToken ).toInt32();
@@ -318,7 +328,7 @@ class QueryAnalyzer
if( sParam.compareTo( QUERYPARAM_SORT_PROP, QUERYPARAM_SORT_PROP.getLength() ) == 0 )
{
sal_Int32 nSubToken = 0;
- ::rtl::OUString sParamName = sParam.getToken( 0, SEPERATOR_QUERYPARAMVALUE, nSubToken );
+ sParam.getToken( 0, SEPERATOR_QUERYPARAMVALUE, nSubToken );
if( nSubToken > 0 )
{
::rtl::OUString sParamValue = sParam.getToken( 0, SEPERATOR_QUERYPARAMVALUE, nSubToken );
More information about the Libreoffice-commits
mailing list