[Libreoffice-commits] .: bin/find-german-comments

2012-03-14 Thread Miklos Vajna
 bin/find-german-comments |   44 +++-
 1 file changed, 43 insertions(+), 1 deletion(-)

New commits:
commit 21c646a8e8e5154f7e7a85de4d50239b72ebc7f6
Author: Tom Thorogood t...@tomthorogood.com
Date:   Tue Mar 13 22:50:13 2012 -0400

Add options to bin/find-german-comments to help weed out false positives

diff --git a/bin/find-german-comments b/bin/find-german-comments
index e0ce382..1cc9d51 100755
--- a/bin/find-german-comments
+++ b/bin/find-german-comments
@@ -44,6 +44,10 @@ class Parser:
 help=Only print the filenames of files containing German 
comments)
 op.add_option(-v, --verbose, action=store_true, dest=verbose, 
default=False,
 help=Turn on verbose mode (print progress to stderr))
+op.add_option(-l, --line-numbers, action=store_true, 
dest=line_numbers, default=False,
+help=Prints the filenames and line numbers only.)
+op.add_option(-t, --threshold, action=store, dest=THRESHOLD, 
default=0,
+help=When used with '--line-numbers', only bothers outputting 
comment info if there are more than X number of flagged comments. Useful for 
weeding out false positives.)
 self.options, args = op.parse_args()
 try:
 dir = args[0]
@@ -141,7 +145,45 @@ class Parser:
 
 checks each comment in a file
 
-if not self.options.filenames_only:
+def tab_calc (string):
+START = 40 #Default of 10 tabs
+if len(string) = START:
+return 1, 0
+diff = START - len(string)
+if diff % 4 is not 0:
+padding = 1
+else:
+padding = 0
+return (diff/4)+padding
+
+if self.options.line_numbers:
+TABS = \t*10
+path_linenums = []
+for linenum, s in self.get_comments(path):
+if self.is_german(s):
+path_linenums.append(linenum)
+valid = len(path_linenums)  int(self.options.THRESHOLD)
+sys.stderr.write(%s ... %s positives -- %s\n % (path, 
str(len(path_linenums)), str(valid)))
+if valid:
+if len(path) + (len(path_linenums)*4)  75:
+print %s:\n % path
+while(path_linenums):
+i = 0
+numline = []
+while i  10:
+try:
+numline.append(path_linenums[0])
+path_linenums.remove(path_linenums[0])
+except IndexError:
+i = 10
+i+=1
+numline = [str(i) for i in numline]
+print %s%s %(TABS, ,.join(numline))
+else:
+path_linenums = [str(i) for i in path_linenums]
+print %s:%s%s % 
(path,\t*tab_calc(path),,.join(path_linenums))
+
+elif not self.options.filenames_only:
 for linenum, s in self.get_comments(path):
 if self.is_german(s):
 print %s:%s: %s % (path, linenum, s)
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: Repository.mk desktop/Executable_sbase.mk desktop/Executable_scalc.mk desktop/Executable_sdraw.mk desktop/Executable_simpress.mk desktop/Executable_smath.mk desktop/Executable

2012-03-14 Thread Michael Stahl
 Repository.mk|4 +++
 desktop/Executable_sbase.mk  |9 +++-
 desktop/Executable_scalc.mk  |9 +++-
 desktop/Executable_sdraw.mk  |9 +++-
 desktop/Executable_simpress.mk   |9 +++-
 desktop/Executable_smath.mk  |9 +++-
 desktop/Executable_sweb.mk   |9 +++-
 desktop/Executable_swriter.mk|9 +++-
 desktop/Module_desktop.mk|1 
 desktop/StaticLibrary_winlauncher.mk |   38 +++
 10 files changed, 71 insertions(+), 35 deletions(-)

New commits:
commit 5cc6398985181574b68ab15386176fb806386490
Author: Michael Stahl mst...@redhat.com
Date:   Wed Mar 14 12:30:53 2012 +0100

fdo#47246: desktop: factor out a winlauncher static library

diff --git a/Repository.mk b/Repository.mk
index ee6835c..351a365 100644
--- a/Repository.mk
+++ b/Repository.mk
@@ -83,6 +83,10 @@ $(eval $(call gb_Helper_register_executables,OOO,\
unopkgio \
 ))
 
+$(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \
+   winlauncher \
+))
+
 else
 
 $(eval $(call gb_Helper_register_executables,OOO,\
diff --git a/desktop/Executable_sbase.mk b/desktop/Executable_sbase.mk
index 37738a0..f3caf5b 100644
--- a/desktop/Executable_sbase.mk
+++ b/desktop/Executable_sbase.mk
@@ -29,10 +29,6 @@ $(eval $(call gb_Executable_Executable,sbase))
 
 $(eval $(call gb_Executable_set_targettype_gui,sbase,YES))
 
-$(eval $(call gb_Executable_set_include,sbase,\
-$$(INCLUDE) \
-))
-
 $(eval $(call gb_Executable_add_defs,sbase,\
 -DUNICODE \
 ))
@@ -41,8 +37,11 @@ $(eval $(call gb_Executable_add_linked_libs,sbase,\
 $(gb_STDLIBS) \
 ))
 
+$(eval $(call gb_Executable_add_linked_static_libs,sbase,\
+winlauncher \
+))
+
 $(eval $(call gb_Executable_add_noexception_objects,sbase,\
-desktop/win32/source/applauncher/launcher \
 desktop/win32/source/applauncher/sbase \
 ))
 
diff --git a/desktop/Executable_scalc.mk b/desktop/Executable_scalc.mk
index ec72742..3c9990b 100644
--- a/desktop/Executable_scalc.mk
+++ b/desktop/Executable_scalc.mk
@@ -29,10 +29,6 @@ $(eval $(call gb_Executable_Executable,scalc))
 
 $(eval $(call gb_Executable_set_targettype_gui,scalc,YES))
 
-$(eval $(call gb_Executable_set_include,scalc,\
-$$(INCLUDE) \
-))
-
 $(eval $(call gb_Executable_add_defs,scalc,\
 -DUNICODE \
 ))
@@ -41,8 +37,11 @@ $(eval $(call gb_Executable_add_linked_libs,scalc,\
 $(gb_STDLIBS) \
 ))
 
+$(eval $(call gb_Executable_add_linked_static_libs,scalc,\
+winlauncher \
+))
+
 $(eval $(call gb_Executable_add_noexception_objects,scalc,\
-desktop/win32/source/applauncher/launcher \
 desktop/win32/source/applauncher/scalc \
 ))
 
diff --git a/desktop/Executable_sdraw.mk b/desktop/Executable_sdraw.mk
index 24fec0e..dcea97d 100644
--- a/desktop/Executable_sdraw.mk
+++ b/desktop/Executable_sdraw.mk
@@ -29,10 +29,6 @@ $(eval $(call gb_Executable_Executable,sdraw))
 
 $(eval $(call gb_Executable_set_targettype_gui,sdraw,YES))
 
-$(eval $(call gb_Executable_set_include,sdraw,\
-$$(INCLUDE) \
-))
-
 $(eval $(call gb_Executable_add_defs,sdraw,\
 -DUNICODE \
 ))
@@ -41,8 +37,11 @@ $(eval $(call gb_Executable_add_linked_libs,sdraw,\
 $(gb_STDLIBS) \
 ))
 
+$(eval $(call gb_Executable_add_linked_static_libs,sdraw,\
+winlauncher \
+))
+
 $(eval $(call gb_Executable_add_noexception_objects,sdraw,\
-desktop/win32/source/applauncher/launcher \
 desktop/win32/source/applauncher/sdraw \
 ))
 
diff --git a/desktop/Executable_simpress.mk b/desktop/Executable_simpress.mk
index f0b7241..ab0cbc0 100644
--- a/desktop/Executable_simpress.mk
+++ b/desktop/Executable_simpress.mk
@@ -29,10 +29,6 @@ $(eval $(call gb_Executable_Executable,simpress))
 
 $(eval $(call gb_Executable_set_targettype_gui,simpress,YES))
 
-$(eval $(call gb_Executable_set_include,simpress,\
-$$(INCLUDE) \
-))
-
 $(eval $(call gb_Executable_add_defs,simpress,\
 -DUNICODE \
 ))
@@ -41,8 +37,11 @@ $(eval $(call gb_Executable_add_linked_libs,simpress,\
 $(gb_STDLIBS) \
 ))
 
+$(eval $(call gb_Executable_add_linked_static_libs,simpress,\
+winlauncher \
+))
+
 $(eval $(call gb_Executable_add_noexception_objects,simpress,\
-desktop/win32/source/applauncher/launcher \
 desktop/win32/source/applauncher/simpress \
 ))
 
diff --git a/desktop/Executable_smath.mk b/desktop/Executable_smath.mk
index ff73c2a..fe1607b 100644
--- a/desktop/Executable_smath.mk
+++ b/desktop/Executable_smath.mk
@@ -29,10 +29,6 @@ $(eval $(call gb_Executable_Executable,smath))
 
 $(eval $(call gb_Executable_set_targettype_gui,smath,YES))
 
-$(eval $(call gb_Executable_set_include,smath,\
-$$(INCLUDE) \
-))
-
 $(eval $(call gb_Executable_add_defs,smath,\
 -DUNICODE \
 ))
@@ -41,8 +37,11 @@ $(eval $(call gb_Executable_add_linked_libs,smath,\
 $(gb_STDLIBS) \
 ))
 
+$(eval $(call gb_Executable_add_linked_static_libs,smath,\
+winlauncher \
+))
+
 $(eval $(call 

[Libreoffice-commits] .: 4 commits - extras/source qadevOOo/testdocs sfx2/source svl/inc svl/source unusedcode.easy

2012-03-14 Thread Caolán McNamara
 extras/source/database/biblio.README |   16 +++-
 extras/source/database/biblio.odb|binary
 qadevOOo/testdocs/ttt.sdw|binary
 sfx2/source/dialog/filedlghelper.cxx |   15 +--
 svl/inc/svl/rngitem.hxx  |   11 ---
 svl/source/items/rngitem.cxx |6 --
 svl/source/items/rngitem_inc.cxx |   14 ++
 unusedcode.easy  |9 -
 8 files changed, 10 insertions(+), 61 deletions(-)

New commits:
commit 848127a6c3975bbbe09d8fe9ca704bf47030168d
Author: Caolán McNamara caol...@redhat.com
Date:   Wed Mar 14 11:26:40 2012 +

make sdw smoketest document more useful

diff --git a/qadevOOo/testdocs/ttt.sdw b/qadevOOo/testdocs/ttt.sdw
index 235a852..fa7a336 100644
Binary files a/qadevOOo/testdocs/ttt.sdw and b/qadevOOo/testdocs/ttt.sdw differ
commit 9de6b045ab27f5f103194a9109eacf53ea29a8b9
Author: Caolán McNamara caol...@redhat.com
Date:   Wed Mar 14 11:13:58 2012 +

toggle on view all records in biblio.odb

diff --git a/extras/source/database/biblio.README 
b/extras/source/database/biblio.README
index 8a25c5d..7c1fcb0 100644
--- a/extras/source/database/biblio.README
+++ b/extras/source/database/biblio.README
@@ -3,19 +3,17 @@ the database inside the .odb, instead it is configured to 
store its data in the
 per-user database/biblio/biblio.dbf and database/biblio/biblio.dbt files. i.e.
 the contents of the ~/.libreoffice/3/user/database/biblio dir.
 
-If you edit biblio.odb in base you will really just be changing your local 
data
-store.
+If you edit biblio.odb in base you will really just be changing your local
+data store.
 
-So, to really change the bibliography the easiest thing to do is to launch 
writer and
-use tools-bibliography database and edit your local one through that UI [1]
+So, to really change the bibliography the easiest thing to do is to launch
+writer and use tools-bibliography database and edit your local one through
+that UI.
 
 Then *copy* ~/.libreoffice/3/user/database/biblio/biblio.db* to
 extras/source/database/ in order to overwrite biblio.dbf and biblio.dbt and
 copy ~/.libreoffice/3/user/database/biblio.odb to
 extras/source/database/biblio.odb
 
-[1] a) oddly base doesn't show the same fields that the bibliography widget 
does,
-   possibly a bug worth fixing ?
-b) oddly base doesn't seem to PACK the dbase III files after editing, so
-   deleted records still take up space in the file, possibly a bug worth
-   fixing ?
+NOTE: base doesn't seem to PACK the dbase III files after editing, so deleted
+records still take up space in the file, possibly a bug worth fixing ?
diff --git a/extras/source/database/biblio.odb 
b/extras/source/database/biblio.odb
index 4e19692..199fd6f 100644
Binary files a/extras/source/database/biblio.odb and 
b/extras/source/database/biblio.odb differ
commit 60cf5b57b0cf12cad3406289e261d637c20f20d9
Author: Caolán McNamara caol...@redhat.com
Date:   Wed Mar 14 11:07:45 2012 +

callcatcher: update list

diff --git a/svl/inc/svl/rngitem.hxx b/svl/inc/svl/rngitem.hxx
index 02eeb06..3f65263 100644
--- a/svl/inc/svl/rngitem.hxx
+++ b/svl/inc/svl/rngitem.hxx
@@ -38,16 +38,6 @@
 #undef SfxXRangeItem
 #undef SfxXRangesItem
 
-#ifndef _SFXITEMS_HXX
-#define NUMTYPE sal_uLong
-#define SfxXRangeItem SfxULongRangeItem
-#define SfxXRangesItem SfxULongRangesItem
-#include svl/rngitem.hxx
-#undef NUMTYPE
-#undef SfxXRangeItem
-#undef SfxXRangesItem
-#endif
-
 #define _SFXRNGITEM_HXX
 
 #else
@@ -94,7 +84,6 @@ private:
 public:
 TYPEINFO();
 SfxXRangesItem();
-SfxXRangesItem( sal_uInt16 nWID, const NUMTYPE 
*pRanges );
 SfxXRangesItem( sal_uInt16 nWID, SvStream 
rStream );
 SfxXRangesItem( const SfxXRangesItem rItem );
 virtual ~SfxXRangesItem();
diff --git a/svl/source/items/rngitem.cxx b/svl/source/items/rngitem.cxx
index de742d7..924a5c2 100644
--- a/svl/source/items/rngitem.cxx
+++ b/svl/source/items/rngitem.cxx
@@ -36,12 +36,6 @@
 #include svl/rngitem.hxx
 #include rngitem_inc.cxx
 
-#define NUMTYPE sal_uInt32
-#define SfxXRangeItem SfxULongRangeItem
-#define SfxXRangesItem SfxULongRangesItem
-#include svl/rngitem.hxx
-#include rngitem_inc.cxx
-
 #else
 
 // We leave this condition just in case NUMTYPE has been defined externally to 
this
diff --git a/svl/source/items/rngitem_inc.cxx b/svl/source/items/rngitem_inc.cxx
index 7c87cb7..2ce9857 100644
--- a/svl/source/items/rngitem_inc.cxx
+++ b/svl/source/items/rngitem_inc.cxx
@@ -108,7 +108,7 @@ SfxPoolItem* SfxXRangeItem::Clone(SfxItemPool *) const
 
 SfxPoolItem* SfxXRangeItem::Create(SvStream rStream, sal_uInt16) const
 {
-NUMTYPE nVon, nBis;
+NUMTYPE nVon(0), nBis(0);
 rStream  nVon;
 rStream  nBis;
 return new SfxXRangeItem( Which(), nVon, nBis );
@@ -132,20 +132,10 @@ 

[Libreoffice-commits] .: dtrans/Library_dnd.mk dtrans/Library_ftransl.mk dtrans/Library_sysdtrans.mk

2012-03-14 Thread Michael Stahl
 dtrans/Library_dnd.mk   |1 -
 dtrans/Library_ftransl.mk   |5 -
 dtrans/Library_sysdtrans.mk |1 -
 3 files changed, 4 insertions(+), 3 deletions(-)

New commits:
commit fe4be5047988782f3143a1af505c5eecb3f2af5a
Author: Michael Stahl mst...@redhat.com
Date:   Wed Mar 14 13:20:50 2012 +0100

fdo#47246: dtrans: fix multiply linked ImplHelper

No idea whether linking ftransl against static library dtobj is good,
but the other two libraries here link against it already...

diff --git a/dtrans/Library_dnd.mk b/dtrans/Library_dnd.mk
index 58f0f00..141d15b 100644
--- a/dtrans/Library_dnd.mk
+++ b/dtrans/Library_dnd.mk
@@ -66,7 +66,6 @@ $(eval $(call gb_Library_add_exception_objects,dnd,\
dtrans/source/win32/dnd/target \
dtrans/source/win32/dnd/targetdragcontext \
dtrans/source/win32/dnd/targetdropcontext \
-   dtrans/source/win32/misc/ImplHelper \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/dtrans/Library_ftransl.mk b/dtrans/Library_ftransl.mk
index 3ba3c3e..706cbd0 100644
--- a/dtrans/Library_ftransl.mk
+++ b/dtrans/Library_ftransl.mk
@@ -50,8 +50,11 @@ $(eval $(call gb_Library_add_linked_libs,ftransl,\
$(gb_STDLIBS) \
 ))
 
+$(eval $(call gb_Library_add_linked_static_libs,ftransl,\
+   dtobj \
+))
+
 $(eval $(call gb_Library_add_exception_objects,ftransl,\
-   dtrans/source/win32/misc/ImplHelper \
dtrans/source/win32/ftransl/ftransl \
dtrans/source/win32/ftransl/ftranslentry \
 ))
diff --git a/dtrans/Library_sysdtrans.mk b/dtrans/Library_sysdtrans.mk
index 8fb7a41..8507675 100644
--- a/dtrans/Library_sysdtrans.mk
+++ b/dtrans/Library_sysdtrans.mk
@@ -67,7 +67,6 @@ $(eval $(call gb_Library_add_exception_objects,sysdtrans,\
dtrans/source/win32/clipb/WinClipboard \
dtrans/source/win32/clipb/wcbentry \
dtrans/source/win32/clipb/MtaOleClipb \
-   dtrans/source/win32/misc/ImplHelper \
 ))
 
 # vim: set noet sw=4 ts=4:
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: binfilter/bf_basic binfilter/bf_forms binfilter/bf_sc binfilter/bf_sw binfilter/bf_xmloff binfilter/inc

2012-03-14 Thread Stephan Bergmann
 binfilter/bf_basic/source/inc/sbintern.hxx   |1 
 binfilter/bf_forms/source/inc/InterfaceContainer.hxx |3 +-
 binfilter/bf_forms/source/inc/property.hxx   |2 +
 binfilter/bf_sc/source/core/tool/sc_interpr3.cxx |   13 
 binfilter/bf_sc/source/filter/xml/XMLStylesExportHelper.hxx  |6 ++--
 binfilter/bf_sw/source/core/inc/flowfrm.hxx  |2 +
 binfilter/bf_sw/source/core/inc/txmsrt.hxx   |   16 ++-
 binfilter/bf_sw/source/core/txtnode/sw_fntcap.cxx|9 ++
 binfilter/bf_sw/source/core/unocore/sw_unoframe.cxx  |8 ++---
 binfilter/bf_sw/source/filter/sw6/sw6file.hxx|2 -
 binfilter/bf_xmloff/source/chart/MultiPropertySetHandler.hxx |4 ++
 binfilter/bf_xmloff/source/forms/callbacks.hxx   |   15 ++
 binfilter/bf_xmloff/source/forms/elementexport.hxx   |8 +++--
 binfilter/bf_xmloff/source/forms/eventimport.hxx |2 +
 binfilter/inc/bf_basic/basmgr.hxx|3 ++
 binfilter/inc/bf_basic/sbxfac.hxx|1 
 binfilter/inc/bf_goodies/b3dlight.hxx|4 ++
 binfilter/inc/bf_goodies/b3dtrans.hxx|6 
 binfilter/inc/bf_goodies/matril3d.hxx|2 +
 binfilter/inc/bf_sfx2/cfgitem.hxx|7 ++--
 binfilter/inc/bf_sfx2/evntconf.hxx   |2 +
 binfilter/inc/bf_so3/ipenv.hxx   |3 ++
 binfilter/inc/bf_so3/transprt.hxx|3 ++
 binfilter/inc/bf_starmath/utility.hxx|5 +--
 binfilter/inc/bf_svtools/itemprop.hxx|2 +
 binfilter/inc/bf_svtools/wallitem.hxx|1 
 binfilter/inc/bf_svx/camera3d.hxx|2 +
 binfilter/inc/bf_svx/fmdmod.hxx  |2 +
 binfilter/inc/bf_svx/svdetc.hxx  |1 
 binfilter/inc/bf_svx/unomaster.hxx   |3 ++
 binfilter/inc/bf_svx/unomod.hxx  |2 +
 binfilter/inc/bf_svx/unoprov.hxx |3 ++
 binfilter/inc/bf_svx/viewpt3d.hxx|2 +
 binfilter/inc/bf_sw/TextCursorHelper.hxx |7 +++-
 binfilter/inc/bf_sw/cellfml.hxx  |2 +
 binfilter/inc/bf_sw/index.hxx|2 -
 binfilter/inc/bf_sw/printdata.hxx|2 +
 binfilter/inc/bf_sw/swcrsr.hxx   |3 ++
 binfilter/inc/bf_sw/unocoll.hxx  |2 +
 binfilter/inc/bf_sw/viscrs.hxx   |2 -
 binfilter/inc/bf_xmloff/txtvfldi.hxx |2 +
 41 files changed, 139 insertions(+), 28 deletions(-)

New commits:
commit c599fdba10c210ecf3f94119cb1138f3846320df
Author: Stephan Bergmann sberg...@redhat.com
Date:   Wed Mar 14 13:29:56 2012 +0100

Adapted to -Wnon-virtual-dtor enabled for GCC 4.6

diff --git a/binfilter/bf_basic/source/inc/sbintern.hxx 
b/binfilter/bf_basic/source/inc/sbintern.hxx
index 1ce571a..2d46bab 100644
--- a/binfilter/bf_basic/source/inc/sbintern.hxx
+++ b/binfilter/bf_basic/source/inc/sbintern.hxx
@@ -49,6 +49,7 @@ class SbModule;
 class SbiFactory : public SbxFactory
 {
 public:
+virtual ~SbiFactory() {}
 virtual SbxBase* Create( UINT16 nSbxId, UINT32 = SBXCR_SBX );
 virtual SbxObject* CreateObject( const String );
 };
diff --git a/binfilter/bf_forms/source/inc/InterfaceContainer.hxx 
b/binfilter/bf_forms/source/inc/InterfaceContainer.hxx
index 7203520..3ed6bb0 100644
--- a/binfilter/bf_forms/source/inc/InterfaceContainer.hxx
+++ b/binfilter/bf_forms/source/inc/InterfaceContainer.hxx
@@ -105,12 +105,13 @@ protected:
 // EventManager
 ::com::sun::star::uno::Reference 
::com::sun::star::script::XEventAttacherManager  m_xEventAttacher;
 
-public:
 OInterfaceContainer(
 const ::com::sun::star::uno::Reference 
::com::sun::star::lang::XMultiServiceFactory _rxFactory,
 ::osl::Mutex _rMutex,
 const ::com::sun::star::uno::Type _rElementType);
 
+~OInterfaceContainer() {}
+
 public:
 // ::com::sun::star::io::XPersistObject
 virtual ::rtl::OUString SAL_CALL getServiceName(  ) 
throw(::com::sun::star::uno::RuntimeException) = 0;
diff --git a/binfilter/bf_forms/source/inc/property.hxx 
b/binfilter/bf_forms/source/inc/property.hxx
index 6ad0c21..c7d864d 100644
--- a/binfilter/bf_forms/source/inc/property.hxx
+++ b/binfilter/bf_forms/source/inc/property.hxx
@@ -103,6 +103,8 @@ private:
 class ConcretInfoService : public ::comphelper::IPropertyInfoService
 {
 public:
+virtual ~ConcretInfoService() {}
+
 virtual sal_Int32 getPreferedPropertyId(const 

[Libreoffice-commits] .: vcl/source

2012-03-14 Thread David Tardon
 vcl/source/gdi/print3.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 6d4cca9c22c52b5a7742adc47ebf1a2930e29764
Author: David Tardon dtar...@redhat.com
Date:   Wed Mar 14 13:58:37 2012 +0100

fix setting of paper tray from print dialog (fdo#43932)

This fixes the simple case when all pages are to be printed from the
same paper tray. The use of this setting is still confusing when there
is application-set tray for a page (e.g., for a page style in Writer,
through Format-Page), because the change in Preferences is applied (and
will be used for pages without application-set tray), but Preferences
shows the application-set value on second try again...

IOW, it still s---s, but it s---s a bit less .-)

diff --git a/vcl/source/gdi/print3.cxx b/vcl/source/gdi/print3.cxx
index 4824203..817e6d5 100644
--- a/vcl/source/gdi/print3.cxx
+++ b/vcl/source/gdi/print3.cxx
@@ -773,7 +773,7 @@ PrinterController::PageSize 
vcl::ImplPrinterControllerData::modifyJobSetup( cons
 PrinterController::PageSize aPageSize;
 aPageSize.aSize = mpPrinter-GetPaperSize();
 awt::Size aSetSize, aIsSize;
-sal_Int32 nPaperBin = mnDefaultPaperBin;
+sal_Int32 nPaperBin = (mnFixedPaperBin != -1) ? mnFixedPaperBin : 
mnDefaultPaperBin;
 for( sal_Int32 nProperty = 0, nPropertyCount = i_rProps.getLength(); 
nProperty  nPropertyCount; ++nProperty )
 {
 if( i_rProps[ nProperty ].Name.equalsAsciiL( 
RTL_CONSTASCII_STRINGPARAM( PreferredPageSize ) ) )
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: sc/qa

2012-03-14 Thread Caolán McNamara
 sc/qa/unit/data/xls/pass/CVE-2007-0031-1.xls |binary
 sc/qa/unit/data/xls/pass/CVE-2007-3490-1.xls |binary
 sc/qa/unit/data/xls/pass/CVE-2010-1246-1.xls |binary
 3 files changed

New commits:
commit 96d28ecffcc9b0e461d9fe10ca4dedd676f1f933
Author: Caolán McNamara caol...@redhat.com
Date:   Wed Mar 14 13:47:14 2012 +

add some more torture tests

diff --git a/sc/qa/unit/data/xls/pass/CVE-2007-0031-1.xls 
b/sc/qa/unit/data/xls/pass/CVE-2007-0031-1.xls
new file mode 100644
index 000..2981d60
Binary files /dev/null and b/sc/qa/unit/data/xls/pass/CVE-2007-0031-1.xls differ
diff --git a/sc/qa/unit/data/xls/pass/CVE-2007-3490-1.xls 
b/sc/qa/unit/data/xls/pass/CVE-2007-3490-1.xls
new file mode 100644
index 000..9f0b9b2
Binary files /dev/null and b/sc/qa/unit/data/xls/pass/CVE-2007-3490-1.xls differ
diff --git a/sc/qa/unit/data/xls/pass/CVE-2010-1246-1.xls 
b/sc/qa/unit/data/xls/pass/CVE-2010-1246-1.xls
new file mode 100644
index 000..1b7c48c
Binary files /dev/null and b/sc/qa/unit/data/xls/pass/CVE-2010-1246-1.xls differ
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: cui/source vcl/source

2012-03-14 Thread Kohei Yoshida
 cui/source/tabpages/page.h   |1 +
 cui/source/tabpages/page.src |2 ++
 vcl/source/gdi/print.cxx |3 ++-
 vcl/source/src/print.src |1 +
 4 files changed, 6 insertions(+), 1 deletion(-)

New commits:
commit 467ac438a3864b3f10ca2f14ed7c5497cf75e4de
Author: Takeshi Abe t...@fixedpoint.jp
Date:   Wed Mar 14 02:07:36 2012 +0900

add 'Japanese Postcard' paper size to both Paper format and Print dialog

diff --git a/cui/source/tabpages/page.h b/cui/source/tabpages/page.h
index 9a6af59..bc7ad78 100644
--- a/cui/source/tabpages/page.h
+++ b/cui/source/tabpages/page.h
@@ -72,6 +72,7 @@
 #define PAPERSIZE_B4_JIS34
 #define PAPERSIZE_B5_JIS35
 #define PAPERSIZE_B6_JIS36
+#define PAPERSIZE_POSTCARD_JP   46
 #define PAPERSIZE_A656
 
 #endif
diff --git a/cui/source/tabpages/page.src b/cui/source/tabpages/page.src
index b1bf107..91873c7 100644
--- a/cui/source/tabpages/page.src
+++ b/cui/source/tabpages/page.src
@@ -418,6 +418,7 @@ StringArray RID_SVXSTRARY_PAPERSIZE_STD
  #10 Envelope ; PAPERSIZE_COM10;  ;
  #11 Envelope ; PAPERSIZE_COM11;  ;
  #12 Envelope ; PAPERSIZE_COM12;  ;
+ Japanese Postcard ; PAPERSIZE_POSTCARD_JP;  ;
 };
 };
 StringArray RID_SVXSTRARY_PAPERSIZE_DRAW
@@ -452,6 +453,7 @@ StringArray RID_SVXSTRARY_PAPERSIZE_DRAW
  C4 Envelope ; PAPERSIZE_C4 ;  ;
  Dia Slide ; PAPERSIZE_DIA ;  ;
  Screen ; PAPERSIZE_SCREEN ;  ;
+ Japanese Postcard ; PAPERSIZE_POSTCARD_JP;  ;
 };
 };
  // ** EOF
diff --git a/vcl/source/gdi/print.cxx b/vcl/source/gdi/print.cxx
index e25aa3a..90e8403 100644
--- a/vcl/source/gdi/print.cxx
+++ b/vcl/source/gdi/print.cxx
@@ -1267,7 +1267,8 @@ rtl::OUString Printer::GetPaperName( Paper ePaper )
 PAPER_ENV_DL, PAPER_SLIDE_DIA, PAPER_SCREEN, PAPER_C, PAPER_D, 
PAPER_E,
 PAPER_EXECUTIVE, PAPER_FANFOLD_LEGAL_DE, PAPER_ENV_MONARCH, 
PAPER_ENV_PERSONAL,
 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
+PAPER_KAI32, PAPER_KAI32BIG, PAPER_B4_JIS, PAPER_B5_JIS, 
PAPER_B6_JIS,
+PAPER_POSTCARD_JP
 };
 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++ )
diff --git a/vcl/source/src/print.src b/vcl/source/src/print.src
index e1dab96..986c381 100644
--- a/vcl/source/src/print.src
+++ b/vcl/source/src/print.src
@@ -531,6 +531,7 @@ StringArray RID_STR_PAPERNAMES
  B4 (JIS); ;
  B5 (JIS); ;
  B6 (JIS); ;
+ Japanese Postcard; ;
 };
 };
 
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: cppu/source

2012-03-14 Thread Stephan Bergmann
 cppu/source/threadpool/current.cxx |   12 
 1 file changed, 12 deletions(-)

New commits:
commit ba6714d34f9896195bca3680da89febcf259e421
Author: Stephan Bergmann sberg...@redhat.com
Date:   Wed Mar 14 15:20:04 2012 +0100

Dead code

diff --git a/cppu/source/threadpool/current.cxx 
b/cppu/source/threadpool/current.cxx
index 87b8c41..ce92209 100644
--- a/cppu/source/threadpool/current.cxx
+++ b/cppu/source/threadpool/current.cxx
@@ -47,18 +47,6 @@ using namespace ::com::sun::star::uno;
 namespace cppu
 {
 
-//--
-class SAL_NO_VTABLE XInterface
-{
-public:
-virtual void SAL_CALL slot_queryInterface() = 0;
-virtual void SAL_CALL acquire() throw () = 0;
-virtual void SAL_CALL release() throw () = 0;
-protected:
-~XInterface() {}
-// avoid warnings about virtual members and non-virtual dtor
-};
-//--
 static typelib_InterfaceTypeDescription * get_type_XCurrentContext()
 {
 static typelib_InterfaceTypeDescription * s_type_XCurrentContext = 0;
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: sw/source

2012-03-14 Thread Miklos Vajna
 sw/source/ui/chrdlg/pardlg.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit f1a2665128fa476f571cfd47c29b202a7ecc21cc
Author: Miklos Vajna vmik...@suse.cz
Date:   Wed Mar 14 15:13:40 2012 +0100

SwParaDlg::PageCreated: replace this hardwired 0x001E with something 
readable

diff --git a/sw/source/ui/chrdlg/pardlg.cxx b/sw/source/ui/chrdlg/pardlg.cxx
index be65dfb..7e92407 100644
--- a/sw/source/ui/chrdlg/pardlg.cxx
+++ b/sw/source/ui/chrdlg/pardlg.cxx
@@ -186,7 +186,8 @@ void SwParaDlg::PageCreated(sal_uInt16 nId, SfxTabPage 
rPage)
 
 if (!bDrawParaDlg)
 {
-aSet.Put(SfxUInt32Item(SID_SVXSTDPARAGRAPHTABPAGE_FLAGSET,0x001E));
+// See SvxStdParagraphTabPage::PageCreated: enable RegisterMode, 
AutoFirstLine, NegativeMode, ContextualMode
+
aSet.Put(SfxUInt32Item(SID_SVXSTDPARAGRAPHTABPAGE_FLAGSET,0x0002|0x0004|0x0008|0x0010));
 aSet.Put(SfxUInt32Item(SID_SVXSTDPARAGRAPHTABPAGE_ABSLINEDIST, 
MM50/10));
 
 }
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: 2 commits - Repository.mk desktop/Executable_soffice.bin.mk desktop/Executable_soffice.mk desktop/Executable_unopkg.mk desktop/Module_desktop.mk desktop/StaticLibrary_winexten

2012-03-14 Thread Michael Stahl
 Repository.mk|1 
 desktop/Executable_soffice.bin.mk|5 --
 desktop/Executable_soffice.mk|6 --
 desktop/Executable_unopkg.mk |6 --
 desktop/Module_desktop.mk|1 
 desktop/StaticLibrary_winextendloaderenv.mk  |   34 +
 fpicker/Library_fop.mk   |   67 ---
 fpicker/Library_fps.mk   |6 ++
 fpicker/Module_fpicker.mk|1 
 fpicker/source/win32/filepicker/FPentry.cxx  |   28 +++
 fpicker/source/win32/folderpicker/MtaFop.cxx |2 
 fpicker/source/win32/fps.component   |   37 ++
 fpicker/util/fop.component   |   34 -
 fpicker/util/fps.component   |   34 -
 postprocess/packcomponents/makefile.mk   |3 -
 postprocess/rebase/coffbase.txt  |1 
 scp2/source/ooo/file_library_ooo.scp |   11 
 17 files changed, 111 insertions(+), 166 deletions(-)

New commits:
commit 5142e628b563a9876e8884c5dd4914eff4a2f307
Author: Michael Stahl mst...@redhat.com
Date:   Wed Mar 14 16:20:27 2012 +0100

fdo#47246: fpicker: merge fop library into fps:

Since nobody seems to know why these are separate, merge fop into fps.
In case this untested change doesn't work out it should be reverted :)

diff --git a/fpicker/Library_fop.mk b/fpicker/Library_fop.mk
deleted file mode 100644
index 2d6091d..000
--- a/fpicker/Library_fop.mk
+++ /dev/null
@@ -1,67 +0,0 @@
-# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*-
-#
-# Version: MPL 1.1 / GPLv3+ / LGPLv3+
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the License); you may not use this file except in compliance with
-# the License or as specified alternatively below. You may obtain a copy of
-# the License at http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an AS IS basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# Major Contributor(s):
-# Copyright (C) 2011 Matúš Kukan matus.ku...@gmail.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.
-
-$(eval $(call gb_Library_Library,fop))
-
-$(eval $(call gb_Library_set_componentfile,fop,fpicker/util/fop))
-
-$(eval $(call gb_Library_add_api,fop,\
-   offapi \
-   udkapi \
-))
-
-$(eval $(call gb_Library_add_defs,fop,\
-   -DUNICODE \
-   -D_UNICODE \
-))
-
-$(eval $(call gb_Library_add_linked_libs,fop,\
-   comphelper \
-   cppu \
-   cppuhelper \
-   sal \
-   tl \
-   vcl \
-   advapi32 \
-   gdi32 \
-   ole32 \
-   oleaut32 \
-   shell32 \
-   $(gb_STDLIBS) \
-))
-
-$(eval $(call gb_Library_add_exception_objects,fop,\
-   fpicker/source/win32/folderpicker/FolderPicker \
-   fpicker/source/win32/folderpicker/Fopentry \
-   fpicker/source/win32/folderpicker/MtaFop \
-   fpicker/source/win32/folderpicker/WinFOPImpl \
-   fpicker/source/win32/misc/AutoBuffer \
-   fpicker/source/win32/misc/resourceprovider \
-   fpicker/source/win32/misc/WinImplHelper \
-))
-
-# vim: set noet sw=4 ts=4:
diff --git a/fpicker/Library_fps.mk b/fpicker/Library_fps.mk
index 3d8a0a5..e70bdf4 100644
--- a/fpicker/Library_fps.mk
+++ b/fpicker/Library_fps.mk
@@ -29,7 +29,7 @@ $(eval $(call gb_Library_Library,fps))
 
 $(eval $(call gb_Library_add_nativeres,fps,fps/src))
 
-$(eval $(call gb_Library_set_componentfile,fps,fpicker/util/fps))
+$(eval $(call gb_Library_set_componentfile,fps,fpicker/source/win32/fps))
 
 $(eval $(call gb_Library_add_api,fps,\
offapi \
@@ -93,6 +93,10 @@ $(eval $(call gb_Library_add_exception_objects,fps,\
fpicker/source/win32/filepicker/VistaFilePickerEventHandler \
fpicker/source/win32/filepicker/VistaFilePickerImpl \
fpicker/source/win32/filepicker/WinFileOpenImpl \
+   fpicker/source/win32/folderpicker/FolderPicker \
+   fpicker/source/win32/folderpicker/Fopentry \
+   fpicker/source/win32/folderpicker/MtaFop \
+   fpicker/source/win32/folderpicker/WinFOPImpl \
fpicker/source/win32/misc/AutoBuffer \
fpicker/source/win32/misc/resourceprovider \
fpicker/source/win32/misc/WinImplHelper \
diff --git a/fpicker/Module_fpicker.mk b/fpicker/Module_fpicker.mk
index 1f0696f..0491e54 100644
--- a/fpicker/Module_fpicker.mk
+++ b/fpicker/Module_fpicker.mk
@@ -44,7 

[Libreoffice-commits] .: sc/source

2012-03-14 Thread Kohei Yoshida
 sc/source/ui/docshell/dbdocfun.cxx |9 +
 1 file changed, 9 insertions(+)

New commits:
commit f6cba0dbb3819cf2e11f72bc0cdb10d5d90721de
Author: Kohei Yoshida kohei.yosh...@gmail.com
Date:   Wed Mar 14 11:27:17 2012 -0400

We need to manually clear the table data in presence of group fields.

There was a hack that did this in ScDPObject, which I removed.  But we
still need to do the same except this time it's outside of ScDPObject.

diff --git a/sc/source/ui/docshell/dbdocfun.cxx 
b/sc/source/ui/docshell/dbdocfun.cxx
index 2881e1d..c1464b1 100644
--- a/sc/source/ui/docshell/dbdocfun.cxx
+++ b/sc/source/ui/docshell/dbdocfun.cxx
@@ -1460,6 +1460,11 @@ sal_uLong ScDBDocFunc::RefreshPivotTables(ScDPObject* 
pDPObj, bool bApi)
 if (!pDPs)
 return 0;
 
+bool bHasGroups = false;
+ScDPSaveData* pSaveData = pDPObj-GetSaveData();
+if (pSaveData  pSaveData-GetExistingDimensionData())
+bHasGroups = true;
+
 std::setScDPObject* aRefs;
 sal_uLong nErrId = pDPs-ReloadCache(pDPObj, aRefs);
 if (nErrId)
@@ -1469,6 +1474,10 @@ sal_uLong ScDBDocFunc::RefreshPivotTables(ScDPObject* 
pDPObj, bool bApi)
 for (; it != itEnd; ++it)
 {
 ScDPObject* pObj = *it;
+if (bHasGroups)
+// Re-build table data for each pivot table when the original 
contains group fields.
+pObj-ClearTableData();
+
 // This action is intentionally not undoable since it modifies cache.
 DataPilotUpdate(pObj, pObj, false, bApi);
 }
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: filter/CppunitTest_filter_tiff_test.mk filter/Module_filter.mk filter/qa

2012-03-14 Thread Caolán McNamara
 filter/CppunitTest_filter_tiff_test.mk|   69 +
 filter/Module_filter.mk   |7 +
 filter/qa/cppunit/data/tiff/fail/CVE-2006-3459-1.tiff |binary
 filter/qa/cppunit/data/tiff/fail/CVE-2009-2285-1.tiff |binary
 filter/qa/cppunit/data/tiff/fail/CVE-2010-2482-1.tiff |binary
 filter/qa/cppunit/data/tiff/indeterminate/.gitignore  |1 
 filter/qa/cppunit/data/tiff/pass/CVE-2005-1544-1.tiff |binary
 filter/qa/cppunit/data/tiff/pass/CVE-2006-2656-1.tiff |binary
 filter/qa/cppunit/data/tiff/pass/CVE-2007-2217-1.tiff |binary
 filter/qa/cppunit/filters-tiff-test.cxx   |   89 ++
 10 files changed, 166 insertions(+)

New commits:
commit e6c0961c3d7d99591ffd8aca454623ec0d8fdefd
Author: Caolán McNamara caol...@redhat.com
Date:   Wed Mar 14 16:33:54 2012 +

add a tiff test

diff --git a/filter/CppunitTest_filter_tiff_test.mk 
b/filter/CppunitTest_filter_tiff_test.mk
new file mode 100644
index 000..33480d1
--- /dev/null
+++ b/filter/CppunitTest_filter_tiff_test.mk
@@ -0,0 +1,69 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the License); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an AS IS basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# Major Contributor(s):
+# Copyright (C) 2012 Red Hat, Inc., Caolán McNamara caol...@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.
+
+$(eval $(call gb_CppunitTest_CppunitTest,filter_tiff_test))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,filter_tiff_test, \
+filter/qa/cppunit/filters-tiff-test \
+))
+
+$(eval $(call gb_CppunitTest_add_linked_libs,filter_tiff_test, \
+iti \
+   sal \
+   test \
+   tl \
+   unotest \
+   vcl \
+$(gb_STDLIBS) \
+))
+
+$(eval $(call gb_CppunitTest_set_include,filter_tiff_test,\
+$$(INCLUDE) \
+))
+
+$(eval $(call gb_CppunitTest_add_api,filter_tiff_test,\
+udkapi \
+offapi \
+))
+
+$(eval $(call gb_CppunitTest_uses_ure,filter_tiff_test))
+
+$(eval $(call gb_CppunitTest_add_type_rdbs,filter_tiff_test,\
+types \
+))
+
+$(eval $(call gb_CppunitTest_add_components,filter_tiff_test,\
+configmgr/source/configmgr \
+))
+
+$(eval $(call gb_CppunitTest_set_args,filter_tiff_test,\
+--headless \
+--protector unoexceptionprotector$(gb_Library_DLLEXT) 
unoexceptionprotector \
+-env:CONFIGURATION_LAYERS=xcsxcu:$(call 
gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/filter/Module_filter.mk b/filter/Module_filter.mk
index 3fbb5e8..dc8842e 100644
--- a/filter/Module_filter.mk
+++ b/filter/Module_filter.mk
@@ -75,6 +75,13 @@ $(eval $(call gb_Module_add_targets,filter,\
 ))
 endif
 
+ifneq ($(OS),WNT)
+# TODO, see if it links and runs under windows
+$(eval $(call gb_Module_add_check_targets,filter,\
+CppunitTest_filter_tiff_test \
+))
+endif
+
 # TODO
 #$(eval $(call gb_Module_add_subsequentcheck_targets,filter,\
JunitTest_filter_complex \
diff --git a/filter/qa/cppunit/data/tiff/fail/.gitignore 
b/filter/qa/cppunit/data/tiff/fail/.gitignore
new file mode 100644
index 000..e69de29
diff --git a/filter/qa/cppunit/data/tiff/fail/CVE-2006-3459-1.tiff 
b/filter/qa/cppunit/data/tiff/fail/CVE-2006-3459-1.tiff
new file mode 100644
index 000..323fb17
Binary files /dev/null and 
b/filter/qa/cppunit/data/tiff/fail/CVE-2006-3459-1.tiff differ
diff --git a/filter/qa/cppunit/data/tiff/fail/CVE-2009-2285-1.tiff 
b/filter/qa/cppunit/data/tiff/fail/CVE-2009-2285-1.tiff
new file mode 100644
index 000..896de2b
Binary files /dev/null and 
b/filter/qa/cppunit/data/tiff/fail/CVE-2009-2285-1.tiff differ
diff --git a/filter/qa/cppunit/data/tiff/fail/CVE-2010-2482-1.tiff 
b/filter/qa/cppunit/data/tiff/fail/CVE-2010-2482-1.tiff
new file mode 100644
index 000..59e3c7e
Binary files /dev/null and 
b/filter/qa/cppunit/data/tiff/fail/CVE-2010-2482-1.tiff differ
diff --git a/filter/qa/cppunit/data/tiff/indeterminate/.gitignore 
b/filter/qa/cppunit/data/tiff/indeterminate/.gitignore
new file mode 100644
index 000..583b009
--- /dev/null
+++ b/filter/qa/cppunit/data/tiff/indeterminate/.gitignore
@@ -0,0 

[Libreoffice-commits] .: Branch 'libreoffice-3-5' - svtools/source

2012-03-14 Thread Caolán McNamara
 svtools/source/edit/texteng.cxx |6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit ecb7bfea45b2385ae7799ecfe7e77d695b57424a
Author: Stephan Bergmann sberg...@redhat.com
Date:   Tue Mar 13 10:33:10 2012 +0100

TextEngine::SeekCursor needs to call SetFont after all

10f28d5c9a072bf108a79f3b05ad8247ca0dcea5 callcatcher: build fixes had 
removed
this with the comment SetFont() doesn't do anything but that is clearly 
wrong:
Without this, e.g. bold text within text fields is not displayed as such 
(e.g.,
File - New - Templates and Documnets - Templates - Presentation 
Backgrounds -
Black and White: the captions in the right hand pane (Title:, Date:, 
etc.)
should be bold).

Signed-off-by: Caolán McNamara caol...@redhat.com

diff --git a/svtools/source/edit/texteng.cxx b/svtools/source/edit/texteng.cxx
index 06062b8..c0a5151 100644
--- a/svtools/source/edit/texteng.cxx
+++ b/svtools/source/edit/texteng.cxx
@@ -1477,7 +1477,11 @@ void TextEngine::SeekCursor( sal_uLong nPara, sal_uInt16 
nPos, Font rFont, Outp
 if ( ( ( pAttrib-GetStart()  nPos )  ( pAttrib-GetEnd() = nPos ) 
)
 || !pNode-GetText().Len() )
 {
-if ( pAttrib-Which() == TEXTATTR_FONTCOLOR )
+if ( pAttrib-Which() != TEXTATTR_FONTCOLOR )
+{
+pAttrib-GetAttr().SetFont(rFont);
+}
+else
 {
 if ( pOutDev )
 pOutDev-SetTextColor( 
((TextAttribFontColor)pAttrib-GetAttr()).GetColor() );
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: 4 commits - oox/inc oox/source unusedcode.easy

2012-03-14 Thread Caolán McNamara
 oox/inc/oox/drawingml/customshapeproperties.hxx |1 -
 oox/inc/oox/drawingml/table/tableproperties.hxx |1 -
 oox/inc/oox/drawingml/theme.hxx |2 --
 oox/source/drawingml/customshapeproperties.cxx  |   10 --
 oox/source/drawingml/diagram/diagram.cxx|3 ---
 oox/source/drawingml/diagram/diagram.hxx|2 --
 oox/source/drawingml/table/tableproperties.cxx  |4 
 oox/source/drawingml/theme.cxx  |5 -
 unusedcode.easy |4 
 9 files changed, 32 deletions(-)

New commits:
commit 02f1aad7003703cf604c5c46da82cf0f46c7f709
Author: Mariana Marasoiu mariana.maras...@gmail.com
Date:   Wed Mar 14 01:34:42 2012 +0200

Remove unused code in drawingml/table.

diff --git a/oox/inc/oox/drawingml/table/tableproperties.hxx 
b/oox/inc/oox/drawingml/table/tableproperties.hxx
index 45246bd..3d783d9 100644
--- a/oox/inc/oox/drawingml/table/tableproperties.hxx
+++ b/oox/inc/oox/drawingml/table/tableproperties.hxx
@@ -61,7 +61,6 @@ public:
 sal_Bool   isBandRow(){ return mbBandRow; };
 sal_Bool   isBandCol(){ return mbBandCol; };
 
-void apply( const TablePropertiesPtr );
 void pushToPropSet( const ::oox::core::XmlFilterBase rFilterBase,
 const ::com::sun::star::uno::Reference  
::com::sun::star::beans::XPropertySet   xPropSet, 
::oox::drawingml::TextListStylePtr pMasterTextListStyle );
 
diff --git a/oox/source/drawingml/table/tableproperties.cxx 
b/oox/source/drawingml/table/tableproperties.cxx
index 7fbd4bd..97ed6e7 100644
--- a/oox/source/drawingml/table/tableproperties.cxx
+++ b/oox/source/drawingml/table/tableproperties.cxx
@@ -61,10 +61,6 @@ TableProperties::~TableProperties()
 {
 }
 
-void TableProperties::apply( const TablePropertiesPtr /* 
rSourceTableProperties */ )
-{
-}
-
 void CreateTableRows( uno::Reference XTableRows  xTableRows, const 
std::vector TableRow  rvTableRows )
 {
 if ( rvTableRows.size()  1 )
diff --git a/unusedcode.easy b/unusedcode.easy
index 11e3bac..5e63e06 100755
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -907,7 +907,6 @@ 
oox::drawingml::lcl_SequenceHasUnhiddenData(com::sun::star::uno::Referencecom::
 
oox::drawingml::lcl_dump_pset(com::sun::star::uno::Referencecom::sun::star::beans::XPropertySet)
 
oox::drawingml::lcl_getSequenceLengthByRole(com::sun::star::uno::Sequencecom::sun::star::uno::Referencecom::sun::star::chart2::data::XLabeledDataSequence
  const, rtl::OUString const)
 
oox::drawingml::lcl_getValueFromSequence(com::sun::star::uno::Referencecom::sun::star::chart2::data::XDataSequence
 const, int)
-oox::drawingml::table::TableProperties::apply(boost::shared_ptroox::drawingml::table::TableProperties
 const)
 oox::dump::AxPropertyObjectBase::construct(oox::dump::OutputObjectBase const, 
oox::dump::BinaryInputStreamRef const, oox::dump::String const, bool)
 oox::dump::BinaryStreamObject::BinaryStreamObject(oox::dump::OutputObjectBase 
const, oox::dump::BinaryInputStreamRef const)
 oox::dump::Config::setNameList(oox::dump::String const, 
boost::shared_ptroox::dump::NameListBase const)
commit 238944f008610d7faeab473c9b26ad04fc024429
Author: Mariana Marasoiu mariana.maras...@gmail.com
Date:   Wed Mar 14 01:25:57 2012 +0200

Remove unused code in drawingml/theme.

diff --git a/oox/inc/oox/drawingml/theme.hxx b/oox/inc/oox/drawingml/theme.hxx
index d6dbb2c..b2a039d 100644
--- a/oox/inc/oox/drawingml/theme.hxx
+++ b/oox/inc/oox/drawingml/theme.hxx
@@ -76,8 +76,6 @@ public:
 
 inline EffectStyleList getEffectStyleList() { return 
maEffectStyleList; }
 inline const EffectStyleList   getEffectStyleList() const { return 
maEffectStyleList; }
-/** Returns the effect properties of the passed one-based themed style 
index. */
-const PropertyMap*  getEffectStyle( sal_Int32 nIndex ) const;
 
 inline FontScheme  getFontScheme() { return maFontScheme; }
 inline const FontSchemegetFontScheme() const { return 
maFontScheme; }
diff --git a/oox/source/drawingml/theme.cxx b/oox/source/drawingml/theme.cxx
index 47a7d30..46f3dbc 100644
--- a/oox/source/drawingml/theme.cxx
+++ b/oox/source/drawingml/theme.cxx
@@ -66,11 +66,6 @@ const LineProperties* Theme::getLineStyle( sal_Int32 nIndex 
) const
  return lclGetStyleElement( maLineStyleList, nIndex );
 }
 
-const PropertyMap* Theme::getEffectStyle( sal_Int32 nIndex ) const
-{
-return lclGetStyleElement( maEffectStyleList, nIndex );
-}
-
 const TextCharacterProperties* Theme::getFontStyle( sal_Int32 nSchemeType ) 
const
 {
 return maFontScheme.get( nSchemeType ).get();
diff --git a/unusedcode.easy b/unusedcode.easy
index 97d0fb5..11e3bac 100755
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -901,7 +901,6 @@ oox::drawingml::ColorPropertySet::setColor(int)
 
oox::drawingml::GraphicProperties::assignUsed(oox::drawingml::GraphicProperties 
const)
 

[Libreoffice-commits] .: sw/source

2012-03-14 Thread Philipp Weissenbacher
 sw/source/core/text/txtfly.cxx |  320 +++--
 1 file changed, 156 insertions(+), 164 deletions(-)

New commits:
commit 7caa7ae8947f20413f06291779aac021128cb126
Author: Philipp Weissenbacher p.weissenbac...@gmail.com
Date:   Wed Mar 14 18:55:03 2012 +0100

Translate German comments

diff --git a/sw/source/core/text/txtfly.cxx b/sw/source/core/text/txtfly.cxx
index a3b4630..7336d13 100644
--- a/sw/source/core/text/txtfly.cxx
+++ b/sw/source/core/text/txtfly.cxx
@@ -38,19 +38,19 @@
 #include swregion.hxx // SwRegionRects
 #include dcontact.hxx // SwContact
 #include dflyobj.hxx  // SdrObject
-#include flyfrm.hxx // SwFlyFrm
-#include frmtool.hxx// ::DrawGraphic
+#include flyfrm.hxx   // SwFlyFrm
+#include frmtool.hxx  // ::DrawGraphic
 #include porfld.hxx   // SwGrfNumPortion
-#include txtfrm.hxx // SwTxtFrm
-#include itrform2.hxx   // SwTxtFormatter
-#include porfly.hxx // NewFlyCntPortion
-#include porfld.hxx // SwGrfNumPortion
-#include txtfly.hxx // SwTxtFly
-#include txtpaint.hxx   // SwSaveClip
-#include txtatr.hxx // SwTxtFlyCnt
+#include txtfrm.hxx   // SwTxtFrm
+#include itrform2.hxx // SwTxtFormatter
+#include porfly.hxx   // NewFlyCntPortion
+#include porfld.hxx   // SwGrfNumPortion
+#include txtfly.hxx   // SwTxtFly
+#include txtpaint.hxx // SwSaveClip
+#include txtatr.hxx   // SwTxtFlyCnt
 #include notxtfrm.hxx
 #include flyfrms.hxx
-#include fmtcnct.hxx  // SwFmtChain
+#include fmtcnct.hxx  // SwFmtChain
 #include pormulti.hxx // SwMultiPortion
 #include svx/obj3d.hxx
 #include editeng/txtrange.hxx
@@ -74,7 +74,7 @@
 #include doc.hxx
 
 #ifdef DBG_UTIL
-#include viewopt.hxx  // SwViewOptions, nur zum Testen (Test2)
+#include viewopt.hxx  // SwViewOptions, only for testing (Test2)
 #include doc.hxx
 #endif
 
@@ -82,37 +82,34 @@
 using namespace ::com::sun::star;
 
 /*
- * Beschreibung:
- * Die Klasse SwTxtFly soll die Universalschnittstelle zwischen der
- * Formatierung/Textausgabe und den u.U. ueberlappenden freifliegenden
- * Frames sein.
- * Waehrend der Formatierung erkundigt sich der Formatierer beim SwTxtFly,
- * ob ein bestimmter Bereich durch die Attribute eines ueberlappenden
- * Frames vorliegt. Solche Bereiche werden in Form von Dummy-Portions
- * abgebildet.
- * Die gesamte Textausgabe und Retusche wird ebenfalls an ein SwTxtFly
- * weitergeleitet. Dieser entscheidet, ob Textteile geclippt werden muessen
- * und zerteilt z.B. die Bereiche bei einem DrawRect.
- * Zu beachten ist, dass alle freifliegenden Frames in einem nach TopLeft
- * sortiertem PtrArray an der Seite zu finden sind. Intern wird immer nur
- * in dokumentglobalen Werten gerechnet. Die IN- und OUT-Parameter sind
- * jedoch in den meisten Faellen an die Beduerfnisse des LineIters
- * zugeschnitten, d.h. sie werden in frame- oder windowlokalen Koordinaten
- * konvertiert.
- * Wenn mehrere Frames mit Umlaufattributen in einer Zeile liegen,
- * ergeben sich unterschiedliche Auswirkungen fuer den Textfluss:
+ * Description:
+ * SwTxtFly's purpose is to be the universal interface between
+ * formatting/text output and the possibly overlapping free-flying frames.
+ * During formatting the formatter gets the information from SwTxtFly, whether
+ * a certain area is present by the attributes of an overlapping frame.
+ * Such areas are represented by dummy portions.
+ * The whole text output and touch-up is, again, forwarded to a SwTxtFly.
+ * This one decides, whether parts of the text need to be clipped and splits
+ * the areas for e.g. a DrawRect.
+ * Please note that all free-flying frames are located in a PtrArray, sorted
+ * by TopLeft.
+ * Internally we always use document-global values. The IN and OUT parameters
+ * are, however, adjusted to the needs of the LineIter most of the time. That
+ * is: they are converted to frame- and window-local coordinates.
+ * If multiple frames with wrap attributes are located on the same line, we get
+ * the following settings for the text flow:
  *
- *  L/RP L R K
- *   P   -P-P- -P-L  -P R- -P K
- *   L   -L P- -L L  -L R- -L K
- *   RR-P-  R-L   R R-  R K
- *   KK P-  K L   K R-  K K
+ *  L/RP L R N
+ *   P   -P-P- -P-L  -P R- -P N
+ *   L   -L P- -L L  -L R- -L N
+ *   RR-P-  R-L   R R-  R N
+ *   NN P-  N L   N R-  N N
  *
- * (P=parallel, L=links, R=rechts, K=kein Umlauf)
+ * (P=parallel, L=left, R=right, N=no wrap)
  *
- * Das Verhalten so beschreiben:
- * Jeder Rahmen kann Text verdraengen, wobei der Einfluss allerdings nur
- * bis zum naechsten Rahmen reicht.
+ * We can describe the behaviour as follows:
+ * Every frame can push away text, with the restriction that it only has 
influence
+ * until the next frame.
  */

[Libreoffice-commits] .: svtools/source

2012-03-14 Thread Stephan Bergmann
 svtools/source/contnr/DocumentInfoPreview.cxx |   18 --
 svtools/source/contnr/fileview.cxx|   18 +++---
 svtools/source/contnr/templwin.cxx|   10 +-
 svtools/source/contnr/templwin.src|1 -
 4 files changed, 20 insertions(+), 27 deletions(-)

New commits:
commit 3d69d78bed225039741213f1d6bb435468f3a818
Author: Stephan Bergmann sberg...@redhat.com
Date:   Wed Mar 14 19:45:08 2012 +0100

Some visual clean up

diff --git a/svtools/source/contnr/DocumentInfoPreview.cxx 
b/svtools/source/contnr/DocumentInfoPreview.cxx
index 805ed0a..b27df17 100644
--- a/svtools/source/contnr/DocumentInfoPreview.cxx
+++ b/svtools/source/contnr/DocumentInfoPreview.cxx
@@ -138,17 +138,15 @@ void ODocumentInfoPreview::fill(
 void ODocumentInfoPreview::insertEntry(
 rtl::OUString const  title, rtl::OUString const  value)
 {
-rtl::OUString p1(rtl::OUString(\n) + title + rtl::OUString(:));
-m_pEditWin.InsertText(p1);
-m_pEditWin.SetAttrib(
-TextAttribFontWeight(WEIGHT_BOLD), m_pEditWin.GetParagraphCount() - 1,
-0, p1.getLength());
-rtl::OUString p2(rtl::OUString(\n) + value);
-m_pEditWin.InsertText(p2);
+if (m_pEditWin.GetText().Len() != 0) {
+m_pEditWin.InsertText(rtl::OUString(\n\n));
+}
+rtl::OUString caption(title + rtl::OUString(:\n));
+m_pEditWin.InsertText(caption);
 m_pEditWin.SetAttrib(
-TextAttribFontWeight(WEIGHT_NORMAL),
-m_pEditWin.GetParagraphCount() - 1, 0, p2.getLength());
-m_pEditWin.InsertText(rtl::OUString(\n));
+TextAttribFontWeight(WEIGHT_BOLD), m_pEditWin.GetParagraphCount() - 2,
+0, caption.getLength() - 1);
+m_pEditWin.InsertText(value);
 }
 
 void ODocumentInfoPreview::insertNonempty(long id, rtl::OUString const  value)
diff --git a/svtools/source/contnr/fileview.cxx 
b/svtools/source/contnr/fileview.cxx
index b686831..de0c2af 100644
--- a/svtools/source/contnr/fileview.cxx
+++ b/svtools/source/contnr/fileview.cxx
@@ -187,6 +187,7 @@ private:
 sal_BoolmbAutoResize: 1;
 sal_BoolmbEnableDelete  : 1;
 sal_BoolmbEnableRename  : 1;
+boolmbShowHeader;
 
 voidDeleteEntries();
 voidDoQuickSearch( const xub_Unicode rChar );
@@ -722,10 +723,9 @@ ViewTabListBox_Impl::ViewTabListBox_Impl( Window* 
pParentWin,
 mbResizeDisabled( sal_False ),
 mbAutoResize( sal_False ),
 mbEnableDelete  ( sal_True ),
-mbEnableRename  ( sal_True )
-
+mbEnableRename  ( sal_True ),
+mbShowHeader( (nFlags  FILEVIEW_SHOW_NONE) == 0 )
 {
-const bool bViewHeader = (nFlags  FILEVIEW_SHOW_NONE) == 0;
 Size aBoxSize = pParentWin-GetSizePixel();
 mpHeaderBar = new HeaderBar( pParentWin, WB_BUTTONSTYLE | WB_BOTTOMBORDER 
);
 mpHeaderBar-SetPosSizePixel( Point( 0, 0 ), 
mpHeaderBar-CalcWindowSizePixel() );
@@ -760,7 +760,7 @@ ViewTabListBox_Impl::ViewTabListBox_Impl( Window* 
pParentWin,
 SetSelectionMode( MULTIPLE_SELECTION );
 
 Show();
-if( bViewHeader )
+if( mbShowHeader )
 mpHeaderBar-Show();
 
 maResetQuickSearch.SetTimeout( QUICK_SEARCH_TIMEOUT );
@@ -806,9 +806,13 @@ void ViewTabListBox_Impl::Resize()
 if ( mbResizeDisabled || !aBoxSize.Width() )
 return;
 
-Size aBarSize = mpHeaderBar-GetSizePixel();
-aBarSize.Width() = mbAutoResize ? aBoxSize.Width() : 
GetSizePixel().Width();
-mpHeaderBar-SetSizePixel( aBarSize );
+Size aBarSize;
+if ( mbShowHeader )
+{
+aBarSize = mpHeaderBar-GetSizePixel();
+aBarSize.Width() = mbAutoResize ? aBoxSize.Width() : 
GetSizePixel().Width();
+mpHeaderBar-SetSizePixel( aBarSize );
+}
 
 if ( mbAutoResize )
 {
diff --git a/svtools/source/contnr/templwin.cxx 
b/svtools/source/contnr/templwin.cxx
index 3bdb0f7..a2a8315 100644
--- a/svtools/source/contnr/templwin.cxx
+++ b/svtools/source/contnr/templwin.cxx
@@ -427,7 +427,6 @@ SvtFileViewWindow_Impl::SvtFileViewWindow_Impl( 
SvtTemplateWindow* pParent ) :
 aFileView.SetStyle( aFileView.GetStyle() | WB_DIALOGCONTROL | WB_TABSTOP );
 aFileView.SetHelpId( HID_TEMPLATEDLG_FILEVIEW );
 aFileView.Show();
-aFileView.SetPosPixel( Point( 0, 0 ) );
 aFileView.EnableAutoResize();
 aFileView.EnableContextMenu( sal_False );
 aFileView.EnableDelete( sal_False );
@@ -528,14 +527,7 @@ Sequence ::rtl::OUString  
SvtFileViewWindow_Impl::GetNewDocContents() const
 
 void SvtFileViewWindow_Impl::Resize()
 {
-Size aWinSize = GetOutputSizePixel();
-
-static int  x = 0;
-static int  y = 0;
-
-aWinSize.nA += x;
-aWinSize.nB += y;
-aFileView.SetSizePixel( aWinSize );
+aFileView.SetSizePixel(GetOutputSizePixel());
 }
 
 String SvtFileViewWindow_Impl::GetSelectedFile() const
diff --git a/svtools/source/contnr/templwin.src 

[Libreoffice-commits] .: 2 commits - Repository.mk canvas/Library_directx9canvas.mk canvas/Library_gdipluscanvas.mk canvas/Module_canvas.mk canvas/StaticLibrary_directxcanvas.mk ucb/Library_ucpodma1.m

2012-03-14 Thread Michael Stahl
 Repository.mk |1 
 canvas/Library_directx9canvas.mk  |   19 ++
 canvas/Library_gdipluscanvas.mk   |   19 ++
 canvas/Module_canvas.mk   |1 
 canvas/StaticLibrary_directxcanvas.mk |   62 ++
 ucb/Library_ucpodma1.mk   |5 ++
 6 files changed, 76 insertions(+), 31 deletions(-)

New commits:
commit a13a88bd2c673d059b60e339dcf3b8fabf991f18
Author: Michael Stahl mst...@redhat.com
Date:   Wed Mar 14 21:08:03 2012 +0100

fdo#47246: canvas: split out static library directxcanvas

diff --git a/Repository.mk b/Repository.mk
index 147eca9..6f1b12c 100644
--- a/Repository.mk
+++ b/Repository.mk
@@ -84,6 +84,7 @@ $(eval $(call gb_Helper_register_executables,OOO,\
 ))
 
 $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \
+   directxcanvas \
winextendloaderenv \
winlauncher \
 ))
diff --git a/canvas/Library_directx9canvas.mk b/canvas/Library_directx9canvas.mk
index 070df09..0b1da59 100644
--- a/canvas/Library_directx9canvas.mk
+++ b/canvas/Library_directx9canvas.mk
@@ -61,37 +61,26 @@ $(eval $(call gb_Library_add_linked_libs,directx9canvas,\
 $(gb_STDLIBS) \
 ))
 
-ifeq ($(OS),WNT)
 $(eval $(call gb_Library_add_linked_libs,directx9canvas,\
d3d9 \
gdi32 \
gdiplus \
 ))
-endif
+
+$(eval $(call gb_Library_add_linked_static_libs,directx9canvas,\
+   directxcanvas \
+))
 
 $(eval $(call gb_Library_add_exception_objects,directx9canvas,\
canvas/source/directx/dx_9rm \
-   canvas/source/directx/dx_bitmap \
-   canvas/source/directx/dx_bitmapcanvashelper \
-   canvas/source/directx/dx_canvasbitmap \
canvas/source/directx/dx_canvascustomsprite \
-   canvas/source/directx/dx_canvasfont \
-   canvas/source/directx/dx_canvashelper \
-   canvas/source/directx/dx_canvashelper_texturefill \
canvas/source/directx/dx_config \
-   canvas/source/directx/dx_devicehelper \
-   canvas/source/directx/dx_gdiplususer \
-   canvas/source/directx/dx_impltools \
-   canvas/source/directx/dx_linepolypolygon \
canvas/source/directx/dx_spritecanvas \
canvas/source/directx/dx_spritecanvashelper \
canvas/source/directx/dx_spritedevicehelper \
canvas/source/directx/dx_spritehelper \
canvas/source/directx/dx_surfacebitmap \
canvas/source/directx/dx_surfacegraphics \
-   canvas/source/directx/dx_textlayout \
-   canvas/source/directx/dx_textlayout_drawhelper \
-   canvas/source/directx/dx_vcltools \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/canvas/Library_gdipluscanvas.mk b/canvas/Library_gdipluscanvas.mk
index 7531d75..3be70e5 100644
--- a/canvas/Library_gdipluscanvas.mk
+++ b/canvas/Library_gdipluscanvas.mk
@@ -67,28 +67,17 @@ $(eval $(call gb_Library_add_linked_libs,gdipluscanvas,\
 $(gb_STDLIBS) \
 ))
 
-ifeq ($(OS),WNT)
 $(eval $(call gb_Library_add_linked_libs,gdipluscanvas,\
gdi32 \
gdiplus \
 ))
-endif
+
+$(eval $(call gb_Library_add_linked_static_libs,gdipluscanvas,\
+   directxcanvas \
+))
 
 $(eval $(call gb_Library_add_exception_objects,gdipluscanvas,\
-   canvas/source/directx/dx_bitmap \
-   canvas/source/directx/dx_bitmapcanvashelper \
canvas/source/directx/dx_canvas \
-   canvas/source/directx/dx_canvasbitmap \
-   canvas/source/directx/dx_canvasfont \
-   canvas/source/directx/dx_canvashelper \
-   canvas/source/directx/dx_canvashelper_texturefill \
-   canvas/source/directx/dx_devicehelper \
-   canvas/source/directx/dx_gdiplususer \
-   canvas/source/directx/dx_impltools \
-   canvas/source/directx/dx_linepolypolygon \
-   canvas/source/directx/dx_textlayout \
-   canvas/source/directx/dx_textlayout_drawhelper \
-   canvas/source/directx/dx_vcltools \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/canvas/Module_canvas.mk b/canvas/Module_canvas.mk
index 8595611..e7aad78 100644
--- a/canvas/Module_canvas.mk
+++ b/canvas/Module_canvas.mk
@@ -49,6 +49,7 @@ ifneq ($(strip $(ENABLE_DIRECTX)),)
 $(eval $(call gb_Module_add_targets,canvas,\
Library_directx9canvas \
Library_gdipluscanvas \
+   StaticLibrary_directxcanvas \
 ))
 
 endif
diff --git a/canvas/StaticLibrary_directxcanvas.mk 
b/canvas/StaticLibrary_directxcanvas.mk
new file mode 100644
index 000..cd74a2c
--- /dev/null
+++ b/canvas/StaticLibrary_directxcanvas.mk
@@ -0,0 +1,62 @@
+# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*-
+#
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the License); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an AS IS basis,
+# WITHOUT WARRANTY OF ANY KIND, either 

[Libreoffice-commits] .: binfilter/inc

2012-03-14 Thread Stephan Bergmann
 binfilter/inc/bf_svtools/fileview.hxx |  265 --
 1 file changed, 265 deletions(-)

New commits:
commit 55ee10fea8ecfe0d471674d5fc7f09be2808b3df
Author: Stephan Bergmann sberg...@redhat.com
Date:   Wed Mar 14 22:14:18 2012 +0100

Dead code

diff --git a/binfilter/inc/bf_svtools/fileview.hxx 
b/binfilter/inc/bf_svtools/fileview.hxx
deleted file mode 100644
index aa46281..000
--- a/binfilter/inc/bf_svtools/fileview.hxx
+++ /dev/null
@@ -1,265 +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 _SVT_FILEVIEW_HXX
-#define _SVT_FILEVIEW_HXX
-
-#include bf_svtools/svtdllapi.h
-
-#include com/sun/star/uno/Sequence.h
-#include com/sun/star/ucb/XContent.hpp
-
-#include vcl/ctrl.hxx
-#include vcl/image.hxx
-#include vcl/fixed.hxx
-#include vcl/button.hxx
-#include vcl/dialog.hxx
-
-namespace binfilter
-{
-
-// class SvtFileView -
-
-#define FILEVIEW_ONLYFOLDER 0x0001
-#define FILEVIEW_MULTISELECTION 0x0002
-
-#define FILEVIEW_SHOW_TITLE 0x0010
-#define FILEVIEW_SHOW_SIZE  0x0020
-#define FILEVIEW_SHOW_DATE  0x0040
-#define FILEVIEW_SHOW_ALL   0x0070
-
-class ViewTabListBox_Impl;
-class SvtFileView_Impl;
-class SvLBoxEntry;
-class HeaderBar;
-class IUrlFilter;
-
-/// the result of an action in the FileView
-enum FileViewResult
-{
-eSuccess,
-eFailure,
-eTimeout,
-eStillRunning
-};
-
-/// describes parameters for doing an action on the FileView asynchronously
-struct FileViewAsyncAction
-{
-sal_uInt32  nMinTimeout;/// minimum time to wait for a result, in 
milliseconds
-sal_uInt32  nMaxTimeout;/// maximum time to wait for a result, in 
milliseconds, until eTimeout is returned
-LinkaFinishHandler; /// the handler to be called when the action 
is finished. Called in every case, no matter of the result
-
-FileViewAsyncAction()
-{
-nMinTimeout = nMaxTimeout = 0;
-}
-};
-
-class  SvtFileView : public Control
-{
-private:
-SvtFileView_Impl*   mpImp;
-
-voidOpenFolder( const ::com::sun::star::uno::Sequence 
::rtl::OUString  aContents );
-
-DECL_LINK(  HeaderSelect_Impl, HeaderBar * );
-DECL_LINK(  HeaderEndDrag_Impl, HeaderBar * );
-
-protected:
-virtual void GetFocus();
-
-public:
-SvtFileView( Window* pParent, const ResId rResId, sal_Bool bOnlyFolder, 
sal_Bool bMultiSelection );
-SvtFileView( Window* pParent, const ResId rResId, sal_Int8 nFlags );
-~SvtFileView();
-
-const String   GetViewURL() const;
-String  GetURL( SvLBoxEntry* pEntry ) const;
-String  GetCurrentURL() const;
-
-sal_BoolGetParentURL( String _rParentURL ) const;
-sal_BoolCreateNewFolder( const String rNewFolder );
-
-voidSetHelpId( sal_uInt32 nHelpId );
-sal_uInt32  GetHelpId( ) const;
-voidSetSizePixel( const Size rNewSize );
-using Window::SetPosSizePixel;
-virtual voidSetPosSizePixel( const Point rNewPos, const Size 
rNewSize );
-
-/** initialize the view with the content of a folder given by URL, and 
aply an immediate filter
-
-@param rFolderURL
-the URL of the folder whose content is to be read
-@param rFilter
-the initial filter to be applied
-@param pAsyncDescriptor
-If not NULL/, this struct describes the parameters for doing the
-action asynchronously.
-*/
-FileViewResult  Initialize(
-const String rFolderURL,
-const String rFilter,
-

[Libreoffice-commits] .: vcl/generic vcl/headless vcl/inc

2012-03-14 Thread Michael Meeks
 vcl/generic/print/common_gfx.cxx |3 -
 vcl/generic/print/genprnpsp.cxx  |   36 ---
 vcl/generic/print/printerjob.cxx |   89 ---
 vcl/generic/print/text_gfx.cxx   |   42 --
 vcl/headless/svpprn.cxx  |   11 
 vcl/inc/generic/printergfx.hxx   |3 -
 6 files changed, 2 insertions(+), 182 deletions(-)

New commits:
commit 230854bad461dbfa2aa72269c2468ff380b789a8
Author: Christina Rossmanith chrrossman...@web.de
Date:   Mon Mar 5 14:57:30 2012 +0100

Remove SO52 strict compatibility stuff

diff --git a/vcl/generic/print/common_gfx.cxx b/vcl/generic/print/common_gfx.cxx
index 941a5cc..44bf1a7 100644
--- a/vcl/generic/print/common_gfx.cxx
+++ b/vcl/generic/print/common_gfx.cxx
@@ -129,8 +129,7 @@ PrinterGfx::PrinterGfx() :
 maFillColor (0xff,0,0),
 maTextColor (0,0,0),
 maLineColor (0, 0xff, 0),
-mpFontSubstitutes( NULL ),
-mbStrictSO52Compatibility( false )
+mpFontSubstitutes( NULL )
 {
 maVirtualStatus.mfLineWidth = 1.0;
 maVirtualStatus.mnTextHeight = 12;
diff --git a/vcl/generic/print/genprnpsp.cxx b/vcl/generic/print/genprnpsp.cxx
index 54cb87c..6525f96 100644
--- a/vcl/generic/print/genprnpsp.cxx
+++ b/vcl/generic/print/genprnpsp.cxx
@@ -413,18 +413,6 @@ void 
SalGenericInstance::configurePspInfoPrinter(PspSalInfoPrinter *pPrinter,
 pJobSetup-maPrinterName= pQueueInfo-maPrinterName;
 pJobSetup-maDriver = aInfo.m_aDriverName;
 copyJobDataToJobSetup( pJobSetup, aInfo );
-
-// set/clear backwards compatibility flag
-bool bStrictSO52Compatibility = false;
-boost::unordered_maprtl::OUString, rtl::OUString, rtl::OUStringHash 
::const_iterator compat_it =
-pJobSetup-maValueMap.find( rtl::OUString( 
RTL_CONSTASCII_USTRINGPARAM( StrictSO52Compatibility ) ) );
-
-if( compat_it != pJobSetup-maValueMap.end() )
-{
-if( 
compat_it-second.equalsIgnoreAsciiCaseAsciiL(RTL_CONSTASCII_STRINGPARAM(true))
 )
-bStrictSO52Compatibility = true;
-}
-pPrinter-m_aPrinterGfx.setStrictSO52Compatibility( 
bStrictSO52Compatibility );
 }
 }
 
@@ -627,18 +615,6 @@ sal_Bool PspSalInfoPrinter::Setup( SalFrame* pFrame, 
ImplJobSetup* pJobSetup )
 // should be merged into the independent data
 sal_Bool PspSalInfoPrinter::SetPrinterData( ImplJobSetup* pJobSetup )
 {
-// set/clear backwards compatibility flag
-bool bStrictSO52Compatibility = false;
-boost::unordered_maprtl::OUString, rtl::OUString, rtl::OUStringHash 
::const_iterator compat_it =
-pJobSetup-maValueMap.find( rtl::OUString( 
RTL_CONSTASCII_USTRINGPARAM( StrictSO52Compatibility ) ) );
-
-if( compat_it != pJobSetup-maValueMap.end() )
-{
-if( 
compat_it-second.equalsIgnoreAsciiCaseAsciiL(RTL_CONSTASCII_STRINGPARAM(true))
 )
-bStrictSO52Compatibility = true;
-}
-m_aPrinterGfx.setStrictSO52Compatibility( bStrictSO52Compatibility );
-
 if( pJobSetup-mpDriverData )
 return SetData( ~0, pJobSetup );
 
@@ -991,18 +967,6 @@ sal_Bool PspSalPrinter::StartJob(
 #endif
 m_aPrinterGfx.Init( m_aJobData );
 
-// set/clear backwards compatibility flag
-bool bStrictSO52Compatibility = false;
-boost::unordered_maprtl::OUString, rtl::OUString, rtl::OUStringHash 
::const_iterator compat_it =
-pJobSetup-maValueMap.find( rtl::OUString( 
RTL_CONSTASCII_USTRINGPARAM( StrictSO52Compatibility ) ) );
-
-if( compat_it != pJobSetup-maValueMap.end() )
-{
-if( 
compat_it-second.equalsIgnoreAsciiCaseAsciiL(RTL_CONSTASCII_STRINGPARAM(true))
 )
-bStrictSO52Compatibility = true;
-}
-m_aPrinterGfx.setStrictSO52Compatibility( bStrictSO52Compatibility );
-
 return m_aPrintJob.StartJob( ! m_aTmpFile.isEmpty() ? m_aTmpFile : 
m_aFileName, nMode, rJobName, rAppName, m_aJobData, m_aPrinterGfx, bDirect ) ? 
sal_True : sal_False;
 }
 
diff --git a/vcl/generic/print/printerjob.cxx b/vcl/generic/print/printerjob.cxx
index 503d7af..4cf9efc 100644
--- a/vcl/generic/print/printerjob.cxx
+++ b/vcl/generic/print/printerjob.cxx
@@ -977,94 +977,7 @@ bool PrinterJob::writeProlog (osl::File* pFile, const 
JobData rJobData )
 %%EndResource\n
 %%EndProlog\n
 };
-static const sal_Char pSO52CompatProlog[] = {
-%%BeginResource: procset PSPrint-Prolog 1.0 0\n
-/ISO1252Encoding [\n
-/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef 
/.notdef\n
-/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef 
/.notdef\n
-/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef 
/.notdef\n
-/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef 
/.notdef\n
-/space /exclam /quotedbl /numbersign /dollar /percent /ampersand 
/quoteright\n
-/parenleft /parenright /asterisk /plus /comma /minus /period /slash\n
-/zero /one /two 

[Libreoffice-commits] .: 2 commits - solenv/bin

2012-03-14 Thread Tim Retout
 solenv/bin/modules/installer/helppack.pm |5 +-
 solenv/bin/modules/installer/packagelist.pm  |2 
 solenv/bin/modules/t/installer-packagelist.t |   57 +++
 3 files changed, 62 insertions(+), 2 deletions(-)

New commits:
commit d3374e77c3df1f928fe90c4c3803938f08a250b2
Author: Tim Retout tim.ret...@smoothwall.net
Date:   Wed Mar 14 22:17:27 2012 +

Turn on strictures and warnings in installer::helppack.

diff --git a/solenv/bin/modules/installer/helppack.pm 
b/solenv/bin/modules/installer/helppack.pm
index 977b0ba..a6a9627 100644
--- a/solenv/bin/modules/installer/helppack.pm
+++ b/solenv/bin/modules/installer/helppack.pm
@@ -27,6 +27,9 @@
 
 package installer::helppack;
 
+use strict;
+use warnings;
+
 use installer::converter;
 use installer::files;
 use installer::globals;
@@ -136,7 +139,7 @@ sub create_tar_gz_file
 
 $packagename =~ s/\.rpm\s*$//;
 my $targzname = $packagename . .tar.gz;
-$systemcall = cd $installdir; tar -cf - $packagestring | gzip  
$targzname;
+my $systemcall = cd $installdir; tar -cf - $packagestring | gzip  
$targzname;
 installer::logger::print_message( ... $systemcall ...\n );
 
 my $returnvalue = system($systemcall);
commit 712e7b813825ec9fb1d0c1fcdbfcea2f44274e69
Author: Tim Retout t...@retout.co.uk
Date:   Thu Feb 23 20:11:50 2012 +

Unit test and correction for remove_multiple_modules_packages

diff --git a/solenv/bin/modules/installer/packagelist.pm 
b/solenv/bin/modules/installer/packagelist.pm
index d6b2f02..e39917c 100644
--- a/solenv/bin/modules/installer/packagelist.pm
+++ b/solenv/bin/modules/installer/packagelist.pm
@@ -214,7 +214,7 @@ sub remove_multiple_modules_packages
 # modules will only be removed from packages, that have more 
modules
 # than the compare package
 
-if ( $packagecount = $comparepackagecount ) { next; }  # 
nothing to do, take next package
+if ( $packagecount  $comparepackagecount ) { next; }  # 
nothing to do, take next package
 
 # iterating over all modules of this package
 
diff --git a/solenv/bin/modules/t/installer-packagelist.t 
b/solenv/bin/modules/t/installer-packagelist.t
new file mode 100644
index 000..b4ef6ce
--- /dev/null
+++ b/solenv/bin/modules/t/installer-packagelist.t
@@ -0,0 +1,57 @@
+# 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) 2012 Tim Retout t...@retout.co.uk (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.
+
+use strict;
+use warnings;
+
+use lib '.';
+
+use Test::More;
+
+BEGIN {
+use_ok('installer::packagelist');
+}
+
+my @packagemodules = (
+{ allmodules = [qw(a b c d)] },
+{ allmodules = [qw(a b c)] },
+{ allmodules = [qw(e f g)] },
+{ allmodules = [qw(h)] },
+{ allmodules = [qw(a b g)] },
+);
+
+my @expected_packagemodules = (
+{ allmodules = [qw(d)] },
+{ allmodules = [qw(c)] },
+{ allmodules = [qw(e f)] },
+{ allmodules = [qw(h)] },
+{ allmodules = [qw(a b g)] },
+);
+
+installer::packagelist::remove_multiple_modules_packages(\@packagemodules);
+
+is_deeply(\@packagemodules, \@expected_packagemodules);
+
+done_testing();
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: solenv/bin

2012-03-14 Thread Tim Retout
 solenv/bin/modules/installer/strip.pm |6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 36c2658145c84a41a1a30e940b6b7bb7550354a5
Author: Tim Retout tim.ret...@smoothwall.net
Date:   Wed Mar 14 22:26:28 2012 +

Turn on strict and warnings for install::strip.

diff --git a/solenv/bin/modules/installer/strip.pm 
b/solenv/bin/modules/installer/strip.pm
index 154f39b..7f0a39a 100644
--- a/solenv/bin/modules/installer/strip.pm
+++ b/solenv/bin/modules/installer/strip.pm
@@ -27,7 +27,9 @@
 
 package installer::strip;
 
-use installer::converter;
+use strict;
+use warnings;
+
 use installer::globals;
 use installer::logger;
 use installer::pathanalyzer;
@@ -107,7 +109,7 @@ sub strip_libraries
 my $shortfilename = $sourcefilename;
 
installer::pathanalyzer::make_absolute_filename_to_relative_filename(\$shortfilename);
 
-$infoline = Strip: $shortfilename\n;
+my $infoline = Strip: $shortfilename\n;
 push( @installer::globals::logfileinfo, $infoline);
 
 # copy file into directory for stripped libraries
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2012-03-14 Thread Kohei Yoshida
 sc/inc/dapiuno.hxx  |1 +
 sc/source/ui/unoobj/dapiuno.cxx |   24 ++--
 2 files changed, 15 insertions(+), 10 deletions(-)

New commits:
commit f697d7aa5c26f9fcfd717b76a4827a5bcb38325e
Author: Kohei Yoshida kohei.yosh...@gmail.com
Date:   Wed Mar 14 20:40:38 2012 -0400

Fix the UNO API for creating a new group dimension.

diff --git a/sc/inc/dapiuno.hxx b/sc/inc/dapiuno.hxx
index fd3ec8d..98bdca0 100644
--- a/sc/inc/dapiuno.hxx
+++ b/sc/inc/dapiuno.hxx
@@ -422,6 +422,7 @@ protected:
 ::com::sun::star::uno::Reference ::com::sun::star::container::XNameAccess 

 GetMembers() const;
 
+ScDocShell* GetDocShell() const;
 protected:
 ScDataPilotDescriptorBase mrParent;
 ScFieldIdentifier   maFieldId;
diff --git a/sc/source/ui/unoobj/dapiuno.cxx b/sc/source/ui/unoobj/dapiuno.cxx
index d1d7d96..45a88e7 100644
--- a/sc/source/ui/unoobj/dapiuno.cxx
+++ b/sc/source/ui/unoobj/dapiuno.cxx
@@ -1193,7 +1193,7 @@ void ScDataPilotTableObj::SetDPObject( ScDPObject* 
pDPObject )
 if ( pDPObj  pDocSh )
 {
 ScDBDocFunc aFunc(*pDocSh);
-aFunc.DataPilotUpdate( pDPObj, pDPObject, sal_True, sal_True );
+aFunc.DataPilotUpdate( pDPObj, pDPObject, true, true );
 }
 }
 
@@ -1565,6 +1565,11 @@ Reference XNameAccess  
ScDataPilotChildObjBase::GetMembers() const
 return xMembersNA;
 }
 
+ScDocShell* ScDataPilotChildObjBase::GetDocShell() const
+{
+return mrParent.GetDocShell();
+}
+
 // 
 
 ScDataPilotFieldsObj::ScDataPilotFieldsObj( ScDataPilotDescriptorBase rParent 
) :
@@ -2569,13 +2574,13 @@ Reference XDataPilotField  SAL_CALL 
ScDataPilotFieldObj::createNameGroup( cons
 ScDPObject* pDPObj = 0;
 if( ScDPSaveDimension* pDim = GetDPDimension( pDPObj ) )
 {
-String aDimName = pDim-GetName();
+rtl::OUString aDimName = pDim-GetName();
 
 ScDPSaveData aSaveData = *pDPObj-GetSaveData();
 ScDPDimensionSaveData* pDimData = aSaveData.GetDimensionData(); // 
created if not there
 
 // find original base
-String aBaseDimName( aDimName );
+rtl::OUString aBaseDimName( aDimName );
 const ScDPSaveGroupDimension* pBaseGroupDim = 
pDimData-GetNamedGroupDim( aDimName );
 if ( pBaseGroupDim )
 {
@@ -2595,7 +2600,7 @@ Reference XDataPilotField  SAL_CALL 
ScDataPilotFieldObj::createNameGroup( cons
 {
 for (nEntry=0; nEntrynEntryCount; nEntry++)
 {
-String aEntryName(rItems[nEntry]);
+const rtl::OUString aEntryName = rItems[nEntry];
 if ( pBaseGroupDim )
 {
 // for each selected (intermediate) group, remove all its 
items
@@ -2615,9 +2620,8 @@ Reference XDataPilotField  SAL_CALL 
ScDataPilotFieldObj::createNameGroup( cons
 if ( !pGroupDimension )
 {
 // create a new group dimension
-String aGroupDimName = pDimData-CreateGroupDimName( aBaseDimName, 
*pDPObj, false, NULL );
-pNewGroupDim = new ScDPSaveGroupDimension( aBaseDimName, 
aGroupDimName );
-sNewDim = aGroupDimName;
+sNewDim = pDimData-CreateGroupDimName( aBaseDimName, *pDPObj, 
false, NULL );
+pNewGroupDim = new ScDPSaveGroupDimension( aBaseDimName, sNewDim );
 
 pGroupDimension = pNewGroupDim; // make changes to the new dim 
if none existed
 
@@ -2645,10 +2649,10 @@ Reference XDataPilotField  SAL_CALL 
ScDataPilotFieldObj::createNameGroup( cons
 }
 }
 }
-String aGroupDimName = pGroupDimension-GetGroupDimName();
+rtl::OUString aGroupDimName = pGroupDimension-GetGroupDimName();
 
 //! localized prefix string
-String aGroupName = pGroupDimension-CreateGroupName( String( 
RTL_CONSTASCII_USTRINGPARAM( Group ) ) );
+rtl::OUString aGroupName = pGroupDimension-CreateGroupName( String( 
RTL_CONSTASCII_USTRINGPARAM( Group ) ) );
 ScDPSaveGroupItem aGroup( aGroupName );
 Reference XNameAccess  xMembers = GetMembers();
 if (!xMembers.is())
@@ -2702,7 +2706,7 @@ Reference XDataPilotField  SAL_CALL 
ScDataPilotFieldObj::createNameGroup( cons
 
 // apply changes
 pDPObj-SetSaveData( aSaveData );
-SetDPObject( pDPObj );
+ScDBDocFunc(*GetDocShell()).RefreshPivotTableGroups(pDPObj);
 }
 
 // if new grouping field has been created (on first group), return it
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: sc/workben

2012-03-14 Thread Kohei Yoshida
 sc/workben/dpcache/perf-test.cpp |  434 +++
 1 file changed, 434 insertions(+)

New commits:
commit e4fb449706b5847311ed14475d3babd6398973c7
Author: Kohei Yoshida kohei.yosh...@gmail.com
Date:   Wed Mar 14 22:46:41 2012 -0400

Some proof-of-concept code for dpcache performance.

diff --git a/sc/workben/dpcache/perf-test.cpp b/sc/workben/dpcache/perf-test.cpp
new file mode 100644
index 000..ab9e80b
--- /dev/null
+++ b/sc/workben/dpcache/perf-test.cpp
@@ -0,0 +1,434 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the License); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an AS IS basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ *   Copyright (C) 2012 Kohei Yoshida kohei.yosh...@suse.com
+ *
+ * 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.
+ */
+
+#include cstdlib
+#include iostream
+#include stdio.h
+#include string
+#include sys/time.h
+#include vector
+#include iterator
+#include algorithm
+#include functional
+
+#include boost/noncopyable.hpp
+
+using namespace std;
+
+namespace {
+
+class stack_printer
+{
+public:
+explicit stack_printer(const char* msg) :
+msMsg(msg)
+{
+fprintf(stdout, %s: --begin\n, msMsg.c_str());
+mfStartTime = getTime();
+}
+
+~stack_printer()
+{
+double fEndTime = getTime();
+fprintf(stdout, %s: --end (duration: %g sec)\n, msMsg.c_str(), 
(fEndTime-mfStartTime));
+}
+
+void printTime(int line) const
+{
+double fEndTime = getTime();
+fprintf(stdout, %s: --(%d) (duration: %g sec)\n, msMsg.c_str(), 
line, (fEndTime-mfStartTime));
+}
+
+private:
+double getTime() const
+{
+timeval tv;
+gettimeofday(tv, NULL);
+return tv.tv_sec + tv.tv_usec / 100.0;
+}
+
+::std::string msMsg;
+double mfStartTime;
+};
+
+typedef std::vectorint values_type;
+typedef std::vectorsize_t indices_type;
+
+#if 1
+size_t val_count = 600;
+double multiplier = 30.0;
+bool dump_values = false;
+#else
+size_t val_count = 20;
+double multiplier = 10.0;
+bool dump_values = true;
+#endif
+
+struct field : boost::noncopyable
+{
+values_type items;   /// unique values
+indices_type data;   /// original value series as indices into unique 
values.
+indices_type order;  /// ascending order of the values as indices.
+};
+
+long compare(int left, int right)
+{
+if (left == right)
+return 0;
+if (left  right)
+return -1;
+return 1;
+}
+
+bool has_item(const values_type items, const indices_type order, int val, 
long index)
+{
+index = items.size();
+bool found = false;
+long low = 0;
+long high = items.size() - 1;
+long comp_res;
+while (low = high)
+{
+long this_index = (low + high) / 2;
+comp_res = compare(items[order[this_index]], val);
+if (comp_res  0)
+low = this_index + 1;
+else
+{
+high = this_index - 1;
+if (comp_res == 0)
+{
+found = true;
+low = this_index;
+}
+}
+}
+index = low;
+return found;
+}
+
+bool check_items(const values_type items)
+{
+if (items.empty())
+return false;
+
+// Items are supposed to be all unique values.
+values_type copied(items);
+sort(copied.begin(), copied.end());
+copied.erase(unique(copied.begin(), copied.end()), copied.end());
+return copied.size() == items.size();
+}
+
+bool check_order(const values_type items, const indices_type order)
+{
+// Ensure that the order is truly in ascending order.
+if (items.size() != order.size())
+return false;
+
+if (items.empty())
+return false;
+
+indices_type::const_iterator it = order.begin();
+values_type::value_type prev = items[*it];
+for (++it; it != order.end(); ++it)
+{
+values_type::value_type val = items[*it];
+if (prev = val)
+return false;
+
+prev = val;
+}
+
+return true;
+}
+
+bool check_data(const values_type items, const