[Libreoffice] Crash after Preference selection on Mac

2010-11-25 Thread Chris Makepeace
Libre Office (current) and OOo (3.2.1) is repeatedly crashing as I go into
Preferences (Mac language for 'Options').

The system console reports that the crash is related to JavaNativeFoundation
and the crash log makes no mention of Java but does spend 771 lines
reporting a lot else.

iMac running OS X 10.6.5

-- 
ChrisM
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] ucb/source/ucb compilation error

2010-11-25 Thread Sebastian Spaeth
On Thu, 21 Oct 2010 09:40:53 +0200, Thomas Klausner w...@netbsd.org wrote:
 -#define OSL_LOG_PREFIX OSL_THIS_FILE : OSL_THIS_FUNC : 
 OSL_MACRO_VALUE_TO_STRING( __LINE__ ) ; 
 +#define OSL_LOG_PREFIX (OSL_THIS_FILE, :, OSL_THIS_FUNC, :, 
 OSL_MACRO_VALUE_TO_STRING( __LINE__ ), ; )

On OOo there is a bug open to remove OSL_THIS_FUNC (or was it an Easy
Hack) as it is not doing anyway what it is suposed to do.

I propose to check that up and rip it out completely.

Sebastian


pgpteDtzGGbip.pgp
Description: PGP signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] ucb/source/ucb compilation error

2010-11-25 Thread Sebastian Spaeth
On Thu, 25 Nov 2010 10:47:22 +0100, Sebastian Spaeth wrote:
  +#define OSL_LOG_PREFIX (OSL_THIS_FILE, :, OSL_THIS_FUNC, :, 
  OSL_MACRO_VALUE_TO_STRING( __LINE__ ), ; )
 
 On OOo there is a bug open to remove OSL_THIS_FUNC (or was it an Easy
 Hack) as it is not doing anyway what it is suposed to do.

This is the bug I thought of, but it is closed as fixed on 09-28:
http://www.openoffice.org/issues/show_bug.cgi?id=114290

Sebastian


pgp41hXjt5e90.pgp
Description: PGP signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] ucb/source/ucb compilation error

2010-11-25 Thread Miklos Vajna
On Thu, Nov 25, 2010 at 10:51:05AM +0100, Sebastian Spaeth 
sebast...@sspaeth.de wrote:
 On Thu, 25 Nov 2010 10:47:22 +0100, Sebastian Spaeth wrote:
   +#define OSL_LOG_PREFIX (OSL_THIS_FILE, :, OSL_THIS_FUNC, :, 
   OSL_MACRO_VALUE_TO_STRING( __LINE__ ), ; )
  
  On OOo there is a bug open to remove OSL_THIS_FUNC (or was it an Easy
  Hack) as it is not doing anyway what it is suposed to do.

That's my patch is intended to fix the issue properly. Just removing it
is not a solution, or you'll have to paste the function name in several
debug messages - and we don't like copypaste in source code, right? :)

 
 This is the bug I thought of, but it is closed as fixed on 09-28:
 http://www.openoffice.org/issues/show_bug.cgi?id=114290

Please see my earlier mail in this thread:

http://article.gmane.org/gmane.comp.documentfoundation.libreoffice.devel/2615

It's not fixed, they just removed it.


pgp2E9gOLzdVD.pgp
Description: PGP signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] ucb/source/ucb compilation error

2010-11-25 Thread Michael Meeks
Hi Miklos,

On Wed, 2010-11-24 at 16:08 +0100, Miklos Vajna wrote:
 Both are just removing the __PRETTY_FUNCTION__ / etc expressions, which
 is not that good, I think.

:-)

 The attached patch tries to solve both problems, and of course
 build-tested.
 Does it look sane - may i push it?

Looks great to me; if we took this chunk of code from boost though - we
should include the relevant boost license header and copyright statement
at the end of that file, and separate out the section it applies to
IMHO.

Thanks,

Michael.

-- 
 michael.me...@novell.com  , Pseudo Engineer, itinerant idiot


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Styles and Formatting

2010-11-25 Thread Michael Meeks
Hi Gert,

On Wed, 2010-11-03 at 18:28 +0100, Gert Faller wrote:
 I have erased the line :
 m_aActionTbL.SetHelpId( HID_TEMPLDLG_TOOLBOX_LEFT );
 in the patch file 2.
 A pastecopy error...

So - I notice this is still not merged; which is bad. Sorry for the
delay - clearly this got killed by some big waffly thread with no
apparent conclusion: which is annoying.

Can you send a patch with your best effort  we'll just merge it to
master :-) any complaints can be fixed later [ or did I just mis-read
and it did get merged ? ].

Sorry,

Michael.

-- 
 michael.me...@novell.com  , Pseudo Engineer, itinerant idiot


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] ucb/source/ucb compilation error

2010-11-25 Thread Tor Lillqvist
 Tor was exercised about this at one stage IIRC, does the above work for you ?

Sure, although I think I would prefer to keep OSL_THIS_FUNC as  instead of 
(unknown) in the fallback case. Also, we need to find out if there really is 
no __func__ or similar even in MSVC2010.

So, you think the i#114290 argument that neither __PRETTY_FUNCTION__ nor 
__func__ can be used because neither is a string literal and thus can't be 
compile-time concatenated with other string literals is bogus?

As such, it is true of course that they can't be used like that. But is the 
proper solution then just to not try to use OSL_THIS_FUNC in that way? Instead 
just pass it as a separate argument to printf (yeah, my C background shows 
through) or whatever?

--tml


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] More links inherited from OOo

2010-11-25 Thread Florian Effenberger

Hi,

Christian Lohmaier wrote on 2010-11-16 16.22:

Do we want to have a support.libreoffice.org subsite, or do we want to
havewww.libreoffice.org/support?


for now, I'd go with the latter one, but that's just my feeling...

Florian

--
Florian Effenberger flo...@documentfoundation.org
Steering Committee and Founding Member of The Document Foundation
Tel: +49 8341 99660880 | Mobile: +49 151 14424108
Skype: floeff | Twitter/Identi.ca: @floeff
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Auto-detection of toolbar icon size (well, kinda)

2010-11-25 Thread Thorsten Behrens
Michael Meeks wrote:
  prompted by some complaints on too large icons on Mac, switched the
  icon size from 'large' to 'auto' for 3.3.
 
   Did we ever get some screenshots of the perceived problem ? I asked in
 some bug, but never got that back AFAIR.
 
Hi Michael,

take my word for it, it looks out-of-place on Mac.

   My concern is for Windows really - I'd want the vast majority of users
 on  1024x768 to have large icons.
 
   Have we tested it there ?
 
Code on Win32 is currently:

long nHeightPx = aMenuFont.GetHeight() * nDPIY / 72;
aStyleSettings.SetToolbarIconSize( (((nHeightPx-1)*2) = 28) ? 
STYLE_TOOLBAR_ICONSIZE_LARGE : STYLE_TOOLBAR_ICONSIZE_SMALL );

If that does not suffice, surely we can do a hard pick for _LARGE
here, just the same as for Gnome/KDE. It's the sole discretion of 
the native widget layer now - that's were it belongs to.

Cheers,

-- Thorsten


pgpcnoQ0Xjxcy.pgp
Description: PGP signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Auto-detection of toolbar icon size (well, kinda)

2010-11-25 Thread Tor Lillqvist
 On 2010-11-25 at 12:47, peterla...@gmail.com wrote:
 On Thu. 25.11.2010 10:19, Michael Meeks wrote:
 prompted by some complaints on too large icons on Mac, switched the
 icon size from 'large' to 'auto' for 3.3.

  Did we ever get some screenshots of the perceived problem ? I asked in
 some bug, but never got that back AFAIR.

 this was already in place for windows

  I really think the small icons are a usability, and legibility disaster
 when used on large screens - and there is a real risk of selecting them;

  My concern is for Windows really - I'd want the vast majority of users
 on  1024x768 to have large icons.
 
 That's fine, but the large Icons are (about 50%) *too* large. I'm on 
 Windows 7, have a 19 monitor, ratio: 4:5, resolution: 1280x1024 and I 
 cannot fit the icons I want into the Toolbar.
 
 See screen-shot: 
 http://picasaweb.google.com/lh/photo/akH_sf-pDibweqBLML-dcQ?feat=directlink 
 
 The situation is made worse by the very poor quality of the icon images. 
 For instance:
 
 1. The New document icon looks more like a fireplace than the standard 
 (a blank white rectangle).
 
 2. the Open Document icon doesn't look like most open icons (yellow 
 folder) and looks worse (so deviating from the standard was not an 
 improvement).
 
 3. The Close Document icon is a black X. That symbol almost always 
 means *delete*.
 
 4. The Print icon is too blurry. Even at the too large size it is less 
 recognizable than the much smaller Print icons of most other applications.
 
 5. There is no Page Settings  icon.
 
 6. The Zoom icon looks too much like a find icon. Pot. solution: add a 
 + inside the magnifier.
 
 7. The Review Changes Toolbar icons don't have icons (only text).
 
 8. The Styles and Formatting icon looks like a 
 Even users in non-localized countries will recognize the B 
 I U better than A A A, even if they don't know what the letters stand 
 for. Even Windows Live Writer uses B I U.

These icons *are* localised, as far as I can see. At least in beta3 on Windows, 
in Swedish, they show up as

   F K U

I guess I don't need to spell it out what English phrase those big ugly letters 
always make me think of.

--tml


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] compilation of LO on mac

2010-11-25 Thread Thorsten Behrens
Jonathan Aquilina wrote:
 hey guys is it possible to compile LO on mac osx? if so what
 dependencies does one need to satisfy before compiling it.

Hi Jonathan,

sure - please read up here for details:

http://wiki.documentfoundation.org/Development/How_to_build#Mac_OS_X

Don't hesitate to ask, either here or on #libreoffice - I think I've
seen you there already. ;)

Cheers,

-- Thorsten


pgpdtChX3e9CL.pgp
Description: PGP signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] installation on mac doesnt require read me or licenses

