[Libreoffice-commits] .: sc/source
sc/source/ui/docshell/docsh.cxx | 41 +++- 1 file changed, 24 insertions(+), 17 deletions(-) New commits: commit fff1cec87f3c81904dad98b7a2ccd50138264791 Author: Christina Rossmanith chrrossman...@web.de Date: Fri Nov 11 23:09:26 2011 +0100 Remove String::Fill() usage diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx index 93bb4bc..4a0981d 100644 --- a/sc/source/ui/docshell/docsh.cxx +++ b/sc/source/ui/docshell/docsh.cxx @@ -134,6 +134,7 @@ #include rtl/logfile.hxx #include comphelper/processfactory.hxx +#include comphelper/string.hxx #include uiitems.hxx #include cellsuno.hxx #include dpobject.hxx @@ -1593,7 +1594,7 @@ sal_Bool ScDocShell::IsInformationLost() // Xcl-like column width measured in characters of standard font. -xub_StrLen lcl_ScDocShell_GetColWidthInChars( sal_uInt16 nWidth ) +sal_Int32 lcl_ScDocShell_GetColWidthInChars( sal_uInt16 nWidth ) { double f = nWidth; f *= 1328.0 / 25.0; @@ -1601,46 +1602,52 @@ xub_StrLen lcl_ScDocShell_GetColWidthInChars( sal_uInt16 nWidth ) f *= 1.0 / 23.0; f /= 256.0; -return xub_StrLen( f ); +return sal_Int32( f ); } void lcl_ScDocShell_GetFixedWidthString( rtl::OUString rStr, const ScDocument rDoc, SCTAB nTab, SCCOL nCol, sal_Bool bValue, SvxCellHorJustify eHorJust ) { -String aString = rStr; -xub_StrLen nLen = lcl_ScDocShell_GetColWidthInChars( +rtl::OUString aString = rStr; +sal_Int32 nLen = lcl_ScDocShell_GetColWidthInChars( rDoc.GetColWidth( nCol, nTab ) ); -if ( nLen aString.Len() ) +if ( nLen aString.getLength() ) { if ( bValue ) -aString.AssignAscii( ### ); -aString.Erase( nLen ); +aString = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ### )); } -if ( nLen aString.Len() ) +if ( nLen aString.getLength() ) { if ( bValue eHorJust == SVX_HOR_JUSTIFY_STANDARD ) eHorJust = SVX_HOR_JUSTIFY_RIGHT; +sal_Int32 nBlanks = nLen - aString.getLength(); switch ( eHorJust ) { case SVX_HOR_JUSTIFY_RIGHT: { -String aTmp; -aTmp.Fill( nLen - aString.Len() ); -aString.Insert( aTmp, 0 ); +rtl::OUStringBuffer aTmp; +aTmp = comphelper::string::padToLength( aTmp, nBlanks, ' ' ); +aString = aTmp.append(aString).makeStringAndClear(); } break; case SVX_HOR_JUSTIFY_CENTER: { -xub_StrLen nLen2 = (nLen - aString.Len()) / 2; -String aTmp; -aTmp.Fill( nLen2 ); -aString.Insert( aTmp, 0 ); -aString.Expand( nLen ); +sal_Int32 nLen2 = nBlanks / 2; +rtl::OUStringBuffer aLeft; +rtl::OUStringBuffer aRight; +aLeft = comphelper::string::padToLength( aLeft, nLen2, ' ' ); +aRight = comphelper::string::padToLength( aRight, nBlanks - nLen2, ' ' ); +aString = aLeft.append(aString).makeStringAndClear(); +aString += aRight.makeStringAndClear(); } break; default: -aString.Expand( nLen ); +{ +rtl::OUStringBuffer aTmp; +comphelper::string::padToLength( aTmp, nBlanks, ' ' ); +aString += aTmp.makeStringAndClear(); +} } } rStr = aString; ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: binfilter/bf_so3 binfilter/bf_starmath binfilter/bf_svtools
binfilter/bf_so3/source/dialog/insdlg.cxx |4 ++-- binfilter/bf_so3/source/dialog/plfilter.cxx |1 - binfilter/bf_so3/source/inplace/plugin.cxx |6 +++--- binfilter/bf_so3/source/persist/transuno.cxx|4 ++-- binfilter/bf_starmath/source/starmath_mathml.cxx|1 - binfilter/bf_starmath/source/starmath_unomodel.cxx |1 - binfilter/bf_svtools/source/config/svt_inetoptions.cxx |1 - binfilter/bf_svtools/source/config/svt_moduleoptions.cxx|4 ++-- binfilter/bf_svtools/source/config/svt_saveopt.cxx |6 +++--- binfilter/bf_svtools/source/config/svt_viewoptions.cxx |4 ++-- binfilter/bf_svtools/source/filter.vcl/filter/svt_FilterConfigCache.cxx |6 +++--- binfilter/bf_svtools/source/filter.vcl/filter/svt_FilterConfigItem.cxx |6 +++--- 12 files changed, 20 insertions(+), 24 deletions(-) New commits: commit 5d038379f98a0b0d636c84bb4414c410bc12771d Author: Stephan Bergmann sberg...@redhat.com Date: Mon Nov 14 11:49:53 2011 +0100 Removed comphelper - unotools processfactory.hxx duplication. diff --git a/binfilter/bf_so3/source/dialog/insdlg.cxx b/binfilter/bf_so3/source/dialog/insdlg.cxx index ea8083d..d9caf70 100644 --- a/binfilter/bf_so3/source/dialog/insdlg.cxx +++ b/binfilter/bf_so3/source/dialog/insdlg.cxx @@ -64,7 +64,7 @@ #include com/sun/star/container/XHierarchicalNameAccess.hpp #include com/sun/star/container/XNameAccess.hpp -#include unotools/processfactory.hxx +#include comphelper/processfactory.hxx #define _SVSTDARR_STRINGSDTOR #include bf_svtools/svstdarr.hxx @@ -121,7 +121,7 @@ void SvObjectServerList::FillInsertObjects() */ { try{ -Reference XMultiServiceFactory _globalMSFactory= utl::getProcessServiceFactory(); +Reference XMultiServiceFactory _globalMSFactory= comphelper::getProcessServiceFactory(); if( _globalMSFactory.is()) { OUString sProviderService( RTL_CONSTASCII_USTRINGPARAM( com.sun.star.configuration.ConfigurationProvider )); diff --git a/binfilter/bf_so3/source/dialog/plfilter.cxx b/binfilter/bf_so3/source/dialog/plfilter.cxx index 723a158..7e1912f 100644 --- a/binfilter/bf_so3/source/dialog/plfilter.cxx +++ b/binfilter/bf_so3/source/dialog/plfilter.cxx @@ -28,7 +28,6 @@ #include set #include map -#include unotools/processfactory.hxx #include tools/debug.hxx #include vcl/stdtext.hxx diff --git a/binfilter/bf_so3/source/inplace/plugin.cxx b/binfilter/bf_so3/source/inplace/plugin.cxx index 6ab2dd5..9f60852 100644 --- a/binfilter/bf_so3/source/inplace/plugin.cxx +++ b/binfilter/bf_so3/source/inplace/plugin.cxx @@ -36,7 +36,7 @@ #include vcl/svapp.hxx #include vcl/stdtext.hxx #include tools/debug.hxx -#include unotools/processfactory.hxx +#include comphelper/processfactory.hxx #include bf_so3/ipclient.hxx #include bf_so3/svstor.hxx @@ -261,7 +261,7 @@ BOOL SvPlugInObject::StartPlugIn( ) pArgs[i] = rCmd.GetArgument(); } -Reference XMultiServiceFactory xFac( ::utl::getProcessServiceFactory() ); +Reference XMultiServiceFactory xFac( ::comphelper::getProcessServiceFactory() ); Reference XPluginManager xPMgr( xFac-createInstance( OUString( RTL_CONSTASCII_USTRINGPARAM( com.sun.star.plugin.PluginManager )) ), UNO_QUERY ); if (! xPMgr.is() ) ShowServiceNotAvailableError( NULL, String::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM( PluginManager ) ), TRUE ); @@ -491,7 +491,7 @@ ErrCode SvPlugInObject::Verb (void)pWorkRectPixel; ErrCode nRet = ERRCODE_SO_NOT_INPLACEACTIVE; -Reference XMultiServiceFactory xFac( ::utl::getProcessServiceFactory() ); +Reference XMultiServiceFactory xFac( ::comphelper::getProcessServiceFactory() ); Sequence OUString aNames( xFac-getAvailableServiceNames() ); const OUString * pNames = aNames.getConstArray(); INT32 nPos; diff --git a/binfilter/bf_so3/source/persist/transuno.cxx b/binfilter/bf_so3/source/persist/transuno.cxx index ca2c649..f28ce80 100644 --- a/binfilter/bf_so3/source/persist/transuno.cxx +++ b/binfilter/bf_so3/source/persist/transuno.cxx @@ -44,7 +44,7 @@ #include com/sun/star/ucb/XContentProvider.hpp #include com/sun/star/ucb/XContentProviderManager.hpp -#include unotools/processfactory.hxx +#include comphelper/processfactory.hxx #include transuno.hxx @@ -83,7 +83,7 @@ com::sun::star::uno::Referencecom::sun::star::uno::XInterface SvBindingTransport_Impl::getProcessServiceFactory (void) { return com::sun::star::uno::Referencecom::sun::star::uno::XInterface( -utl::getProcessServiceFactory(), com::sun::star::uno::UNO_QUERY_THROW); +comphelper::getProcessServiceFactory(), com::sun::star::uno::UNO_QUERY_THROW); } /* diff --git a/binfilter/bf_starmath/source/starmath_mathml.cxx
[Libreoffice-commits] .: sc/source
sc/source/ui/docshell/docsh.cxx | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) New commits: commit fb754a0df859e30255c25af8fa19bfaa75f257e7 Author: Caolán McNamara caol...@redhat.com Date: Mon Nov 14 12:19:09 2011 + original would unconditionally truncate to nLen diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx index 4a0981d..65fccaa 100644 --- a/sc/source/ui/docshell/docsh.cxx +++ b/sc/source/ui/docshell/docsh.cxx @@ -1612,10 +1612,17 @@ void lcl_ScDocShell_GetFixedWidthString( rtl::OUString rStr, const ScDocument rtl::OUString aString = rStr; sal_Int32 nLen = lcl_ScDocShell_GetColWidthInChars( rDoc.GetColWidth( nCol, nTab ) ); +//If the text won't fit in the column if ( nLen aString.getLength() ) { -if ( bValue ) -aString = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ### )); +rtl::OUStringBuffer aReplacement; +if (bValue) +aReplacement.appendAscii(RTL_CONSTASCII_STRINGPARAM(###)); +else +aReplacement.append(aString); +//truncate to the number of characters that should fit, even in the +//bValue case nLen might be len ### +aString = comphelper::string::truncateToLength(aReplacement, nLen).makeStringAndClear(); } if ( nLen aString.getLength() ) { ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: bin/distro-install-clean-up bin/distro-install-desktop-integration bin/distro-install-file-lists bin/distro-install-sdk
bin/distro-install-clean-up|2 bin/distro-install-desktop-integration |8 +- bin/distro-install-file-lists | 130 - bin/distro-install-sdk | 72 +- 4 files changed, 106 insertions(+), 106 deletions(-) New commits: commit 8326efcbb46d423958f5b4bf86941ce30c3639be Author: Tomas Chvatal tchva...@suse.cz Date: Mon Nov 14 15:07:15 2011 +0100 Remove basisVERSION from distro scripts as it is not used anymore. diff --git a/bin/distro-install-clean-up b/bin/distro-install-clean-up index c18a2c4..98fb546 100755 --- a/bin/distro-install-clean-up +++ b/bin/distro-install-clean-up @@ -59,7 +59,7 @@ if test -f $DESTDIR$INSTALLDIR/help/en/sbasic.cfg -a \ fi echo Fixing permissions... -for dir in $DESTDIR$DOCDIR $DESTDIR$INSTALLDIR/basis$PRODUCTVERSION/sdk/examples ; do +for dir in $DESTDIR$DOCDIR $DESTDIR$INSTALLDIR/sdk/examples ; do if test -d $dir -a -w $dir ; then find $dir -type f \( -name *.txt -o -name *.java -o -name *.xml -o \ -name *.xcu -o -name *.xcs -o -name *.html -o \ diff --git a/bin/distro-install-desktop-integration b/bin/distro-install-desktop-integration index 466a9ad..f988e12 100755 --- a/bin/distro-install-desktop-integration +++ b/bin/distro-install-desktop-integration @@ -182,9 +182,9 @@ if test $WITH_COMPAT_OOWRAPPERS = YES ; then fi echo Install $OOINSTDIR/basis$VERSION/program/java-set-classpath; -mkdir -p $DESTDIR$INSTALLDIR/basis$PRODUCTVERSION/program -sed -e s|@INSTALLDIR@|$INSTALLDIR|g bin/java-set-classpath.in | $DESTDIR$INSTALLDIR/basis$PRODUCTVERSION/program/java-set-classpath || exit 1; -chmod 755 $DESTDIR$INSTALLDIR/basis$PRODUCTVERSION/program/java-set-classpath -test -f $DESTDIR/gid_Module_Root_Brand echo $INSTALLDIR/basis$PRODUCTVERSION/program/java-set-classpath $DESTDIR/gid_Module_Root_Brand +mkdir -p $DESTDIR$INSTALLDIR/program +sed -e s|@INSTALLDIR@|$INSTALLDIR|g bin/java-set-classpath.in | $DESTDIR$INSTALLDIR/program/java-set-classpath || exit 1; +chmod 755 $DESTDIR$INSTALLDIR/program/java-set-classpath +test -f $DESTDIR/gid_Module_Root_Brand echo $INSTALLDIR/program/java-set-classpath $DESTDIR/gid_Module_Root_Brand exit 0 diff --git a/bin/distro-install-file-lists b/bin/distro-install-file-lists index eaabf9c..d00d9ea 100755 --- a/bin/distro-install-file-lists +++ b/bin/distro-install-file-lists @@ -186,7 +186,7 @@ if test z$OOO_VENDOR != zDebian ; then if test $OOO_VENDOR = Mandriva -o \( $OOO_VENDOR = Novell, Inc. -a $SPLIT_APP_MODULES = YES \) ; then for lang in `echo $WITH_LANG_LIST | sed -e s/-/_/g`; do test -f $FILELISTSDIR/help_${lang}_list.txt || continue; -mv_file_between_flists $FILELISTSDIR/help_${lang}_list.txt $FILELISTSDIR/lang_${lang}_list.txt $INSTALLDIR/basis$PRODUCTVERSION/help/.* +mv_file_between_flists $FILELISTSDIR/help_${lang}_list.txt $FILELISTSDIR/lang_${lang}_list.txt $INSTALLDIR/help/.* add_used_directories $FILELISTSDIR/help_${lang}_list.txt $FILELISTSDIR/lang_${lang}_list.txt done fi @@ -206,28 +206,28 @@ if test z$OOO_VENDOR != zDebian ; then # kde subpackage test -f $DESTDIR/gid_Module_Optional_Kde cp $DESTDIR/gid_Module_Optional_Kde kde_list.txt || : mv_file_between_flists kde_list.txt common_list.txt $INSTALLDIR/program/kdefilepicker -mv_file_between_flists kde_list.txt common_list.txt $INSTALLDIR/basis$PRODUCTVERSION/program/fps_kde.uno.so -mv_file_between_flists kde_list.txt common_list.txt $INSTALLDIR/basis$PRODUCTVERSION/program/libvclplug_kdel..so -mv_file_between_flists kde_list.txt common_list.txt $INSTALLDIR/basis$PRODUCTVERSION/program/libkabdrv1.so +mv_file_between_flists kde_list.txt common_list.txt $INSTALLDIR/program/fps_kde.uno.so +mv_file_between_flists kde_list.txt common_list.txt $INSTALLDIR/program/libvclplug_kdel..so +mv_file_between_flists kde_list.txt common_list.txt $INSTALLDIR/program/libkabdrv1.so add_used_directories kde_list.txt common_list.txt # create kde4 subpackage -mv_file_between_flists kde4_list.txt kde_list.txt $INSTALLDIR/basis$PRODUCTVERSION/program/kde4be1.uno.so -mv_file_between_flists kde4_list.txt common_list.txt $INSTALLDIR/basis$PRODUCTVERSION/program/libvclplug_kde4l..so -mv_file_between_flists kde4_list.txt common_list.txt $INSTALLDIR/basis$PRODUCTVERSION/program/fps_kde4.uno.so +mv_file_between_flists kde4_list.txt kde_list.txt $INSTALLDIR/program/kde4be1.uno.so +mv_file_between_flists kde4_list.txt common_list.txt $INSTALLDIR/program/libvclplug_kde4l..so +mv_file_between_flists kde4_list.txt common_list.txt $INSTALLDIR/program/fps_kde4.uno.so add_used_directories kde4_list.txt common_list.txt # gnome subpackage test -f $DESTDIR/gid_Module_Optional_Gnome cp $DESTDIR/gid_Module_Optional_Gnome
[Libreoffice-commits] .: solenv/bin
solenv/bin/modules/installer/windows/msiglobal.pm | 27 ++ 1 file changed, 13 insertions(+), 14 deletions(-) New commits: commit 5538efab96126d9a78bb2a909de909b581f11a2d Author: Andras Timar ati...@suse.com Date: Mon Nov 14 15:30:34 2011 +0100 fix some comments diff --git a/solenv/bin/modules/installer/windows/msiglobal.pm b/solenv/bin/modules/installer/windows/msiglobal.pm index 07f6b73..aae0e39 100644 --- a/solenv/bin/modules/installer/windows/msiglobal.pm +++ b/solenv/bin/modules/installer/windows/msiglobal.pm @@ -113,7 +113,7 @@ sub check_ddf_file ## # Lines in ddf files must not be longer than 256 characters. -# Therefore it can be useful to use relative pathes. Then it is +# Therefore it can be useful to use relative paths. Then it is # necessary to change into temp directory before calling # makecab.exe. ## @@ -201,7 +201,7 @@ sub generate_cab_file_list if ( $onefile-{'Styles'} ) { $styles = $onefile-{'Styles'}; }; if ( $styles =~ /\bDONT_PACK\b/ ) { $doinclude = 0; } -# to avoid lines with more than 256 characters, it can be useful to use relative pathes +# to avoid lines with more than 256 characters, it can be useful to use relative paths if ( $allvariables-{'RELATIVE_PATHES_IN_DDF'} ) { $sourcepath = make_relative_ddf_path($sourcepath); } # all files with the same cabinetfile have increasing sequencenumbers @@ -223,7 +223,7 @@ sub generate_cab_file_list { $sourcepath = $nextfile-{'sourcepath'}; if ( $^O =~ /cygwin/i ) { $sourcepath = $nextfile-{'cyg_sourcepath'}; } -# to avoid lines with more than 256 characters, it can be useful to use relative pathes +# to avoid lines with more than 256 characters, it can be useful to use relative paths if ( $allvariables-{'RELATIVE_PATHES_IN_DDF'} ) { $sourcepath = make_relative_ddf_path($sourcepath); } $uniquename = $nextfile-{'uniquename'}; my $localdoinclude = 1; @@ -295,7 +295,7 @@ sub generate_cab_file_list if ( $onefile-{'Styles'} ) { $styles = $onefile-{'Styles'}; }; if ( $styles =~ /\bDONT_PACK\b/ ) { $doinclude = 0; } -# to avoid lines with more than 256 characters, it can be useful to use relative pathes +# to avoid lines with more than 256 characters, it can be useful to use relative paths if ( $allvariables-{'RELATIVE_PATHES_IN_DDF'} ) { $sourcepath = make_relative_ddf_path($sourcepath); } my @ddffile = (); @@ -316,7 +316,7 @@ sub generate_cab_file_list { $sourcepath = $nextfile-{'sourcepath'}; if ( $^O =~ /cygwin/i ) { $sourcepath = $nextfile-{'cyg_sourcepath'}; } -# to avoid lines with more than 256 characters, it can be useful to use relative pathes +# to avoid lines with more than 256 characters, it can be useful to use relative paths if ( $allvariables-{'RELATIVE_PATHES_IN_DDF'} ) { $sourcepath = make_relative_ddf_path($sourcepath); } $uniquename = $nextfile-{'uniquename'}; my $localdoinclude = 1; @@ -325,7 +325,7 @@ sub generate_cab_file_list if ( $nextfilestyles =~ /\bDONT_PACK\b/ ) { $localdoinclude = 0; } $ddfline = \ . $sourcepath . \ . . $uniquename . \n; if ( $localdoinclude ) { push(@ddffile, $ddfline); } -$counter++; # increasing the counter! +$counter++; $nextfile = ; $nextcabinetfile = _lastfile_; if (( exists($sequenceorder-{$counter}) ) ( ${$filesref}[$sequenceorder-{$counter}] )) @@ -375,7 +375,7 @@ sub generate_cab_file_list if ( $styles =~ /\bDONT_PACK\b/ ) { $doinclude = 0; } -# to avoid lines with more than 256 characters, it can be useful to use relative pathes +# to avoid lines with more than 256 characters, it can be useful to use relative paths if ( $allvariables-{'RELATIVE_PATHES_IN_DDF'} ) { $sourcepath = make_relative_ddf_path($sourcepath); } # all files with the same cabinetfile are directly behind each other in the files collector @@ -396,7 +396,7 @@ sub generate_cab_file_list { $sourcepath = $nextfile-{'sourcepath'}; if ( $^O =~ /cygwin/i ) { $sourcepath = $nextfile-{'cyg_sourcepath'}; } -# to avoid lines with more than 256 characters, it can be useful to use relative pathes +# to avoid lines with more than 256 characters, it can be useful to use relative paths
[Libreoffice-commits] .: 2 commits - sc/source tools/source
sc/source/ui/docshell/docsh.cxx | 21 tools/source/fsys/comdep.hxx|2 tools/source/fsys/dirent.cxx|2 tools/source/fsys/wntmsc.cxx| 94 +--- 4 files changed, 63 insertions(+), 56 deletions(-) New commits: commit f8beaced3d4dbf541fafb94b84ed35b498d4365e Author: Caolán McNamara caol...@redhat.com Date: Mon Nov 14 14:42:47 2011 + remove dodgy const_casts diff --git a/tools/source/fsys/comdep.hxx b/tools/source/fsys/comdep.hxx index efa9e1a..94dfdff 100644 --- a/tools/source/fsys/comdep.hxx +++ b/tools/source/fsys/comdep.hxx @@ -136,7 +136,7 @@ struct FileCopier_Impl // #if defined WNT -sal_Bool IsRedirectable_Impl( const ByteString rPath ); +sal_Bool IsRedirectable_Impl( const rtl::OString rPath ); #else #define IsRedirectable_Impl( rPath )sal_True #endif diff --git a/tools/source/fsys/dirent.cxx b/tools/source/fsys/dirent.cxx index 95fcd32..052a6a2 100644 --- a/tools/source/fsys/dirent.cxx +++ b/tools/source/fsys/dirent.cxx @@ -162,7 +162,7 @@ void FSysRedirector::DoRedirect( String rPath ) return; // redirect only removable or remote volumes -if ( !IsRedirectable_Impl( ByteString( aURL, osl_getThreadTextEncoding() ) ) ) +if (!IsRedirectable_Impl(rtl::OUStringToOString(aURL, osl_getThreadTextEncoding( return; // Redirection is acessible only by one thread per time diff --git a/tools/source/fsys/wntmsc.cxx b/tools/source/fsys/wntmsc.cxx index 3d8bd91..ee90636 100644 --- a/tools/source/fsys/wntmsc.cxx +++ b/tools/source/fsys/wntmsc.cxx @@ -45,6 +45,7 @@ #include tools/wldcrd.hxx #include tools/fsys.hxx #include tools/bigint.hxx +#include vector int Sys2SolarError_Impl( int nSysErr ); @@ -52,11 +53,12 @@ static sal_Bool bLastCaseSensitive= sal_False; // -ByteString Upper_Impl( const ByteString rStr ) +rtl::OString Upper_Impl(const rtl::OString rStr) { -ByteString aRet( rStr.GetBuffer() ); // es muss ein neuer String entstehen! -CharUpperBuff( (char*) aRet.GetBuffer(), aRet.Len() ); -return aRet; +std::vectorsal_Char aBuffer(rStr.getLength()); +memcpy(aBuffer[0], rStr.getStr(), rStr.getLength()); +CharUpperBuff(aBuffer[0], rStr.getLength()); +return rtl::OString(aBuffer[0], rStr.getLength()); } // @@ -132,9 +134,10 @@ sal_Bool DirEntry::ToAbs() char sBuf[256]; char *pOld; -ByteString aFullName( GetFull(), osl_getThreadTextEncoding() ); +rtl::OString aFullName(rtl::OUStringToOString(GetFull(), +osl_getThreadTextEncoding())); FSysFailOnErrorImpl(); -if ( GetFullPathName((char*)aFullName.GetBuffer(),256,sBuf,pOld) 511 ) +if ( GetFullPathName(aFullName.getStr(), 256, sBuf, pOld) 511 ) return sal_False; *this = DirEntry( String(sBuf, osl_getThreadTextEncoding() )); @@ -150,16 +153,17 @@ sal_Bool DirEntry::ToAbs() String DirEntry::GetVolume() const { - DBG_CHKTHIS( DirEntry, ImpCheckDirEntry ); +DBG_CHKTHIS( DirEntry, ImpCheckDirEntry ); String aRet; const DirEntry *pTop = ImpGetTopPtr(); -ByteString aName = ByteString( pTop-aName ).ToLowerAscii(); +rtl::OString aName = rtl::OString(pTop-aName).toAsciiLowerCase(); if ( ( pTop-eFlag == FSYS_FLAG_ABSROOT || pTop-eFlag == FSYS_FLAG_RELROOT || pTop-eFlag == FSYS_FLAG_VOLUME ) - aName != a: aName != b: Exists() ) + !aName.equalsL(RTL_CONSTASCII_STRINGPARAM(a:)) + !aName.equalsL(RTL_CONSTASCII_STRINGPARAM(b:)) Exists() ) { char sFileSysName[256]; char sVolumeName[256]; @@ -167,19 +171,19 @@ String DirEntry::GetVolume() const DWORD nSerial[2]; DWORD nMaxCompLen[2]; DWORD nFlags[2]; -ByteString aRootDir = pTop-aName; +rtl::OString aRootDir = pTop-aName; FSysFailOnErrorImpl(); // Network-Device zuerst probieren wegen langsamer Samba-Drives -if ( !WNetGetConnection( (char*) aRootDir.GetBuffer(), +if ( !WNetGetConnection( aRootDir.getStr(), sVolumeName, nVolumeNameLen ) ) aRet = String( sVolumeName, osl_getThreadTextEncoding()); // dann den VolumeNamen fuer lokale Drives if ( aRet.Len() == 0 ) { -aRootDir += \\; -if ( GetVolumeInformation( (char*) aRootDir.GetBuffer(), +aRootDir += rtl::OString(RTL_CONSTASCII_STRINGPARAM(\\)); +if ( GetVolumeInformation( aRootDir.getStr(), sVolumeName, 256, (LPDWORD) nSerial, (LPDWORD) nMaxCompLen, (LPDWORD) nFlags, sFileSysName, 256 )
[Libreoffice-commits] .: sc/inc sc/source
sc/inc/queryparam.hxx |1 - sc/source/core/data/dociter.cxx|4 sc/source/core/data/table3.cxx | 17 - sc/source/core/tool/doubleref.cxx |1 - sc/source/core/tool/interpr1.cxx |3 --- sc/source/core/tool/queryparam.cxx |6 ++ 6 files changed, 2 insertions(+), 30 deletions(-) New commits: commit ebdd9c300718bce454ef56a31d5d8fb699fc1822 Author: Kohei Yoshida kohei.yosh...@suse.com Date: Mon Nov 14 10:37:47 2011 -0500 Revert Revert Removing the mixed comparison flag, which is no longer needed. This reverts commit 7d7036c235a92268f23cc04eab8abcb08cddeb3f. diff --git a/sc/inc/queryparam.hxx b/sc/inc/queryparam.hxx index d04f7b4..49fa2bc 100644 --- a/sc/inc/queryparam.hxx +++ b/sc/inc/queryparam.hxx @@ -45,7 +45,6 @@ struct ScQueryParamBase boolbCaseSens; boolbRegExp; boolbDuplicate; -boolbMixedComparison; // whether numbers are smaller than strings virtual ~ScQueryParamBase(); diff --git a/sc/source/core/data/dociter.cxx b/sc/source/core/data/dociter.cxx index 5efe016..689e68e 100644 --- a/sc/source/core/data/dociter.cxx +++ b/sc/source/core/data/dociter.cxx @@ -865,10 +865,6 @@ bool ScDBQueryDataIterator::DataAccessMatrix::isValidQuery(SCROW nRow, const ScM } while (false); } -else if (mpParam-bMixedComparison) -{ -// Not used at the moment. -} if (aResults.empty()) // First query entry. diff --git a/sc/source/core/data/table3.cxx b/sc/source/core/data/table3.cxx index 16c4793..4539055 100644 --- a/sc/source/core/data/table3.cxx +++ b/sc/source/core/data/table3.cxx @@ -1442,23 +1442,6 @@ bool ScTable::ValidQuery(SCROW nRow, const ScQueryParam rParam, } } } -else if (rParam.bMixedComparison) -{ -if (rItem.meType == ScQueryEntry::ByString -(rEntry.eOp == SC_LESS || rEntry.eOp == SC_LESS_EQUAL) -(pCell ? pCell-HasValueData() : - HasValueData( static_castSCCOL(rEntry.nField), nRow))) -{ -bOk = true; -} -else if (rItem.meType != ScQueryEntry::ByString -(rEntry.eOp == SC_GREATER || rEntry.eOp == SC_GREATER_EQUAL) -(pCell ? pCell-HasStringData() : - HasStringData( static_castSCCOL(rEntry.nField), nRow))) -{ -bOk = true; -} -} if (nPos == -1) { diff --git a/sc/source/core/tool/doubleref.cxx b/sc/source/core/tool/doubleref.cxx index 15e6d53..a7414aa 100644 --- a/sc/source/core/tool/doubleref.cxx +++ b/sc/source/core/tool/doubleref.cxx @@ -276,7 +276,6 @@ void ScDBRangeBase::fillQueryOptions(ScQueryParamBase* pParam) pParam-bCaseSens = false; pParam-bRegExp = false; pParam-bDuplicate = true; -pParam-bMixedComparison = false; } ScDocument* ScDBRangeBase::getDoc() const diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx index a0a577f..bc33bf8 100644 --- a/sc/source/core/tool/interpr1.cxx +++ b/sc/source/core/tool/interpr1.cxx @@ -4473,7 +4473,6 @@ void ScInterpreter::ScMatch() rParam.nRow1 = nRow1; rParam.nCol2 = nCol2; rParam.nTab= nTab1; -rParam.bMixedComparison = true; ScQueryEntry rEntry = rParam.GetEntry(0); ScQueryEntry::Item rItem = rEntry.GetQueryItem(); @@ -5805,7 +5804,6 @@ void ScInterpreter::ScLookup() aParam.nCol2= bVertical ? nCol1 : nCol2; aParam.nRow2= bVertical ? nRow2 : nRow1; aParam.bByRow = bVertical; -aParam.bMixedComparison = true; rEntry.bDoQuery = true; rEntry.eOp = SC_LESS_EQUAL; @@ -6026,7 +6024,6 @@ void ScInterpreter::CalculateLookup(bool HLookup) rParam.nRow2 = nRow2; rParam.nTab= nTab1; } -rParam.bMixedComparison = true; ScQueryEntry rEntry = rParam.GetEntry(0); rEntry.bDoQuery = true; diff --git a/sc/source/core/tool/queryparam.cxx b/sc/source/core/tool/queryparam.cxx index 4012f13..a1df6a2 100644 --- a/sc/source/core/tool/queryparam.cxx +++ b/sc/source/core/tool/queryparam.cxx @@ -48,7 +48,7 @@ ScQueryParamBase::ScQueryParamBase() ScQueryParamBase::ScQueryParamBase(const ScQueryParamBase r) : bHasHeader(r.bHasHeader), bByRow(r.bByRow), bInplace(r.bInplace), bCaseSens(r.bCaseSens), -bRegExp(r.bRegExp), bDuplicate(r.bDuplicate), bMixedComparison(r.bMixedComparison), +bRegExp(r.bRegExp), bDuplicate(r.bDuplicate), maEntries(r.maEntries) { } @@ -226,7 +226,7 @@ void ScQueryParam::Clear() nCol1=nCol2 = 0; nRow1=nRow2 = 0; nTab = SCTAB_MAX; -bHasHeader = bCaseSens =
[Libreoffice-commits] .: sc/qa
sc/qa/unit/ucalc.cxx | 46 +++--- 1 file changed, 23 insertions(+), 23 deletions(-) New commits: commit 2f61bdff4435fd25b2d7da3c2366d663bd7e5085 Author: Kohei Yoshida kohei.yosh...@suse.com Date: Mon Nov 14 11:57:15 2011 -0500 Modified VLOOKUP test case to account for mixed comparisons. When the lookup value is of type Text, and the last match is of type Number, it should return #N/A according to the ODFF spec. diff --git a/sc/qa/unit/ucalc.cxx b/sc/qa/unit/ucalc.cxx index cbc45d0..3faa208 100644 --- a/sc/qa/unit/ucalc.cxx +++ b/sc/qa/unit/ucalc.cxx @@ -452,7 +452,7 @@ void testFuncVLOOKUP(ScDocument* pDoc) { 50, 7 }, { 60, 8 }, { 70, 9 }, -{ A, 10 }, +{ B, 10 }, { B, 11 }, { C, 12 }, { D, 13 }, @@ -472,26 +472,26 @@ void testFuncVLOOKUP(ScDocument* pDoc) // Formula data struct { -const char* pLookup; const char* pFormula; double fResult; +const char* pLookup; const char* pFormula; const char* pRes; } aChecks[] = { { Lookup, Formula, 0 }, -{ 12, =VLOOKUP(D2;A2:B14;2;1), 3 }, -{ 29, =VLOOKUP(D3;A2:B14;2;1), 4 }, -{ 31, =VLOOKUP(D4;A2:B14;2;1), 5 }, -{ 45, =VLOOKUP(D5;A2:B14;2;1), 6 }, -{ 56, =VLOOKUP(D6;A2:B14;2;1), 7 }, -{ 65, =VLOOKUP(D7;A2:B14;2;1), 8 }, -{ 78, =VLOOKUP(D8;A2:B14;2;1), 9 }, -{ Andy,=VLOOKUP(D9;A2:B14;2;1), 10 }, -{ Bruce, =VLOOKUP(D10;A2:B14;2;1), 11 }, -{ Charlie, =VLOOKUP(D11;A2:B14;2;1), 12 }, -{ David, =VLOOKUP(D12;A2:B14;2;1), 13 }, -{ Edward, =VLOOKUP(D13;A2:B14;2;1), 14 }, -{ Frank, =VLOOKUP(D14;A2:B14;2;1), 15 }, -{ Henry, =VLOOKUP(D15;A2:B14;2;1), 15 }, -{ 100, =VLOOKUP(D16;A2:B14;2;1), 9 }, -{ 1000,=VLOOKUP(D17;A2:B14;2;1), 9 }, -{ Zena,=VLOOKUP(D18;A2:B14;2;1), 15 } +{ 12, =VLOOKUP(D2;A2:B14;2;1), 3 }, +{ 29, =VLOOKUP(D3;A2:B14;2;1), 4 }, +{ 31, =VLOOKUP(D4;A2:B14;2;1), 5 }, +{ 45, =VLOOKUP(D5;A2:B14;2;1), 6 }, +{ 56, =VLOOKUP(D6;A2:B14;2;1), 7 }, +{ 65, =VLOOKUP(D7;A2:B14;2;1), 8 }, +{ 78, =VLOOKUP(D8;A2:B14;2;1), 9 }, +{ Andy,=VLOOKUP(D9;A2:B14;2;1), #N/A }, +{ Bruce, =VLOOKUP(D10;A2:B14;2;1), 11 }, +{ Charlie, =VLOOKUP(D11;A2:B14;2;1), 12 }, +{ David, =VLOOKUP(D12;A2:B14;2;1), 13 }, +{ Edward, =VLOOKUP(D13;A2:B14;2;1), 14 }, +{ Frank, =VLOOKUP(D14;A2:B14;2;1), 15 }, +{ Henry, =VLOOKUP(D15;A2:B14;2;1), 15 }, +{ 100, =VLOOKUP(D16;A2:B14;2;1),9 }, +{ 1000,=VLOOKUP(D17;A2:B14;2;1),9 }, +{ Zena,=VLOOKUP(D18;A2:B14;2;1), 15 } }; // Insert formula data into D1:E18. @@ -510,13 +510,13 @@ void testFuncVLOOKUP(ScDocument* pDoc) // Skip the header row. continue; -double result; -pDoc-GetValue(4, i, 0, result); -bool bGood = result == aChecks[i].fResult; +rtl::OUString aRes; +pDoc-GetString(4, i, 0, aRes); +bool bGood = aRes.equalsAscii(aChecks[i].pRes); if (!bGood) { cerr row (i+1) : lookup value=' aChecks[i].pLookup - ' expected= aChecks[i].fResultactual= result endl; + ' expected=' aChecks[i].pRes ' actual=' aRes ' endl; CPPUNIT_ASSERT_MESSAGE(Unexpected result for VLOOKUP, false); } } ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: sc/qa
sc/qa/unit/ucalc.cxx | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) New commits: commit 51494ab7291ad97eca5acfe2d9a4943ddfb4800d Author: Kohei Yoshida kohei.yosh...@suse.com Date: Mon Nov 14 12:07:48 2011 -0500 Likewise, adjusted the test cases for MATCH to handle mixed comparisons. diff --git a/sc/qa/unit/ucalc.cxx b/sc/qa/unit/ucalc.cxx index 3faa208..b18bfe0 100644 --- a/sc/qa/unit/ucalc.cxx +++ b/sc/qa/unit/ucalc.cxx @@ -589,7 +589,7 @@ void testFuncMATCH(ScDocument* pDoc) 7, 8, 9, -A, +B, B, C, }; @@ -608,7 +608,7 @@ void testFuncMATCH(ScDocument* pDoc) { 9.59, 9 }, { 10, 9 }, { 100, 9 }, -{ Andy,10 }, +{ Andy, #N/A }, { Bruce, 11 }, { Charlie, 12 } }; @@ -621,9 +621,9 @@ void testFuncMATCH(ScDocument* pDoc) // data range (A1:A9) const char* aData[] = { +D, C, B, -A, 9, 8, 7, @@ -649,9 +649,10 @@ void testFuncMATCH(ScDocument* pDoc) { 0.8, 12 }, { 0, 12 }, { -2, 12 }, -{ Andy,2 }, -{ Bruce, 1 }, -{ Charlie, #N/A }, +{ Andy,3 }, +{ Bruce, 2 }, +{ Charlie, 1 }, +{ David, #N/A } }; runTestMATCHSAL_N_ELEMENTS(aData),SAL_N_ELEMENTS(aChecks),-1(pDoc, aData, aChecks); ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: framework/source
framework/source/loadenv/loadenv.cxx |8 1 file changed, 4 insertions(+), 4 deletions(-) New commits: commit 718f032a3c9dc5071f86a6d69321dc23d6b56188 Author: Michael Stahl mst...@redhat.com Date: Mon Nov 14 20:35:32 2011 +0100 LoadEnv::impl_makeFrameWindowVisible: fix crash: do not insert Preview property if it does not exist already (dbaccess crashes after throwing uncaught exception because of this when creating new database; regression in 88285f84bdf54147ee5238e97d0d805fa1c127c1) diff --git a/framework/source/loadenv/loadenv.cxx b/framework/source/loadenv/loadenv.cxx index 61c520d..e82823b 100644 --- a/framework/source/loadenv/loadenv.cxx +++ b/framework/source/loadenv/loadenv.cxx @@ -1688,14 +1688,14 @@ void LoadEnv::impl_makeFrameWindowVisible(const css::uno::Reference css::awt::X Window* pWindow = VCLUnoHelper::GetWindow(xWindow); if ( pWindow ) { -bool preview(false); -css::uno::Any a = m_lMediaDescriptor[::comphelper::MediaDescriptor::PROP_PREVIEW()]; -a = preview; +bool const preview( m_lMediaDescriptor.getUnpackedValueOrDefault( +::comphelper::MediaDescriptor::PROP_PREVIEW(), sal_False) ); bool bForceFrontAndFocus(false); if ( !preview ) { -a = ::comphelper::ConfigurationHelper::readDirectKey( +css::uno::Any const a = +::comphelper::ConfigurationHelper::readDirectKey( xSMGR, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(org.openoffice.Office.Common/View)), ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(NewDocumentHandling)), ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: sw/qa
sw/qa/complex/writer/CheckBookmarks.java |9 - 1 file changed, 4 insertions(+), 5 deletions(-) New commits: commit fe7026d72b1b88f60e009fd4de2f53306e0d1c4e Author: Bjoern Michaelsen bjoern.michael...@canonical.com Date: Mon Nov 14 23:03:23 2011 +0100 fdo#40819, i#116193: disable WW8 roundtrip as it breaks on big bookmark counts diff --git a/sw/qa/complex/writer/CheckBookmarks.java b/sw/qa/complex/writer/CheckBookmarks.java index 405ca0d..c922da2 100644 --- a/sw/qa/complex/writer/CheckBookmarks.java +++ b/sw/qa/complex/writer/CheckBookmarks.java @@ -107,9 +107,8 @@ public class CheckBookmarks { result.m_nDeleteRandomHash = new BigInteger(-3ec87e810b46d734677c351ad893bbbf9ea10f55,16); result.m_nLinebreakHash = new BigInteger(3ae08c284ea0d6e738cb43c0a8105e718a633550,16); result.m_nOdfReloadHash = new BigInteger(3ae08c284ea0d6e738cb43c0a8105e718a633550,16); -// MsWord Hash changed from DEV300m41 = behaviour change, possible regression? +// MsWord Hash is unstable over different systems // result.m_nMsWordReloadHash = new BigInteger(3ae08c284ea0d6e738cb43c0a8105e718a633550,16); - result.m_nMsWordReloadHash = new BigInteger(-53193413016049203700369483764549874348805475606,10); return result; } @@ -136,14 +135,14 @@ public class CheckBookmarks { actualHashes.m_nLinebreakHash = BookmarkHashes.getBookmarksHash(m_xDoc); m_xOdfReloadedDoc = reloadFrom(StarOffice XML (Writer), odf); actualHashes.m_nOdfReloadHash = BookmarkHashes.getBookmarksHash(m_xOdfReloadedDoc); -m_xMsWordReloadedDoc = reloadFrom(MS Word 97, doc); -actualHashes.m_nMsWordReloadHash = BookmarkHashes.getBookmarksHash(m_xMsWordReloadedDoc); +//m_xMsWordReloadedDoc = reloadFrom(MS Word 97, doc); +//actualHashes.m_nMsWordReloadHash = BookmarkHashes.getBookmarksHash(m_xMsWordReloadedDoc); } @After public void tearDownDocuments() { util.DesktopTools.closeDoc(m_xDoc); util.DesktopTools.closeDoc(m_xOdfReloadedDoc); -util.DesktopTools.closeDoc(m_xMsWordReloadedDoc); +//util.DesktopTools.closeDoc(m_xMsWordReloadedDoc); } @BeforeClass public static void setUpConnection() throws Exception { ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: 5 commits - sc/qa sd/qa sw/CppunitTest_sw_macros_test.mk sw/Module_sw.mk sw/qa
sc/qa/unit/filters-test.cxx |2 sc/qa/unit/macros-test.cxx | 66 ++- sd/qa/unit/filters-test.cxx |2 sw/CppunitTest_sw_macros_test.mk | 144 sw/Module_sw.mk |1 sw/qa/core/data/xls/testVba.doc |binary sw/qa/core/macros-test.cxx | 232 +++ 7 files changed, 395 insertions(+), 52 deletions(-) New commits: commit cb7c50c1a0739d11d28135160c573f59f010a73e Author: Markus Mohrhard markus.mohrh...@googlemail.com Date: Mon Nov 14 22:38:34 2011 +0100 move macros_test to sw the macros_test does not execute a useful macro at the moment diff --git a/sw/CppunitTest_sw_macros_test.mk b/sw/CppunitTest_sw_macros_test.mk new file mode 100644 index 000..21603f0 --- /dev/null +++ b/sw/CppunitTest_sw_macros_test.mk @@ -0,0 +1,144 @@ +# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- +#* +# Version: MPL 1.1 / GPLv3+ / LGPLv3+ +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the License); you may not use this file except in compliance with +# the License or as specified alternatively below. You may obtain a copy of +# the License at http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an AS IS basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Initial Developer of the Original Code is +# Caolán McNamara, Red Hat, Inc. caol...@redhat.com +# Portions created by the Initial Developer are Copyright (C) 2011 the +# Initial Developer. All Rights Reserved. +# +# Major Contributor(s): +# +# For minor contributions see the git repository. +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 3 or later (the GPLv3+), or +# the GNU Lesser General Public License Version 3 or later (the LGPLv3+), +# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable +# instead of those above. +#* + +$(eval $(call gb_CppunitTest_CppunitTest,sw_macros_test)) + +$(eval $(call gb_CppunitTest_add_exception_objects,sw_macros_test, \ +sw/qa/core/macros-test \ +)) + +$(eval $(call gb_CppunitTest_add_linked_libs,sw_macros_test, \ +avmedia \ +basegfx \ +comphelper \ +cppu \ +cppuhelper \ +drawinglayer \ +editeng \ +fileacc \ +for \ +forui \ +i18nisolang1 \ +msfilter \ +oox \ +sal \ +salhelper \ +sax \ +sb \ +sw \ +sfx \ +sot \ +svl \ +svt \ +svx \ +svxcore \ + test \ +tl \ +tk \ +ucbhelper \ + unotest \ +utl \ +vbahelper \ +vcl \ +xo \ + $(gb_STDLIBS) \ +)) + +$(eval $(call gb_CppunitTest_set_include,sw_macros_test,\ +-I$(realpath $(SRCDIR)/sw/inc/pch) \ +-I$(realpath $(SRCDIR)/sw/source/ui/inc) \ +-I$(realpath $(SRCDIR)/sw/inc) \ +$$(INCLUDE) \ +-I$(OUTDIR)/inc \ +)) + +$(eval $(call gb_CppunitTest_add_api,sw_macros_test,\ +offapi \ +oovbaapi \ +udkapi \ +)) + +$(eval $(call gb_CppunitTest_uses_ure,sw_macros_test)) + +$(eval $(call gb_CppunitTest_add_type_rdbs,sw_macros_test,\ +oovbaapi \ +types \ +)) + +$(eval $(call gb_CppunitTest_add_components,sw_macros_test,\ +basic/util/sb \ +comphelper/util/comphelp \ +dbaccess/util/dba \ +fileaccess/source/fileacc \ +filter/source/config/cache/filterconfig1 \ +forms/util/frm \ +framework/util/fwk \ +i18npool/util/i18npool \ +oox/util/oox \ +package/source/xstor/xstor \ +package/util/package2 \ +sax/source/expatwrap/expwrap \ +sax/source/fastparser/fastsax \ +sw/util/sw \ +sw/util/swd \ +sw/util/msword \ +sw/util/vbaswobj \ +scripting/source/basprov/basprov \ +scripting/util/scriptframe \ +sfx2/util/sfx \ +sot/util/sot \ +svl/source/fsstor/fsstorage \ +toolkit/util/tk \ +unotools/util/utl \ +unoxml/source/rdf/unordf \ +unoxml/source/service/unoxml \ +)) + +$(eval $(call gb_CppunitTest_add_old_components,sw_macros_test,\ +configmgr \ +ucb1 \ +ucpfile1 \ +ucptdoc1 \ +)) + +$(eval $(call gb_CppunitTest_set_args,sw_macros_test,\ +--headless \ +--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ +-env:CONFIGURATION_LAYERS=xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) module:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry/spool) xcsxcu:$(call gb_CppunitTarget__make_url,$(SRCDIR)/sc/qa/unit/data/registry) \ +)) +# .../spool is required for the (somewhat strange) filter configuration + +# we need to +# a) explicitly depend on library msword because it is
[Libreoffice-commits] .: sw/qa
dev/null|binary sw/qa/core/data/doc/testVba.doc |binary 2 files changed New commits: commit b197bac71a6111c3d024f5a3ee7863b833396689 Author: Markus Mohrhard markus.mohrh...@googlemail.com Date: Tue Nov 15 00:29:50 2011 +0100 test file needs to be in doc and not in xls diff --git a/sw/qa/core/data/doc/testVba.doc b/sw/qa/core/data/doc/testVba.doc new file mode 100644 index 000..e8c87c6 Binary files /dev/null and b/sw/qa/core/data/doc/testVba.doc differ diff --git a/sw/qa/core/data/xls/testVba.doc b/sw/qa/core/data/xls/testVba.doc deleted file mode 100644 index e8c87c6..000 Binary files a/sw/qa/core/data/xls/testVba.doc and /dev/null differ ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: 2 commits - sfx2/inc sfx2/source
sfx2/inc/sfx2/docfilt.hxx|4 ++-- sfx2/inc/sfx2/fcontnr.hxx|2 +- sfx2/source/appl/appinit.cxx |7 --- sfx2/source/appl/appmain.cxx | 19 --- sfx2/source/appl/sfxpicklist.cxx | 36 ++-- sfx2/source/bastyp/fltfnc.cxx|4 ++-- sfx2/source/doc/objstor.cxx |2 +- sfx2/source/inc/sfxpicklist.hxx | 13 ++--- 8 files changed, 30 insertions(+), 57 deletions(-) New commits: commit 12df49396e6bcb07bafc95255a8526caac96e60a Author: Takeshi Abe t...@fixedpoint.jp Date: Mon Nov 14 18:32:07 2011 +0900 replaced String in SfxPickList with rtl::OUString diff --git a/sfx2/inc/sfx2/docfilt.hxx b/sfx2/inc/sfx2/docfilt.hxx index a951239..1da1dea 100644 --- a/sfx2/inc/sfx2/docfilt.hxx +++ b/sfx2/inc/sfx2/docfilt.hxx @@ -57,7 +57,7 @@ friend class SfxFilterContainer; SfxFilterFlags nFormatType; sal_uInt16 nDocIcon; String aServiceName; -String aMimeType; +::rtl::OUString aMimeType; String aFilterName; String aPattern; sal_uIntPtr nVersion; @@ -85,7 +85,7 @@ public: bool IsInternal() const { return nFormatType SFX_FILTER_INTERNAL; } SfxFilterFlags GetFilterFlags() const { return nFormatType; } const String GetFilterName() const { return aFilterName; } -const String GetMimeType() const { return aMimeType; } +const ::rtl::OUString GetMimeType() const { return aMimeType; } const String GetName() const { return aFilterName; } const WildCard GetWildcard() const { return aWildCard; } const String GetRealTypeName() const { return aTypeName; } diff --git a/sfx2/inc/sfx2/fcontnr.hxx b/sfx2/inc/sfx2/fcontnr.hxx index a6187a6..f6c1d01 100644 --- a/sfx2/inc/sfx2/fcontnr.hxx +++ b/sfx2/inc/sfx2/fcontnr.hxx @@ -140,7 +140,7 @@ public: sal_uInt32 GuessFilterControlDefaultUI( SfxMedium rMedium, const SfxFilter **, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED, sal_Bool bDefUI = sal_True ) const; sal_uInt32 DetectFilter( SfxMedium rMedium, const SfxFilter **, sal_Bool bPlugIn, sal_Bool bAPI = sal_False ) const; -const SfxFilter*GetFilter4Mime( const String rMime, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED) const; +const SfxFilter*GetFilter4Mime( const ::rtl::OUString rMime, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED) const; const SfxFilter*GetFilter4ClipBoardId( sal_uInt32 nId, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const; const SfxFilter*GetFilter4EA( const String rEA, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const; const SfxFilter*GetFilter4Extension( const String rExt, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const; diff --git a/sfx2/source/appl/sfxpicklist.cxx b/sfx2/source/appl/sfxpicklist.cxx index c3332d9..d80a80c 100644 --- a/sfx2/source/appl/sfxpicklist.cxx +++ b/sfx2/source/appl/sfxpicklist.cxx @@ -84,30 +84,30 @@ class StringLength : public ::cppu::WeakImplHelper1 XStringWidth } }; -void SfxPickList::CreatePicklistMenuTitle( Menu* pMenu, sal_uInt16 nItemId, const String aURLString, sal_uInt32 nNo ) +void SfxPickList::CreatePicklistMenuTitle( Menu* pMenu, sal_uInt16 nItemId, const ::rtl::OUString aURLString, sal_uInt32 nNo ) { -String aPickEntry; +::rtl::OUStringBuffer aPickEntry; if ( nNo 9 ) { -aPickEntry += '~'; -aPickEntry += String::CreateFromInt32( nNo + 1 ); +aPickEntry.append('~'); +aPickEntry.append(::rtl::OUString::valueOf(static_castsal_Int32(nNo + 1))); } else if ( nNo == 9 ) -aPickEntry += DEFINE_CONST_UNICODE(1~0); +aPickEntry.appendAscii(1~0); else -aPickEntry += String::CreateFromInt32( nNo + 1 ); -aPickEntry += DEFINE_CONST_UNICODE(: ); +aPickEntry.append(::rtl::OUString::valueOf(static_castsal_Int32(nNo + 1))); +aPickEntry.appendAscii(: ); INetURLObject aURL( aURLString ); rtl::OUString aTipHelpText; -rtl::OUString aAccessibleName( aPickEntry ); +rtl::OUString aAccessibleName = aPickEntry.toString(); if ( aURL.GetProtocol() == INET_PROT_FILE ) { // Do handle file URL differently = convert it to a system // path and abbreviate it with a special function: -String aFileSystemPath( aURL.getFSysPath( INetURLObject::FSYS_DETECT ) ); +::rtl::OUString aFileSystemPath( aURL.getFSysPath( INetURLObject::FSYS_DETECT ) ); ::rtl::OUString aSystemPath( aFileSystemPath ); ::rtl::OUString aCompactedSystemPath; @@ -116,28 +116,28 @@ void SfxPickList::CreatePicklistMenuTitle(
[Libreoffice-commits] .: sfx2/inc sfx2/source
sfx2/inc/sfx2/docfilt.hxx|4 ++-- sfx2/inc/sfx2/fcontnr.hxx|2 +- sfx2/source/appl/sfxpicklist.cxx | 36 ++-- sfx2/source/bastyp/fltfnc.cxx|4 ++-- sfx2/source/doc/objstor.cxx |2 +- sfx2/source/inc/sfxpicklist.hxx | 13 +++-- 6 files changed, 31 insertions(+), 30 deletions(-) New commits: commit f7319622f63c9dae0eed9e60404d290580fce9fe Author: Takeshi Abe t...@fixedpoint.jp Date: Tue Nov 15 10:57:42 2011 +0900 Revert replaced String in SfxPickList with rtl::OUString This reverts commit 12df49396e6bcb07bafc95255a8526caac96e60a. diff --git a/sfx2/inc/sfx2/docfilt.hxx b/sfx2/inc/sfx2/docfilt.hxx index 1da1dea..a951239 100644 --- a/sfx2/inc/sfx2/docfilt.hxx +++ b/sfx2/inc/sfx2/docfilt.hxx @@ -57,7 +57,7 @@ friend class SfxFilterContainer; SfxFilterFlags nFormatType; sal_uInt16 nDocIcon; String aServiceName; -::rtl::OUString aMimeType; +String aMimeType; String aFilterName; String aPattern; sal_uIntPtr nVersion; @@ -85,7 +85,7 @@ public: bool IsInternal() const { return nFormatType SFX_FILTER_INTERNAL; } SfxFilterFlags GetFilterFlags() const { return nFormatType; } const String GetFilterName() const { return aFilterName; } -const ::rtl::OUString GetMimeType() const { return aMimeType; } +const String GetMimeType() const { return aMimeType; } const String GetName() const { return aFilterName; } const WildCard GetWildcard() const { return aWildCard; } const String GetRealTypeName() const { return aTypeName; } diff --git a/sfx2/inc/sfx2/fcontnr.hxx b/sfx2/inc/sfx2/fcontnr.hxx index f6c1d01..a6187a6 100644 --- a/sfx2/inc/sfx2/fcontnr.hxx +++ b/sfx2/inc/sfx2/fcontnr.hxx @@ -140,7 +140,7 @@ public: sal_uInt32 GuessFilterControlDefaultUI( SfxMedium rMedium, const SfxFilter **, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED, sal_Bool bDefUI = sal_True ) const; sal_uInt32 DetectFilter( SfxMedium rMedium, const SfxFilter **, sal_Bool bPlugIn, sal_Bool bAPI = sal_False ) const; -const SfxFilter*GetFilter4Mime( const ::rtl::OUString rMime, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED) const; +const SfxFilter*GetFilter4Mime( const String rMime, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED) const; const SfxFilter*GetFilter4ClipBoardId( sal_uInt32 nId, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const; const SfxFilter*GetFilter4EA( const String rEA, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const; const SfxFilter*GetFilter4Extension( const String rExt, SfxFilterFlags nMust = SFX_FILTER_IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const; diff --git a/sfx2/source/appl/sfxpicklist.cxx b/sfx2/source/appl/sfxpicklist.cxx index d80a80c..c3332d9 100644 --- a/sfx2/source/appl/sfxpicklist.cxx +++ b/sfx2/source/appl/sfxpicklist.cxx @@ -84,30 +84,30 @@ class StringLength : public ::cppu::WeakImplHelper1 XStringWidth } }; -void SfxPickList::CreatePicklistMenuTitle( Menu* pMenu, sal_uInt16 nItemId, const ::rtl::OUString aURLString, sal_uInt32 nNo ) +void SfxPickList::CreatePicklistMenuTitle( Menu* pMenu, sal_uInt16 nItemId, const String aURLString, sal_uInt32 nNo ) { -::rtl::OUStringBuffer aPickEntry; +String aPickEntry; if ( nNo 9 ) { -aPickEntry.append('~'); -aPickEntry.append(::rtl::OUString::valueOf(static_castsal_Int32(nNo + 1))); +aPickEntry += '~'; +aPickEntry += String::CreateFromInt32( nNo + 1 ); } else if ( nNo == 9 ) -aPickEntry.appendAscii(1~0); +aPickEntry += DEFINE_CONST_UNICODE(1~0); else -aPickEntry.append(::rtl::OUString::valueOf(static_castsal_Int32(nNo + 1))); -aPickEntry.appendAscii(: ); +aPickEntry += String::CreateFromInt32( nNo + 1 ); +aPickEntry += DEFINE_CONST_UNICODE(: ); INetURLObject aURL( aURLString ); rtl::OUString aTipHelpText; -rtl::OUString aAccessibleName = aPickEntry.toString(); +rtl::OUString aAccessibleName( aPickEntry ); if ( aURL.GetProtocol() == INET_PROT_FILE ) { // Do handle file URL differently = convert it to a system // path and abbreviate it with a special function: -::rtl::OUString aFileSystemPath( aURL.getFSysPath( INetURLObject::FSYS_DETECT ) ); +String aFileSystemPath( aURL.getFSysPath( INetURLObject::FSYS_DETECT ) ); ::rtl::OUString aSystemPath( aFileSystemPath ); ::rtl::OUString aCompactedSystemPath; @@ -116,28 +116,28 @@ void SfxPickList::CreatePicklistMenuTitle( Menu* pMenu, sal_uInt16
[Libreoffice-commits] .: sw/qa
sw/qa/core/macros-test.cxx | 17 + 1 file changed, 1 insertion(+), 16 deletions(-) New commits: commit fe8c3c69fd784af9df56706c0026b4a09aed1a2d Author: Markus Mohrhard markus.mohrh...@googlemail.com Date: Tue Nov 15 02:39:34 2011 +0100 we don't need to inherit from FiltersTest here diff --git a/sw/qa/core/macros-test.cxx b/sw/qa/core/macros-test.cxx index 10e83bc..d4ddbca 100644 --- a/sw/qa/core/macros-test.cxx +++ b/sw/qa/core/macros-test.cxx @@ -58,14 +58,11 @@ using namespace ::com::sun::star::uno; /* Implementation of Macros test */ -class SwMacrosTest -: public test::FiltersTest -, public test::BootstrapFixture +class SwMacrosTest : public test::BootstrapFixture { public: SwMacrosTest(); -virtual bool load(const rtl::OUString rFilter, const rtl::OUString rURL, const rtl::OUString rUserData); SwDocShellRef load(const rtl::OUString rFilter, const rtl::OUString rURL, const rtl::OUString rUserData, const rtl::OUString rTypeName, sal_uLong nFormatType=0); uno::Reference com::sun::star::lang::XComponent loadFromDesktop(const rtl::OUString rURL); @@ -108,18 +105,6 @@ uno::Reference com::sun::star::lang::XComponent SwMacrosTest::loadFromDesktop return xComponent; } - -bool SwMacrosTest::load(const rtl::OUString rFilter, const rtl::OUString rURL, -const rtl::OUString rUserData) -{ -SwDocShellRef xDocShRef; -bool bLoaded = xDocShRef.Is(); -//reference counting of SwDocShellRef is very confused. -if (bLoaded) -xDocShRef-DoClose(); -return bLoaded; -} - void SwMacrosTest::createFileURL(const rtl::OUString aFileBase, const rtl::OUString aFileExtension, rtl::OUString rFilePath) { rtl::OUString aSep(RTL_CONSTASCII_USTRINGPARAM(/)); ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: desktop/source
desktop/source/app/copyright_ascii_sun.c | 10 -- 1 file changed, 10 deletions(-) New commits: commit 9ba9707611e08b936ea800cbc9cd4270d0c19aae Author: Norbert Thiebaud nthieb...@gmail.com Date: Mon Nov 14 21:41:48 2011 -0600 remove unused desktop/source/app/copyright_ascii_sun.c diff --git a/desktop/source/app/copyright_ascii_sun.c b/desktop/source/app/copyright_ascii_sun.c deleted file mode 100644 index c7d6e7e..000 --- a/desktop/source/app/copyright_ascii_sun.c +++ /dev/null @@ -1,10 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ - - /* - * copyright text to see as text in the soffice binary - * - */ - -const char copyright_text_1[] = Copyright © 2000, 2010 Oracle and/or its affiliates, All rights reserved.; - -/* 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/source
vcl/source/gdi/print.cxx |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) New commits: commit 6947091ab0d93bfa84dbbb4a919368f2865d2a45 Author: David Tardon dtar...@redhat.com Date: Tue Nov 15 06:13:30 2011 +0100 use SAL_N_ELEMENTS diff --git a/vcl/source/gdi/print.cxx b/vcl/source/gdi/print.cxx index 440da9c..7812032 100644 --- a/vcl/source/gdi/print.cxx +++ b/vcl/source/gdi/print.cxx @@ -1292,8 +1292,8 @@ rtl::OUString Printer::GetPaperName( Paper ePaper ) PAPER_ENV_9, PAPER_ENV_10, PAPER_ENV_11, PAPER_ENV_12, PAPER_KAI16, PAPER_KAI32, PAPER_KAI32BIG, PAPER_B4_JIS, PAPER_B5_JIS, PAPER_B6_JIS }; -OSL_ENSURE( sal_uInt32(sizeof(PaperIndex)/sizeof(PaperIndex[0])) == aPaperStrings.Count(), localized paper name count wrong ); -for( int i = 0; i int(sizeof(PaperIndex)/sizeof(PaperIndex[0])); i++ ) +OSL_ENSURE( sal_uInt32(SAL_N_ELEMENTS(PaperIndex)) == aPaperStrings.Count(), localized paper name count wrong ); +for( int i = 0; i int(SAL_N_ELEMENTS(PaperIndex)); i++ ) (*pSVData-mpPaperNames)[PaperIndex[i]] = aPaperStrings.GetString(i); } } ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: 5 commits - sc/source
sc/source/core/data/dptablecache.cxx | 38 +++ sc/source/core/data/dptabres.cxx |4 +++ 2 files changed, 12 insertions(+), 30 deletions(-) New commits: commit 1d4971d77afa492bfdbfd18113eff4f77b3100e3 Author: Kohei Yoshida kohei.yosh...@suse.com Date: Tue Nov 15 00:19:54 2011 -0500 Beware that the sequence can be empty. And when it's empty, it causes an invalid array access later on. diff --git a/sc/source/core/data/dptabres.cxx b/sc/source/core/data/dptabres.cxx index 84ce258..c1a1824 100644 --- a/sc/source/core/data/dptabres.cxx +++ b/sc/source/core/data/dptabres.cxx @@ -1369,6 +1369,10 @@ void ScDPResultMember::FillMemberResults( uno::Sequencesheet::MemberResult* pS // IsVisible() test is in ScDPResultDimension::FillMemberResults // (not on data layout dimension) +if (!pSequences-getLength()) +// empty sequence. Bail out. +return; + long nSize = GetSize(nMeasure); sheet::MemberResult* pArray = pSequences-getArray(); OSL_ENSURE( rPos+nSize = pSequences-getLength(), bumm ); commit 690e14ad035e642f4382d20b8b7b792762338126 Author: Kohei Yoshida kohei.yosh...@suse.com Date: Mon Nov 14 23:21:02 2011 -0500 Unused local var. diff --git a/sc/source/core/data/dptablecache.cxx b/sc/source/core/data/dptablecache.cxx index ecfab69..5bbef8f 100644 --- a/sc/source/core/data/dptablecache.cxx +++ b/sc/source/core/data/dptablecache.cxx @@ -607,7 +607,6 @@ bool ScDPCache::ValidQuery( SCROW nRow, const ScQueryParam rParam) const const ScDPItemData* pCellData = GetItemDataById( nSourceField, nId ); bool bOk = false; -bool bTestEqual = false; if (rEntry.GetQueryItem().meType == ScQueryEntry::ByEmpty) { @@ -670,8 +669,6 @@ bool ScDPCache::ValidQuery( SCROW nRow, const ScQueryParam rParam) const bMatch = false;// RegExp must match entire cell string if (bRealRegExp) bOk = ((rEntry.eOp == SC_NOT_EQUAL) ? !bMatch : bMatch); -else -bTestEqual = bMatch; } if (!bRealRegExp) { commit 10afa30240edec37a052ee87ff5b5e36c615abcd Author: Kohei Yoshida kohei.yosh...@suse.com Date: Mon Nov 14 23:19:21 2011 -0500 Used std::vector instead of C-style array. diff --git a/sc/source/core/data/dptablecache.cxx b/sc/source/core/data/dptablecache.cxx index cbf9065..ecfab69 100644 --- a/sc/source/core/data/dptablecache.cxx +++ b/sc/source/core/data/dptablecache.cxx @@ -582,12 +582,8 @@ bool ScDPCache::ValidQuery( SCROW nRow, const ScQueryParam rParam) const return true; bool bMatchWholeCell = mpDoc-GetDocOptions().IsMatchWholeCell(); -//--- - -const SCSIZE nFixedBools = 32; -bool aBool[nFixedBools]; SCSIZE nEntryCount = rParam.GetEntryCount(); -bool* pPasst = ( nEntryCount = nFixedBools ? aBool[0] : new bool[nEntryCount] ); +std::vectorbool aPassed(nEntryCount, false); long nPos = -1; CollatorWrapper* pCollator = (rParam.bCaseSens ? ScGlobal::GetCaseCollator() : @@ -753,31 +749,26 @@ bool ScDPCache::ValidQuery( SCROW nRow, const ScQueryParam rParam) const if (nPos == -1) { nPos++; -pPasst[nPos] = bOk; +aPassed[nPos] = bOk; } else { if (rEntry.eConnect == SC_AND) { -pPasst[nPos] = pPasst[nPos] bOk; +aPassed[nPos] = aPassed[nPos] bOk; } else { nPos++; -pPasst[nPos] = bOk; +aPassed[nPos] = bOk; } } } for (long j=1; j = nPos; j++) -{ -pPasst[0] = pPasst[0] || pPasst[j]; -} - -bool bRet = pPasst[0]; -if (pPasst != aBool[0]) -delete [] pPasst; +aPassed[0] = aPassed[0] || aPassed[j]; +bool bRet = aPassed[0]; return bRet; } commit 011878812eac685b76a925fa9ffb17a152c27e6a Author: Kohei Yoshida kohei.yosh...@suse.com Date: Mon Nov 14 23:13:26 2011 -0500 This can be for loop instead. diff --git a/sc/source/core/data/dptablecache.cxx b/sc/source/core/data/dptablecache.cxx index 2810b51..cbf9065 100644 --- a/sc/source/core/data/dptablecache.cxx +++ b/sc/source/core/data/dptablecache.cxx @@ -589,14 +589,13 @@ bool ScDPCache::ValidQuery( SCROW nRow, const ScQueryParam rParam) const SCSIZE nEntryCount = rParam.GetEntryCount(); bool* pPasst = ( nEntryCount = nFixedBools ? aBool[0] : new bool[nEntryCount] ); -longnPos = -1; -SCSIZE i= 0; +long nPos = -1; CollatorWrapper* pCollator = (rParam.bCaseSens ? ScGlobal::GetCaseCollator() : ScGlobal::GetCollator() ); ::utl::TransliterationWrapper* pTransliteration = (rParam.bCaseSens ?
[Libreoffice-commits] .: set_soenv.in
set_soenv.in |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 7af550496ffa5489e9cebdb0625cd341f338cf14 Author: Jan Holesovsky ke...@suse.cz Date: Tue Nov 15 07:49:35 2011 +0100 Fix location of the prebuilt mozilla files. diff --git a/set_soenv.in b/set_soenv.in index d45d245..a05d288 100755 --- a/set_soenv.in +++ b/set_soenv.in @@ -837,7 +837,7 @@ if ( @WITH_MOZILLA@ eq YES and @BUILD_MOZAB@ ne TRUE and @SYSTEM_MOZILL print mozilla libraries yourself you have to provide the needed files\n; print $OS$COM$CPU\{inc,lib,runtime\}.zip in moz/zipped/ .\n; print These files can be found here:\n; - print http://tools.openoffice.org/moz_prebuild/680/.\n\n; + print http://dev-www.libreoffice.org/mozilla/.\n\n; die; } } ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: 3 commits - comphelper/inc comphelper/source sc/inc sc/source
comphelper/inc/comphelper/string.hxx |3 ++ comphelper/source/misc/string.cxx| 12 ++ sc/inc/dptabres.hxx | 36 +++--- sc/source/core/data/dptabres.cxx | 42 --- sc/source/core/data/dptabsrc.cxx | 12 +- 5 files changed, 59 insertions(+), 46 deletions(-) New commits: commit e786e2d25ab0105e88d7ca260c7ef4a88c9b821c Author: Kohei Yoshida kohei.yosh...@suse.com Date: Tue Nov 15 02:02:14 2011 -0500 String to rtl::OUString. diff --git a/comphelper/inc/comphelper/string.hxx b/comphelper/inc/comphelper/string.hxx index 4545302..620db1b 100644 --- a/comphelper/inc/comphelper/string.hxx +++ b/comphelper/inc/comphelper/string.hxx @@ -352,6 +352,9 @@ COMPHELPER_DLLPUBLIC inline rtl::OUStringBuffer padToLength( return detail::padToLength(rBuffer, nLength, cFill); } +COMPHELPER_DLLPUBLIC rtl::OUString removeTrailingChars( +const rtl::OUString rStr, sal_Unicode cChar); + /** Convert a sequence of strings to a single comma separated string. Note that no escaping of commas or anything fancy is done. diff --git a/comphelper/source/misc/string.cxx b/comphelper/source/misc/string.cxx index 873a1ff..6f59564 100644 --- a/comphelper/source/misc/string.cxx +++ b/comphelper/source/misc/string.cxx @@ -235,6 +235,18 @@ sal_uInt32 decimalStringToNumber( return result; } +rtl::OUString removeTrailingChars(const rtl::OUString rStr, sal_Unicode cChar) +{ +sal_Int32 n = rStr.getLength(); +const sal_Unicode* p = rStr.getStr()[n-1]; // last char +while (n 0 *p == cChar) +{ +--p; +--n; +} +return rStr.copy(0, n); +} + using namespace ::com::sun::star; // convert between sequence of string and comma separated string diff --git a/sc/inc/dptabres.hxx b/sc/inc/dptabres.hxx index b8a2414..2c92f22 100644 --- a/sc/inc/dptabres.hxx +++ b/sc/inc/dptabres.hxx @@ -299,7 +299,7 @@ private: ScSubTotalFunc* pMeasFuncs; ::com::sun::star::sheet::DataPilotFieldReference* pMeasRefs; sal_uInt16* pMeasRefOrient; -std::vectorString maMeasureNames; +std::vectorrtl::OUString maMeasureNames; boolbLateInit:1; boolbDataAtCol:1; boolbDataAtRow:1; @@ -312,7 +312,7 @@ public: voidSetMeasureData( long nCount, const ScSubTotalFunc* pFunctions, const ::com::sun::star::sheet::DataPilotFieldReference* pRefs, -const sal_uInt16* pRefOrient, std::vectorString rNames ); +const sal_uInt16* pRefOrient, std::vectorrtl::OUString rNames ); voidSetDataLayoutOrientation( sal_uInt16 nOrient ); voidSetLateInit( bool bSet ); diff --git a/sc/source/core/data/dptabres.cxx b/sc/source/core/data/dptabres.cxx index b7c5e0a..62feb0b 100644 --- a/sc/source/core/data/dptabres.cxx +++ b/sc/source/core/data/dptabres.cxx @@ -786,7 +786,7 @@ ScDPResultData::~ScDPResultData() void ScDPResultData::SetMeasureData( long nCount, const ScSubTotalFunc* pFunctions, const sheet::DataPilotFieldReference* pRefs, const sal_uInt16* pRefOrient, -std::vectorString rNames ) +std::vectorrtl::OUString rNames ) { delete[] pMeasFuncs; delete[] pMeasRefs; @@ -815,7 +815,7 @@ void ScDPResultData::SetMeasureData( long nCount, const ScSubTotalFunc* pFunctio pMeasRefs = new sheet::DataPilotFieldReference[1]; // default ctor is ok pMeasRefOrient = new sal_uInt16[1]; pMeasRefOrient[0] = sheet::DataPilotFieldOrientation_HIDDEN; -std::vectorString aMeasureName; +std::vectorrtl::OUString aMeasureName; aMeasureName.push_back(ScGlobal::GetRscString(STR_EMPTYDATA)); maMeasureNames.swap(aMeasureName); } @@ -887,18 +887,18 @@ String ScDPResultData::GetMeasureString(long nMeasure, bool bForce, ScSubTotalFu if (pLayoutName) return *pLayoutName; } -String aRet; +rtl::OUStringBuffer aRet; ScSubTotalFunc eFunc = ( eForceFunc == SUBTOTAL_FUNC_NONE ) ? GetMeasureFunction(nMeasure) : eForceFunc; sal_uInt16 nId = nFuncStrIds[eFunc]; if (nId) { -aRet += ScGlobal::GetRscString(nId);// function name -aRet.AppendAscii(RTL_CONSTASCII_STRINGPARAM( - )); +aRet.append(ScGlobal::GetRscString(nId));// function name +aRet.appendAscii(RTL_CONSTASCII_STRINGPARAM( - )); } -aRet += maMeasureNames[nMeasure]; // field name +aRet.append(maMeasureNames[nMeasure]); // field name -return aRet; +
[Libreoffice-commits] .: solenv/gbuild
solenv/gbuild/Output.mk |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) New commits: commit 7bd4f50af64e7fbec578e222cdf93a6003a12b09 Author: Thorsten Behrens tbehr...@suse.com Date: Tue Nov 15 08:49:27 2011 +0100 Remove non-animated prefixes in gb_COLOR mode. diff --git a/solenv/gbuild/Output.mk b/solenv/gbuild/Output.mk index 09885de..e4b811f 100644 --- a/solenv/gbuild/Output.mk +++ b/solenv/gbuild/Output.mk @@ -98,8 +98,8 @@ gb_Output_COLOR_ERROR := $(gb_Output_COLOR_RESETANDESCAPE)[37;1;41m define gb_Output__format_type $(subst :, ,$(word 2,$(1) \ - $(gb_Output_COLOR_OUTBUILD_LEVEL$(3))[:$(gb_Output_COLOR_INBUILD_LEVEL$(3))__.oO:$(subst $(WHITESPACE),:,$(2))$(gb_Output_COLOR_OUTBUILD_LEVEL$(3)):] \ - $(gb_Output_COLOR_OUTCLEAN_LEVEL$(3))[:$(gb_Output_COLOR_INCLEAN_LEVEL$(3))Xx.__:$(subst $(WHITESPACE),:,$(2))$(gb_Output_COLOR_OUTCLEAN_LEVEL$(3)):]))$(gb_Output_COLOR_RESET) + $(gb_Output_COLOR_OUTBUILD_LEVEL$(3))[:$(gb_Output_COLOR_INBUILD_LEVEL$(3))$(subst $(WHITESPACE),:,$(2))$(gb_Output_COLOR_OUTBUILD_LEVEL$(3)):] \ + $(gb_Output_COLOR_OUTCLEAN_LEVEL$(3))[:$(gb_Output_COLOR_INCLEAN_LEVEL$(3))$(subst $(WHITESPACE),:,$(2))$(gb_Output_COLOR_OUTCLEAN_LEVEL$(3)):]))$(gb_Output_COLOR_RESET) endef define gb_Output_info ___ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits