[Libreoffice-commits] core.git: ios/Executable_Viewer.mk

2013-03-22 Thread Tor Lillqvist
 ios/Executable_Viewer.mk |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 66ac0a5beb7178df42232cc8a96ba69169ea965b
Author: Tor Lillqvist t...@iki.fi
Date:   Fri Mar 22 08:24:05 2013 +0200

Try to make the tinderbox build succeed

Change-Id: Iae0b134d9579dcaaa39ce8a99e843fe24c27060a

diff --git a/ios/Executable_Viewer.mk b/ios/Executable_Viewer.mk
index edfc498..79a5aa9 100644
--- a/ios/Executable_Viewer.mk
+++ b/ios/Executable_Viewer.mk
@@ -40,6 +40,8 @@ $(eval $(call gb_Executable_add_objcobjects,Viewer,\
 # executable is.
 $(eval $(call gb_Executable_use_libraries,Viewer,\
msword \
+   sal \
+   sc \
scfilt \
sdfilt \
swui \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: officecfg/registry

2013-03-22 Thread Thomas Arnhold
 officecfg/registry/data/org/openoffice/Office/UI.xcu | 
   1 
 officecfg/registry/data/org/openoffice/Office/UI/BasicIDEWindowState.xcu | 
   1 
 officecfg/registry/data/org/openoffice/Office/UI/DbuCommands.xcu | 
   1 
 officecfg/registry/data/org/openoffice/Office/UI/DrawImpressCommands.xcu | 
  22 -
 officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu | 
  26 ---
 officecfg/registry/data/org/openoffice/Office/UI/WriterFormWindowState.xcu   | 
  37 --
 officecfg/registry/data/org/openoffice/Office/UI/WriterReportWindowState.xcu | 
  37 --
 officecfg/registry/data/org/openoffice/Office/UI/XFormsWindowState.xcu   | 
  37 --
 8 files changed, 162 deletions(-)

New commits:
commit 0e49bd05eef97ddd25a5657cdd5fb277a2a86014
Author: Thomas Arnhold tho...@arnhold.org
Date:   Fri Mar 22 03:13:15 2013 +0100

officecfg: remove translated strings

Change-Id: Ie8d5e04556dc73213e972969d7dd7461799cd396
Reviewed-on: https://gerrit.libreoffice.org/2905
Reviewed-by: Andras Timar ati...@suse.com
Tested-by: Andras Timar ati...@suse.com

diff --git a/officecfg/registry/data/org/openoffice/Office/UI.xcu 
b/officecfg/registry/data/org/openoffice/Office/UI.xcu
index 6d924b8..44fd486 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI.xcu
@@ -87,7 +87,6 @@
 node oor:name=com.sun.star.sdb.OfficeDatabaseDocument 
oor:op=replace
 prop oor:name=DisplayName
 
-value xml:lang=enDatabase Documents/value
 value xml:lang=en-USDatabase documents/value
 /prop
 prop oor:name=Filters
diff --git 
a/officecfg/registry/data/org/openoffice/Office/UI/BasicIDEWindowState.xcu 
b/officecfg/registry/data/org/openoffice/Office/UI/BasicIDEWindowState.xcu
index a69cc7d..35f95f0 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/BasicIDEWindowState.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/BasicIDEWindowState.xcu
@@ -71,7 +71,6 @@
 /prop
 prop oor:name=UIName oor:type=xs:string
 value xml:lang=en-USDialog/value
-value xml:lang=deDialog/value
 /prop
 prop oor:name=Visible oor:type=xs:boolean
 valuetrue/value
diff --git a/officecfg/registry/data/org/openoffice/Office/UI/DbuCommands.xcu 
b/officecfg/registry/data/org/openoffice/Office/UI/DbuCommands.xcu
index 4445a4c..9a5873f 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/DbuCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/DbuCommands.xcu
@@ -502,7 +502,6 @@
 /node
 node oor:name=.uno:DBNewReport oor:op=replace
 prop oor:name=Label oor:type=xs:string
-value xml:lang=deBericht.../value
 value xml:lang=en-USReport.../value
 /prop
 prop oor:name=Properties oor:type=xs:int
diff --git 
a/officecfg/registry/data/org/openoffice/Office/UI/DrawImpressCommands.xcu 
b/officecfg/registry/data/org/openoffice/Office/UI/DrawImpressCommands.xcu
index e1fe537..58013bd 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/DrawImpressCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/DrawImpressCommands.xcu
@@ -1859,7 +1859,6 @@
 
   node oor:name=.uno:MergeCells oor:op=replace
 prop oor:name=Label oor:type=xs:string
-  value xml:lang=deZellen verbinden/value
   value xml:lang=en-USMerge Cells/value
 /prop
 prop oor:name=Properties oor:type=xs:int
@@ -1868,7 +1867,6 @@
   /node
   node oor:name=.uno:SplitCell oor:op=replace
 prop oor:name=Label oor:type=xs:string
-  value xml:lang=deZelle teilen/value
   value xml:lang=en-USSplit Cells/value
 /prop
 prop oor:name=Properties oor:type=xs:int
@@ -1877,7 +1875,6 @@
   /node
   node oor:name=.uno:OptimizeTable oor:op=replace
 prop oor:name=Label oor:type=xs:string
-  value xml:lang=deOptimieren/value
   value xml:lang=en-USOptimize/value
 /prop
 prop oor:name=Properties oor:type=xs:int
@@ -1902,7 +1899,6 @@
   /node
   node oor:name=.uno:CellVertBottom oor:op=replace
 prop oor:name=Label oor:type=xs:string
-  value xml:lang=deUnten/value
   value xml:lang=en-USBottom/value
 /prop
 prop oor:name=Properties oor:type=xs:int
@@ -1911,7 +1907,6 @@
   /node
   node oor:name=.uno:CellVertCenter oor:op=replace
 prop oor:name=Label oor:type=xs:string
-  value xml:lang=deMittig (vertikal)/value
   value xml:lang=en-USCenter ( vertical )/value
 /prop
 prop oor:name=Properties oor:type=xs:int
@@ -1920,7 +1915,6 @@
   /node
 

[PUSHED] officecfg: remove translated strings

2013-03-22 Thread Andras Timar (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2905

Approvals:
  Andras Timar: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2905
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie8d5e04556dc73213e972969d7dd7461799cd396
Gerrit-PatchSet: 3
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Thomas Arnhold tho...@arnhold.org
Gerrit-Reviewer: Andras Timar ati...@suse.com

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


[Libreoffice-commits] core.git: jvmfwk/source

2013-03-22 Thread Tor Lillqvist
 jvmfwk/source/framework.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 55e95d1dcbfd155566bb9d7879d9a4a39b9a2cd7
Author: Tor Lillqvist t...@iki.fi
Date:   Fri Mar 22 08:25:43 2013 +0200

warning: unknown log area 'jvmfwk' [loplugin]

This is not a warning that would stop an --enable-werror build, but still
worth fixing.

Change-Id: I6c47fd636f57f55cbe406f51e2f24e015924ce14

diff --git a/jvmfwk/source/framework.cxx b/jvmfwk/source/framework.cxx
index b4dde95..ac9f59d 100644
--- a/jvmfwk/source/framework.cxx
+++ b/jvmfwk/source/framework.cxx
@@ -460,7 +460,7 @@ javaFrameworkError SAL_CALL jfw_startVM(
 
 //start Java
 JavaVM *pVm = NULL;
-SAL_INFO(jvmfwk, starting java);
+SAL_INFO(jfw, Starting Java);
 javaPluginError plerr = (*pFunc)(pInfo, arOpt, index,  pVm, ppEnv);
 if (plerr == JFW_PLUGIN_E_VM_CREATION_FAILED)
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: dbaccess/source

2013-03-22 Thread Mathias Hasselmann
 dbaccess/source/ui/dlg/dbwizsetup.cxx |   32 
 1 file changed, 16 insertions(+), 16 deletions(-)

New commits:
commit eca62e11db6d721dd4518ed66169069b5edf64e0
Author: Mathias Hasselmann math...@openismus.com
Date:   Fri Mar 22 00:16:08 2013 +0100

Use initialization list for ODbTypeWizDialogSetup

Some members got initialized by assignment instead of initialization
list without need. A refactoring artifact most likely.

Change-Id: I6b1d4036a24bd26443ce7c6e44e51d08b8b83b20
Reviewed-on: https://gerrit.libreoffice.org/2903
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/dbaccess/source/ui/dlg/dbwizsetup.cxx 
b/dbaccess/source/ui/dlg/dbwizsetup.cxx
index cb53dfd..d5f2973 100644
--- a/dbaccess/source/ui/dlg/dbwizsetup.cxx
+++ b/dbaccess/source/ui/dlg/dbwizsetup.cxx
@@ -133,27 +133,27 @@ ODbTypeWizDialogSetup::ODbTypeWizDialogSetup(Window* 
_pParent
 , m_bApplied(sal_False)
 , m_bUIEnabled( sal_True )
 , m_bIsConnectable( sal_False)
-, m_sRM_IntroText(ModuleRes(STR_PAGETITLE_INTROPAGE))
-, m_sRM_dBaseText(ModuleRes(STR_PAGETITLE_DBASE))
-, m_sRM_TextText(ModuleRes(STR_PAGETITLE_TEXT))
-, m_sRM_MSAccessText(ModuleRes(STR_PAGETITLE_MSACCESS))
-, m_sRM_LDAPText(ModuleRes(STR_PAGETITLE_LDAP))
-, m_sRM_ADOText(ModuleRes(STR_PAGETITLE_ADO))
-, m_sRM_JDBCText(ModuleRes(STR_PAGETITLE_JDBC))
-, m_sRM_MySQLNativePageTitle(ModuleRes(STR_PAGETITLE_MYSQL_NATIVE))
+, m_sRM_IntroText( ModuleRes( STR_PAGETITLE_INTROPAGE ) )
+, m_sRM_dBaseText( ModuleRes( STR_PAGETITLE_DBASE ) )
+, m_sRM_TextText( ModuleRes( STR_PAGETITLE_TEXT ) )
+, m_sRM_MSAccessText( ModuleRes( STR_PAGETITLE_MSACCESS ) )
+, m_sRM_LDAPText( ModuleRes( STR_PAGETITLE_LDAP ) )
+, m_sRM_ADOText( ModuleRes( STR_PAGETITLE_ADO ) )
+, m_sRM_JDBCText( ModuleRes( STR_PAGETITLE_JDBC ) )
+, m_sRM_MySQLNativePageTitle( ModuleRes( STR_PAGETITLE_MYSQL_NATIVE ) )
+, m_sRM_OracleText( ModuleRes( STR_PAGETITLE_ORACLE ) )
+, m_sRM_MySQLText( ModuleRes( STR_PAGETITLE_MYSQL ) )
+, m_sRM_ODBCText( ModuleRes( STR_PAGETITLE_ODBC ) )
+, m_sRM_SpreadSheetText( ModuleRes( STR_PAGETITLE_SPREADSHEET ) )
+, m_sRM_AuthentificationText( ModuleRes( STR_PAGETITLE_AUTHENTIFICATION ) )
+, m_sRM_FinalText( ModuleRes( STR_PAGETITLE_FINAL ) )
+, m_sWorkPath( SvtPathOptions().GetWorkPath() )
 , m_pGeneralPage( NULL )
-, m_pMySQLIntroPage(NULL)
+, m_pMySQLIntroPage( NULL )
 , m_pCollection( NULL )
 {
 DBG_CTOR(ODbTypeWizDialogSetup,NULL);
 // no local resources needed anymore
-m_sRM_MySQLText = String(ModuleRes(STR_PAGETITLE_MYSQL));
-m_sRM_OracleText = String(ModuleRes(STR_PAGETITLE_ORACLE));
-m_sRM_ODBCText = String(ModuleRes(STR_PAGETITLE_ODBC));
-m_sRM_SpreadSheetText = String(ModuleRes(STR_PAGETITLE_SPREADSHEET));
-m_sRM_AuthentificationText = 
String(ModuleRes(STR_PAGETITLE_AUTHENTIFICATION));
-m_sRM_FinalText = String(ModuleRes(STR_PAGETITLE_FINAL));
-m_sWorkPath = SvtPathOptions().GetWorkPath();
 pFinalPage = NULL;
 // extract the datasource type collection from the item set
 DbuTypeCollectionItem* pCollectionItem = PTR_CAST(DbuTypeCollectionItem, 
_pItems-GetItem(DSID_TYPECOLLECTION));
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[PUSHED] Use initialization list for ODbTypeWizDialogSetup

2013-03-22 Thread Fridrich Strba (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2903

Approvals:
  Fridrich Strba: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2903
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I6b1d4036a24bd26443ce7c6e44e51d08b8b83b20
Gerrit-PatchSet: 3
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Mathias Hasselmann math...@openismus.com
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org
Gerrit-Reviewer: Lionel Elie Mamane lio...@mamane.lu

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


[Libreoffice-commits] core.git: 9 commits - sc/qa sc/source

2013-03-22 Thread Markus Mohrhard
 sc/qa/unit/data/ods/databar.ods|binary
 sc/qa/unit/data/xlsx/databar.xlsx  |binary
 sc/qa/unit/subsequent_filters-test.cxx |  173 -
 sc/source/core/data/colorscale.cxx |7 +
 sc/source/filter/excel/xeextlst.cxx|9 +
 sc/source/ui/formdlg/formula.cxx   |8 -
 6 files changed, 80 insertions(+), 117 deletions(-)

New commits:
commit 33b0684dd721c4ee5c24d2c9b3b77974db882046
Author: Markus Mohrhard markus.mohrh...@googlemail.com
Date:   Fri Mar 22 06:58:27 2013 +0100

update the test files

Change-Id: I0285e9d6739e7f2a9882fd19f03524482128e2d2

diff --git a/sc/qa/unit/data/ods/databar.ods b/sc/qa/unit/data/ods/databar.ods
index 404f7a2..b3cb964 100644
Binary files a/sc/qa/unit/data/ods/databar.ods and 
b/sc/qa/unit/data/ods/databar.ods differ
diff --git a/sc/qa/unit/data/xlsx/databar.xlsx 
b/sc/qa/unit/data/xlsx/databar.xlsx
index c099f57..bf43cd6 100644
Binary files a/sc/qa/unit/data/xlsx/databar.xlsx and 
b/sc/qa/unit/data/xlsx/databar.xlsx differ
commit b22b7d0c675304c3c7e6b49e7e10563a2dc737c5
Author: Markus Mohrhard markus.mohrh...@googlemail.com
Date:   Fri Mar 22 06:58:02 2013 +0100

we need to copy the formula cell as well

Change-Id: If73ca17414a1aac1ce9efe5a56b0b1f499014fa0

diff --git a/sc/source/core/data/colorscale.cxx 
b/sc/source/core/data/colorscale.cxx
index e4183e7..16a8575 100644
--- a/sc/source/core/data/colorscale.cxx
+++ b/sc/source/core/data/colorscale.cxx
@@ -59,6 +59,11 @@ ScColorScaleEntry::ScColorScaleEntry(const 
ScColorScaleEntry rEntry):
 mpCell(),
 meType(rEntry.meType)
 {
+if(rEntry.mpCell)
+{
+
mpCell.reset(static_castScFormulaCell*(rEntry.mpCell-Clone(*rEntry.mpCell-GetDocument(),
 SC_CLONECELL_NOMAKEABS_EXTERNAL)));
+mpCell-StartListeningTo( mpCell-GetDocument() );
+}
 }
 
 ScColorScaleEntry::ScColorScaleEntry(ScDocument* pDoc, const 
ScColorScaleEntry rEntry):
@@ -76,6 +81,8 @@ ScColorScaleEntry::ScColorScaleEntry(ScDocument* pDoc, const 
ScColorScaleEntry
 
 ScColorScaleEntry::~ScColorScaleEntry()
 {
+if(mpCell)
+mpCell-EndListeningTo(mpCell-GetDocument());
 }
 
 void ScColorScaleEntry::SetFormula( const rtl::OUString rFormula, ScDocument* 
pDoc, const ScAddress rAddr, formula::FormulaGrammar::Grammar eGrammar )
commit 9263095cf6beb43b46a4feda359d84c66fdfd811
Author: Markus Mohrhard markus.mohrh...@googlemail.com
Date:   Fri Mar 22 06:15:07 2013 +0100

add import test for data bars

Change-Id: Ida98e51a7f9970c7d4c845f5a6ac1566cbed9e3a

diff --git a/sc/qa/unit/data/ods/databar.ods b/sc/qa/unit/data/ods/databar.ods
new file mode 100644
index 000..404f7a2
Binary files /dev/null and b/sc/qa/unit/data/ods/databar.ods differ
diff --git a/sc/qa/unit/data/xlsx/databar.xlsx 
b/sc/qa/unit/data/xlsx/databar.xlsx
new file mode 100644
index 000..c099f57
Binary files /dev/null and b/sc/qa/unit/data/xlsx/databar.xlsx differ
diff --git a/sc/qa/unit/subsequent_filters-test.cxx 
b/sc/qa/unit/subsequent_filters-test.cxx
index b2133db..2206f42 100644
--- a/sc/qa/unit/subsequent_filters-test.cxx
+++ b/sc/qa/unit/subsequent_filters-test.cxx
@@ -58,6 +58,7 @@
 #include stlsheet.hxx
 #include docfunc.hxx
 #include markdata.hxx
+#include colorscale.hxx
 
 #include com/sun/star/drawing/XDrawPageSupplier.hpp
 #include com/sun/star/drawing/XControlShape.hpp
@@ -122,6 +123,7 @@ public:
 void testDataValidityODS();
 
 void testDataBarODS();
+void testDataBarXLSX();
 void testNewCondFormatXLSX();
 
 //change this test file only in excel and not in calc
@@ -181,6 +183,7 @@ public:
 CPPUNIT_TEST(testChartImportODS);
 
 CPPUNIT_TEST(testDataBarODS);
+CPPUNIT_TEST(testDataBarXLSX);
 CPPUNIT_TEST(testNewCondFormatXLSX);
 
 CPPUNIT_TEST(testNumberFormatHTML);
@@ -1724,8 +1727,85 @@ void ScFiltersTest::testRichTextContentODS()
 xDocSh-DoClose();
 }
 
+namespace {
+
+struct FindCondFormatByEnclosingRange
+{
+FindCondFormatByEnclosingRange(const ScRange rRange):
+mrRange(rRange) {}
+
+bool operator()(const ScConditionalFormat rFormat)
+{
+if(rFormat.GetRange().Combine() == mrRange)
+return true;
+
+return false;
+}
+
+private:
+const ScRange mrRange;
+};
+
+struct DataBarData
+{
+ScRange aRange;
+ScColorScaleEntryType eLowerLimitType;
+ScColorScaleEntryType eUpperLimitType;
+databar::ScAxisPostion eAxisPosition;
+};
+
+DataBarData aData[] = {
+{ ScRange(1,2,0,1,5,0), COLORSCALE_AUTO, COLORSCALE_AUTO, 
databar::AUTOMATIC },
+{ ScRange(3,2,0,3,5,0), COLORSCALE_MIN, COLORSCALE_MAX, databar::AUTOMATIC 
},
+{ ScRange(5,2,0,5,5,0), COLORSCALE_PERCENTILE, COLORSCALE_PERCENT, 
databar::AUTOMATIC },
+{ ScRange(7,2,0,7,5,0), COLORSCALE_VALUE, COLORSCALE_FORMULA, 
databar::AUTOMATIC },
+{ ScRange(1,9,0,1,12,0), COLORSCALE_AUTO, COLORSCALE_AUTO, databar::MIDDLE 
}
+};
+
+void testDataBar_Impl(ScDocument* pDoc)
+{
+

[Libreoffice-commits] core.git: l10ntools/source

2013-03-22 Thread Zolnai Tamás
 l10ntools/source/localize.cxx |8 +++-
 1 file changed, 7 insertions(+), 1 deletion(-)

New commits:
commit 0552b4334c2fb6b130ec05934b952b60418aadca
Author: Zolnai Tamás zolnaitamas2...@gmail.com
Date:   Thu Mar 21 17:20:38 2013 +0100

Check return value of system()

Change-Id: I1b9e31b8c64ed8bf7eb073f036a7fdda39a15392

diff --git a/l10ntools/source/localize.cxx b/l10ntools/source/localize.cxx
index b608ee0..b19521a 100644
--- a/l10ntools/source/localize.cxx
+++ b/l10ntools/source/localize.cxx
@@ -284,7 +284,13 @@ void handleFilesOfDir(
 aPOStream.close();
 if( bDel )
 {
-system(OString(rm  + sPotFile).getStr());
+if ( system(OString(rm  + sPotFile).getStr()) != 0 )
+{
+cerr
+ Error: Cannot remove entryless pot file: 
+ sPotFile.getStr()  \n;
+throw false; //TODO
+}
 }
 }
 //Remove empty pot directories
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: dbaccess/source

2013-03-22 Thread Mathias Hasselmann
 dbaccess/source/ui/dlg/dbwizsetup.cxx |   20 +---
 dbaccess/source/ui/inc/dbwizsetup.hxx |3 +++
 2 files changed, 12 insertions(+), 11 deletions(-)

New commits:
commit ae88d7ec8ebea00357da345ddb6cd241112d53b8
Author: Mathias Hasselmann math...@openismus.com
Date:   Fri Mar 22 00:36:11 2013 +0100

dbwizsetup: Make pFinalPage a class member

It really should not have been a global variable.

Change-Id: I26d4b0d4736a2d026eb61149ede88f6f6ead6dfa
Reviewed-on: https://gerrit.libreoffice.org/2904
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/dbaccess/source/ui/dlg/dbwizsetup.cxx 
b/dbaccess/source/ui/dlg/dbwizsetup.cxx
index d5f2973..5b1ba07 100644
--- a/dbaccess/source/ui/dlg/dbwizsetup.cxx
+++ b/dbaccess/source/ui/dlg/dbwizsetup.cxx
@@ -113,8 +113,6 @@ using namespace ::cppu;
 #define START_PAGE  0
 #define CONNECTION_PAGE 1
 
-OFinalDBPageSetup*  pFinalPage;
-
 DBG_NAME(ODbTypeWizDialogSetup)
 //=
 //= ODbTypeWizDialogSetup
@@ -150,11 +148,11 @@ ODbTypeWizDialogSetup::ODbTypeWizDialogSetup(Window* 
_pParent
 , m_sWorkPath( SvtPathOptions().GetWorkPath() )
 , m_pGeneralPage( NULL )
 , m_pMySQLIntroPage( NULL )
+, m_pFinalPage( NULL )
 , m_pCollection( NULL )
 {
 DBG_CTOR(ODbTypeWizDialogSetup,NULL);
 // no local resources needed anymore
-pFinalPage = NULL;
 // extract the datasource type collection from the item set
 DbuTypeCollectionItem* pCollectionItem = PTR_CAST(DbuTypeCollectionItem, 
_pItems-GetItem(DSID_TYPECOLLECTION));
 if (pCollectionItem)
@@ -583,7 +581,7 @@ TabPage* ODbTypeWizDialogSetup::createPage(WizardState 
_nState)
 
 case PAGE_DBSETUPWIZARD_FINAL:
 pPage = 
OFinalDBPageSetup::CreateFinalDBTabPageSetup(this,*m_pOutSet);
-pFinalPage = static_castOFinalDBPageSetup* (pPage);
+m_pFinalPage = static_castOFinalDBPageSetup* (pPage);
 break;
 }
 
@@ -674,8 +672,8 @@ void ODbTypeWizDialogSetup::enterState(WizardState _nState)
 break;
 case PAGE_DBSETUPWIZARD_FINAL:
 enableButtons( WZB_FINISH, sal_True);
-if ( pFinalPage )
-
pFinalPage-enableTableWizardCheckBox(m_pCollection-supportsTableCreation(m_sURL));
+if ( m_pFinalPage )
+
m_pFinalPage-enableTableWizardCheckBox(m_pCollection-supportsTableCreation(m_sURL));
 break;
 }
 }
@@ -754,7 +752,7 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
 ::rtl::OUString sPath = m_pImpl-getDocumentUrl( *m_pOutSet );
 xStore-storeAsURL( sPath, aArgs.getPropertyValues() );
 
-if ( !pFinalPage || pFinalPage-IsDatabaseDocumentToBeRegistered() 
)
+if ( !m_pFinalPage || 
m_pFinalPage-IsDatabaseDocumentToBeRegistered() )
 RegisterDataSourceByLocation( sPath );
 
 return sal_True;
@@ -788,8 +786,8 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
 if ( m_pGeneralPage-GetDatabaseCreationMode() == 
OGeneralPage::eOpenExisting )
 return sal_True;
 
-if ( pFinalPage != NULL )
-return pFinalPage-IsDatabaseDocumentToBeOpened();
+if ( m_pFinalPage != NULL )
+return m_pFinalPage-IsDatabaseDocumentToBeOpened();
 
 return sal_True;
 }
@@ -800,8 +798,8 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
 if ( m_pGeneralPage-GetDatabaseCreationMode() == 
OGeneralPage::eOpenExisting )
 return sal_False;
 
-if ( pFinalPage != NULL )
-return pFinalPage-IsTableWizardToBeStarted();
+if ( m_pFinalPage != NULL )
+return m_pFinalPage-IsTableWizardToBeStarted();
 
 return sal_False;
 }
diff --git a/dbaccess/source/ui/inc/dbwizsetup.hxx 
b/dbaccess/source/ui/inc/dbwizsetup.hxx
index d04508a..5d9dd46 100644
--- a/dbaccess/source/ui/inc/dbwizsetup.hxx
+++ b/dbaccess/source/ui/inc/dbwizsetup.hxx
@@ -57,6 +57,7 @@ class ODbDataSourceAdministrationHelper;
 /** tab dialog for administrating the office wide registered data sources
 */
 class OMySQLIntroPageSetup;
+class OFinalDBPageSetup;
 
 class ODbTypeWizDialogSetup : public svt::RoadmapWizard , public 
IItemSetHelper, public IDatabaseSettingsDialog,public dbaui::OModuleClient
 {
@@ -89,6 +90,8 @@ private:
 String  m_sWorkPath;
 OGeneralPage*   m_pGeneralPage;
 OMySQLIntroPageSetup*   m_pMySQLIntroPage;
+OFinalDBPageSetup*  m_pFinalPage;
+
 ::dbaccess::ODsnTypeCollection*
 m_pCollection;  /// the DSN type collection 
instance
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[PUSHED] dbwizsetup: Make pFinalPage a class member

2013-03-22 Thread Fridrich Strba (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2904

Approvals:
  Fridrich Strba: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2904
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I26d4b0d4736a2d026eb61149ede88f6f6ead6dfa
Gerrit-PatchSet: 4
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Mathias Hasselmann math...@openismus.com
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org
Gerrit-Reviewer: Lionel Elie Mamane lio...@mamane.lu

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


Re: Build failure on master with Linux 32 bit in localize.cxx

2013-03-22 Thread Zolnai Tamás
Hi Alex,

As of last night, I'm now getting a build failure in localize.cxx with
 my build from master, both on make dev-install, and after make clean/make :


Thanks for your notice.
The problem has been solved with this commit:
http://cgit.freedesktop.org/libreoffice/core/commit/?id=0552b4334c2fb6b130ec05934b952b60418aadca

Best regards,
Tamás
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: Branch 'distro/suse/suse-3.6' - sd/source

2013-03-22 Thread Muthu Subramanian
 sd/source/ui/view/drtxtob.cxx |   22 +-
 1 file changed, 21 insertions(+), 1 deletion(-)

New commits:
commit a5fdee6020d13bba6145dcbb7b83a9ceef4a0fe7
Author: Muthu Subramanian sumu...@suse.com
Date:   Thu Mar 7 18:17:01 2013 +0530

n#657905: Display the scaled fontsize in the toolbar.

Initial set of changes to improve UX for autofit.

diff --git a/sd/source/ui/view/drtxtob.cxx b/sd/source/ui/view/drtxtob.cxx
index e124fcc..4bb15eb 100644
--- a/sd/source/ui/view/drtxtob.cxx
+++ b/sd/source/ui/view/drtxtob.cxx
@@ -54,6 +54,7 @@
 #include editeng/outlobj.hxx
 #include editeng/writingmodeitem.hxx
 #include editeng/frmdiritem.hxx
+#include editeng/fhgtitem.hxx
 
 
 #include sfx2/objface.hxx
@@ -179,6 +180,8 @@ void TextObjectBar::GetAttrState( SfxItemSet rSet )
 case SID_ATTR_CHAR_WEIGHT:
 case SID_ATTR_CHAR_POSTURE:
 {
+sal_uInt16 stretchX = 100;
+sal_uInt16 stretchY = 100;
 SvxScriptSetItem aSetItem( nSlotId, GetPool() );
 aSetItem.GetItemSet().Put( aAttrSet, sal_False );
 
@@ -189,6 +192,7 @@ void TextObjectBar::GetAttrState( SfxItemSet rSet )
 // input language should be preferred over
 // current cursor position to detect script type
 OutlinerView* pOLV = mpView-GetTextEditOutlinerView();
+SdrOutliner *pOutliner = mpView-GetTextEditOutliner();
 
 if (mpView-ISA(OutlineView))
 {
@@ -196,6 +200,9 @@ void TextObjectBar::GetAttrState( SfxItemSet rSet )
 mpViewShell-GetActiveWindow());
 }
 
+if( pOutliner )
+pOutliner-GetGlobalCharStretching( stretchX, stretchY 
);
+
 if(pOLV  !pOLV-GetSelection().HasRange())
 {
 if( mpViewShell  mpViewShell-GetViewShell()  
mpViewShell-GetViewShell()-GetWindow() )
@@ -209,9 +216,22 @@ void TextObjectBar::GetAttrState( SfxItemSet rSet )
 
 const SfxPoolItem* pI = aSetItem.GetItemOfScript( nScriptType 
);
 if( pI )
-aAttrSet.Put( *pI, nWhich );
+{
+if( nSlotId == SID_ATTR_CHAR_FONTHEIGHT )
+{
+SvxFontHeightItem aFontItem = *(dynamic_castconst 
SvxFontHeightItem *(pI));
+aFontItem.SetHeight(aFontItem.GetHeight(), stretchX, 
aFontItem.GetPropUnit());
+aAttrSet.Put( aFontItem, nWhich );
+}
+else
+{
+aAttrSet.Put( *pI, nWhich );
+}
+}
 else
+{
 aAttrSet.InvalidateItem( nWhich );
+}
 }
 break;
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: tools/source

2013-03-22 Thread Tor Lillqvist
 tools/source/fsys/comdep.hxx |2 --
 1 file changed, 2 deletions(-)

New commits:
commit edf57013463eff6d3b40d8d5d933577f0e6cf8e3
Author: Tor Lillqvist t...@iki.fi
Date:   Fri Mar 22 09:00:32 2013 +0200

SEARCHDELIM_C() was unused

Change-Id: I64432470c3d53ec58d4bfe7ce5756f44bcfa5ac8

diff --git a/tools/source/fsys/comdep.hxx b/tools/source/fsys/comdep.hxx
index 7d244a8..80cd3a0 100644
--- a/tools/source/fsys/comdep.hxx
+++ b/tools/source/fsys/comdep.hxx
@@ -25,8 +25,6 @@
 #define ACCESSDELIM_C(e)(char)\
 ( ( e == FSYS_STYLE_NTFS ) ? '\\' : '/' )
 #define SEARCHDELIM(e)  ( (e == FSYS_STYLE_BSD) ? : : ; )
-#define SEARCHDELIM_C(e)(char)\
-( (e == FSYS_STYLE_BSD) ? ':' : ';' )
 #define ACTPARENT(e)..
 #define ACTCURRENT(e)   .
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-0-2' - basic/source

2013-03-22 Thread Eike Rathke
 basic/source/sbx/sbxscan.cxx |  195 +--
 1 file changed, 117 insertions(+), 78 deletions(-)

New commits:
commit f16e95c5c86256d3c3eb017654ce229839df6584
Author: Eike Rathke er...@redhat.com
Date:   Tue Mar 19 23:23:16 2013 +0100

resolved rhbz#919020 Basic CDbl() and CSng() scan localized number

Code wrongly replaced decimal separator with '.' and used atof() to scan
the number string which itself may be localized on *iX systems but not
on Windows. Hence on *iX the numbers may had been truncated where on
Windows they were not.

Additionally made this work with Unicode separators if defined for the
locale, removed the awkward conversion to ASCII byte string and
eliminated use of toupper() and isdigit() calls. Also eliminated a
possible buffer overflow.

(cherry picked from commit 9e9f39d171cafa035d7b8e74187e25c3581cb89d)

Conflicts:
basic/source/sbx/sbxscan.cxx

replace decimal separator at correct position, rhbz#919020

(cherry picked from commit e96c7a60c88bc1e3008ebdeafd59327933d6707f)

Change-Id: I35d82e8f267ecb925783bf6f2de044a29c08f688
Reviewed-on: https://gerrit.libreoffice.org/2859
Reviewed-by: Noel Power noel.po...@suse.com
Tested-by: Noel Power noel.po...@suse.com
(cherry picked from commit 96b079e24f86f7f49a624573783c6e103012f942)
Reviewed-on: https://gerrit.libreoffice.org/2893
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Petr Mladek pmla...@suse.cz
Reviewed-by: Petr Mladek pmla...@suse.cz

diff --git a/basic/source/sbx/sbxscan.cxx b/basic/source/sbx/sbxscan.cxx
index f9a328e..b59844e 100644
--- a/basic/source/sbx/sbxscan.cxx
+++ b/basic/source/sbx/sbxscan.cxx
@@ -55,108 +55,131 @@ void ImpGetIntntlSep( sal_Unicode rcDecimalSep, 
sal_Unicode rcThousandSep )
 rcThousandSep = rData.getNumThousandSep()[0];
 }
 
+inline bool ImpIsDigit( sal_Unicode c )
+{
+return '0' = c  c = '9';
+}
+
+/** NOTE: slightly differs from strchr() in that it does not consider the
+terminating NULL character to be part of the string and returns bool
+instead of pointer, if character is 0 returns false.
+ */
+bool ImpStrChr( const sal_Unicode* p, sal_Unicode c )
+{
+if (!c)
+return false;
+while (*p)
+{
+if (*p++ == c)
+return true;
+}
+return false;
+}
+
+bool ImpIsAlNum( sal_Unicode c )
+{
+return (c  128) ? isalnum( static_castchar(c) ) : false;
+}
+
 // scanning a string according to BASIC-conventions
-// but exponent may also be a D, so data type is SbxDOUBLED
+// but exponent may also be a D, so data type is SbxDOUBLE
 // conversion error if data type is fixed and it doesn't fit
 
 SbxError ImpScan( const ::rtl::OUString rWSrc, double nVal, SbxDataType 
rType,
   sal_uInt16* pLen, bool bAllowIntntl, bool bOnlyIntntl )
 {
-::rtl::OString aBStr( ::rtl::OUStringToOString( rWSrc, 
RTL_TEXTENCODING_ASCII_US ) );
-
-char cIntntlComma, cIntntl1000;
-char cNonIntntlComma = '.';
-
-sal_Unicode cDecimalSep, cThousandSep = 0;
+sal_Unicode cIntntlDecSep, cIntntlGrpSep;
+sal_Unicode cNonIntntlDecSep = '.';
 if( bAllowIntntl || bOnlyIntntl )
 {
-ImpGetIntntlSep( cDecimalSep, cThousandSep );
-cIntntlComma = (char)cDecimalSep;
-cIntntl1000 = (char)cThousandSep;
+ImpGetIntntlSep( cIntntlDecSep, cIntntlGrpSep );
+if( bOnlyIntntl )
+cNonIntntlDecSep = cIntntlDecSep;
 }
-
 else
 {
-cIntntlComma = cNonIntntlComma;
-cIntntl1000 = cNonIntntlComma;
+cIntntlDecSep = cNonIntntlDecSep;
+cIntntlGrpSep = 0;  // no group separator accepted in non-i18n
 }
 
-if( bOnlyIntntl )
-{
-cNonIntntlComma = cIntntlComma;
-cIntntl1000 = (char)cThousandSep;
-}
-
-const char* pStart = aBStr.getStr();
-const char* p = pStart;
-char buf[ 80 ], *q = buf;
+const sal_Unicode* const pStart = rWSrc.getStr();
+const sal_Unicode* p = pStart;
+OUStringBuffer aBuf( rWSrc.getLength());
 bool bRes = true;
 bool bMinus = false;
 nVal = 0;
 SbxDataType eScanType = SbxSINGLE;
-while( *p ( *p == ' ' || *p == '\t' ) ) p++;
+while( *p == ' ' || *p == '\t' )
+p++;
 if( *p == '-' )
-p++, bMinus = true;
-if( isdigit( *p ) ||( (*p == cNonIntntlComma || *p == cIntntlComma ||
-*p == cIntntl1000)  isdigit( *(p+1 ) ) ) )
+{
+p++;
+bMinus = true;
+}
+if( ImpIsDigit( *p ) || ((*p == cNonIntntlDecSep || *p == cIntntlDecSep ||
+(cIntntlDecSep  *p == cIntntlGrpSep))  ImpIsDigit( 
*(p+1) )))
 {
 short exp = 0;
-short comma = 0;
+short decsep = 0;
 short ndig = 0;
 short ncdig = 0;// number of digits after decimal point
-rtl::OStringBuffer 

[Libreoffice-commits] core.git: Branch 'libreoffice-4-0-2' - setup_native/source

2013-03-22 Thread Stephan Bergmann
 setup_native/source/packinfo/packinfo_office.txt |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 939daba04c25a9a3b7be2f3df39692453cf9a304
Author: Stephan Bergmann sberg...@redhat.com
Date:   Thu Mar 21 15:57:18 2013 +0100

Missing dependency of librelogo on writer

...at least due to dependency of librelogo.xcd on writer.xcd, see
82c53d537a05dadf4d7fd7ea41292897bf2d47c7 Missing dependency.

Otherwise, having librelogo installed but not writer will cause an uncaught
RuntimeException from configmgr::Components::parseXcdFiles
(configmgr/source/components.cxx) early on in soffice.bin.

(cherry picked from commit 4e69b35674882d8d675a677940805b187cad0bc3)
Conflicts:
setup_native/source/packinfo/packinfo_office.txt

Change-Id: I97565fe5c790ed182bb27fd722c650acf8a8ee08
Reviewed-on: https://gerrit.libreoffice.org/2898
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Reviewed-by: Andras Timar ati...@suse.com
Reviewed-by: Petr Mladek pmla...@suse.cz
Tested-by: Petr Mladek pmla...@suse.cz

diff --git a/setup_native/source/packinfo/packinfo_office.txt 
b/setup_native/source/packinfo/packinfo_office.txt
index 3e8c89e..cbf8c490 100644
--- a/setup_native/source/packinfo/packinfo_office.txt
+++ b/setup_native/source/packinfo/packinfo_office.txt
@@ -314,10 +314,10 @@ End
 Start
 module = gid_Module_Optional_Pyuno_LibreLogo
 solarispackagename = %BASISPACKAGEPREFIX%WITHOUTDOTPRODUCTVERSION-librelogo
-solarisrequires = %BASISPACKAGEPREFIX%WITHOUTDOTPRODUCTVERSION-core01, 
SUNWPython
+solarisrequires = 
%BASISPACKAGEPREFIX%WITHOUTDOTPRODUCTVERSION-core01,%BASISPACKAGEPREFIX%WITHOUTDOTPRODUCTVERSION-writer,SUNWPython
 packagename = %BASISPACKAGEPREFIX%PRODUCTVERSION-librelogo
-freebsdrequires = %BASISPACKAGEPREFIX%PRODUCTVERSION-core01
-requires = %BASISPACKAGEPREFIX%PRODUCTVERSION-core01
+freebsdrequires = 
%BASISPACKAGEPREFIX%PRODUCTVERSION-core01,%BASISPACKAGEPREFIX%PRODUCTVERSION-writer
+requires = 
%BASISPACKAGEPREFIX%PRODUCTVERSION-core01,%BASISPACKAGEPREFIX%PRODUCTVERSION-writer
 copyright = 2012 The Document Foundation
 solariscopyright = solariscopyrightfile
 vendor = The Document Foundation
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[PUSHED libreoffice-4-0-2] resolved rhbz#919020 Basic CDbl() and CSng() scan localized ...

2013-03-22 Thread Petr Mladek (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2893

Approvals:
  Petr Mladek: Verified; Looks good to me, approved
  Fridrich Strba: Looks good to me, but someone else must approve


-- 
To view, visit https://gerrit.libreoffice.org/2893
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I35d82e8f267ecb925783bf6f2de044a29c08f688
Gerrit-PatchSet: 2
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0-2
Gerrit-Owner: Eike Rathke er...@redhat.com
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org
Gerrit-Reviewer: Noel Power noel.po...@suse.com
Gerrit-Reviewer: Petr Mladek pmla...@suse.cz

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


[PUSHED libreoffice-4-0-2] Missing dependency of librelogo on writer

2013-03-22 Thread Petr Mladek (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2898

Approvals:
  Andras Timar: Looks good to me, but someone else must approve
  Petr Mladek: Verified; Looks good to me, approved
  Fridrich Strba: Looks good to me, but someone else must approve


-- 
To view, visit https://gerrit.libreoffice.org/2898
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I97565fe5c790ed182bb27fd722c650acf8a8ee08
Gerrit-PatchSet: 2
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0-2
Gerrit-Owner: Stephan Bergmann sberg...@redhat.com
Gerrit-Reviewer: Andras Timar ati...@suse.com
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org
Gerrit-Reviewer: Petr Mladek pmla...@suse.cz

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


[Libreoffice-commits] libcdr.git: src/lib

2013-03-22 Thread Fridrich Štrba
 src/lib/CDRParser.cpp |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 67787854285459557e0bc8f89e14091da07c743e
Author: Fridrich Å trba fridrich.st...@bluewin.ch
Date:   Fri Mar 22 09:29:02 2013 +0100

Detect also uppercase  TUR postfix

diff --git a/src/lib/CDRParser.cpp b/src/lib/CDRParser.cpp
index 60c3ccb..52cea0b 100644
--- a/src/lib/CDRParser.cpp
+++ b/src/lib/CDRParser.cpp
@@ -104,6 +104,8 @@ static void processNameForEncoding(WPXString name, 
unsigned short encoding)
 encoding = 0xa1;
   else if (length  4  (found=fontName.rfind( Tur, length - 4)) != 
std::string::npos)
 encoding = 0xa2;
+  else if (length  4  (found=fontName.rfind( TUR, length - 4)) != 
std::string::npos)
+encoding = 0xa2;
   else if (length  7  (found=fontName.rfind( Hebrew, length - 7)) != 
std::string::npos)
 encoding = 0xb1;
   else if (length  7  (found=fontName.rfind( Arabic, length - 7)) != 
std::string::npos)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: 5 commits - sc/qa

2013-03-22 Thread Markus Mohrhard
 dev/null   |binary
 sc/qa/unit/data/ods/colorscale.ods |binary
 sc/qa/unit/data/xlsx/colorscale.xlsx   |binary
 sc/qa/unit/helper/qahelper.hxx |1 
 sc/qa/unit/helper/shared_test_impl.hxx |  155 +
 sc/qa/unit/subsequent_export-test.cxx  |   68 +-
 sc/qa/unit/subsequent_filters-test.cxx |   88 +-
 7 files changed, 248 insertions(+), 64 deletions(-)

New commits:
commit 317a9b2e9463635b87f1c00fc11755dc9a4129f6
Author: Markus Mohrhard markus.mohrh...@googlemail.com
Date:   Fri Mar 22 08:52:11 2013 +0100

add databar export test

Change-Id: I0770d20911307ddd9426417314bebbe569660b14

diff --git a/sc/qa/unit/helper/shared_test_impl.hxx 
b/sc/qa/unit/helper/shared_test_impl.hxx
index 6874a48..04f0547 100644
--- a/sc/qa/unit/helper/shared_test_impl.hxx
+++ b/sc/qa/unit/helper/shared_test_impl.hxx
@@ -30,6 +30,46 @@ private:
 const ScRange mrRange;
 };
 
+struct DataBarData
+{
+ScRange aRange;
+ScColorScaleEntryType eLowerLimitType;
+ScColorScaleEntryType eUpperLimitType;
+databar::ScAxisPostion eAxisPosition;
+};
+
+DataBarData aData[] = {
+{ ScRange(1,2,0,1,5,0), COLORSCALE_AUTO, COLORSCALE_AUTO, 
databar::AUTOMATIC },
+{ ScRange(3,2,0,3,5,0), COLORSCALE_MIN, COLORSCALE_MAX, databar::AUTOMATIC 
},
+{ ScRange(5,2,0,5,5,0), COLORSCALE_PERCENTILE, COLORSCALE_PERCENT, 
databar::AUTOMATIC },
+{ ScRange(7,2,0,7,5,0), COLORSCALE_VALUE, COLORSCALE_FORMULA, 
databar::AUTOMATIC },
+{ ScRange(1,9,0,1,12,0), COLORSCALE_AUTO, COLORSCALE_AUTO, databar::MIDDLE 
}
+};
+
+void testDataBar_Impl(ScDocument* pDoc)
+{
+ScConditionalFormatList* pList = pDoc-GetCondFormList(0);
+CPPUNIT_ASSERT(pList);
+
+for(size_t i = 0; i  SAL_N_ELEMENTS(aData); ++i)
+{
+ScConditionalFormatList::const_iterator itr = 
std::find_if(pList-begin(),
+pList-end(), FindCondFormatByEnclosingRange(aData[i].aRange));
+CPPUNIT_ASSERT(itr != pList-end());
+CPPUNIT_ASSERT_EQUAL(size_t(1), itr-size());
+
+const ScFormatEntry* pFormatEntry = itr-GetEntry(0);
+CPPUNIT_ASSERT_EQUAL(pFormatEntry-GetType(), condformat::DATABAR);
+const ScDataBarFormat* pDataBar = static_castconst 
ScDataBarFormat*(pFormatEntry);
+CPPUNIT_ASSERT(pDataBar);
+const ScDataBarFormatData* pDataBarData = pDataBar-GetDataBarData();
+CPPUNIT_ASSERT_EQUAL(aData[i].eLowerLimitType, 
pDataBarData-mpLowerLimit-GetType());
+CPPUNIT_ASSERT_EQUAL(aData[i].eUpperLimitType, 
pDataBarData-mpUpperLimit-GetType());
+
+CPPUNIT_ASSERT_EQUAL(aData[i].eAxisPosition, 
pDataBarData-meAxisPosition);
+}
+}
+
 struct ColorScale2EntryData
 {
 ScRange aRange;
diff --git a/sc/qa/unit/subsequent_export-test.cxx 
b/sc/qa/unit/subsequent_export-test.cxx
index aa0c1ed..c73ba31 100644
--- a/sc/qa/unit/subsequent_export-test.cxx
+++ b/sc/qa/unit/subsequent_export-test.cxx
@@ -48,6 +48,8 @@ public:
 void testConditionalFormatExportXLSX();
 void testColorScaleExportODS();
 void testColorScaleExportXLSX();
+void testDataBarExportODS();
+void testDataBarExportXLSX();
 void testMiscRowHeightExport();
 
 CPPUNIT_TEST_SUITE(ScExportTest);
@@ -192,6 +194,34 @@ void ScExportTest::testColorScaleExportXLSX()
 testColorScale3Entry_Impl(pDoc);
 }
 
+void ScExportTest::testDataBarExportODS()
+{
+ScDocShellRef xShell = loadDoc(databar., ODS);
+CPPUNIT_ASSERT(xShell.Is());
+
+ScDocShellRef xDocSh = saveAndReload(xShell, ODS);
+CPPUNIT_ASSERT(xDocSh.Is());
+
+ScDocument* pDoc = xDocSh-GetDocument();
+CPPUNIT_ASSERT(pDoc);
+
+testDataBar_Impl(pDoc);
+}
+
+void ScExportTest::testDataBarExportXLSX()
+{
+ScDocShellRef xShell = loadDoc(databar., XLSX);
+CPPUNIT_ASSERT(xShell.Is());
+
+ScDocShellRef xDocSh = saveAndReload(xShell, XLSX);
+CPPUNIT_ASSERT(xDocSh.Is());
+
+ScDocument* pDoc = xDocSh-GetDocument();
+CPPUNIT_ASSERT(pDoc);
+
+testDataBar_Impl(pDoc);
+}
+
 void ScExportTest::testMiscRowHeightExport()
 {
 TestParam::RowData DfltRowData[] =
diff --git a/sc/qa/unit/subsequent_filters-test.cxx 
b/sc/qa/unit/subsequent_filters-test.cxx
index 5a417f8..bdb09fd 100644
--- a/sc/qa/unit/subsequent_filters-test.cxx
+++ b/sc/qa/unit/subsequent_filters-test.cxx
@@ -1732,50 +1732,6 @@ void ScFiltersTest::testRichTextContentODS()
 xDocSh-DoClose();
 }
 
-namespace {
-
-struct DataBarData
-{
-ScRange aRange;
-ScColorScaleEntryType eLowerLimitType;
-ScColorScaleEntryType eUpperLimitType;
-databar::ScAxisPostion eAxisPosition;
-};
-
-DataBarData aData[] = {
-{ ScRange(1,2,0,1,5,0), COLORSCALE_AUTO, COLORSCALE_AUTO, 
databar::AUTOMATIC },
-{ ScRange(3,2,0,3,5,0), COLORSCALE_MIN, COLORSCALE_MAX, databar::AUTOMATIC 
},
-{ ScRange(5,2,0,5,5,0), COLORSCALE_PERCENTILE, COLORSCALE_PERCENT, 
databar::AUTOMATIC },
-{ ScRange(7,2,0,7,5,0), COLORSCALE_VALUE, 

[Libreoffice-commits] core.git: 2 commits - configure.ac liborcus/ExternalProject_liborcus.mk

2013-03-22 Thread Stephan Bergmann
 configure.ac |2 +-
 liborcus/ExternalProject_liborcus.mk |5 -
 2 files changed, 5 insertions(+), 2 deletions(-)

New commits:
commit cc8e169d6cddc081e2a8b5249f34169c0e41d7d3
Author: Stephan Bergmann sberg...@redhat.com
Date:   Fri Mar 22 10:02:30 2013 +0100

liborcus depends on zlib

...at least unless configured --without-gnumeric-filter, see its 
configure.ac:
The gnumeric import filter depends on zLib.

Change-Id: Ied3fb0119978ed484c5e0668cd6a949b448e1ee0

diff --git a/liborcus/ExternalProject_liborcus.mk 
b/liborcus/ExternalProject_liborcus.mk
index c725345..21db367 100644
--- a/liborcus/ExternalProject_liborcus.mk
+++ b/liborcus/ExternalProject_liborcus.mk
@@ -13,7 +13,10 @@ $(eval $(call 
gb_ExternalProject_use_unpacked,liborcus,orcus))
 
 $(eval $(call gb_ExternalProject_use_autoconf,liborcus,build))
 
-$(eval $(call gb_ExternalProject_use_external,liborcus,boost_headers))
+$(eval $(call gb_ExternalProject_use_externals,liborcus, \
+boost_headers \
+zlib \
+))
 
 $(eval $(call gb_ExternalProject_register_targets,liborcus,\
build \
commit 1939c8c89bc2a92b3ab90b27632ab5a97b9d7e2a
Author: Stephan Bergmann sberg...@redhat.com
Date:   Fri Mar 22 10:01:27 2013 +0100

Our internal (static) zlib library is called zlib, not z

Change-Id: Ied4b734a412546558b049b1fc627c421b61a0629

diff --git a/configure.ac b/configure.ac
index 54a4a10..9a69275 100644
--- a/configure.ac
+++ b/configure.ac
@@ -6967,7 +6967,7 @@ else
 SYSTEM_ZLIB=NO
 BUILD_TYPE=$BUILD_TYPE ZLIB
 ZLIB_CFLAGS=-I${OUTDIR}/inc/external/zlib
-ZLIB_LIBS=-L${OUTDIR}/lib -lz
+ZLIB_LIBS=-L${OUTDIR}/lib -lzlib
 fi
 AC_SUBST(ZLIB_CFLAGS)
 AC_SUBST(ZLIB_LIBS)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: [4.0] Calc+Base fail without registry/writer.xcd from Writer package

2013-03-22 Thread Stephan Bergmann

On 03/21/2013 07:57 PM, Andreas Radke wrote:

Am Thu, 21 Mar 2013 18:04:15 +0100
schrieb Stephan Bergmann sberg...@redhat.com:

On 03/21/2013 05:39 PM, Andreas Radke wrote:

Am Thu, 21 Mar 2013 14:55:37 +0100
schrieb Stephan Bergmann sberg...@redhat.com:

However, for the two archlinux issues mentioned above, I would
assume that this things are packaged differently there, and
share/registry/librelogo.xcd erroneously ends up in some core
package? Which would make those issues downstream ones.

Stephan


We rely on the upstream file-lists/*_list.txt files to move all
stuff into our packages.

/usr/lib/libreoffice/share/registry/librelogo.xcd is part of
libreoffice-common.


Sorry, I have no idea about those file-lists/*_list.txt files.  Can
you give a link to them in the LibreOffice git repo at
http://cgit.freedesktop.org/libreoffice?


http://cgit.freedesktop.org/libreoffice/core/tree/bin/distro-install-file-lists

I guess this is the base where they are created. Petr Mladek should
know best how this is done.


So maybe 
http://cgit.freedesktop.org/libreoffice/core/commit/?id=f9f89ee1dc05d5cac1e155f84028ffda65620d55 
Add librelogo to lists needs some tweaking.  Tomas, Petr, can you have 
a look?


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


Re: fdo#55814: unit test is missing

2013-03-22 Thread Miklos Vajna
Hi David,

On Thu, Mar 21, 2013 at 10:42:27AM +0100, David Ostrovsky 
d.ostrov...@idaia.de wrote:
 And yes i am going to migrate it to C++ as you argued that it would be
 easier to debug then java. I wonder if it would make sense to establish
 Python_test machinery in our build system to be able to write such and
 many other tests in python instead and just say make Pytest_sw_complex
 instead of make JunitTest_sw_complex (python have got unittest module
 that we can start with)?

Hmm, yes, I think that would be an improvement. As far as I understand,
most of the Java tests have two difficulties:

1) A separate soffice process is started, then Java code connects to
this, and executes tests. This is a bit slow, compred to the C++ unit
tests, where we bootstap UNO ourselves + a bit painful to debug, as you
have to run one process in gdb (listening on a socket) and an other
process to trigger the problem.

If do a 1:1 conversion of Java tests to Python, this will be still an
issue. IMHO doing the C++ way for Python (running the tests in a single
process) makes more sense.

(Don't confuse these C++ tests with the various uwriter/ucalc/etc tests,
which even have access to private library symbols.)

2) When a unit test fails, it's handy to step the unit test line-by-line
in gdb to see exactly which line triggers an exception, etc.

I imagine this only works if you write the test in C++, but even with
basic or python, it should not be *that* bad, as we can have the
interpreter with debug symbols, etc. I think in this second case even a
1:1 conversion from java to python would help a lot.

And after all, be sure to talk to Markus, he's the testing expert, not
me. :-)

HTH,

Miklos


signature.asc
Description: Digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Build failure on master with Linux 32 bit in localize.cxx

2013-03-22 Thread Alexander Thurgood
Le 22/03/13 08:28, Zolnai Tamás a écrit :

Hi Tamás,

 Thanks for your notice.
 The problem has been solved with this commit:
 http://cgit.freedesktop.org/libreoffice/core/commit/?id=0552b4334c2fb6b130ec05934b952b60418aadca
 


Excellent, thanks :-)

Alex

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


Re: [4.0] Calc+Base fail without registry/writer.xcd from Writer package

2013-03-22 Thread Tomáš Chvátal
2013/3/22 Stephan Bergmann sberg...@redhat.com:

 We rely on the upstream file-lists/*_list.txt files to move all
 stuff into our packages.

 /usr/lib/libreoffice/share/registry/librelogo.xcd is part of
 libreoffice-common.

 http://cgit.freedesktop.org/libreoffice/core/tree/bin/distro-install-file-lists

 I guess this is the base where they are created. Petr Mladek should
 know best how this is done.

 So maybe
 http://cgit.freedesktop.org/libreoffice/core/commit/?id=f9f89ee1dc05d5cac1e155f84028ffda65620d55
 Add librelogo to lists needs some tweaking.  Tomas, Petr, can you have a
 look?


Yup seems like I picked wrong category for this one.

From what I see librelogo could be part of Writer list then?

Cheers

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


Re: NumericBox unsafe double conversion

2013-03-22 Thread Zolnai Tamás
Hi Kendy,

 Yes, I give it a try.

 Great, thanks a lot! :-)


Well, I said I'm interested in this cleanup, but just until it is not too
far from my tasks. :)
I used NumericBox to derive from it while implementing LimitBox and I'd
like to allow the user adding values unlimitedly, so the only limit would
be the maximum value of the used type (in this case sal_Int64). (Anyway, I
think such maximum value for a NumericBox is a rare case. Maybe that's why
this bug dont outcrop yet) So I'm interested only in NumericBox, and I
would do my changes only in it with taking care not to change others
behaviour.

Plus, as I see there are not only multiplication in ConvertDoubleValue, but
division too. Replace these simply with integer division will not result
the same. So that make this situation more difficult to solve only with
integer operations and avoid all double aritmetic. So yes, its getting
complicated, too complicated.

Otherwise in ImplNumericGetValue() the problem of overflow/underflow can be
avoid with these lines
sal_Int64 nValue = aStr.toInt64()
if( OUString::valueOf(nValue) != aStr )
{
if( bNegative )
rValue = SAL_MIN_INT64;
else
rValue = SAL_MAX_INT64;
return sal_True;
}
With this the bevavior would be the excepted, because NumericBox and others
were made to return the maximum value (mnMax, GetMax()) when the typed one
is bigger. (mnMin just the same)

So, I try to solve the problem of NumericBox, but MetricBox remain the
same. Maybe an other day or an other man. :)

Best regards,
Tamás
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: sw/qa writerfilter/source

2013-03-22 Thread Miklos Vajna
 sw/qa/extras/rtfimport/data/fdo62288.rtf   |   23 +++
 sw/qa/extras/rtfimport/rtfimport.cxx   |   15 +++
 writerfilter/source/rtftok/rtfdocumentimpl.cxx |9 +
 3 files changed, 47 insertions(+)

New commits:
commit 24d5261f5a122e22675210445056cdf67663237b
Author: Miklos Vajna vmik...@suse.cz
Date:   Fri Mar 22 11:08:12 2013 +0100

fdo#62288 fix RTF import of table paragraph margins

Regression from 4a507f732d82c188ad81b022cbe3037951e58ac3. The problem
was that in some cases \pard can't reset all paragraph properties. The
original commit just made this keyword a noop when it occurred between
\cell and \row, but this is too much. At least margins do need
resetting.

Change-Id: I5cbb1df72bf1211f85ef69ab64d5b46cbce5c742

diff --git a/sw/qa/extras/rtfimport/data/fdo62288.rtf 
b/sw/qa/extras/rtfimport/data/fdo62288.rtf
new file mode 100644
index 000..f5ec592
--- /dev/null
+++ b/sw/qa/extras/rtfimport/data/fdo62288.rtf
@@ -0,0 +1,23 @@
+{\rtf1
+\paperw11907\paperh16840\margl567\margr567\margt567\margb567 
+\sb113\sa113
+{\b\fs22\cf1\kerning1\cgrid0 Objectives}
+{\fs24\kerning1\cgrid0 
+\par }
+\trowd \trgaph10\trleft-10 \clvertalt\cltxlrtb \cellx4808\clvertalt\cltxlrtb 
\cellx5375\clvertalt\cltxlrtb \cellx10194\clvertalt\cltxlrtb \cellx10762\pard 
\li567\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 One}
+{\fs24\kerning1\cgrid0 \cell }
+\pard \qc\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 [ ]}
+{\fs24\kerning1\cgrid0 \cell }
+\pard \li567\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 Two}
+{
+\fs24\kerning1\cgrid0 \cell }
+\pard \qc\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 [ ]}
+{\fs24\kerning1\cgrid0 \cell }
+\pard \widctlpar\intbl\adjustright 
+{\fs24\kerning1\cgrid0 \row }
+\pard\par
+}
diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx 
b/sw/qa/extras/rtfimport/rtfimport.cxx
index 4d042dc..a7b1e01 100644
--- a/sw/qa/extras/rtfimport/rtfimport.cxx
+++ b/sw/qa/extras/rtfimport/rtfimport.cxx
@@ -146,6 +146,7 @@ public:
 void testFdo59638();
 void testFdo60722();
 void testFdo61909();
+void testFdo62288();
 
 CPPUNIT_TEST_SUITE(Test);
 #if !defined(MACOSX)  !defined(WNT)
@@ -264,6 +265,7 @@ void Test::run()
 {fdo59638.rtf, Test::testFdo59638},
 {fdo60722.rtf, Test::testFdo60722},
 {fdo61909.rtf, Test::testFdo61909},
+{fdo62288.rtf, Test::testFdo62288},
 };
 header();
 for (unsigned int i = 0; i  SAL_N_ELEMENTS(aMethods); ++i)
@@ -1177,6 +1179,19 @@ void Test::testFdo61909()
 CPPUNIT_ASSERT_EQUAL(COL_AUTO, getPropertysal_uInt32(xTextRange, 
CharBackColor));
 }
 
+void Test::testFdo62288()
+{
+uno::Referencetext::XTextTablesSupplier xTextTablesSupplier(mxComponent, 
uno::UNO_QUERY);
+uno::Referencecontainer::XIndexAccess 
xTables(xTextTablesSupplier-getTextTables(), uno::UNO_QUERY);
+uno::Referencetext::XTextTable xTable(xTables-getByIndex(0), 
uno::UNO_QUERY);
+uno::Referencetext::XTextRange xCell(xTable-getCellByName(B1), 
uno::UNO_QUERY);
+uno::Referencecontainer::XEnumerationAccess 
xParaEnumAccess(xCell-getText(), uno::UNO_QUERY);
+uno::Referencecontainer::XEnumeration xParaEnum = 
xParaEnumAccess-createEnumeration();
+uno::Referencetext::XTextRange xPara(xParaEnum-nextElement(), 
uno::UNO_QUERY);
+// Margins were inherited from the previous cell, even there was a \pard 
there.
+CPPUNIT_ASSERT_EQUAL(sal_Int32(0), getPropertysal_Int32(xPara, 
ParaLeftMargin));
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(Test);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx 
b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 4fbb6cc..47d2af1 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -2173,11 +2173,20 @@ int RTFDocumentImpl::dispatchFlag(RTFKeyword nKeyword)
 // \pard is allowed between \cell and \row, but in that case it 
should not reset the fact that we're inside a table.
 if (m_aStates.top().nCells == 0)
 {
+// Reset everything.
 m_aStates.top().aParagraphSprms = 
m_aDefaultState.aParagraphSprms;
 m_aStates.top().aParagraphAttributes = 
m_aDefaultState.aParagraphAttributes;
 if (m_aStates.top().nDestinationState != DESTINATION_SHAPETEXT)
 m_pCurrentBuffer = 0;
 }
+else
+{
+// Reset only margins.
+lcl_eraseNestedAttribute(m_aStates.top().aParagraphSprms, 
NS_ooxml::LN_CT_PPrBase_spacing, NS_ooxml::LN_CT_Spacing_before);
+lcl_eraseNestedAttribute(m_aStates.top().aParagraphSprms, 
NS_ooxml::LN_CT_PPrBase_spacing, NS_ooxml::LN_CT_Spacing_after);
+m_aStates.top().aParagraphSprms.erase(NS_sprm::LN_PDxaLeft);
+

Re: NumericBox unsafe double conversion

2013-03-22 Thread Stephan Bergmann

On 03/22/2013 11:44 AM, Zolnai Tamás wrote:

Otherwise in ImplNumericGetValue() the problem of overflow/underflow can
be avoid with these lines
sal_Int64 nValue = aStr.toInt64()
if( OUString::valueOf(nValue) != aStr )
{
 if( bNegative )
 rValue = SAL_MIN_INT64;
 else
 rValue = SAL_MAX_INT64;
 return sal_True;
}


...but only if aStr is known to be in canonical form, esp. neither 
contains minus zero nor contains excessive leading zero digits.  None of 
that is guaranteed for ImplNumericGetValue in its current form (and also 
consider nDecDigits  0, where input rStr=0 and nDecDigits=2, say, 
would lead to aStr=000 and the above comparison erroneously failing).


Stephan

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


[Libreoffice-commits] .: 2 commits - src/conv src/lib

2013-03-22 Thread Libreoffice Gerrit user
 src/conv/raw/vsd2raw.cpp|  183 ++--
 src/conv/raw/vss2raw.cpp|  183 ++--
 src/lib/VSDContentCollector.cpp |   74 +---
 src/lib/VSDContentCollector.h   |1 
 4 files changed, 357 insertions(+), 84 deletions(-)

New commits:
commit 6b27d3cc5974edd2b65c33fd11c11a9a6ee692a3
Author: Fridrich Å trba fridrich.st...@bluewin.ch
Date:   Fri Mar 22 12:30:13 2013 +0100

Option to test the callback graph, in order to detect mismatched grouping

diff --git a/src/conv/raw/vsd2raw.cpp b/src/conv/raw/vsd2raw.cpp
index e79e343..dbc2ccc 100644
--- a/src/conv/raw/vsd2raw.cpp
+++ b/src/conv/raw/vsd2raw.cpp
@@ -29,16 +29,55 @@
  */
 
 #include stdio.h
+#include stdarg.h
 #include string.h
+#include stack
 
 #include libvisio.h
 #include libwpd-stream/libwpd-stream.h
 #include libwpd/libwpd.h
 
+enum PainterCallback
+{
+  PC_START_GRAPHICS = 0,
+  PC_START_LAYER,
+  PC_START_EMBEDDED_GRAPHICS,
+  PC_START_TEXT_OBJECT,
+  PC_START_TEXT_LINE,
+  PC_START_TEXT_SPAN
+};
+
+#ifdef _U
+#undef _U
+#endif
+
+#define _U(M, L) \
+   if (!m_printCallgraphScore) \
+   __iuprintf M; \
+   else \
+   m_callStack.push(L);
+
+#ifdef _D
+#undef _D
+#endif
+
+#define _D(M, L) \
+   if (!m_printCallgraphScore) \
+   __idprintf M; \
+   else \
+   { \
+   PainterCallback lc = m_callStack.top(); \
+   if (lc != L) \
+   m_callbackMisses++; \
+   m_callStack.pop(); \
+   }
+
 class RawPainter : public libwpg::WPGPaintInterface
 {
 public:
-  RawPainter();
+  RawPainter(bool printCallgraphScore);
+
+  ~RawPainter();
 
   void startGraphics(const ::WPXPropertyList propList);
   void endGraphics();
@@ -62,6 +101,25 @@ public:
   void startTextSpan(const ::WPXPropertyList propList);
   void endTextSpan();
   void insertText(const ::WPXString str);
+
+private:
+  int m_indent;
+  int m_callbackMisses;
+  bool m_printCallgraphScore;
+  std::stackPainterCallback m_callStack;
+
+  void __indentUp()
+  {
+m_indent++;
+  }
+  void __indentDown()
+  {
+if (m_indent  0) m_indent--;
+  }
+
+  void __iprintf(const char *format, ...);
+  void __iuprintf(const char *format, ...);
+  void __idprintf(const char *format, ...);
 };
 
 WPXString getPropString(const WPXPropertyList propList)
@@ -111,108 +169,177 @@ WPXString getPropString(const WPXPropertyListVector 
itemList)
   return propString;
 }
 
-RawPainter::RawPainter(): libwpg::WPGPaintInterface()
+RawPainter::RawPainter(bool printCallgraphScore):
+  libwpg::WPGPaintInterface(),
+  m_indent(0),
+  m_callbackMisses(0),
+  m_printCallgraphScore(printCallgraphScore),
+  m_callStack()
+{
+}
+
+RawPainter::~RawPainter()
+{
+  if (m_printCallgraphScore)
+printf(%d\n, (int)(m_callStack.size() + m_callbackMisses));
+}
+
+void RawPainter::__iprintf(const char *format, ...)
 {
+  if (m_printCallgraphScore) return;
+
+  va_list args;
+  va_start(args, format);
+  for (int i=0; im_indent; i++)
+printf(  );
+  vprintf(format, args);
+  va_end(args);
+}
+
+void RawPainter::__iuprintf(const char *format, ...)
+{
+  va_list args;
+  va_start(args, format);
+  for (int i=0; im_indent; i++)
+printf(  );
+  vprintf(format, args);
+  __indentUp();
+  va_end(args);
+}
+
+void RawPainter::__idprintf(const char *format, ...)
+{
+  va_list args;
+  va_start(args, format);
+  __indentDown();
+  for (int i=0; im_indent; i++)
+printf(  );
+  vprintf(format, args);
+  va_end(args);
 }
 
 void RawPainter::startGraphics(const ::WPXPropertyList propList)
 {
-  printf(RawPainter::startGraphics(%s)\n, getPropString(propList).cstr());
+  _U((RawPainter::startGraphics(%s)\n, getPropString(propList).cstr()), 
PC_START_GRAPHICS);
 }
 
 void RawPainter::endGraphics()
 {
-  printf(RawPainter::endGraphics\n);
+  _D((RawPainter::endGraphics\n), PC_START_GRAPHICS);
 }
 
 void RawPainter::startLayer(const ::WPXPropertyList propList)
 {
-  printf(RawPainter::startLayer (%s)\n, getPropString(propList).cstr());
+  _U((RawPainter::startLayer (%s)\n, getPropString(propList).cstr()), 
PC_START_LAYER);
 }
 
 void RawPainter::endLayer()
 {
-  printf(RawPainter::endLayer\n);
+  _D((RawPainter::endLayer\n), PC_START_LAYER);
 }
 
 void RawPainter::startEmbeddedGraphics(const ::WPXPropertyList propList)
 {
-  printf(RawPainter::startEmbeddedGraphics (%s)\n, 
getPropString(propList).cstr());
+  _U((RawPainter::startEmbeddedGraphics (%s)\n, 
getPropString(propList).cstr()), PC_START_EMBEDDED_GRAPHICS);
 }
 
 void RawPainter::endEmbeddedGraphics()
 {
-  printf(RawPainter::endEmbeddedGraphics \n);
+  _D((RawPainter::endEmbeddedGraphics \n), PC_START_EMBEDDED_GRAPHICS);
 }
 
 void RawPainter::setStyle(const ::WPXPropertyList propList, const 
::WPXPropertyListVector gradient)
 {
-  printf(RawPainter::setStyle(%s, gradient: (%s))\n, 
getPropString(propList).cstr(), getPropString(gradient).cstr());
+  if 

[Libreoffice-commits] dev-tools.git: git-hooks/contrib

2013-03-22 Thread Miklos Vajna
 git-hooks/contrib/libvisio.git/hooks/update |7 ---
 1 file changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 21f2873914ed25f6efa55c687dded9a73683846a
Author: Miklos Vajna vmik...@suse.cz
Date:   Fri Mar 22 12:39:10 2013 +0100

git-hooks: sync libvisio with core

Change-Id: I844bf0378c7bd659938d3324034eb8233a0d28ed

diff --git a/git-hooks/contrib/libvisio.git/hooks/update 
b/git-hooks/contrib/libvisio.git/hooks/update
index 336996a..2966fb8 100755
--- a/git-hooks/contrib/libvisio.git/hooks/update
+++ b/git-hooks/contrib/libvisio.git/hooks/update
@@ -14,6 +14,7 @@ if [ $(id -u -n ) != logerrit ] ; then
echo *** The reference for this repo is gerrit. do not push directly 
to fdo 2
exit 1
 fi
+from=$(git show -s --pretty=format:'%an %ae' $3^{})
 
 project=$(cat $GIT_DIR/description)
 recipients=libreoffice-comm...@lists.freedesktop.org
@@ -54,8 +55,9 @@ date_format=%F %R %z
 num_path_components=2
 
 # Set subject
+repo=$(basename $(cd $GIT_DIR ; pwd))
 if expr $2 : '0*$' /dev/null ; then
-   subject=Changes to '${1##refs/heads/}'
+   subject=$repo: Changes to '${1##refs/heads/}'
 else
base=$(git-merge-base $2 $3)
subject=$(git-diff-tree -r --name-only $base $3 |
@@ -68,7 +70,6 @@ else
if [ $branch != master ] ; then
subject=Branch '$branch' - $subject
fi
-   repo=$(basename $GIT_DIR)
subject=$repo: $subject
 fi
 
@@ -135,5 +136,5 @@ else
done
 fi |
 mail -s $subject -a X-Git-Repository: 
git://anongit.freedesktop.org/git/libreoffice/contrib/libvisio.git \
- -a List-Post: mailto:libreoffice@lists.freedesktop.org $recipients
+ -a List-Post: mailto:libreoffice@lists.freedesktop.org -a From: 
$from $recipients
 exit 0
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: 2 commits - sd/source vcl/qa

2013-03-22 Thread Michael Meeks
 sd/source/ui/remotecontrol/BufferedStreamSocket.cxx  |3 +++
 vcl/qa/cppunit/graphicfilter/data/png/pass/invalid-chunk.png |binary
 2 files changed, 3 insertions(+)

New commits:
commit ad65fea9c28542dcb986b693ec743b2ec668f0fd
Author: Michael Meeks michael.me...@suse.com
Date:   Thu Mar 21 19:44:08 2013 +

fdo#61847 - add test file of png image with invalid final chunk length.

Change-Id: Ie031f3442abcce053ed5f0a5cf74993219485029

diff --git a/vcl/qa/cppunit/graphicfilter/data/png/pass/invalid-chunk.png 
b/vcl/qa/cppunit/graphicfilter/data/png/pass/invalid-chunk.png
new file mode 100644
index 000..1c45c76
Binary files /dev/null and 
b/vcl/qa/cppunit/graphicfilter/data/png/pass/invalid-chunk.png differ
commit c8fcfb3c87a7aa857bd98209718b2fde99c901c2
Author: Michael Meeks michael.me...@suse.com
Date:   Thu Mar 21 19:10:40 2013 +

sdremote: add more verbose protocol debug.

Change-Id: I1b189824f2b0bb2cf4568378e7ab3efd5a677141

diff --git a/sd/source/ui/remotecontrol/BufferedStreamSocket.cxx 
b/sd/source/ui/remotecontrol/BufferedStreamSocket.cxx
index c1e0287..4b4c1ce 100644
--- a/sd/source/ui/remotecontrol/BufferedStreamSocket.cxx
+++ b/sd/source/ui/remotecontrol/BufferedStreamSocket.cxx
@@ -90,6 +90,8 @@ sal_Int32 BufferedStreamSocket::readLine( OString aLine )
 aBuffer.erase( aBuffer.begin(), aIt + 1 ); // Also delete the 
empty line
 aRead -= (aLocation + 1);
 
+SAL_INFO( sdremote.bluetooth, recv line '  aLine  ' );
+
 return aLine.getLength() + 1;
 }
 
@@ -100,6 +102,7 @@ sal_Int32 BufferedStreamSocket::readLine( OString aLine )
 else
 aRet = ::recv( mSocket, aBuffer[aRead], 100, 0 );
 
+SAL_INFO( sdremote.bluetooth, recv   aRet   aBuffer len   
aBuffer.size() );
 if ( aRet = 0 )
 {
 return 0;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


LibreOffice for Android (how the overcome the problem with the 50 MB limit)

2013-03-22 Thread Tobias Kuban
Looking forward to use it on Android so long. I recently read an 
interview where the 50 MB limit would be a huge challenge. According 
to 
http://android-developers.blogspot.de/2012/03/android-apps-break-50mb-barrier.html 
this limit doesn't exist anymore.

Best, Tobias Kuban
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[PATCH libreoffice-4-0] fdo#62288 fix RTF import of table paragraph margins

2013-03-22 Thread Miklos Vajna (via Code Review)
Hi,

I have submitted a patch for review:

https://gerrit.libreoffice.org/2906

To pull it, you can do:

git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/06/2906/1

fdo#62288 fix RTF import of table paragraph margins

Regression from 4a507f732d82c188ad81b022cbe3037951e58ac3. The problem
was that in some cases \pard can't reset all paragraph properties. The
original commit just made this keyword a noop when it occurred between
\cell and \row, but this is too much. At least margins do need
resetting.

Change-Id: I5cbb1df72bf1211f85ef69ab64d5b46cbce5c742
(cherry picked from commit 24d5261f5a122e22675210445056cdf67663237b)
---
A sw/qa/extras/rtfimport/data/fdo62288.rtf
M sw/qa/extras/rtfimport/rtfimport.cxx
M writerfilter/source/rtftok/rtfdocumentimpl.cxx
3 files changed, 47 insertions(+), 0 deletions(-)



diff --git a/sw/qa/extras/rtfimport/data/fdo62288.rtf 
b/sw/qa/extras/rtfimport/data/fdo62288.rtf
new file mode 100644
index 000..f5ec592
--- /dev/null
+++ b/sw/qa/extras/rtfimport/data/fdo62288.rtf
@@ -0,0 +1,23 @@
+{\rtf1
+\paperw11907\paperh16840\margl567\margr567\margt567\margb567 
+\sb113\sa113
+{\b\fs22\cf1\kerning1\cgrid0 Objectives}
+{\fs24\kerning1\cgrid0 
+\par }
+\trowd \trgaph10\trleft-10 \clvertalt\cltxlrtb \cellx4808\clvertalt\cltxlrtb 
\cellx5375\clvertalt\cltxlrtb \cellx10194\clvertalt\cltxlrtb \cellx10762\pard 
\li567\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 One}
+{\fs24\kerning1\cgrid0 \cell }
+\pard \qc\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 [ ]}
+{\fs24\kerning1\cgrid0 \cell }
+\pard \li567\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 Two}
+{
+\fs24\kerning1\cgrid0 \cell }
+\pard \qc\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 [ ]}
+{\fs24\kerning1\cgrid0 \cell }
+\pard \widctlpar\intbl\adjustright 
+{\fs24\kerning1\cgrid0 \row }
+\pard\par
+}
diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx 
b/sw/qa/extras/rtfimport/rtfimport.cxx
index 07583fc..e54812f 100644
--- a/sw/qa/extras/rtfimport/rtfimport.cxx
+++ b/sw/qa/extras/rtfimport/rtfimport.cxx
@@ -142,6 +142,7 @@
 void testFdo59638();
 void testFdo60722();
 void testFdo61909();
+void testFdo62288();
 
 CPPUNIT_TEST_SUITE(Test);
 #if !defined(MACOSX)  !defined(WNT)
@@ -234,6 +235,7 @@
 {fdo59638.rtf, Test::testFdo59638},
 {fdo60722.rtf, Test::testFdo60722},
 {fdo61909.rtf, Test::testFdo61909},
+{fdo62288.rtf, Test::testFdo62288},
 };
 for (unsigned int i = 0; i  SAL_N_ELEMENTS(aMethods); ++i)
 {
@@ -1142,6 +1144,19 @@
 CPPUNIT_ASSERT_EQUAL(COL_AUTO, getPropertysal_uInt32(xTextRange, 
CharBackColor));
 }
 
+void Test::testFdo62288()
+{
+uno::Referencetext::XTextTablesSupplier xTextTablesSupplier(mxComponent, 
uno::UNO_QUERY);
+uno::Referencecontainer::XIndexAccess 
xTables(xTextTablesSupplier-getTextTables(), uno::UNO_QUERY);
+uno::Referencetext::XTextTable xTable(xTables-getByIndex(0), 
uno::UNO_QUERY);
+uno::Referencetext::XTextRange xCell(xTable-getCellByName(B1), 
uno::UNO_QUERY);
+uno::Referencecontainer::XEnumerationAccess 
xParaEnumAccess(xCell-getText(), uno::UNO_QUERY);
+uno::Referencecontainer::XEnumeration xParaEnum = 
xParaEnumAccess-createEnumeration();
+uno::Referencetext::XTextRange xPara(xParaEnum-nextElement(), 
uno::UNO_QUERY);
+// Margins were inherited from the previous cell, even there was a \pard 
there.
+CPPUNIT_ASSERT_EQUAL(sal_Int32(0), getPropertysal_Int32(xPara, 
ParaLeftMargin));
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(Test);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx 
b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 34b779d..3f18695 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -2172,11 +2172,20 @@
 // \pard is allowed between \cell and \row, but in that case it 
should not reset the fact that we're inside a table.
 if (m_aStates.top().nCells == 0)
 {
+// Reset everything.
 m_aStates.top().aParagraphSprms = 
m_aDefaultState.aParagraphSprms;
 m_aStates.top().aParagraphAttributes = 
m_aDefaultState.aParagraphAttributes;
 if (m_aStates.top().nDestinationState != DESTINATION_SHAPETEXT)
 m_pCurrentBuffer = 0;
 }
+else
+{
+// Reset only margins.
+lcl_eraseNestedAttribute(m_aStates.top().aParagraphSprms, 
NS_ooxml::LN_CT_PPrBase_spacing, NS_ooxml::LN_CT_Spacing_before);
+lcl_eraseNestedAttribute(m_aStates.top().aParagraphSprms, 
NS_ooxml::LN_CT_PPrBase_spacing, NS_ooxml::LN_CT_Spacing_after);
+m_aStates.top().aParagraphSprms.erase(NS_sprm::LN_PDxaLeft);
+m_aStates.top().aParagraphSprms.erase(NS_sprm::LN_PDxaRight);
+}
 m_aStates.top().resetFrame();
 break;

Re: LibreOffice for Android (how the overcome the problem with the 50 MB limit)

2013-03-22 Thread Noel Grandin

On 2013-03-22 14:01, Tobias Kuban wrote:
Looking forward to use it on Android so long. I recently read an 
interview where the 50 MB limit would be a huge challenge. According 
to 
http://android-developers.blogspot.de/2012/03/android-apps-break-50mb-barrier.html 
this limit doesn't exist anymore.

Best, Tobias Kuban


We know about this, and no, it doesn't solve our immediate problem.

Unless, of course, you are volunteering to implement the splitting of 
our APK file into a core installer segment, and an add-on expansion pack?


Disclaimer: http://www.peralex.com/disclaimer.html


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


Re: Minutes of ESC call

2013-03-22 Thread Michael Meeks

On Thu, 2013-03-21 at 17:28 +0100, Jan Holesovsky wrote:
 * Completed Action Items
   + none :-(

We seemed to loose these two:

* Completed Action Items
+ send details of new icon (Lionel)
+ finally remove the */prj/build.lst files (Michael+Andras)

from the proto agenda :-) otherwise thanks so much for the minutes.

ATB,

Michael.

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

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


api.libreoffice.org CSS lost

2013-03-22 Thread Laurent Godard

Hi all

http://api.libreoffice.org/docs/common/ref/com/sun/star/module-ix.html
shows wrong colors

is it known ?

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


[Libreoffice-commits] core.git: tools/source

2013-03-22 Thread Miklos Vajna
 tools/source/inet/inetstrm.cxx |   13 -
 1 file changed, 4 insertions(+), 9 deletions(-)

New commits:
commit 793d4810c8cd087b42df51ab5326e35f4dd1132d
Author: Miklos Vajna vmik...@suse.cz
Date:   Fri Mar 22 13:07:47 2013 +0100

tools: remove no longer needed CONSTASCII_STRINGPARAM macro

Change-Id: I5edf79ed165b8ed8e96e091f3f29ded0ac6067f2

diff --git a/tools/source/inet/inetstrm.cxx b/tools/source/inet/inetstrm.cxx
index 009c905..544f23d 100644
--- a/tools/source/inet/inetstrm.cxx
+++ b/tools/source/inet/inetstrm.cxx
@@ -31,8 +31,6 @@ inline sal_Bool SAL_CALL ascii_isWhitespace( sal_Unicode ch )
 return ((ch = 0x20)  ch);
 }
 
-#define CONSTASCII_STRINGPARAM(a) (a), RTL_TEXTENCODING_ASCII_US
-
 /** Quoted-Printable Encoding */
 class INetMessageEncodeQPStream_Impl : public INetMessageIStream
 {
@@ -1173,14 +1171,13 @@ int INetMIMEMessageStream::GetMsgLine (sal_Char *pData, 
sal_uIntPtr nSize)
 {
 String aPCT (pMsg-GetParent()-GetContentType());
 if (aPCT.CompareIgnoreCaseToAscii (message/rfc822, 14) == 0)
-pMsg-SetMIMEVersion (
-String(CONSTASCII_STRINGPARAM(1.0)));
+pMsg-SetMIMEVersion (1.0);
 else
 pMsg-SetMIMEVersion (String());
 }
 else
 {
-pMsg-SetMIMEVersion (String(CONSTASCII_STRINGPARAM(1.0)));
+pMsg-SetMIMEVersion (1.0);
 }
 
 // Check ContentType.
@@ -1226,14 +1223,12 @@ int INetMIMEMessageStream::GetMsgLine (sal_Char *pData, 
sal_uIntPtr nSize)
 if (eEncoding == INETMSG_ENCODING_BASE64)
 {
 // Base64.
-pMsg-SetContentTransferEncoding (
-String(CONSTASCII_STRINGPARAM(base64)));
+pMsg-SetContentTransferEncoding (base64);
 }
 else if (eEncoding == INETMSG_ENCODING_QUOTED)
 {
 // Quoted-Printable.
-pMsg-SetContentTransferEncoding (
-String(CONSTASCII_STRINGPARAM(quoted-printable)));
+pMsg-SetContentTransferEncoding (quoted-printable);
 }
 else
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: api.libreoffice.org CSS lost

2013-03-22 Thread Andras Timar
Hi Laurent,

On 2013.03.22. 12:32, Laurent Godard wrote:
 Hi all

 http://api.libreoffice.org/docs/common/ref/com/sun/star/module-ix.html
 shows wrong colors

 is it known ?

Yes, it is known. I'm working on it.

Thanks,
Andras

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


Re: Pivot Table data provider extension framework (removal possibility)

2013-03-22 Thread Michael Meeks

On Thu, 2013-03-21 at 12:24 -0400, Kohei Yoshida wrote:
 I have a cunning idea. Since one of the difficulties on this is to reach 
 out to the actual users of this functionality, I'd like to remove the 
 4th check box from the current pivot table data source selection dialog 
 in 4.1 (and maybe 4.0.x if you guys agree) and see if anyone reports it 
 as a bug.

Sounds rather sensible to me :-) 

HTH,

Michael.

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

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


RE: LibreOffice for Android (how the overcome the problem with the 50 MB limit)

2013-03-22 Thread Jonathan Aquilina
That is actually what I though seeing for instance the size of games and
other apps.

-Original Message-
From: libreoffice-bounces+eagles051387=gmail@lists.freedesktop.org
[mailto:libreoffice-bounces+eagles051387=gmail@lists.freedesktop.org] On
Behalf Of Tobias Kuban
Sent: 22 March 2013 13:01
To: Libreoffice@lists.freedesktop.org
Subject: LibreOffice for Android (how the overcome the problem with the 50
MB limit)

Looking forward to use it on Android so long. I recently read an interview
where the 50 MB limit would be a huge challenge. According to
http://android-developers.blogspot.de/2012/03/android-apps-break-50mb-barrie
r.html
this limit doesn't exist anymore.
Best, Tobias Kuban
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice

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


Re: api.libreoffice.org CSS lost

2013-03-22 Thread Michael Stahl
On 22/03/13 13:10, Andras Timar wrote:
 Hi Laurent,
 
 On 2013.03.22. 12:32, Laurent Godard wrote:
 Hi all

 http://api.libreoffice.org/docs/common/ref/com/sun/star/module-ix.html
 shows wrong colors

 is it known ?
 
 Yes, it is known. I'm working on it.

lol, substantial parts of the content were missing for a month and
nobody noticed, but if the colors are off we get a complaint within 2
days  :)

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


[Libreoffice-commits] core.git: 2 commits - sfx2/inc sfx2/source

2013-03-22 Thread Cédric Bosdonnat
 sfx2/inc/sfx2/thumbnailview.hxx  |   13 -
 sfx2/source/control/thumbnailview.cxx|  218 +--
 sfx2/source/control/thumbnailviewacc.cxx |2 
 3 files changed, 127 insertions(+), 106 deletions(-)

New commits:
commit ee819bdd2dab5756cc3bad74f24e50bd7409f308
Author: Cédric Bosdonnat cedric.bosdon...@free.fr
Date:   Fri Mar 22 11:43:11 2013 +0100

fdo#61390: simple keybard support in TemplateManager

Adds support for the UP, DOWN, LEFT, RIGHT and RETURN keys in the
thumbnails view but doesn't handle the modifiers yet. There are still
some problems with the focus and key input outside the top level

Change-Id: I5ba67583c835bcc00b075071411c0d6590a07f9a

diff --git a/sfx2/inc/sfx2/thumbnailview.hxx b/sfx2/inc/sfx2/thumbnailview.hxx
index 282e3c4b..5058144 100644
--- a/sfx2/inc/sfx2/thumbnailview.hxx
+++ b/sfx2/inc/sfx2/thumbnailview.hxx
@@ -202,6 +202,8 @@ public:
 
 void SelectItem( sal_uInt16 nItemId );
 
+void DeselectItem( sal_uInt16 nItemId );
+
 bool IsItemSelected( sal_uInt16 nItemId ) const;
 
 /**
@@ -235,6 +237,8 @@ public:
 
 protected:
 
+virtual void KeyInput( const KeyEvent rKEvt );
+
 virtual void MouseButtonDown( const MouseEvent rMEvt );
 
 virtual void MouseButtonUp( const MouseEvent rMEvt );
@@ -268,8 +272,6 @@ protected:
 using Control::ImplInitSettings;
 using Window::ImplInit;
 
-void calculateColumnsRows ();
-
 void CalculateItemPositions ();
 
 SFX2_DLLPRIVATE void ImplInit();
@@ -290,6 +292,7 @@ protected:
 protected:
 
 ValueItemList mItemList;
+ValueItemList mFilteredItemList; /// Cache to store the filtered items
 ScrollBar* mpScrBar;
 Rectangle maItemListRect;
 long mnHeaderHeight;
diff --git a/sfx2/source/control/thumbnailview.cxx 
b/sfx2/source/control/thumbnailview.cxx
index ea66ecc..b73b908 100644
--- a/sfx2/source/control/thumbnailview.cxx
+++ b/sfx2/source/control/thumbnailview.cxx
@@ -214,6 +214,8 @@ void ThumbnailView::CalculateItemPositions ()
 WinBits nStyle = GetStyle();
 ScrollBar*  pDelScrBar = NULL;
 
+mFilteredItemList.clear();
+
 // consider the scrolling
 if ( nStyle  WB_VSCROLL )
 ImplInitScrollBar();
@@ -295,6 +297,7 @@ void ThumbnailView::CalculateItemPositions ()
 
 if (maFilterFunc(pItem))
 {
+mFilteredItemList.push_back(pItem);
 if ((nCurCount = nFirstItem)  (nCurCount  nLastItem))
 {
 if( !pItem-isVisible())
@@ -487,6 +490,73 @@ IMPL_LINK (ThumbnailView, OnItemSelected, 
ThumbnailViewItem*, pItem)
 return 0;
 }
 
+void ThumbnailView::KeyInput( const KeyEvent rKEvt )
+{
+// Get the last selected item in the list
+size_t nLastPos = 0;
+bool bFoundLast = false;
+for ( long i = mFilteredItemList.size() - 1; !bFoundLast  i = 0; --i )
+{
+ThumbnailViewItem* pItem = mFilteredItemList[i];
+if ( pItem-isSelected() )
+{
+nLastPos = i;
+bFoundLast = true;
+}
+}
+
+KeyCode aKeyCode = rKEvt.GetKeyCode();
+ThumbnailViewItem* pNext = NULL;
+switch ( aKeyCode.GetCode() )
+{
+case KEY_RIGHT:
+{
+size_t nNextPos = nLastPos;
+if ( bFoundLast  nLastPos  mFilteredItemList.size( ) - 1 )
+nNextPos = nLastPos + 1;
+pNext = mFilteredItemList[nNextPos];
+}
+break;
+case KEY_LEFT:
+{
+size_t nNextPos = nLastPos;
+if ( nLastPos  0 )
+nNextPos = nLastPos - 1;
+pNext = mFilteredItemList[nNextPos];
+}
+break;
+case KEY_DOWN:
+{
+size_t nNextPos = nLastPos;
+if ( bFoundLast  nLastPos  mFilteredItemList.size( ) - 
mnCols )
+nNextPos = nLastPos + mnCols;
+pNext = mFilteredItemList[nNextPos];
+}
+break;
+case KEY_UP:
+{
+size_t nNextPos = nLastPos;
+if ( nLastPos = mnCols )
+nNextPos = nLastPos - mnCols;
+pNext = mFilteredItemList[nNextPos];
+}
+break;
+case KEY_RETURN:
+{
+if ( bFoundLast )
+OnItemDblClicked( mFilteredItemList[nLastPos] );
+}
+default:
+Control::KeyInput( rKEvt );
+}
+
+if ( pNext  pNext-isVisible() )
+{
+deselectItems();
+SelectItem(pNext-mnId);
+}
+}
+
 void ThumbnailView::MouseButtonDown( const MouseEvent rMEvt )
 {
 if ( rMEvt.IsLeft() )
@@ -497,12 +567,17 @@ void ThumbnailView::MouseButtonDown( const MouseEvent 
rMEvt )
 {
 if ( rMEvt.GetClicks() == 1 )
 {
-if (!pItem-isSelected()  !rMEvt.IsMod1())
-

Re: need help debugging unopkg error on centos 6.3

2013-03-22 Thread Neeraj Rai
Hi Michael,

I have closed the bad shell and all new  shells I open are working fine.
Your answers have provided me pointers about how to debug this if it
happens again.
I am trying to build on my knwoledgebase about uno tools as I start to use
them.

thanks
Neeraj


 strace only traces system calls; presumably osl_executeProcess would
 result in clone and some variant of exec on Linux.


 nothing obviously going wrong there.
 there's also no clone or exec* return value indicating failure.
 hmm.. perhaps you should try gdb instead :)

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


RE: LibreOffice for Android (how the overcome the problem with the 50 MB limit)

2013-03-22 Thread Jonathan Aquilina
Question becomes if this is a limit of the play store is there a need to use
the play store. Could we distribute the apk via website download to avoid
the limitation?

-Original Message-
From: libreoffice-bounces+eagles051387=gmail@lists.freedesktop.org
[mailto:libreoffice-bounces+eagles051387=gmail@lists.freedesktop.org] On
Behalf Of Noel Grandin
Sent: 22 March 2013 13:06
To: Tobias Kuban
Cc: Libreoffice@lists.freedesktop.org
Subject: Re: LibreOffice for Android (how the overcome the problem with the
50 MB limit)

On 2013-03-22 14:01, Tobias Kuban wrote:
 Looking forward to use it on Android so long. I recently read an 
 interview where the 50 MB limit would be a huge challenge. According 
 to 
 http://android-developers.blogspot.de/2012/03/android-apps-break-50mb-
 barrier.html
 this limit doesn't exist anymore.
 Best, Tobias Kuban

We know about this, and no, it doesn't solve our immediate problem.

Unless, of course, you are volunteering to implement the splitting of our
APK file into a core installer segment, and an add-on expansion pack?

Disclaimer: http://www.peralex.com/disclaimer.html


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

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


Re: LibreOffice for Android (how the overcome the problem with the 50 MB limit)

2013-03-22 Thread Tor Lillqvist
Please, guys, the size limit, whether it is there or not, in what
sense, and how to work around it if need to, is the least interesting
problem right now. And this is a *development* list.

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


Re: Difficulties to build LO for windows

2013-03-22 Thread Jan Holesovsky
Hi Mitthieu,

Gay, Matthieu píše v Čt 21. 03. 2013 v 12:28 +:

 I get these errors now and I don't know how to resolve them:

 ERROR: error 65280 occurred while
 making /cygdrive/d/libreOffice/git3/libo/wizards/prj
 
 ERROR: error 65280 occurred while
 making /cygdrive/d/libreOffice/git3/libo/svtools/prj
 
 ERROR: error 65280 occurred while
 making /cygdrive/d/libreOffice/git3/libo/nss
 
 ERROR: error 65280 occurred while
 making /cygdrive/d/libreOffice/git3/libo/helpcontent2/source/auxiliary
 
 ERROR: error 65280 occurred while
 making /cygdrive/d/libreOffice/git3/libo/lpsolve

Sorry to hear you are having trouble building LibreOffice :-(

Please, what happened when you followed the advice:
 
 it seems you are using a threaded build, which means that the
 
 actual compile error is probably hidden far above, and could be
 
 inside any of these other modules:
 
  nss helpcontent2 wizards svtools
 
 please re-run build inside each one to isolate the problem.
 
 ---
 
  
 
 /usr/bin/sh
 
 cd D:/libreOffice/git3/libo
 
 source ./Env.Host.sh
 
 cd lpsolve
 
 rm -Rf D:/libreOffice/git3/libo/lpsolve/wntmsci12.pro # optional
 module 'clean'
 
 build

?  Ie. when you changed directory to 'nss', removed wntmsci12.pro there,
and run 'build'?

All the best,
Kendy


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


[PATCH] get rid of two-argument compareToAscii

2013-03-22 Thread Christian Lohmaier (via Code Review)
Hi,

I have submitted a patch for review:

https://gerrit.libreoffice.org/2907

To pull it, you can do:

git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/07/2907/1

get rid of two-argument compareToAscii

As I don't see a point in comparing a mimetype with only a
substring, it probably could be a simple compareToAscii, but
play it save and use startsWith.

Change-Id: Ic33c8089283def615999ddf80cd12f6fe219ed17
---
M vcl/aqua/source/dtrans/DataFlavorMapping.cxx
1 file changed, 1 insertion(+), 1 deletion(-)



diff --git a/vcl/aqua/source/dtrans/DataFlavorMapping.cxx 
b/vcl/aqua/source/dtrans/DataFlavorMapping.cxx
index a1a69ff..6cfc2c9 100644
--- a/vcl/aqua/source/dtrans/DataFlavorMapping.cxx
+++ b/vcl/aqua/source/dtrans/DataFlavorMapping.cxx
@@ -526,7 +526,7 @@
 
   for (size_t i = 0; i  SIZE_FLAVOR_MAP; i++)
 {
-  if (oOOFlavor.MimeType.compareToAscii(flavorMap[i].OOoFlavor, 
strlen(flavorMap[i].OOoFlavor)) == 0)
+  if (oOOFlavor.MimeType.startsWith(flavorMap[i].OOoFlavor))
 {
   sysFlavor = flavorMap[i].SystemFlavor;
 }

-- 
To view, visit https://gerrit.libreoffice.org/2907
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic33c8089283def615999ddf80cd12f6fe219ed17
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Christian Lohmaier lohmaier+libreoff...@googlemail.com

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


[Libreoffice-commits] core.git: odk/CustomTarget_doxygen.mk odk/pack

2013-03-22 Thread Andras Timar
 odk/CustomTarget_doxygen.mk |1 +
 odk/pack/gendocu/Doxyfile   |1 +
 2 files changed, 2 insertions(+)

New commits:
commit d8e83ec04f677333257a5ec539a4bee330f692e6
Author: Andras Timar ati...@suse.com
Date:   Fri Mar 22 14:03:08 2013 +0100

fdo#61790 define PROJECT_NAME in Doxygen config file

Change-Id: I25fc78104cedb83990b1c03f589b50a94890e7da

diff --git a/odk/CustomTarget_doxygen.mk b/odk/CustomTarget_doxygen.mk
index 2aa3832..8bf2a14 100644
--- a/odk/CustomTarget_doxygen.mk
+++ b/odk/CustomTarget_doxygen.mk
@@ -52,6 +52,7 @@ $(odk_WORKDIR)/docs/cpp/ref/index.html: $(DOXY_DEPS)
sed -e 's!^INPUT = %$$!INPUT = $(DOXY_INPUT)!' \
-e 's!^OUTPUT_DIRECTORY = %$$!OUTPUT_DIRECTORY = $(DOXY_WORKDIR)!' \
-e 's!^PROJECT_BRIEF = %$$!PROJECT_BRIEF = $(CPPDOCREFNAME)!' \
+   -e 's!^PROJECT_NAME = %$$!PROJECT_NAME = $(PRODUCTNAME)!' \
 -e 's!^QUIET = %$$!QUIET = $(if $(VERBOSE),NO,YES)!' \
 -e 's!^STRIP_FROM_PATH = %$$!STRIP_FROM_PATH = $(DOXY_STRIP_PATH)!' \
$  $(odk_WORKDIR)/Doxyfile
diff --git a/odk/pack/gendocu/Doxyfile b/odk/pack/gendocu/Doxyfile
index 512a5c0..4cde2ea 100644
--- a/odk/pack/gendocu/Doxyfile
+++ b/odk/pack/gendocu/Doxyfile
@@ -27,6 +27,7 @@
 ##
 
 PROJECT_BRIEF = %
+PROJECT_NAME = %
 OUTPUT_DIRECTORY = %
 STRIP_FROM_PATH = %
 JAVADOC_AUTOBRIEF = YES
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Minutes of ESC call

2013-03-22 Thread Rob Snelders

Op 21-03-13 17:28, Jan Holesovsky schreef:


+ BSA has now French version
+ such bugs go to the French ML first, they'll translate them to
  English  file


Well.. not completely. The mail still doesn't arrive at the fr-qa-list. 
I don't know why and will try next week to solve it.


--
Greetings,
Rob Snelders
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: 3 commits - sd/CppunitTest_sd_uimpress.mk sd/Library_sdfilt.mk sd/Library_sdui.mk sd/source

2013-03-22 Thread Stephan Bergmann
 sd/CppunitTest_sd_uimpress.mk |4 
 sd/Library_sdfilt.mk  |4 
 sd/Library_sdui.mk|4 
 sd/source/filter/html/htmlattr.cxx|5 -
 sd/source/filter/html/pubdlg.cxx  |4 
 sd/source/ui/dlg/PhotoAlbumDialog.cxx |4 
 sd/source/ui/dlg/brkdlg.cxx   |5 -
 sd/source/ui/dlg/copydlg.cxx  |5 -
 sd/source/ui/dlg/custsdlg.cxx |5 -
 sd/source/ui/dlg/dlgass.cxx   |4 
 sd/source/ui/dlg/dlgassim.cxx |4 
 sd/source/ui/dlg/dlgchar.cxx  |6 --
 sd/source/ui/dlg/dlgfield.cxx |7 ---
 sd/source/ui/dlg/dlgolbul.cxx |5 -
 sd/source/ui/dlg/dlgpage.cxx  |5 -
 sd/source/ui/dlg/dlgsnap.cxx  |6 --
 sd/source/ui/dlg/headerfooterdlg.cxx  |5 -
 sd/source/ui/dlg/inspagob.cxx |6 --
 sd/source/ui/dlg/masterlayoutdlg.cxx  |5 -
 sd/source/ui/dlg/morphdlg.cxx |5 -
 sd/source/ui/dlg/paragr.cxx   |5 -
 sd/source/ui/dlg/present.cxx  |4 
 sd/source/ui/dlg/prltempl.cxx |6 --
 sd/source/ui/dlg/prntopts.cxx |6 --
 sd/source/ui/dlg/sddlgfact.cxx|5 -
 sd/source/ui/dlg/sdpreslt.cxx |6 --
 sd/source/ui/dlg/sduiexp.cxx  |5 -
 sd/source/ui/dlg/tabtempl.cxx |5 -
 sd/source/ui/dlg/tpaction.cxx |5 -
 sd/source/ui/dlg/tpoption.cxx |5 -
 sd/source/ui/dlg/vectdlg.cxx  |4 
 31 files changed, 154 deletions(-)

New commits:
commit b1b4695b71368b970ca6fb60b2ae697b1bddd2ac
Author: Stephan Bergmann sberg...@redhat.com
Date:   Thu Mar 21 18:39:38 2013 +0100

No (more?) reason for SD_DLLIMPLEMENTATION in CppunitTest_sd_uimpress

IIRC, this was a quirk with the old build system, dutifully carried across.

Change-Id: Ia66fe04666472a37bdb5f044aa7db09bb337e5eb

diff --git a/sd/CppunitTest_sd_uimpress.mk b/sd/CppunitTest_sd_uimpress.mk
index 094ee32..61af411 100644
--- a/sd/CppunitTest_sd_uimpress.mk
+++ b/sd/CppunitTest_sd_uimpress.mk
@@ -32,10 +32,6 @@ $(eval $(call gb_CppunitTest_set_include,sd_uimpress,\
 -I$(SRCDIR)/sd/inc \
 ))
 
-$(eval $(call gb_CppunitTest_add_defs,sd_uimpress,\
--DSD_DLLIMPLEMENTATION \
-))
-
 $(eval $(call gb_CppunitTest_use_api,sd_uimpress,\
 offapi \
 udkapi \
commit e1c53130a77beec74aefc4cf336229ce76f0870d
Author: Stephan Bergmann sberg...@redhat.com
Date:   Thu Mar 21 18:38:12 2013 +0100

No (more?) reason for SD_DLLIMPLEMENTATION in Library_sdfilt

IIRC, this was a quirk with the old build system, dutifully carried across.

Change-Id: Id2bc5efb645abd3f3074a9e363d643f88d107d1b

diff --git a/sd/Library_sdfilt.mk b/sd/Library_sdfilt.mk
index 5a3..f667dd2 100644
--- a/sd/Library_sdfilt.mk
+++ b/sd/Library_sdfilt.mk
@@ -32,10 +32,6 @@ $(eval $(call gb_Library_set_include,sdfilt,\
 -I$(SRCDIR)/sd/inc \
 ))
 
-$(eval $(call gb_Library_add_defs,sdfilt,\
--DSD_DLLIMPLEMENTATION \
-))
-
 ifneq ($(strip $(dbg_anim_log)$(DBG_ANIM_LOG)),)
 $(eval $(call gb_Library_add_defs,sdfilt,\
 -DDBG_ANIM_LOG \
commit 8da8952561c677dfc3a60f61e93ad880f37714be
Author: Stephan Bergmann sberg...@redhat.com
Date:   Thu Mar 21 18:17:07 2013 +0100

No (more?) reason for SD_DLLIMPLEMENTATION in Library_sdui

In practice, all of the .cxx of that library (except for a handful of newly
introduced ones that had failed to follow the cargo cult) undefined it first
thing before including anything else, anyway.  IIRC, this was a quirk with 
the
old build system, that had dutifully been carried across.

Change-Id: I7642c21af48e15b14f245bbbf3d38fdd365c3c89

diff --git a/sd/Library_sdui.mk b/sd/Library_sdui.mk
index 0501234..a94b757 100644
--- a/sd/Library_sdui.mk
+++ b/sd/Library_sdui.mk
@@ -33,10 +33,6 @@ $(eval $(call gb_Library_set_include,sdui,\
 -I$(SRCDIR)/sd/source/ui/inc \
 ))
 
-$(eval $(call gb_Library_add_defs,sdui,\
--DSD_DLLIMPLEMENTATION \
-))
-
 ifeq ($(ENABLE_SDREMOTE),YES)
 $(eval $(call gb_Library_add_defs,sdui,\
 -DENABLE_SDREMOTE \
diff --git a/sd/source/filter/html/htmlattr.cxx 
b/sd/source/filter/html/htmlattr.cxx
index 1d29675..21ca43a 100644
--- a/sd/source/filter/html/htmlattr.cxx
+++ b/sd/source/filter/html/htmlattr.cxx
@@ -17,11 +17,6 @@
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
 
-
-#ifdef SD_DLLIMPLEMENTATION
-#undef SD_DLLIMPLEMENTATION
-#endif
-
 #include htmlattr.hxx
 #include htmlex.hxx
 #include vcl/decoview.hxx
diff --git a/sd/source/filter/html/pubdlg.cxx b/sd/source/filter/html/pubdlg.cxx
index 0d42988..092cd99 100644
--- a/sd/source/filter/html/pubdlg.cxx
+++ b/sd/source/filter/html/pubdlg.cxx
@@ -17,10 +17,6 @@
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
 
-
-#ifdef SD_DLLIMPLEMENTATION
-#undef 

[Libreoffice-commits] core.git: sfx2/source

2013-03-22 Thread Stephan Bergmann
 sfx2/source/control/thumbnailview.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 68579e6054c660de345a5c95f54fee60b3498f4a
Author: Stephan Bergmann sberg...@redhat.com
Date:   Fri Mar 22 14:35:50 2013 +0100

-Werror,-Wparentheses-equality

Change-Id: I69fd94447718e23ed88af28fed7ba2957559dc5b

diff --git a/sfx2/source/control/thumbnailview.cxx 
b/sfx2/source/control/thumbnailview.cxx
index b73b908..cc05d70 100644
--- a/sfx2/source/control/thumbnailview.cxx
+++ b/sfx2/source/control/thumbnailview.cxx
@@ -777,7 +777,7 @@ void ThumbnailView::RemoveItem( sal_uInt16 nItemId )
 }
 
 // reset variables
-if ( (mnHighItemId == nItemId) )
+if ( mnHighItemId == nItemId )
 {
 mnHighItemId= 0;
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: sw/qa

2013-03-22 Thread Miklos Vajna
 sw/qa/extras/odfimport/data/fdo55814.odt |binary
 sw/qa/extras/odfimport/odfimport.cxx |   16 
 2 files changed, 16 insertions(+)

New commits:
commit f7b5afc895930f0ef67b2c67c98fc429f45e067d
Author: Miklos Vajna vmik...@suse.cz
Date:   Fri Mar 22 14:21:29 2013 +0100

testcase for 62344016de056965a58ea2016d912a68eac0d6b0

Change-Id: I5d7544f38c5d48826cad18a655ffd3b621eb0ca2

diff --git a/sw/qa/extras/odfimport/data/fdo55814.odt 
b/sw/qa/extras/odfimport/data/fdo55814.odt
new file mode 100644
index 000..890fa4b
Binary files /dev/null and b/sw/qa/extras/odfimport/data/fdo55814.odt differ
diff --git a/sw/qa/extras/odfimport/odfimport.cxx 
b/sw/qa/extras/odfimport/odfimport.cxx
index 3bef663..d9b37d2 100644
--- a/sw/qa/extras/odfimport/odfimport.cxx
+++ b/sw/qa/extras/odfimport/odfimport.cxx
@@ -45,6 +45,7 @@ public:
 void testFdo61952();
 void testFdo60842();
 void testFdo56272();
+void testFdo55814();
 
 CPPUNIT_TEST_SUITE(Test);
 #if !defined(MACOSX)  !defined(WNT)
@@ -67,6 +68,7 @@ void Test::run()
 {hello.odt, Test::testFdo61952},
 {fdo60842.odt, Test::testFdo60842},
 {fdo56272.odt, Test::testFdo56272},
+{fdo55814.odt, Test::testFdo55814},
 };
 header();
 for (unsigned int i = 0; i  SAL_N_ELEMENTS(aMethods); ++i)
@@ -325,6 +327,20 @@ void Test::testFdo56272()
 CPPUNIT_ASSERT_EQUAL(sal_Int32(422), xShape-getPosition().Y); // Was -2371
 }
 
+void Test::testFdo55814()
+{
+uno::Referencetext::XTextFieldsSupplier xTextFieldsSupplier(mxComponent, 
uno::UNO_QUERY);
+uno::Referencecontainer::XEnumerationAccess 
xFieldsAccess(xTextFieldsSupplier-getTextFields());
+uno::Referencecontainer::XEnumeration 
xFields(xFieldsAccess-createEnumeration());
+uno::Referencebeans::XPropertySet xField(xFields-nextElement(), 
uno::UNO_QUERY);
+xField-setPropertyValue(Content, uno::makeAny(OUString(Yes)));
+uno::Referenceutil::XRefreshable(xTextFieldsSupplier-getTextFields(), 
uno::UNO_QUERY)-refresh();
+uno::Referencetext::XTextSectionsSupplier 
xTextSectionsSupplier(mxComponent, uno::UNO_QUERY);
+uno::Referencecontainer::XIndexAccess 
xSections(xTextSectionsSupplier-getTextSections(), uno::UNO_QUERY);
+// This was 0.
+CPPUNIT_ASSERT_EQUAL(OUString(Hide==\Yes\), 
getPropertyOUString(xSections-getByIndex(0), Condition));
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(Test);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'feature/formula-core-rework' - sc/inc sc/source

2013-03-22 Thread Kohei Yoshida
 sc/inc/document.hxx  |2 --
 sc/source/core/data/cell2.cxx|2 +-
 sc/source/core/data/document.cxx |   22 --
 sc/source/core/data/table6.cxx   |   15 ---
 sc/source/ui/app/transobj.cxx|1 -
 sc/source/ui/undo/undocell.cxx   |4 +++-
 6 files changed, 16 insertions(+), 30 deletions(-)

New commits:
commit 70af04307ad62f362a18318096a37d425bbd8f35
Author: Kohei Yoshida kohei.yosh...@gmail.com
Date:   Fri Mar 22 09:41:42 2013 -0400

Remove a variant of PutCell().

Change-Id: I6100d30954536a3683be69363f1fc13d54cacfef

diff --git a/sc/inc/document.hxx b/sc/inc/document.hxx
index 783281e..e0f19cd 100644
--- a/sc/inc/document.hxx
+++ b/sc/inc/document.hxx
@@ -744,8 +744,6 @@ public:
 SC_DLLPUBLIC void EnsureTable( SCTAB nTab );
 
 SC_DLLPUBLIC void   PutCell( const ScAddress, ScBaseCell* pCell, 
bool bForceTab = false );
-SC_DLLPUBLIC void   PutCell( SCCOL nCol, SCROW nRow, SCTAB nTab, 
ScBaseCell* pCell,
-bool bForceTab = false );
 SC_DLLPUBLIC void   PutCell(SCCOL nCol, SCROW nRow, SCTAB nTab, 
ScBaseCell* pCell,
 sal_uLong nFormatIndex, bool bForceTab = false);
 //  return TRUE = number format is set
diff --git a/sc/source/core/data/cell2.cxx b/sc/source/core/data/cell2.cxx
index 5bd3846..0e217f2 100644
--- a/sc/source/core/data/cell2.cxx
+++ b/sc/source/core/data/cell2.cxx
@@ -1442,7 +1442,7 @@ void ScFormulaCell::UpdateTranspose( const ScRange 
rSource, const ScAddress rD
 ScFormulaCell* pFCell = new ScFormulaCell( pUndoDoc, aPos, pOld,
 eTempGrammar, cMatrixFlag);
 pFCell-aResult.SetToken( NULL);  // to recognize it as changed 
later (Cut/Paste!)
-pUndoDoc-PutCell( aPos.Col(), aPos.Row(), aPos.Tab(), pFCell );
+pUndoDoc-SetFormulaCell(aPos, pFCell);
 }
 
 bCompile = true;
diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
index d5ceb08..7064ee2 100644
--- a/sc/source/core/data/document.cxx
+++ b/sc/source/core/data/document.cxx
@@ -2925,28 +2925,6 @@ void ScDocument::FillTabMarked( SCTAB nSrcTab, const 
ScMarkData rMark,
 }
 }
 
-
-void ScDocument::PutCell( SCCOL nCol, SCROW nRow, SCTAB nTab, ScBaseCell* 
pCell, bool bForceTab )
-{
-if (ValidTab(nTab))
-{
-if ( bForceTab  ( nTab = static_castSCTAB(maTabs.size()) || 
!maTabs[nTab]) )
-{
-bool bExtras = !bIsUndo;// Spaltenbreiten, Zeilenhoehen, 
Flags
-
-if (nTab = static_castSCTAB(maTabs.size()))
-maTabs.resize(nTab + 1,NULL);
-maTabs[nTab] = new ScTable(this, nTab,
-OUString(temp),
-bExtras, bExtras);
-}
-
-if (maTabs[nTab])
-maTabs[nTab]-PutCell( nCol, nRow, pCell );
-}
-}
-
-
 void ScDocument::PutCell( const ScAddress rPos, ScBaseCell* pCell, bool 
bForceTab )
 {
 SCTAB nTab = rPos.Tab();
diff --git a/sc/source/core/data/table6.cxx b/sc/source/core/data/table6.cxx
index 640ed59..6df2249 100644
--- a/sc/source/core/data/table6.cxx
+++ b/sc/source/core/data/table6.cxx
@@ -31,6 +31,7 @@
 #include editutil.hxx
 #include detfunc.hxx
 #include postit.hxx
+#include stringutil.hxx
 
 //--
 
@@ -966,10 +967,14 @@ bool ScTable::SearchRangeForAllEmptyCells(
 {
 aCol[nCol].Insert(i, new ScStringCell(rNewStr));
 if (pUndoDoc)
+{
 // TODO: I'm using a string cell with empty 
content to
 // trigger deletion of cell instance on undo.  
Maybe I
 // should create a new cell type for this?
-pUndoDoc-PutCell(nCol, i, nTab, new 
ScStringCell(String()));
+ScSetStringParam aParam;
+aParam.setTextInput();
+pUndoDoc-SetString(ScAddress(nCol, i, nTab), 
EMPTY_OUSTRING);
+}
 }
 rUndoStr = String();
 }
@@ -999,10 +1004,14 @@ bool ScTable::SearchRangeForAllEmptyCells(
 {
 aCol[nCol].Insert(nRow, new 
ScStringCell(rSearchItem.GetReplaceString()));
 if (pUndoDoc)
+{
 // TODO: I'm using a string cell with empty content to
 // trigger deletion of cell instance on undo.  Maybe I
 // should create a new cell type for this?
-pUndoDoc-PutCell(nCol, nRow, nTab, new 
ScStringCell(String()));
+ScSetStringParam aParam;
+

Re: NumericBox unsafe double conversion

2013-03-22 Thread Zolnai Tamás
2013/3/22 Stephan Bergmann sberg...@redhat.com

 On 03/22/2013 11:44 AM, Zolnai Tamás wrote:

 Otherwise in ImplNumericGetValue() the problem of overflow/underflow can
 be avoid with these lines
 sal_Int64 nValue = aStr.toInt64()
 if( OUString::valueOf(nValue) != aStr )
 {
  if( bNegative )
  rValue = SAL_MIN_INT64;
  else
  rValue = SAL_MAX_INT64;
  return sal_True;
 }


 ...but only if aStr is known to be in canonical form, esp. neither
 contains minus zero nor contains excessive leading zero digits.  None of
 that is guaranteed for ImplNumericGetValue in its current form (and also
 consider nDecDigits  0, where input rStr=0 and nDecDigits=2, say, would
 lead to aStr=000 and the above comparison erroneously failing).


Oh, that's true. Thanks. I extend the check to take notice of these two
things.
From that matter, why is that the toInt64() function doesn't pay attention
on overflow/underflow? Maybe it would simpler to handle these flows in
that function.


Regards,
Tamás
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: libmariadb/configs libmariadb/my_config.h libmariadb/mysql_version.h libmariadb/UnpackedTarball_mariadb.mk

2013-03-22 Thread Fridrich Štrba
 libmariadb/UnpackedTarball_mariadb.mk |   12 -
 libmariadb/configs/linux_my_config.h  |  297 ++
 libmariadb/configs/mac_my_config.h|  277 +++
 libmariadb/configs/mysql_version.h|   24 ++
 libmariadb/my_config.h|  164 --
 libmariadb/mysql_version.h|   24 --
 6 files changed, 606 insertions(+), 192 deletions(-)

New commits:
commit ab374c8e5d3b41e7cda2b7f55ad209683ffa48fe
Author: Fridrich Å trba fridrich.st...@bluewin.ch
Date:   Fri Mar 22 15:00:31 2013 +0100

Some more granularity in the libmariadb build

Change-Id: I99a6506443c789fb278684464a3973c1b4961ba4

diff --git a/libmariadb/UnpackedTarball_mariadb.mk 
b/libmariadb/UnpackedTarball_mariadb.mk
index fa3324e..f80bed6 100644
--- a/libmariadb/UnpackedTarball_mariadb.mk
+++ b/libmariadb/UnpackedTarball_mariadb.mk
@@ -11,11 +11,15 @@ $(eval $(call gb_UnpackedTarball_UnpackedTarball,mariadb))
 
 $(eval $(call gb_UnpackedTarball_set_tarball,mariadb,$(MARIADB_TARBALL)))
 
-# This was generated on a 64-bit linux, will have to conditionalize it if it 
is broken
-# for another configuration.
-$(eval $(call 
gb_UnpackedTarball_add_file,mariadb,include/my_config.h,libmariadb/my_config.h))
+$(eval $(call 
gb_UnpackedTarball_add_file,mariadb,include/mysql_version.h,libmariadb/configs/mysql_version.h))
 
-$(eval $(call 
gb_UnpackedTarball_add_file,mariadb,include/mysql_version.h,libmariadb/mysql_version.h))
+ifneq ($(OS),WNT)
+ifeq ($(OS),MACOSX)
+$(eval $(call 
gb_UnpackedTarball_add_file,mariadb,include/my_config.h,libmariadb/configs/mac_my_config.h))
+else
+$(eval $(call 
gb_UnpackedTarball_add_file,mariadb,include/my_config.h,libmariadb/configs/linux_my_config.h))
+endif
+endif # $(OS),WNT
 
 $(eval $(call gb_UnpackedTarball_set_patchlevel,mariadb,1))
 
diff --git a/libmariadb/configs/linux_my_config.h 
b/libmariadb/configs/linux_my_config.h
new file mode 100644
index 000..817fa9e
--- /dev/null
+++ b/libmariadb/configs/linux_my_config.h
@@ -0,0 +1,297 @@
+
+#define HAVE_GETHOSTBYNAME_R_GLIBC2_STYLE 1
+
+/*
+ * Include file constants (processed in LibmysqlIncludeFiles.txt 1
+ */
+#define HAVE_ALLOCA_H 1
+#define HAVE_ARPA_INET_H 1
+#define HAVE_CRYPT_H 1
+#define HAVE_DIRENT_H 1
+#define HAVE_DLFCN_H 1
+#define HAVE_EXECINFO_H 1
+#define HAVE_FCNTL_H 1
+#define HAVE_FENV_H 1
+#define HAVE_FLOAT_H 1
+/* #undef HAVE_FPU_CONTROL_H */
+#define HAVE_GRP_H 1
+/* #undef HAVE_IEEEFP_H */
+#define HAVE_LIMITS_H 1
+#define HAVE_MALLOC_H 1
+#define HAVE_MEMORY_H 1
+#define HAVE_NETINET_IN_H 1
+#define HAVE_PATHS_H 1
+#define HAVE_PWD_H 1
+#define HAVE_SCHED_H 1
+/* #undef HAVE_SELECT_H */
+#define HAVE_STDDEF_H 1
+#define HAVE_STDINT_H 1
+#define HAVE_STDLIB_H 1
+#define HAVE_STRING_H 1
+#define HAVE_STRINGS_H 1
+/* #undef HAVE_SYNCH_H */
+/* #undef HAVE_SYS_FPU_H */
+#define HAVE_SYS_IOCTL_H 1
+#define HAVE_SYS_IPC_H 1
+#define HAVE_SYS_MMAN_H 1
+#define HAVE_SYS_PRCTL_H 1
+#define HAVE_SYS_SELECT_H 1
+#define HAVE_SYS_SHM_H 1
+#define HAVE_SYS_SOCKET_H 1
+#define HAVE_SYS_STAT_H 1
+/* #undef HAVE_SYS_STREAM_H */
+#define HAVE_SYS_TIMEB_H 1
+#define HAVE_SYS_TYPES_H 1
+#define HAVE_SYS_UN_H 1
+/* #undef HAVE_SYSENT_H */
+#define HAVE_TERMIO_H 1
+#define HAVE_TERMIOS_H 1
+#define HAVE_UNISTD_H 1
+#define HAVE_UTIME_H 1
+
+/*
+ * function definitions - processed in LibmysqlFunctions.txt 
+ */
+#define HAVE_ACCESS 1
+/* #undef HAVE_AIOWAIT */
+#define HAVE_ALARM 1
+/* #undef HAVE_ALLOCA */
+#define HAVE_BCMP 1
+/* #undef HAVE_BFILL */
+/* #undef HAVE_BMOVE */
+#define HAVE_BZERO 1
+/* #undef HAVE_CLOCK_GETTIME */
+/* #undef HAVE_COMPRESS */
+/* #undef HAVE_CRYPT */
+#define HAVE_DLERROR 1
+#define HAVE_DLOPEN 1
+#define HAVE_FCHMOD 1
+#define HAVE_FCNTL 1
+/* #undef HAVE_FCONVERT */
+#define HAVE_FDATASYNC 1
+/* #undef HAVE_FESETROUND */
+#define HAVE_FINITE 1
+#define HAVE_FSEEKO 1
+#define HAVE_FSYNC 1
+#define HAVE_GETADDRINFO 1
+#define HAVE_GETCWD 1
+#define HAVE_GETHOSTBYADDR_R 1
+#define HAVE_GETHOSTBYNAME_R 1
+/* #undef HAVE_GETHRTIME */
+#define HAVE_GETNAMEINFO 1
+#define HAVE_GETPAGESIZE 1
+#define HAVE_GETPASS 1
+/* #undef HAVE_GETPASSPHRASE */
+#define HAVE_GETPWNAM 1
+#define HAVE_GETPWUID 1
+#define HAVE_GETRLIMIT 1
+#define HAVE_GETRUSAGE 1
+#define HAVE_GETWD 1
+#define HAVE_GMTIME_R 1
+#define HAVE_INITGROUPS 1
+#define HAVE_LDIV 1
+#define HAVE_LOCALTIME_R 1
+/* #undef HAVE_LOG2 */
+#define HAVE_LONGJMP 1
+#define HAVE_LSTAT 1
+#define HAVE_MADVISE 1
+#define HAVE_MALLINFO 1
+#define HAVE_MEMALIGN 1
+#define HAVE_MEMCPY 1
+#define HAVE_MEMMOVE 1
+#define HAVE_MKSTEMP 1
+#define HAVE_MLOCK 1
+#define HAVE_MLOCKALL 1
+#define HAVE_MMAP 1
+#define HAVE_MMAP64 1
+#define HAVE_PERROR 1
+#define HAVE_POLL 1
+#define HAVE_PREAD 1
+/* #undef HAVE_PTHREAD_ATTR_CREATE */
+/* #undef HAVE_PTHREAD_ATTR_GETSTACKSIZE */
+/* #undef HAVE_PTHREAD_ATTR_SETPRIO */
+#define HAVE_PTHREAD_ATTR_SETSCHEDPARAM 1
+#define HAVE_PTHREAD_ATTR_SETSCOPE 1
+/* 

[Libreoffice-commits] core.git: libmariadb/configs

2013-03-22 Thread Fridrich Štrba
 libmariadb/configs/linux_my_config.h |   44 +--
 libmariadb/configs/mac_my_config.h   |   44 +--
 2 files changed, 44 insertions(+), 44 deletions(-)

New commits:
commit e8a526e1f5626673a572d53dc1c8db6d8aadba13
Author: Fridrich Å trba fridrich.st...@bluewin.ch
Date:   Fri Mar 22 15:23:20 2013 +0100

Remove some unnecessary warnings

Change-Id: I19a8931e8cda700c87d632fb6abeda9fa88c6041

diff --git a/libmariadb/configs/linux_my_config.h 
b/libmariadb/configs/linux_my_config.h
index 817fa9e..6007d85 100644
--- a/libmariadb/configs/linux_my_config.h
+++ b/libmariadb/configs/linux_my_config.h
@@ -160,7 +160,7 @@
  */
 /* Types we may use */
 #define SIZEOF_CHAR 1
-#if SIZEOF_CHAR
+#ifdef SIZEOF_CHAR
 # define HAVE_CHAR 1
 #endif
 
@@ -169,17 +169,17 @@
 #else
 #define SIZEOF_CHARP 4
 #endif
-#if SIZEOF_CHARP
+#ifdef SIZEOF_CHARP
 # define HAVE_CHARP 1
 #endif
 
 #define SIZEOF_SHORT 2
-#if SIZEOF_SHORT
+#ifdef SIZEOF_SHORT
 # define HAVE_SHORT 1
 #endif
 
 #define SIZEOF_INT 4
-#if SIZEOF_INT
+#ifdef SIZEOF_INT
 # define HAVE_INT 1
 #endif
 
@@ -188,12 +188,12 @@
 #else
 #define SIZEOF_LONG 4
 #endif
-#if SIZEOF_LONG
+#ifdef SIZEOF_LONG
 # define HAVE_LONG 1
 #endif
 
 #define SIZEOF_LONG_LONG 8
-#if SIZEOF_LONG_LONG
+#ifdef SIZEOF_LONG_LONG
 # define HAVE_LONG_LONG 1
 #endif
 
@@ -202,12 +202,12 @@
 #else
 #define SIZEOF_OFF_T 4
 #endif
-#if SIZEOF_OFF_T
+#ifdef SIZEOF_OFF_T
 # define HAVE_OFF_T 1
 #endif
 
 #define SIZEOF_SIGSET_T 128
-#if SIZEOF_SIGSET_T
+#ifdef SIZEOF_SIGSET_T
 # define HAVE_SIGSET_T 1
 #endif
 
@@ -216,17 +216,17 @@
 #else
 #define SIZEOF_SIZE_T 4
 #endif
-#if SIZEOF_SIZE_T
+#ifdef SIZEOF_SIZE_T
 # define HAVE_SIZE_T 1
 #endif
 
 /* #undef SIZEOF_UCHAR */
-#if SIZEOF_UCHAR
+#ifdef SIZEOF_UCHAR
 # define HAVE_UCHAR 1
 #endif
 
 #define SIZEOF_UINT 4
-#if SIZEOF_UINT
+#ifdef SIZEOF_UINT
 # define HAVE_UINT 1
 #endif
 
@@ -235,52 +235,52 @@
 #else
 #define SIZEOF_ULONG 4
 #endif
-#if SIZEOF_ULONG
+#ifdef SIZEOF_ULONG
 # define HAVE_ULONG 1
 #endif
 
 /* #undef SIZEOF_INT8 */
-#if SIZEOF_INT8
+#ifdef SIZEOF_INT8
 # define HAVE_INT8 1
 #endif
 /* #undef SIZEOF_UINT8 */
-#if SIZEOF_UINT8
+#ifdef SIZEOF_UINT8
 # define HAVE_UINT8 1
 #endif
 
 /* #undef SIZEOF_INT16 */
-#if SIZEOF_INT16
+#ifdef SIZEOF_INT16
 # define HAVE_INT16 1
 #endif
 /* #undef SIZEOF_UINT16 */
-#if SIZEOF_UINT16
+#ifdef SIZEOF_UINT16
 # define HAVE_UINT16 1
 #endif
 
 /* #undef SIZEOF_INT32 */
-#if SIZEOF_INT32
+#ifdef SIZEOF_INT32
 # define HAVE_INT32 1
 #endif
 /* #undef SIZEOF_UINT32 */
-#if SIZEOF_UINT32
+#ifdef SIZEOF_UINT32
 # define HAVE_UINT32 1
 #endif
 /* #undef SIZEOF_U_INT32_T */
-#if SIZEOF_U_INT32_T
+#ifdef SIZEOF_U_INT32_T
 # define HAVE_U_INT32_T 1
 #endif
 
 /* #undef SIZEOF_INT64 */
-#if SIZEOF_INT64
+#ifdef SIZEOF_INT64
 # define HAVE_INT64 1
 #endif
 /* #undef SIZEOF_UINT64 */
-#if SIZEOF_UINT64
+#ifdef SIZEOF_UINT64
 # define HAVE_UINT64 1
 #endif
 
 /* #undef SIZEOF_SOCKLEN_T */
-#if SIZEOF_SOCKLEN_T
+#ifdef SIZEOF_SOCKLEN_T
 # define HAVE_SOCKLEN_T 1
 #endif
 
diff --git a/libmariadb/configs/mac_my_config.h 
b/libmariadb/configs/mac_my_config.h
index 44d822f..baa4f18 100644
--- a/libmariadb/configs/mac_my_config.h
+++ b/libmariadb/configs/mac_my_config.h
@@ -160,107 +160,107 @@
  */
 /* Types we may use */
 #define SIZEOF_CHAR 1
-#if SIZEOF_CHAR
+#ifdef SIZEOF_CHAR
 # define HAVE_CHAR 1
 #endif
 
 #define SIZEOF_CHARP 4
-#if SIZEOF_CHARP
+#ifdef SIZEOF_CHARP
 # define HAVE_CHARP 1
 #endif
 
 #define SIZEOF_SHORT 2
-#if SIZEOF_SHORT
+#ifdef SIZEOF_SHORT
 # define HAVE_SHORT 1
 #endif
 
 #define SIZEOF_INT 4
-#if SIZEOF_INT
+#ifdef SIZEOF_INT
 # define HAVE_INT 1
 #endif
 
 #define SIZEOF_LONG 4
-#if SIZEOF_LONG
+#ifdef SIZEOF_LONG
 # define HAVE_LONG 1
 #endif
 
 #define SIZEOF_LONG_LONG 8
-#if SIZEOF_LONG_LONG
+#ifdef SIZEOF_LONG_LONG
 # define HAVE_LONG_LONG 1
 #endif
 
 #define SIZEOF_OFF_T 8
-#if SIZEOF_OFF_T
+#ifdef SIZEOF_OFF_T
 # define HAVE_OFF_T 1
 #endif
 
 #define SIZEOF_SIGSET_T 4
-#if SIZEOF_SIGSET_T
+#ifdef SIZEOF_SIGSET_T
 # define HAVE_SIGSET_T 1
 #endif
 
 #define SIZEOF_SIZE_T 4
-#if SIZEOF_SIZE_T
+#ifdef SIZEOF_SIZE_T
 # define HAVE_SIZE_T 1
 #endif
 
 /* #undef SIZEOF_UCHAR */
-#if SIZEOF_UCHAR
+#ifdef SIZEOF_UCHAR
 # define HAVE_UCHAR 1
 #endif
 
 #define SIZEOF_UINT 4
-#if SIZEOF_UINT
+#ifdef SIZEOF_UINT
 # define HAVE_UINT 1
 #endif
 
 /* #undef SIZEOF_ULONG */
-#if SIZEOF_ULONG
+#ifdef SIZEOF_ULONG
 # define HAVE_ULONG 1
 #endif
 
 /* #undef SIZEOF_INT8 */
-#if SIZEOF_INT8
+#ifdef SIZEOF_INT8
 # define HAVE_INT8 1
 #endif
 /* #undef SIZEOF_UINT8 */
-#if SIZEOF_UINT8
+#ifdef SIZEOF_UINT8
 # define HAVE_UINT8 1
 #endif
 
 /* #undef SIZEOF_INT16 */
-#if SIZEOF_INT16
+#ifdef SIZEOF_INT16
 # define HAVE_INT16 1
 #endif
 /* #undef SIZEOF_UINT16 */
-#if SIZEOF_UINT16
+#ifdef SIZEOF_UINT16
 # define HAVE_UINT16 1
 #endif
 
 /* #undef SIZEOF_INT32 */
-#if SIZEOF_INT32
+#ifdef SIZEOF_INT32
 # define HAVE_INT32 1
 

[Libreoffice-commits] core.git: 2 commits - comphelper/inc comphelper/source sd/source xmloff/source

2013-03-22 Thread Michael Stahl
 comphelper/inc/comphelper/propertysethelper.hxx  |   10 -
 comphelper/source/property/propertysethelper.cxx |   11 +++---
 sd/source/ui/unoidl/UnoDocumentSettings.cxx  |   25 +--
 xmloff/source/draw/sdxmlexp.cxx  |   15 ++---
 4 files changed, 43 insertions(+), 18 deletions(-)

New commits:
commit 3605407693c83e5e5e0af6f7ec4a3863bc7178b0
Author: Michael Stahl mst...@redhat.com
Date:   Fri Mar 22 14:24:13 2013 +0100

sd::DocumentSettings: throwing UnknownPropertyException ...

... for properties that are in the PropertySetInfo just because there's
no document or shell is just plain wrong.

Change-Id: I84f4f930f492753b20ba04ec4d41c905d674b9ba

diff --git a/comphelper/inc/comphelper/propertysethelper.hxx 
b/comphelper/inc/comphelper/propertysethelper.hxx
index 6aa647f..c9f1b4d 100644
--- a/comphelper/inc/comphelper/propertysethelper.hxx
+++ b/comphelper/inc/comphelper/propertysethelper.hxx
@@ -46,12 +46,12 @@ private:
 PropertySetHelperImpl* mp;
 
 protected:
-virtual void _setPropertyValues( const comphelper::PropertyMapEntry** 
ppEntries, const ::com::sun::star::uno::Any* pValues ) 
throw(::com::sun::star::beans::UnknownPropertyException, 
::com::sun::star::beans::PropertyVetoException, 
::com::sun::star::lang::IllegalArgumentException, 
::com::sun::star::lang::WrappedTargetException ) = 0;
-virtual void _getPropertyValues( const comphelper::PropertyMapEntry** 
ppEntries, ::com::sun::star::uno::Any* pValue ) 
throw(::com::sun::star::beans::UnknownPropertyException, 
::com::sun::star::lang::WrappedTargetException ) = 0;
+virtual void _setPropertyValues( const comphelper::PropertyMapEntry** 
ppEntries, const ::com::sun::star::uno::Any* pValues ) 
throw(::com::sun::star::beans::UnknownPropertyException, 
::com::sun::star::beans::PropertyVetoException, 
::com::sun::star::lang::IllegalArgumentException, 
::com::sun::star::lang::WrappedTargetException, 
::com::sun::star::uno::RuntimeException ) = 0;
+virtual void _getPropertyValues( const comphelper::PropertyMapEntry** 
ppEntries, ::com::sun::star::uno::Any* pValue ) 
throw(::com::sun::star::beans::UnknownPropertyException, 
::com::sun::star::lang::WrappedTargetException, 
::com::sun::star::uno::RuntimeException ) = 0;
 
-virtual void _getPropertyStates( const comphelper::PropertyMapEntry** 
ppEntries, ::com::sun::star::beans::PropertyState* pStates ) 
throw(::com::sun::star::beans::UnknownPropertyException );
-virtual void _setPropertyToDefault( const comphelper::PropertyMapEntry* 
pEntry )  throw(::com::sun::star::beans::UnknownPropertyException );
-virtual ::com::sun::star::uno::Any _getPropertyDefault( const 
comphelper::PropertyMapEntry* pEntry ) 
throw(::com::sun::star::beans::UnknownPropertyException, 
::com::sun::star::lang::WrappedTargetException );
+virtual void _getPropertyStates( const comphelper::PropertyMapEntry** 
ppEntries, ::com::sun::star::beans::PropertyState* pStates ) 
throw(::com::sun::star::beans::UnknownPropertyException, 
::com::sun::star::uno::RuntimeException );
+virtual void _setPropertyToDefault( const comphelper::PropertyMapEntry* 
pEntry )  throw(::com::sun::star::beans::UnknownPropertyException, 
::com::sun::star::uno::RuntimeException );
+virtual ::com::sun::star::uno::Any _getPropertyDefault( const 
comphelper::PropertyMapEntry* pEntry ) 
throw(::com::sun::star::beans::UnknownPropertyException, 
::com::sun::star::lang::WrappedTargetException, 
::com::sun::star::uno::RuntimeException );
 
 public:
 PropertySetHelper( comphelper::PropertySetInfo* pInfo ) throw();
diff --git a/comphelper/source/property/propertysethelper.cxx 
b/comphelper/source/property/propertysethelper.cxx
index 979f1c9..27b4c0e 100644
--- a/comphelper/source/property/propertysethelper.cxx
+++ b/comphelper/source/property/propertysethelper.cxx
@@ -282,17 +282,22 @@ Any SAL_CALL PropertySetHelper::getPropertyDefault( const 
::rtl::OUString aProp
 return _getPropertyDefault( pEntry );
 }
 
-void PropertySetHelper::_getPropertyStates( const 
comphelper::PropertyMapEntry**, PropertyState* ) throw(UnknownPropertyException 
)
+void PropertySetHelper::_getPropertyStates(
+const comphelper::PropertyMapEntry**, PropertyState*)
+throw (UnknownPropertyException, RuntimeException)
 {
 OSL_FAIL( you have to implement this yourself!);
 }
 
-void PropertySetHelper::_setPropertyToDefault( const 
comphelper::PropertyMapEntry* )  throw(UnknownPropertyException )
+void
+PropertySetHelper::_setPropertyToDefault(const comphelper::PropertyMapEntry*)
+throw (UnknownPropertyException, RuntimeException)
 {
 OSL_FAIL( you have to implement this yourself!);
 }
 
-Any PropertySetHelper::_getPropertyDefault( const 
comphelper::PropertyMapEntry* ) throw(UnknownPropertyException, 
WrappedTargetException )
+Any PropertySetHelper::_getPropertyDefault(const comphelper::PropertyMapEntry*)
+throw (UnknownPropertyException, WrappedTargetException, 

[Libreoffice-commits] core.git: configure.ac

2013-03-22 Thread Fridrich Štrba
 configure.ac |6 --
 1 file changed, 6 deletions(-)

New commits:
commit 9f78c8ed2c1ebeed54621ff3d4c0e5a7b9e811b3
Author: Fridrich Å trba fridrich.st...@bluewin.ch
Date:   Fri Mar 22 15:36:34 2013 +0100

Removing some old HH crack

Change-Id: I4b9b2db500af6cff2cfb1bc17002baf08715

diff --git a/configure.ac b/configure.ac
index 9a69275..7aaacba 100644
--- a/configure.ac
+++ b/configure.ac
@@ -7608,12 +7608,6 @@ int main(int argc, char **argv) {
 LIBS=$save_LIBS
 else
 AC_MSG_RESULT([internal])
-AC_MSG_CHECKING([for mysqlcppconn module])
-if test -d mysqlcppconn; then
-AC_MSG_RESULT([OK])
-else
-AC_MSG_ERROR([not existing. get it (did you get the -extensions 
tarball?)])
-fi
 BUILD_TYPE=$BUILD_TYPE MYSQLCPPCONN
 SYSTEM_MYSQL_CPPCONN=NO
 fi
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[ANN] LibreOffice 3.6.6 RC1 available

2013-03-22 Thread Thorsten Behrens
Dear Community,

The Document Foundation is happy to announce the first release
candidate of LibreOffice 3.6.6. The upcoming 3.6.6 will be the sixth
in a series of frequent bugfix releases for our stable 3.6
branch. Please be aware that LibreOffice 3.6.6 RC1 is not ready for
production use, you should continue to use LibreOffice 3.6.5 for that.

The release is available for Windows, Linux and Mac OS X from our QA
builds download page at

  http://www.libreoffice.org/download/pre-releases/

Should you find bugs, please report them to the FreeDesktop Bugzilla:

  https://bugs.freedesktop.org

A good way to assess the release candidate quality is to run some
specific manual tests on it, our TCM wiki page has more details:

 
http://wiki.documentfoundation.org/QA/Testing/Regression_Tests#Full_Regression_Test

  - or checkout our manual test database for starting right away -

 http://manual-test.libreoffice.org/runtests/

For other ways to get involved with this exciting project - you can
e.g. contribute code:

  http://www.libreoffice.org/get-involved/developers/

translate LibreOffice to your language:

  http://wiki.documentfoundation.org/Translation_for_3.5

or help with funding our operations:

  http://donate.libreoffice.org/

A list of known issues and fixed bugs with 3.6.6 RC1 is available
from our wiki:

  http://wiki.documentfoundation.org/Releases/3.6.6/RC1

Let us close again with a BIG Thank You! to all of you having
contributed to the LibreOffice project - this release would not have
been possible without your help.

Yours,

The Document Foundation Board of Directors

The Document Foundation, Zimmerstr. 69, 10117 Berlin, Germany
Rechtsfähige Stiftung des bürgerlichen Rechts
Legal details: http://www.documentfoundation.org/imprint


signature.asc
Description: Digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


TemplateManager refactoring

2013-03-22 Thread Cedric Bosdonnat
Hello Rafael,

I just hit another problem due to the TemplateView class. Did you manage
to merge this one back into the TemplateAbstractView?

I'll try to workaround it for the while... but it would really be
awesome to have that in ;)

Regards,
--
Cedric

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


[PATCH libreoffice-4-0-2] fdo#60769 implement odf export of multi-paragraph comment ra...

2013-03-22 Thread Miklos Vajna (via Code Review)
Hi,

I have submitted a patch for review:

https://gerrit.libreoffice.org/2908

To pull it, you can do:

git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/08/2908/1

fdo#60769 implement odf export of multi-paragraph comment ranges

(cherry picked from commits 287c254d5ebf9b58ca63a8c271e523adf0d34b82 and
1fba17854b2be4fdbe436f44da3ae57a1f75a27c)

Conflicts:
sw/qa/extras/odfexport/odfexport.cxx

Reviewed-on: https://gerrit.libreoffice.org/2873
Reviewed-by: Noel Power noel.po...@suse.com
Tested-by: Noel Power noel.po...@suse.com

(cherry picked from commit 473cd59a71706ada01f8be68c7dfd008ca9bb716)

Change-Id: Ic4a5a1bc685917f2b26be4ab645203f706719c80
---
A sw/qa/extras/odfexport/data/fdo60769.odt
M sw/qa/extras/odfexport/odfexport.cxx
M sw/source/core/unocore/unoportenum.cxx
M xmloff/source/text/txtparae.cxx
4 files changed, 52 insertions(+), 8 deletions(-)



diff --git a/sw/qa/extras/odfexport/data/fdo60769.odt 
b/sw/qa/extras/odfexport/data/fdo60769.odt
new file mode 100644
index 000..b3c3937
--- /dev/null
+++ b/sw/qa/extras/odfexport/data/fdo60769.odt
Binary files differ
diff --git a/sw/qa/extras/odfexport/odfexport.cxx 
b/sw/qa/extras/odfexport/odfexport.cxx
index 7d93b3b..1252fe9 100644
--- a/sw/qa/extras/odfexport/odfexport.cxx
+++ b/sw/qa/extras/odfexport/odfexport.cxx
@@ -33,6 +33,7 @@
 public:
 void testFdo38244();
 void testFirstHeaderFooter();
+void testFdo60769();
 
 CPPUNIT_TEST_SUITE(Test);
 #if !defined(MACOSX)  !defined(WNT)
@@ -49,6 +50,7 @@
 MethodEntryTest aMethods[] = {
 {fdo38244.odt, Test::testFdo38244},
 {first-header-footer.odt, Test::testFirstHeaderFooter},
+{fdo60769.odt, Test::testFdo60769},
 };
 for (unsigned int i = 0; i  SAL_N_ELEMENTS(aMethods); ++i)
 {
@@ -116,6 +118,32 @@
 CPPUNIT_ASSERT_EQUAL(OUString(Left footer2),  
parseDump(/root/page[6]/footer/txt/text()));
 }
 
+void Test::testFdo60769()
+{
+// Test multi-paragraph comment range feature.
+uno::Referencetext::XTextDocument xTextDocument(mxComponent, 
uno::UNO_QUERY);
+uno::Referencecontainer::XEnumerationAccess 
xParaEnumAccess(xTextDocument-getText(), uno::UNO_QUERY);
+uno::Referencecontainer::XEnumeration xParaEnum = 
xParaEnumAccess-createEnumeration();
+uno::Referencecontainer::XEnumerationAccess 
xRunEnumAccess(xParaEnum-nextElement(), uno::UNO_QUERY);
+uno::Referencecontainer::XEnumeration xRunEnum = 
xRunEnumAccess-createEnumeration();
+while (xRunEnum-hasMoreElements())
+{
+uno::Referencebeans::XPropertySet 
xPropertySet(xRunEnum-nextElement(), uno::UNO_QUERY);
+OUString aType =  getPropertyOUString(xPropertySet, 
TextPortionType);
+// First paragraph: no field end, no anchor
+CPPUNIT_ASSERT(aType == Text || aType == TextFieldStart);
+}
+
+xRunEnumAccess.set(xParaEnum-nextElement(), uno::UNO_QUERY);
+while (xRunEnum-hasMoreElements())
+{
+uno::Referencebeans::XPropertySet 
xPropertySet(xRunEnum-nextElement(), uno::UNO_QUERY);
+OUString aType =  getPropertyOUString(xPropertySet, 
TextPortionType);
+// Second paragraph: no field start
+CPPUNIT_ASSERT(aType == Text || aType == TextFieldEnd || aType == 
TextFieldEnd);
+}
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(Test);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/sw/source/core/unocore/unoportenum.cxx 
b/sw/source/core/unocore/unoportenum.cxx
index d05b8f5..2829d3f 100644
--- a/sw/source/core/unocore/unoportenum.cxx
+++ b/sw/source/core/unocore/unoportenum.cxx
@@ -754,6 +754,18 @@
 ReferenceXTextField xField =
 SwXTextField::CreateSwXTextField(*pDoc, 
pAttr-GetFld());
 pPortion-SetTextField(xField);
+
+// If this is a postit field and it has a fieldmark
+// associated, set the fieldmark as a bookmark.
+const SwField* pField = pAttr-GetFld().GetFld();
+if (pField-Which() == RES_POSTITFLD)
+{
+const SwPostItField* pPostItField = 
dynamic_castconst SwPostItField*(pField);
+IDocumentMarkAccess* pMarkAccess = 
pDoc-getIDocumentMarkAccess();
+IDocumentMarkAccess::const_iterator_t it = 
pMarkAccess-findMark(pPostItField-GetName());
+if (it != pMarkAccess-getMarksEnd())
+
pPortion-SetBookmark(SwXFieldmark::CreateXFieldmark(*pDoc, *it-get()));
+}
 }
 break;
 case RES_TXTATR_FLYCNT   :
diff --git a/xmloff/source/text/txtparae.cxx b/xmloff/source/text/txtparae.cxx
index 96cb842..36f7f0c 100644
--- a/xmloff/source/text/txtparae.cxx
+++ b/xmloff/source/text/txtparae.cxx
@@ -2198,7 +2198,6 @@
 static const OUString sMeta(InContentMetadata);
 static const OUString 

Re: Pivot Table data provider extension framework (removal possibility)

2013-03-22 Thread Eike Rathke
Hi Kohei,

On Thursday, 2013-03-21 12:24:01 -0400, Kohei Yoshida wrote:

 and I propose to remove the last choice from this dialog as the first step.
 
 If, by 4.1, nobody complains, then we assume it's safe to remove
 this.

Sounds good.

  Eike

-- 
LibreOffice Calc developer. Number formatter stricken i18n transpositionizer.
New GnuPG key 0x65632D3A : 2265 D7F3 A7B0 95CC 3918  630B 6A6C D5B7 6563 2D3A
Old GnuPG key 0x293C05FD : 997A 4C60 CE41 0149 0DB3  9E96 2F1A D073 293C 05FD
Support the FSFE, care about Free Software! https://fsfe.org/support/?erack


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


[Libreoffice-commits] core.git: Branch 'feature/formula-core-rework' - sc/inc sc/source

2013-03-22 Thread Kohei Yoshida
 sc/inc/cellvalue.hxx  |4 +
 sc/source/core/data/cellvalue.cxx |   18 +++
 sc/source/ui/docshell/docfunc.cxx |   89 +-
 sc/source/ui/inc/undocell.hxx |2 
 sc/source/ui/undo/undocell.cxx|   40 -
 5 files changed, 102 insertions(+), 51 deletions(-)

New commits:
commit 3e885b5972999d69c14a46bf2507471376760d09
Author: Kohei Yoshida kohei.yosh...@gmail.com
Date:   Fri Mar 22 11:23:08 2013 -0400

Get change tracking to work again with these new ScDocFunc methods.

Change-Id: Icdbf2af7bc552bc8f4914cc8bd036ed45934c461

diff --git a/sc/inc/cellvalue.hxx b/sc/inc/cellvalue.hxx
index 409e178..ac96274 100644
--- a/sc/inc/cellvalue.hxx
+++ b/sc/inc/cellvalue.hxx
@@ -51,6 +51,10 @@ struct ScCellValue
 void commit( ScDocument rDoc, const ScAddress rPos );
 };
 
+// TODO: temporary workaround.  To be removed later.
+class ScBaseCell;
+ScBaseCell* getHackedBaseCell( ScDocument* pDoc, const ScCellValue rVal );
+
 #endif
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/core/data/cellvalue.cxx 
b/sc/source/core/data/cellvalue.cxx
index fe038ce..6a51c68 100644
--- a/sc/source/core/data/cellvalue.cxx
+++ b/sc/source/core/data/cellvalue.cxx
@@ -113,4 +113,22 @@ void ScCellValue::commit( ScDocument rDoc, const 
ScAddress rPos )
 }
 }
 
+ScBaseCell* getHackedBaseCell( ScDocument* pDoc, const ScCellValue rVal )
+{
+switch (rVal.meType)
+{
+case CELLTYPE_STRING:
+return new ScStringCell(*rVal.mpString);
+case CELLTYPE_EDIT:
+return new ScEditCell(rVal.mpEditText-Clone(), pDoc);
+case CELLTYPE_VALUE:
+return new ScValueCell(rVal.mfValue);
+case CELLTYPE_FORMULA:
+return rVal.mpFormula-Clone();
+default:
+;
+}
+return NULL;
+}
+
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/ui/docshell/docfunc.cxx 
b/sc/source/ui/docshell/docfunc.cxx
index 70ca4c3..1bc8021 100644
--- a/sc/source/ui/docshell/docfunc.cxx
+++ b/sc/source/ui/docshell/docfunc.cxx
@@ -808,51 +808,6 @@ sal_Bool ScDocFunc::SetNormalString( bool o_rbNumFmtSet, 
const ScAddress rPos,
 return sal_True;
 }
 
-namespace {
-
-void pushUndoSetCell( ScDocShell rDocShell, ScDocument* pDoc, const 
ScAddress rPos, const ScCellValue rNewVal )
-{
-svl::IUndoManager* pUndoMgr = rDocShell.GetUndoManager();
-switch (pDoc-GetCellType(rPos))
-{
-case CELLTYPE_NONE:
-case CELLTYPE_NOTE:
-// Empty cell.
-pUndoMgr-AddUndoAction(new ScUndoSetCell(rDocShell, rPos, 
rNewVal));
-break;
-case CELLTYPE_VALUE:
-{
-double fOldVal = pDoc-GetValue(rPos);
-pUndoMgr-AddUndoAction(new ScUndoSetCell(rDocShell, rPos, 
fOldVal, rNewVal));
-}
-break;
-case CELLTYPE_STRING:
-{
-OUString aOldStr = pDoc-GetString(rPos);
-pUndoMgr-AddUndoAction(new ScUndoSetCell(rDocShell, rPos, 
aOldStr, rNewVal));
-}
-break;
-case CELLTYPE_EDIT:
-{
-const EditTextObject* pOldText = pDoc-GetEditText(rPos);
-if (pOldText)
-pUndoMgr-AddUndoAction(new ScUndoSetCell(rDocShell, rPos, 
*pOldText, rNewVal));
-}
-break;
-case CELLTYPE_FORMULA:
-{
-const ScFormulaCell* pCell = pDoc-GetFormulaCell(rPos);
-if (pCell)
-pUndoMgr-AddUndoAction(new ScUndoSetCell(rDocShell, rPos, 
*pCell, rNewVal));
-}
-break;
-default:
-;
-}
-}
-
-}
-
 bool ScDocFunc::SetValueCell( const ScAddress rPos, double fVal, bool 
bInteraction )
 {
 ScDocShellModificator aModificator( rDocShell );
@@ -861,11 +816,20 @@ bool ScDocFunc::SetValueCell( const ScAddress rPos, 
double fVal, bool bInteract
 
 bool bHeight = pDoc-HasAttrib(rPos, HASATTR_NEEDHEIGHT);
 
+ScCellValue aOldVal;
 if (bUndo)
-pushUndoSetCell(rDocShell, pDoc, rPos, fVal);
+aOldVal.assign(*pDoc, rPos);
 
 pDoc-SetValue(rPos, fVal);
 
+if (bUndo)
+{
+svl::IUndoManager* pUndoMgr = rDocShell.GetUndoManager();
+ScCellValue aNewVal;
+aNewVal.assign(*pDoc, rPos);
+pUndoMgr-AddUndoAction(new ScUndoSetCell(rDocShell, rPos, aOldVal, 
aNewVal));
+}
+
 if (bHeight)
 AdjustRowHeight(rPos);
 
@@ -886,13 +850,22 @@ bool ScDocFunc::SetStringCell( const ScAddress rPos, 
const OUString rStr, bool
 
 bool bHeight = pDoc-HasAttrib(rPos, HASATTR_NEEDHEIGHT);
 
+ScCellValue aOldVal;
 if (bUndo)
-pushUndoSetCell(rDocShell, pDoc, rPos, rStr);
+aOldVal.assign(*pDoc, rPos);
 
 ScSetStringParam aParam;
 aParam.setTextInput();
 pDoc-SetString(rPos, rStr, aParam);
 
+if (bUndo)
+{
+svl::IUndoManager* pUndoMgr = rDocShell.GetUndoManager();
+ScCellValue aNewVal;
+

[Libreoffice-commits] core.git: Branch 'libreoffice-4-0' - sw/qa writerfilter/source

2013-03-22 Thread Miklos Vajna
 sw/qa/extras/rtfimport/data/fdo62288.rtf   |   23 +++
 sw/qa/extras/rtfimport/rtfimport.cxx   |   15 +++
 writerfilter/source/rtftok/rtfdocumentimpl.cxx |9 +
 3 files changed, 47 insertions(+)

New commits:
commit cd8de6c4138d227a48d01b05212f5aaf53b67aab
Author: Miklos Vajna vmik...@suse.cz
Date:   Fri Mar 22 11:08:12 2013 +0100

fdo#62288 fix RTF import of table paragraph margins

Regression from 4a507f732d82c188ad81b022cbe3037951e58ac3. The problem
was that in some cases \pard can't reset all paragraph properties. The
original commit just made this keyword a noop when it occurred between
\cell and \row, but this is too much. At least margins do need
resetting.

Change-Id: I5cbb1df72bf1211f85ef69ab64d5b46cbce5c742
(cherry picked from commit 24d5261f5a122e22675210445056cdf67663237b)
Reviewed-on: https://gerrit.libreoffice.org/2906
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/sw/qa/extras/rtfimport/data/fdo62288.rtf 
b/sw/qa/extras/rtfimport/data/fdo62288.rtf
new file mode 100644
index 000..f5ec592
--- /dev/null
+++ b/sw/qa/extras/rtfimport/data/fdo62288.rtf
@@ -0,0 +1,23 @@
+{\rtf1
+\paperw11907\paperh16840\margl567\margr567\margt567\margb567 
+\sb113\sa113
+{\b\fs22\cf1\kerning1\cgrid0 Objectives}
+{\fs24\kerning1\cgrid0 
+\par }
+\trowd \trgaph10\trleft-10 \clvertalt\cltxlrtb \cellx4808\clvertalt\cltxlrtb 
\cellx5375\clvertalt\cltxlrtb \cellx10194\clvertalt\cltxlrtb \cellx10762\pard 
\li567\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 One}
+{\fs24\kerning1\cgrid0 \cell }
+\pard \qc\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 [ ]}
+{\fs24\kerning1\cgrid0 \cell }
+\pard \li567\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 Two}
+{
+\fs24\kerning1\cgrid0 \cell }
+\pard \qc\nowidctlpar\intbl\adjustright 
+{\cf1\kerning1\cgrid0 [ ]}
+{\fs24\kerning1\cgrid0 \cell }
+\pard \widctlpar\intbl\adjustright 
+{\fs24\kerning1\cgrid0 \row }
+\pard\par
+}
diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx 
b/sw/qa/extras/rtfimport/rtfimport.cxx
index 07583fc..e54812f 100644
--- a/sw/qa/extras/rtfimport/rtfimport.cxx
+++ b/sw/qa/extras/rtfimport/rtfimport.cxx
@@ -142,6 +142,7 @@ public:
 void testFdo59638();
 void testFdo60722();
 void testFdo61909();
+void testFdo62288();
 
 CPPUNIT_TEST_SUITE(Test);
 #if !defined(MACOSX)  !defined(WNT)
@@ -234,6 +235,7 @@ void Test::run()
 {fdo59638.rtf, Test::testFdo59638},
 {fdo60722.rtf, Test::testFdo60722},
 {fdo61909.rtf, Test::testFdo61909},
+{fdo62288.rtf, Test::testFdo62288},
 };
 for (unsigned int i = 0; i  SAL_N_ELEMENTS(aMethods); ++i)
 {
@@ -1142,6 +1144,19 @@ void Test::testFdo61909()
 CPPUNIT_ASSERT_EQUAL(COL_AUTO, getPropertysal_uInt32(xTextRange, 
CharBackColor));
 }
 
+void Test::testFdo62288()
+{
+uno::Referencetext::XTextTablesSupplier xTextTablesSupplier(mxComponent, 
uno::UNO_QUERY);
+uno::Referencecontainer::XIndexAccess 
xTables(xTextTablesSupplier-getTextTables(), uno::UNO_QUERY);
+uno::Referencetext::XTextTable xTable(xTables-getByIndex(0), 
uno::UNO_QUERY);
+uno::Referencetext::XTextRange xCell(xTable-getCellByName(B1), 
uno::UNO_QUERY);
+uno::Referencecontainer::XEnumerationAccess 
xParaEnumAccess(xCell-getText(), uno::UNO_QUERY);
+uno::Referencecontainer::XEnumeration xParaEnum = 
xParaEnumAccess-createEnumeration();
+uno::Referencetext::XTextRange xPara(xParaEnum-nextElement(), 
uno::UNO_QUERY);
+// Margins were inherited from the previous cell, even there was a \pard 
there.
+CPPUNIT_ASSERT_EQUAL(sal_Int32(0), getPropertysal_Int32(xPara, 
ParaLeftMargin));
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(Test);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx 
b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 34b779d..3f18695 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -2172,11 +2172,20 @@ int RTFDocumentImpl::dispatchFlag(RTFKeyword nKeyword)
 // \pard is allowed between \cell and \row, but in that case it 
should not reset the fact that we're inside a table.
 if (m_aStates.top().nCells == 0)
 {
+// Reset everything.
 m_aStates.top().aParagraphSprms = 
m_aDefaultState.aParagraphSprms;
 m_aStates.top().aParagraphAttributes = 
m_aDefaultState.aParagraphAttributes;
 if (m_aStates.top().nDestinationState != DESTINATION_SHAPETEXT)
 m_pCurrentBuffer = 0;
 }
+else
+{
+// Reset only margins.
+lcl_eraseNestedAttribute(m_aStates.top().aParagraphSprms, 
NS_ooxml::LN_CT_PPrBase_spacing, NS_ooxml::LN_CT_Spacing_before);
+

[PUSHED libreoffice-4-0] fdo#62288 fix RTF import of table paragraph margins

2013-03-22 Thread Fridrich Strba (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2906

Approvals:
  Fridrich Strba: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2906
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I5cbb1df72bf1211f85ef69ab64d5b46cbce5c742
Gerrit-PatchSet: 2
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0
Gerrit-Owner: Miklos Vajna vmik...@suse.cz
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org

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


[Libreoffice-commits] core.git: vcl/source

2013-03-22 Thread Tor Lillqvist
 vcl/source/window/syschild.cxx |3 +++
 1 file changed, 3 insertions(+)

New commits:
commit a4b4942ff6d79394a3120cd1c55eb21a10769a30
Author: Tor Lillqvist t...@iki.fi
Date:   Fri Mar 22 17:53:09 2013 +0200

Don't include Java-related headers when they aren't needed

Change-Id: Ia971f98c904b69ce126a03d4737833b8e9e57369

diff --git a/vcl/source/window/syschild.cxx b/vcl/source/window/syschild.cxx
index fee36d4..93086e9 100644
--- a/vcl/source/window/syschild.cxx
+++ b/vcl/source/window/syschild.cxx
@@ -42,9 +42,12 @@
 #endif
 
 #include comphelper/processfactory.hxx
+
+#ifdef SOLAR_JAVA
 #include jvmaccess/virtualmachine.hxx
 #include com/sun/star/java/JavaVirtualMachine.hpp
 #include com/sun/star/lang/XMultiServiceFactory.hpp
+#endif
 
 using namespace ::com::sun::star;
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: sfx2/inc sfx2/source

2013-03-22 Thread Cédric Bosdonnat
 sfx2/inc/sfx2/templateview.hxx   |1 -
 sfx2/source/control/templateabstractview.cxx |   10 --
 sfx2/source/control/templateview.cxx |   16 +---
 sfx2/source/control/templateview.src |6 --
 4 files changed, 13 insertions(+), 20 deletions(-)

New commits:
commit 7a25aa2821ccf7318ce4a13efe171763989009d5
Author: Cédric Bosdonnat cedric.bosdon...@free.fr
Date:   Fri Mar 22 16:33:20 2013 +0100

fdo#61390: Fixed the tabstop in the TemplateView.

Change-Id: I887b11646efb9a839da11cd3e20cdf7e532caf3e

diff --git a/sfx2/inc/sfx2/templateview.hxx b/sfx2/inc/sfx2/templateview.hxx
index b7ff215..104cb11 100644
--- a/sfx2/inc/sfx2/templateview.hxx
+++ b/sfx2/inc/sfx2/templateview.hxx
@@ -54,7 +54,6 @@ private:
 Link maOpenHdl;
 TemplateAbstractView* mpMasterView;
 
-ControlmaButtons;
 PushButton maAllButton;
 FixedText  maFTName;
 sal_uInt16 mnId;
diff --git a/sfx2/source/control/templateabstractview.cxx 
b/sfx2/source/control/templateabstractview.cxx
index 737f087..b6cd646 100644
--- a/sfx2/source/control/templateabstractview.cxx
+++ b/sfx2/source/control/templateabstractview.cxx
@@ -115,7 +115,7 @@ bool ViewFilter_Keyword::operator ()(const 
ThumbnailViewItem *pItem)
 
 TemplateAbstractView::TemplateAbstractView (Window *pParent, WinBits 
nWinStyle, bool bDisableTransientChildren)
 : ThumbnailView(pParent,nWinStyle,bDisableTransientChildren),
-  mpItemView(new TemplateView(this)),
+  mpItemView(new TemplateView(pParent)),
   mbFilteredResults(false),
   meFilterOption(FILTER_APP_WRITER)
 {
@@ -124,7 +124,7 @@ TemplateAbstractView::TemplateAbstractView (Window 
*pParent, WinBits nWinStyle,
 
 TemplateAbstractView::TemplateAbstractView(Window *pParent, const ResId 
rResId, bool bDisableTransientChildren)
 : ThumbnailView(pParent,rResId,bDisableTransientChildren),
-  mpItemView(new TemplateView(this)),
+  mpItemView(new TemplateView(pParent)),
   mbFilteredResults(false),
   meFilterOption(FILTER_APP_WRITER)
 {
@@ -186,8 +186,14 @@ void TemplateAbstractView::filterTemplatesByApp (const 
FILTER_APPLICATION eApp)
 
 void TemplateAbstractView::showOverlay (bool bVisible)
 {
+Show(!bVisible);
 mpItemView-Show(bVisible);
 
+mpItemView-SetPosSizePixel(GetPosPixel(), GetSizePixel());
+mpItemView-SetStyle(GetStyle());
+
+mpItemView-GrabFocus();
+
 // Clear items is the overlay is closed.
 if (!bVisible)
 {
diff --git a/sfx2/source/control/templateview.cxx 
b/sfx2/source/control/templateview.cxx
index 21b2603..a19c8c5 100644
--- a/sfx2/source/control/templateview.cxx
+++ b/sfx2/source/control/templateview.cxx
@@ -34,14 +34,13 @@ using namespace drawinglayer::attribute;
 using namespace drawinglayer::primitive2d;
 
 TemplateView::TemplateView (Window *pParent)
-: ThumbnailView(pParent,WB_VSCROLL),
+: ThumbnailView(pParent,WB_VSCROLL | WB_TABSTOP),
   mpMasterView(NULL),
-  maButtons(this, SfxResId(CONTROL_BUTTONS)),
-  maAllButton(maButtons, SfxResId(BTN_ALL_TEMPLATES)),
-  maFTName(maButtons, SfxResId(FT_NAME)),
+  maAllButton(this, SfxResId(BTN_ALL_TEMPLATES)),
+  maFTName(this, SfxResId(FT_NAME)),
   mnId(0)
 {
-mnHeaderHeight = maButtons.GetSizePixel().getHeight();
+mnHeaderHeight = maAllButton.GetSizePixel().getHeight() + 
maAllButton.GetPosPixel().Y() * 2;
 maAllButton.SetStyle(maAllButton.GetStyle() | WB_FLATBUTTON);
 }
 
@@ -88,13 +87,8 @@ void TemplateView::Resize()
 Size aWinSize = GetOutputSize();
 
 // Set the buttons panel and buttons size
-Size aPanelSize = maButtons.GetSizePixel();
-int nDeltaW = aWinSize.getWidth() - aPanelSize.getWidth();
-aPanelSize.setWidth(aWinSize.getWidth());
-maButtons.SetSizePixel(aPanelSize);
-
 Size aNameSize = maFTName.GetSizePixel();
-aNameSize.setWidth(aNameSize.getWidth() + nDeltaW);
+aNameSize.setWidth( aWinSize.getWidth() - maFTName.GetPosPixel().X());
 maFTName.SetSizePixel(aNameSize);
 
 ThumbnailView::Resize();
diff --git a/sfx2/source/control/templateview.src 
b/sfx2/source/control/templateview.src
index 1f78a88..5836a95 100644
--- a/sfx2/source/control/templateview.src
+++ b/sfx2/source/control/templateview.src
@@ -9,12 +9,6 @@
 
 #include templateview.hrc
 
-Control CONTROL_BUTTONS
-{
-Size = MAP_APPFONT( 290, 17 );
-TabStop = False;
-};
-
 PushButton BTN_ALL_TEMPLATES
 {
 Pos = MAP_APPFONT( 1, 1 );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[PATCH libreoffice-4-0] Template Manager: fixed control WinBits reset... was breakin...

2013-03-22 Thread Bosdonnat Cedric (via Code Review)
Hi,

I have submitted a patch for review:

https://gerrit.libreoffice.org/2909

To pull it, you can do:

git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/09/2909/1

Template Manager: fixed control WinBits reset... was breaking tabstop

Change-Id: I6e542ecc0e0f5a2b3e0ca59a52bb809b1a23284f
(cherry picked from commit 5fa5f95612c53511fb951660b4ad397321e8)
---
M sfx2/source/doc/templatedlg.cxx
1 file changed, 1 insertion(+), 1 deletion(-)



diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index e9f85eb..b9d3945 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -163,7 +163,7 @@
 
mpSearchEdit-SetUpdateDataHdl(LINK(this,SfxTemplateManagerDlg,SearchUpdateHdl));
 mpSearchEdit-EnableUpdateData();
 
-maView-SetStyle(WB_VSCROLL);
+maView-SetStyle(maView-GetStyle() | WB_VSCROLL);
 maView-setItemMaxTextLength(TEMPLATE_ITEM_MAX_TEXT_LENGTH);
 
 
maView-setItemDimensions(TEMPLATE_ITEM_MAX_WIDTH,TEMPLATE_ITEM_THUMBNAIL_MAX_HEIGHT,

-- 
To view, visit https://gerrit.libreoffice.org/2909
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6e542ecc0e0f5a2b3e0ca59a52bb809b1a23284f
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0
Gerrit-Owner: Bosdonnat Cedric cedric.bosdon...@free.fr

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


[PATCH libreoffice-4-0] Template Manager: select first item when getting focus if no...

2013-03-22 Thread Bosdonnat Cedric (via Code Review)
Hi,

I have submitted a patch for review:

https://gerrit.libreoffice.org/2910

To pull it, you can do:

git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/10/2910/1

Template Manager: select first item when getting focus if no selection

Change-Id: Ie012e010ca92728725535345c76fc9f5eb31a254
(cherry picked from commit ec2f84b376f595b0553297d25b7716f6b97e1b87)
---
M sfx2/source/control/thumbnailview.cxx
1 file changed, 18 insertions(+), 1 deletion(-)



diff --git a/sfx2/source/control/thumbnailview.cxx 
b/sfx2/source/control/thumbnailview.cxx
index c996f0f..57dba07 100644
--- a/sfx2/source/control/thumbnailview.cxx
+++ b/sfx2/source/control/thumbnailview.cxx
@@ -579,12 +579,29 @@
 
 void ThumbnailView::GetFocus()
 {
-Control::GetFocus();
+// Select the first item if nothing selected
+int nSelected = -1;
+for (size_t i = 0, n = mItemList.size(); i  n  nSelected == -1; ++i)
+{
+if (mItemList[i]-isSelected())
+nSelected = i;
+}
+
+if ( nSelected == -1  mItemList.size( )  0 )
+{
+mItemList[0]-setSelection(true);
+maItemStateHdl.Call(mItemList[0]);
+
+if (IsReallyVisible()  IsUpdateMode())
+Invalidate();
+}
 
 // Tell the accessible object that we got the focus.
 ThumbnailViewAcc* pAcc = ThumbnailViewAcc::getImplementation( 
GetAccessible( sal_False ) );
 if( pAcc )
 pAcc-GetFocus();
+
+Control::GetFocus();
 }
 
 void ThumbnailView::LoseFocus()

-- 
To view, visit https://gerrit.libreoffice.org/2910
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie012e010ca92728725535345c76fc9f5eb31a254
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0
Gerrit-Owner: Bosdonnat Cedric cedric.bosdon...@free.fr

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


[PATCH libreoffice-4-0] Template Manager: removed some dead selection code

2013-03-22 Thread Bosdonnat Cedric (via Code Review)
Hi,

I have submitted a patch for review:

https://gerrit.libreoffice.org/2911

To pull it, you can do:

git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/11/2911/1

Template Manager: removed some dead selection code

(cherry picked from commit bfd1bcb204ed3ca35df1455a346a0ee7254a1191)

Conflicts:
sfx2/source/control/thumbnailview.cxx

Change-Id: Ib5ebcd928e77a115f4f62a50724656c33ae13c61
---
M sfx2/inc/sfx2/thumbnailview.hxx
M sfx2/source/control/thumbnailview.cxx
M sfx2/source/control/thumbnailviewacc.cxx
3 files changed, 24 insertions(+), 111 deletions(-)



diff --git a/sfx2/inc/sfx2/thumbnailview.hxx b/sfx2/inc/sfx2/thumbnailview.hxx
index 8eb9426..efc5e78 100644
--- a/sfx2/inc/sfx2/thumbnailview.hxx
+++ b/sfx2/inc/sfx2/thumbnailview.hxx
@@ -202,10 +202,7 @@
 
 void SelectItem( sal_uInt16 nItemId );
 
-sal_uInt16 GetSelectItemId() const { return mnSelItemId; }
-
-bool IsItemSelected( sal_uInt16 nItemId ) const
-{ return nItemId == mnSelItemId; }
+bool IsItemSelected( sal_uInt16 nItemId ) const;
 
 void deselectItem (const sal_uInt16 nItemId);
 
@@ -258,8 +255,6 @@
 
 virtual void DataChanged( const DataChangedEvent rDCEvt );
 
-virtual bool StartDrag( const CommandEvent rCEvt, Region rRegion );
-
 virtual ::com::sun::star::uno::Reference 
::com::sun::star::accessibility::XAccessible  CreateAccessible();
 
 protected:
@@ -310,7 +305,6 @@
 long mnVisLines;
 long mnLines;
 sal_uInt16 mnScrBarOffset;
-sal_uInt16 mnSelItemId;
 sal_uInt16 mnHighItemId;
 sal_uInt16 mnCols;
 sal_uInt16 mnFirstLine;
diff --git a/sfx2/source/control/thumbnailview.cxx 
b/sfx2/source/control/thumbnailview.cxx
index 57dba07..63ba189 100644
--- a/sfx2/source/control/thumbnailview.cxx
+++ b/sfx2/source/control/thumbnailview.cxx
@@ -92,7 +92,6 @@
 mnLines = 0;
 mnFirstLine = 0;
 mnScrBarOffset = 1;
-mnSelItemId = 0;
 mnHighItemId= 0;
 mnCols  = 0;
 mnSpacing   = 0;
@@ -589,11 +588,7 @@
 
 if ( nSelected == -1  mItemList.size( )  0 )
 {
-mItemList[0]-setSelection(true);
-maItemStateHdl.Call(mItemList[0]);
-
-if (IsReallyVisible()  IsUpdateMode())
-Invalidate();
+SelectItem( 1 );
 }
 
 // Tell the accessible object that we got the focus.
@@ -710,10 +705,9 @@
 }
 
 // reset variables
-if ( (mnHighItemId == nItemId) || (mnSelItemId == nItemId) )
+if ( (mnHighItemId == nItemId) )
 {
 mnHighItemId= 0;
-mnSelItemId = 0;
 }
 
 CalculateItemPositions();
@@ -729,7 +723,6 @@
 // reset variables
 mnFirstLine = 0;
 mnHighItemId= 0;
-mnSelItemId = 0;
 
 CalculateItemPositions();
 
@@ -777,19 +770,18 @@
 
 void ThumbnailView::SelectItem( sal_uInt16 nItemId )
 {
-size_t nItemPos = 0;
+size_t nItemPos = GetItemPos( nItemId );
+if ( nItemPos == THUMBNAILVIEW_ITEM_NOTFOUND )
+return;
 
-if ( nItemId )
+ThumbnailViewItem* pItem = mItemList[nItemPos];
+if (!pItem-isSelected())
 {
-nItemPos = GetItemPos( nItemId );
-if ( nItemPos == THUMBNAILVIEW_ITEM_NOTFOUND )
-return;
-}
+mItemList[nItemPos]-setSelection(true);
+maItemStateHdl.Call(mItemList[nItemPos]);
 
-if ( mnSelItemId != nItemId)
-{
-sal_uInt16 nOldItem = mnSelItemId ? mnSelItemId : 1;
-mnSelItemId = nItemId;
+if (IsReallyVisible()  IsUpdateMode())
+Invalidate();
 
 bool bNewOut = IsReallyVisible()  IsUpdateMode();
 
@@ -815,44 +807,8 @@
 
 if( ImplHasAccessibleListeners() )
 {
-// focus event (deselect)
-if( nOldItem )
-{
-const size_t nPos = GetItemPos( nItemId );
-
-if( nPos != THUMBNAILVIEW_ITEM_NOTFOUND )
-{
-ThumbnailViewAcc* pItemAcc = 
ThumbnailViewAcc::getImplementation(
-mItemList[nPos]-GetAccessible( 
mbIsTransientChildrenDisabled ) );
-
-if( pItemAcc )
-{
-::com::sun::star::uno::Any aOldAny, aNewAny;
-if( !mbIsTransientChildrenDisabled )
-{
-aOldAny = ::com::sun::star::uno::Reference 
::com::sun::star::uno::XInterface (
-static_cast ::cppu::OWeakObject* ( pItemAcc 
));
-ImplFireAccessibleEvent 
(::com::sun::star::accessibility::AccessibleEventId::ACTIVE_DESCENDANT_CHANGED, 
aOldAny, aNewAny );
-}
-else
-{
-aOldAny = 
::com::sun::star::accessibility::AccessibleStateType::FOCUSED;
-pItemAcc-FireAccessibleEvent( 

[PATCH libreoffice-4-0] fdo#61390: simple keybard support in TemplateManager

2013-03-22 Thread Bosdonnat Cedric (via Code Review)
Hi,

I have submitted a patch for review:

https://gerrit.libreoffice.org/2912

To pull it, you can do:

git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/12/2912/1

fdo#61390: simple keybard support in TemplateManager

Adds support for the UP, DOWN, LEFT, RIGHT and RETURN keys in the
thumbnails view but doesn't handle the modifiers yet. There are still
some problems with the focus and key input outside the top level

(cherry picked from commit ee819bdd2dab5756cc3bad74f24e50bd7409f308)

Conflicts:
sfx2/source/control/thumbnailview.cxx

Change-Id: I5ba67583c835bcc00b075071411c0d6590a07f9a
---
M sfx2/inc/sfx2/thumbnailview.hxx
M sfx2/source/control/thumbnailview.cxx
2 files changed, 104 insertions(+), 7 deletions(-)



diff --git a/sfx2/inc/sfx2/thumbnailview.hxx b/sfx2/inc/sfx2/thumbnailview.hxx
index efc5e78..95e6b53 100644
--- a/sfx2/inc/sfx2/thumbnailview.hxx
+++ b/sfx2/inc/sfx2/thumbnailview.hxx
@@ -202,6 +202,8 @@
 
 void SelectItem( sal_uInt16 nItemId );
 
+void DeselectItem( sal_uInt16 nItemId );
+
 bool IsItemSelected( sal_uInt16 nItemId ) const;
 
 void deselectItem (const sal_uInt16 nItemId);
@@ -239,6 +241,8 @@
 
 protected:
 
+virtual void KeyInput( const KeyEvent rKEvt );
+
 virtual void MouseButtonDown( const MouseEvent rMEvt );
 
 virtual void MouseButtonUp( const MouseEvent rMEvt );
@@ -272,8 +276,6 @@
 using Control::ImplInitSettings;
 using Window::ImplInit;
 
-void calculateColumnsRows ();
-
 void CalculateItemPositions ();
 
 SFX2_DLLPRIVATE void ImplInit();
@@ -294,6 +296,7 @@
 protected:
 
 ValueItemList mItemList;
+ValueItemList mFilteredItemList; /// Cache to store the filtered items
 ScrollBar* mpScrBar;
 Rectangle maItemListRect;
 long mnHeaderHeight;
diff --git a/sfx2/source/control/thumbnailview.cxx 
b/sfx2/source/control/thumbnailview.cxx
index 63ba189..f78a308 100644
--- a/sfx2/source/control/thumbnailview.cxx
+++ b/sfx2/source/control/thumbnailview.cxx
@@ -214,6 +214,8 @@
 WinBits nStyle = GetStyle();
 ScrollBar*  pDelScrBar = NULL;
 
+mFilteredItemList.clear();
+
 // consider the scrolling
 if ( nStyle  WB_VSCROLL )
 ImplInitScrollBar();
@@ -298,6 +300,7 @@
 
 if (maFilterFunc(pItem))
 {
+mFilteredItemList.push_back(pItem);
 if ((nCurCount = nFirstItem)  (nCurCount  nLastItem))
 {
 if( !pItem-isVisible())
@@ -490,6 +493,73 @@
 return 0;
 }
 
+void ThumbnailView::KeyInput( const KeyEvent rKEvt )
+{
+// Get the last selected item in the list
+size_t nLastPos = 0;
+bool bFoundLast = false;
+for ( long i = mFilteredItemList.size() - 1; !bFoundLast  i = 0; --i )
+{
+ThumbnailViewItem* pItem = mFilteredItemList[i];
+if ( pItem-isSelected() )
+{
+nLastPos = i;
+bFoundLast = true;
+}
+}
+
+KeyCode aKeyCode = rKEvt.GetKeyCode();
+ThumbnailViewItem* pNext = NULL;
+switch ( aKeyCode.GetCode() )
+{
+case KEY_RIGHT:
+{
+size_t nNextPos = nLastPos;
+if ( bFoundLast  nLastPos  mFilteredItemList.size( ) - 1 )
+nNextPos = nLastPos + 1;
+pNext = mFilteredItemList[nNextPos];
+}
+break;
+case KEY_LEFT:
+{
+size_t nNextPos = nLastPos;
+if ( nLastPos  0 )
+nNextPos = nLastPos - 1;
+pNext = mFilteredItemList[nNextPos];
+}
+break;
+case KEY_DOWN:
+{
+size_t nNextPos = nLastPos;
+if ( bFoundLast  nLastPos  mFilteredItemList.size( ) - 
mnCols )
+nNextPos = nLastPos + mnCols;
+pNext = mFilteredItemList[nNextPos];
+}
+break;
+case KEY_UP:
+{
+size_t nNextPos = nLastPos;
+if ( nLastPos = mnCols )
+nNextPos = nLastPos - mnCols;
+pNext = mFilteredItemList[nNextPos];
+}
+break;
+case KEY_RETURN:
+{
+if ( bFoundLast )
+OnItemDblClicked( mFilteredItemList[nLastPos] );
+}
+default:
+Control::KeyInput( rKEvt );
+}
+
+if ( pNext  pNext-isVisible() )
+{
+deselectItems();
+SelectItem(pNext-mnId);
+}
+}
+
 void ThumbnailView::MouseButtonDown( const MouseEvent rMEvt )
 {
 if ( rMEvt.IsLeft() )
@@ -500,12 +570,17 @@
 {
 if ( rMEvt.GetClicks() == 1 )
 {
-if (!pItem-isSelected()  !rMEvt.IsMod1())
-deselectItems( );
-pItem-setSelection(true);
+if (pItem-isSelected()  rMEvt.IsMod1())
+DeselectItem( pItem-mnId );
+else
+ 

[PATCH libreoffice-4-0] fdo#61390: Fixed the tabstop in the TemplateView.

2013-03-22 Thread Bosdonnat Cedric (via Code Review)
Hi,

I have submitted a patch for review:

https://gerrit.libreoffice.org/2913

To pull it, you can do:

git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/13/2913/1

fdo#61390: Fixed the tabstop in the TemplateView.

Change-Id: I887b11646efb9a839da11cd3e20cdf7e532caf3e
(cherry picked from commit 7a25aa2821ccf7318ce4a13efe171763989009d5)
---
M sfx2/inc/sfx2/templateview.hxx
M sfx2/source/control/templateabstractview.cxx
M sfx2/source/control/templateview.cxx
M sfx2/source/control/templateview.src
4 files changed, 13 insertions(+), 20 deletions(-)



diff --git a/sfx2/inc/sfx2/templateview.hxx b/sfx2/inc/sfx2/templateview.hxx
index 3e2a7c8..e219905 100644
--- a/sfx2/inc/sfx2/templateview.hxx
+++ b/sfx2/inc/sfx2/templateview.hxx
@@ -51,7 +51,6 @@
 private:
 TemplateAbstractView* mpMasterView;
 
-ControlmaButtons;
 PushButton maAllButton;
 FixedText  maFTName;
 sal_uInt16 mnId;
diff --git a/sfx2/source/control/templateabstractview.cxx 
b/sfx2/source/control/templateabstractview.cxx
index de2091f..14ab811 100644
--- a/sfx2/source/control/templateabstractview.cxx
+++ b/sfx2/source/control/templateabstractview.cxx
@@ -114,7 +114,7 @@
 
 TemplateAbstractView::TemplateAbstractView (Window *pParent, WinBits 
nWinStyle, bool bDisableTransientChildren)
 : ThumbnailView(pParent,nWinStyle,bDisableTransientChildren),
-  mpItemView(new TemplateView(this)),
+  mpItemView(new TemplateView(pParent)),
   mbFilteredResults(false),
   meFilterOption(FILTER_APP_WRITER)
 {
@@ -123,7 +123,7 @@
 
 TemplateAbstractView::TemplateAbstractView(Window *pParent, const ResId 
rResId, bool bDisableTransientChildren)
 : ThumbnailView(pParent,rResId,bDisableTransientChildren),
-  mpItemView(new TemplateView(this)),
+  mpItemView(new TemplateView(pParent)),
   mbFilteredResults(false),
   meFilterOption(FILTER_APP_WRITER)
 {
@@ -190,8 +190,14 @@
 
 void TemplateAbstractView::showOverlay (bool bVisible)
 {
+Show(!bVisible);
 mpItemView-Show(bVisible);
 
+mpItemView-SetPosSizePixel(GetPosPixel(), GetSizePixel());
+mpItemView-SetStyle(GetStyle());
+
+mpItemView-GrabFocus();
+
 // Clear items is the overlay is closed.
 if (!bVisible)
 {
diff --git a/sfx2/source/control/templateview.cxx 
b/sfx2/source/control/templateview.cxx
index 615465d..46ebeaa 100644
--- a/sfx2/source/control/templateview.cxx
+++ b/sfx2/source/control/templateview.cxx
@@ -34,14 +34,13 @@
 using namespace drawinglayer::primitive2d;
 
 TemplateView::TemplateView (Window *pParent)
-: ThumbnailView(pParent,WB_VSCROLL),
+: ThumbnailView(pParent,WB_VSCROLL | WB_TABSTOP),
   mpMasterView(NULL),
-  maButtons(this, SfxResId(CONTROL_BUTTONS)),
-  maAllButton(maButtons, SfxResId(BTN_ALL_TEMPLATES)),
-  maFTName(maButtons, SfxResId(FT_NAME)),
+  maAllButton(this, SfxResId(BTN_ALL_TEMPLATES)),
+  maFTName(this, SfxResId(FT_NAME)),
   mnId(0)
 {
-mnHeaderHeight = maButtons.GetSizePixel().getHeight();
+mnHeaderHeight = maAllButton.GetSizePixel().getHeight() + 
maAllButton.GetPosPixel().Y() * 2;
 maAllButton.SetStyle(maAllButton.GetStyle() | WB_FLATBUTTON);
 }
 
@@ -88,13 +87,8 @@
 Size aWinSize = GetOutputSize();
 
 // Set the buttons panel and buttons size
-Size aPanelSize = maButtons.GetSizePixel();
-int nDeltaW = aWinSize.getWidth() - aPanelSize.getWidth();
-aPanelSize.setWidth(aWinSize.getWidth());
-maButtons.SetSizePixel(aPanelSize);
-
 Size aNameSize = maFTName.GetSizePixel();
-aNameSize.setWidth(aNameSize.getWidth() + nDeltaW);
+aNameSize.setWidth( aWinSize.getWidth() - maFTName.GetPosPixel().X());
 maFTName.SetSizePixel(aNameSize);
 
 ThumbnailView::Resize();
diff --git a/sfx2/source/control/templateview.src 
b/sfx2/source/control/templateview.src
index db4d575..8549c96 100644
--- a/sfx2/source/control/templateview.src
+++ b/sfx2/source/control/templateview.src
@@ -8,12 +8,6 @@
 
 #include templateview.hrc
 
-Control CONTROL_BUTTONS
-{
-Size = MAP_APPFONT( 290, 17 );
-TabStop = False;
-};
-
 PushButton BTN_ALL_TEMPLATES
 {
 Pos = MAP_APPFONT( 1, 1 );

-- 
To view, visit https://gerrit.libreoffice.org/2913
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I887b11646efb9a839da11cd3e20cdf7e532caf3e
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0
Gerrit-Owner: Bosdonnat Cedric cedric.bosdon...@free.fr

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


[Libreoffice-commits] core.git: Branch 'libreoffice-4-0-2' - sw/qa sw/source xmloff/source

2013-03-22 Thread Miklos Vajna
 sw/qa/extras/odfexport/data/fdo60769.odt |binary
 sw/qa/extras/odfexport/odfexport.cxx |   28 
 sw/source/core/unocore/unoportenum.cxx   |   12 
 xmloff/source/text/txtparae.cxx  |   20 
 4 files changed, 52 insertions(+), 8 deletions(-)

New commits:
commit 7aa93e2c7c17e11f612bd4313e7c819aa49a9f26
Author: Miklos Vajna vmik...@suse.cz
Date:   Wed Mar 20 10:39:08 2013 +0100

fdo#60769 implement odf export of multi-paragraph comment ranges

(cherry picked from commits 287c254d5ebf9b58ca63a8c271e523adf0d34b82 and
1fba17854b2be4fdbe436f44da3ae57a1f75a27c)

Conflicts:
sw/qa/extras/odfexport/odfexport.cxx

Reviewed-on: https://gerrit.libreoffice.org/2873
Reviewed-by: Noel Power noel.po...@suse.com
Tested-by: Noel Power noel.po...@suse.com

(cherry picked from commit 473cd59a71706ada01f8be68c7dfd008ca9bb716)

Change-Id: Ic4a5a1bc685917f2b26be4ab645203f706719c80
Reviewed-on: https://gerrit.libreoffice.org/2908
Reviewed-by: Michael Meeks michael.me...@suse.com
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Reviewed-by: Petr Mladek pmla...@suse.cz
Tested-by: Petr Mladek pmla...@suse.cz

diff --git a/sw/qa/extras/odfexport/data/fdo60769.odt 
b/sw/qa/extras/odfexport/data/fdo60769.odt
new file mode 100644
index 000..b3c3937
Binary files /dev/null and b/sw/qa/extras/odfexport/data/fdo60769.odt differ
diff --git a/sw/qa/extras/odfexport/odfexport.cxx 
b/sw/qa/extras/odfexport/odfexport.cxx
index 7d93b3b..1252fe9 100644
--- a/sw/qa/extras/odfexport/odfexport.cxx
+++ b/sw/qa/extras/odfexport/odfexport.cxx
@@ -33,6 +33,7 @@ class Test : public SwModelTestBase
 public:
 void testFdo38244();
 void testFirstHeaderFooter();
+void testFdo60769();
 
 CPPUNIT_TEST_SUITE(Test);
 #if !defined(MACOSX)  !defined(WNT)
@@ -49,6 +50,7 @@ void Test::run()
 MethodEntryTest aMethods[] = {
 {fdo38244.odt, Test::testFdo38244},
 {first-header-footer.odt, Test::testFirstHeaderFooter},
+{fdo60769.odt, Test::testFdo60769},
 };
 for (unsigned int i = 0; i  SAL_N_ELEMENTS(aMethods); ++i)
 {
@@ -116,6 +118,32 @@ void Test::testFirstHeaderFooter()
 CPPUNIT_ASSERT_EQUAL(OUString(Left footer2),  
parseDump(/root/page[6]/footer/txt/text()));
 }
 
+void Test::testFdo60769()
+{
+// Test multi-paragraph comment range feature.
+uno::Referencetext::XTextDocument xTextDocument(mxComponent, 
uno::UNO_QUERY);
+uno::Referencecontainer::XEnumerationAccess 
xParaEnumAccess(xTextDocument-getText(), uno::UNO_QUERY);
+uno::Referencecontainer::XEnumeration xParaEnum = 
xParaEnumAccess-createEnumeration();
+uno::Referencecontainer::XEnumerationAccess 
xRunEnumAccess(xParaEnum-nextElement(), uno::UNO_QUERY);
+uno::Referencecontainer::XEnumeration xRunEnum = 
xRunEnumAccess-createEnumeration();
+while (xRunEnum-hasMoreElements())
+{
+uno::Referencebeans::XPropertySet 
xPropertySet(xRunEnum-nextElement(), uno::UNO_QUERY);
+OUString aType =  getPropertyOUString(xPropertySet, 
TextPortionType);
+// First paragraph: no field end, no anchor
+CPPUNIT_ASSERT(aType == Text || aType == TextFieldStart);
+}
+
+xRunEnumAccess.set(xParaEnum-nextElement(), uno::UNO_QUERY);
+while (xRunEnum-hasMoreElements())
+{
+uno::Referencebeans::XPropertySet 
xPropertySet(xRunEnum-nextElement(), uno::UNO_QUERY);
+OUString aType =  getPropertyOUString(xPropertySet, 
TextPortionType);
+// Second paragraph: no field start
+CPPUNIT_ASSERT(aType == Text || aType == TextFieldEnd || aType == 
TextFieldEnd);
+}
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(Test);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/sw/source/core/unocore/unoportenum.cxx 
b/sw/source/core/unocore/unoportenum.cxx
index d05b8f5..2829d3f 100644
--- a/sw/source/core/unocore/unoportenum.cxx
+++ b/sw/source/core/unocore/unoportenum.cxx
@@ -754,6 +754,18 @@ lcl_ExportHints(
 ReferenceXTextField xField =
 SwXTextField::CreateSwXTextField(*pDoc, 
pAttr-GetFld());
 pPortion-SetTextField(xField);
+
+// If this is a postit field and it has a fieldmark
+// associated, set the fieldmark as a bookmark.
+const SwField* pField = pAttr-GetFld().GetFld();
+if (pField-Which() == RES_POSTITFLD)
+{
+const SwPostItField* pPostItField = 
dynamic_castconst SwPostItField*(pField);
+IDocumentMarkAccess* pMarkAccess = 
pDoc-getIDocumentMarkAccess();
+IDocumentMarkAccess::const_iterator_t it = 
pMarkAccess-findMark(pPostItField-GetName());
+if (it != pMarkAccess-getMarksEnd())
+

[Libreoffice-commits] core.git: Branch 'libreoffice-4-0' - sfx2/source

2013-03-22 Thread Cédric Bosdonnat
 sfx2/source/control/thumbnailview.cxx |   19 ++-
 1 file changed, 18 insertions(+), 1 deletion(-)

New commits:
commit 8396ef6b53bc2363aff158be34eeb93cd21fc2be
Author: Cédric Bosdonnat cedric.bosdon...@free.fr
Date:   Wed Mar 20 17:06:31 2013 +0100

Template Manager: select first item when getting focus if no selection

Change-Id: Ie012e010ca92728725535345c76fc9f5eb31a254
(cherry picked from commit ec2f84b376f595b0553297d25b7716f6b97e1b87)
Reviewed-on: https://gerrit.libreoffice.org/2910
Reviewed-by: Michael Meeks michael.me...@suse.com
Tested-by: Michael Meeks michael.me...@suse.com

diff --git a/sfx2/source/control/thumbnailview.cxx 
b/sfx2/source/control/thumbnailview.cxx
index c996f0f..57dba07 100644
--- a/sfx2/source/control/thumbnailview.cxx
+++ b/sfx2/source/control/thumbnailview.cxx
@@ -579,12 +579,29 @@ void ThumbnailView::Paint( const Rectangle aRect)
 
 void ThumbnailView::GetFocus()
 {
-Control::GetFocus();
+// Select the first item if nothing selected
+int nSelected = -1;
+for (size_t i = 0, n = mItemList.size(); i  n  nSelected == -1; ++i)
+{
+if (mItemList[i]-isSelected())
+nSelected = i;
+}
+
+if ( nSelected == -1  mItemList.size( )  0 )
+{
+mItemList[0]-setSelection(true);
+maItemStateHdl.Call(mItemList[0]);
+
+if (IsReallyVisible()  IsUpdateMode())
+Invalidate();
+}
 
 // Tell the accessible object that we got the focus.
 ThumbnailViewAcc* pAcc = ThumbnailViewAcc::getImplementation( 
GetAccessible( sal_False ) );
 if( pAcc )
 pAcc-GetFocus();
+
+Control::GetFocus();
 }
 
 void ThumbnailView::LoseFocus()
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[PUSHED libreoffice-4-0] Template Manager: select first item when getting focus if no...

2013-03-22 Thread Michael Meeks (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2910

Approvals:
  Michael Meeks: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2910
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie012e010ca92728725535345c76fc9f5eb31a254
Gerrit-PatchSet: 2
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0
Gerrit-Owner: Bosdonnat Cedric cedric.bosdon...@free.fr
Gerrit-Reviewer: Michael Meeks michael.me...@suse.com

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


[Libreoffice-commits] core.git: Branch 'libreoffice-4-0' - sfx2/source

2013-03-22 Thread Cédric Bosdonnat
 sfx2/source/doc/templatedlg.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 617b885df741da12535b14798ee101872476f7bc
Author: Cédric Bosdonnat cedric.bosdon...@free.fr
Date:   Wed Mar 20 16:03:29 2013 +0100

Template Manager: fixed control WinBits reset... was breaking tabstop

Change-Id: I6e542ecc0e0f5a2b3e0ca59a52bb809b1a23284f
(cherry picked from commit 5fa5f95612c53511fb951660b4ad397321e8)
Reviewed-on: https://gerrit.libreoffice.org/2909
Reviewed-by: Petr Mladek pmla...@suse.cz
Tested-by: Petr Mladek pmla...@suse.cz

diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index e9f85eb..b9d3945 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -163,7 +163,7 @@ SfxTemplateManagerDlg::SfxTemplateManagerDlg (Window 
*parent)
 
mpSearchEdit-SetUpdateDataHdl(LINK(this,SfxTemplateManagerDlg,SearchUpdateHdl));
 mpSearchEdit-EnableUpdateData();
 
-maView-SetStyle(WB_VSCROLL);
+maView-SetStyle(maView-GetStyle() | WB_VSCROLL);
 maView-setItemMaxTextLength(TEMPLATE_ITEM_MAX_TEXT_LENGTH);
 
 
maView-setItemDimensions(TEMPLATE_ITEM_MAX_WIDTH,TEMPLATE_ITEM_THUMBNAIL_MAX_HEIGHT,
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[PUSHED libreoffice-4-0] Template Manager: fixed control WinBits reset... was breakin...

2013-03-22 Thread Petr Mladek (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2909

Approvals:
  Petr Mladek: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2909
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I6e542ecc0e0f5a2b3e0ca59a52bb809b1a23284f
Gerrit-PatchSet: 2
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0
Gerrit-Owner: Bosdonnat Cedric cedric.bosdon...@free.fr
Gerrit-Reviewer: Petr Mladek pmla...@suse.cz

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


[Libreoffice-commits] core.git: 2 commits - cppuhelper/inc cppuhelper/ZipPackage_cppuhelper_odk_headers.mk sw/inc sw/source

2013-03-22 Thread Michael Meeks
 cppuhelper/ZipPackage_cppuhelper_odk_headers.mk |1 
 cppuhelper/inc/cppuhelper/implbase13.hxx|  299 
 sw/inc/unotextcursor.hxx|   21 +
 sw/source/core/unocore/unoobj.cxx   |   62 
 sw/source/core/unocore/unoparagraph.cxx |3 
 5 files changed, 384 insertions(+), 2 deletions(-)

New commits:
commit 1d0c1d4b8298c52b226e5c39b4dd98f9ec38a222
Author: Michael Meeks michael.me...@suse.com
Date:   Thu Mar 21 21:44:14 2013 +

implement part of XMultiPropertySet on SwXTextCursor.

Change-Id: I903f049a3bdba96a8e1ac613ca8b9443a062fe8f

diff --git a/sw/inc/unotextcursor.hxx b/sw/inc/unotextcursor.hxx
index 485a4df..d0b0dde 100644
--- a/sw/inc/unotextcursor.hxx
+++ b/sw/inc/unotextcursor.hxx
@@ -24,6 +24,7 @@
 #include com/sun/star/lang/XServiceInfo.hpp
 #include com/sun/star/beans/XPropertySet.hpp
 #include com/sun/star/beans/XPropertyState.hpp
+#include com/sun/star/beans/XMultiPropertySet.hpp
 #include com/sun/star/beans/XMultiPropertyStates.hpp
 #include com/sun/star/container/XEnumerationAccess.hpp
 #include com/sun/star/container/XContentEnumerationAccess.hpp
@@ -34,7 +35,7 @@
 #include com/sun/star/text/XParagraphCursor.hpp
 #include com/sun/star/text/XRedline.hpp
 
-#include cppuhelper/implbase12.hxx
+#include cppuhelper/implbase13.hxx
 
 #include comphelper/uno3.hxx
 
@@ -47,10 +48,11 @@ struct SwPosition;
 class SwUnoCrsr;
 
 
-typedef ::cppu::WeakImplHelper12
+typedef ::cppu::WeakImplHelper13
::com::sun::star::lang::XServiceInfo
 ,   ::com::sun::star::beans::XPropertySet
 ,   ::com::sun::star::beans::XPropertyState
+,   ::com::sun::star::beans::XMultiPropertySet
 ,   ::com::sun::star::beans::XMultiPropertyStates
 ,   ::com::sun::star::container::XEnumerationAccess
 ,   ::com::sun::star::container::XContentEnumerationAccess
@@ -191,6 +193,21 @@ public:
 ::com::sun::star::lang::WrappedTargetException,
 ::com::sun::star::uno::RuntimeException);
 
+// XMultiPropertySet
+virtual void SAL_CALL setPropertyValues(
+const ::com::sun::star::uno::Sequence ::rtl::OUString  
aPropertyNames,
+const ::com::sun::star::uno::Sequence ::com::sun::star::uno::Any 
 aValues );
+virtual ::com::sun::star::uno::Sequence ::com::sun::star::uno::Any  
SAL_CALL
+getPropertyValues( const ::com::sun::star::uno::Sequence 
::rtl::OUString  aPropertyNames );
+virtual void SAL_CALL addPropertiesChangeListener(
+const ::com::sun::star::uno::Sequence ::rtl::OUString  
aPropertyNames,
+const ::com::sun::star::uno::Reference 
css::beans::XPropertiesChangeListener  xListener );
+virtual void SAL_CALL removePropertiesChangeListener(
+const ::com::sun::star::uno::Reference 
css::beans::XPropertiesChangeListener  xListener );
+virtual void SAL_CALL firePropertiesChangeEvent(
+const ::com::sun::star::uno::Sequence ::rtl::OUString  
aPropertyNames,
+const ::com::sun::star::uno::Reference 
css::beans::XPropertiesChangeListener  xListener );
+
 // XMultiPropertyStates
 virtual void SAL_CALL setAllPropertiesToDefault()
 throw (::com::sun::star::uno::RuntimeException);
diff --git a/sw/source/core/unocore/unoobj.cxx 
b/sw/source/core/unocore/unoobj.cxx
index 75b7f0b..91b30f5 100644
--- a/sw/source/core/unocore/unoobj.cxx
+++ b/sw/source/core/unocore/unoobj.cxx
@@ -2332,6 +2332,68 @@ throw (beans::UnknownPropertyException, 
lang::WrappedTargetException,
 return getPropertyDefaults ( aSequence ).getConstArray()[0];
 }
 
+void SAL_CALL SwXTextCursor::setPropertyValues(
+const uno::Sequence ::rtl::OUString  aPropertyNames,
+const uno::Sequence uno::Any  aValues )
+{
+if( aValues.getLength() != aPropertyNames.getLength() )
+{
+OSL_FAIL( mis-matched property value sequences );
+throw lang::IllegalArgumentException();
+}
+
+SolarMutexGuard aGuard;
+
+SwUnoCrsr  rUnoCursor( m_pImpl-GetCursorOrThrow() );
+
+// a little lame to have to copy into this.
+uno::Sequence beans::PropertyValue  aPropertyValues( aValues.getLength() 
);
+for ( sal_Int32 i = 0; i  aPropertyNames.getLength(); i++ )
+{
+if ( aPropertyNames[ i ].equalsAsciiL(
+SW_PROP_NAME(UNO_NAME_IS_SKIP_HIDDEN_TEXT)) ||
+ aPropertyNames[ i ].equalsAsciiL(
+SW_PROP_NAME(UNO_NAME_IS_SKIP_PROTECTED_TEXT)) )
+{
+// the behaviour of these is hard to model in a group
+OSL_ASSERT(invalid property name for batch setting);
+throw lang::IllegalArgumentException();
+}
+aPropertyValues[ i ].Name = aPropertyNames[ i ];
+aPropertyValues[ i ].Value = aValues[ i ];
+}
+SwUnoCursorHelper::SetPropertyValues( rUnoCursor, m_pImpl-m_rPropSet, 
aPropertyValues );
+}
+
+uno::Sequence uno::Any  SAL_CALL
+SwXTextCursor::getPropertyValues( const uno::Sequence ::rtl::OUString  
aPropertyNames )
+{
+   

[Libreoffice-commits] core.git: basic/source

2013-03-22 Thread Eike Rathke
 basic/source/runtime/methods.cxx |   17 ++---
 1 file changed, 14 insertions(+), 3 deletions(-)

New commits:
commit e8638ad5a7196ea79d90415b86a99a4c9f110a5e
Author: Eike Rathke er...@redhat.com
Date:   Fri Mar 22 17:42:20 2013 +0100

in Val() check status after stringToDouble()

instead of calling checkArithmeticOverflow()

Change-Id: I2e3307ee054db77bab0a106d886823dba9e56ea8

diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index 0318b82..76c8dd9 100644
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -1782,9 +1782,20 @@ RTLFUNC(Val)
 }
 else
 {
-// #57844 use localized function
-nResult = ::rtl::math::stringToDouble( aStr, '.', ',', NULL, NULL 
);
-checkArithmeticOverflow( nResult );
+rtl_math_ConversionStatus eStatus = rtl_math_ConversionStatus_Ok;
+sal_Int32 nParseEnd = 0;
+nResult = ::rtl::math::stringToDouble( aStr, '.', ',', eStatus, 
nParseEnd );
+if ( eStatus != rtl_math_ConversionStatus_Ok )
+StarBASIC::Error( SbERR_MATH_OVERFLOW );
+/* TODO: we should check whether all characters were parsed here,
+ * but earlier code silently ignored trailing nonsense such as 1x
+ * resulting in 1 with the side effect that any alpha-only-string
+ * like x resulted in 0. Not changing that now (2013-03-22) as
+ * user macros may rely on it. */
+#if 0
+else if ( nParseEnd != aStr.getLength() )
+StarBASIC::Error( SbERR_CONVERSION );
+#endif
 }
 
 rPar.Get(0)-PutDouble( nResult );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[PATCH] String::AppendAscii cleanup

2013-03-22 Thread Ricardo Montania (via Code Review)
Hi,

I have submitted a patch for review:

https://gerrit.libreoffice.org/2914

To pull it, you can do:

git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/14/2914/1

String::AppendAscii cleanup

Change-Id: I3c1ff291488b7747e143982aa7ea95169175c2c2
---
M basctl/source/basicide/baside2.cxx
M connectivity/source/drivers/dbase/DIndex.cxx
M connectivity/source/drivers/dbase/DTable.cxx
M cui/source/dialogs/hyphen.cxx
M cui/source/dialogs/postdlg.cxx
M cui/source/options/optdict.cxx
6 files changed, 22 insertions(+), 23 deletions(-)



diff --git a/basctl/source/basicide/baside2.cxx 
b/basctl/source/basicide/baside2.cxx
index 72d594d..f8962c5 100644
--- a/basctl/source/basicide/baside2.cxx
+++ b/basctl/source/basicide/baside2.cxx
@@ -1339,7 +1339,7 @@
 ScriptDocument aDocument( GetDocument() );
 String aLibName( GetLibName() );
 LibraryLocation eLocation = aDocument.getLibraryLocation( aLibName );
-String aModName( GetName() );
+OUString aModName( GetName() );
 String aLibSubName;
 if( xBasic.Is()  aDocument.isInVBAMode()  XModule().Is() )
 {
@@ -1355,7 +1355,7 @@
 ModuleInfoHelper::getObjectName( xLib, aModName, sObjName 
);
 if( !sObjName.isEmpty() )
 {
-aModName.AppendAscii( 
().Append(sObjName).AppendAscii());
+aModName +=  ( + sObjName + );
 }
 }
 break;
diff --git a/connectivity/source/drivers/dbase/DIndex.cxx 
b/connectivity/source/drivers/dbase/DIndex.cxx
index 0cb4630..1e70a5c 100644
--- a/connectivity/source/drivers/dbase/DIndex.cxx
+++ b/connectivity/source/drivers/dbase/DIndex.cxx
@@ -509,16 +509,15 @@
 aName = getString(xCol-getFastPropertyValue(PROPERTY_ID_NAME));
 
 const String 
aQuote(m_pTable-getConnection()-getMetaData()-getIdentifierQuoteString());
-String aStatement;
-aStatement.AssignAscii(SELECT );
+OUString aStatement( SELECT  );
 aStatement += aQuote;
 aStatement += aName;
 aStatement += aQuote;
-aStatement.AppendAscii( FROM );
+aStatement +=  FROM ;
 aStatement += aQuote;
 aStatement += m_pTable-getName().getStr();
 aStatement += aQuote;
-aStatement.AppendAscii( ORDER BY );
+aStatement +=  ORDER BY ;
 aStatement += aQuote;
 aStatement += aName;
 aStatement += aQuote;
diff --git a/connectivity/source/drivers/dbase/DTable.cxx 
b/connectivity/source/drivers/dbase/DTable.cxx
index ee2d7df..386d802 100644
--- a/connectivity/source/drivers/dbase/DTable.cxx
+++ b/connectivity/source/drivers/dbase/DTable.cxx
@@ -2318,8 +2318,8 @@
 aURL.SetURL(aName);
 
 aURL.setExtension( _sExtension );
-String sNewName(newName);
-sNewName.AppendAscii(.);
+OUString sNewName(newName);
+sNewName += .;
 sNewName += _sExtension;
 
 try
diff --git a/cui/source/dialogs/hyphen.cxx b/cui/source/dialogs/hyphen.cxx
index 82bef8d..26326647 100644
--- a/cui/source/dialogs/hyphen.cxx
+++ b/cui/source/dialogs/hyphen.cxx
@@ -521,10 +521,10 @@
 void SvxHyphenWordDialog::SetWindowTitle( LanguageType nLang )
 {
 String aLangStr( SvtLanguageTable::GetLanguageString( nLang ) );
-String aTmp( aLabel );
-aTmp.AppendAscii( RTL_CONSTASCII_STRINGPARAM(  ( ) );
-aTmp.Append( aLangStr );
-aTmp.Append( sal_Unicode( ')' ) );
+OUString aTmp( aLabel );
+aTmp +=  (;
+aTmp += aLangStr;
+aTmp += );
 SetText( aTmp );
 }
 
diff --git a/cui/source/dialogs/postdlg.cxx b/cui/source/dialogs/postdlg.cxx
index cec8c01..4e2465e 100644
--- a/cui/source/dialogs/postdlg.cxx
+++ b/cui/source/dialogs/postdlg.cxx
@@ -134,8 +134,8 @@
 
 void SvxPostItDialog::ShowLastAuthor(const String rAuthor, const String 
rDate)
 {
-String sTxt( rAuthor );
-sTxt.AppendAscii( RTL_CONSTASCII_STRINGPARAM( ,  ) );
+OUString sTxt( rAuthor );
+sTxt += , ;
 sTxt += rDate;
 m_pLastEditFT-SetText( sTxt );
 }
@@ -187,23 +187,23 @@
 Time aTime( Time::SYSTEM );
 String aTmp( SvtUserOptions().GetID() );
 const LocaleDataWrapper rLocaleWrapper( 
Application::GetSettings().GetLocaleDataWrapper() );
-String aStr( m_pEditED-GetText() );
-aStr.AppendAscii( RTL_CONSTASCII_STRINGPARAM( \n  ) );
+OUString aStr( m_pEditED-GetText() );
+aStr += \n ;
 
 if ( aTmp.Len()  0 )
 {
 aStr += aTmp;
-aStr.AppendAscii( RTL_CONSTASCII_STRINGPARAM( ,  ) );
+aStr += , ;
 }
 aStr += rLocaleWrapper.getDate(aDate);
-aStr.AppendAscii( RTL_CONSTASCII_STRINGPARAM( ,  ) );
+aStr += , ;
 aStr += rLocaleWrapper.getTime(aTime, sal_False, sal_False);
-aStr.AppendAscii( RTL_CONSTASCII_STRINGPARAM(  \n ) );
+aStr +=  \n;
 
 aStr = convertLineEnd(aStr, GetSystemLineEnd());
 
 m_pEditED-SetText(aStr);
-xub_StrLen nLen = aStr.Len();
+   

[Libreoffice-commits] core.git: Branch 'feature/formula-core-rework' - sc/inc sc/source

2013-03-22 Thread Kohei Yoshida
 sc/inc/dociter.hxx|   18 ---
 sc/inc/document.hxx   |1 
 sc/source/core/data/autonamecache.cxx |2 
 sc/source/core/data/dociter.cxx   |  146 +-
 sc/source/core/data/document.cxx  |4 
 sc/source/core/tool/chgtrack.cxx  |8 -
 sc/source/core/tool/compiler.cxx  |   18 +--
 sc/source/core/tool/detfunc.cxx   |   22 +--
 sc/source/core/tool/interpr5.cxx  |2 
 sc/source/ui/Accessibility/AccessibleCell.cxx |2 
 sc/source/ui/app/transobj.cxx |4 
 sc/source/ui/docshell/dbdocfun.cxx|2 
 sc/source/ui/unoobj/cellsuno.cxx  |   27 +---
 sc/source/ui/view/viewfunc.cxx|3 
 14 files changed, 105 insertions(+), 154 deletions(-)

New commits:
commit 47f3f7201907013196232884937975e23617eb6c
Author: Kohei Yoshida kohei.yosh...@gmail.com
Date:   Fri Mar 22 13:03:23 2013 -0400

Simplify ScCellIterator.

Change-Id: I33b10e68434fe0047f8e7c3959b87a51f3460d29

diff --git a/sc/inc/dociter.hxx b/sc/inc/dociter.hxx
index 3683111..c104a33 100644
--- a/sc/inc/dociter.hxx
+++ b/sc/inc/dociter.hxx
@@ -214,19 +214,14 @@ class ScCellIterator// walk through all cells 
in an area
 {   // for SubTotal no hidden and no sub-total 
lines
 private:
 ScDocument* pDoc;
-SCCOL   nStartCol;
-SCROW   nStartRow;
-SCTAB   nStartTab;
-SCCOL   nEndCol;
-SCROW   nEndRow;
-SCTAB   nEndTab;
-SCCOL   nCol;
-SCROW   nRow;
-SCTAB   nTab;
+ScAddress maStartPos;
+ScAddress maEndPos;
+ScAddress maCurPos;
 SCSIZE  nColRow;
 boolbSubTotal;
 
 ScBaseCell* GetThis();
+void init();
 public:
 ScCellIterator(ScDocument* pDocument,
SCCOL nSCol, SCROW nSRow, SCTAB nSTab,
@@ -236,10 +231,7 @@ public:
const ScRange rRange, bool bSTotal = 
false);
 ScBaseCell* GetFirst();
 ScBaseCell* GetNext();
-SCCOL   GetCol() const { return nCol; }
-SCROW   GetRow() const { return nRow; }
-SCTAB   GetTab() const { return nTab; }
-ScAddress   GetPos() const { return ScAddress( nCol, nRow, nTab ); }
+const ScAddress GetPos() const { return maCurPos; }
 };
 
 class ScQueryCellIterator   // walk through all non-empty cells in an 
area
diff --git a/sc/inc/document.hxx b/sc/inc/document.hxx
index e0f19cd..742bfc9 100644
--- a/sc/inc/document.hxx
+++ b/sc/inc/document.hxx
@@ -1213,6 +1213,7 @@ public:
 double rResult );
 
 SC_DLLPUBLIC const SfxPoolItem* GetAttr( SCCOL nCol, SCROW nRow, 
SCTAB nTab, sal_uInt16 nWhich ) const;
+SC_DLLPUBLIC const SfxPoolItem* GetAttr( const ScAddress rPos, sal_uInt16 
nWhich ) const;
 SC_DLLPUBLIC const ScPatternAttr*   GetPattern( SCCOL nCol, SCROW nRow, 
SCTAB nTab ) const;
 SC_DLLPUBLIC const ScPatternAttr*GetMostUsedPattern( SCCOL nCol, SCROW 
nStartRow, SCROW nEndRow, SCTAB nTab ) const;
 const ScPatternAttr*GetSelectionPattern( const ScMarkData rMark, bool 
bDeep = true );
diff --git a/sc/source/core/data/autonamecache.cxx 
b/sc/source/core/data/autonamecache.cxx
index 4dde59f..f0e98dc 100644
--- a/sc/source/core/data/autonamecache.cxx
+++ b/sc/source/core/data/autonamecache.cxx
@@ -84,7 +84,7 @@ const ScAutoNameAddresses 
ScAutoNameCache::GetNameOccurrences( const String rN
 }
 if ( ScGlobal::GetpTransliteration()-isEqual( aStr, rName ) )
 {
-rAddresses.push_back( ScAddress( aIter.GetCol(), 
aIter.GetRow(), aIter.GetTab() ) );
+rAddresses.push_back(aIter.GetPos());
 }
 }
 }
diff --git a/sc/source/core/data/dociter.cxx b/sc/source/core/data/dociter.cxx
index 33533f6..d5417d5 100644
--- a/sc/source/core/data/dociter.cxx
+++ b/sc/source/core/data/dociter.cxx
@@ -940,152 +940,114 @@ ScCellIterator::ScCellIterator( ScDocument* pDocument,
 SCCOL nSCol, SCROW nSRow, SCTAB nSTab,
 SCCOL nECol, SCROW nERow, SCTAB nETab, bool 
bSTotal ) :
 pDoc( pDocument ),
-nStartCol( nSCol),
-nStartRow( nSRow),
-nStartTab( nSTab ),
-nEndCol( nECol ),
-nEndRow( nERow),
-nEndTab( nETab ),
+maStartPos(nSCol, nSRow, nSTab),
+maEndPos(nECol, nERow, nETab),
+nColRow(0),
 bSubTotal(bSTotal)
-
 {
-SCTAB nDocMaxTab = pDocument-GetTableCount() - 1;
-
-PutInOrder( nStartCol, nEndCol);
-PutInOrder( nStartRow, nEndRow);
-PutInOrder( nStartTab, nEndTab );
-
-if (!ValidCol(nStartCol)) nStartCol = MAXCOL;
-if (!ValidCol(nEndCol)) nEndCol = MAXCOL;
-if (!ValidRow(nStartRow)) 

[Libreoffice-commits] core.git: Branch 'libreoffice-4-0' - sfx2/inc sfx2/source

2013-03-22 Thread Cédric Bosdonnat
 sfx2/inc/sfx2/thumbnailview.hxx  |8 -
 sfx2/source/control/thumbnailview.cxx|  125 +--
 sfx2/source/control/thumbnailviewacc.cxx |2 
 3 files changed, 24 insertions(+), 111 deletions(-)

New commits:
commit e2ce03c2eaf1bdf6a3b736052be8e2ed8ef8c6ca
Author: Cédric Bosdonnat cedric.bosdon...@free.fr
Date:   Thu Mar 21 11:49:01 2013 +0100

Template Manager: removed some dead selection code

(cherry picked from commit bfd1bcb204ed3ca35df1455a346a0ee7254a1191)

Conflicts:
sfx2/source/control/thumbnailview.cxx

Change-Id: Ib5ebcd928e77a115f4f62a50724656c33ae13c61
Reviewed-on: https://gerrit.libreoffice.org/2911
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/sfx2/inc/sfx2/thumbnailview.hxx b/sfx2/inc/sfx2/thumbnailview.hxx
index 8eb9426..efc5e78 100644
--- a/sfx2/inc/sfx2/thumbnailview.hxx
+++ b/sfx2/inc/sfx2/thumbnailview.hxx
@@ -202,10 +202,7 @@ public:
 
 void SelectItem( sal_uInt16 nItemId );
 
-sal_uInt16 GetSelectItemId() const { return mnSelItemId; }
-
-bool IsItemSelected( sal_uInt16 nItemId ) const
-{ return nItemId == mnSelItemId; }
+bool IsItemSelected( sal_uInt16 nItemId ) const;
 
 void deselectItem (const sal_uInt16 nItemId);
 
@@ -258,8 +255,6 @@ protected:
 
 virtual void DataChanged( const DataChangedEvent rDCEvt );
 
-virtual bool StartDrag( const CommandEvent rCEvt, Region rRegion );
-
 virtual ::com::sun::star::uno::Reference 
::com::sun::star::accessibility::XAccessible  CreateAccessible();
 
 protected:
@@ -310,7 +305,6 @@ protected:
 long mnVisLines;
 long mnLines;
 sal_uInt16 mnScrBarOffset;
-sal_uInt16 mnSelItemId;
 sal_uInt16 mnHighItemId;
 sal_uInt16 mnCols;
 sal_uInt16 mnFirstLine;
diff --git a/sfx2/source/control/thumbnailview.cxx 
b/sfx2/source/control/thumbnailview.cxx
index 57dba07..63ba189 100644
--- a/sfx2/source/control/thumbnailview.cxx
+++ b/sfx2/source/control/thumbnailview.cxx
@@ -92,7 +92,6 @@ void ThumbnailView::ImplInit()
 mnLines = 0;
 mnFirstLine = 0;
 mnScrBarOffset = 1;
-mnSelItemId = 0;
 mnHighItemId= 0;
 mnCols  = 0;
 mnSpacing   = 0;
@@ -589,11 +588,7 @@ void ThumbnailView::GetFocus()
 
 if ( nSelected == -1  mItemList.size( )  0 )
 {
-mItemList[0]-setSelection(true);
-maItemStateHdl.Call(mItemList[0]);
-
-if (IsReallyVisible()  IsUpdateMode())
-Invalidate();
+SelectItem( 1 );
 }
 
 // Tell the accessible object that we got the focus.
@@ -710,10 +705,9 @@ void ThumbnailView::RemoveItem( sal_uInt16 nItemId )
 }
 
 // reset variables
-if ( (mnHighItemId == nItemId) || (mnSelItemId == nItemId) )
+if ( (mnHighItemId == nItemId) )
 {
 mnHighItemId= 0;
-mnSelItemId = 0;
 }
 
 CalculateItemPositions();
@@ -729,7 +723,6 @@ void ThumbnailView::Clear()
 // reset variables
 mnFirstLine = 0;
 mnHighItemId= 0;
-mnSelItemId = 0;
 
 CalculateItemPositions();
 
@@ -777,19 +770,18 @@ void ThumbnailView::setItemDimensions(long itemWidth, 
long thumbnailHeight, long
 
 void ThumbnailView::SelectItem( sal_uInt16 nItemId )
 {
-size_t nItemPos = 0;
+size_t nItemPos = GetItemPos( nItemId );
+if ( nItemPos == THUMBNAILVIEW_ITEM_NOTFOUND )
+return;
 
-if ( nItemId )
+ThumbnailViewItem* pItem = mItemList[nItemPos];
+if (!pItem-isSelected())
 {
-nItemPos = GetItemPos( nItemId );
-if ( nItemPos == THUMBNAILVIEW_ITEM_NOTFOUND )
-return;
-}
+mItemList[nItemPos]-setSelection(true);
+maItemStateHdl.Call(mItemList[nItemPos]);
 
-if ( mnSelItemId != nItemId)
-{
-sal_uInt16 nOldItem = mnSelItemId ? mnSelItemId : 1;
-mnSelItemId = nItemId;
+if (IsReallyVisible()  IsUpdateMode())
+Invalidate();
 
 bool bNewOut = IsReallyVisible()  IsUpdateMode();
 
@@ -815,44 +807,8 @@ void ThumbnailView::SelectItem( sal_uInt16 nItemId )
 
 if( ImplHasAccessibleListeners() )
 {
-// focus event (deselect)
-if( nOldItem )
-{
-const size_t nPos = GetItemPos( nItemId );
-
-if( nPos != THUMBNAILVIEW_ITEM_NOTFOUND )
-{
-ThumbnailViewAcc* pItemAcc = 
ThumbnailViewAcc::getImplementation(
-mItemList[nPos]-GetAccessible( 
mbIsTransientChildrenDisabled ) );
-
-if( pItemAcc )
-{
-::com::sun::star::uno::Any aOldAny, aNewAny;
-if( !mbIsTransientChildrenDisabled )
-{
-aOldAny = ::com::sun::star::uno::Reference 
::com::sun::star::uno::XInterface (
-

[Libreoffice-commits] core.git: Branch 'libreoffice-4-0' - 2 commits - sfx2/inc sfx2/source

2013-03-22 Thread Cédric Bosdonnat
 sfx2/inc/sfx2/templateview.hxx   |1 
 sfx2/inc/sfx2/thumbnailview.hxx  |7 +
 sfx2/source/control/templateabstractview.cxx |   10 ++
 sfx2/source/control/templateview.cxx |   16 +---
 sfx2/source/control/templateview.src |6 -
 sfx2/source/control/thumbnailview.cxx|  104 +--
 6 files changed, 117 insertions(+), 27 deletions(-)

New commits:
commit 9296cf4088a0637f0326803fe220816ebc8daf22
Author: Cédric Bosdonnat cedric.bosdon...@free.fr
Date:   Fri Mar 22 16:33:20 2013 +0100

fdo#61390: Fixed the tabstop in the TemplateView.

Change-Id: I887b11646efb9a839da11cd3e20cdf7e532caf3e
(cherry picked from commit 7a25aa2821ccf7318ce4a13efe171763989009d5)
Reviewed-on: https://gerrit.libreoffice.org/2913
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/sfx2/inc/sfx2/templateview.hxx b/sfx2/inc/sfx2/templateview.hxx
index 3e2a7c8..e219905 100644
--- a/sfx2/inc/sfx2/templateview.hxx
+++ b/sfx2/inc/sfx2/templateview.hxx
@@ -51,7 +51,6 @@ protected:
 private:
 TemplateAbstractView* mpMasterView;
 
-ControlmaButtons;
 PushButton maAllButton;
 FixedText  maFTName;
 sal_uInt16 mnId;
diff --git a/sfx2/source/control/templateabstractview.cxx 
b/sfx2/source/control/templateabstractview.cxx
index de2091f..14ab811 100644
--- a/sfx2/source/control/templateabstractview.cxx
+++ b/sfx2/source/control/templateabstractview.cxx
@@ -114,7 +114,7 @@ bool ViewFilter_Keyword::operator ()(const 
ThumbnailViewItem *pItem)
 
 TemplateAbstractView::TemplateAbstractView (Window *pParent, WinBits 
nWinStyle, bool bDisableTransientChildren)
 : ThumbnailView(pParent,nWinStyle,bDisableTransientChildren),
-  mpItemView(new TemplateView(this)),
+  mpItemView(new TemplateView(pParent)),
   mbFilteredResults(false),
   meFilterOption(FILTER_APP_WRITER)
 {
@@ -123,7 +123,7 @@ TemplateAbstractView::TemplateAbstractView (Window 
*pParent, WinBits nWinStyle,
 
 TemplateAbstractView::TemplateAbstractView(Window *pParent, const ResId 
rResId, bool bDisableTransientChildren)
 : ThumbnailView(pParent,rResId,bDisableTransientChildren),
-  mpItemView(new TemplateView(this)),
+  mpItemView(new TemplateView(pParent)),
   mbFilteredResults(false),
   meFilterOption(FILTER_APP_WRITER)
 {
@@ -190,8 +190,14 @@ void TemplateAbstractView::filterTemplatesByApp (const 
FILTER_APPLICATION eApp)
 
 void TemplateAbstractView::showOverlay (bool bVisible)
 {
+Show(!bVisible);
 mpItemView-Show(bVisible);
 
+mpItemView-SetPosSizePixel(GetPosPixel(), GetSizePixel());
+mpItemView-SetStyle(GetStyle());
+
+mpItemView-GrabFocus();
+
 // Clear items is the overlay is closed.
 if (!bVisible)
 {
diff --git a/sfx2/source/control/templateview.cxx 
b/sfx2/source/control/templateview.cxx
index 615465d..46ebeaa 100644
--- a/sfx2/source/control/templateview.cxx
+++ b/sfx2/source/control/templateview.cxx
@@ -34,14 +34,13 @@ using namespace drawinglayer::attribute;
 using namespace drawinglayer::primitive2d;
 
 TemplateView::TemplateView (Window *pParent)
-: ThumbnailView(pParent,WB_VSCROLL),
+: ThumbnailView(pParent,WB_VSCROLL | WB_TABSTOP),
   mpMasterView(NULL),
-  maButtons(this, SfxResId(CONTROL_BUTTONS)),
-  maAllButton(maButtons, SfxResId(BTN_ALL_TEMPLATES)),
-  maFTName(maButtons, SfxResId(FT_NAME)),
+  maAllButton(this, SfxResId(BTN_ALL_TEMPLATES)),
+  maFTName(this, SfxResId(FT_NAME)),
   mnId(0)
 {
-mnHeaderHeight = maButtons.GetSizePixel().getHeight();
+mnHeaderHeight = maAllButton.GetSizePixel().getHeight() + 
maAllButton.GetPosPixel().Y() * 2;
 maAllButton.SetStyle(maAllButton.GetStyle() | WB_FLATBUTTON);
 }
 
@@ -88,13 +87,8 @@ void TemplateView::Resize()
 Size aWinSize = GetOutputSize();
 
 // Set the buttons panel and buttons size
-Size aPanelSize = maButtons.GetSizePixel();
-int nDeltaW = aWinSize.getWidth() - aPanelSize.getWidth();
-aPanelSize.setWidth(aWinSize.getWidth());
-maButtons.SetSizePixel(aPanelSize);
-
 Size aNameSize = maFTName.GetSizePixel();
-aNameSize.setWidth(aNameSize.getWidth() + nDeltaW);
+aNameSize.setWidth( aWinSize.getWidth() - maFTName.GetPosPixel().X());
 maFTName.SetSizePixel(aNameSize);
 
 ThumbnailView::Resize();
diff --git a/sfx2/source/control/templateview.src 
b/sfx2/source/control/templateview.src
index db4d575..8549c96 100644
--- a/sfx2/source/control/templateview.src
+++ b/sfx2/source/control/templateview.src
@@ -8,12 +8,6 @@
 
 #include templateview.hrc
 
-Control CONTROL_BUTTONS
-{
-Size = MAP_APPFONT( 290, 17 );
-TabStop = False;
-};
-
 PushButton BTN_ALL_TEMPLATES
 {
 Pos = MAP_APPFONT( 1, 1 );
commit 43bbcfc7a1625aa79b69c443c492f0969b31baad
Author: Cédric Bosdonnat cedric.bosdon...@free.fr
Date:   Fri Mar 22 11:43:11 2013 +0100

fdo#61390: simple 

[Libreoffice-commits] core.git: vcl/aqua

2013-03-22 Thread Christian Lohmaier
 vcl/aqua/source/dtrans/DataFlavorMapping.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 683142294f291a77329a2d266124432aeba8522b
Author: Christian Lohmaier lohmaier+libreoff...@googlemail.com
Date:   Fri Mar 22 14:00:19 2013 +0100

get rid of two-argument compareToAscii

As I don't see a point in comparing a mimetype with only a
substring, it probably could be a simple compareToAscii, but
play it save and use startsWith.

Change-Id: Ic33c8089283def615999ddf80cd12f6fe219ed17
Reviewed-on: https://gerrit.libreoffice.org/2907
Reviewed-by: Thomas Arnhold tho...@arnhold.org
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/vcl/aqua/source/dtrans/DataFlavorMapping.cxx 
b/vcl/aqua/source/dtrans/DataFlavorMapping.cxx
index a1a69ff..6cfc2c9 100644
--- a/vcl/aqua/source/dtrans/DataFlavorMapping.cxx
+++ b/vcl/aqua/source/dtrans/DataFlavorMapping.cxx
@@ -526,7 +526,7 @@ NSString* DataFlavorMapper::openOfficeToSystemFlavor(const 
DataFlavor oOOFlavor
 
   for (size_t i = 0; i  SIZE_FLAVOR_MAP; i++)
 {
-  if (oOOFlavor.MimeType.compareToAscii(flavorMap[i].OOoFlavor, 
strlen(flavorMap[i].OOoFlavor)) == 0)
+  if (oOOFlavor.MimeType.startsWith(flavorMap[i].OOoFlavor))
 {
   sysFlavor = flavorMap[i].SystemFlavor;
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: config_host/README

2013-03-22 Thread Stephan Bergmann
 config_host/README |   14 +++---
 1 file changed, 7 insertions(+), 7 deletions(-)

New commits:
commit 43f59b86cd2c65bf408bea8108b56839b21b8b4e
Author: Stephan Bergmann sberg...@redhat.com
Date:   Fri Mar 22 18:12:05 2013 +0100

Consistent config_XXX.h naming

Change-Id: Ie7cb4356fd2400753934ca907f09cf240ada734e

diff --git a/config_host/README b/config_host/README
index 05068b3..4f9d3ce 100644
--- a/config_host/README
+++ b/config_host/README
@@ -11,20 +11,20 @@ Adding a new setting:
 =
 
 - do AC_DEFINE(HAVE_FOO) in configure.ac when a setting should be set
-- choose the proper config_host/config_xxx.h file to use
+- choose the proper config_host/config_XXX.h file to use
 - if it is a global setting (such as availability of a compiler feature),
 use config_host/config_global.h
-- otherwise check if there is a matching config_host/config_hxx.h file
+- otherwise check if there is a matching config_host/config_XXX.h file
 - if none matches, add a new one:
-- add config_host/config_xxx.h.in here, with just #ifndef include guard
-- add AC_CONFIG_HEADERS([config_host/config_xxx.h]) next to the others
+- add config_host/config_XXX.h.in here, with just #ifndef include guard
+- add AC_CONFIG_HEADERS([config_host/config_XXX.h]) next to the others
 in configure.ac
-- add config_hxx.h to config_host/.gitignore
-- add #undef HAVE_FOO to the config_host/config_hxx.h , possibly with a comment
+- add config_XXX.h to config_host/.gitignore
+- add #undef HAVE_FOO to the config_host/config_XXX.h , possibly with a comment
 - if the setting is an on/off setting (i.e. not a value of anything),
   add the following block right after it
 #ifndef HAVE_FOO
 #define HAVE_FOO 0
 #endif
-- add #include config_xxx.h before any #if HAVE_FOO in a source file
+- add #include config_XXX.h before any #if HAVE_FOO in a source file
 - make sure you use #if HAVE_FOO, do not use #ifdef
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[PUSHED libreoffice-4-0] Template Manager: removed some dead selection code

2013-03-22 Thread Fridrich Strba (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2911

Approvals:
  Fridrich Strba: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2911
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib5ebcd928e77a115f4f62a50724656c33ae13c61
Gerrit-PatchSet: 3
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0
Gerrit-Owner: Bosdonnat Cedric cedric.bosdon...@free.fr
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org

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


[PUSHED libreoffice-4-0] fdo#61390: simple keybard support in TemplateManager

2013-03-22 Thread Fridrich Strba (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2912

Approvals:
  Fridrich Strba: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2912
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I5ba67583c835bcc00b075071411c0d6590a07f9a
Gerrit-PatchSet: 3
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0
Gerrit-Owner: Bosdonnat Cedric cedric.bosdon...@free.fr
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org

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


[PUSHED libreoffice-4-0] fdo#61390: Fixed the tabstop in the TemplateView.

2013-03-22 Thread Fridrich Strba (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2913

Approvals:
  Fridrich Strba: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2913
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I887b11646efb9a839da11cd3e20cdf7e532caf3e
Gerrit-PatchSet: 3
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0
Gerrit-Owner: Bosdonnat Cedric cedric.bosdon...@free.fr
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org

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


[PUSHED] get rid of two-argument compareToAscii

2013-03-22 Thread Fridrich Strba (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2907

Approvals:
  Thomas Arnhold: Looks good to me, but someone else must approve
  Fridrich Strba: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2907
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic33c8089283def615999ddf80cd12f6fe219ed17
Gerrit-PatchSet: 2
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Christian Lohmaier lohmaier+libreoff...@googlemail.com
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org
Gerrit-Reviewer: Thomas Arnhold tho...@arnhold.org

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


[Libreoffice-commits] core.git: basctl/source connectivity/source cui/source

2013-03-22 Thread Ricardo Montania
 basctl/source/basicide/baside2.cxx   |4 ++--
 connectivity/source/drivers/dbase/DIndex.cxx |7 +++
 connectivity/source/drivers/dbase/DTable.cxx |4 ++--
 cui/source/dialogs/hyphen.cxx|8 
 cui/source/dialogs/postdlg.cxx   |   16 
 cui/source/options/optdict.cxx   |6 +++---
 6 files changed, 22 insertions(+), 23 deletions(-)

New commits:
commit 9c281fda84bea4407bb8265d1e125fc6e429064d
Author: Ricardo Montania rica...@linuxafundo.com.br
Date:   Fri Mar 22 13:52:16 2013 -0300

String::AppendAscii cleanup

Change-Id: I3c1ff291488b7747e143982aa7ea95169175c2c2
Reviewed-on: https://gerrit.libreoffice.org/2914
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/basctl/source/basicide/baside2.cxx 
b/basctl/source/basicide/baside2.cxx
index 72d594d..f8962c5 100644
--- a/basctl/source/basicide/baside2.cxx
+++ b/basctl/source/basicide/baside2.cxx
@@ -1339,7 +1339,7 @@ EntryDescriptor ModulWindow::CreateEntryDescriptor()
 ScriptDocument aDocument( GetDocument() );
 String aLibName( GetLibName() );
 LibraryLocation eLocation = aDocument.getLibraryLocation( aLibName );
-String aModName( GetName() );
+OUString aModName( GetName() );
 String aLibSubName;
 if( xBasic.Is()  aDocument.isInVBAMode()  XModule().Is() )
 {
@@ -1355,7 +1355,7 @@ EntryDescriptor ModulWindow::CreateEntryDescriptor()
 ModuleInfoHelper::getObjectName( xLib, aModName, sObjName 
);
 if( !sObjName.isEmpty() )
 {
-aModName.AppendAscii( 
().Append(sObjName).AppendAscii());
+aModName +=  ( + sObjName + );
 }
 }
 break;
diff --git a/connectivity/source/drivers/dbase/DIndex.cxx 
b/connectivity/source/drivers/dbase/DIndex.cxx
index 0cb4630..1e70a5c 100644
--- a/connectivity/source/drivers/dbase/DIndex.cxx
+++ b/connectivity/source/drivers/dbase/DIndex.cxx
@@ -509,16 +509,15 @@ sal_Bool ODbaseIndex::CreateImpl()
 aName = getString(xCol-getFastPropertyValue(PROPERTY_ID_NAME));
 
 const String 
aQuote(m_pTable-getConnection()-getMetaData()-getIdentifierQuoteString());
-String aStatement;
-aStatement.AssignAscii(SELECT );
+OUString aStatement( SELECT  );
 aStatement += aQuote;
 aStatement += aName;
 aStatement += aQuote;
-aStatement.AppendAscii( FROM );
+aStatement +=  FROM ;
 aStatement += aQuote;
 aStatement += m_pTable-getName().getStr();
 aStatement += aQuote;
-aStatement.AppendAscii( ORDER BY );
+aStatement +=  ORDER BY ;
 aStatement += aQuote;
 aStatement += aName;
 aStatement += aQuote;
diff --git a/connectivity/source/drivers/dbase/DTable.cxx 
b/connectivity/source/drivers/dbase/DTable.cxx
index ee2d7df..386d802 100644
--- a/connectivity/source/drivers/dbase/DTable.cxx
+++ b/connectivity/source/drivers/dbase/DTable.cxx
@@ -2318,8 +2318,8 @@ namespace
 aURL.SetURL(aName);
 
 aURL.setExtension( _sExtension );
-String sNewName(newName);
-sNewName.AppendAscii(.);
+OUString sNewName(newName);
+sNewName += .;
 sNewName += _sExtension;
 
 try
diff --git a/cui/source/dialogs/hyphen.cxx b/cui/source/dialogs/hyphen.cxx
index 82bef8d..26326647 100644
--- a/cui/source/dialogs/hyphen.cxx
+++ b/cui/source/dialogs/hyphen.cxx
@@ -521,10 +521,10 @@ SvxHyphenWordDialog::~SvxHyphenWordDialog()
 void SvxHyphenWordDialog::SetWindowTitle( LanguageType nLang )
 {
 String aLangStr( SvtLanguageTable::GetLanguageString( nLang ) );
-String aTmp( aLabel );
-aTmp.AppendAscii( RTL_CONSTASCII_STRINGPARAM(  ( ) );
-aTmp.Append( aLangStr );
-aTmp.Append( sal_Unicode( ')' ) );
+OUString aTmp( aLabel );
+aTmp +=  (;
+aTmp += aLangStr;
+aTmp += );
 SetText( aTmp );
 }
 
diff --git a/cui/source/dialogs/postdlg.cxx b/cui/source/dialogs/postdlg.cxx
index cec8c01..4e2465e 100644
--- a/cui/source/dialogs/postdlg.cxx
+++ b/cui/source/dialogs/postdlg.cxx
@@ -134,8 +134,8 @@ SvxPostItDialog::~SvxPostItDialog()
 
 void SvxPostItDialog::ShowLastAuthor(const String rAuthor, const String 
rDate)
 {
-String sTxt( rAuthor );
-sTxt.AppendAscii( RTL_CONSTASCII_STRINGPARAM( ,  ) );
+OUString sTxt( rAuthor );
+sTxt += , ;
 sTxt += rDate;
 m_pLastEditFT-SetText( sTxt );
 }
@@ -187,23 +187,23 @@ IMPL_LINK_NOARG(SvxPostItDialog, Stamp)
 Time aTime( Time::SYSTEM );
 String aTmp( SvtUserOptions().GetID() );
 const LocaleDataWrapper rLocaleWrapper( 
Application::GetSettings().GetLocaleDataWrapper() );
-String aStr( m_pEditED-GetText() );
-aStr.AppendAscii( RTL_CONSTASCII_STRINGPARAM( \n  ) );
+OUString aStr( m_pEditED-GetText() );
+

[PUSHED] String::AppendAscii cleanup

2013-03-22 Thread Fridrich Strba (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2914

Approvals:
  Fridrich Strba: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2914
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I3c1ff291488b7747e143982aa7ea95169175c2c2
Gerrit-PatchSet: 2
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Ricardo Montania rica...@linuxafundo.com.br
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org

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


[Libreoffice-commits] core.git: sal/inc

2013-03-22 Thread Stephan Bergmann
 sal/inc/rtl/allocator.hxx   |6 ++
 sal/inc/rtl/instance.hxx|4 +---
 sal/inc/rtl/stringutils.hxx |4 
 sal/inc/sal/config.h|4 
 sal/inc/sal/types.h |4 
 5 files changed, 7 insertions(+), 15 deletions(-)

New commits:
commit 1f393e01ca9ed878e6abc2cfa2bc8cf8e64f2ef3
Author: Stephan Bergmann sberg...@redhat.com
Date:   Fri Mar 22 18:19:55 2013 +0100

For convenience, include config_global.h in sal/config.h

...which must be included first thing everywhere anyway.

Change-Id: Idbbf941b526f48a89d6398e19404b1ff0e23a6b4

diff --git a/sal/inc/rtl/allocator.hxx b/sal/inc/rtl/allocator.hxx
index 2cbf95b..05575c2 100644
--- a/sal/inc/rtl/allocator.hxx
+++ b/sal/inc/rtl/allocator.hxx
@@ -19,14 +19,12 @@
 #ifndef INCLUDED_RTL_ALLOCATOR_HXX
 #define INCLUDED_RTL_ALLOCATOR_HXX
 
+#include sal/config.h
+
 #include sal/types.h
 #include rtl/alloc.h
 #include cstddef
 
-#if defined LIBO_INTERNAL_ONLY
-#include config_global.h
-#endif
-
 /// @cond INTERNAL
 
 //##
diff --git a/sal/inc/rtl/instance.hxx b/sal/inc/rtl/instance.hxx
index 912a3d4..1efda80 100644
--- a/sal/inc/rtl/instance.hxx
+++ b/sal/inc/rtl/instance.hxx
@@ -20,9 +20,7 @@
 #ifndef INCLUDED_RTL_INSTANCE_HXX
 #define INCLUDED_RTL_INSTANCE_HXX
 
-#if defined LIBO_INTERNAL_ONLY
-#include config_global.h
-#endif
+#include sal/config.h
 
 #include osl/doublecheckedlocking.h
 #include osl/getglobalmutex.hxx
diff --git a/sal/inc/rtl/stringutils.hxx b/sal/inc/rtl/stringutils.hxx
index 765319d..7ca2281 100644
--- a/sal/inc/rtl/stringutils.hxx
+++ b/sal/inc/rtl/stringutils.hxx
@@ -31,10 +31,6 @@
 
 #include sal/config.h
 
-#if defined LIBO_INTERNAL_ONLY
-#include config_global.h
-#endif
-
 // Manually defining RTL_DISABLE_FAST_STRING allows to force turning fast 
string concatenation off
 // (e.g. for debugging).
 #ifndef RTL_DISABLE_FAST_STRING
diff --git a/sal/inc/sal/config.h b/sal/inc/sal/config.h
index 03e24c6..e990e35 100644
--- a/sal/inc/sal/config.h
+++ b/sal/inc/sal/config.h
@@ -20,6 +20,10 @@
 #ifndef _SAL_CONFIG_H_
 #define _SAL_CONFIG_H_
 
+#if defined LIBO_INTERNAL_ONLY
+#include config_global.h
+#endif
+
 #ifndef INCLUDED_STDLIB_H
 #include stdlib.h
 #define INCLUDED_STDLIB_H
diff --git a/sal/inc/sal/types.h b/sal/inc/sal/types.h
index b89b056..346abf6 100644
--- a/sal/inc/sal/types.h
+++ b/sal/inc/sal/types.h
@@ -23,10 +23,6 @@
 #include sal/config.h
 #include sal/macros.h
 
-#if defined LIBO_INTERNAL_ONLY
-#include config_global.h
-#endif
-
 #include sal/typesizes.h
 
 #ifdef __cplusplus
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: [PATCH] String::AppendAscii cleanup

2013-03-22 Thread Eike Rathke
Hi,

On Friday, 2013-03-22 16:53:20 +, Ricardo Montania (via Code Review) wrote:

hum.. did that

 --- a/cui/source/dialogs/postdlg.cxx
 +++ b/cui/source/dialogs/postdlg.cxx
 -xub_StrLen nLen = aStr.Len();
 +xub_StrLen nLen = aStr.getLength();

compile? Note that OUString::getLength() returns saL_int32 while
xub_StrLen is sal_uInt16.

  Eike

-- 
LibreOffice Calc developer. Number formatter stricken i18n transpositionizer.
New GnuPG key 0x65632D3A : 2265 D7F3 A7B0 95CC 3918  630B 6A6C D5B7 6563 2D3A
Old GnuPG key 0x293C05FD : 997A 4C60 CE41 0149 0DB3  9E96 2F1A D073 293C 05FD
Support the FSFE, care about Free Software! https://fsfe.org/support/?erack


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


Re: Minutes of ESC call

2013-03-22 Thread Stephan Bergmann

On 03/21/2013 05:28 PM, Jan Holesovsky wrote:

* Kill include guards in .hxx, and use #pragma once instead
 + makes the headers nicer
 + the benchmark available on the net seems to suggest it speeds
   up MSVC
 + Lubos' test seems to suggest that there is ~no difference for
   gcc
+ consensus: let's just do it after 4.0.2 is out


The only drawback I can find is that #pragma once is non-standard and 
therefore 
http://gcc.gnu.org/onlinedocs/gcc-4.7.2/cpp/Alternatives-to-Wrapper-_0023ifndef.html#Alternatives-to-Wrapper-_0023ifndef---arguably 
rightly so---recommends against its use.


Stephan

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


[Libreoffice-commits] core.git: oox/source sal/inc tools/source vcl/source

2013-03-22 Thread Thomas Arnhold
 oox/source/export/chartexport.cxx |3 +--
 sal/inc/sal/log-areas.dox |1 +
 tools/source/generic/config.cxx   |   11 ++-
 vcl/source/window/accel.cxx   |2 +-
 vcl/source/window/winproc.cxx |2 +-
 5 files changed, 6 insertions(+), 13 deletions(-)

New commits:
commit 5ea8a48a3b26ac326ea5fe4a637a2d9b59cd2b94
Author: Thomas Arnhold tho...@arnhold.org
Date:   Thu Mar 21 10:19:50 2013 +0100

clean up DBG_ERRORn

Those were DBG_ERRORn before and were falsely changed to OSL_TRACE by me.

See:
1707a350af8a0909ae88c2b11deb714f8b2a93ff
533f89e49395bbc31baaab9ade46db934b383e14

Change-Id: I4f4188ba25b988128a539542f49797ea6985702e
Reviewed-on: https://gerrit.libreoffice.org/2900
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/oox/source/export/chartexport.cxx 
b/oox/source/export/chartexport.cxx
index ef3c014..4f4b83d 100644
--- a/oox/source/export/chartexport.cxx
+++ b/oox/source/export/chartexport.cxx
@@ -2417,8 +2417,7 @@ void ChartExport::exportDataPoints(
 catch( const uno::Exception  rEx )
 {
 (void)rEx; // avoid warning for pro build
-OSL_TRACE( Exception caught during Export of data point: 
%s,
-OUStringToOString( rEx.Message, 
RTL_TEXTENCODING_ASCII_US ).getStr() );
+SAL_WARN( oox, Exception caught during Export of data 
point:   rEx.Message );
 }
 }
 else
diff --git a/sal/inc/sal/log-areas.dox b/sal/inc/sal/log-areas.dox
index 3bb316f..07c7399 100644
--- a/sal/inc/sal/log-areas.dox
+++ b/sal/inc/sal/log-areas.dox
@@ -195,6 +195,7 @@ certain functionality.
 
 @li @c tools.debug
 @li @c tools.datetime
+@li @c tools.generic
 @li @c tools.memtools
 @li @c tools.rc - resource manager
 @li @c tools.stream - SvStream class
diff --git a/tools/source/generic/config.cxx b/tools/source/generic/config.cxx
index 9d2d284..dac13f0 100644
--- a/tools/source/generic/config.cxx
+++ b/tools/source/generic/config.cxx
@@ -537,15 +537,8 @@ static void ImplReadConfig( ImplConfigData* pData )
 
 static void ImplWriteConfig( ImplConfigData* pData )
 {
-#ifdef DBG_UTIL
-if ( DbgIsAssert() )
-{
-if ( pData-mnTimeStamp != ImplSysGetConfigTimeStamp( 
pData-maFileName ) )
-{
-OSL_TRACE( Config overwrites modified configfile:\n %s, 
rtl::OUStringToOString(pData-maFileName, RTL_TEXTENCODING_UTF8).getStr() );
-}
-}
-#endif
+SAL_WARN_IF( pData-mnTimeStamp != ImplSysGetConfigTimeStamp( 
pData-maFileName ),
+tools.generic, Config overwrites modified configfile:   
pData-maFileName );
 
 // Read config list from buffer
 sal_uIntPtr nBufLen;
diff --git a/vcl/source/window/accel.cxx b/vcl/source/window/accel.cxx
index 261c4d0..653dac9 100644
--- a/vcl/source/window/accel.cxx
+++ b/vcl/source/window/accel.cxx
@@ -264,7 +264,7 @@ void Accelerator::ImplInsertAccel( sal_uInt16 nItemId, 
const KeyCode rKeyCode,
 }
 else if ( !mpData-maKeyMap.insert( std::make_pair( nCode, pEntry ) 
).second )
 {
-OSL_TRACE( Accelerator::InsertItem(): KeyCode (Key: %lx) already 
exists, nCode );
+SAL_WARN( vcl.layout, Accelerator::InsertItem(): KeyCode (Key:   
nCode  ) already exists );
 delete pEntry;
 }
 else
diff --git a/vcl/source/window/winproc.cxx b/vcl/source/window/winproc.cxx
index b8f1cde..98c856b 100644
--- a/vcl/source/window/winproc.cxx
+++ b/vcl/source/window/winproc.cxx
@@ -2661,7 +2661,7 @@ long ImplWindowFrameProc( Window* pWindow, SalFrame* 
/*pFrame*/,
 break;
 #ifdef DBG_UTIL
 default:
-OSL_TRACE( ImplWindowFrameProc(): unknown event (%lu), 
(sal_uLong)nEvent );
+SAL_WARN( vcl.layout, ImplWindowFrameProc(): unknown event ( 
 nEvent  ) );
 break;
 #endif
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[PUSHED] clean up DBG_ERRORn

2013-03-22 Thread Fridrich Strba (via Code Review)
Hi,

Thank you for your patch!  It has been merged to LibreOffice.

If you are interested in details, please visit

https://gerrit.libreoffice.org/2900

Approvals:
  Fridrich Strba: Verified; Looks good to me, approved


-- 
To view, visit https://gerrit.libreoffice.org/2900
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I4f4188ba25b988128a539542f49797ea6985702e
Gerrit-PatchSet: 3
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Thomas Arnhold tho...@arnhold.org
Gerrit-Reviewer: Fridrich Strba fridr...@documentfoundation.org

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


Build error - testFdo60915

2013-03-22 Thread Marcos Souza
Hi guys,

I'm trying to build LO with head 683142294f291a77329a2d266124432aeba8522b
and I'm getting the following error message:

[build CXX] svx/source/unodraw/unopool.cxx
svl.cxx:321:Assertion
Test name: (anonymous namespace)::Test::testFdo60915
equality assertion failed
- Expected: 18/05/2446
- Actual  : 17/05/2446

Failures !!!
Run: 2   Failure total: 1   Failures: 1   Errors: 0

Anybody knows how to solve this?

-- 
Att,

Marcos Paulo de Souza
Acadêmico de Ciencia da Computação - FURB - SC
Github: https://github.com/marcosps/
Uma vida sem desafios é uma vida sem razão
A life without challenges, is a non reason life
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Minutes of ESC call

2013-03-22 Thread Michael Stahl
On 22/03/13 18:25, Stephan Bergmann wrote:
 On 03/21/2013 05:28 PM, Jan Holesovsky wrote:
 * Kill include guards in .hxx, and use #pragma once instead
  + makes the headers nicer
  + the benchmark available on the net seems to suggest it speeds
up MSVC
  + Lubos' test seems to suggest that there is ~no difference for
gcc
  + consensus: let's just do it after 4.0.2 is out
 
 The only drawback I can find is that #pragma once is non-standard and 
 therefore 
 http://gcc.gnu.org/onlinedocs/gcc-4.7.2/cpp/Alternatives-to-Wrapper-_0023ifndef.html#Alternatives-to-Wrapper-_0023ifndef---arguably
  
 rightly so---recommends against its use.

hmm... does that really matter? what is the likelihood that anybody
wants to use something older than GCC 3.4 to build LO anyway?

after all we rely on the implementation providing two's complement
arithmetic as well in a lot of places which is not mandated by C++
standard... (not to mention small conveniences like shared libraries)

also the existing include guards are not a stellar example of standard
compliant code anyway, given that a lot of them define macros starting
with underscores, and thus trample over the part of the namespace
reserved for the implementation by the C++ standard...

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


Re: Minutes of ESC call

2013-03-22 Thread Stephan Bergmann

On 03/22/2013 06:41 PM, Michael Stahl wrote:

On 22/03/13 18:25, Stephan Bergmann wrote:

On 03/21/2013 05:28 PM, Jan Holesovsky wrote:

* Kill include guards in .hxx, and use #pragma once instead
  + makes the headers nicer
  + the benchmark available on the net seems to suggest it speeds
up MSVC
  + Lubos' test seems to suggest that there is ~no difference for
gcc
+ consensus: let's just do it after 4.0.2 is out


The only drawback I can find is that #pragma once is non-standard and
therefore
http://gcc.gnu.org/onlinedocs/gcc-4.7.2/cpp/Alternatives-to-Wrapper-_0023ifndef.html#Alternatives-to-Wrapper-_0023ifndef---arguably
rightly so---recommends against its use.


hmm... does that really matter?


Hopefully not.  But if the claimed MSVC speedup was non-existent, it 
would be humble to go with the (not completely inadequate, after all) 
standard means and avoid one potential pitfall.  (/Every/ deviation from 
the standard, however minuscule, is bound to bite us one day down the 
road.)  Or maybe not.  Anyway, I should probably have inserted very 
minor before drawback, or even kept away from the keyboard entirely... ;)


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


[Libreoffice-commits] core.git: sw/inc sw/source

2013-03-22 Thread Stephan Bergmann
 sw/inc/unotextcursor.hxx  |   22 +-
 sw/source/core/unocore/unoobj.cxx |7 +++
 2 files changed, 24 insertions(+), 5 deletions(-)

New commits:
commit 8d68b885b021a60af0fd199a167cbaeac1f15116
Author: Stephan Bergmann sberg...@redhat.com
Date:   Fri Mar 22 19:12:21 2013 +0100

Looser throw specifiers

Change-Id: I671d5d6459a3e1305c3d7a5ff21b63a5f6d0a289

diff --git a/sw/inc/unotextcursor.hxx b/sw/inc/unotextcursor.hxx
index d0b0dde..93c1bcf 100644
--- a/sw/inc/unotextcursor.hxx
+++ b/sw/inc/unotextcursor.hxx
@@ -196,17 +196,29 @@ public:
 // XMultiPropertySet
 virtual void SAL_CALL setPropertyValues(
 const ::com::sun::star::uno::Sequence ::rtl::OUString  
aPropertyNames,
-const ::com::sun::star::uno::Sequence ::com::sun::star::uno::Any 
 aValues );
+const ::com::sun::star::uno::Sequence ::com::sun::star::uno::Any 
 aValues )
+throw (
+css::beans::PropertyVetoException,
+css::lang::IllegalArgumentException,
+css::lang::WrappedTargetException, css::uno::RuntimeException);
+
 virtual ::com::sun::star::uno::Sequence ::com::sun::star::uno::Any  
SAL_CALL
-getPropertyValues( const ::com::sun::star::uno::Sequence 
::rtl::OUString  aPropertyNames );
+getPropertyValues( const ::com::sun::star::uno::Sequence 
::rtl::OUString  aPropertyNames )
+throw (css::uno::RuntimeException);
+
 virtual void SAL_CALL addPropertiesChangeListener(
 const ::com::sun::star::uno::Sequence ::rtl::OUString  
aPropertyNames,
-const ::com::sun::star::uno::Reference 
css::beans::XPropertiesChangeListener  xListener );
+const ::com::sun::star::uno::Reference 
css::beans::XPropertiesChangeListener  xListener )
+throw (css::uno::RuntimeException);
+
 virtual void SAL_CALL removePropertiesChangeListener(
-const ::com::sun::star::uno::Reference 
css::beans::XPropertiesChangeListener  xListener );
+const ::com::sun::star::uno::Reference 
css::beans::XPropertiesChangeListener  xListener )
+throw (css::uno::RuntimeException);
+
 virtual void SAL_CALL firePropertiesChangeEvent(
 const ::com::sun::star::uno::Sequence ::rtl::OUString  
aPropertyNames,
-const ::com::sun::star::uno::Reference 
css::beans::XPropertiesChangeListener  xListener );
+const ::com::sun::star::uno::Reference 
css::beans::XPropertiesChangeListener  xListener )
+throw (css::uno::RuntimeException);
 
 // XMultiPropertyStates
 virtual void SAL_CALL setAllPropertiesToDefault()
diff --git a/sw/source/core/unocore/unoobj.cxx 
b/sw/source/core/unocore/unoobj.cxx
index 91b30f5..050b9cb 100644
--- a/sw/source/core/unocore/unoobj.cxx
+++ b/sw/source/core/unocore/unoobj.cxx
@@ -2335,6 +2335,9 @@ throw (beans::UnknownPropertyException, 
lang::WrappedTargetException,
 void SAL_CALL SwXTextCursor::setPropertyValues(
 const uno::Sequence ::rtl::OUString  aPropertyNames,
 const uno::Sequence uno::Any  aValues )
+throw (
+css::beans::PropertyVetoException, css::lang::IllegalArgumentException,
+css::lang::WrappedTargetException, css::uno::RuntimeException)
 {
 if( aValues.getLength() != aPropertyNames.getLength() )
 {
@@ -2367,6 +2370,7 @@ void SAL_CALL SwXTextCursor::setPropertyValues(
 
 uno::Sequence uno::Any  SAL_CALL
 SwXTextCursor::getPropertyValues( const uno::Sequence ::rtl::OUString  
aPropertyNames )
+throw (css::uno::RuntimeException)
 {
 // a banal implementation for now
 uno::Sequence uno::Any  aValues( aPropertyNames.getLength() );
@@ -2378,11 +2382,13 @@ SwXTextCursor::getPropertyValues( const uno::Sequence 
::rtl::OUString  aPrope
 void SAL_CALL SwXTextCursor::addPropertiesChangeListener(
 const uno::Sequence ::rtl::OUString  /* aPropertyNames */,
 const uno::Reference css::beans::XPropertiesChangeListener  /* 
xListener */ )
+throw (css::uno::RuntimeException)
 {
 OSL_FAIL(SwXTextCursor::addPropertiesChangeListener(): not implemented);
 }
 void SAL_CALL SwXTextCursor::removePropertiesChangeListener(
 const uno::Reference css::beans::XPropertiesChangeListener  /* 
xListener */ )
+throw (css::uno::RuntimeException)
 {
 OSL_FAIL(SwXTextCursor::removePropertiesChangeListener(): not 
implemented);
 }
@@ -2390,6 +2396,7 @@ void SAL_CALL 
SwXTextCursor::removePropertiesChangeListener(
 void SAL_CALL SwXTextCursor::firePropertiesChangeEvent(
 const uno::Sequence ::rtl::OUString  /* aPropertyNames */,
 const uno::Reference css::beans::XPropertiesChangeListener  /* 
xListener */ )
+throw (css::uno::RuntimeException)
 {
 OSL_FAIL(SwXTextCursor::firePropertiesChangeEvent(): not implemented);
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: toolkit/source

2013-03-22 Thread Stephan Bergmann
 toolkit/source/controls/stdtabcontroller.cxx |7 +--
 1 file changed, 5 insertions(+), 2 deletions(-)

New commits:
commit 9e2034c0330f969b6795dd9ec8771fdad34777a6
Author: Stephan Bergmann sberg...@redhat.com
Date:   Fri Mar 22 19:13:34 2013 +0100

Missing solar mutex

...as witnessed by the triggered assert

MSVCR90!wassert+0x641
vcllo!ImplDbgTestSolarMutex+0x72 [c:\lo\core\vcl\source\app\dbggui.cxx @ 
1750]
tllo!DbgFunc+0x47a [c:\lo\core\tools\source\debug\debug.cxx @ 1120]
vcllo!DbgTestSolarMutex+0xd 
[c:\lo\core\solver\wntmsci12\inc\tools\debug.hxx @ 295]
vcllo!OutputDevice::ImplInitClipRegion+0x2d 
[c:\lo\core\vcl\source\gdi\outdev.cxx @ 913]
vcllo!Window::Invert+0xef [c:\lo\core\vcl\source\window\window2.cxx @ 411]
vcllo!ImplCursorInvert+0x437 [c:\lo\core\vcl\source\window\cursor.cxx @ 120]
vcllo!Cursor::ImplRestore+0x27 [c:\lo\core\vcl\source\window\cursor.cxx @ 
159]
vcllo!Cursor::ImplDoHide+0x40 [c:\lo\core\vcl\source\window\cursor.cxx @ 
216]
vcllo!Cursor::ImplHide+0x3c [c:\lo\core\vcl\source\window\cursor.cxx @ 234]
vcllo!Window::ImplGrabFocus+0x4aa [c:\lo\core\vcl\source\window\window.cxx 
@ 4053]
vcllo!Window::GrabFocus+0x52 [c:\lo\core\vcl\source\window\window.cxx @ 
7544]
tklo!StdTabController::ImplActivateControl+0x1fe 
[c:\lo\core\toolkit\source\controls\stdtabcontroller.cxx @ 152]
tklo!StdTabController::activateFirst+0x45 
[c:\lo\core\toolkit\source\controls\stdtabcontroller.cxx @ 354]
msci_uno!`anonymous namespace'::callVirtualMethod+0x8a 
[c:\lo\core\bridges\source\cpp_uno\msvc_win32_intel\uno2cpp.cxx @ 76]
msci_uno!`anonymous namespace'::cpp_call+0x4b3 
[c:\lo\core\bridges\source\cpp_uno\msvc_win32_intel\uno2cpp.cxx @ 257]
msci_uno!bridges::cpp_uno::shared::unoInterfaceProxyDispatch+0x321 
[c:\lo\core\bridges\source\cpp_uno\msvc_win32_intel\uno2cpp.cxx @ 438]
binaryurp_uno!binaryurp::IncomingRequest::execute_throw+0xaa8 
[c:\lo\core\binaryurp\source\incomingrequest.cxx @ 245]
binaryurp_uno!binaryurp::IncomingRequest::execute+0xe0 
[c:\lo\core\binaryurp\source\incomingrequest.cxx @ 74]
binaryurp_uno!request+0x6b [c:\lo\core\binaryurp\source\reader.cxx @ 85]
cppu3!cppu_threadpool::JobQueue::enter+0x28d 
[c:\lo\core\cppu\source\threadpool\jobqueue.cxx @ 115]
cppu3!cppu_threadpool::ORequestThread::run+0xc6 
[c:\lo\core\cppu\source\threadpool\thread.cxx @ 175]
cppu3!threadFunc+0x18 [c:\lo\core\solver\wntmsci12\inc\osl\thread.hxx @ 187]
sal3!oslWorkerWrapperFunction+0x23 [c:\lo\core\sal\osl\w32\thread.c @ 60]

during JunitTest_toolkit_unoapi on Windows (which does not use a headless 
mode
for those tests).

Whether locking the class instance's GetMutex() is really necessary here I 
do
not know, but at least be careful to lock the global solar mutex first.

Change-Id: Icbd7936f4bf8433ef6a36912566d43361e911429

diff --git a/toolkit/source/controls/stdtabcontroller.cxx 
b/toolkit/source/controls/stdtabcontroller.cxx
index f9d9ae1..08969cf 100644
--- a/toolkit/source/controls/stdtabcontroller.cxx
+++ b/toolkit/source/controls/stdtabcontroller.cxx
@@ -28,6 +28,7 @@
 #include rtl/uuid.h
 
 #include tools/debug.hxx
+#include vcl/svapp.hxx
 #include vcl/window.hxx
 #include comphelper/sequence.hxx
 
@@ -348,14 +349,16 @@ void StdTabController::activateTabOrder(  ) 
throw(RuntimeException)
 
 void StdTabController::activateFirst(  ) throw(RuntimeException)
 {
-::osl::Guard ::osl::Mutex  aGuard( GetMutex() );
+SolarMutexGuard aSolarGuard;
+::osl::Guard ::osl::Mutex  aGuard( GetMutex() ); //TODO: necessary?
 
 ImplActivateControl( sal_True );
 }
 
 void StdTabController::activateLast(  ) throw(RuntimeException)
 {
-::osl::Guard ::osl::Mutex  aGuard( GetMutex() );
+SolarMutexGuard aSolarGuard;
+::osl::Guard ::osl::Mutex  aGuard( GetMutex() ); //TODO: necessary?
 
 ImplActivateControl( sal_False );
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


  1   2   3   4   >