2010-11-25 Thread Thorsten Behrens
Jonathan Aquilina wrote:
 hey guys i'm noticing something interesting. wouldn't it be better
 to use an installer to make sure the read me's as well as the
 licenses get installed in the LO directory. currently the way it is
 i don't have to drag either of them into the application directory.

Hi Jonathan,

well - I consider that a feature? As it is now, chances are probably
higher that a user notices the licenses in the first place. ;)

Cheers,

-- Thorsten, who doesn't really like installers on Mac


pgpP2wQQP32hH.pgp
Description: PGP signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] installation on mac doesnt require read me or licenses

2010-11-25 Thread Jonathan Aquilina
im happy with the way things are done on mac, but the folder that has the
licenses i didnt even bother looking at that folder hence the suggestion for
a mac package that would install LO in the app folder.

On Thu, Nov 25, 2010 at 1:11 PM, Thorsten Behrens 
t...@documentfoundation.org wrote:

 Jonathan Aquilina wrote:
  hey guys i'm noticing something interesting. wouldn't it be better
  to use an installer to make sure the read me's as well as the
  licenses get installed in the LO directory. currently the way it is
  i don't have to drag either of them into the application directory.
 
 Hi Jonathan,

 well - I consider that a feature? As it is now, chances are probably
 higher that a user notices the licenses in the first place. ;)

 Cheers,

 -- Thorsten, who doesn't really like installers on Mac




-- 
Jonathan Aquilina
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Are ISC/BSD-licensed contributions acceptable?

2010-11-25 Thread Michael Meeks

On Mon, 2010-11-22 at 09:47 +0100, Gioele Barabucci wrote:
 in bug #31633 I proposed a patch to one of the export filters.

I've just committed it; sorry for delay.

It's great to have you prodding at this piece of the code. One of the
sad things about the XSLT filters is that they require Java - yielding
not only a performance problem, but a nightmare for those without Java
installed. Perhaps this underlies some reluctance here too:

https://bugs.freedesktop.org/show_bug.cgi?id=31624

around associating with this file type by default (in case you have no
working Java).

It would be simply wonderful to re-use the libxslt code (that we
already ship) for the XSLT filter. I wonder if you might be interested
in that ? if not - adding an easy hack to the wiki would be good [ and
pointing me at it so we can add some code pointers as to how to do
that ].

Thanks !

Michael.

-- 
 michael.me...@novell.com  , Pseudo Engineer, itinerant idiot


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] quick starter applet/systray defaults and various confusion

2010-11-25 Thread Caolán McNamara
On Wed, 2010-11-24 at 20:50 +, Caolán McNamara wrote:
 On Wed, 2010-11-24 at 12:04 +0100, David Tardon wrote:
  Does anyone have any clever idea how to prevent that?
 
 How about we over-engineer and..
 
 a) use osl_getModuleURLFromFunctionAddress or something of that nature
 to get the filename of the physical .so that we were originally dlopened
 on
 b) Get a GFileMonitor from gio via g_file_monitor for that .so and
 attach to its changed signal to get notified when that .so has been
 deleted, and turn off the quickstarter (or get it to disable its menus
 and sommat like LibreOffice upgraded restart needed! :-0) when that
 happens.

This seems to work, e.g. the attached.

C.
diff --git a/sfx2/source/appl/makefile.mk b/sfx2/source/appl/makefile.mk
index 72ac94a..a583102 100644
--- a/sfx2/source/appl/makefile.mk
+++ b/sfx2/source/appl/makefile.mk
@@ -53,6 +53,10 @@ CFLAGS+=-DENABLE_QUICKSTART_APPLET
 CDEFS+=-DDLL_NAME=libsfx$(DLLPOSTFIX)$(DLLPOST)
 .IF $(ENABLE_SYSTRAY_GTK)==TRUE
 PKGCONFIG_MODULES=gtk+-2.0
+.IF $(ENABLE_GIO)!=
+PKGCONFIG_MODULES+=gio-2.0
+CDEFS+=-DENABLE_GIO
+.ENDIF
 .INCLUDE: pkg_config.mk
 CFLAGS+=$(PKGCONFIG_CFLAGS)
 CFLAGS+=-DENABLE_QUICKSTART_APPLET
diff --git a/sfx2/source/appl/shutdowniconunx.cxx b/sfx2/source/appl/shutdowniconunx.cxx
index e31c32f..1b78f9b 100644
--- a/sfx2/source/appl/shutdowniconunx.cxx
+++ b/sfx2/source/appl/shutdowniconunx.cxx
@@ -19,6 +19,10 @@
 #include shutdownicon.hxx
 #endif
 
+#ifdef ENABLE_GIO
+#include gio/gio.h
+#endif
+
 // Cut/paste from vcl/inc/svids.hrc
 #define SV_ICON_SMALL_START 25000
 
@@ -39,6 +43,9 @@ static EggTrayIcon *pTrayIcon;
 static GtkWidget *pExitMenuItem = NULL;
 static GtkWidget *pOpenMenuItem = NULL;
 static GtkWidget *pDisableMenuItem = NULL;
+#ifdef ENABLE_GIO
+GFileMonitor* pMonitor = NULL;
+#endif
 
 static void open_url_cb( GtkWidget *, gpointer data )
 {
@@ -358,6 +365,22 @@ extern C {
 }
 }
 
+#ifdef ENABLE_GIO
+/*
+ * See rhbz#610103. If the quickstarter is running, then LibreOffice is
+ * upgraded, then the old quickstarter is still running, but is now unreliable
+ * as the old install has been deleted. A fairly intractable problem but we
+ * can avoid much of the pain if we turn off the quickstarter if we detect
+ * that it has been physically deleted.
+*/
+static void notify_file_changed(GFileMonitor * /*gfilemonitor*/, GFile * /*arg1*/,
+GFile * /*arg2*/, GFileMonitorEvent event_type, gpointer /*user_data*/)
+{
+if (event_type == G_FILE_MONITOR_EVENT_DELETED)
+exit_quickstarter_cb(GTK_WIDGET(pTrayIcon));
+}
+#endif
+
 void SAL_DLLPUBLIC_EXPORT plugin_init_sys_tray()
 {
 ::SolarMutexGuard aGuard;
@@ -403,6 +426,20 @@ void SAL_DLLPUBLIC_EXPORT plugin_init_sys_tray()
 
 g_signal_connect(GTK_WIDGET(pTrayIcon), destroy,
 G_CALLBACK(exit_quickstarter_cb), NULL);
+
+#ifdef ENABLE_GIO
+GFile* pFile = NULL;
+rtl::OUString sLibraryFileUrl;
+if (osl::Module::getUrlFromAddress(plugin_init_sys_tray, sLibraryFileUrl))
+pFile = g_file_new_for_uri(rtl::OUStringToOString(sLibraryFileUrl, RTL_TEXTENCODING_UTF8).getStr());
+
+if (pFile)
+{
+if ((pMonitor = g_file_monitor_file(pFile, G_FILE_MONITOR_NONE, NULL, NULL)))
+g_signal_connect(pMonitor, changed, (GCallback)notify_file_changed, NULL); 
+g_object_unref(pFile);
+}
+#endif
 }
 
 void SAL_DLLPUBLIC_EXPORT plugin_shutdown_sys_tray()
@@ -411,6 +448,17 @@ void SAL_DLLPUBLIC_EXPORT plugin_shutdown_sys_tray()
 if( !pTrayIcon )
 return;
 
+#ifdef ENABLE_GIO
+if (pMonitor)
+{
+g_signal_handlers_disconnect_by_func(pMonitor,
+(void*)notify_file_changed, pMonitor);
+g_file_monitor_cancel(pMonitor);
+g_object_unref(pMonitor);
+pMonitor = NULL;
+}
+#endif
+
 /* we have to set pTrayIcon to NULL now, because gtk_widget_destroy
  * causes calling exit_quickstarter_cb (which then calls this func.)
  * again - crash.
@@ -419,7 +467,7 @@ void SAL_DLLPUBLIC_EXPORT plugin_shutdown_sys_tray()
  */
 GtkWidget* const pIcon = GTK_WIDGET( pTrayIcon );
 pTrayIcon = NULL;
-	gtk_widget_destroy( pIcon );
+gtk_widget_destroy( pIcon );
 
 pExitMenuItem = NULL;
 pOpenMenuItem = NULL;
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH] Another Base cleanup

2010-11-25 Thread Wols Lists
Cheers,
Wol
From 6642a11fbcfa7f2f4f35f5535ffe8c33fa856309 Mon Sep 17 00:00:00 2001
From: Wol anth...@youngman.org.uk
Date: Thu, 25 Nov 2010 13:04:08 +
Subject: [PATCH 4/4] Dead code deletion

---
 dbaccess/source/ui/querydesign/JoinDesignView.cxx  |1 -
 dbaccess/source/ui/querydesign/QueryDesignView.cxx |1 -
 dbaccess/source/ui/tabledesign/FieldDescGenWin.cxx |9 -
 .../source/ui/tabledesign/TableFieldControl.cxx|3 ---
 .../source/ui/tabledesign/TableFieldDescWin.cxx|1 -
 dbaccess/source/ui/tabledesign/TableRow.cxx|4 +---
 .../source/ui/tabledesign/TableRowExchange.cxx |7 ---
 dbaccess/source/ui/tabledesign/TableUndo.cxx   |3 ---
 8 files changed, 1 insertions(+), 28 deletions(-)

diff --git a/dbaccess/source/ui/querydesign/JoinDesignView.cxx 
b/dbaccess/source/ui/querydesign/JoinDesignView.cxx
index 86545a6..f917f00 100644
--- a/dbaccess/source/ui/querydesign/JoinDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/JoinDesignView.cxx
@@ -49,7 +49,6 @@
 #include comphelper/extract.hxx
 #include UITools.hxx
 #include JoinTableView.hxx
-// #include com/sun/star/util/URL.hdl
 
 using namespace ::com::sun::star::uno;
 using namespace ::com::sun::star::lang;
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx 
b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index 920fb54..1e1aa76 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -375,7 +375,6 @@ namespace
 {
 ::rtl::OUString aDBName(pEntryTab-GetComposedName());
 
-// Reference XConnection xConnection = 
static_castOQueryController(_pView-getController()).getConnection();
 if( _xConnection.is() )
 {
 try
diff --git a/dbaccess/source/ui/tabledesign/FieldDescGenWin.cxx 
b/dbaccess/source/ui/tabledesign/FieldDescGenWin.cxx
index 05384fd..b0fc9c5 100644
--- a/dbaccess/source/ui/tabledesign/FieldDescGenWin.cxx
+++ b/dbaccess/source/ui/tabledesign/FieldDescGenWin.cxx
@@ -110,11 +110,6 @@ OTableEditorCtrl* OFieldDescGenWin::GetEditorCtrl()
 }
 #endif
 
//--
-//short OFieldDescGenWin::GetFormatCategory(OFieldDescription* pFieldDescr)
-//{
-// return m_pFieldControl-GetFormatCategory(pFieldDescr);
-//}
-//--
 void OFieldDescGenWin::SaveData( OFieldDescription* pFieldDescr )
 {
 DBG_CHKTHIS(OFieldDescGenWin,NULL);
@@ -184,8 +179,4 @@ void OFieldDescGenWin::paste()
 }
 // 
-
 
-
-
-
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableFieldControl.cxx 
b/dbaccess/source/ui/tabledesign/TableFieldControl.cxx
index 60cc7ea..65b0dfc 100644
--- a/dbaccess/source/ui/tabledesign/TableFieldControl.cxx
+++ b/dbaccess/source/ui/tabledesign/TableFieldControl.cxx
@@ -153,7 +153,4 @@ sal_Bool OTableFieldControl::isAutoIncrementValueEnabled() 
const
 }
 // 
-
 
-
-
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx 
b/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
index d5dab97..bf506d1 100644
--- a/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
+++ b/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
@@ -317,5 +317,4 @@ long OTableFieldDescWin::PreNotify( NotifyEvent rNEvt )
 return bHandled ? 1L : TabPage::PreNotify(rNEvt);
 }
 
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableRow.cxx 
b/dbaccess/source/ui/tabledesign/TableRow.cxx
index 568e7c3..1ca7d53 100644
--- a/dbaccess/source/ui/tabledesign/TableRow.cxx
+++ b/dbaccess/source/ui/tabledesign/TableRow.cxx
@@ -156,7 +156,7 @@ namespace dbaui
 _rStr  sal_Int32(pFieldDesc-IsAutoIncrement() ? 1 : 0);
 _rStr  sal_Int32(pFieldDesc-IsPrimaryKey() ? 1 : 0);
 _rStr  sal_Int32(pFieldDesc-IsCurrency() ? 1 : 0);
-} // if(pFieldDesc)
+}
 else
 _rStr  (sal_Int32)0;
 return _rStr;
@@ -226,6 +226,4 @@ namespace dbaui
 // 
-
 }
 
-
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableRowExchange.cxx 
b/dbaccess/source/ui/tabledesign/TableRowExchange.cxx
index 6eabff9..249698c 100644
--- a/dbaccess/source/ui/tabledesign/TableRowExchange.cxx
+++ b/dbaccess/source/ui/tabledesign/TableRowExchange.cxx
@@ -81,11 +81,4 @@ namespace dbaui
 // 
-
 }
 
-
-
-
-
-
-
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git 

[Libreoffice] [Pushed] Another Base cleanup

2010-11-25 Thread Michael Meeks

Nice, thanks !

Michael.

-- 
 michael.me...@novell.com  , Pseudo Engineer, itinerant idiot


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Are ISC/BSD-licensed contributions acceptable?

2010-11-25 Thread Gioele Barabucci

Wols Lists 25/11/2010 14:21:

It's tricky, but imho the rule should be if you make a major
contribution to a file then you add your copyright notice. In general,
patches, fixes, etc shouldn't. And possibly we add a line that says
copyright assorted contributors - see git history for details.


Major is quite hard to define, I'd say impossible, given that almost 
every contry has its own threshold for what is and what isn't a major 
change.


My take is: whoever made a commit to a file should be in the list of the 
authors for a file. There can be problems with people trying to sneak 
in the authors' list, as Michael Meeks pointed out. But that is just 
unavoidable, just be careful with what patches you accept.


Git can help you track down the authors (and there should be automated 
tools to do that; in my spare time I'm working on one) but there should 
also be external bookkeepers for pre-git commits and for commits not 
made by the original author.



BUT. As far as my contributions so far are concerned I don't even know
if they are significant enough to be worthy of copyright! If I was asked
to assign a licence I would say BSD but even that's overkill for what I
think they're worth :-)


That is the exact reason I wanted to use the ISC license. But if somehow 
that makes things harder to integrate and maintain...



We want to get it right. If not, we could be storing up legal trouble
down the line. But at the end of the day, if the consensus is that we
want to be an LGPL project, then simply saying all contributions must
be LGPL3+ compatible keeps us out of trouble.  If contributors want to
use BSD etc why should we care?


The problems usually arise with the contribution of non-BSD patches on 
top of BSD patches that are on top of other non-BSD patches. Go figure 
it out what are you contributing to.



And if third parties want to extract
said BSD code, why should we make their life easy (or hard :-) ? If they
want the code, it's their problem :-)


I could not agree more ;)

--
Gioele Barabucci gio...@svario.it

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] quick starter applet/systray defaults and various confusion

2010-11-25 Thread Michael Meeks

On Thu, 2010-11-25 at 13:14 +, Caolán McNamara wrote:
 This seems to work, e.g. the attached.

Looks great to me :-) [ still puzzling over the migration swamp
though ].

Regards,

Michael.

-- 
 michael.me...@novell.com  , Pseudo Engineer, itinerant idiot


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] quick starter applet/systray defaults and various confusion

2010-11-25 Thread Michael Meeks
Hi Caolan,

On Thu, 2010-11-25 at 09:42 +, Caolán McNamara wrote:
 On Fri, 2010-11-19 at 15:37 +, Caolán McNamara wrote:
  3) We should probably instead modify InitializeQuickStartMode to
  effectively || Sfx::ShutdownIcon::GetAutostart() with the IsQuickStart
  command line argument.
  
  If we were to do all through, the first thing people would notice is
  that the quickstart applet/systray would appear to change from defaulted
  on to defaulted off. 
 
 I've pushed this change to master. If there is no complaints or horrific
 fallout I propose to cherrypick it for 3.3 in a few days.

That would be brilliant - I'm testing migration, and it's certainly an
underwhelming mis-feature that pops up and part-mangles that.

Thanks !

Michael.

-- 
 michael.me...@novell.com  , Pseudo Engineer, itinerant idiot


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH] Remove dead codes and undesired comments with fixed typo

2010-11-25 Thread Takeshi Abe
Hi,

yet another cleanup on base.

Cheers,
-- Takeshi Abe
From dff2f8d6d37863a5517a412ea4f92ebdbee536ff Mon Sep 17 00:00:00 2001
From: Takeshi Abe t...@fixedpoint.jp
Date: Fri, 26 Nov 2010 01:45:21 +0900
Subject: [PATCH] Remove dead codes and undesired comments with fixed typo

---
 dbaccess/source/ui/browser/sbagrid.cxx |3 -
 dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx  |1 -
 dbaccess/source/ui/dlg/ExtensionNotPresent.hrc |1 -
 dbaccess/source/ui/dlg/dbwizsetup.cxx  |1 -
 dbaccess/source/ui/inc/RefFunctor.hxx  |4 -
 dbaccess/source/ui/inc/TableRow.hxx|3 -
 dbaccess/source/ui/inc/sbagrid.hxx |2 -
 dbaccess/source/ui/misc/RowSetDrop.cxx |7 +-
 dbaccess/source/ui/misc/WCPage.cxx |5 +-
 dbaccess/source/ui/misc/WCopyTable.cxx |1 -
 dbaccess/source/ui/misc/WTypeSelect.cxx|1 -
 .../ui/relationdesign/RelationController.cxx   |2 -
 dbaccess/source/ui/tabledesign/TEditControl.cxx|   28 +
 .../source/ui/tabledesign/TableDesignControl.cxx   |3 -
 dbaccess/source/ui/tabledesign/TableDesignView.cxx |1 -
 reportdesign/inc/RptPage.hxx   |1 -
 reportdesign/inc/RptResId.hrc  |1 -
 reportdesign/qa/complex/ReportDesignerTest.java|   63 
 reportdesign/source/core/api/ReportDefinition.cxx  |   46 ++-
 reportdesign/source/core/inc/Tools.hxx |6 +-
 reportdesign/source/core/sdr/RptPage.cxx   |   29 +
 reportdesign/source/ui/dlg/AddField.cxx|8 +--
 reportdesign/source/ui/dlg/GroupsSorting.hrc   |   10 ---
 .../source/ui/inspection/GeometryHandler.cxx   |   15 +
 24 files changed, 22 insertions(+), 220 deletions(-)

diff --git a/dbaccess/source/ui/browser/sbagrid.cxx b/dbaccess/source/ui/browser/sbagrid.cxx
index 23c7e24..e8d4459 100644
--- a/dbaccess/source/ui/browser/sbagrid.cxx
+++ b/dbaccess/source/ui/browser/sbagrid.cxx
@@ -257,8 +257,6 @@ void SAL_CALL SbaXGridControl::createPeer(const Reference ::com::sun::star::awt
 
 // TODO: why the hell this whole class does not use any mutex?
 
-//	if (0 == m_nPeerCreationLevel)
-{
 Reference ::com::sun::star::frame::XDispatch   xDisp(getPeer(), UNO_QUERY);
 for (	StatusMultiplexerArray::iterator aIter = m_aStatusMultiplexer.begin();
 aIter != m_aStatusMultiplexer.end();
@@ -267,7 +265,6 @@ void SAL_CALL SbaXGridControl::createPeer(const Reference ::com::sun::star::awt
 if ((*aIter).second  (*aIter).second-getLength())
 xDisp-addStatusListener((*aIter).second, (*aIter).first);
 }
-}
 }
 
 //---
diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
index fe236af..d2efae3 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
@@ -48,7 +48,6 @@ namespace dbaui
 //.
 
 class IDatabaseSettingsDialog;
-//		static	OGenericAdministrationPage*	CreateDbaseTabPage( Window* pParent, const SfxItemSet _rAttrSet );
 
 
//
diff --git a/dbaccess/source/ui/dlg/ExtensionNotPresent.hrc b/dbaccess/source/ui/dlg/ExtensionNotPresent.hrc
index cb314b9..17b4d14 100644
--- a/dbaccess/source/ui/dlg/ExtensionNotPresent.hrc
+++ b/dbaccess/source/ui/dlg/ExtensionNotPresent.hrc
@@ -37,7 +37,6 @@
 #define BUTTON_HEIGHT		14
 #define BUTTON_WIDTH		55
 #define BROWSER_HEIGHT		75
-// #define PAGE_WIDTH			( CELL_PADDING + BUTTON_WIDTH + CELL_PADDING + BUTTON_WIDTH + CELL_PADDING)
 #define LEFT_PADDING32 /* size for the icon */
 #define RIGHT_PADDING   16
 #define DLG_WIDTH			( 250 )
diff --git a/dbaccess/source/ui/dlg/dbwizsetup.cxx b/dbaccess/source/ui/dlg/dbwizsetup.cxx
index 5c2d19a..3e64f82 100644
--- a/dbaccess/source/ui/dlg/dbwizsetup.cxx
+++ b/dbaccess/source/ui/dlg/dbwizsetup.cxx
@@ -181,7 +181,6 @@ ODbTypeWizDialogSetup::ODbTypeWizDialogSetup(Window* _pParent
 m_pOutSet = new SfxItemSet( *_pItems-GetPool(), _pItems-GetRanges() );
 
 m_pImpl-translateProperties(xDatasource, *m_pOutSet);
-//	eType = m_pImpl-getDatasourceType(*m_pOutSet);
 
 SetPageSizePixel(LogicToPixel(::Size(WIZARD_PAGE_X, WIZARD_PAGE_Y), MAP_APPFONT));
 ShowButtonFixedLine(sal_True);
diff --git a/dbaccess/source/ui/inc/RefFunctor.hxx b/dbaccess/source/ui/inc/RefFunctor.hxx
index 6e33ef2..7782fec 100644
--- a/dbaccess/source/ui/inc/RefFunctor.hxx
+++ b/dbaccess/source/ui/inc/RefFunctor.hxx
@@ -47,10 +47,6 @@ namespace dbaui
 {
 m_aFunction(_aType.get());
 }
-//		inline void operator()(const ::rtl::ReferenceT _aType)

Re: [Libreoffice] LibreOffice config migration

2010-11-25 Thread Michael Meeks

On Fri, 2010-10-15 at 19:23 +0200, André Schnabel wrote:
 Am 15.10.2010 17:21, schrieb Michael Meeks:
  So - here is my suggestion ;-) hopefully it annoys everybody, and it is
  two-fold.
..
 (no question on 1. - harden the code for migration)

 ...
  2. we continue to do automatic config migration since this is
 a commonly desired use-case
  *but*
 as we migrate the settings the first time, we write into the
 (original - ie. the old version)'s directory a stamp file
 that says these have been imported
  *and*
 if the same version is run again with the new settings
 directory removed (ie. someting went wrong); we prompt the
 user on the second time:
  do you want to (re-)import settings from ABC install

 Sounds like a reasonable compromise to me. Mechtilde?

Ok - so, I just pushed this to master, and will cherry-pick to 3.3 in a
bit; I didn't add the prompting piece - so, we essentially do a one-shot
migration from the old settings; and if people want to re-do that they
need to remove the 'MIGRATED' file from their old settings directory
(hopefully that is somewhat possible).

For post 3.3 - hopefully, we can have the dialog pop up - and it would
also be nice to have some graphical warning that we are about to restart
having done a settings migration, instead of the silent exit we have
now. I can't make myself use the non-layout dialog code though ;-) so -
must review Ricardo's new layout work next.

HTH,

Michael.

-- 
 michael.me...@novell.com  , Pseudo Engineer, itinerant idiot


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] warnig and coding, need a little help on C++

2010-11-25 Thread Pierre-André Jacquod
Hello,
as I said, still in warm up phase and getting back familiar with C++..
So cleaning is a good exercise.

I got a compiler warning:

filters/binfilter/bf_sw/source/core/para/sw_paratr.cxx:214:26: warning:
'nTemp' may be used uninitialized in this function

for this:

case MID_DROPCAP_LINES :
{
 sal_Int8 nTemp;
 rVal = nTemp;
 if(nTemp =1  nTemp  0x7f
 nLines = (BYTE)nTemp;
}

Well, that's fine for me, nTemp is effectively not initialized. And the
second line is then the same as: rVal = rVal  nTemp

In my understanding, since nTemps is not initialized, if the compiler is
nice, nTemp is then defaulted to 0 (or NULL). Then rVal = rVal  0 make
not a lot of sense and is a true nop (no operation). And if the compiler
is not nice, I do not know which value has nTemp, i could almost use
random... So for me it seems the two first lines are not needed and even
dangerous.

OK, now the question: what did I missed ?

Thank for your help
regards
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] Extensions code cleanup

2010-11-25 Thread Roth Robert
Some more dead code and bogus comments removed from extensions. The license,
as always is LGPLv3+ / MPL.
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] Fwd: Extensions code cleanup with patch

2010-11-25 Thread Roth Robert
-- Forwarded message --
From: Roth Robert robert.roth@gmail.com
Date: Thu, Nov 25, 2010 at 9:27 PM
Subject: Extensions code cleanup
To: libreoffice@lists.freedesktop.org


Some more dead code and bogus comments removed from extensions. The license,
as always is LGPLv3+ / MPL.
From 550313e5020f855fd1a733f8ac9aed269bd00de3 Mon Sep 17 00:00:00 2001
From: Robert Roth robert.roth@gmail.com
Date: Thu, 25 Nov 2010 21:22:04 +0200
Subject: [PATCH] Some more dead code removed from the extensions.

---
 extensions/source/bibliography/datman.cxx|   30 --
 extensions/source/bibliography/toolbar.cxx   |7 +
 extensions/source/bibliography/toolbar.hxx   |1 -
 extensions/source/dbpilots/controlwizard.cxx |   25 --
 extensions/source/dbpilots/groupboxwiz.cxx   |6 
 extensions/source/ole/ole2uno.cxx|   16 ---
 extensions/source/ole/unoconversionutilities.hxx |7 -
 extensions/source/ole/unotypewrapper.hxx |2 +-
 extensions/source/oooimprovement/invite_job.cxx  |9 --
 extensions/source/propctrlr/browserview.hxx  |2 -
 extensions/source/propctrlr/taborder.cxx |2 -
 extensions/source/scanner/sane.cxx   |1 -
 extensions/source/scanner/scanwin.cxx|   14 +-
 extensions/source/svg/svgwriter.cxx  |4 ---
 14 files changed, 9 insertions(+), 117 deletions(-)

diff --git a/extensions/source/bibliography/datman.cxx b/extensions/source/bibliography/datman.cxx
index 85fb0f9..3ad77ed 100644
--- a/extensions/source/bibliography/datman.cxx
+++ b/extensions/source/bibliography/datman.cxx
@@ -134,19 +134,12 @@ Reference XConnection  getConnection(const ::rtl::OUString _rURL)
 ::rtl::OUString sUser, sPwd;
 Reference XPropertySet   xDataSourceProps(xDataSource, UNO_QUERY);
 Reference XCompletedConnection  xComplConn(xDataSource, UNO_QUERY);
-/*		Reference XPropertySetInfo   xInfo = xDataSourceProps.is() ? xDataSourceProps-getPropertySetInfo() : Reference XPropertySetInfo  ();
-if (xInfo.is()  xInfo-hasPropertyByName(C2U(User)))
-xDataSourceProps-getPropertyValue(C2U(User)) = sUser;
-if (xInfo.is()  xInfo-hasPropertyByName(C2U(Password)))
-xDataSourceProps-getPropertyValue(C2U(Password))= sPwd;
-*/
 try
 {
 
 ReferenceXInterface xHdl = xMgr-createInstance(C2U(com.sun.star.task.InteractionHandler));
 Referencetask::XInteractionHandler xIHdl(xHdl, UNO_QUERY);
 xConn = xComplConn-connectWithCompletion(xIHdl);
-//			xConn = xDataSource-getConnection(sUser, sPwd);
 }
 catch(SQLException)
 {
@@ -582,7 +575,6 @@ class DBChangeDialog_Impl : public ModalDialog
 
 BibDataManager* pDatMan;
 
-//	DECL_LINK(EndDragHdl, HeaderBar*);
 DECL_LINK(DoubleClickHdl, SvTabListBox*);
 public:
 DBChangeDialog_Impl(Window* pParent, BibDataManager* pMan );
@@ -651,16 +643,6 @@ IMPL_LINK(DBChangeDialog_Impl, DoubleClickHdl, SvTabListBox*, /*pLB*/)
 return 0;
 }
 
-/*IMPL_LINK(DBChangeDialog_Impl, EndDragHdl, HeaderBar*, pHB)
-{
-long nTabs[3];
-nTabs[0] = 2;// Number of Tabs
-nTabs[1] = 0;
-nTabs[2] = pHB-GetItemSize( 1 );
-aSelectionLB.SetTabs( nTabs[0], MAP_PIXEL );
-return 0;
-};*/
-
 DBChangeDialog_Impl::~DBChangeDialog_Impl()
 {
 }
@@ -676,7 +658,6 @@ String	DBChangeDialog_Impl::GetCurrentURL()const
 return sRet;
 }
 
-// #100312# 
 // XDispatchProvider
 BibInterceptorHelper::BibInterceptorHelper( ::bib::BibBeamer* pBibBeamer, ::com::sun::star::uno::Reference ::com::sun::star::frame::XDispatch  xDispatch)
 {
@@ -762,7 +743,6 @@ void SAL_CALL BibInterceptorHelper::setMasterDispatchProvider( const ::com::sun:
 
 BibDataManager::BibDataManager()
 :BibDataManager_Base( GetMutex() )
-// #100312# --
 ,m_pInterceptorHelper( NULL )
 ,m_aLoadListeners(m_aMutex)
 ,pBibView( NULL )
@@ -791,7 +771,6 @@ BibDataManager::~BibDataManager()
 xConnection-dispose();
 m_xForm = NULL;
 }
-// #100312# 
 if( m_pInterceptorHelper )
 {
 m_pInterceptorHelper-ReleaseInterceptor();
@@ -910,9 +889,6 @@ Reference awt::XControlModel 	BibDataManager::updateGridModel(const Reference
 m_xGridModel = createGridModel( gGridName );
 
 Reference XNameContainer   xNameCont(xDbForm, UNO_QUERY);
-//			if (xNameCont-hasByName(sName))
-//xNameCont-removeByName(sName);
-//
 xNameCont-insertByName( sName, makeAny( m_xGridModel ) );
 }
 
@@ -1513,7 +1489,6 @@ Reference awt::XControlModel 	BibDataManager::loadControlModel(
 // (as an anologon to the XStatusListener semantics).
 //
 // But this would be way too risky for this last-day fix here.
-// 97140 - 

Re: [Libreoffice] C++0x and LibreOffice

2010-11-25 Thread Caolán McNamara
On Thu, 2010-11-25 at 19:53 +0100, Pierre-André Jacquod wrote:
 Hello,
 thanks, will avoid some errors..
 
 I guess this is not (yet ?) enabled per default / per configure choices?

Not yet.

 Since I am very weak with make and such tools: any possibility to enable
 it per option when running ./autogen.sh ? Activated if possible during
 the configure run?  Or an other way to let it run?

I intend to add a configure test to see if, when using gcc, the 
-std=c++0x option is accepted and if it is default to using it. The only
open question is, seeing as c++0x isn't finalized yet, what version of 
g++ is the earliest where -std=c++0x supports what we need. I'll
probably just toggle it on for gcc 4.5.1 and let people with earlier
versions experiment and see if tweaking the number lower works too.

C.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [PUSHED] Re: [PATCH 02/12] RTL_CONSTASCII_USTRINGPARAM in components cui options

2010-11-25 Thread Jan Holesovsky
Hi Wol,

On 2010-11-23 at 20:49 +, Wols Lists wrote:

   String aFoo = String::createFromAscii( Something )
 
  should be replaced, with
 
   String aFoo( RTL_CONSTASCII_USTRINGPARAM( Something ) )

 Fine. Fixes in base will appear as I spot them :-) Just one important
 little point - the reason I asked is that I think the strings might
 actually be being passed to a non-OOo library - will this break a
 third-party library? (My C++-foo isn't good enough to answer this
 question for myself :-)

This 'String' is an LibO internal class too (usually called tools
string), so should be no problem.  Or do you mean something different?

Regards,
Kendy

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] main.xdg 2 largest sections not needed on startup?

2010-11-25 Thread Sebastian Spaeth
Hi all, after looking at kcachegrind for a while, I found that a
significant amount of our startuptime comes from allocating string
memory and comparing strings 400k times, much of it reading the
configuration files. I just looked at the .xcd files now and of that I
focused on main.xcd because this is likely to be read in on every app
start and is by far the biggest .xcd file.

Here is a breakdown of all xml sections with their LOC count (as
determined by xmllint --format). Each name has a component-data and a
component-scheme section it seems, I have not merged them. Anyway, the 2
biggest contenders are perhaps not even needed there.

File basis3.3/share/registry/main.xcd: total 63014 lines:

The 2 biggest sections are:
Labels 14345 + 11 lines (defining label sizes for printing envelope labels)
TableWizard 8666 + 26 lines

These make 1/3 of main.xdg, are both needed on startup or can those be
put into a different file that is only read when it is really needed?

Sebastian

Breakdown follows:

14345 oor:component-data 
xmlns:install=http://openoffice.org/2004/installation; oor:name=Labels 
oor:package=org.openoffice.Office
8666 oor:component-data 
xmlns:install=http://openoffice.org/2004/installation; oor:name=TableWizard 
oor:package=org.openoffice.Office
8539 oor:component-data 
xmlns:install=http://openoffice.org/2004/installation; oor:name=VCL 
oor:package=org.openoffice
5414 oor:component-data 
xmlns:install=http://openoffice.org/2004/installation; 
oor:name=GenericCommands oor:package=org.openoffice.Office.UI
5305 oor:component-data 
xmlns:install=http://openoffice.org/2004/installation; oor:name=Accelerators 
oor:package=org.openoffice.Office
1854 oor:component-data 
xmlns:install=http://openoffice.org/2004/installation; 
oor:name=DrawImpressCommands oor:package=org.openoffice.Office.UI
1618 oor:component-schema oor:name=Common 
oor:package=org.openoffice.Office xml:lang=en-US
1478 oor:component-schema oor:name=Writer 
oor:package=org.openoffice.Office xml:lang=en-US
1447 oor:component-data 
xmlns:install=http://openoffice.org/2004/installation; oor:name=WebWizard 
oor:package=org.openoffice.Office
969 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=Math oor:package=org.openoffice.Office
785 oor:component-data oor:package=org.openoffice.TypeDetection 
oor:name=GraphicFilter
659 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=Writer oor:package=org.openoffice.Office
653 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=DataAccess oor:package=org.openoffice.Office
609 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=ChartCommands oor:package=org.openoffice.Office.UI
595 oor:component-data oor:package=org.openoffice.TypeDetection 
oor:name=Types
522 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=DbuCommands oor:package=org.openoffice.Office.UI
471 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=Controller oor:package=org.openoffice.Office.UI
448 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=Security oor:package=org.openoffice.Office
389 oor:component-schema oor:name=Calc oor:package=org.openoffice.Office 
xml:lang=en-US
372 oor:component-schema oor:name=Impress 
oor:package=org.openoffice.Office xml:lang=en-US
323 oor:component-schema oor:name=DataAccess 
oor:package=org.openoffice.Office xml:lang=en-US
320 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=Setup oor:package=org.openoffice
316 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=Inet oor:package=org.openoffice
274 oor:component-schema oor:name=Draw oor:package=org.openoffice.Office 
xml:lang=en-US
245 oor:component-schema oor:name=WriterWeb 
oor:package=org.openoffice.Office xml:lang=en-US
238 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=Accelerators oor:package=org.openoffice.Office
230 oor:component-data oor:name=Drivers 
oor:package=org.openoffice.Office.DataAccess
227 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=UI oor:package=org.openoffice.Office
216 oor:component-schema oor:name=UI oor:package=org.openoffice.Office 
xml:lang=en-US
194 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=Calc oor:package=org.openoffice.Office
191 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=StartModuleCommands oor:package=org.openoffice.Office.UI
186 oor:component-schema oor:name=Math oor:package=org.openoffice.Office 
xml:lang=en-US
186 oor:component-data oor:name=Drivers 
oor:package=org.openoffice.Office.DataAccess
176 oor:component-data xmlns:install=http://openoffice.org/2004/installation; 
oor:name=Configuration 

Re: [Libreoffice] warnig and coding, need a little help on C++

2010-11-25 Thread Caolán McNamara
On Thu, 2010-11-25 at 19:41 +0100, Pierre-André Jacquod wrote:
 {
  sal_Int8 nTemp;
  rVal = nTemp;
  if(nTemp =1  nTemp  0x7f
  nLines = (BYTE)nTemp;
 }
 
 Well, that's fine for me, nTemp is effectively not initialized. And the
 second line is then the same as: rVal = rVal  nTemp
 
 In my understanding, since nTemps is not initialized, if the compiler is
 nice, nTemp is then defaulted to 0 (or NULL). Then rVal = rVal  0 make
 not a lot of sense

 OK, now the question: what did I missed ?

Heh, this also confuses cppcheck as well. rVal is an Any and there is
an overloaded operator = which operates on that Any and nTemp. So
its not anything to do with bit shifting. Read it like...

rVal.ExtractTo(nTemp)

Now, if = fails it leaves nTemp untouched. So the general fix is
indeed to initialize nTemp to 0 to clear the warning.

C.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [PUSHED] Clean code at writer [source/ui]

2010-11-25 Thread Kayo Hamid
I can't see the commit at cgit, where is? I want to see the changes to improve 
my skills, see the changes. What wrong I'm doing? Better, what are wrong remove?
revol_


Pushed with some changes.

D.



  ___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [Patch] cppcheck, Memory leak: fallback in shell/source/unix/misc/gnome-open-url.c

2010-11-25 Thread Julien Nabet

Hello,

Here's a small patch for shell/source/unix/misc/gnome-open-url.c

Julien.
(LGPLv3+ / MPL)
commit 6b768a031280d0c3ad23624dd3a6470c57395a56
Author: serval ser...@ilapharm.com
Date:   Thu Nov 25 23:26:39 2010 +0100

correct cppcheck, Memory leak: fallback

diff --git a/shell/source/unix/misc/gnome-open-url.c 
b/shell/source/unix/misc/gnome-open-url.c
index 69cd837..9ee106b 100644
--- a/shell/source/unix/misc/gnome-open-url.c
+++ b/shell/source/unix/misc/gnome-open-url.c
@@ -139,6 +139,7 @@ int main(int argc, char *argv[] )
 args[2] = NULL;
 return execv(fallback, args);
 }
+free(fallback);
 
 return -1;  
 }
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH] run-libreoffice-ciabot: avoid flood on merges

2010-11-25 Thread Miklos Vajna
Hi Kendy,

I'm attaching a patch that updates the cia bot so that you don't need to
manually disable it on each merge. ;)

OK to push? (More importantly, if I push it, it would be nice if you
could restart the bot, as I guess that's not automatic. :) )

Thanks.
From 53a5563a0b4df6a45d73bc80be6927b06556e573 Mon Sep 17 00:00:00 2001
From: Miklos Vajna vmik...@frugalware.org
Date: Fri, 26 Nov 2010 01:27:46 +0100
Subject: [PATCH] run-libreoffice-ciabot: avoid flood on merges

Check if the last hash is a merge commit: if yes, then just announce the
last one, otherwise do the usual announce any commit since the last
one dance.
---
 scratch/cia/run-libreoffice-ciabot.pl |   26 +-
 1 files changed, 17 insertions(+), 9 deletions(-)

diff --git a/scratch/cia/run-libreoffice-ciabot.pl 
b/scratch/cia/run-libreoffice-ciabot.pl
index bc8c0aa..0c6f892 100644
--- a/scratch/cia/run-libreoffice-ciabot.pl
+++ b/scratch/cia/run-libreoffice-ciabot.pl
@@ -44,16 +44,24 @@ sub report($$$) {
 
 if ( defined( $old_head ) ) {
 if ( $old_head ne $new_head ) {
-if ( open COMMITS, git rev-list $new_head ^$old_head | tac | 
) {
-while ( COMMITS ) {
-chomp;
-print Sending report about $_ in $key\n;
-qx(libreoffice-ciabot.pl $repo $_ $branch_name)
+my $ret = system(git rev-parse -q --verify $new_head^2 
/dev/null);
+if ($ret != 0) {
+# not a merge commit, announce every commit
+if ( open COMMITS, git rev-list $new_head ^$old_head | 
tac | ) {
+while ( COMMITS ) {
+chomp;
+print Sending report about $_ in $key\n;
+qx(libreoffice-ciabot.pl $repo $_ $branch_name)
+}
+close COMMITS;
 }
-close COMMITS;
-}
-else {
-error( Cannot call git rev-list. );
+else {
+error( Cannot call git rev-list. );
+}
+} else {
+# just process the merge commit itself
+print Sending report about $new_head in $key\n;
+qx(libreoffice-ciabot.pl $repo $new_head $branch_name)
 }
 }
 }
-- 
1.7.3.2



pgpLxiTAJhV9T.pgp
Description: PGP signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] C++0x and LibreOffice

2010-11-25 Thread René Kjellerup
Well, the version 4.4.3 of gcc on my system seems to support it.

One way to see when it's available would be to look up gcc's documentation
in the changelog for the 4.4.x series

I took a quick look at gnu's web site and found this:
http://gcc.gnu.org/projects/cxx0x.html

(looks like a little of the C++0x is available as early as 4.3)

kr
René

sent from my phone
On Nov 25, 2010 9:26 PM, Caolán McNamara caol...@redhat.com wrote:
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Fwd: Extensions code cleanup with patch

2010-11-25 Thread David Tardon
On Thu, Nov 25, 2010 at 10:15:52PM +0200, Roth Robert wrote:
 -- Forwarded message --
 From: Roth Robert robert.roth@gmail.com
 Date: Thu, Nov 25, 2010 at 9:27 PM
 Subject: Extensions code cleanup
 To: libreoffice@lists.freedesktop.org
 
 
 Some more dead code and bogus comments removed from extensions. The license,
 as always is LGPLv3+ / MPL.

 --- a/extensions/source/ole/unotypewrapper.hxx
 +++ b/extensions/source/ole/unotypewrapper.hxx
 @@ -36,7 +36,7 @@
  #define _WIN32_WINNT 0x0403
  #define _WIN32_DCOM
  #if OSL_DEBUG_LEVEL  0
 -//#define _ATL_DEBUG_INTERFACES
 +
  #endif
  #include atlbase.h
  extern CComModule _Module;

I've done

-#if OSL_DEBUG_LEVEL  0
-//#define _ATL_DEBUG_INTERFACES
+#if OSL_DEBUG_LEVEL  2
+#define _ATL_DEBUG_INTERFACES

instead. No reason the debugging shouldn't be available when someone
needs it.

D.
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH 1/9] suppress warning in binfilters sc_token

2010-11-25 Thread Pierre-André Jacquod
Hello,
here some patches in binfilter to remove warnings by compiling...
Since some changes could (will) look strange, I submit it in little
chunks, often with compiler warning in comment. This may help the reviewer.

Hope I did no mistake
regards
Pierre-André
From c747a9dcc4af190aac1f216a93f7abd4b39fec85 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch
Date: Tue, 23 Nov 2010 07:46:54 +0100
Subject: [PATCH 1/9] suppress warning in binfilters sc_token

changes based on following warnings:

sc_token.cxx:1573:28: warning: comparison is always false due to limited range of data type
sc_token.cxx:452:12: warning: unused parameter 'n'
sc_token.cxx:452:12: warning: unused parameter 'rPos'
sc_token.cxx:452:12: warning: unused parameter 'rPos'
sc_token.cxx:452:12: warning: unused parameter 'n'
sc_token.cxx:1613:26: warning: declaration of 'r' shadows a previous local
sc_token.cxx:1593:25: warning: shadowed declaration is here
---
 binfilter/bf_sc/source/core/tool/sc_token.cxx |   45 ++---
 1 files changed, 18 insertions(+), 27 deletions(-)

diff --git a/binfilter/bf_sc/source/core/tool/sc_token.cxx b/binfilter/bf_sc/source/core/tool/sc_token.cxx
index fe98c35..0bfad52 100644
--- a/binfilter/bf_sc/source/core/tool/sc_token.cxx
+++ b/binfilter/bf_sc/source/core/tool/sc_token.cxx
@@ -449,7 +449,7 @@ namespace binfilter {
 /*N*/ 	return 0;
 /*N*/ }
 
-/*N*/ void ScToken::SetByte( BYTE n )
+/*N*/ void ScToken::SetByte( BYTE /*n*/ )
 /*N*/ {
 /*N*/  DBG_ERRORFILE( ScToken::SetByte: virtual dummy called );
 /*N*/ }
@@ -502,12 +502,12 @@ namespace binfilter {
 /*N*/  	return aDummySingleRef;
 /*N*/  }
 
-/*N*/ void ScToken::CalcAbsIfRel( const ScAddress rPos )
+/*N*/ void ScToken::CalcAbsIfRel( const ScAddress /*rPos*/ )
 /*N*/ {
 /*N*/ 	DBG_ERRORFILE( ScToken::CalcAbsIfRel: virtual dummy called );
 /*N*/ }
 
-/*N*/ void ScToken::CalcRelFromAbs( const ScAddress rPos )
+/*N*/ void ScToken::CalcRelFromAbs( const ScAddress /*rPos*/ )
 /*N*/ {
 /*N*/ 	DBG_ERRORFILE( ScToken::CalcRelFromAbs: virtual dummy called );
 /*N*/ }
@@ -524,7 +524,7 @@ namespace binfilter {
 /*N*/ 	return 0;
 /*N*/ }
 
-/*N*/  void ScToken::SetIndex( USHORT n )
+/*N*/  void ScToken::SetIndex( USHORT /*n*/ )
 /*N*/  {
 /*N*/  	DBG_ERRORFILE( ScToken::SetIndex: virtual dummy called );
 /*N*/  }
@@ -1570,16 +1570,7 @@ namespace binfilter {
 /*N*/ 		{
 /*N*/ 			sal_Char c[ MAXSTRLEN+1 ];
 /*N*/ 			rStream  n;
-/*N*/ 			if( n  MAXSTRLEN-1 )
-/*N*/ 			{
-/*?*/ DBG_ERRORFILE( bad string array boundary );
-/*?*/ USHORT nDiff = n - (MAXSTRLEN-1);
-/*?*/ n = MAXSTRLEN-1;
-/*?*/ rStream.Read( c, n );
-/*?*/ rStream.SeekRel( nDiff );
-/*N*/ 			}
-/*N*/ 			else
-/*N*/ rStream.Read( c, n );
+/*N*/ 			rStream.Read( c, n );
 /*N*/ 			cStr[ n ] = 0;
 /*N*/ 			CharSet eSrc = rStream.GetStreamCharSet();
 /*N*/ 			for ( BYTE j=0; jn; j++ )
@@ -1590,10 +1581,10 @@ namespace binfilter {
 /*N*/ 		case svSingleRef:
 /*N*/ 		case svDoubleRef:
 /*N*/ 		{
-/*N*/ 			SingleRefData r = aRef.Ref1;
-/*N*/ 			rStream  r.nCol
-/*N*/ 	 r.nRow
-/*N*/ 	 r.nTab
+/*N*/ 			SingleRefData r1 = aRef.Ref1;
+/*N*/ 			rStream  r1.nCol
+/*N*/ 	 r1.nRow
+/*N*/ 	 r1.nTab
 /*N*/ 	 n;
 /*N*/ 			if ( nVer  SC_RELATIVE_REFS )
 /*N*/ 			{
@@ -1602,18 +1593,18 @@ namespace binfilter {
 /*N*/ aBools.bRelRow = ( ( n  2 )  0x03 );
 /*N*/ aBools.bRelTab = ( ( n  4 )  0x03 );
 /*N*/ aBools.bOldFlag3D = ( ( n  6 )  0x03 );
-/*N*/ r.OldBoolsToNewFlags( aBools );
+/*N*/ r1.OldBoolsToNewFlags( aBools );
 /*N*/ 			}
 /*N*/ 			else
-/*N*/ r.CreateFlagsFromLoadByte( n );
+/*N*/ r1.CreateFlagsFromLoadByte( n );
 /*N*/ 			if( eType == svSingleRef )
-/*N*/ aRef.Ref2 = r;
+/*N*/ aRef.Ref2 = r1;
 /*N*/ 			else
 /*N*/ 			{
-/*N*/ SingleRefData r = aRef.Ref2;
-/*N*/ rStream  r.nCol
-/*N*/ 		 r.nRow
-/*N*/ 		 r.nTab
+/*N*/ SingleRefData r2 = aRef.Ref2;
+/*N*/ rStream  r2.nCol
+/*N*/ 		 r2.nRow
+/*N*/ 		 r2.nTab
 /*N*/ 		 n;
 /*N*/ if ( nVer  SC_RELATIVE_REFS )
 /*N*/ {
@@ -1622,10 +1613,10 @@ namespace binfilter {
 /*N*/ 	aBools.bRelRow = ( ( n  2 )  0x03 );
 /*N*/ 	aBools.bRelTab = ( ( n  4 )  0x03 );
 /*N*/ 	aBools.bOldFlag3D = ( ( n  6 )  0x03 );
-/*N*/ 	r.OldBoolsToNewFlags( aBools );
+/*N*/ 	r2.OldBoolsToNewFlags( aBools );
 /*N*/ }
 /*N*/ else
-/*N*/ 	r.CreateFlagsFromLoadByte( n );
+/*N*/ 	r2.CreateFlagsFromLoadByte( n );
 /*N*/ 			}
 /*N*/ 			break;
 /*N*/ 		}
-- 
1.7.1

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH 4/9] binfilter sc_interpr4.cxx further warnings removal

2010-11-25 Thread Pierre-André Jacquod
regards
From f6202b304ca7f0ffdd16cbd2886872465273852a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch
Date: Tue, 23 Nov 2010 21:58:53 +0100
Subject: [PATCH 4/9] binfilter sc_interpr4.cxx further warnings removal

---
 binfilter/bf_sc/source/core/tool/sc_interpr4.cxx |   17 -
 1 files changed, 8 insertions(+), 9 deletions(-)

diff --git a/binfilter/bf_sc/source/core/tool/sc_interpr4.cxx b/binfilter/bf_sc/source/core/tool/sc_interpr4.cxx
index 31201a3..547d168 100644
--- a/binfilter/bf_sc/source/core/tool/sc_interpr4.cxx
+++ b/binfilter/bf_sc/source/core/tool/sc_interpr4.cxx
@@ -1358,7 +1358,7 @@ BOOL ScInterpreter::DoubleRefToPosSingleRef( const ScRange rRange, ScAddress r
 /*N*/  	{
 /*N*/  		ScBaseCell* pCell;
 /*N*/  		ScQueryCellIterator aCellIter(pDok, nTab, aQueryParam);
-/*N*/  		if (pCell = aCellIter.GetFirst())
+/*N*/  		if ( (pCell = aCellIter.GetFirst() ) )
 /*N*/  		{
 /*N*/  			if (aCellIter.GetNext())
 /*N*/  SetIllegalArgument();
@@ -1458,7 +1458,6 @@ BOOL ScInterpreter::DoubleRefToPosSingleRef( const ScRange rRange, ScAddress r
 /*?*/ 
 /*?*/ 			for (i = nParamCount; (i  0)  (nGlobalError == 0); i--)
 /*?*/ 			{
-/*?*/ BYTE nStackType = GetStackType();
 /*?*/ switch (eParamType[i])
 /*?*/ {
 /*?*/ 	case PTR_DOUBLE :
@@ -2098,14 +2097,14 @@ void ScInterpreter::ScMissing()
 /*?*/ 	{
 /*?*/ 		short nIdx[ 2 ];
 /*?*/ 		nIdx[ 0 ] = j+1;
-/*?*/ 		for( USHORT i = 0; i  nC; i++ )
+/*?*/ 		for( USHORT k = 0; k  nC; i++ )
 /*?*/ 		{
-/*?*/ 			nIdx[ 1 ] = i+1;
+/*?*/ 			nIdx[ 1 ] = k+1;
 /*?*/ 			SbxVariable* p = refArray-Get( nIdx );
-/*?*/ 			if (pMat-IsString(i, j))
-/*?*/ p-PutString( pMat-GetString(i, j) );
+/*?*/ 			if (pMat-IsString(k, j))
+/*?*/ p-PutString( pMat-GetString(k, j) );
 /*?*/ 			else
-/*?*/ p-PutDouble( pMat-GetDouble(i, j) );
+/*?*/ p-PutDouble( pMat-GetDouble(k, j) );
 /*?*/ 		}
 /*?*/ 	}
 /*?*/ 	pPar-PutObject( refArray );
@@ -3041,10 +3040,10 @@ void ScInterpreter::ScTTT()
 /*?*/ {	// Stack abraeumen, geht davon aus, dass jede Funktion
 /*?*/ 	// prinzipiell ein Ergebnis pusht, im Fehlerfall kann dies
 /*?*/ 	// ein zufaelliger Wert sein
-/*?*/ 	const ScToken* pResult = pStack[ sp - 1 ];
+/*?*/ 	const ScToken* pResult2 = pStack[ sp - 1 ];
 /*?*/ 	while ( sp  nStackBase )
 /*?*/ 		Pop();
-/*?*/ 	PushTempToken( *pResult );
+/*?*/ 	PushTempToken( *pResult2 );
 /*?*/ }
 /*N*/ 			}
 /*N*/ 		}
-- 
1.7.1

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH 5/9] waring removal in binfilter core/para

2010-11-25 Thread Pierre-André Jacquod
regards
From 01e9e819f9dd8f1726ddff7672f27cfcbd44760c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch
Date: Thu, 25 Nov 2010 20:09:15 +0100
Subject: [PATCH 5/9] waring removal in binfilter core/para

---
 binfilter/bf_sw/source/core/para/sw_paratr.cxx |   16 
 1 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/binfilter/bf_sw/source/core/para/sw_paratr.cxx b/binfilter/bf_sw/source/core/para/sw_paratr.cxx
index cb4dd70..646bb4b 100644
--- a/binfilter/bf_sw/source/core/para/sw_paratr.cxx
+++ b/binfilter/bf_sw/source/core/para/sw_paratr.cxx
@@ -104,7 +104,7 @@ using namespace ::com::sun::star;
 
 
 
-/*N*/ void SwFmtDrop::Modify( SfxPoolItem *pA, SfxPoolItem *pB )
+/*N*/ void SwFmtDrop::Modify( SfxPoolItem * /*pA*/, SfxPoolItem * /*pB*/ )
 /*N*/ {
 /*N*/ 	if( pDefinedIn )
 /*N*/ 	{
@@ -130,7 +130,7 @@ using namespace ::com::sun::star;
 
 
 
-/*N*/ sal_Bool SwFmtDrop::GetInfo( SfxPoolItem rInfo ) const
+/*N*/ sal_Bool SwFmtDrop::GetInfo( SfxPoolItem /*rInfo*/ ) const
 /*N*/ {
 /*N*/ 	// fuers UNDO: pruefe ob das Attribut wirklich in diesem Format steht
 /*N*/ #ifdef USED_30
@@ -180,7 +180,7 @@ using namespace ::com::sun::star;
 /*N*/ case MID_DROPCAP_LINES : rVal = (sal_Int16)nLines; break;
 /*N*/ case MID_DROPCAP_COUNT : rVal = (sal_Int16)nChars; break;
 /*N*/ case MID_DROPCAP_DISTANCE : rVal = (sal_Int16) TWIP_TO_MM100(nDistance); break;
-/*N*/ 		case MID_DROPCAP_FORMAT:
+/*N*/ case MID_DROPCAP_FORMAT:
 /*N*/ 		{
 /*N*/ 		 	style::DropCapFormat aDrop;
 /*N*/ 			aDrop.Lines	= nLines   ;
@@ -244,8 +244,8 @@ using namespace ::com::sun::star;
 /*N*/ nDistance 	= MM100_TO_TWIP(pDrop-Distance);
 /*N*/ 			}
 /*N*/ 			else
-/*N*/ //exception( wrong_type)
-/*N*/ ;
+/*N*/ 			{	//exception( wrong_type)
+/*N*/ 			}
 /*N*/ 		}
 /*N*/ 		break;
 /*N*/ 		case MID_DROPCAP_WHOLE_WORD:
@@ -267,14 +267,14 @@ using namespace ::com::sun::star;
 /*N*/ }
 
 // class SwNumRuleItem -
-/*N*/ SfxPoolItem* SwNumRuleItem::Clone( SfxItemPool *pPool  ) const
+/*N*/ SfxPoolItem* SwNumRuleItem::Clone( SfxItemPool * /*pPool*/  ) const
 /*N*/ {
 /*N*/ 	return new SwNumRuleItem( *this );
 /*N*/ }
 /* -27.06.00 11:05
 
  ---*/
-/*N*/ bool SwNumRuleItem::QueryValue( ::com::sun::star::uno::Any rVal, BYTE nMemberId ) const
+/*N*/ bool SwNumRuleItem::QueryValue( ::com::sun::star::uno::Any rVal, BYTE /*nMemberId*/ ) const
 /*N*/ {
 /*N*/ 	::rtl::OUString sRet = SwStyleNameMapper::GetProgName(GetValue(), GET_POOLID_NUMRULE );
 /*N*/ 	rVal = sRet;
@@ -283,7 +283,7 @@ using namespace ::com::sun::star;
 /* -27.06.00 11:05
 
  ---*/
-/*N*/ bool SwNumRuleItem::PutValue( const ::com::sun::star::uno::Any rVal, BYTE nMemberId )
+/*N*/ bool SwNumRuleItem::PutValue( const ::com::sun::star::uno::Any rVal, BYTE /*nMemberId*/ )
 /*N*/ {
 /*N*/ 	::rtl::OUString uName;
 /*N*/ 	rVal = uName;
-- 
1.7.1

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH 6/9] waring cleaning in sw_sw3redln.cxx

2010-11-25 Thread Pierre-André Jacquod
regards

From 84e58630f70dc34f71ee34419d9843980b14b723 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch
Date: Thu, 25 Nov 2010 20:18:10 +0100
Subject: [PATCH 6/9] waring cleaning in sw_sw3redln.cxx

shadowing warning and unused parameters
---
 binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx |   11 ---
 1 files changed, 4 insertions(+), 7 deletions(-)

diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx
index b0a286b..e2453f4 100644
--- a/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx
+++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx
@@ -97,8 +97,6 @@ namespace binfilter {
 /*N*/ 	{
 /*N*/ 		OpenRec( SWG_REDLINEDATA_LCL );
 /*N*/ 
-/*N*/ 		BYTE cDFlags = OpenFlagRec();
-/*N*/ 
 /*N*/ 		BYTE cType;
 /*N*/ 		UINT16 nStrIdx;
 /*N*/ 
@@ -106,10 +104,10 @@ namespace binfilter {
 /*N*/  nStrIdx;
 /*N*/ 		CloseFlagRec();
 /*N*/ 
-/*N*/ 		UINT32 nDate, nTime;
+/*N*/ 		UINT32 nDate2, nTime2;
 /*N*/ 		String aComment;
-/*N*/ 		*pStrm 	 nDate
-/*N*/  nTime;
+/*N*/ 		*pStrm 	 nDate2
+/*N*/  nTime2;
 /*N*/ 		InString( *pStrm, aComment );
 /*N*/ 
 /*N*/ 		// Das oberste Element des Stack wurde als letztes geschrieben.
@@ -120,7 +118,7 @@ namespace binfilter {
 /*N*/ 			nAuthorIdx = pDoc-GetRedlineAuthor();
 /*N*/ 
 /*N*/ 		pData =	new SwRedlineData( (SwRedlineType)cType, nAuthorIdx,
-/*N*/    DateTime( nDate, nTime ), aComment,
+/*N*/    DateTime( nDate2, nTime2 ), aComment,
 /*N*/    pData );
 /*N*/ 
 /*N*/ 		CloseRec( SWG_REDLINEDATA_LCL );
@@ -128,7 +126,6 @@ namespace binfilter {
 /*N*/ 
 /*N*/ 	// Der PaM ist erstmal egal und wird erst spaeter gesetzt
 /*N*/ 	SwPosition aDummyPos( pDoc-GetNodes().GetEndOfExtras() );
-/*N*/ 	BOOL bVisible = (cFlags  0x10) != 0;
 /*N*/ 	SwRedline *pRedline =
 /*N*/ 		new SwRedline( pData, aDummyPos, (cFlags  0x10) != 0,
 /*N*/ 	   (cFlags  0x20) != 0, (cFlags  0x40) != 0 );
-- 
1.7.1

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH 7/9] warnings removal in binfilter sw_sw3redln.cxx

2010-11-25 Thread Pierre-André Jacquod
regards
From 13a33d71df128454159d0e911f55179cddac2d72 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch
Date: Thu, 25 Nov 2010 20:52:47 +0100
Subject: [PATCH 7/9] warnings removal in binfilter sw_sw3redln.cxx

all code deletion due to compiler warning with message:

sw_sw3redln.cxx:255:25:
warning: comparison is always false due to limited range of data type
---
 binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx |   21 ++---
 1 files changed, 2 insertions(+), 19 deletions(-)

diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx
index e2453f4..2a3f9ef 100644
--- a/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx
+++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx
@@ -251,12 +251,7 @@ xub_StrLen lcl_sw3io_getNodeOff( const SwNodeIndex rNdIdx, xub_StrLen nCntntIdx
 // unbenutzte Content-Position.
 const SwNode rNode = rNdIdx.GetNode();
 if( rNode.IsCntntNode() )
-{
-if( nCntntIdx  STRING_MAXLEN52 )
-return STRING_MAXLEN52;
-else
-return nCntntIdx;
-}
+return nCntntIdx;
 
 if( rNode.IsStartNode() )
 return 0;
@@ -294,10 +289,6 @@ xub_StrLen lcl_sw3io_getNodeOff( const SwNodeIndex rNdIdx, xub_StrLen nCntntIdx
 /*?*/ 		// If the redline is within one node and starts behind the
 /*?*/ 		// last position that is possible within the 5.2 version,
 /*?*/ 		// it will be ignored.
-/*?*/ 		if( pPos-nContent.GetIndex()  STRING_MAXLEN52 
-/*?*/ 			pPos-nNode.GetIndex() == pEndPos-nNode.GetIndex() 
-/*?*/ 			pEndPos-nContent.GetIndex()  STRING_MAXLEN52 )
-/*?*/ 			continue;
 /*?*/ 
 /*?*/ 		if( pDoc-IsInHeaderFooter( pPos-nNode ) )
 /*?*/ 		{
@@ -457,7 +448,7 @@ xub_StrLen lcl_sw3io_getNodeOff( const SwNodeIndex rNdIdx, xub_StrLen nCntntIdx
 /*N*/ 		xub_StrLen nLen = rNode.GetCntntNode()-Len();
 /*N*/ 		xub_StrLen nIdx = static_cast xub_StrLen ( nNodeOff+nCntntOff );
 /*N*/ 		ASSERT( nIdx=0  nIdx=nLen, ungueltiger Cntnt-Offset );
-/*N*/ 		if( nIdx0 || nIdx  nLen )
+/*N*/ 		if( nIdx  nLen )
 /*N*/ 		{
 /*N*/ 			bInvalid = sal_True;
 /*N*/ 		}
@@ -635,14 +626,6 @@ xub_StrLen lcl_sw3io_getNodeOff( const SwNodeIndex rNdIdx, xub_StrLen nCntntIdx
 /*?*/ else if( pContentIdx )
 /*?*/ 	cFlags |= 0x20;
 /*?*/ 
-/*?*/ xub_StrLen nOffs = pMark-GetNodeOff();
-/*?*/ if( pDoc-GetNodes()[nIdx]-IsCntntNode() 
-/*?*/ 	nOffs  STRING_MAXLEN52 )
-/*?*/ 	nOffs = STRING_MAXLEN52;
-/*?*/ *pStrm   (BYTE)  cFlags
-/*?*/ 		 (UINT16)pMark-GetId()
-/*?*/ 		 (UINT16)nOffs;
-/*?*/ 
 /*?*/ if( pContentIdx )
 /*?*/ {
 /*?*/ 	ASSERT( pContentIdx-GetNode().EndOfSectionIndex() -
-- 
1.7.1

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [PATCH 3/9] warnings in binfilters sc_interpr4.cxx

2010-11-25 Thread Jonathan Aquilina
Quick question wouldn't it be better to have the comments in English 
instead of German?

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH 9/9] binfilter sw3io warning fixes

2010-11-25 Thread Pierre-André Jacquod
regards

From d8ca0db19fdc508ebc0bf0ee42107fdea2f498b1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch
Date: Thu, 25 Nov 2010 21:10:27 +0100
Subject: [PATCH 9/9] binfilter sw3io  warning fixes

use of not initialized variables
---
 binfilter/bf_sw/source/core/sw3io/sw_sw3fmts.cxx |   20 ++--
 1 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3fmts.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3fmts.cxx
index 16c641a..3606f9b 100644
--- a/binfilter/bf_sw/source/core/sw3io/sw_sw3fmts.cxx
+++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3fmts.cxx
@@ -310,7 +310,7 @@ sal_Bool lcl_sw3io_insFtn( const SwTxtNode *pTxtNd )
 /*N*/ 	if( rSet.Count() )
 /*N*/ 	{
 /*N*/ 		// Beim 3.1 Export den aktuellen Attrset merken
-/*N*/ 		const SfxItemSet *pOldExportItemSet;
+/*N*/ 		const SfxItemSet *pOldExportItemSet = NULL;
 /*N*/ 		if( pExportInfo )
 /*N*/ 		{
 /*N*/ 			pOldExportItemSet = pExportInfo-pItemSet;
@@ -938,21 +938,21 @@ sal_Bool lcl_sw3io_insFtn( const SwTxtNode *pTxtNd )
 /*N*/ 	if( bWriteName )
 /*N*/ 		OutString( *pStrm, rFmt.GetName() );
 /*N*/ 
-/*N*/ 	BOOL bOldExportFlyFrmFmt;
-/*N*/ 	const SwFlyFrm* pOldExportFlyFrm;
 /*N*/ 	if( pExportInfo )
 /*N*/ 	{
-/*N*/ 		bOldExportFlyFrmFmt = pExportInfo-bFlyFrmFmt;
-/*N*/ 		pOldExportFlyFrm = pExportInfo-pFlyFrm;
+/*N*/ 		BOOL bOldExportFlyFrmFmt = pExportInfo-bFlyFrmFmt;
+/*N*/ 		const SwFlyFrm* pOldExportFlyFrm = pExportInfo-pFlyFrm;
 /*N*/ 		pExportInfo-bFlyFrmFmt = (cType == SWG_FLYFMT);
 /*N*/ 		pExportInfo-pFlyFrm = pExportFlyFrm;
-/*N*/ 	}
-/*N*/ 	OutAttrSet( rFmt.GetAttrSet(), SWG_SECTFMT == cType );
-/*N*/ 	if( pExportInfo )
-/*N*/ 	{
+OutAttrSet( rFmt.GetAttrSet(), SWG_SECTFMT == cType );
 /*N*/ 		pExportInfo-bFlyFrmFmt = bOldExportFlyFrmFmt;
 /*N*/ 		pExportInfo-pFlyFrm = pOldExportFlyFrm;
+
 /*N*/ 	}
+else
+{
+/*N*/ 	OutAttrSet( rFmt.GetAttrSet(), SWG_SECTFMT == cType );
+}
 /*N*/ 	CloseRec( cType );
 /*N*/ 	if( cType != SWG_FREEFMT  cType != SWG_SECTFMT )
 /*N*/ 		((SwFmt)rFmt).SetWritten();
@@ -1103,7 +1103,7 @@ sal_Bool lcl_sw3io_insFtn( const SwTxtNode *pTxtNd )
 
 extern BOOL TstFlyRange( const SwPaM* pPam, const SwIndex rFlyPos );
 
-/*N*/ void Sw3IoImp::CollectFlyFrms( const SwPaM* pPaM )
+/*N*/ void Sw3IoImp::CollectFlyFrms( const SwPaM* /*pPaM*/ )
 /*N*/ {
 /*N*/ 	if( !pFlyFrms )
 /*N*/ 	{
-- 
1.7.1

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [PATCH 3/9] warnings in binfilters sc_interpr4.cxx

2010-11-25 Thread Pierre-André Jacquod
 Quick question wouldn't it be better to have the comments in English
 instead of German?
Sorry, !! I translate then when I can, but I did not the job to the
end for this one.
Not_appropriate_handling_for_me++
regards
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] warnig and coding, need a little help on C++

2010-11-25 Thread Pierre-André Jacquod
Thanks for helping.

 Heh, this also confuses cppcheck as well. 
cough... cough... ! I am not smarter than a machine... ! A professor I
had told: this not a good point being too smart... I understand what he
meant.

For stepping in, not the easiest way. Once there is no waring any more
when compiling, let start hacking to remove the overloaded operator and
replace it through more instinctive function call ::--)) /joke


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice