[Libreoffice-commits] .: oox/source

2011-11-02 Thread Muthu Subramanian
 oox/source/drawingml/chart/seriesconverter.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit b645f9195f4da3014e001fb27b8a117d89c8f389
Author: Muthu Subramanian sumu...@suse.com
Date:   Wed Nov 2 13:50:20 2011 +0530

n#706792: Fix crash while opening certain pptx files.

diff --git a/oox/source/drawingml/chart/seriesconverter.cxx 
b/oox/source/drawingml/chart/seriesconverter.cxx
index 8a98471..3ed07e6 100644
--- a/oox/source/drawingml/chart/seriesconverter.cxx
+++ b/oox/source/drawingml/chart/seriesconverter.cxx
@@ -196,7 +196,7 @@ void DataLabelConverter::convertFromModel( const Reference 
XDataSeries  rxDat
 PropertySet aPropSet( rxDataSeries-getDataPointByIndex( 
mrModel.mnIndex ) );
 lclConvertLabelFormatting( aPropSet, getFormatter(), mrModel, 
rTypeGroup, false );
 
-if( !mrModel.mxLayout-mbAutoLayout )
+if( mrModel.mxLayout  !mrModel.mxLayout-mbAutoLayout )
 {
 // bnc#694340 - nasty hack - chart2 cannot individually
 // place data labels, let's try to find a useful
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: 3 commits - solenv/gbuild

2011-11-02 Thread Stephan Bergmann
 solenv/gbuild/ComponentsTarget.mk |   77 ++
 solenv/gbuild/Jar.mk  |3 -
 solenv/gbuild/TargetLocations.mk  |2 
 solenv/gbuild/UnoApiTarget.mk |4 -
 solenv/gbuild/gbuild.mk   |3 +
 5 files changed, 84 insertions(+), 5 deletions(-)

New commits:
commit ea5021e2d7db54be402c99ee551b470b95f1e92b
Author: Stephan Bergmann sberg...@redhat.com
Date:   Wed Nov 2 09:05:57 2011 +0100

Add gbuild support for .components files.

diff --git a/solenv/gbuild/ComponentsTarget.mk 
b/solenv/gbuild/ComponentsTarget.mk
new file mode 100644
index 000..686a7ee
--- /dev/null
+++ b/solenv/gbuild/ComponentsTarget.mk
@@ -0,0 +1,77 @@
+#
+# 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 Stephan Bergmann, Red Hat sberg...@redhat.com (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.
+#
+
+# Create a .components file bundling multiple .component files:
+
+# $(1): ID of this components entity (a relative pathname without .components
+#  extension)
+define gb_ComponentsTarget_ComponentsTarget
+$(call gb_ComponentsTarget_get_target,$(1)): \
+$(call gb_ComponentsTarget_get_target,$(1)).input
+$(call gb_ComponentsTarget_get_target,$(1)).input: COMPONENTFILES :=
+$(eval $(call gb_Module_register_target,$(call 
gb_ComponentsTarget_get_target,$(1)),$(call 
gb_ComponentsTarget_get_clean_target,$(1
+
+endef
+
+# $(1): ID of this components entity
+# $(2): absolute .component pathname (must be underneath $(WORKDIR) due to the
+#  --stringparam prefix approach of $(SOLARENV)/bin/packcomponents.xslt)
+define gb_ComponentsTarget_add_componentfile
+$(call gb_ComponentsTarget_get_target,$(1)): $(2)
+$(call gb_ComponentsTarget_get_target,$(1)).input: COMPONENTFILES += $(2)
+
+endef
+
+$(call gb_ComponentsTarget_get_target,%): \
+$(call gb_ComponentsTarget_get_target,%).input
+   $(call gb_Output_announce,$*,$(true),CPS,1)
+   $(call gb_Helper_abbreviate_dirs_native, \
+mkdir -p $(dir $@))
+   $(call gb_Helper_abbreviate_dirs_native, \
+$(gb_XSLTPROC) --nonet --stringparam prefix $(WORKDIR) -o $@ \
+$(SOLARENV)/bin/packcomponents.xslt $@.input)
+
+$(call gb_ComponentsTarget_get_clean_target,%): \
+$(call gb_ComponentsTarget_get_clean_target,%).input
+   $(call gb_Output_announce,$*,$(false),CPS,1)
+   $(call gb_Helper_abbreviate_dirs_native, \
+rm -f $(call gb_ComponentsTarget_get_target,$*))
+
+$(call gb_ComponentsTarget_get_target,%).input:
+   $(call gb_Output_announce,$*,$(true),CPI,1)
+   $(call gb_Helper_abbreviate_dirs_native, \
+mkdir -p $(dir $@))
+   $(call gb_Helper_abbreviate_dirs_native, \
+printf 'list%s/list' \
+$(foreach i,$(COMPONENTFILES),filename$(subst 
$(WORKDIR),,$i)/filename) \
+ $@)
+
+$(call gb_ComponentsTarget_get_clean_target,%).input:
+   $(call gb_Output_announce,$*,$(false),CPI,1)
+   $(call gb_Helper_abbreviate_dirs_native, \
+rm -f $(call gb_ComponentsTarget_get_target,$*).input)
diff --git a/solenv/gbuild/TargetLocations.mk b/solenv/gbuild/TargetLocations.mk
index 9205d44..fe907b1 100644
--- a/solenv/gbuild/TargetLocations.mk
+++ b/solenv/gbuild/TargetLocations.mk
@@ -72,6 +72,7 @@ gb_CObject_get_target = $(WORKDIR)/CObject/$(1).o
 gb_GenCObject_get_target = $(WORKDIR)/GenCObject/$(1).o
 gb_ComponentTarget_get_target = $(WORKDIR)/ComponentTarget/$(1).component
 gb_ComponentTarget_get_inbuild_target = 
$(WORKDIR)/ComponentTarget/$(1).inbuild.component
+gb_ComponentsTarget_get_target = $(WORKDIR)/ComponentsTarget/$(1).components
 gb_CppunitTest_get_target = $(WORKDIR)/CppunitTest/$(1).test
 gb_CustomTarget_get_repo_target = $(WORKDIR)/CustomTarget/$(2)_$(1).done
 gb_CustomTarget_get_target = $(WORKDIR)/CustomTarget/$(1).done
@@ -155,6 +156,7 @@ endef
 $(eval $(call gb_Helper_make_clean_targets,\
AllLangResTarget \
ComponentTarget \
+   ComponentsTarget \
Extension \
JavaClassSet \
Jar \

[Libreoffice-commits] .: Branch 'libreoffice-3-4' - sal/qa

2011-11-02 Thread Stephan Bergmann
 sal/qa/osl/security/osl_Security.cxx |   30 +-
 1 file changed, 1 insertion(+), 29 deletions(-)

New commits:
commit bc9b86940a707e9e2e1076f2954f38075398b5d7
Author: Francois Tigeot ftig...@wolfpond.org
Date:   Wed May 11 13:48:17 2011 +0200

Remove the ::osl::Security getHomeDir() check

It serves no useful purpose and breaks the build under some packaging
systems such as pkgsrc.

(Cherry-picked from 
http://cgit.freedesktop.org/libreoffice/core/commit/?id=84d10c7cda75b58384d1bbcd4022c3056002813d.)

Signed-off-by: Stephan Bergmann sberg...@redhat.com

diff --git a/sal/qa/osl/security/osl_Security.cxx 
b/sal/qa/osl/security/osl_Security.cxx
index 93fa96a..a90d2f0 100644
--- a/sal/qa/osl/security/osl_Security.cxx
+++ b/sal/qa/osl/security/osl_Security.cxx
@@ -197,30 +197,6 @@ namespace osl_Security
 }; // class getUserName
 
 
-
-/** testing the method:
-inline sal_Bool SAL_CALL getHomeDir( ::rtl::OUString strDirectory) 
const;
-*/
-class getHomeDir : public CppUnit::TestFixture
-{
-public:
-sal_Bool bRes, bRes1;
-
-void getHomeDir_001( )
-{
-::osl::Security aSec;
-::rtl::OUString strHome;
-bRes = aSec.getHomeDir( strHome );
-
-CPPUNIT_ASSERT_MESSAGE( #test comment#: getHomeDir and compare it 
with the info we get at the beginning.,
- ( sal_True == strHomeDirectory.equals( 
strHome ) )  ( sal_True == bRes ) );
-}
-
-CPPUNIT_TEST_SUITE( getHomeDir );
-CPPUNIT_TEST( getHomeDir_001 );
-CPPUNIT_TEST_SUITE_END( );
-}; // class getHomeDir
-
 /** testing the method:
 inline sal_Bool Security::getConfigDir( rtl::OUString strDirectory ) 
const
 */
@@ -341,7 +317,6 @@ CPPUNIT_TEST_SUITE_REGISTRATION(osl_Security::ctors);
 CPPUNIT_TEST_SUITE_REGISTRATION(osl_Security::logonUser);
 CPPUNIT_TEST_SUITE_REGISTRATION(osl_Security::getUserIdent);
 CPPUNIT_TEST_SUITE_REGISTRATION(osl_Security::getUserName);
-CPPUNIT_TEST_SUITE_REGISTRATION(osl_Security::getHomeDir);
 CPPUNIT_TEST_SUITE_REGISTRATION(osl_Security::getConfigDir);
 CPPUNIT_TEST_SUITE_REGISTRATION(osl_Security::isAdministrator);
 CPPUNIT_TEST_SUITE_REGISTRATION(osl_Security::getHandle);
@@ -393,11 +368,8 @@ void MyTestPlugInImpl::initialize( 
CPPUNIT_NS::TestFactoryRegistry *,
 strUserName = ::rtl::OUString::createFromAscii( pw-pw_name );
 
 /// get home directory;
-char *pw_dir = pw-pw_dir;
-if( getenv( FAKEROOTKEY ) )
-pw_dir = getenv(HOME);
 CPPUNIT_ASSERT_MESSAGE( #Convert from system path to URL failed.,
-::osl::File::E_None == 
::osl::File::getFileURLFromSystemPath( ::rtl::OUString::createFromAscii( pw_dir 
), strHomeDirectory ) );
+::osl::File::E_None == 
::osl::File::getFileURLFromSystemPath( ::rtl::OUString::createFromAscii( 
pw-pw_dir ), strHomeDirectory ) );
 
 /// get config directory;
 strConfigDirectory = strHomeDirectory.copy(0);
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: cppuhelper/source

2011-11-02 Thread Stephan Bergmann
 cppuhelper/source/bootstrap.cxx |   68 
 1 file changed, 22 insertions(+), 46 deletions(-)

New commits:
commit 793274a6cf555cb2af783a0ec6da14bbc6547a77
Author: Stephan Bergmann sberg...@redhat.com
Date:   Wed Nov 2 10:36:50 2011 +0100

Minor clean up.

diff --git a/cppuhelper/source/bootstrap.cxx b/cppuhelper/source/bootstrap.cxx
index 0da5cb0..90a16af 100644
--- a/cppuhelper/source/bootstrap.cxx
+++ b/cppuhelper/source/bootstrap.cxx
@@ -38,9 +38,6 @@
 #include rtl/string.hxx
 #include rtl/ustrbuf.hxx
 #include rtl/uri.hxx
-#if OSL_DEBUG_LEVEL  0
-#include rtl/strbuf.hxx
-#endif
 #include osl/diagnose.h
 #include osl/file.hxx
 #include osl/module.hxx
@@ -150,7 +147,7 @@ inline beans::PropertyValue createPropertyValue(
 name, -1, makeAny( value ), beans::PropertyState_DIRECT_VALUE );
 }
 
-OUString findBoostrapArgument(
+OUString findBootstrapArgument(
 const Bootstrap  bootstrap,
 const OUString  arg_name,
 sal_Bool * pFallenBack )
@@ -180,33 +177,22 @@ OUString findBoostrapArgument(
 result_buf.appendAscii( RTL_CONSTASCII_STRINGPARAM(.rdb) );
 result = result_buf.makeStringAndClear();
 
-#if OSL_DEBUG_LEVEL  1
-OString result_dbg =
-OUStringToOString(result, RTL_TEXTENCODING_ASCII_US);
-OString arg_name_dbg =
-OUStringToOString(arg_name, RTL_TEXTENCODING_ASCII_US);
 OSL_TRACE(
-cppuhelper::findBoostrapArgument - 
-setting %s relative to executable: %s\n,
-arg_name_dbg.getStr(),
-result_dbg.getStr() );
-#endif
+(OSL_LOG_PREFIX findBootstrapArgument, setting \%s\ relative to
+  executable \%s\),
+OUStringToOString(arg_name, RTL_TEXTENCODING_UTF8).getStr(),
+OUStringToOString(result, RTL_TEXTENCODING_UTF8).getStr());
 }
 else
 {
 if(pFallenBack)
 *pFallenBack = sal_False;
 
-#if OSL_DEBUG_LEVEL  1
-OString prefixed_arg_name_dbg = OUStringToOString(
-prefixed_arg_name, RTL_TEXTENCODING_ASCII_US );
-OString result_dbg = OUStringToOString(
-result, RTL_TEXTENCODING_ASCII_US );
 OSL_TRACE(
-cppuhelper::findBoostrapArgument - found %s in env: %s,
-prefixed_arg_name_dbg.getStr(),
-result_dbg.getStr() );
-#endif
+OSL_LOG_PREFIX findBootstrapArgument, found \%s\ in env \%s\,
+(OUStringToOString(prefixed_arg_name, RTL_TEXTENCODING_UTF8).
+ getStr()),
+OUStringToOString(result, RTL_TEXTENCODING_UTF8).getStr());
 }
 
 return result;
@@ -233,18 +219,13 @@ Reference registry::XSimpleRegistry  nestRegistries(
 {
 lastRegistry-open(write_rdb, sal_False, forceWrite_rdb);
 }
-catch (registry::InvalidRegistryException  invalidRegistryException)
+catch (registry::InvalidRegistryException  e)
 {
-(void) invalidRegistryException;
-#if OSL_DEBUG_LEVEL  1
-OString rdb_name_tmp = OUStringToOString(
-write_rdb, RTL_TEXTENCODING_ASCII_US);
-OString message_dbg = OUStringToOString(
-invalidRegistryException.Message, RTL_TEXTENCODING_ASCII_US);
+(void) e; // avoid warnings
 OSL_TRACE(
-warning: couldn't open %s cause of %s,
-rdb_name_tmp.getStr(), message_dbg.getStr() );
-#endif
+OSL_LOG_PREFIX warning, could not open \%s\: \%s\,
+OUStringToOString(write_rdb, RTL_TEXTENCODING_UTF8).getStr(),
+OUStringToOString(e.Message, RTL_TEXTENCODING_UTF8).getStr());
 }
 
 if(!lastRegistry-isValid())
@@ -290,17 +271,13 @@ Reference registry::XSimpleRegistry  nestRegistries(
 else
 lastRegistry = simpleRegistry;
 }
-catch(registry::InvalidRegistryException  invalidRegistryException)
+catch(registry::InvalidRegistryException  e)
 {
-#if OSL_DEBUG_LEVEL  1
-OString rdb_name_tmp = OUStringToOString(
-rdb_name, RTL_TEXTENCODING_ASCII_US );
-OString message_dbg = OUStringToOString(
-invalidRegistryException.Message, RTL_TEXTENCODING_ASCII_US );
+(void) e; // avoid warnings
 OSL_TRACE(
-warning: couldn't open %s cause of %s,
-rdb_name_tmp.getStr(), message_dbg.getStr() );
-#endif
+OSL_LOG_PREFIX warning, could not open \%s\: \%s\,
+OUStringToOString(rdb_name, RTL_TEXTENCODING_UTF8).getStr(),
+OUStringToOString(e.Message, RTL_TEXTENCODING_UTF8).getStr());
 if (! optional)
 {
 // if a registry was explicitly given, the exception shall fly
@@ -308,7 +285,6 @@ Reference registry::XSimpleRegistry  nestRegistries(
 throw;
 }
 
-(void) 

[Libreoffice-commits] .: 4 commits - comphelper/inc comphelper/source sw/inc sw/source unusedcode.easy xmloff/inc xmloff/source

2011-11-02 Thread Caolán McNamara
 comphelper/inc/comphelper/embeddedobjectcontainer.hxx   |3 -
 comphelper/inc/comphelper/mimeconfighelper.hxx  |3 -
 comphelper/source/container/embeddedobjectcontainer.cxx |   24 -
 comphelper/source/misc/mimeconfighelper.cxx |   15 -
 sw/inc/cmdid.h  |2 
 sw/source/core/access/accmap.cxx|6 +-
 sw/source/core/doc/docbasic.cxx |8 +--
 sw/source/core/edit/edtox.cxx   |4 -
 sw/source/core/tox/toxhlp.cxx   |   36 ++---
 sw/source/core/unocore/unofield.cxx |9 +--
 sw/source/core/unocore/unoframe.cxx |   14 +++--
 sw/source/ui/dbui/dbmgr.cxx |2 
 sw/source/ui/dbui/mmoutputpage.cxx  |2 
 sw/source/ui/shells/tabsh.cxx   |6 +-
 sw/source/ui/uiview/formatclipboard.cxx |6 +-
 unusedcode.easy |9 ---
 xmloff/inc/xmloff/txtparae.hxx  |2 
 xmloff/inc/xmloff/xmlnume.hxx   |5 -
 xmloff/source/style/xmlnume.cxx |   42 
 xmloff/source/text/txtparae.cxx |   16 --
 20 files changed, 52 insertions(+), 162 deletions(-)

New commits:
commit de04c92dea40c906fdf2b9058bd3139134d62f15
Author: Caolán McNamara caol...@redhat.com
Date:   Wed Nov 2 10:36:12 2011 +

make this build

diff --git a/sw/inc/cmdid.h b/sw/inc/cmdid.h
index fae2a95..94d9692 100644
--- a/sw/inc/cmdid.h
+++ b/sw/inc/cmdid.h
@@ -614,7 +614,7 @@ included in c-context files, so c++ style stuff will cause 
problems.
 #define FN_TABLE_MODE_FIX   (FN_FORMAT + 189)  /* table mode */
 #define FN_TABLE_MODE_FIX_PROP  (FN_FORMAT + 190)  /*  --  */
 #define FN_TABLE_MODE_VARIABLE  (FN_FORMAT + 191)  /*  --  */
-#define FN_TABLE_BOX_TEXTDIRECTION  (FN_FORMAT + 192)  /*  text direction of 
table cells */
+#define FN_TABLE_BOX_TEXTORIENTATION (FN_FORMAT + 192)  /* text orientation of 
table cells */
 
 #define FN_TABLE_AUTOSUM(FN_FORMAT + 195)  /* */
 #define FN_SET_CONTROL_HANDLER  (FN_FORMAT + 199)  /* set macro */
diff --git a/sw/source/ui/shells/tabsh.cxx b/sw/source/ui/shells/tabsh.cxx
index 44500b8..3c892ad 100644
--- a/sw/source/ui/shells/tabsh.cxx
+++ b/sw/source/ui/shells/tabsh.cxx
@@ -140,7 +140,7 @@ const sal_uInt16 aUITableAttrRange[] =
 FN_TABLE_SET_VERT_ALIGN,FN_TABLE_SET_VERT_ALIGN,
 RES_FRAMEDIR,   RES_FRAMEDIR,
 RES_ROW_SPLIT,  RES_ROW_SPLIT,
-FN_TABLE_BOX_TEXTDIRECTION, FN_TABLE_BOX_TEXTDIRECTION,
+FN_TABLE_BOX_TEXTORIENTATION,   FN_TABLE_BOX_TEXTORIENTATION,
 // #i29550#
 RES_COLLAPSING_BORDERS, RES_COLLAPSING_BORDERS,
 // -- collapsing borders
@@ -188,7 +188,7 @@ static SwTableRep*  lcl_TableParamToItemSet( SfxItemSet 
rSet, SwWrtShell rSh )
 // text direction in boxes
 SvxFrameDirectionItem aBoxDirection( FRMDIR_ENVIRONMENT, RES_FRAMEDIR );
 if(rSh.GetBoxDirection( aBoxDirection ))
-rSet.Put(aBoxDirection, FN_TABLE_BOX_TEXTDIRECTION);
+rSet.Put(aBoxDirection, FN_TABLE_BOX_TEXTORIENTATION);
 
 sal_Bool bTableSel = rSh.IsTableMode();
 if(!bTableSel)
@@ -309,7 +309,7 @@ void ItemSetToTableParam( const SfxItemSet rSet,
 const SfxPoolItem* pSplit = 0;
 sal_Bool bRowSplit = SFX_ITEM_SET == rSet.GetItemState( RES_ROW_SPLIT, 
sal_False, pSplit );
 const SfxPoolItem* pBoxDirection = 0;
-sal_Bool bBoxDirection = SFX_ITEM_SET == rSet.GetItemState( 
FN_TABLE_BOX_TEXTDIRECTION, sal_False, pBoxDirection );
+sal_Bool bBoxDirection = SFX_ITEM_SET == rSet.GetItemState( 
FN_TABLE_BOX_TEXTORIENTATION, sal_False, pBoxDirection );
 if( bBackground || bBorder || bRowSplit || bBoxDirection)
 {
 /*
diff --git a/sw/source/ui/uiview/formatclipboard.cxx 
b/sw/source/ui/uiview/formatclipboard.cxx
index 0fa7a6a..a9bfa3f 100644
--- a/sw/source/ui/uiview/formatclipboard.cxx
+++ b/sw/source/ui/uiview/formatclipboard.cxx
@@ -117,7 +117,7 @@ SfxItemSet* lcl_CreateEmptyItemSet( int nSelectionType, 
SfxItemPool rPool
 RES_KEEP,   RES_KEEP,
 RES_FRAMEDIR,   RES_FRAMEDIR,
 FN_PARAM_TABLE_HEADLINE, FN_PARAM_TABLE_HEADLINE,
-FN_TABLE_BOX_TEXTDIRECTION, FN_TABLE_BOX_TEXTDIRECTION,
+FN_TABLE_BOX_TEXTORIENTATION, 
FN_TABLE_BOX_TEXTORIENTATION,
 FN_TABLE_SET_VERT_ALIGN, FN_TABLE_SET_VERT_ALIGN,
 0);
 }
@@ -158,7 +158,7 @@ void lcl_getTableAttributes( SfxItemSet rSet, SwWrtShell 
rSh )
 
 SvxFrameDirectionItem aBoxDirection( FRMDIR_ENVIRONMENT, RES_FRAMEDIR );
 if(rSh.GetBoxDirection( aBoxDirection ))
-

[Libreoffice-commits] .: 2 commits - cui/source offapi/com sw/source

2011-11-02 Thread Cédric Bosdonnat
 cui/source/dialogs/SpellAttrib.hxx  |   10 
 cui/source/dialogs/SpellDialog.cxx  |  149 
 cui/source/dialogs/SpellDialog.hrc  |5 
 cui/source/dialogs/SpellDialog.src  |   69 ++---
 cui/source/inc/SpellDialog.hxx  |   29 +-
 offapi/com/sun/star/linguistic2/SingleProofreadingError.idl |4 
 sw/source/ui/docvw/FrameControlsManager.cxx |   15 +
 sw/source/ui/docvw/PageBreakWin.cxx |   43 ++-
 sw/source/ui/inc/FrameControlsManager.hxx   |1 
 sw/source/ui/inc/PageBreakWin.hxx   |1 
 10 files changed, 210 insertions(+), 116 deletions(-)

New commits:
commit bc3c10b5ce88869871761000e9724bcad9a0d556
Author: Cédric Bosdonnat cedric.bosdon...@free.fr
Date:   Sun Oct 23 07:35:06 2011 -0700

Grammar checking dialog: reworked how explanations are shown

diff --git a/cui/source/dialogs/SpellAttrib.hxx 
b/cui/source/dialogs/SpellAttrib.hxx
index 9ebc229..731c694 100644
--- a/cui/source/dialogs/SpellAttrib.hxx
+++ b/cui/source/dialogs/SpellAttrib.hxx
@@ -47,6 +47,7 @@ struct SpellErrorDescription
 ::rtl::OUString sErrorText;
 ::rtl::OUString sDialogTitle;
 ::rtl::OUString sExplanation;
+::rtl::OUString sExplanationURL;
 ::com::sun::star::lang::Locale  aLocale;
 ::com::sun::star::uno::Reference 
::com::sun::star::linguistic2::XProofreader  xGrammarChecker;
 ::rtl::OUString sServiceName; 
//service name of GrammarChecker/SpellChecker
@@ -64,9 +65,13 @@ struct SpellErrorDescription
   const ::rtl::OUString rServiceName,
   const ::rtl::OUString* pDialogTitle = 0,
   const ::rtl::OUString* pExplanation = 0,
-  const ::rtl::OUString* pRuleId = 0 ) :
+  const ::rtl::OUString* pRuleId = 0,
+  const ::rtl::OUString* pExplanationURL = 0 ) :
 bIsGrammarError( bGrammar ),
 sErrorText( rText ),
+sDialogTitle( ),
+sExplanation( ),
+sExplanationURL( ),
 aLocale( rLocale ),
 xGrammarChecker( rxGrammarChecker ),
 sServiceName( rServiceName ),
@@ -76,6 +81,8 @@ struct SpellErrorDescription
 sDialogTitle = *pDialogTitle;
 if( pExplanation )
 sExplanation = *pExplanation;
+if( pExplanationURL )
+sExplanationURL = *pExplanationURL;
 if( pRuleId )
 sRuleId = *pRuleId;
 };
@@ -91,6 +98,7 @@ struct SpellErrorDescription
 xGrammarChecker == rDesc.xGrammarChecker 
 sDialogTitle.equals( rDesc.sDialogTitle ) 
 sExplanation.equals( rDesc.sExplanation ) 
+sExplanationURL.equals( rDesc.sExplanationURL ) 
 sRuleId == rDesc.sRuleId;
 }
 };
diff --git a/cui/source/dialogs/SpellDialog.cxx 
b/cui/source/dialogs/SpellDialog.cxx
index 389cee6..9990e4c 100644
--- a/cui/source/dialogs/SpellDialog.cxx
+++ b/cui/source/dialogs/SpellDialog.cxx
@@ -51,6 +51,8 @@
 #include com/sun/star/lang/XServiceDisplayName.hpp
 #include com/sun/star/linguistic2/SpellFailure.hpp
 #include com/sun/star/frame/XStorable.hpp
+#include com/sun/star/system/SystemShellExecuteFlags.hpp
+#include com/sun/star/system/XSystemShellExecute.hpp
 #include sfx2/app.hxx
 #include vcl/help.hxx
 #include vcl/graph.hxx
@@ -68,6 +70,8 @@
 #include svx/svxerr.hxx
 #include treeopt.hxx
 #include svtools/langtab.hxx
+#include comphelper/anytostring.hxx
+#include cppuhelper/exc_hlp.hxx
 
 using namespace ::com::sun::star;
 using namespace ::com::sun::star::uno;
@@ -189,6 +193,26 @@ sal_uInt16 SpellUndoAction_Impl::GetId()const
 return m_nId;
 }
 
+HelpFixedText::HelpFixedText( Window* pParent, const ResId rResId ):
+FixedText( pParent, rResId )
+{
+}
+
+void HelpFixedText::Paint( const Rectangle rRect )
+{
+Rectangle aTextRect( rRect.Left() + 6, rRect.Top(), rRect.Right() - 6, 
rRect.Bottom() );
+DrawText( aTextRect, GetText(), TEXT_DRAW_WORDBREAK | TEXT_DRAW_MULTILINE 
);
+}
+
+long HelpFixedText::GetActualHeight( )
+{
+Rectangle rRect( GetPosPixel( ), GetSizePixel() );
+Rectangle aTextRect( rRect.Left() + 6, rRect.Top(), rRect.Right() - 6, 
rRect.Bottom() );
+Rectangle aBounds = GetTextRect( aTextRect, GetText(), TEXT_DRAW_WORDBREAK 
| TEXT_DRAW_MULTILINE );
+
+return aBounds.getHeight();
+}
+
 // class SvxSpellCheckDialog -
 
 SpellDialog::SpellDialog(
@@ -200,9 +224,10 @@ SpellDialog::SpellDialog(
 pParent,
 

[Libreoffice-commits] .: 2 commits - configure.in RepositoryExternal.mk set_soenv.in vcl/Library_vclplug_gtk3.mk vcl/Library_vclplug_gtk.mk

2011-11-02 Thread David Tardon
 RepositoryExternal.mk   |   28 
 configure.in|4 
 set_soenv.in|2 ++
 vcl/Library_vclplug_gtk.mk  |   15 +--
 vcl/Library_vclplug_gtk3.mk |   17 -
 5 files changed, 39 insertions(+), 27 deletions(-)

New commits:
commit 337b07d872e903cdc5f4411d76aca873567eee81
Author: David Tardon dtar...@redhat.com
Date:   Wed Nov 2 13:04:19 2011 +0100

use external

diff --git a/vcl/Library_vclplug_gtk.mk b/vcl/Library_vclplug_gtk.mk
index 2e1983e..e2f9b8d 100644
--- a/vcl/Library_vclplug_gtk.mk
+++ b/vcl/Library_vclplug_gtk.mk
@@ -41,20 +41,6 @@ $(eval $(call gb_Library_add_defs,vclplug_gtk,\
 -DVERSION=\$(UPD)$(LAST_MINOR)\ \
 ))
 
-ifneq ($(ENABLE_DBUS),)
-# FIXME: pkg-config calls should be done in configure, and this should be 
_use_external
-$(eval $(call gb_Library_set_include,vclplug_gtk,\
-   $$(INCLUDE) \
-   $(filter -I%,$(shell pkg-config --cflags dbus-glib-1)) \
-))
-$(eval $(call gb_Library_add_defs,vclplug_gtk,\
--DENABLE_DBUS \
-))
-$(eval $(call gb_Library_add_libs,vclplug_gtk,\
-$(shell pkg-config --libs dbus-glib-1)\
-))
-endif
-
 $(eval $(call gb_Library_add_api,vclplug_gtk,\
 offapi \
 udkapi \
@@ -84,6 +70,7 @@ $(eval $(call gb_Library_add_linked_libs,vclplug_gtk,\
 ))
 
 $(eval $(call gb_Library_use_externals,vclplug_gtk,\
+   dbus \
gtk \
gthread \
icule \
diff --git a/vcl/Library_vclplug_gtk3.mk b/vcl/Library_vclplug_gtk3.mk
index 72e7a75..9c589ff 100644
--- a/vcl/Library_vclplug_gtk3.mk
+++ b/vcl/Library_vclplug_gtk3.mk
@@ -51,19 +51,6 @@ $(eval $(call gb_Library_add_api,vclplug_gtk3,\
 udkapi \
 ))
 
-ifneq ($(ENABLE_DBUS),)
-$(eval $(call gb_Library_set_include,vclplug_gtk3,\
-   $$(INCLUDE) \
-   $(filter -I%,$(shell pkg-config --cflags dbus-glib-1)) \
-))
-$(eval $(call gb_Library_add_defs,vclplug_gtk3,\
--DENABLE_DBUS \
-))
-$(eval $(call gb_Library_add_libs,vclplug_gtk3,\
-$(shell pkg-config --libs dbus-glib-1)\
-))
-endif
-
 $(eval $(call gb_Library_add_libs,vclplug_gtk3,\
 $$(GTK3_LIBS) \
 $$(GTHREAD_LIBS) \
@@ -92,6 +79,10 @@ $(eval $(call gb_Library_add_linked_libs,vclplug_gtk3,\
 $(gb_STDLIBS) \
 ))
 
+$(eval $(call gb_Library_use_externals,vclplug_gtk,\
+   dbus \
+))
+
 $(eval $(call gb_Library_add_exception_objects,vclplug_gtk3,\
 vcl/unx/gtk3/a11y/gtk3atkaction \
 vcl/unx/gtk3/a11y/gtk3atkbridge \
commit 1b717cee8c7e9d321dc8fdbfb47719cbd9b6c870
Author: David Tardon dtar...@redhat.com
Date:   Wed Nov 2 13:00:48 2011 +0100

export DBUS_{CFLAGS,LIBS}

diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk
index db8138c..8891d6b 100644
--- a/RepositoryExternal.mk
+++ b/RepositoryExternal.mk
@@ -646,6 +646,34 @@ $(call gb_LinkTarget_add_libs,$(1),$(GTHREAD_LIBS))
 
 endef
 
+
+ifeq ($(ENABLE_DBUS),YES)
+
+define gb_LinkTarget__use_dbus
+$(call gb_LinkTarget_set_include,$(1),\
+   $$(INCLUDE) \
+   $(DBUS_CFLAGS) \
+)
+
+$(call gb_Library_add_defs,$(1),\
+-DENABLE_DBUS \
+)
+
+$(call gb_LinkTarget_add_libs,$(1),\
+   $(DBUS_LIBS) \
+)
+
+endef
+
+else # ENABLE_DBUS
+
+define gb_LinkTarget__use_dbus
+
+endef
+
+endif # ENABLE_DBUS
+
+
 define gb_LinkTarget__use_dbusmenugtk
 $(call gb_LinkTarget_set_include,$(1),\
$$(INCLUDE) \
diff --git a/configure.in b/configure.in
index 6052587..a260a0a 100644
--- a/configure.in
+++ b/configure.in
@@ -6985,6 +6985,8 @@ GTK_CFLAGS=
 GTK_LIBS=
 ENABLE_SYSTRAY_GTK=
 ENABLE_DBUS=
+DBUS_CFLAGS=
+DBUS_LIBS=
 if test  $test_gtk = yes; then
 
 if test $ENABLE_GTK = TRUE ; then
@@ -7027,6 +7029,8 @@ AC_SUBST(GTK_CFLAGS)
 AC_SUBST(GTK_LIBS)
 AC_SUBST(GTHREAD_CFLAGS)
 AC_SUBST(GTHREAD_LIBS)
+AC_SUBST(DBUS_CFLAGS)
+AC_SUBST(DBUS_LIBS)
 
 PKG_CHECK_MODULES( LIBPNG, libpng, ENABLE_QUICKSTART_LIBPNG=TRUE, 
ENABLE_QUICKSTART_LIBPNG= )
 AC_SUBST(LIBPNG_LIBS)
diff --git a/set_soenv.in b/set_soenv.in
index dc2d996..2505e19 100755
--- a/set_soenv.in
+++ b/set_soenv.in
@@ -1530,6 +1530,8 @@ ToFile( COMMONS_LOGGING_JAR,@COMMONS_LOGGING_JAR@,e 
);
 ToFile( SYSTEM_SERVLETAPI, @SYSTEM_SERVLETAPI@, e );
 ToFile( SERVLETAPI_JAR,@SERVLETAPI_JAR@,   e );
 ToFile( ENABLE_DBUS,   @ENABLE_DBUS@,  e );
+ToFile( DBUS_CFLAGS,   @DBUS_CFLAGS@,  e );
+ToFile( DBUS_LIBS, @DBUS_LIBS@,e );
 ToFile( ENABLE_GCONF,  @ENABLE_GCONF@, e );
 ToFile( ENABLE_GNOMEVFS,   @ENABLE_GNOMEVFS@,  e );
 ToFile( ENABLE_GSTREAMER,  @ENABLE_GSTREAMER@, e );
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: basctl/source

2011-11-02 Thread Joseph Powers
 basctl/source/basicide/bastype4.hxx |   69 
 1 file changed, 69 deletions(-)

New commits:
commit f65946944eca8da10d1e54a78eb2537e205e855c
Author: Joseph Powers jpower...@cox.net
Date:   Wed Nov 2 05:56:25 2011 -0700

Remove an unused header from basctl

diff --git a/basctl/source/basicide/bastype4.hxx 
b/basctl/source/basicide/bastype4.hxx
deleted file mode 100644
index 000eec7..000
--- a/basctl/source/basicide/bastype4.hxx
+++ /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
- * http://www.openoffice.org/license.html
- * for a copy of the LGPLv3 License.
- *
- /
-#ifndef _BASTYPE4_HXX
-#define _BASTYPE4_HXX
-
-
-#include svtools/tabbar.hxx
-
-class EditEngine;
-class EditView;
-
-class ExtendedTabBar : public TabBar
-{
-EditEngine* pEditEngine;
-EditView*   pEditView;
-sal_BoolbIsInKeyInput;
-#if _SOLAR__PRIVATE
-voidImpCheckEditEngine( sal_Bool bKeepNewText );
-#endif
-protected:
-virtual voidMouseButtonDown( const MouseEvent rMEvt );
-virtual voidMouseButtonUp( const MouseEvent rMEvt );
-virtual voidMouseMove( const MouseEvent rMEvt );
-virtual voidLoseFocus();
-virtual voidKeyInput( const KeyEvent rKEvent );
-virtual voidPaint( const Rectangle );
-
-virtual sal_BoolStartRenamingTab( sal_uInt16 nCurId );
-virtual sal_BoolAllowRenamingTab( sal_uInt16 nCurId, const String 
rNewName );
-virtual voidTabRenamed( sal_uInt16 nCurId, const String rNewName );
-
-public:
-ExtendedTabBar( Window* pParent, WinBits nStyle );
-~ExtendedTabBar();
-
-voidRenameSelectedTab();
-sal_BoolIsInEditMode() const { return pEditEngine ? sal_True : 
sal_False; }
-voidStopEditMode( sal_Bool bKeepCurText = sal_False );
-};
-
-#endif  //_BASTYPE4_HXX
-
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: vcl/inc vcl/unx

2011-11-02 Thread David Tardon
 vcl/inc/unx/salunx.h|3 ---
 vcl/unx/generic/app/saldata.cxx |2 +-
 2 files changed, 1 insertion(+), 4 deletions(-)

New commits:
commit b2e0b5f3f5b9a4c6b8483e6fb9855054c84aab92
Author: David Tardon dtar...@redhat.com
Date:   Wed Nov 2 14:55:17 2011 +0100

use SAL_N_ELEMENTS

diff --git a/vcl/inc/unx/salunx.h b/vcl/inc/unx/salunx.h
index e4150f0..5082519 100644
--- a/vcl/inc/unx/salunx.h
+++ b/vcl/inc/unx/salunx.h
@@ -33,9 +33,6 @@
 #include unx/svunx.h
 #include unx/salstd.hxx
 
-// -=-= #defines -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
-#define capacityof(a)   (sizeof(a)/sizeof(*a))
-
 // -=-= inlines =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 inline long Divide( long nDividend, long nDivisor )
 { return (nDividend + nDivisor/2) / nDivisor; }
diff --git a/vcl/unx/generic/app/saldata.cxx b/vcl/unx/generic/app/saldata.cxx
index 8eb6602..3f88f35 100644
--- a/vcl/unx/generic/app/saldata.cxx
+++ b/vcl/unx/generic/app/saldata.cxx
@@ -513,7 +513,7 @@ static void PrintXError( Display *pDisplay, XErrorEvent 
*pEvent )
 XGetErrorText( pDisplay, pEvent-error_code, msg, sizeof( msg ) );
 #endif
 std::fprintf( stderr, X-Error: %s\n, msg );
-if( pEvent-request_code  capacityof( XRequest ) )
+if( pEvent-request_code  SAL_N_ELEMENTS( XRequest ) )
 {
 const char* pName = XRequest[pEvent-request_code];
 if( !pName )
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: Branch 'libreoffice-3-4' - sc/source

2011-11-02 Thread Kohei Yoshida
 sc/source/core/tool/scmatrix.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 19e143362cd88917c0466d5133fa4ca63988c106
Author: Markus Mohrhard markus.mohrh...@googlemail.com
Date:   Wed Nov 2 12:34:27 2011 +0100

we need to use ValidColRowOrRepeated, silly mistake by me.

Signed-off-by: Kohei Yoshida kohei.yosh...@suse.com

diff --git a/sc/source/core/tool/scmatrix.cxx b/sc/source/core/tool/scmatrix.cxx
index 3074e36..912eef1 100644
--- a/sc/source/core/tool/scmatrix.cxx
+++ b/sc/source/core/tool/scmatrix.cxx
@@ -592,7 +592,7 @@ bool ScMatrixImpl::IsEmpty( SCSIZE nC, SCSIZE nR ) const
 bool ScMatrixImpl::IsEmptyPath( SCSIZE nC, SCSIZE nR ) const
 {
 // 'Empty path' is empty plus non-zero flag.
-if (ValidColRowReplicated( nC, nR ))
+if (ValidColRowOrReplicated( nC, nR ))
 return maMat.get_type(nR, nC) == ::mdds::element_empty  
maMat.get_flag(nR, nC) != 0;
 else
 return true;
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: cli_ure/inc cli_ure/source

2011-11-02 Thread Joseph Powers
 cli_ure/inc/pch/precompiled_cli_ure.cxx   |   31 ---
 cli_ure/inc/pch/precompiled_cli_ure.hxx   |   34 --
 cli_ure/source/climaker/climaker_app.cxx  |3 --
 cli_ure/source/climaker/climaker_emit.cxx |3 --
 cli_ure/source/native/assembly.cxx|3 --
 cli_ure/source/uno_bridge/cli_bridge.cxx  |3 --
 cli_ure/source/uno_bridge/cli_data.cxx|3 --
 cli_ure/source/uno_bridge/cli_environment.cxx |3 --
 cli_ure/source/uno_bridge/cli_proxy.cxx   |2 -
 cli_ure/source/uno_bridge/cli_uno.cxx |3 --
 10 files changed, 88 deletions(-)

New commits:
commit 0c9d2b9cb3f1b5bac034ccfee0eb83aa2182f2cf
Author: Joseph Powers jpower...@cox.net
Date:   Wed Nov 2 06:39:08 2011 -0700

precompiled_cli_ure.hxx is empty, so just remove it

diff --git a/cli_ure/inc/pch/precompiled_cli_ure.cxx 
b/cli_ure/inc/pch/precompiled_cli_ure.cxx
deleted file mode 100644
index e11d204..000
--- a/cli_ure/inc/pch/precompiled_cli_ure.cxx
+++ /dev/null
@@ -1,31 +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
- * http://www.openoffice.org/license.html
- * for a copy of the LGPLv3 License.
- *
- /
-
-#include precompiled_cli_ure.hxx
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cli_ure/inc/pch/precompiled_cli_ure.hxx 
b/cli_ure/inc/pch/precompiled_cli_ure.hxx
deleted file mode 100644
index 59c8eb0..000
--- a/cli_ure/inc/pch/precompiled_cli_ure.hxx
+++ /dev/null
@@ -1,34 +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
- * http://www.openoffice.org/license.html
- * for a copy of the LGPLv3 License.
- *
- /
-
-// MARKER(update_precomp.py): Generated on 2006-09-01 17:49:33.514782
-
-#ifdef PRECOMPILED_HEADERS
-#endif
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cli_ure/source/climaker/climaker_app.cxx 
b/cli_ure/source/climaker/climaker_app.cxx
index 3d34498..b7f5db1 100644
--- a/cli_ure/source/climaker/climaker_app.cxx
+++ b/cli_ure/source/climaker/climaker_app.cxx
@@ -26,9 +26,6 @@
  *
  /
 
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include precompiled_cli_ure.hxx
-
 #include stdio.h
 #include vector
 #include memory
diff --git a/cli_ure/source/climaker/climaker_emit.cxx 
b/cli_ure/source/climaker/climaker_emit.cxx
index 5415d8f..d7d20e4 100644
--- a/cli_ure/source/climaker/climaker_emit.cxx
+++ b/cli_ure/source/climaker/climaker_emit.cxx
@@ -26,9 +26,6 @@
  *
  /
 
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include precompiled_cli_ure.hxx
-
 #include climaker_share.h
 
 #include 

[Libreoffice-commits] .: 2 commits - sw/inc sw/Library_sw.mk sw/source

2011-11-02 Thread Caolán McNamara
 sw/Library_sw.mk |1 
 sw/inc/swabstdlg.hxx |   12 -
 sw/source/ui/app/swmodule.cxx|2 
 sw/source/ui/dialog/swdlgfact.cxx|   45 --
 sw/source/ui/dialog/swdlgfact.hxx|   15 ---
 sw/source/ui/dialog/wordcountdialog.cxx  |   56 ++-
 sw/source/ui/dialog/wordcountdialog.hrc  |1 
 sw/source/ui/dialog/wordcountdialog.src  |   12 +
 sw/source/ui/dialog/wordcountwrapper.cxx |   63 +++
 sw/source/ui/docvw/edtwin.cxx|   16 +++
 sw/source/ui/inc/wordcountdialog.hxx |   38 ++
 sw/source/ui/shells/annotsh.cxx  |   25 
 sw/source/ui/shells/drawsh.cxx   |   23 ---
 sw/source/ui/shells/drwtxtex.cxx |   23 ---
 sw/source/ui/shells/frmsh.cxx|   24 ---
 sw/source/ui/shells/textsh.cxx   |1 
 sw/source/ui/shells/textsh1.cxx  |   24 ---
 17 files changed, 285 insertions(+), 96 deletions(-)

New commits:
commit 555c89db131240641cb01c7c8caa239d1621df84
Author: Caolán McNamara caol...@redhat.com
Date:   Wed Nov 2 14:50:28 2011 +

fix this to build

diff --git a/sw/source/ui/dialog/wordcountwrapper.cxx 
b/sw/source/ui/dialog/wordcountwrapper.cxx
index 764f9f9..ddecf5a 100644
--- a/sw/source/ui/dialog/wordcountwrapper.cxx
+++ b/sw/source/ui/dialog/wordcountwrapper.cxx
@@ -32,7 +32,6 @@
 #include dialog.hrc
 #include layout/layout-pre.hxx
 #include wordcountdialog.hrc
-#include wordcountwrapper.hxx
 #include cmdid.h
 
 SFX_IMPL_CHILDWINDOW(SwWordCountWrapper, FN_WORDCOUNT_DIALOG)
diff --git a/sw/source/ui/shells/annotsh.cxx b/sw/source/ui/shells/annotsh.cxx
index cf38a16..6aada30 100644
--- a/sw/source/ui/shells/annotsh.cxx
+++ b/sw/source/ui/shells/annotsh.cxx
@@ -131,6 +131,8 @@
 
 #include langhelper.hxx
 
+#include wordcountdialog.hxx
+
 using namespace ::com::sun::star;
 using namespace ::com::sun::star::uno;
 using namespace ::com::sun::star::beans;
@@ -410,7 +412,7 @@ void SwAnnotationShell::Exec( SfxRequest rReq )
 break;
 case FN_WORDCOUNT_DIALOG:
 {
-SfxViewFrame* pVFrame = GetView().GetViewFrame();
+SfxViewFrame* pVFrame = rView.GetViewFrame();
 if (pVFrame != NULL)
 {
 pVFrame-ToggleChildWindow(FN_WORDCOUNT_DIALOG);
diff --git a/sw/source/ui/shells/drawsh.cxx b/sw/source/ui/shells/drawsh.cxx
index 7dc94e0..56e0a42 100644
--- a/sw/source/ui/shells/drawsh.cxx
+++ b/sw/source/ui/shells/drawsh.cxx
@@ -70,6 +70,7 @@
 #include sfx2/msg.hxx
 #include swslots.hxx
 #include swabstdlg.hxx
+#include wordcountdialog.hxx
 #include misc.hrc
 
 using namespace ::com::sun::star;
diff --git a/sw/source/ui/shells/drwtxtex.cxx b/sw/source/ui/shells/drwtxtex.cxx
index b21da6d..dcbdd6f 100644
--- a/sw/source/ui/shells/drwtxtex.cxx
+++ b/sw/source/ui/shells/drwtxtex.cxx
@@ -101,6 +101,7 @@
 #include viewopt.hxx
 #include wrtsh.hxx
 #include wview.hxx
+#include wordcountdialog.hxx
 
 #include swabstdlg.hxx
 #include chrdlg.hrc
diff --git a/sw/source/ui/shells/frmsh.cxx b/sw/source/ui/shells/frmsh.cxx
index 6eb2ea7..12efea7 100644
--- a/sw/source/ui/shells/frmsh.cxx
+++ b/sw/source/ui/shells/frmsh.cxx
@@ -95,6 +95,8 @@
 #include com/sun/star/frame/XStorable.hpp
 #include com/sun/star/uno/Any.h
 
+#include wordcountdialog.hxx
+
 using ::editeng::SvxBorderLine;
 using namespace ::com::sun::star;
 using namespace ::com::sun::star::uno;
commit 12402e2cfdacf9a77af390e51ce12a4a6025f286
Author: Matt Pratt mattpratt...@gmail.com
Date:   Tue Nov 1 22:47:33 2011 -0600

Resolves: #i46785# Word count dialog modeless

diff --git a/sw/Library_sw.mk b/sw/Library_sw.mk
index b2ce776..a8ee383 100644
--- a/sw/Library_sw.mk
+++ b/sw/Library_sw.mk
@@ -615,6 +615,7 @@ $(eval $(call gb_Library_add_exception_objects,sw,\
 sw/source/ui/frmdlg/frmmgr \
 sw/source/ui/globdoc/globdoc \
 sw/source/ui/index/idxmrk \
+sw/source/ui/dialog/wordcountwrapper \
 sw/source/ui/index/toxmgr \
 sw/source/ui/lingu/hhcwrp \
 sw/source/ui/lingu/hyp \
diff --git a/sw/inc/swabstdlg.hxx b/sw/inc/swabstdlg.hxx
index 9a685db..2c6045c 100644
--- a/sw/inc/swabstdlg.hxx
+++ b/sw/inc/swabstdlg.hxx
@@ -200,10 +200,11 @@ public:
 virtual void SetSectionData(SwSectionData const rSect) = 0;
 };
 
-class AbstractSwWordCountDialog : public VclAbstractDialog
+class AbstractSwWordCountFloatDlg : public VclAbstractDialog
 {
 public:
-virtual voidSetValues(const SwDocStat rCurrent, const SwDocStat 
rDoc) = 0;
+virtual voidUpdateCounts() = 0;
+virtual Window *GetWindow() = 0; //this method is added for return a 
Window type pointer
 };
 
 class AbstractSwInsertAbstractDlg : public VclAbstractDialog// add for 
SwInsertAbstractDlg
@@ -353,7 +354,12 @@ public:
 const ::com::sun::star::uno::Reference 

[Libreoffice-commits] .: svx/source

2011-11-02 Thread Jan Holesovsky
 svx/source/svdraw/svdmrkv.cxx |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 2ab818f8e9822ff027ad6c90e7b6fb1f4c089f9f
Author: Ivan Timofeev timofeev@gmail.com
Date:   Wed Nov 2 15:55:28 2011 +0100

Fix i#89051: Move the point you've just inserted, not the previous one.

diff --git a/svx/source/svdraw/svdmrkv.cxx b/svx/source/svdraw/svdmrkv.cxx
index becc523..9dd2e62 100644
--- a/svx/source/svdraw/svdmrkv.cxx
+++ b/svx/source/svdraw/svdmrkv.cxx
@@ -802,12 +802,12 @@ void SdrMarkView::SetMarkHandles()
 // Drehpunkt/Spiegelachse
 AddDragModeHdl(eDragMode);
 
-// add custom handles (used by other apps, e.g. AnchorPos)
-AddCustomHdl();
-
 // sort handles
 aHdl.Sort();
 
+// add custom handles (used by other apps, e.g. AnchorPos)
+AddCustomHdl();
+
 // #105722# try to restore focus handle index from remembered values
 if(bSaveOldFocus)
 {
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: sw/source

2011-11-02 Thread Cédric Bosdonnat
 sw/source/core/text/txttab.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 208c9648ec31ccf27edddc2f5dbfd1387a445fdb
Author: Cédric Bosdonnat cedric.bosdon...@free.fr
Date:   Wed Nov 2 16:20:46 2011 +0100

n#693238: fixed parentheses warning

diff --git a/sw/source/core/text/txttab.cxx b/sw/source/core/text/txttab.cxx
index d237873..341bde2 100644
--- a/sw/source/core/text/txttab.cxx
+++ b/sw/source/core/text/txttab.cxx
@@ -452,7 +452,7 @@ sal_Bool SwTabPortion::PreFormat( SwTxtFormatInfo rInf )
 // tab stop position is outside the frame:
 bool bAtParaEnd = rInf.GetIdx() + GetLen() == 
rInf.GetTxt().Len();
 if ( bFull  bTabCompat 
- ( bTabOverflow  ( rInf.IsTabOverflow() || 
!IsAutoTabStop() ) || bAtParaEnd ) 
+ ( ( bTabOverflow  ( rInf.IsTabOverflow() || 
!IsAutoTabStop() ) ) || bAtParaEnd ) 
  GetTabPos() = rInf.GetTxtFrm()-Frm().Width() )
 {
 bFull = sal_False;
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: 3 commits - sw/source unotools/inc unotools/source unusedcode.easy vcl/inc vcl/source

2011-11-02 Thread Caolán McNamara
 sw/source/ui/wrtsh/select.cxx   |   23 ---
 unotools/inc/unotools/lingucfg.hxx  |1 -
 unotools/source/config/lingucfg.cxx |   15 ---
 unusedcode.easy |   36 ++--
 vcl/inc/vcl/button.hxx  |1 -
 vcl/source/control/button.cxx   |6 --
 6 files changed, 50 insertions(+), 32 deletions(-)

New commits:
commit 8fa8a59cad3970bbe68724fbbb93797fb5786c37
Author: Caolán McNamara caol...@redhat.com
Date:   Wed Nov 2 16:03:57 2011 +

update unused list

diff --git a/unusedcode.easy b/unusedcode.easy
index a8cece3..e895bbc 100644
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -487,8 +487,6 @@ ScInputBarGroup::LinkStubImpl_ScrollHdl(void*, void*)
 ScJobSetup::ScJobSetup(SfxPrinter*)
 ScLeftFooterEditPage::GetRanges()
 ScLeftHeaderEditPage::GetRanges()
-ScMacrosTest::testStarBasic()
-ScMacrosTest::testVba()
 ScMatrix::CalcOffset(unsigned long, unsigned long) const
 ScMultiTextWnd::GetLineCount()
 ScMyCellInfo::ScMyCellInfo()
@@ -1269,6 +1267,7 @@ VCLUnoHelper::CreatePointer()
 VCLXDevice::IsCreatedWithToolkit() const
 VCLXPrinterServer::getImplementationId()
 VCLXPrinterServer::getTypes()
+VCLXRadioButton::getFirstActionListener()
 VbaFontBase::getUnderline()
 VbaFontBase::setUnderline(com::sun::star::uno::Any const)
 VbaFoundFilesEnum::SetFileList(com::sun::star::uno::Sequencertl::OUString)
@@ -2136,7 +2135,40 @@ graphite2::TtfUtil::GlyfLookup(unsigned short, void 
const*, void const*, unsigne
 jfw_plugin::VendorBase::createInstance()
 jfw_plugin::VendorBase::getJavaExePaths(int*)
 
jvmaccess::ClassPath::doLoadClass(com::sun::star::uno::Referencecom::sun::star::uno::XComponentContext
 const, void*, rtl::OUString const, rtl::OUString const)
+layout::Box::Box(layout::Context const*, char const*)
+layout::Box::Box(rtl::OUString const, int, bool)
+layout::Box::setProps(com::sun::star::uno::Referencecom::sun::star::awt::XLayoutConstrains,
 bool, bool, int)
+layout::Button::GetButton() const
+layout::Container::ShowAll(bool)
+layout::ControlImpl::GetGetFocusHdl()
+layout::ControlImpl::GetLoseFocusHdl()
+layout::Dialog::GetDialog() const
+layout::Edit::GetEdit() const
+layout::ErrorBox::ErrorBox(Window*, char const*, char const*, char const*, 
rtl::OString const, char const*, char const*)
+layout::ErrorBox::ErrorBox(Window*, long, char const*, char const*, char 
const*, rtl::OString const, char const*, char const*)
+layout::ErrorBox::ErrorBox(Window*, long, rtl::OUString const, rtl::OUString, 
rtl::OUString, rtl::OString const, char const*, char const*)
+layout::ErrorBox::ErrorBox(Window*, rtl::OUString const, rtl::OUString, 
rtl::OUString, rtl::OString const, char const*, char const*)
+layout::InfoBox::InfoBox(Window*, char const*, char const*, char const*, 
rtl::OString const, char const*, char const*)
+layout::InfoBox::InfoBox(Window*, long, char const*, char const*, char const*, 
rtl::OString const, char const*, char const*)
+layout::InfoBox::InfoBox(Window*, long, rtl::OUString const, rtl::OUString, 
rtl::OUString, rtl::OString const, char const*, char const*)
+layout::InfoBox::InfoBox(Window*, rtl::OUString const, rtl::OUString, 
rtl::OUString, rtl::OString const, char const*, char const*)
+layout::ListBox::GetEntry(unsigned short) const
+layout::ListBox::GetEntryPos(String const) const
+layout::ListBox::GetSelectEntryPos(unsigned short) const
+layout::ListBox::SelectEntryPos(unsigned short, bool)
+layout::MetricFormatter::MetricFormatter(layout::FormatterBaseImpl*)
+layout::MetricFormatter::getFormatImpl() const
+layout::NumericFormatter::NumericFormatter(layout::FormatterBaseImpl*)
+layout::NumericFormatter::getFormatImpl() const
+layout::PushButton::Check(bool)
+layout::PushButton::GetPushButton() const
+layout::TabControl::SetCurPageId(unsigned short)
+layout::Table::setProps(com::sun::star::uno::Referencecom::sun::star::awt::XLayoutConstrains,
 bool, bool, int, int)
+layout::Window::CreatePeer(layout::Window*, long, char const*)
+layout::Window::getContext()
+layout::WindowImpl::getProperty(char const*)
 layoutimpl::LayoutRoot::addItem(rtl::OUString const, 
com::sun::star::uno::Referencecom::sun::star::awt::XLayoutConstrains const)
+layoutimpl::VCLXPlugin::SetPlugin(Control*)
 
layoutimpl::VCLXTabControl::AddChild(com::sun::star::uno::Referencecom::sun::star::awt::XLayoutConstrains
 const)
 layoutimpl::WidgetFactory::sfx2CreateWindow(VCLXWindow**, Window*, 
rtl::OUString const, long)
 
layoutimpl::getParent(com::sun::star::uno::Referencecom::sun::star::uno::XInterface)
commit da0bd7a50139b06e14c1917af044b37d10ebaf4f
Author: Caolán McNamara caol...@redhat.com
Date:   Wed Nov 2 16:03:45 2011 +

drop freshly unused methods

diff --git a/unotools/inc/unotools/lingucfg.hxx 
b/unotools/inc/unotools/lingucfg.hxx
index 4ae1020..668cb26 100644
--- a/unotools/inc/unotools/lingucfg.hxx
+++ b/unotools/inc/unotools/lingucfg.hxx
@@ -225,7 +225,6 @@ public:
 std::vector 

[Libreoffice-commits] .: post_download.in

2011-11-02 Thread Tor Lillqvist
 post_download.in |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 4ab6d2841dc47219d443e18f007f7b9893705966
Author: Tor Lillqvist tlillqv...@suse.com
Date:   Wed Nov 2 17:39:07 2011 +0200

Pointless to check for executability of gdiplus.dll here

diff --git a/post_download.in b/post_download.in
index 7c5d07f..6025d38 100644
--- a/post_download.in
+++ b/post_download.in
@@ -50,7 +50,7 @@ dnl Windows builds need gdiplus.dll in external/gdiplus/
 dnl ===
 if test $_os = WINNT; then
AC_MSG_CHECKING([for gdiplus.dll])
-   if test -x ./external/gdiplus/gdiplus.dll; then
+   if test -f ./external/gdiplus/gdiplus.dll; then
   AC_MSG_RESULT([found])
else
   AC_MSG_ERROR([gdiplus.dll is missing in external/gdiplus/.
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: 2 commits - codemaker/source cppuhelper/source scp2/source ure/source

2011-11-02 Thread Stephan Bergmann
 codemaker/source/cppumaker/cpputype.cxx |  169 +---
 codemaker/source/cppumaker/cpputype.hxx |   17 ++-
 cppuhelper/source/bootstrap.cxx |  163 ++
 scp2/source/ooo/common_brand.scp|4 
 scp2/source/ooo/directory_ooo.scp   |   10 +
 scp2/source/ooo/file_ooo.scp|6 -
 ure/source/README   |5 
 7 files changed, 201 insertions(+), 173 deletions(-)

New commits:
commit b5ec39a65e8b5d78f9f58bc179e9130c81ec347a
Author: Stephan Bergmann sberg...@redhat.com
Date:   Wed Nov 2 17:01:25 2011 +0100

Make .hpp/.hdl more robust against accidental include of .hdl instead of 
.hpp.

.hdl failed to declare the inline cppu_detail_getUnoType functions defined 
in
.hpp, which if client code only includes .hdl instead of .hpp could lead to
runtime failures, now leads to compiler warnings.

diff --git a/codemaker/source/cppumaker/cpputype.cxx 
b/codemaker/source/cppumaker/cpputype.cxx
index 5b87cc0..e1a524f 100644
--- a/codemaker/source/cppumaker/cpputype.cxx
+++ b/codemaker/source/cppumaker/cpputype.cxx
@@ -125,6 +125,10 @@ void 
CppuType::addGetCppuTypeIncludes(codemaker::cppumaker::Includes  includes)
 }
 }
 
+void CppuType::dumpDeclaration(FileStream ) throw (CannotDumpException) {
+OSL_ASSERT(false);
+}
+
 bool CppuType::dumpFiles(CppuOptions * options, rtl::OString const  outPath) {
 return dumpFile(options, .hdl, m_typeName, outPath)
  dumpFile(options, .hpp, m_typeName, outPath);
@@ -433,6 +437,42 @@ void CppuType::dumpInitializer(
 out  );
 }
 
+void CppuType::dumpHFileContent(
+FileStream  out, codemaker::cppumaker::Includes  includes)
+{
+addDefaultHIncludes(includes);
+dumpHeaderDefine(out, HDL);
+out  \n;
+includes.dump(out, 0);
+out  (\nnamespace com { namespace sun { namespace star { namespace uno
+ { class Type; } } } }\n\n);
+if (codemaker::cppumaker::dumpNamespaceOpen(out, m_typeName, false)) {
+out  \n;
+}
+dumpDeclaration(out);
+if (!(m_typeName.equalsL(
+  RTL_CONSTASCII_STRINGPARAM(com/sun/star/uno/XInterface)) ||
+  m_typeName.equalsL(
+  RTL_CONSTASCII_STRINGPARAM(com/sun/star/uno/Exception)) ||
+  isPolymorphic()))
+{
+out  \n  indent()
+ (inline ::com::sun::star::uno::Type const 
+ cppu_detail_getUnoType();
+dumpType(out, m_typeName, false, false, true);
+out   const *);\n;
+}
+if (codemaker::cppumaker::dumpNamespaceClose(out, m_typeName, false)) {
+out  \n;
+}
+out  \n;
+dumpTemplateHead(out);
+out  inline ::com::sun::star::uno::Type const  SAL_CALL getCppuType(;
+dumpType(out, m_typeName, true);
+dumpTemplateParameters(out);
+out   *) SAL_THROW(());\n\n#endif\n;
+}
+
 void CppuType::dumpGetCppuType(FileStream  out) {
 if (m_typeName.equals(com/sun/star/uno/XInterface)) {
 out  indent()
@@ -1268,34 +1308,14 @@ sal_Bool InterfaceType::dumpHFile(
 FileStream o, codemaker::cppumaker::Includes  includes)
 throw( CannotDumpException )
 {
-OString headerDefine(dumpHeaderDefine(o, HDL));
-o  \n;
-
-addDefaultHIncludes(includes);
 if (m_reader.getMethodCount() != 0) {
 includes.add(com/sun/star/uno/RuntimeException);
 }
-includes.dump(o, 0);
-o  (\nnamespace com { namespace sun { namespace star { namespace uno 
{\n
-  class Type;\n} } } }\n\n);
-
-if (codemaker::cppumaker::dumpNamespaceOpen(o, m_typeName, false)) {
-o  \n;
-}
-dumpDeclaration(o);
-if (codemaker::cppumaker::dumpNamespaceClose(o, m_typeName, false)) {
-o  \n;
-}
-
-o  \ninline const ::com::sun::star::uno::Type SAL_CALL getCppuType( ;
-dumpType(o, m_typeName, sal_True, sal_False);
-o  * ) SAL_THROW( () );\n\n;
-
-o  #endif //  headerDefine  \n;
+dumpHFileContent(o, includes);
 return sal_True;
 }
 
-sal_Bool InterfaceType::dumpDeclaration(FileStream o)
+void InterfaceType::dumpDeclaration(FileStream o)
 throw( CannotDumpException )
 {
 // rtl::OString cppName(translateUnoToCppIdentifier(
@@ -1323,8 +1343,6 @@ sal_Bool InterfaceType::dumpDeclaration(FileStream o)
 
 dec();
 o  };\n\n;
-
-return sal_True;
 }
 
 sal_Bool InterfaceType::dumpHxxFile(
@@ -2283,7 +2301,7 @@ sal_Bool ConstantsType::dumpHFile(
 return sal_True;
 }
 
-sal_Bool ConstantsType::dumpDeclaration(FileStream o)
+void ConstantsType::dumpDeclaration(FileStream o)
 throw( CannotDumpException )
 {
 sal_uInt16  fieldCount = m_reader.getFieldCount();
@@ -2302,8 +2320,6 @@ sal_Bool ConstantsType::dumpDeclaration(FileStream o)
 dumpConstantValue(o, i);
 o  ;\n;
 }
-
-return sal_True;
 }
 
 sal_Bool ConstantsType::hasConstants()
@@ -2395,38 +2411,11 @@ sal_Bool StructureType::dumpHFile(
 FileStream o, codemaker::cppumaker::Includes  includes)
 

[Libreoffice-commits] .: configure.in libxmlsec/makefile.mk moz/extractfiles.mk moz/makefile.mk nss/makefile.mk nss/readme.txt set_soenv.in xmlsecurity/Library_xsec_xmlsec.mk xmlsecurity/Module_xmlsec

2011-11-02 Thread Jan Holesovsky
 configure.in   |   77 +
 libxmlsec/makefile.mk  |8 +--
 moz/extractfiles.mk|   18 
 moz/makefile.mk|2 
 nss/makefile.mk|4 -
 nss/readme.txt |2 
 set_soenv.in   |   10 +---
 xmlsecurity/Library_xsec_xmlsec.mk |   11 +
 xmlsecurity/Module_xmlsecurity.mk  |2 
 9 files changed, 55 insertions(+), 79 deletions(-)

New commits:
commit f6f5c89259867b5aeb86d5509f826da949d122c4
Author: Tomas Chvatal tchva...@suse.cz
Date:   Wed Nov 2 17:36:27 2011 +0100

Rename --enable-nss-module to --with-system-nss + introduce --enable-xmlsec.

This also finishes the uncoupling of NSS from the --with-system-mozilla.

diff --git a/configure.in b/configure.in
index a260a0a..b69aeb6 100644
--- a/configure.in
+++ b/configure.in
@@ -361,10 +361,10 @@ AC_ARG_ENABLE(build-mozilla,
  the Mozilla source code but take precompiled zips.]),
 ,)
 
-AC_ARG_ENABLE(nss-module,
-AS_HELP_STRING([--disable-nss-module],
-[Whether to use provided NSS module.]),
-,enable_nss_module=yes)
+AC_ARG_ENABLE(xmlsec,
+AS_HELP_STRING([--disable-xmlsec],
+[Whether to enable XMLsec for open document signing.]),
+)
 
 AC_ARG_ENABLE(kde,
 AS_HELP_STRING([--enable-kde],
@@ -643,6 +643,11 @@ AC_ARG_WITH(system-cairo,
 [Use Cairo libraries already on system.]),
 ,)
 
+AC_ARG_WITH(system-nss,
+AS_HELP_STRING([--with-system-nss],
+[Use NSS/nspr libraries already on system.]),
+,)
+
 AC_ARG_WITH(mozilla-version,
 AS_HELP_STRING([--with-mozilla-version],
 [Choose which version of Mozilla to use while building Mozilla.
@@ -5723,11 +5728,14 @@ else
 fi
 
 AC_MSG_CHECKING([whether to build XML Security support])
-if test $enable_nss_module = no; then
-AC_MSG_RESULT([no, NSS disabled])
+if test $enable_xmlsec = no; then
+AC_MSG_RESULT([no])
+ENABLE_XMLSEC=no
 else
+ENABLE_XMLSEC=yes
 AC_MSG_RESULT([yes])
 fi
+AC_SUBST(ENABLE_XMLSEC)
 
 AC_MSG_CHECKING([whether to build LDAP configuration backend])
 if test -z $enable_ldap || test $enable_ldap = yes; then
@@ -5776,8 +5784,6 @@ AC_MSG_CHECKING([which Mozilla to use])
 if test -n $with_system_mozilla  test $with_system_mozilla != no; then
 AC_MSG_RESULT([external])
 SYSTEM_MOZILLA=YES
-ENABLE_NSS_MODULE=NO
-enable_nss_module=no
 AC_MSG_CHECKING([which Mozilla flavour to use])
 if test -n $with_system_mozilla  test $with_system_mozilla = 
libxul; then
 MOZ_FLAVOUR=libxul
@@ -5795,22 +5801,6 @@ if test -n $with_system_mozilla  test 
$with_system_mozilla != no; then
 tmp=`echo $MOZ_FLAVOUR | $PERL -e 'print ucfirst(STDIN);'`
 AC_MSG_RESULT($tmp)
 
-PKG_CHECK_MODULES( MOZ_NSS, nss, STANDALONENSS=TRUE, STANDALONENSS= )
-if test -z $STANDALONENSS; then
-PKG_CHECK_MODULES( MOZ_NSS, $MOZ_FLAVOUR-nss )
-else
-NSS_LIB=-L`$PKG_CONFIG --variable=libdir nss`
-AC_SUBST(NSS_LIB)
-fi
-
-if $PKG_CONFIG --exists nspr ; then
-PKG_CHECK_MODULES( MOZ_NSPR, nspr )
-NSPR_LIB=-L`$PKG_CONFIG --variable=libdir nspr`
-AC_SUBST(NSPR_LIB)
-else
-PKG_CHECK_MODULES( MOZ_NSPR, $MOZ_FLAVOUR-nspr )
-fi
-
 if test $MOZ_FLAVOUR != libxul; then
 PKG_CHECK_MODULES( MOZILLAXPCOM, $MOZ_FLAVOUR-xpcom, HASXPCOM=TRUE, 
HASXPCOM= )
 MOZ_INC=`$PKG_CONFIG --variable=includedir $MOZ_FLAVOUR-xpcom`
@@ -5829,19 +5819,6 @@ if test -n $with_system_mozilla  test 
$with_system_mozilla != no; then
 fi
 fi
 
-save_CPPFLAGS=$CPPFLAGS
-save_LDFLAGS=$LDFLAGS
-save_LIBS=$LIBS
-CPPFLAGS=$CPPFLAGS $MOZ_NSS_CFLAGS
-LDFLAGS=$LDFLAGS $MOZ_NSS_LIBS
-AC_CHECK_LIB(nss3, PK11_GetCertFromPrivateKey, [],
-  [AC_MSG_ERROR(PK11_GetCertFromPrivateKey missing but needed.
-See https://bugzilla.mozilla.org/show_bug.cgi?id=262274.
-Fixed since nss 3.9.3 (contained by e.g. mozilla = 1.7.5))], [])
-LDFLAGS=$save_LDFLAGS
-CPPFLAGS=$save_CPPFLAGS
-LIBS=$save_LIBS
-
 MOZ_LIB_XPCOM=$MOZILLAXPCOM_LIBS
 if test $WITH_LDAP != NO  test $WITH_OPENLDAP != YES; then
 AC_MSG_CHECKING([whether $tmp was compiled with --enable-ldap])
@@ -6001,18 +5978,22 @@ AC_SUBST(MOZ_FLAVOUR)
 AC_SUBST(MOZ_INC)
 AC_SUBST(MOZ_LIB)
 AC_SUBST(MOZ_LIB_XPCOM)
-AC_SUBST(MOZ_NSPR_CFLAGS)
-AC_SUBST(MOZ_NSS_CFLAGS)
 AC_SUBST(MOZ_LDAP_CFLAGS)
 
 dnl ===
-dnl Check for system NSS
+dnl Check for system NSS only with xmlsec or mozilla build enabled
 dnl ===
-AC_MSG_CHECKING([whether to build provided NSS module])
-if test $enable_nss_module != no; then
-ENABLE_NSS_MODULE=YES
+if test x$enable_xmlsec != xno -o x$enable_mozilla = xyes; then
+AC_MSG_CHECKING([which NSS to use])
+if test -n $with_system_nss -o -n 

[Libreoffice-commits] .: vcl/inc vcl/unx

2011-11-02 Thread Michael Meeks
 vcl/inc/unx/gtk/gtkgdi.hxx|   17 
 vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx |  949 --
 2 files changed, 772 insertions(+), 194 deletions(-)

New commits:
commit 625afed7a89732decb068a12bb526fb406cd2c7f
Author: Cosimo Cecchi cosi...@gnome.org
Date:   Wed Nov 2 12:02:09 2011 -0400

gtk3: improve the GTK3 theming layer somewhat

Improvements include:
- don't create widgets when calculating the native region size, but use
  GtkStyleContext instead
- refactor the native control drawing cycle
- theme scrollbars
- theme menu radios/checks/separators/arrows

diff --git a/vcl/inc/unx/gtk/gtkgdi.hxx b/vcl/inc/unx/gtk/gtkgdi.hxx
index 4604751..cbf2500 100644
--- a/vcl/inc/unx/gtk/gtkgdi.hxx
+++ b/vcl/inc/unx/gtk/gtkgdi.hxx
@@ -72,10 +72,21 @@ private:
 static GtkStyleContext *mpToolbarStyle;
 static GtkStyleContext *mpToolButtonStyle;
 static GtkStyleContext *mpCheckButtonStyle;
-void renderAreaToPix( cairo_t* cr, cairo_rectangle_t* rect );
-void drawStyleContext( GtkStyleContext* style, GtkStateFlags flags,
-const Rectangle rControlRegion, bool render_background = true );
+static GtkStyleContext *mpMenuBarStyle;
+static GtkStyleContext *mpMenuBarItemStyle;
+static GtkStyleContext *mpMenuStyle;
+static GtkStyleContext *mpMenuItemStyle;
+static GtkStyleContext *mpTooltipStyle;
+
+void renderAreaToPix( cairo_t* cr, cairo_rectangle_int_t *region );
 void getStyleContext( GtkStyleContext** style, GtkWidget* widget );
+Rectangle NWGetScrollButtonRect( ControlPart nPart, Rectangle aAreaRect );
+void PaintScrollbar(GtkStyleContext *context,
+cairo_t *cr,
+const Rectangle rControlRectangle,
+ControlPart nPart,
+const ImplControlValue aValue );
+
 static bool style_loaded;
 };
 
diff --git a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx 
b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx
index fb88bc4..b9100f0 100644
--- a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx
+++ b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx
@@ -40,6 +40,11 @@ GtkStyleContext* GtkSalGraphics::mpScrollbarStyle = NULL;
 GtkStyleContext* GtkSalGraphics::mpToolbarStyle = NULL;
 GtkStyleContext* GtkSalGraphics::mpToolButtonStyle = NULL;
 GtkStyleContext* GtkSalGraphics::mpCheckButtonStyle = NULL;
+GtkStyleContext* GtkSalGraphics::mpMenuBarStyle = NULL;
+GtkStyleContext* GtkSalGraphics::mpMenuBarItemStyle = NULL;
+GtkStyleContext* GtkSalGraphics::mpMenuStyle = NULL;
+GtkStyleContext* GtkSalGraphics::mpMenuItemStyle = NULL;
+
 bool GtkSalGraphics::style_loaded = false;
 /
  * State conversion
@@ -48,99 +53,412 @@ static void NWConvertVCLStateToGTKState( ControlState 
nVCLState,
 GtkStateFlags* nGTKState, GtkShadowType* nGTKShadow )
 {
 *nGTKShadow = GTK_SHADOW_OUT;
-*nGTKState = GTK_STATE_FLAG_INSENSITIVE;
+*nGTKState = GTK_STATE_FLAG_NORMAL;
+
+if (!( nVCLState  CTRL_STATE_ENABLED ))
+*nGTKState = GTK_STATE_FLAG_INSENSITIVE;
+
+if ( nVCLState  CTRL_STATE_PRESSED )
+{
+*nGTKState = (GtkStateFlags) (*nGTKState | GTK_STATE_FLAG_ACTIVE);
+*nGTKShadow = GTK_SHADOW_IN;
+}
+
+if ( nVCLState  CTRL_STATE_ROLLOVER )
+*nGTKState = (GtkStateFlags) (*nGTKState | GTK_STATE_FLAG_PRELIGHT);
+
+if ( nVCLState  CTRL_STATE_SELECTED )
+*nGTKState = (GtkStateFlags) (*nGTKState | GTK_STATE_FLAG_SELECTED);
+
+if ( nVCLState  CTRL_STATE_FOCUSED )
+*nGTKState = (GtkStateFlags) (*nGTKState | GTK_STATE_FLAG_FOCUSED);
+}
+
+enum {
+RENDER_BACKGROUND_AND_FRAME = 1,
+RENDER_CHECK = 2,
+RENDER_BACKGROUND = 3,
+RENDER_LINE = 4,
+RENDER_ARROW = 5,
+RENDER_RADIO = 6,
+RENDER_SCROLLBAR = 7,
+};
+
+static void NWCalcArrowRect( const Rectangle rButton, Rectangle rArrow )
+{
+// Size the arrow appropriately
+Size aSize( rButton.GetWidth()/2, rButton.GetHeight()/2 );
+rArrow.SetSize( aSize );
+
+rArrow.SetPos( Point(
+rButton.Left() + ( rButton.GetWidth()  - rArrow.GetWidth()  ) / 2,
+rButton.Top() + ( rButton.GetHeight() - rArrow.GetHeight() ) / 2
+) );
+}
+
+Rectangle GtkSalGraphics::NWGetScrollButtonRect( ControlPart nPart, Rectangle 
aAreaRect )
+{
+gint slider_width;
+gint stepper_size;
+gint stepper_spacing;
+gint trough_border;
 
-if ( nVCLState  CTRL_STATE_ENABLED )
+// Grab some button style attributes
+gtk_style_context_get_style( mpScrollbarStyle,
+ slider-width, slider_width,
+ stepper-size, stepper_size,
+ trough-border, trough_border,
+ stepper-spacing, stepper_spacing, (char 
*)NULL );
+  
+gboolean has_forward;
+gboolean 

[Libreoffice-commits] .: dictionaries/pt_PT

2011-11-02 Thread René Engelhard
 dictionaries/pt_PT/dictionaries.xcu.bak |   44 
 1 file changed, 44 deletions(-)

New commits:
commit ca7e6f5cabfeaa82aa4479b8aa1151c26d903993
Author: Rene Engelhard r...@debian.org
Date:   Wed Nov 2 18:24:33 2011 +0100

remove bogus dictionaries/pt_PT/dictionaries.xcu.bak

diff --git a/dictionaries/pt_PT/dictionaries.xcu.bak 
b/dictionaries/pt_PT/dictionaries.xcu.bak
deleted file mode 100644
index 0979975..000
--- a/dictionaries/pt_PT/dictionaries.xcu.bak
+++ /dev/null
@@ -1,44 +0,0 @@
-?xml version=1.0 encoding=UTF-8?
-oor:component-data xmlns:oor=http://openoffice.org/2001/registry; 
xmlns:xs=http://www.w3.org/2001/XMLSchema; oor:name=Linguistic 
oor:package=org.openoffice.Office
- node oor:name=ServiceManager
-node oor:name=Dictionaries
-node oor:name=HunSpellDic_pt_PT oor:op=fuse
-prop oor:name=Locations oor:type=oor:string-list
-value%origin%/dictionaries/pt_PT.aff 
%origin%/dictionaries/pt_PT.dic/value
-/prop
-prop oor:name=Format oor:type=xs:string
-valueDICT_SPELL/value
-/prop
-prop oor:name=Locales oor:type=oor:string-list
-valuept-PT/value
-/prop
-/node
-
-node oor:name=HyphDic_pt_PT oor:op=fuse
-prop oor:name=Locations oor:type=oor:string-list
-value%origin%/dictionaries/hyph_pt_PT.dic/value
-/prop
-prop oor:name=Format oor:type=xs:string
-valueDICT_HYPH/value
-/prop
-prop oor:name=Locales oor:type=oor:string-list
-valuept-PT/value
-/prop
-/node
-
-node oor:name=ThesDic_pt_PT oor:op=fuse
-prop oor:name=Locations oor:type=oor:string-list
-value%origin%/dictionaries/th_pt_PT_v2.dat 
%origin%/dictionaries/th_pt_PT_v2.idx/value
-/prop
-prop oor:name=Format oor:type=xs:string
-valueDICT_THES/value
-/prop
-prop oor:name=Locales oor:type=oor:string-list
-valuept-PT/value
-/prop
-/node
-/node
- /node  
-/oor:component-data
-
-
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: set_soenv.in

2011-11-02 Thread René Engelhard
 set_soenv.in |1 -
 1 file changed, 1 deletion(-)

New commits:
commit a5925095882efee3cd2cfbecfdb43c72b47caf34
Author: Rene Engelhard r...@debian.org
Date:   Wed Nov 2 17:35:05 2011 +

remove obsolete @SYSTEM_TRANSLATE_TOOLKIT@ from set_soenv.in

diff --git a/set_soenv.in b/set_soenv.in
index 6a97b45..0344653 100755
--- a/set_soenv.in
+++ b/set_soenv.in
@@ -1927,7 +1927,6 @@ ToFile( WITH_EXTRA_GALLERY,   
@WITH_EXTRA_GALLERY@,  e );
 ToFile( WITH_EXTRA_TEMPLATE,   @WITH_EXTRA_TEMPLATE@,  e );
 ToFile( WITH_EXTRA_SAMPLE,   @WITH_EXTRA_SAMPLE@,  e );
 ToFile( WITH_EXTRA_FONT,   @WITH_EXTRA_FONT@,  e );
-ToFile( SYSTEM_TRANSLATE_TOOLKIT, @SYSTEM_TRANSLATE_TOOLKIT@,e );
 ToFile( SYSTEM_DB, @SYSTEM_DB@,e );
 ToFile( SYSTEM_DB_CFLAGS,  @SYSTEM_DB_CFLAGS@, e );
 ToFile( DB_LIB,@DB_LIB@,   e );
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: 2 commits - fpicker/source

2011-11-02 Thread Michael Meeks
 fpicker/source/unx/gnome/SalGtkFilePicker.cxx   |  127 +---
 fpicker/source/unx/gnome/SalGtkFilePicker.hxx   |   11 +-
 fpicker/source/unx/gnome/SalGtkFolderPicker.cxx |   18 ++-
 fpicker/source/unx/gnome/SalGtkPicker.cxx   |   37 +++---
 fpicker/source/unx/gnome/SalGtkPicker.hxx   |2 
 5 files changed, 106 insertions(+), 89 deletions(-)

New commits:
commit 32af4b5f3ae56afaf0fcf9a1b08e220723ff7be8
Author: Michael Meeks michael.me...@suse.com
Date:   Wed Nov 2 17:42:23 2011 +

more fpicker related gtk cleanup

diff --git a/fpicker/source/unx/gnome/SalGtkFilePicker.hxx 
b/fpicker/source/unx/gnome/SalGtkFilePicker.hxx
index e15de9c..832e944 100644
--- a/fpicker/source/unx/gnome/SalGtkFilePicker.hxx
+++ b/fpicker/source/unx/gnome/SalGtkFilePicker.hxx
@@ -108,7 +108,7 @@ class SalGtkFilePicker :
 virtual void SAL_CALL setTitle( const ::rtl::OUString aTitle )
 throw( ::com::sun::star::uno::RuntimeException );
 
-virtual sal_Int16 SAL_CALL execute(  )
+virtual sal_Int16 SAL_CALL execute()
 throw( ::com::sun::star::uno::RuntimeException );
 
 
//
diff --git a/fpicker/source/unx/gnome/SalGtkPicker.cxx 
b/fpicker/source/unx/gnome/SalGtkPicker.cxx
index e3283e3..d52c2c6 100644
--- a/fpicker/source/unx/gnome/SalGtkPicker.cxx
+++ b/fpicker/source/unx/gnome/SalGtkPicker.cxx
@@ -118,18 +118,17 @@ rtl::OString SalGtkPicker::unicodetouri(const 
rtl::OUString rURL)
 return sURL;
 }
 
-gboolean canceldialog(RunDialog *pDialog)
-{
-GdkThreadLock lock;
-
-pDialog-cancel();
-return false;
-}
-
 extern C
 {
 struct Display;
 extern GdkDisplay* gdk_x11_lookup_xdisplay (void*xdisplay);
+
+static gboolean canceldialog(RunDialog *pDialog)
+{
+GdkThreadLock lock;
+pDialog-cancel();
+return false;
+}
 }
 
 RunDialog::RunDialog( GtkWidget *pDialog, uno::Reference 
awt::XExtendedToolkit  rToolkit,
@@ -176,9 +175,9 @@ RunDialog::~RunDialog()
 SolarMutexGuard g;
 
 if (mpCreatedParent)
-{
 gdk_window_destroy (mpCreatedParent);
-}
+
+g_source_remove_by_user_data (this);
 }
 
 void SAL_CALL RunDialog::windowOpened( const 
::com::sun::star::lang::EventObject )
commit 861a1c2dea41c141bffce54c30d53e65b7b88973
Author: Michael Stahl mst...@redhat.com
Date:   Wed Nov 2 17:34:55 2011 +

cleanup gtk / gdk locking situation to use the SolarMutex instead

The SolarMutex is integrated with native gtk+ toolkit locking so
this is semantically equivalent and rather less problematic.

diff --git a/fpicker/source/unx/gnome/SalGtkFilePicker.cxx 
b/fpicker/source/unx/gnome/SalGtkFilePicker.cxx
index 9b5051a..1cac989 100644
--- a/fpicker/source/unx/gnome/SalGtkFilePicker.cxx
+++ b/fpicker/source/unx/gnome/SalGtkFilePicker.cxx
@@ -51,6 +51,8 @@
 #include osl/mutex.hxx
 #include SalGtkFilePicker.hxx
 
+#include vcl/svapp.hxx
+
 #include tools/string.hxx
 #include tools/urlobj.hxx
 
@@ -98,8 +100,6 @@ namespace
 
 static void expandexpanders(GtkContainer *pWidget)
 {
-GdkThreadLock aLock;
-
 GList *pChildren = gtk_container_get_children(pWidget);
 for( GList *p = pChildren; p; p = p-next )
 {
@@ -118,8 +118,6 @@ void SalGtkFilePicker::dialog_mapped_cb(GtkWidget *, 
SalGtkFilePicker *pobjFP)
 
 void SalGtkFilePicker::InitialMapping()
 {
-GdkThreadLock aLock;
-
 if (!mbPreviewState )
 {
 gtk_widget_hide( m_pPreview );
@@ -180,8 +178,6 @@ SalGtkFilePicker::SalGtkFilePicker( const 
uno::Referencelang::XMultiServiceFact
 CResourceProvider aResProvider;
 OUString aFilePickerTitle = aResProvider.getResString( 
FILE_PICKER_TITLE_OPEN );
 
-GdkThreadLock aLock;
-
 m_pDialog = gtk_file_chooser_dialog_new(
 OUStringToOString( aFilePickerTitle, RTL_TEXTENCODING_UTF8 
).getStr(),
 NULL,
@@ -359,12 +355,18 @@ SalGtkFilePicker::SalGtkFilePicker( const 
uno::Referencelang::XMultiServiceFact
 void SAL_CALL SalGtkFilePicker::addFilePickerListener( const 
uno::ReferenceXFilePickerListener xListener )
 throw( uno::RuntimeException )
 {
+SolarMutexGuard g;
+
+OSL_ENSURE(!m_xListener.is(),
+SalGtkFilePicker only talks with one listener at a time...);
 m_xListener = xListener;
 }
 
 void SAL_CALL SalGtkFilePicker::removeFilePickerListener( const 
uno::ReferenceXFilePickerListener )
 throw( uno::RuntimeException )
 {
+SolarMutexGuard g;
+
 m_xListener.clear();
 }
 
@@ -374,6 +376,8 @@ void SAL_CALL SalGtkFilePicker::removeFilePickerListener( 
const uno::ReferenceX
 
 void SAL_CALL SalGtkFilePicker::disposing( const lang::EventObject aEvent ) 
throw( uno::RuntimeException )
 {
+// no member access = no mutex needed
+
 uno::ReferenceXFilePickerListener xFilePickerListener( aEvent.Source, 
::com::sun::star::uno::UNO_QUERY );
 
 if( xFilePickerListener.is() )
@@ -384,19 +388,19 

[Libreoffice-commits] .: sw/source

2011-11-02 Thread Ivan Timofeev
 sw/source/core/doc/doc.cxx |   95 +++--
 1 file changed, 15 insertions(+), 80 deletions(-)

New commits:
commit 0847d1cb9868396cbcdf59b1a389dc88bcd5b71e
Author: Ivan Timofeev timofeev@gmail.com
Date:   Mon Oct 31 11:59:07 2011 +0400

simplify determination of pages to print

diff --git a/sw/source/core/doc/doc.cxx b/sw/source/core/doc/doc.cxx
index c512862..b3d9472 100644
--- a/sw/source/core/doc/doc.cxx
+++ b/sw/source/core/doc/doc.cxx
@@ -1253,92 +1253,27 @@ void SwDoc::CalculatePagesForPrinting(
 // #i103700# printing selections should not allow for automatic inserting 
empty pages
 bool bPrintEmptyPages   = bPrintSelection ? false : 
rOptions.IsPrintEmptyPages( bIsPDFExport );
 
-Range aPages( 1, nDocPageCount );
-
-MultiSelection aMulti( aPages );
-aMulti.SetTotalRange( Range( 0, RANGE_MAX ) );
-aMulti.Select( aPages );
-
-const SwPageFrm *pStPage  = dynamic_castconst SwPageFrm*( 
rLayout.Lower() );
-const SwFrm *pEndPage = pStPage;
-
-sal_uInt16 nFirstPageNo = 0;
-sal_uInt16 nLastPageNo  = 0;
-
-for( sal_uInt16 i = 1; i = (sal_uInt16)aPages.Max(); ++i )
-{
-if( i  (sal_uInt16)aPages.Min() )
-{
-if( !pStPage-GetNext() )
-break;
-pStPage = (SwPageFrm*)pStPage-GetNext();
-pEndPage= pStPage;
-}
-else if( i == (sal_uInt16)aPages.Min() )
-{
-nFirstPageNo = i;
-nLastPageNo = nFirstPageNo;
-if( !pStPage-GetNext() || (i == (sal_uInt16)aPages.Max()) )
-break;
-pEndPage = pStPage-GetNext();
-}
-else if( i  (sal_uInt16)aPages.Min() )
-{
-nLastPageNo = i;
-if( !pEndPage-GetNext() || (i == (sal_uInt16)aPages.Max()) )
-break;
-pEndPage = pEndPage-GetNext();
-}
-}
+std::map sal_Int32, sal_Int32  rPrinterPaperTrays = 
rData.GetPrinterPaperTrays();
+std::set sal_Int32  rValidPages = rData.GetValidPagesSet();
+rValidPages.clear();
 
-OSL_ENSURE( nFirstPageNo, first page not found!  Should not happen! );
-if (nFirstPageNo)
+sal_Int32 nPageNum = 1;
+const SwPageFrm *pStPage = dynamic_castconst SwPageFrm*( rLayout.Lower() 
);
+while (pStPage  nPageNum = nDocPageCount)
 {
-// HACK: Hier muss von der MultiSelection noch eine akzeptable Moeglichkeit
-// geschaffen werden, alle Seiten von Seite x an zu deselektieren.
-// Z.B. durch SetTotalRange 
+const bool bPrintThisPage =
+( (bPrintRightPages  pStPage-OnRightPage()) ||
+  (bPrintLeftPages  !pStPage-OnRightPage()) ) 
+( bPrintEmptyPages || pStPage-Frm().Height() );
 
-//  aMulti.Select( Range( nLastPageNo+1, SELECTION_MAX ), 
sal_False );
-MultiSelection aTmpMulti( Range( 1, nLastPageNo ) );
-long nTmpIdx = aMulti.FirstSelected();
-static long nEndOfSelection = SFX_ENDOFSELECTION;
-while ( nEndOfSelection != nTmpIdx  nTmpIdx = long(nLastPageNo) )
+if (bPrintThisPage)
 {
-aTmpMulti.Select( nTmpIdx );
-nTmpIdx = aMulti.NextSelected();
+rValidPages.insert( nPageNum );
+rPrinterPaperTrays[ nPageNum ] = lcl_GetPaperBin( pStPage );
 }
-aMulti = aTmpMulti;
-// Ende des HACKs
-
-sal_uInt16 nPageNo = nFirstPageNo;
-
-std::map sal_Int32, sal_Int32  rPrinterPaperTrays = 
rData.GetPrinterPaperTrays();
-std::set sal_Int32  rValidPages = rData.GetValidPagesSet();
-rValidPages.clear();
-while ( pStPage )
-{
-const sal_Bool bRightPg = pStPage-OnRightPage();
-if ( aMulti.IsSelected( nPageNo ) 
-( (bRightPg  bPrintRightPages) ||
-(!bRightPg  bPrintLeftPages) ) )
-{
-// Feature - Print empty pages
-if ( bPrintEmptyPages || pStPage-Frm().Height() )
-{
-rValidPages.insert( nPageNo );
-rPrinterPaperTrays[ nPageNo ] = lcl_GetPaperBin( pStPage );
-}
-}
 
-if ( pStPage == pEndPage )
-{
-pStPage = 0;
-}
-else
-{   ++nPageNo;
-pStPage = (SwPageFrm*)pStPage-GetNext();
-}
-}
+++nPageNum;
+pStPage = (SwPageFrm*)pStPage-GetNext();
 }
 
 
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] Changes to 'feature/cell-format-data-bar'

2011-11-02 Thread Kohei Yoshida
New branch 'feature/cell-format-data-bar' available with the following commits:
commit 7cd72f2ef8d441802edc476ad549bb785da6
Author: Michael Meeks michael.me...@suse.com
Date:   Wed Nov 2 14:24:31 2011 -0400

Initial proof-of-concept patch.

___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: 3 commits - sc/source

2011-11-02 Thread Kohei Yoshida
 sc/source/ui/inc/gridwin.hxx   |  109 +++-
 sc/source/ui/view/gridwin.cxx  |   87 ++-
 sc/source/ui/view/gridwin2.cxx |   10 +-
 sc/source/ui/view/gridwin3.cxx |   38 
 sc/source/ui/view/gridwin4.cxx |  183 +
 sc/source/ui/view/gridwin5.cxx |   22 ++--
 6 files changed, 137 insertions(+), 312 deletions(-)

New commits:
commit 08f73742b35ffbef96e470c61f9f86cd7d3ee2e1
Author: Kohei Yoshida kohei.yosh...@suse.com
Date:   Wed Nov 2 15:41:22 2011 -0400

More on sal_Bool to bool (in method signatures).

diff --git a/sc/source/ui/inc/gridwin.hxx b/sc/source/ui/inc/gridwin.hxx
index 3976c90..08e47a3 100644
--- a/sc/source/ui/inc/gridwin.hxx
+++ b/sc/source/ui/inc/gridwin.hxx
@@ -207,9 +207,9 @@ private:
 DECL_LINK( PopupModeEndHdl, FloatingWindow* );
 DECL_LINK( PopupSpellingHdl, SpellCallbackInfo* );
 
-sal_BoolTestMouse( const MouseEvent rMEvt, sal_Bool bAction );
+boolTestMouse( const MouseEvent rMEvt, bool bAction );
 
-sal_BoolDoPageFieldSelection( SCCOL nCol, SCROW nRow );
+boolDoPageFieldSelection( SCCOL nCol, SCROW nRow );
 boolDoAutoFilterButton( SCCOL nCol, SCROW nRow, const 
MouseEvent rMEvt );
 voidDoPushButton( SCCOL nCol, SCROW nRow, const MouseEvent 
rMEvt );
 
@@ -231,9 +231,9 @@ private:
 
 voidPagebreakMove( const MouseEvent rMEvt, sal_Bool bUp );
 
-voidUpdateDragRect( sal_Bool bShowRange, const Rectangle 
rPosRect );
+voidUpdateDragRect( bool bShowRange, const Rectangle rPosRect 
);
 
-sal_BoolIsAutoFilterActive( SCCOL nCol, SCROW nRow, SCTAB nTab 
);
+boolIsAutoFilterActive( SCCOL nCol, SCROW nRow, SCTAB nTab );
 voidExecFilter( sal_uLong nSel, SCCOL nCol, SCROW nRow,
 const String aValue, bool bCheckForDates );
 voidFilterSelect( sal_uLong nSel );
@@ -242,27 +242,27 @@ private:
 
 voidExecPageFieldSelect( SCCOL nCol, SCROW nRow, sal_Bool 
bHasSelection, const String rStr );
 
-sal_BoolHasScenarioButton( const Point rPosPixel, ScRange 
rScenRange );
+boolHasScenarioButton( const Point rPosPixel, ScRange 
rScenRange );
 
-sal_BoolDropScroll( const Point rMousePos );
+boolDropScroll( const Point rMousePos );
 
 sal_Int8AcceptPrivateDrop( const AcceptDropEvent rEvt );
 sal_Int8ExecutePrivateDrop( const ExecuteDropEvent rEvt );
 sal_Int8DropTransferObj( ScTransferObj* pTransObj, SCCOL 
nDestPosX, SCROW nDestPosY,
-const Point rLogicPos, sal_Int8 
nDndAction );
+ const Point rLogicPos, sal_Int8 
nDndAction );
 
 voidHandleMouseButtonDown( const MouseEvent rMEvt );
 
-sal_BoolDrawMouseButtonDown(const MouseEvent rMEvt);
-sal_BoolDrawMouseButtonUp(const MouseEvent rMEvt);
-sal_BoolDrawMouseMove(const MouseEvent rMEvt);
-sal_BoolDrawKeyInput(const KeyEvent rKEvt);
-sal_BoolDrawCommand(const CommandEvent rCEvt);
-sal_BoolDrawHasMarkedObj();
+boolDrawMouseButtonDown(const MouseEvent rMEvt);
+boolDrawMouseButtonUp(const MouseEvent rMEvt);
+boolDrawMouseMove(const MouseEvent rMEvt);
+boolDrawKeyInput(const KeyEvent rKEvt);
+boolDrawCommand(const CommandEvent rCEvt);
+boolDrawHasMarkedObj();
 voidDrawEndAction();
 voidDrawMarkDropObj( SdrObject* pObj );
 SdrObject*  GetEditObject();
-sal_BoolIsMyModel(SdrEditView* pSdrView);
+boolIsMyModel(SdrEditView* pSdrView);
 
 voidDrawRedraw( ScOutputData rOutputData, ScUpdateMode eMode, 
sal_uLong nLayer );
 voidDrawSdrGrid( const Rectangle rDrawingRect, OutputDevice* 
pContentDev );
@@ -271,10 +271,10 @@ private:
 
 voidDrawPagePreview( SCCOL nX1, SCROW nY1, SCCOL nX2, SCROW 
nY2, OutputDevice* pContentDev );
 
-sal_BoolGetEditUrl( const Point rPos,
-String* pName=0, String* pUrl=0, String* 
pTarget=0 );
-sal_BoolGetEditUrlOrError( sal_Bool bSpellErr, const Point 
rPos,
+boolGetEditUrl( const Point rPos,
 String* pName=0, String* pUrl=0, String* 
pTarget=0 );
+boolGetEditUrlOrError( bool bSpellErr, const Point rPos,
+   String* pName=0, String* pUrl=0, 
String* pTarget=0 );
 
 boolHitRangeFinder( const Point rMouse, bool rCorner, 
sal_uInt16* pIndex = NULL,
 SCsCOL* pAddX = NULL, SCsROW* pAddY = NULL 
);
@@ -338,7 

[Libreoffice-commits] .: RepositoryExternal.mk

2011-11-02 Thread Tomáš Chvátal
 RepositoryExternal.mk |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 75f77e63189607142d0a90047ac04cd415072174
Author: Tomas Chvatal tchva...@suse.cz
Date:   Wed Nov 2 21:16:53 2011 +0100

One more SYSTEM_MOZILLA to SYSTEM_NSS

diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk
index 8891d6b..d7ff86f 100644
--- a/RepositoryExternal.mk
+++ b/RepositoryExternal.mk
@@ -828,16 +828,16 @@ $(call gb_LinkTarget_add_libs,$(1), \
 
 endef
 
-ifeq ($(SYSTEM_MOZILLA),YES)
+ifeq ($(SYSTEM_NSS),YES)
 
 define gb_LinkTarget__use_plc4
 $(call gb_LinkTarget_set_include,$(1),\
 $$(INCLUDE) \
-$(MOZ_NSS_CFLAGS) \
+$(NSS_CFLAGS) \
 )
 
 $(call gb_LinkTarget_add_libs,$(1),\
-$(MOZ_NSS_LIBS) \
+$(NSS_LIBS) \
 )
 
 endef
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: binfilter/bf_offmgr binfilter/bf_svx binfilter/bf_sw binfilter/filter binfilter/inc binfilter/legacysmgr

2011-11-02 Thread Stephan Bergmann
 binfilter/bf_offmgr/source/offapp/app/offmgr_app.cxx  |2 
 binfilter/bf_svx/source/xoutdev/svx__xfont.cxx|5 +
 binfilter/bf_sw/source/core/bastyp/sw_breakit.cxx |3 -
 binfilter/bf_sw/source/core/bastyp/sw_checkit.cxx |1 
 binfilter/filter/source/bf_offwrp/bf_wrapper.cxx  |8 --
 binfilter/inc/bf_sd/build.lst |   20 ---
 binfilter/inc/legacysmgr/build.lst|4 -
 binfilter/inc/legacysmgr/legacy_binfilters_smgr.hxx   |   25 +
 binfilter/legacysmgr/source/legacy/gcc3.map   |1 
 binfilter/legacysmgr/source/legacy/legacy_binfilters_smgr.cxx |   27 ++
 binfilter/legacysmgr/source/legacy/mingw_intel.map|1 
 binfilter/legacysmgr/source/legacy/msci.map   |1 
 binfilter/legacysmgr/source/legacy/sols.map   |1 
 13 files changed, 29 insertions(+), 70 deletions(-)

New commits:
commit 82728f114d1f9f7b20f0c2e0e054cd2504a59b50
Author: Stephan Bergmann sberg...@redhat.com
Date:   Wed Nov 2 21:25:52 2011 +0100

Some minor clean up.

diff --git a/binfilter/bf_offmgr/source/offapp/app/offmgr_app.cxx 
b/binfilter/bf_offmgr/source/offapp/app/offmgr_app.cxx
index f6e72c3..61b486a 100644
--- a/binfilter/bf_offmgr/source/offapp/app/offmgr_app.cxx
+++ b/binfilter/bf_offmgr/source/offapp/app/offmgr_app.cxx
@@ -36,7 +36,9 @@
 #include bf_svx/svdoutl.hxx
 #include bf_svx/svxerr.hxx
 #include com/sun/star/container/XSet.hpp
+#include com/sun/star/lang/XSingleServiceFactory.hpp
 #include comphelper/processfactory.hxx
+#include cppuhelper/factory.hxx
 #include bf_svtools/pathoptions.hxx
 #include bf_svx/fmobjfac.hxx
 #include bf_svx/siimport.hxx
diff --git a/binfilter/bf_svx/source/xoutdev/svx__xfont.cxx 
b/binfilter/bf_svx/source/xoutdev/svx__xfont.cxx
index 0e963a1..fb2b6d6 100644
--- a/binfilter/bf_svx/source/xoutdev/svx__xfont.cxx
+++ b/binfilter/bf_svx/source/xoutdev/svx__xfont.cxx
@@ -35,9 +35,10 @@
 #include xoutx.hxx
 #include outliner.hxx
 
-#include com/sun/star/i18n/ScriptType.hdl
+#include com/sun/star/i18n/ScriptType.hpp
 #include com/sun/star/i18n/XBreakIterator.hpp
-#include com/sun/star/i18n/CharacterIteratorMode.hdl
+#include com/sun/star/i18n/CharacterIteratorMode.hpp
+#include com/sun/star/lang/XMultiServiceFactory.hpp
 
 #include unolingu.hxx
 #include legacysmgr/legacy_binfilters_smgr.hxx
diff --git a/binfilter/bf_sw/source/core/bastyp/sw_breakit.cxx 
b/binfilter/bf_sw/source/core/bastyp/sw_breakit.cxx
index 1bb4b90..c1fbd92 100644
--- a/binfilter/bf_sw/source/core/bastyp/sw_breakit.cxx
+++ b/binfilter/bf_sw/source/core/bastyp/sw_breakit.cxx
@@ -31,7 +31,8 @@
 #pragma hdrstop
 #endif
 
-#include com/sun/star/i18n/ScriptType.hdl
+#include com/sun/star/i18n/ScriptType.hpp
+#include com/sun/star/lang/XMultiServiceFactory.hpp
 #include unotools/localedatawrapper.hxx
 #include bf_svx/unolingu.hxx
 #include bf_svx/scripttypeitem.hxx
diff --git a/binfilter/bf_sw/source/core/bastyp/sw_checkit.cxx 
b/binfilter/bf_sw/source/core/bastyp/sw_checkit.cxx
index a8a2dae..fcbf345 100644
--- a/binfilter/bf_sw/source/core/bastyp/sw_checkit.cxx
+++ b/binfilter/bf_sw/source/core/bastyp/sw_checkit.cxx
@@ -32,6 +32,7 @@
 #endif
 
 #include checkit.hxx
+#include com/sun/star/lang/XMultiServiceFactory.hpp
 #include legacysmgr/legacy_binfilters_smgr.hxx
 namespace binfilter {
 using namespace ::com::sun::star::uno;
diff --git a/binfilter/filter/source/bf_offwrp/bf_wrapper.cxx 
b/binfilter/filter/source/bf_offwrp/bf_wrapper.cxx
index 6be3059..317a8d2 100644
--- a/binfilter/filter/source/bf_offwrp/bf_wrapper.cxx
+++ b/binfilter/filter/source/bf_offwrp/bf_wrapper.cxx
@@ -118,12 +118,6 @@ Reference XInterface   SAL_CALL 
bf_OfficeWrapper_CreateInstance( const Referen
 return (XComponent*)0;
 }
 
-extern C
-{
-//added for #i31251#
-void legcy_setBinfilterInitState(void);
-}
-
 bf_OfficeWrapper::bf_OfficeWrapper( const Reference  XMultiServiceFactory  )
 : pApp( new OfficeApplication )
 , aListeners( aMutex )
@@ -158,8 +152,6 @@ bf_OfficeWrapper::bf_OfficeWrapper( const Reference  
XMultiServiceFactory  )
 pSmDLL = new SmDLL;
 SmDLL::LibInit();
 }
-//added i#31251#
-legcy_setBinfilterInitState();
 }
 
 void SAL_CALL bf_OfficeWrapper::initialize( const Sequence Any  ) throw( 
Exception )
diff --git a/binfilter/inc/bf_sd/build.lst b/binfilter/inc/bf_sd/build.lst
deleted file mode 100644
index fadbbe8..000
--- a/binfilter/inc/bf_sd/build.lst
+++ /dev/null
@@ -1,20 +0,0 @@
-sd bf_sd   :   bf_offmgr bf_sc NULL
-sd bf_sd   
usr1-   all sd_mkout NULL
-sd bf_sd\inc   
get -   all sd_inc NULL
-sd bf_sd\prj   

[Libreoffice-commits] .: 7 commits - dbaccess/Library_dbu.mk dbaccess/Library_dbui.mk dbaccess/source sc/source sd/source sfx2/source sw/source unotools/Library_utl.mk unotools/Package_inc.mk unotools

2011-11-02 Thread Michael Stahl
 dbaccess/Library_dbu.mk  |1 
 dbaccess/Library_dbui.mk |1 
 dbaccess/source/ui/app/AppController.cxx |4 
 dbaccess/source/ui/app/closeveto.cxx |  183 ---
 dbaccess/source/ui/app/closeveto.hxx |   70 ---
 sc/source/ui/unoobj/docuno.cxx   |   15 ++
 sd/source/ui/view/DocumentRenderer.cxx   |   17 +-
 sfx2/source/view/viewprn.cxx |   23 +++
 sw/source/ui/uno/unotxdoc.cxx|   15 ++
 unotools/Library_utl.mk  |1 
 unotools/Package_inc.mk  |1 
 unotools/inc/unotools/closeveto.hxx  |   70 +++
 unotools/source/misc/closeveto.cxx   |  183 +++
 vcl/Library_vclplug_gtk3.mk  |2 
 vcl/generic/app/geninst.cxx  |1 
 vcl/source/gdi/print3.cxx|   22 +++
 16 files changed, 337 insertions(+), 272 deletions(-)

New commits:
commit 543c57eb87cf3f37c36c0f3d8cf669d9acbb9286
Merge: 75fe0e0... 75f77e6...
Author: Michael Stahl mst...@redhat.com
Date:   Wed Nov 2 21:58:35 2011 +0100

Merge branch 'master' of git://anongit.freedesktop.org/libreoffice/core

commit 75fe0e01d9ea7f6c832c75e3d074bea3f17a36ae
Author: Michael Stahl mst...@redhat.com
Date:   Wed Nov 2 18:12:33 2011 +0100

Library_vclplug_gtk3.mk: fix typo

diff --git a/vcl/Library_vclplug_gtk3.mk b/vcl/Library_vclplug_gtk3.mk
index 9c589ff..d328e81 100644
--- a/vcl/Library_vclplug_gtk3.mk
+++ b/vcl/Library_vclplug_gtk3.mk
@@ -79,7 +79,7 @@ $(eval $(call gb_Library_add_linked_libs,vclplug_gtk3,\
 $(gb_STDLIBS) \
 ))
 
-$(eval $(call gb_Library_use_externals,vclplug_gtk,\
+$(eval $(call gb_Library_use_externals,vclplug_gtk3,\
dbus \
 ))
 
commit 66d9925bb6e9c43aacfe9e4ac6f1ee10a8e25166
Merge: b2254d5... f6f5c89...
Author: Michael Stahl mst...@redhat.com
Date:   Wed Nov 2 17:49:42 2011 +0100

Merge branch 'master' of git://anongit.freedesktop.org/libreoffice/core

commit b2254d5d6fde8c28501e99e29bc824e935a25247
Author: Michael Stahl mst...@redhat.com
Date:   Wed Nov 2 13:21:14 2011 +0100

rhbz#657394: sd::DocumentRenderer:

Closing an Impress document while it is printing results in the document
being destroyed, but the DocumentRenderer still retaining views that
contain SfxItemSets that reference the document's SfxItemPool.
Prevent the crash by retaining a SfxObjectShellRef.

diff --git a/sd/source/ui/view/DocumentRenderer.cxx 
b/sd/source/ui/view/DocumentRenderer.cxx
index 9966f6c..0e79d61 100644
--- a/sd/source/ui/view/DocumentRenderer.cxx
+++ b/sd/source/ui/view/DocumentRenderer.cxx
@@ -1198,13 +1198,14 @@ class DocumentRenderer::Implementation
 {
 public:
 Implementation (ViewShellBase rBase)
-: mrBase(rBase),
-  mbIsDisposed(false),
-  mpPrinter(NULL),
-  mpOptions(),
-  maPrinterPages(),
-  mpPrintView(),
-  mbHasOrientationWarningBeenShown(false)
+: mxObjectShell(rBase.GetDocShell())
+, mrBase(rBase)
+, mbIsDisposed(false)
+, mpPrinter(NULL)
+, mpOptions()
+, maPrinterPages()
+, mpPrintView()
+, mbHasOrientationWarningBeenShown(false)
 {
 DialogCreator aCreator( mrBase.GetDocShell()-GetDocumentType() == 
DOCUMENT_TYPE_IMPRESS );
 m_aUIProperties = aCreator.GetDialogControls();
@@ -1400,6 +1401,8 @@ public:
 
 
 private:
+// rhbz#657394: keep the document alive: prevents crash when
+SfxObjectShellRef mxObjectShell; // destroying mpPrintView
 ViewShellBase mrBase;
 bool mbIsDisposed;
 Printer* mpPrinter;
commit d33e8d9bfecb7602b65b10d628c807e1ca2dccc2
Author: Michael Stahl mst...@redhat.com
Date:   Tue Nov 1 19:34:00 2011 +0100

SalYieldMutex::release(): add assertion

diff --git a/vcl/generic/app/geninst.cxx b/vcl/generic/app/geninst.cxx
index 24f4967..f958ea6 100644
--- a/vcl/generic/app/geninst.cxx
+++ b/vcl/generic/app/geninst.cxx
@@ -65,6 +65,7 @@ void SalYieldMutex::acquire()
 
 void SalYieldMutex::release()
 {
+OSL_ENSURE(mnCount  0, SalYieldMutex::release() called with zero count);
 if ( mnThreadId == osl::Thread::getCurrentIdentifier() )
 {
 if ( mnCount == 1 )
commit 7edb1da8c566c8c17b6bf9dd4f88101c14a07df8
Author: Michael Stahl mst...@redhat.com
Date:   Mon Oct 31 21:18:24 2011 +0100

move CloseVeto from dbaccess to unotools

diff --git a/dbaccess/Library_dbu.mk b/dbaccess/Library_dbu.mk
index 0f7ca59..0419c29 100644
--- a/dbaccess/Library_dbu.mk
+++ b/dbaccess/Library_dbu.mk
@@ -107,7 +107,6 @@ $(eval $(call gb_Library_add_exception_objects,dbu,\
 dbaccess/source/ui/app/AppSwapWindow \
 dbaccess/source/ui/app/AppTitleWindow \
 dbaccess/source/ui/app/AppView \
-dbaccess/source/ui/app/closeveto \
 dbaccess/source/ui/app/subcomponentmanager \
 dbaccess/source/ui/browser/AsyncronousLink \
 dbaccess/source/ui/browser/brwctrlr \
diff --git 

[Libreoffice-commits] Changes to 'feature/new-autofilter-popup'

2011-11-02 Thread Kohei Yoshida
New branch 'feature/new-autofilter-popup' available with the following commits:
commit d29b904213d0dd553978a8a49ed6c50ffde10c4b
Author: Kohei Yoshida kohei.yosh...@suse.com
Date:   Wed Nov 2 17:16:47 2011 -0400

Separate the code path and add new method for autofilter popup launch.

___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: Branch 'feature/new-autofilter-popup' - sc/source

2011-11-02 Thread Kohei Yoshida
 sc/source/ui/view/gridwin.cxx |   30 ++
 1 file changed, 30 insertions(+)

New commits:
commit 4bebac7302fbfe0939dbe1843f05afc9c46f6967
Author: Kohei Yoshida kohei.yosh...@suse.com
Date:   Wed Nov 2 22:05:07 2011 -0400

Populate the popup with unique values and the default action items.

diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index 558bd85..e38386c 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -585,17 +585,47 @@ void ScGridWindow::ExecPageFieldSelect( SCCOL nCol, SCROW 
nRow, sal_Bool bHasSel
 }
 }
 
+namespace {
+
+class PopupAction : public ScMenuFloatingWindow::Action
+{
+public:
+virtual void execute()
+{
+}
+};
+
+
+}
+
 void ScGridWindow::LaunchAutoFilterMenu(SCCOL nCol, SCROW nRow)
 {
 mpAutoFilterPopup.reset(new ScCheckListMenuWindow(this, 
pViewData-GetDocument()));
 Point aPos = pViewData-GetScrPos(nCol, nRow, eWhich);
+SCTAB nTab = pViewData-GetTabNo();
+ScDocument* pDoc = pViewData-GetDocument();
 long nSizeX  = 0;
 long nSizeY  = 0;
 pViewData-GetMergeSizePixel(nCol, nRow, nSizeX, nSizeY);
 Rectangle aCellRect(OutputToScreenPixel(aPos), Size(nSizeX, nSizeY));
 
 // Populate the check box list.
+bool bHasDates = false;
+TypedScStrCollection aStrings(128, 128);
+pDoc-GetFilterEntries(nCol, nRow, nTab, true, aStrings, bHasDates);
 
+sal_uInt16 nCount = aStrings.GetCount();
+mpAutoFilterPopup-setMemberSize(nCount);
+for (sal_uInt16 i = 0; i  nCount; ++i)
+mpAutoFilterPopup-addMember(aStrings[i]-GetString(), true);
+mpAutoFilterPopup-initMembers();
+
+// Populate the menu.
+
mpAutoFilterPopup-addMenuItem(ScResId::toString(ScResId(SCSTR_ALLFILTER)), 
true, new PopupAction);
+
mpAutoFilterPopup-addMenuItem(ScResId::toString(ScResId(SCSTR_TOP10FILTER)), 
true, new PopupAction);
+
mpAutoFilterPopup-addMenuItem(ScResId::toString(ScResId(SCSTR_STDFILTER)), 
true, new PopupAction);
+mpAutoFilterPopup-addMenuItem(ScResId::toString(ScResId(SCSTR_EMPTY)), 
true, new PopupAction);
+mpAutoFilterPopup-addMenuItem(ScResId::toString(ScResId(SCSTR_NOTEMPTY)), 
true, new PopupAction);
 
 mpAutoFilterPopup-SetPopupModeEndHdl( LINK(this, ScGridWindow, 
PopupModeEndHdl) );
 mpAutoFilterPopup-StartPopupMode(aCellRect, (FLOATWIN_POPUPMODE_DOWN | 
FLOATWIN_POPUPMODE_GRABFOCUS));
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: Branch 'feature/new-autofilter-popup' - sc/source

2011-11-02 Thread Kohei Yoshida
 sc/source/ui/cctrl/checklistmenu.cxx |  185 +++
 sc/source/ui/inc/checklistmenu.hxx   |   10 +
 sc/source/ui/view/gridwin.cxx|2 
 sc/source/ui/view/gridwin2.cxx   |2 
 4 files changed, 115 insertions(+), 84 deletions(-)

New commits:
commit 4384f07f0dc2f0fbd1043235eabeb268555431be
Author: Kohei Yoshida kohei.yosh...@suse.com
Date:   Wed Nov 2 23:44:00 2011 -0400

Calculate window size and geometries of controls based on menu items.

This makes the popup window more flexible and adjust to a varying number
of menu items.  This is necessary now that we use this popup in two
different places (autofilter and pivot table field popup) with different
menu item configurations.

diff --git a/sc/source/ui/cctrl/checklistmenu.cxx 
b/sc/source/ui/cctrl/checklistmenu.cxx
index 63a0f30..ed32c8f 100644
--- a/sc/source/ui/cctrl/checklistmenu.cxx
+++ b/sc/source/ui/cctrl/checklistmenu.cxx
@@ -261,6 +261,25 @@ ScMenuFloatingWindow* 
ScMenuFloatingWindow::addSubMenuItem(const OUString rText
 return aItem.mpSubMenuWin.get();
 }
 
+Size ScMenuFloatingWindow::getMenuSize() const
+{
+if (maMenuItems.empty())
+return Size();
+
+vectorMenuItemData::const_iterator itr = maMenuItems.begin(), itrEnd = 
maMenuItems.end();
+long nTextWidth = 0;
+for (; itr != itrEnd; ++itr)
+nTextWidth = ::std::max(GetTextWidth(itr-maText), nTextWidth);
+
+size_t nLastPos = maMenuItems.size()-1;
+Point aPos;
+Size aSize;
+getMenuItemPosSize(nLastPos, aPos, aSize);
+aPos.X() += nTextWidth + 15;
+aPos.Y() += aSize.Height() + 5;
+return Size(aPos.X(), aPos.Y());
+}
+
 void ScMenuFloatingWindow::drawMenuItem(size_t nPos)
 {
 if (nPos = maMenuItems.size())
@@ -471,21 +490,7 @@ ScDocument* ScMenuFloatingWindow::getDoc()
 
 void ScMenuFloatingWindow::resizeToFitMenuItems()
 {
-if (maMenuItems.empty())
-return;
-
-vectorMenuItemData::const_iterator itr = maMenuItems.begin(), itrEnd = 
maMenuItems.end();
-long nTextWidth = 0;
-for (; itr != itrEnd; ++itr)
-nTextWidth = ::std::max(GetTextWidth(itr-maText), nTextWidth);
-
-size_t nLastPos = maMenuItems.size()-1;
-Point aPos;
-Size aSize;
-getMenuItemPosSize(nLastPos, aPos, aSize);
-aPos.X() += nTextWidth + 15;
-aPos.Y() += aSize.Height() + 5;
-SetOutputSizePixel(Size(aPos.X(), aPos.Y()));
+SetOutputSizePixel(getMenuSize());
 }
 
 void ScMenuFloatingWindow::selectMenuItem(size_t nPos, bool bSelected, bool 
bSubMenuTimer)
@@ -768,7 +773,7 @@ ScCheckListMenuWindow::ScCheckListMenuWindow(Window* 
pParent, ScDocument* pDoc)
 mnCurTabStop(0),
 mpExtendedData(NULL),
 mpOKAction(NULL),
-maWndSize(240, 330),
+maWndSize(200, 330),
 mePrevToggleAllState(STATE_DONTKNOW)
 {
 maTabStopCtrls.reserve(7);
@@ -779,80 +784,34 @@ ScCheckListMenuWindow::ScCheckListMenuWindow(Window* 
pParent, ScDocument* pDoc)
 maTabStopCtrls.push_back(maBtnUnselectSingle);
 maTabStopCtrls.push_back(maBtnOk);
 maTabStopCtrls.push_back(maBtnCancel);
-
-const StyleSettings rStyle = GetSettings().GetStyleSettings();
-
-Point aPos;
-Size aSize;
-getSectionPosSize(aPos, aSize, WHOLE);
-SetOutputSizePixel(aSize);
-
-getSectionPosSize(aPos, aSize, BTN_OK);
-maBtnOk.SetPosSizePixel(aPos, aSize);
-maBtnOk.SetFont(getLabelFont());
-maBtnOk.SetClickHdl( LINK(this, ScCheckListMenuWindow, ButtonHdl) );
-maBtnOk.Show();
-
-getSectionPosSize(aPos, aSize, BTN_CANCEL);
-maBtnCancel.SetPosSizePixel(aPos, aSize);
-maBtnCancel.SetFont(getLabelFont());
-maBtnCancel.Show();
-
-getSectionPosSize(aPos, aSize, LISTBOX_AREA_INNER);
-maChecks.SetPosSizePixel(aPos, aSize);
-maChecks.SetFont(getLabelFont());
-maChecks.SetCheckButtonHdl( LINK(this, ScCheckListMenuWindow, CheckHdl) );
-maChecks.Show();
-
-getSectionPosSize(aPos, aSize, CHECK_TOGGLE_ALL);
-maChkToggleAll.SetPosSizePixel(aPos, aSize);
-maChkToggleAll.SetFont(getLabelFont());
-maChkToggleAll.SetText(ScRscStrLoader(RID_POPUP_FILTER, 
STR_BTN_TOGGLE_ALL).GetString());
-maChkToggleAll.SetTextColor(rStyle.GetMenuTextColor());
-maChkToggleAll.SetControlBackground(rStyle.GetMenuColor());
-maChkToggleAll.SetClickHdl( LINK(this, ScCheckListMenuWindow, TriStateHdl) 
);
-maChkToggleAll.Show();
-
-getSectionPosSize(aPos, aSize, BTN_SINGLE_SELECT);
-maBtnSelectSingle.SetPosSizePixel(aPos, aSize);
-maBtnSelectSingle.SetQuickHelpText(ScRscStrLoader(RID_POPUP_FILTER, 
STR_BTN_SELECT_CURRENT).GetString());
-maBtnSelectSingle.SetModeImage(Image(ScResId(RID_IMG_SELECT_CURRENT)));
-maBtnSelectSingle.SetClickHdl( LINK(this, ScCheckListMenuWindow, 
ButtonHdl) );
-maBtnSelectSingle.Show();
-
-getSectionPosSize(aPos, aSize, BTN_SINGLE_UNSELECT);
-maBtnUnselectSingle.SetPosSizePixel(aPos, aSize);
-