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

2019-03-05 Thread Libreoffice Gerrit user
 include/tools/solar.h   |1 
 vcl/source/gdi/animate.cxx  |   21 ++-
 vcl/source/gdi/bitmapex.cxx |5 +-
 vcl/source/gdi/gdimtf.cxx   |   84 ++--
 4 files changed, 58 insertions(+), 53 deletions(-)

New commits:
commit 936308d3ef4f43d9c525401cb1cfca197df13b0f
Author: Stephan Bergmann 
AuthorDate: Tue Mar 5 17:38:52 2019 +0100
Commit: Stephan Bergmann 
CommitDate: Wed Mar 6 08:28:58 2019 +0100

Introduce Int32ToSVBT32 for cases that apparently want to write a signed 
value

...and clean up some other (legitimate) uses of UInt32ToSVBT32 to not use a
(somewhat misleading) static_cast(...)

Change-Id: Ifd0c3f771c3f6e20eef3413b9c27fd2514dc0c13
Reviewed-on: https://gerrit.libreoffice.org/68767
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 

diff --git a/include/tools/solar.h b/include/tools/solar.h
index 3fd676acbc2a..721573287685 100644
--- a/include/tools/solar.h
+++ b/include/tools/solar.h
@@ -94,6 +94,7 @@ inline void UInt32ToSVBT32 ( sal_uInt32  n, SVBT32 p )
 p[2] = static_cast(n >> 16);
 p[3] = static_cast(n >> 24);
 }
+inline void Int32ToSVBT32 ( sal_Int32  n, SVBT32 p ) { 
UInt32ToSVBT32(sal_uInt32(n), p); }
 #if defined OSL_LITENDIAN
 inline void DoubleToSVBT64( double n, SVBT64 p ) { p[0] = 
reinterpret_cast(&n)[0];
p[1] = 
reinterpret_cast(&n)[1];
diff --git a/vcl/source/gdi/animate.cxx b/vcl/source/gdi/animate.cxx
index 7e3cb72ac9cf..25eceb595f39 100644
--- a/vcl/source/gdi/animate.cxx
+++ b/vcl/source/gdi/animate.cxx
@@ -17,6 +17,9 @@
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
 
+#include 
+
+#include 
 #include 
 #include 
 #include 
@@ -38,25 +41,25 @@ BitmapChecksum AnimationBitmap::GetChecksum() const
 BitmapChecksum  nCrc = aBmpEx.GetChecksum();
 SVBT32  aBT32;
 
-UInt32ToSVBT32( aPosPix.X(), aBT32 );
+Int32ToSVBT32( aPosPix.X(), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
-UInt32ToSVBT32( aPosPix.Y(), aBT32 );
+Int32ToSVBT32( aPosPix.Y(), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
-UInt32ToSVBT32( aSizePix.Width(), aBT32 );
+Int32ToSVBT32( aSizePix.Width(), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
-UInt32ToSVBT32( aSizePix.Height(), aBT32 );
+Int32ToSVBT32( aSizePix.Height(), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
-UInt32ToSVBT32( nWait, aBT32 );
+Int32ToSVBT32( nWait, aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
-UInt32ToSVBT32( static_cast(eDisposal), aBT32 );
+UInt32ToSVBT32( o3tl::underlyingEnumValue(eDisposal), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
-UInt32ToSVBT32( static_cast(bUserInput), aBT32 );
+UInt32ToSVBT32( sal_uInt32(bUserInput), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
 return nCrc;
@@ -195,10 +198,10 @@ BitmapChecksum Animation::GetChecksum() const
 UInt32ToSVBT32( maList.size(), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
-UInt32ToSVBT32( maGlobalSize.Width(), aBT32 );
+Int32ToSVBT32( maGlobalSize.Width(), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
-UInt32ToSVBT32( maGlobalSize.Height(), aBT32 );
+Int32ToSVBT32( maGlobalSize.Height(), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
 for(auto const & i : maList)
diff --git a/vcl/source/gdi/bitmapex.cxx b/vcl/source/gdi/bitmapex.cxx
index 3db94e9171f3..b3068db0c8bc 100644
--- a/vcl/source/gdi/bitmapex.cxx
+++ b/vcl/source/gdi/bitmapex.cxx
@@ -20,6 +20,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -291,10 +292,10 @@ BitmapChecksum BitmapEx::GetChecksum() const
 SVBT32  aBT32;
 BitmapChecksumOctetArray aBCOA;
 
-UInt32ToSVBT32( static_cast(meTransparent), aBT32 );
+UInt32ToSVBT32( o3tl::underlyingEnumValue(meTransparent), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
-UInt32ToSVBT32( static_cast(mbAlpha), aBT32 );
+UInt32ToSVBT32( sal_uInt32(mbAlpha), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
 if( ( TransparentType::Bitmap == meTransparent ) && !maMask.IsEmpty() )
diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx
index 7038fb7c5244..0aa29bf55173 100644
--- a/vcl/source/gdi/gdimtf.cxx
+++ b/vcl/source/gdi/gdimtf.cxx
@@ -2229,10 +2229,10 @@ BitmapChecksum GDIMetaFile::GetChecksum() const
 BCToBCOA( pAct->GetBitmap().GetChecksum(), aBCOA );
 nCrc = vcl_get_checksum( nCrc, aBCOA, BITMAP_CHECKSUM_SIZE );
 
-UInt32ToSVBT32( pAct->GetPoint().X(), aBT32 );
+Int32ToSVBT32( pAct->GetPoint().X(), aBT32 );
 nCrc = vcl_get_checksum( nCrc, aBT32, 4 );
 
-UInt32ToSVBT32( pAct->GetPoint().Y(), aBT32 );
+Int32ToSVBT32( pAct->GetPoint().Y(), aBT32 );
  

[Libreoffice-commits] core.git: external/harfbuzz

2019-03-05 Thread Libreoffice Gerrit user
 external/harfbuzz/UnpackedTarball_harfbuzz.mk |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit efcf8149b5762d95b158a809430a3d053bb2d41d
Author: Stephan Bergmann 
AuthorDate: Tue Mar 5 17:31:12 2019 +0100
Commit: Stephan Bergmann 
CommitDate: Wed Mar 6 08:28:42 2019 +0100

Record external/harfbuzz/msvc.patch as sent upstream

Change-Id: I47277272170508e9af7617e9b774bbdca05e9ec3
Reviewed-on: https://gerrit.libreoffice.org/68766
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 

diff --git a/external/harfbuzz/UnpackedTarball_harfbuzz.mk 
b/external/harfbuzz/UnpackedTarball_harfbuzz.mk
index 48d7b450bc3a..8101f244f4df 100644
--- a/external/harfbuzz/UnpackedTarball_harfbuzz.mk
+++ b/external/harfbuzz/UnpackedTarball_harfbuzz.mk
@@ -15,6 +15,8 @@ $(eval $(call 
gb_UnpackedTarball_update_autoconf_configs,harfbuzz))
 
 $(eval $(call gb_UnpackedTarball_set_patchlevel,harfbuzz,0))
 
+# * external/harfbuzz/msvc.patch sent upstream as 

+#   "Fix hb_atomic_* variants based on C++11 atomics":
 $(eval $(call gb_UnpackedTarball_add_patches,harfbuzz, \
 external/harfbuzz/msvc.patch \
 ))
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Re: LibreOffice Online Build

2019-03-05 Thread Samuel Mehrbrodt

Hi Ahmed,


Am 06.03.2019 um 03:01 schrieb ahmed elshreif:
--with-poco-includes=/tmp/poco/Net/include --with-poco-libs=/tmp/poco/lib 


This looks suspicious - why is that in /tmp and what is in 
/tmp/poco/Net/include ?
Note that on most recent distros you don't need to build Poco yourself, 
but can just use the version provided by the OS.

No need for these configure parameters then.

Regards
Samuel
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice

[Libreoffice-commits] core.git: sd/uiconfig sw/uiconfig

2019-03-05 Thread Libreoffice Gerrit user
 sd/uiconfig/sdraw/menubar/menubar.xml   |   65 
 sd/uiconfig/sdraw/popupmenu/curve.xml   |2 
 sd/uiconfig/sdraw/popupmenu/drawtext.xml|1 
 sd/uiconfig/sdraw/popupmenu/form.xml|   24 
 sd/uiconfig/sdraw/popupmenu/measure.xml |2 
 sd/uiconfig/sdraw/popupmenu/multiselect.xml |2 
 sd/uiconfig/sdraw/popupmenu/oleobject.xml   |2 
 sd/uiconfig/sdraw/toolbar/arrowsbar.xml |4 
 sd/uiconfig/sdraw/toolbar/arrowshapes.xml   |   32 
 sd/uiconfig/sdraw/toolbar/basicshapes.xml   |2 
 sd/uiconfig/sdraw/toolbar/bezierobjectbar.xml   |2 
 sd/uiconfig/sdraw/toolbar/formsfilterbar.xml|4 
 sd/uiconfig/sdraw/toolbar/formsnavigationbar.xml|3 
 sd/uiconfig/sdraw/toolbar/fullscreenbar.xml |   19 
 sd/uiconfig/sdraw/toolbar/linesbar.xml  |   13 
 sd/uiconfig/sdraw/toolbar/moreformcontrols.xml  |4 
 sd/uiconfig/sdraw/toolbar/optimizetablebar.xml  |6 
 sd/uiconfig/sdraw/toolbar/standardbar.xml   |1 
 sd/uiconfig/sdraw/toolbar/symbolshapes.xml  |   16 
 sd/uiconfig/sdraw/toolbar/textobjectbar.xml |1 
 sd/uiconfig/sdraw/toolbar/viewerbar.xml |2 
 sd/uiconfig/simpress/menubar/menubar.xml| 1312 ++--
 sd/uiconfig/simpress/popupmenu/line.xml |1 
 sd/uiconfig/simpress/popupmenu/media.xml|1 
 sd/uiconfig/simpress/popupmenu/oleobject.xml|1 
 sd/uiconfig/simpress/popupmenu/textbox.xml  |3 
 sd/uiconfig/simpress/toolbar/arrowsbar.xml  |   14 
 sd/uiconfig/simpress/toolbar/arrowshapes.xml|   32 
 sd/uiconfig/simpress/toolbar/basicshapes.xml|   20 
 sd/uiconfig/simpress/toolbar/bezierobjectbar.xml|   12 
 sd/uiconfig/simpress/toolbar/calloutshapes.xml  |3 
 sd/uiconfig/simpress/toolbar/connectorsbar.xml  |   47 
 sd/uiconfig/simpress/toolbar/fontworkobjectbar.xml  |2 
 sd/uiconfig/simpress/toolbar/formsnavigationbar.xml |3 
 sd/uiconfig/simpress/toolbar/fullscreenbar.xml  |   19 
 sd/uiconfig/simpress/toolbar/standardbar.xml|1 
 sd/uiconfig/simpress/toolbar/starshapes.xml |8 
 sd/uiconfig/simpress/toolbar/symbolshapes.xml   |   16 
 sd/uiconfig/simpress/toolbar/tableobjectbar.xml |8 
 sd/uiconfig/simpress/toolbar/textobjectbar.xml  |1 
 sd/uiconfig/simpress/toolbar/viewerbar.xml  |2 
 sw/uiconfig/swriter/toolbar/bezierobjectbar.xml |1 
 42 files changed, 896 insertions(+), 818 deletions(-)

New commits:
commit 668a3de9be203f47357190ea059155e70944741f
Author: andreas kainz 
AuthorDate: Wed Mar 6 00:37:17 2019 +0100
Commit: andreas_kainz 
CommitDate: Wed Mar 6 08:21:02 2019 +0100

sync sdraw and simpress ui files with swriter ui files

Change-Id: I321233437b573d254ca63aaf7274b54334ec066a
Reviewed-on: https://gerrit.libreoffice.org/68786
Tested-by: Jenkins
Reviewed-by: andreas_kainz 

diff --git a/sd/uiconfig/sdraw/menubar/menubar.xml 
b/sd/uiconfig/sdraw/menubar/menubar.xml
index 6283b9a357dc..b465f34498f4 100644
--- a/sd/uiconfig/sdraw/menubar/menubar.xml
+++ b/sd/uiconfig/sdraw/menubar/menubar.xml
@@ -25,6 +25,7 @@
   
   
   
+  
   
   
   
@@ -33,7 +34,6 @@
   
   
   
-  
   
   
   
@@ -43,13 +43,19 @@
   
   
   
+  
   
   
   
   
   
-  
-  
+  
+
+  
+  
+
+  
+  
 
   
   
@@ -85,6 +91,7 @@
   
 
   
+  
   
   
   
@@ -188,8 +195,8 @@
   
   
 
-  
   
+  
 
   
   
@@ -218,6 +225,7 @@
 
   
   
+  
   
 
   
@@ -285,18 +293,18 @@
   
   
   
-  
-
-  
-  
-  
-  
-  
-  
-  
-  
-
-  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
 
   
   
@@ -307,18 +315,21 @@
   
   
   
+  
+  
+  
 
   
   
 
-  
-  
-  
-  
-  
-  
-  
-  
+  
+  
+  
+  
+  
+  
+  
+  
 
   
   
@@ -388,7 +399,7 @@
   
   
   
-  
+  
 
   
   
@@ -557,9 +568,9 @@
 
   
   
-  
-  
   
+  
+  
   
   
 
diff --git a/sd/uiconfig/s

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

2019-03-05 Thread Libreoffice Gerrit user
 sw/qa/extras/odfimport/data/tdf123829.odt |binary
 sw/qa/extras/odfimport/odfimport.cxx  |   11 +++
 sw/source/filter/xml/xmlimp.cxx   |6 ++
 3 files changed, 17 insertions(+)

New commits:
commit 0d2da0acfaa610c690bce552c0ed5df62d4c35cb
Author: Samuel Mehrbrodt 
AuthorDate: Tue Mar 5 13:47:10 2019 +0100
Commit: Samuel Mehrbrodt 
CommitDate: Wed Mar 6 08:11:02 2019 +0100

tdf#123829 Respect CollapseEmptyCellPara setting when reading odf docs

Commit 56b2cf0c10d9caa01ebae1d80465e342d046a85c introduced a "feature"
which would hide an empty line after a table and only make it visible
when the cursor is in it.

So when loading an ODF doc, only enable this feature for which have the
CollapseEmptyCellPara setting set.

Change-Id: Ib4dfbbe8d45eb57547c51c7eee2f81331fc5300e
Reviewed-on: https://gerrit.libreoffice.org/68742
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt 

diff --git a/sw/qa/extras/odfimport/data/tdf123829.odt 
b/sw/qa/extras/odfimport/data/tdf123829.odt
new file mode 100644
index ..3219b4156182
Binary files /dev/null and b/sw/qa/extras/odfimport/data/tdf123829.odt differ
diff --git a/sw/qa/extras/odfimport/odfimport.cxx 
b/sw/qa/extras/odfimport/odfimport.cxx
index 84133227b642..a911635d3a6d 100644
--- a/sw/qa/extras/odfimport/odfimport.cxx
+++ b/sw/qa/extras/odfimport/odfimport.cxx
@@ -23,6 +23,7 @@
 #include 
 #include 
 
+#include 
 #include 
 #include 
 #include 
@@ -916,5 +917,15 @@ DECLARE_ODFIMPORT_TEST(testTdf120677, "tdf120677.fodt")
 // The document used to hang the layout, consuming memory until OOM
 }
 
+DECLARE_ODFIMPORT_TEST(testTdf123829, "tdf123829.odt")
+{
+SwXTextDocument* pTextDoc = 
dynamic_cast(mxComponent.get());
+CPPUNIT_ASSERT(pTextDoc);
+SwDoc* pDoc = pTextDoc->GetDocShell()->GetDoc();
+CPPUNIT_ASSERT_EQUAL_MESSAGE(
+"Compatibility: collapse cell paras should not be set", false,
+
pDoc->getIDocumentSettingAccess().get(DocumentSettingId::COLLAPSE_EMPTY_CELL_PARA));
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/filter/xml/xmlimp.cxx b/sw/source/filter/xml/xmlimp.cxx
index abc22321a47d..80a5a9aeeeba 100644
--- a/sw/source/filter/xml/xmlimp.cxx
+++ b/sw/source/filter/xml/xmlimp.cxx
@@ -1392,6 +1392,7 @@ void SwXMLImport::SetConfigurationSettings(const Sequence 
< PropertyValue > & aC
 bool bPropLineSpacingShrinksFirstLine = false;
 bool bSubtractFlysAnchoredAtFlys = false;
 bool bDisableOffPagePositioning = false;
+bool bCollapseEmptyCellPara = false;
 
 const PropertyValue* currentDatabaseDataSource = nullptr;
 const PropertyValue* currentDatabaseCommand = nullptr;
@@ -1489,6 +1490,8 @@ void SwXMLImport::SetConfigurationSettings(const Sequence 
< PropertyValue > & aC
 bSubtractFlysAnchoredAtFlys = true;
 else if (pValues->Name == "DisableOffPagePositioning")
 bDisableOffPagePositioning = true;
+else if (pValues->Name == "CollapseEmptyCellPara")
+bCollapseEmptyCellPara = true;
 }
 catch( Exception& )
 {
@@ -1660,6 +1663,9 @@ void SwXMLImport::SetConfigurationSettings(const Sequence 
< PropertyValue > & aC
 if ( bDisableOffPagePositioning )
 xProps->setPropertyValue("DisableOffPagePositioning", makeAny(true));
 
+if (!bCollapseEmptyCellPara)
+xProps->setPropertyValue("CollapseEmptyCellPara", makeAny(false));
+
 SwDoc *pDoc = getDoc();
 SfxPrinter *pPrinter = pDoc->getIDocumentDeviceAccess().getPrinter( false 
);
 if( pPrinter )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 sw/qa/uitest/writer_tests5/xwindow.py |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 3061ca82a323ec922dbdf2f5dcc008ade81f23a8
Author: Andrea Gelmini 
AuthorDate: Tue Mar 5 10:53:32 2019 +
Commit: Julien Nabet 
CommitDate: Wed Mar 6 07:05:02 2019 +0100

Fix typo

Change-Id: I0b1c04b846ff5e6197fce59bd3c4325528169a7c
Reviewed-on: https://gerrit.libreoffice.org/68787
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sw/qa/uitest/writer_tests5/xwindow.py 
b/sw/qa/uitest/writer_tests5/xwindow.py
index d63df73c69ea..81104bb7a3ef 100644
--- a/sw/qa/uitest/writer_tests5/xwindow.py
+++ b/sw/qa/uitest/writer_tests5/xwindow.py
@@ -128,7 +128,7 @@ class XWindow(UITestCase):
 xToolkitRobot.keyPress(xKeyEvent)
 xToolkitRobot.keyRelease(xKeyEvent)
 
-# remove moue listener
+# remove mouse listener
 xWindow.removeMouseListener(xMouseListener)
 self.assertEqual(1, mouseListenerCount)
 del xMouseListener
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 linguistic/source/hyphdsp.cxx  |6 +++---
 linguistic/source/hyphdta.cxx  |2 +-
 linguistic/source/spelldsp.cxx |4 ++--
 3 files changed, 6 insertions(+), 6 deletions(-)

New commits:
commit e578e2b7855d0b474eed5b1ef6b808ba25295c06
Author: Julien Nabet 
AuthorDate: Tue Mar 5 21:36:50 2019 +0100
Commit: Julien Nabet 
CommitDate: Wed Mar 6 07:04:22 2019 +0100

Typo: unexpectend->unexpected

Change-Id: Id7aface81f907afdb046a22f1a64641718391000
Reviewed-on: https://gerrit.libreoffice.org/68776
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/linguistic/source/hyphdsp.cxx b/linguistic/source/hyphdsp.cxx
index b15ec9c15807..38cd240c2b76 100644
--- a/linguistic/source/hyphdsp.cxx
+++ b/linguistic/source/hyphdsp.cxx
@@ -299,7 +299,7 @@ Reference< XHyphenatedWord > SAL_CALL
 
 // replace typographical apostroph by ascii apostroph
 OUString aSingleQuote( GetLocaleDataWrapper( nLanguage 
).getQuotationMarkEnd() );
-DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpectend length of 
quotation mark" );
+DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpected length of 
quotation mark" );
 if (!aSingleQuote.isEmpty())
 aChkWord = aChkWord.replace( aSingleQuote[0], '\'' );
 
@@ -434,7 +434,7 @@ Reference< XHyphenatedWord > SAL_CALL
 
 // replace typographical apostroph by ascii apostroph
 OUString aSingleQuote( GetLocaleDataWrapper( nLanguage 
).getQuotationMarkEnd() );
-DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpectend length of 
quotation mark" );
+DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpected length of 
quotation mark" );
 if (!aSingleQuote.isEmpty())
 aChkWord = aChkWord.replace( aSingleQuote[0], '\'' );
 
@@ -559,7 +559,7 @@ Reference< XPossibleHyphens > SAL_CALL
 
 // replace typographical apostroph by ascii apostroph
 OUString aSingleQuote( GetLocaleDataWrapper( nLanguage 
).getQuotationMarkEnd() );
-DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpectend length of 
quotation mark" );
+DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpected length of 
quotation mark" );
 if (!aSingleQuote.isEmpty())
 aChkWord = aChkWord.replace( aSingleQuote[0], '\'' );
 
diff --git a/linguistic/source/hyphdta.cxx b/linguistic/source/hyphdta.cxx
index 278eaa0d279f..3996fc5fb994 100644
--- a/linguistic/source/hyphdta.cxx
+++ b/linguistic/source/hyphdta.cxx
@@ -49,7 +49,7 @@ HyphenatedWord::HyphenatedWord(const OUString &rWord, 
LanguageType nLang, sal_In
 nLanguage   (nLang)
 {
 OUString aSingleQuote( GetLocaleDataWrapper( nLanguage 
).getQuotationMarkEnd() );
-DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpectend length of 
quotation mark" );
+DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpected length of quotation 
mark" );
 if (!aSingleQuote.isEmpty())
 {
 // ignore typographical apostrophes (which got replaced in original
diff --git a/linguistic/source/spelldsp.cxx b/linguistic/source/spelldsp.cxx
index 3103d1c7ef1c..522ee43a96e5 100644
--- a/linguistic/source/spelldsp.cxx
+++ b/linguistic/source/spelldsp.cxx
@@ -285,7 +285,7 @@ bool SpellCheckerDispatcher::isValid_Impl(
 
 // replace typographical apostroph by ascii apostroph
 OUString aSingleQuote( GetLocaleDataWrapper( nLanguage 
).getQuotationMarkEnd() );
-DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpectend length of 
quotation mark" );
+DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpected length of 
quotation mark" );
 if (!aSingleQuote.isEmpty())
 aChkWord = aChkWord.replace( aSingleQuote[0], '\'' );
 
@@ -448,7 +448,7 @@ Reference< XSpellAlternatives > 
SpellCheckerDispatcher::spell_Impl(
 
 // replace typographical apostroph by ascii apostroph
 OUString aSingleQuote( GetLocaleDataWrapper( nLanguage 
).getQuotationMarkEnd() );
-DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpectend length of 
quotation mark" );
+DBG_ASSERT( 1 == aSingleQuote.getLength(), "unexpected length of 
quotation mark" );
 if (!aSingleQuote.isEmpty())
 aChkWord = aChkWord.replace( aSingleQuote[0], '\'' );
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: compilerplugins/clang

2019-03-05 Thread Libreoffice Gerrit user
 compilerplugins/clang/typedefparam.cxx |8 
 1 file changed, 8 deletions(-)

New commits:
commit d8f5b8e622f08f1ede5d2287ed5be7fae5724ff9
Author: Stephan Bergmann 
AuthorDate: Tue Mar 5 21:53:47 2019 +0100
Commit: Noel Grandin 
CommitDate: Wed Mar 6 06:48:05 2019 +0100

Remove debugging dump()s

Change-Id: I1f5479adefbf7c77a5584d698c6a6c35ff4716d0
Reviewed-on: https://gerrit.libreoffice.org/68778
Reviewed-by: Noel Grandin 
Tested-by: Noel Grandin 

diff --git a/compilerplugins/clang/typedefparam.cxx 
b/compilerplugins/clang/typedefparam.cxx
index b3fa70f97532..8c96aa62576e 100644
--- a/compilerplugins/clang/typedefparam.cxx
+++ b/compilerplugins/clang/typedefparam.cxx
@@ -62,8 +62,6 @@ bool TypedefParam::VisitFunctionDecl(FunctionDecl const* 
functionDecl)
 report(DiagnosticsEngine::Note, "declaration site here",
compat::getBeginLoc(canonicalDecl))
 << canonicalDecl->getSourceRange();
-thisParam->getType()->dump();
-canonicalParam->getType()->dump();
 }
 }
 
@@ -77,8 +75,6 @@ bool TypedefParam::VisitFunctionDecl(FunctionDecl const* 
functionDecl)
 << functionDecl->getSourceRange();
 report(DiagnosticsEngine::Note, "declaration site here", 
compat::getBeginLoc(canonicalDecl))
 << canonicalDecl->getSourceRange();
-functionDecl->getReturnType()->dump();
-canonicalDecl->getReturnType()->dump();
 }
 return true;
 }
@@ -122,8 +118,6 @@ bool TypedefParam::VisitCXXMethodDecl(CXXMethodDecl const* 
methodDecl)
 report(DiagnosticsEngine::Note, "super-class method here",
compat::getBeginLoc(superMethodDecl))
 << superMethodDecl->getSourceRange();
-parmVarDecl->getType()->dump();
-superParmVarDecl->getType()->dump();
 }
 ++i;
 }
@@ -142,8 +136,6 @@ bool TypedefParam::VisitCXXMethodDecl(CXXMethodDecl const* 
methodDecl)
 report(DiagnosticsEngine::Note, "super-class method here",
compat::getBeginLoc(superMethodDecl))
 << superMethodDecl->getSourceRange();
-returnType->dump();
-superMethodDecl->getReturnType()->dump();
 }
 }
 return true;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: basic/source dbaccess/source desktop/source filter/source i18npool/source pyuno/source sc/source sfx2/source shell/source svl/source vcl/osx vcl/source vcl/unx writerpe

2019-03-05 Thread Libreoffice Gerrit user
 basic/source/comp/exprgen.cxx |4 -
 dbaccess/source/core/dataaccess/datasource.cxx|4 -
 desktop/source/lib/init.cxx   |4 -
 filter/source/graphicfilter/ipsd/ipsd.cxx |5 --
 i18npool/source/nativenumber/nativenumbersupplier.cxx |4 -
 i18npool/source/textconversion/genconv_dict.cxx   |4 -
 i18npool/source/textconversion/textconversion_ko.cxx  |4 -
 pyuno/source/module/pyuno_callable.cxx|8 +--
 sc/source/core/tool/interpr1.cxx  |4 -
 sfx2/source/dialog/filtergrouping.cxx |4 -
 shell/source/backends/wininetbe/wininetbackend.cxx|4 -
 svl/source/crypto/cryptosign.cxx  |   20 
 vcl/osx/saldata.cxx   |4 -
 vcl/source/fontsubset/sft.cxx |   16 +++---
 vcl/source/fontsubset/ttcr.cxx|   24 +-
 vcl/unx/generic/app/i18n_keysym.cxx   |   43 --
 vcl/unx/generic/app/saldisp.cxx   |4 -
 vcl/unx/generic/fontmanager/fontmanager.cxx   |4 -
 vcl/unx/gtk/a11y/atkhypertext.cxx |4 -
 vcl/unx/gtk/hudawareness.cxx  |4 -
 writerperfect/source/common/WPXSvInputStream.cxx  |   42 ++---
 xmloff/source/xforms/xformsexport.cxx |4 -
 22 files changed, 103 insertions(+), 115 deletions(-)

New commits:
commit 83db9afa20b8cf54b522ca9c3f04e7e267684c59
Author: Noel Grandin 
AuthorDate: Tue Mar 5 16:11:51 2019 +0200
Commit: Noel Grandin 
CommitDate: Wed Mar 6 06:47:21 2019 +0100

remove some unnecessary typedef struct... sugar

Change-Id: I1576282b0a0a3af8ae14c04725d9c4900073f2c4
Reviewed-on: https://gerrit.libreoffice.org/68758
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/basic/source/comp/exprgen.cxx b/basic/source/comp/exprgen.cxx
index 4cf496b2f966..a00bfc0f6945 100644
--- a/basic/source/comp/exprgen.cxx
+++ b/basic/source/comp/exprgen.cxx
@@ -24,10 +24,10 @@
 
 // Transform table for token operators and opcodes
 
-typedef struct {
+struct OpTable {
 SbiToken  eTok; // Token
 SbiOpcode eOp;  // Opcode
-} OpTable;
+};
 
 static const OpTable aOpTable [] = {
 { EXPON,SbiOpcode::EXP_ },
diff --git a/dbaccess/source/core/dataaccess/datasource.cxx 
b/dbaccess/source/core/dataaccess/datasource.cxx
index 6dd3a3fbd1e8..ead7061ab4b8 100644
--- a/dbaccess/source/core/dataaccess/datasource.cxx
+++ b/dbaccess/source/core/dataaccess/datasource.cxx
@@ -272,11 +272,11 @@ class OSharedConnectionManager : public 
::cppu::WeakImplHelper< XEventListener >
 {
 
  // contains the currently used master connections
-typedef struct
+struct TConnectionHolder
 {
 Reference< XConnection >xMasterConnection;
 oslInterlockedCount nALiveCount;
-} TConnectionHolder;
+};
 
 // the less-compare functor, used for the stl::map
 struct TDigestLess
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index f7380fcad4d8..a24a12c99647 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -154,11 +154,11 @@ static LibLibreOffice_Impl *gImpl = nullptr;
 static std::weak_ptr< LibreOfficeKitClass > gOfficeClass;
 static std::weak_ptr< LibreOfficeKitDocumentClass > gDocumentClass;
 
-typedef struct
+struct ExtensionMap
 {
 const char *extn;
 const char *filterName;
-} ExtensionMap;
+};
 
 static const ExtensionMap aWriterExtensionMap[] =
 {
diff --git a/filter/source/graphicfilter/ipsd/ipsd.cxx 
b/filter/source/graphicfilter/ipsd/ipsd.cxx
index c055b1c20925..a404e6f63b45 100644
--- a/filter/source/graphicfilter/ipsd/ipsd.cxx
+++ b/filter/source/graphicfilter/ipsd/ipsd.cxx
@@ -40,7 +40,7 @@ class FilterConfigItem;
 #define PSD_DUOTONE 8
 #define PSD_LAB 9
 
-typedef struct
+struct PSDFileHeader
 {
 sal_uInt32  nSignature;
 sal_uInt16  nVersion;
@@ -51,8 +51,7 @@ typedef struct
 sal_uInt32  nColumns;
 sal_uInt16  nDepth;
 sal_uInt16  nMode;
-
-} PSDFileHeader;
+};
 
 class PSDReader {
 
diff --git a/i18npool/source/nativenumber/nativenumbersupplier.cxx 
b/i18npool/source/nativenumber/nativenumbersupplier.cxx
index 80fd575e115d..38ae3e116933 100644
--- a/i18npool/source/nativenumber/nativenumbersupplier.cxx
+++ b/i18npool/source/nativenumber/nativenumbersupplier.cxx
@@ -36,13 +36,13 @@ using namespace ::com::sun::star::uno;
 using namespace ::com::sun::star::i18n;
 using namespace ::com::sun::star::lang;
 
-typedef struct {
+struct Number {
 sal_Int16 number;
 const sal_Unicode *multiplierChar;
 sal_Int16 numberFlag;
 sal_Int16 exponentCount;
 const sal_Int16 *multiplierExponent;
-} Number;
+};
 
 
 #define NUMBER_OMIT_ZERO (1 << 0)
diff --git a/i18npool/source/textconversion/genconv

[Libreoffice-commits] core.git: 2 commits - canvas/source compilerplugins/clang connectivity/source cui/source dbaccess/source editeng/source extensions/source filter/source framework/source hwpfilter

2019-03-05 Thread Libreoffice Gerrit user
 canvas/source/tools/page.hxx|4 
 compilerplugins/clang/test/unnecessaryparen.cxx |   11 ++
 compilerplugins/clang/unnecessaryparen.cxx  |8 +
 connectivity/source/drivers/firebird/Connection.cxx |2 
 cui/source/options/optfltr.cxx  |   78 
 cui/source/options/optfltr.hxx  |9 +
 dbaccess/source/ui/querydesign/querycontroller.cxx  |2 
 editeng/source/editeng/impedit3.cxx |4 
 extensions/source/update/ui/updatecheckui.cxx   |2 
 filter/source/graphicfilter/icgm/bitmap.cxx |2 
 framework/source/services/autorecovery.cxx  |   10 --
 framework/source/xml/acceleratorconfigurationreader.cxx |5 -
 hwpfilter/source/hiodev.cxx |   12 +-
 reportdesign/source/ui/report/ReportController.cxx  |4 
 sal/osl/unx/file.cxx|2 
 sal/qa/osl/module/osl_Module.cxx|8 -
 sc/source/core/opencl/formulagroupcl.cxx|2 
 sc/source/ui/dbgui/tpsubt.cxx   |4 
 sc/source/ui/vba/vbarange.cxx   |2 
 sc/source/ui/view/output3.cxx   |8 -
 sd/source/filter/html/htmlex.cxx|2 
 sfx2/source/control/thumbnailview.cxx   |2 
 sfx2/source/dialog/titledockwin.cxx |2 
 starmath/source/dialog.cxx  |4 
 starmath/source/mathtype.cxx|6 -
 svl/source/items/itemset.cxx|2 
 svtools/source/contnr/imivctl1.cxx  |4 
 svx/source/dialog/pagectrl.cxx  |4 
 svx/source/svdraw/svdhdl.cxx|2 
 svx/source/svdraw/svdmrkv.cxx   |4 
 sw/source/core/crsr/crsrsh.cxx  |4 
 sw/source/core/fields/expfld.cxx|2 
 sw/source/core/text/porfld.cxx  |2 
 sw/source/core/txtnode/fmtatr2.cxx  |2 
 sw/source/core/txtnode/txatritr.cxx |2 
 sw/source/core/txtnode/txtedt.cxx   |2 
 sw/source/core/undo/unmove.cxx  |4 
 sw/source/core/unocore/unoidx.cxx   |6 -
 sw/source/core/unocore/unoobj2.cxx  |2 
 sw/source/core/unocore/unosect.cxx  |   12 +-
 sw/source/core/unocore/unosett.cxx  |2 
 sw/source/core/view/pagepreviewlayout.cxx   |4 
 sw/source/filter/ww8/ww8par2.cxx|4 
 sw/source/filter/ww8/ww8scan.cxx|6 -
 sw/source/filter/ww8/ww8scan.hxx|2 
 sw/source/filter/xml/xmltbli.cxx|2 
 sw/source/ui/misc/docfnote.cxx  |2 
 sw/source/uibase/app/docsh.cxx  |2 
 sw/source/uibase/docvw/AnnotationWin2.cxx   |2 
 tools/source/zcodec/zcodec.cxx  |2 
 vcl/qt5/Qt5Frame.cxx|4 
 vcl/source/control/imp_listbox.cxx  |2 
 vcl/source/filter/ixpm/xpmread.cxx  |2 
 vcl/source/gdi/sallayout.cxx|4 
 vcl/source/treelist/headbar.cxx |4 
 vcl/source/treelist/svimpbox.cxx|4 
 vcl/source/treelist/transfer.cxx|2 
 vcl/source/window/dockmgr.cxx   |8 -
 vcl/source/window/dockwin.cxx   |8 -
 vcl/source/window/menufloatingwindow.cxx|2 
 vcl/source/window/mouse.cxx |4 
 vcl/source/window/splitwin.cxx  |   16 +--
 vcl/unx/generic/app/saldisp.cxx |4 
 xmloff/source/core/xmlcnimp.cxx |2 
 64 files changed, 178 insertions(+), 165 deletions(-)

New commits:
commit a2e3705d8b3b05ae664d54b762d6ff72927d5e48
Author: Noel Grandin 
AuthorDate: Tue Mar 5 13:44:17 2019 +0200
Commit: Noel Grandin 
CommitDate: Wed Mar 6 06:47:06 2019 +0100

loplugin:unnecessaryparen improve member expression

Change-Id: I304621018cb1e2a47e478e86df4229bcf2176741
Reviewed-on: https://gerrit.libreoffice.org/68757
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/canvas/source/tools/page.hxx b/canvas/source/tools/page.hxx
index d063c7a0f716..800a294a9433 100644
--- a/canvas/source/tools/page.hxx
+++ b/canvas/source/tools/page.hxx
@@ -108,7 +108,7 @@ namespace canvas
 // request was made to select this fragment,
 // but this fragment has not b

[Libreoffice-commits] online.git: loleaflet/Makefile.am loleaflet/src

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am|2 --
 loleaflet/src/core/Socket.js |2 +-
 loleaflet/src/map/Map.js |   39 ++-
 3 files changed, 27 insertions(+), 16 deletions(-)

New commits:
commit 31aa763470f9dfc3df5280c2f2fab47c15432afd
Author: Henry Castro 
AuthorDate: Sat Feb 16 18:09:52 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 23:55:39 2019 -0400

loleaflet: remove timeago.min.js

simplify using Date.toLocaleDateString

Change-Id: Ib264cd90edd7ddacb3b944ee7f252648a629ab3f

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index d3e0160e0..953add0c6 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -232,8 +232,6 @@ NODE_MODULES_JS =\
node_modules/jquery-mousewheel/jquery.mousewheel.js \
node_modules/jquery-contextmenu/dist/jquery.contextMenu.js \
node_modules/smartmenus/dist/jquery.smartmenus.js \
-   node_modules/timeago.js/dist/timeago.min.js \
-   node_modules/timeago.js/dist/timeago.locales.min.js \
node_modules/autolinker/dist/Autolinker.js \
node_modules/json-js/json2.js \
node_modules/select2/dist/js/select2.js \
diff --git a/loleaflet/src/core/Socket.js b/loleaflet/src/core/Socket.js
index 68080b9fa..3fe3cb2c7 100644
--- a/loleaflet/src/core/Socket.js
+++ b/loleaflet/src/core/Socket.js
@@ -322,7 +322,7 @@ L.Socket = L.Class.extend({
return;
}
else if (textMsg.startsWith('lastmodtime: ')) {
-   var time = textMsg.substring(textMsg.indexOf(' '));
+   var time = textMsg.substring(textMsg.indexOf(' ') + 1);
this._map.updateModificationIndicator(time);
return;
}
diff --git a/loleaflet/src/map/Map.js b/loleaflet/src/map/Map.js
index 9f7f35af3..b0a5b9da5 100644
--- a/loleaflet/src/map/Map.js
+++ b/loleaflet/src/map/Map.js
@@ -16,7 +16,7 @@ function moveObjectVertically(obj, diff) {
}
 }
 
-/* global timeago closebutton vex $ _ */
+/* global closebutton vex $ _ */
 L.Map = L.Evented.extend({
 
options: {
@@ -312,20 +312,33 @@ L.Map = L.Evented.extend({
},
 
updateModificationIndicator: function(newModificationTime) {
-   this._lastmodtime = newModificationTime;
+   var timeout;
+
+   if (typeof newModificationTime === 'string') {
+   this._lastmodtime = newModificationTime;
+   }
+
+   clearTimeout(this._modTimeout);
+
if (this.lastModIndicator !== null && this.lastModIndicator !== 
undefined) {
-   // Get locale
-   var special = [ 'bn_IN', 'hi_IN', 'id_ID', 'nb_NO', 
'nn_NO', 'pt_BR', 'zh_CN', 'zh_TW'];
-   var locale = String.locale;
-   locale = locale.replace('-', '_');
-   if ($.inArray(locale, special) < 0) {
-   if (locale.indexOf('_') > 0) {
-   locale = locale.substring(0, 
locale.indexOf('_'));
-   }
+   var dateTime = new 
Date(this._lastmodtime.replace(/,.*/, 'Z'));
+   var dateValue = 
dateTime.toLocaleDateString(String.locale,
+   { year: 'numeric', month: 'short', day: 
'numeric', hour: '2-digit', minute: '2-digit' });
+
+   var elapsed = Date.now() - dateTime;
+   if (elapsed < 6) {
+   dateValue = Math.round(elapsed / 1000) + ' ' + 
_('seconds ago');
+   timeout = 6000;
+   } else if (elapsed < 360) {
+   dateValue = Math.round(elapsed / 6) + ' ' + 
_('minutes ago');
+   timeout = 6;
+   }
+
+   this.lastModIndicator.innerHTML = dateValue;
+
+   if (timeout) {
+   this._modTimeout = 
setTimeout(L.bind(this.updateModificationIndicator, this, -1), timeout);
}
-   // Real-time auto update
-   this.lastModIndicator.setAttribute('datetime', 
newModificationTime);
-   timeago().render(this.lastModIndicator, locale);
}
},
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/Makefile.am loleaflet/src

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am|3 +--
 loleaflet/src/core/Socket.js |4 +++-
 2 files changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 1d801b833f76239e0b0f44d285e0dd57498cc9d1
Author: Henry Castro 
AuthorDate: Wed Feb 13 11:04:44 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 23:50:39 2019 -0400

loleaflet: remove jquery.time ago

use Date.toLocaleDateString that returns a string with a language sensitive
representation of the date portion of this date

Change-Id: Id2e207e5b4d0dbc8d82498567c97105052d70b90

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index 697877b67..d3e0160e0 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -232,7 +232,6 @@ NODE_MODULES_JS =\
node_modules/jquery-mousewheel/jquery.mousewheel.js \
node_modules/jquery-contextmenu/dist/jquery.contextMenu.js \
node_modules/smartmenus/dist/jquery.smartmenus.js \
-   node_modules/timeago/jquery.timeago.js \
node_modules/timeago.js/dist/timeago.min.js \
node_modules/timeago.js/dist/timeago.locales.min.js \
node_modules/autolinker/dist/Autolinker.js \
@@ -357,7 +356,7 @@ $(builddir)/dist/bundle.js: $(NODE_MODULES_JS_SRC) \
$(builddir)/build/dist/loleaflet-src.js \
$(srcdir)/js/toolbar.js \
$(srcdir)/js/main.js \
-   --source-map --output $@
+   --output $@
 endif
 
 $(builddir)/dist/loleaflet.html: $(srcdir)/html/loleaflet.html.m4 
$(LOLEAFLET_HTML_DST) \
diff --git a/loleaflet/src/core/Socket.js b/loleaflet/src/core/Socket.js
index 2009418af..68080b9fa 100644
--- a/loleaflet/src/core/Socket.js
+++ b/loleaflet/src/core/Socket.js
@@ -125,7 +125,9 @@ L.Socket = L.Class.extend({
if (parseInt(this._map.options.docParams.access_token_ttl) - 
Date.now() <= 0) {
expirymsg = errorMessages.sessionexpired;
}
-   var timerepr = 
$.timeago(parseInt(this._map.options.docParams.access_token_ttl)).replace(' 
ago', '');
+   var dateTime = new 
Date(parseInt(this._map.options.docParams.access_token_ttl));
+   var dateOptions = { year: 'numeric', month: 'short', day: 
'numeric', hour: '2-digit', minute: '2-digit' };
+   var timerepr = dateTime.toLocaleDateString(String.locale, 
dateOptions);
this._map.fire('warn', {msg: expirymsg.replace('%time', 
timerepr)});
 
// If user still doesn't refresh the session, warn again 
periodically
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/build loleaflet/src

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/build/deps.js  |   24 
 loleaflet/src/geo/crs/CRS.EPSG3395.js|   14 
 loleaflet/src/geo/crs/CRS.EPSG3857.js|   18 
 loleaflet/src/geo/crs/CRS.EPSG4326.js|   10 
 loleaflet/src/geo/crs/CRS.Earth.js   |   21 
 loleaflet/src/geo/projection/Projection.Mercator.js  |   44 -
 loleaflet/src/geo/projection/Projection.SphericalMercator.js |   32 -
 loleaflet/src/layer/GeoJSON.js   |  269 ---
 loleaflet/src/map/ext/Map.Geolocation.js |   92 ---
 9 files changed, 524 deletions(-)

New commits:
commit 83130d1e45b7b5706835c7cb7ee057f0fc34fb9c
Author: Henry Castro 
AuthorDate: Tue Feb 12 14:57:19 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 23:46:29 2019 -0400

loleaflet: remove unused map geolocation code

Change-Id: I14f4ca2bade957f0105f31838efe26601d965943

diff --git a/loleaflet/build/deps.js b/loleaflet/build/deps.js
index a050edf47..933c39c6d 100644
--- a/loleaflet/build/deps.js
+++ b/loleaflet/build/deps.js
@@ -19,25 +19,14 @@ var deps = {
  'geo/LatLng.js',
  'geo/LatLngBounds.js',
  'geo/projection/Projection.LonLat.js',
- 'geo/projection/Projection.SphericalMercator.js',
  'geo/crs/CRS.js',
  'geo/crs/CRS.Simple.js',
- 'geo/crs/CRS.Earth.js',
- 'geo/crs/CRS.EPSG3857.js',
- 'geo/crs/CRS.EPSG4326.js',
  'map/Map.js',
  'layer/Layer.js'
  ],
desc: 'The core of the library, including OOP, events, DOM 
facilities, basic units, projections (EPSG:3857 and EPSG:4326) and the base Map 
class.'
},
 
-   EPSG3395: {
-   src: ['geo/projection/Projection.Mercator.js',
- 'geo/crs/CRS.EPSG3395.js'],
-   desc: 'EPSG:3395 projection (used by some map providers).',
-   heading: 'Additional projections'
-   },
-
GridLayer: {
src: ['layer/tile/GridLayer.js'],
desc: 'Used as base class for grid-like layers like TileLayer.',
@@ -191,13 +180,6 @@ var deps = {
desc: 'Canvas backend for vector layers.'
},
 
-   GeoJSON: {
-   src: ['layer/GeoJSON.js'],
-   deps: ['Polygon', 'Circle', 'CircleMarker', 'Marker', 
'FeatureGroup'],
-   desc: 'GeoJSON layer, parses the data and adds corresponding 
layers above.'
-   },
-
-
MapDrag: {
src: ['dom/DomEvent.js',
  'dom/Draggable.js',
@@ -462,12 +444,6 @@ var deps = {
desc: 'Smooth zooming animation. Works only on browsers that 
support CSS3 Transitions.'
},
 
-   Geolocation: {
-   src: ['map/ext/Map.Geolocation.js'],
-   desc: 'Adds Map#locate method and related events to make 
geolocation easier.',
-   heading: 'Misc'
-   },
-
AnnotationManager: {
src: ['layer/AnnotationManager.js'],
desc: 'Group Annotations to put on the map.'
diff --git a/loleaflet/src/geo/crs/CRS.EPSG3395.js 
b/loleaflet/src/geo/crs/CRS.EPSG3395.js
deleted file mode 100644
index be1429c7f..0
--- a/loleaflet/src/geo/crs/CRS.EPSG3395.js
+++ /dev/null
@@ -1,14 +0,0 @@
-/* -*- js-indent-level: 8 -*- */
-/*
- * L.CRS.EPSG3857 (World Mercator) CRS implementation.
- */
-
-L.CRS.EPSG3395 = L.extend({}, L.CRS.Earth, {
-   code: 'EPSG:3395',
-   projection: L.Projection.Mercator,
-
-   transformation: (function () {
-   var scale = 0.5 / (Math.PI * L.Projection.Mercator.R);
-   return new L.Transformation(scale, 0.5, -scale, 0.5);
-   }())
-});
diff --git a/loleaflet/src/geo/crs/CRS.EPSG3857.js 
b/loleaflet/src/geo/crs/CRS.EPSG3857.js
deleted file mode 100644
index 3373d6630..0
--- a/loleaflet/src/geo/crs/CRS.EPSG3857.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/* -*- js-indent-level: 8 -*- */
-/*
- * L.CRS.EPSG3857 (Spherical Mercator) is the most common CRS for web mapping 
and is used by Leaflet by default.
- */
-
-L.CRS.EPSG3857 = L.extend({}, L.CRS.Earth, {
-   code: 'EPSG:3857',
-   projection: L.Projection.SphericalMercator,
-
-   transformation: (function () {
-   var scale = 0.5 / (Math.PI * L.Projection.SphericalMercator.R);
-   return new L.Transformation(scale, 0.5, -scale, 0.5);
-   }())
-});
-
-L.CRS.EPSG900913 = L.extend({}, L.CRS.EPSG3857, {
-   code: 'EPSG:900913'
-});
diff --git a/loleaflet/src/geo/crs/CRS.EPSG4326.js 
b/loleaflet/src/geo/crs/CRS.EPSG4326.js
deleted file mode 100644
index 0f90029ac..0
--- a/loleaflet/src/geo/crs/CRS.EPSG4326.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/* -*- js-indent-level: 8 -*- */

[Libreoffice-commits] online.git: loleaflet/js loleaflet/Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am  |4 +---
 loleaflet/js/global.js |8 
 2 files changed, 1 insertion(+), 11 deletions(-)

New commits:
commit e81441f63bb19981fa5a47b0fd251a91a8b98c1f
Author: Henry Castro 
AuthorDate: Tue Feb 12 09:56:45 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 23:42:24 2019 -0400

loleaflet: remove jquery-ui.js

This library is not used, reduce bundle size

Change-Id: I925ed1335a46f78ba74af55582261a86376d7aca

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index 81d8c4614..697877b67 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -212,8 +212,7 @@ LOLEAFLET_CSS =\
$(builddir)/node_modules/vex-js/css/vex-theme-bottom-right-corner.css \
$(builddir)/node_modules/smartmenus/dist/css/sm-core-css.css \
$(builddir)/node_modules/smartmenus/dist/css/sm-simple/sm-simple.css \
-   $(srcdir)/css/menubar.css \
-   $(builddir)/node_modules/jquery-ui/themes/ui-lightness/jquery-ui.css
+   $(srcdir)/css/menubar.css
 
 LOLEAFLET_CSS_DST = $(foreach file,$(LOLEAFLET_CSS),$(builddir)/dist/$(notdir 
$(file)))
 LOLEAFLET_CSS_M4 = $(strip $(foreach file,$(LOLEAFLET_CSS),$(notdir $(file
@@ -232,7 +231,6 @@ NODE_MODULES_JS =\
node_modules/jquery/dist/jquery.js \
node_modules/jquery-mousewheel/jquery.mousewheel.js \
node_modules/jquery-contextmenu/dist/jquery.contextMenu.js \
-   node_modules/jquery-ui/jquery-ui.js \
node_modules/smartmenus/dist/jquery.smartmenus.js \
node_modules/timeago/jquery.timeago.js \
node_modules/timeago.js/dist/timeago.min.js \
diff --git a/loleaflet/js/global.js b/loleaflet/js/global.js
index b6b1c7bd4..ea2933d73 100644
--- a/loleaflet/js/global.js
+++ b/loleaflet/js/global.js
@@ -11,14 +11,6 @@
}
}
 
-   // fix jquery-ui
-   // var jQuery = require('jquery');
-   global.require = function (path) {
-   if (path=='jquery') {
-   return global.jQuery;
-   }
-   };
-
global.getParameterByName = function (name) {
name = name.replace(/[\[]/, '\\[').replace(/[\]]/, '\\]');
var regex = new RegExp('[\\?&]' + name + '=([^&#]*)');
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am |   11 ---
 1 file changed, 4 insertions(+), 7 deletions(-)

New commits:
commit 4a31a3beac9892d98138af8a9446025587293891
Author: Henry Castro 
AuthorDate: Sun Feb 10 20:21:18 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 23:37:27 2019 -0400

loleaflet: fix debug makefile rules

Change-Id: I90f7e1789e631d1a3194316e1c01012326f671ab

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index 4bb13c046..81d8c4614 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -249,12 +249,6 @@ NODE_MODULES_JS_DST = $(patsubst 
%.js,$(builddir)/dist/%.js,$(NODE_MODULES_JS))
 LOLEAFLET_JS = $(strip $(shell NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
-e "try {console.log(require('$(1)').getFiles().join(' '))} catch(e) {}"))
 LOPLUGIN_JS = $(strip $(shell NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
-e "try {console.log(require('$(1)').deps.join(' '))} catch(e) {}"))
 
-PLUGINS_JS =\
-   jquery.mCustomScrollbar.js \
-   w2ui-1.5.rc1.js \
-   toolbar.js \
-   main.js
-
 LOLEAFLET_JS_SRC = $(shell find $(srcdir)/src -name '*.js')
 LOLEAFLET_JS_DST = $(patsubst 
$(srcdir)/src/%.js,$(builddir)/dist/src/%.js,$(LOLEAFLET_JS_SRC))
 
@@ -380,9 +374,12 @@ $(builddir)/dist/loleaflet.html: 
$(srcdir)/html/loleaflet.html.m4 $(LOLEAFLET_HT
-DBUNDLE_CSS="$(abs_builddir)/dist/bundle.css" \
-DGLOBAL_JS="$(abs_builddir)/dist/global.js" \
-DLOLEAFLET_JS="$(subst $(SPACE),$(COMMA),$(NODE_MODULES_JS) \
+   jquery.mCustomScrollbar.js \
+   w2ui-1.5.rc1.js \
$(call LOLEAFLET_JS,$(srcdir)/build/build.js) \
$(patsubst %.js,plugins/path-transform/%.js,$(call 
LOPLUGIN_JS,$(srcdir)/plugins/path-transform/build/deps.js)) \
-   $(PLUGINS_JS))" \
+   toolbar.js \
+   main.js)" \
$(srcdir)/html/loleaflet.html.m4 > $@
 
 node_modules: npm-shrinkwrap.json
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/Makefile.am loleaflet/plugins

2019-03-05 Thread Libreoffice Gerrit user
 dev/null|binary
 loleaflet/Makefile.am   |   21 
 loleaflet/plugins/draw-0.2.4/.gitattributes |   22 
 loleaflet/plugins/draw-0.2.4/.gitignore |  167 
 loleaflet/plugins/draw-0.2.4/BREAKINGCHANGES.md |   54 
 loleaflet/plugins/draw-0.2.4/CHANGELOG.md   |  145 
 loleaflet/plugins/draw-0.2.4/MIT-LICENCE.txt|   20 
 loleaflet/plugins/draw-0.2.4/README.md  |  440 -
 loleaflet/plugins/draw-0.2.4/TODO.md|   62 
 loleaflet/plugins/draw-0.2.4/build/build.html   |  243 
 loleaflet/plugins/draw-0.2.4/build/build.js |   87 
 loleaflet/plugins/draw-0.2.4/build/deps.js  |   78 
 loleaflet/plugins/draw-0.2.4/build/hintrc.js|   40 
 loleaflet/plugins/draw-0.2.4/build/leaflet.draw-include.js  |   43 
 loleaflet/plugins/draw-0.2.4/dist/leaflet.draw.css  |  308 
 loleaflet/plugins/draw-0.2.4/examples/basic.html|  114 
 loleaflet/plugins/draw-0.2.4/examples/edithandlers.html |   67 
 loleaflet/plugins/draw-0.2.4/examples/full.html |   66 
 loleaflet/plugins/draw-0.2.4/examples/libs/leaflet.css  |  478 -
 loleaflet/plugins/draw-0.2.4/package.json   |   39 
 loleaflet/plugins/draw-0.2.4/spec/after.js  |3 
 loleaflet/plugins/draw-0.2.4/spec/before.js |4 
 loleaflet/plugins/draw-0.2.4/spec/expect.js | 1254 --
 loleaflet/plugins/draw-0.2.4/spec/happen.js |   94 
 loleaflet/plugins/draw-0.2.4/spec/karma.conf.js |   73 
 loleaflet/plugins/draw-0.2.4/spec/sinon.js  | 4224 
--
 loleaflet/plugins/draw-0.2.4/spec/spec.hintrc.js|   26 
 loleaflet/plugins/draw-0.2.4/spec/suites/DrawControlSpec.js |   15 
 loleaflet/plugins/draw-0.2.4/spec/suites/EditSpec.js|   72 
 loleaflet/plugins/draw-0.2.4/spec/suites/GeometryUtilSpec.js|   26 
 loleaflet/plugins/draw-0.2.4/spec/suites/LatLngUtilSpec.js  |   12 
 loleaflet/plugins/draw-0.2.4/spec/suites/SpecHelper.js  |   29 
 loleaflet/plugins/draw-0.2.4/src/Control.Draw.js|  105 
 loleaflet/plugins/draw-0.2.4/src/Leaflet.draw.js|  103 
 loleaflet/plugins/draw-0.2.4/src/Toolbar.js |  245 
 loleaflet/plugins/draw-0.2.4/src/Tooltip.js |   64 
 loleaflet/plugins/draw-0.2.4/src/copyright.js   |9 
 loleaflet/plugins/draw-0.2.4/src/draw/DrawToolbar.js|   88 
 loleaflet/plugins/draw-0.2.4/src/draw/handler/Draw.Circle.js|   64 
 loleaflet/plugins/draw-0.2.4/src/draw/handler/Draw.Feature.js   |   79 
 loleaflet/plugins/draw-0.2.4/src/draw/handler/Draw.Marker.js|  103 
 loleaflet/plugins/draw-0.2.4/src/draw/handler/Draw.Polygon.js   |  104 
 loleaflet/plugins/draw-0.2.4/src/draw/handler/Draw.Polyline.js  |  434 -
 loleaflet/plugins/draw-0.2.4/src/draw/handler/Draw.Rectangle.js |   60 
 loleaflet/plugins/draw-0.2.4/src/draw/handler/Draw.SimpleShape.js   |   95 
 loleaflet/plugins/draw-0.2.4/src/edit/EditToolbar.js|  166 
 loleaflet/plugins/draw-0.2.4/src/edit/handler/Edit.Circle.js|   64 
 loleaflet/plugins/draw-0.2.4/src/edit/handler/Edit.Marker.js|   75 
 loleaflet/plugins/draw-0.2.4/src/edit/handler/Edit.Poly.js  |  285 
 loleaflet/plugins/draw-0.2.4/src/edit/handler/Edit.Rectangle.js |  126 
 loleaflet/plugins/draw-0.2.4/src/edit/handler/EditToolbar.Delete.js |  134 
 loleaflet/plugins/draw-0.2.4/src/edit/handler/EditToolbar.Edit.js   |  184 
 loleaflet/plugins/draw-0.2.4/src/ext/GeometryUtil.js|   69 
 loleaflet/plugins/draw-0.2.4/src/ext/LatLngUtil.js  |   19 
 loleaflet/plugins/draw-0.2.4/src/ext/LineUtil.Intersect.js  |   16 
 loleaflet/plugins/draw-0.2.4/src/ext/Polygon.Intersect.js   |   28 
 loleaflet/plugins/draw-0.2.4/src/ext/Polyline.Intersect.js  |   86 
 loleaflet/plugins/draw-0.2.4/src/images/spritesheet.svg |   41 
 58 files changed, 2 insertions(+), 11170 deletions(-)

New commits:
commit 3d91ea94a90fa47b3aea38fe4b8f8fc5cee1
Author: Henry Castro 
AuthorDate: Sun Feb 10 19:53:57 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 23:20:24 2019 -0400

loleaflet: remove unused draw plugin

Change-Id: I6acdec7a5e04ba9cd370b80a3a04b54d370420a0

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index 31df8f092..4bb13c046 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -1,5 +

[Libreoffice-commits] online.git: loleaflet/html loleaflet/js loleaflet/Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am|   23 ---
 loleaflet/html/loleaflet.html.m4 |9 -
 loleaflet/js/l10n.js |  291 ---
 3 files changed, 323 deletions(-)

New commits:
commit c9685387b9fb639ab9d31fa0619cb0beab430e8a
Author: Henry Castro 
AuthorDate: Sun Feb 10 19:02:56 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 22:38:13 2019 -0400

loleaflet: remove client side L10n

Change-Id: I4bd40e569441c22b902b5bac2cb21705a4565384

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index e220dbd62..31df8f092 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -164,11 +164,6 @@ JQUERY_MINIFIED_DIST_IMAGES = $(patsubst 
$(JQUERY_MINIFIED_IMAGE_PATH)/%.png,$(b
 LOLEAFLET_IMAGES_SRC = $(shell find $(srcdir)/images -name '*.*')
 LOLEAFLET_IMAGES_DST = $(patsubst 
$(srcdir)/%,$(builddir)/dist/%,$(LOLEAFLET_IMAGES_SRC))
 
-LOLEAFLET_L10N_SRC = $(shell find $(srcdir)/l10n -name '*.*')
-if !ENABLE_IOSAPP
-LOLEAFLET_L10N_DST =  $(patsubst 
$(srcdir)/l10n/%,$(builddir)/dist/l10n/%,$(LOLEAFLET_L10N_SRC))
-endif
-
 LOLEAFLET_DRAW_JS_SRC = $(shell find 
$(srcdir)/plugins/draw-$(DRAW_VERSION)/src -name '*.js')
 LOLEAFLET_DRAW_JS_DST = $(patsubst 
$(srcdir)/plugins/%.js,$(builddir)/dist/plugins/%.js,$(LOLEAFLET_DRAW_JS_SRC))
 
@@ -256,11 +251,6 @@ NODE_MODULES_JS =\
node_modules/vex-js/js/vex.js \
node_modules/vex-js/js/vex.dialog.js
 
-if !ENABLE_MOBILEAPP
-NODE_MODULES_JS +=\
-   node_modules/l10n-for-node/l10n.js
-endif
-
 NODE_MODULES_JS_SRC = $(patsubst %.js,$(builddir)/%.js,$(NODE_MODULES_JS))
 NODE_MODULES_JS_DST = $(patsubst %.js,$(builddir)/dist/%.js,$(NODE_MODULES_JS))
 
@@ -345,7 +335,6 @@ $(builddir)/dist/bundle.css: $(LOLEAFLET_CSS_DST)
 $(builddir)/dist/bundle.js: $(NODE_MODULES_JS_DST) \
$(LOLEAFLET_PREFIX)/dist/loleaflet-src.js \
$(builddir)/dist/global.js \
-   $(builddir)/dist/l10n.js \
$(builddir)/dist/w2ui-1.5.rc1.js \
$(builddir)/dist/toolbar.js \
$(builddir)/dist/main.js
@@ -374,22 +363,15 @@ $(builddir)/dist/global.js: $(srcdir)/js/global.js
@echo "Uglify global.js file..."
@NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
node_modules/uglify-js/bin/uglifyjs $< --output $@
 
-$(builddir)/dist/l10n.js: $(srcdir)/js/l10n.js
-   @echo "Uglify l10n.js file..."
-   @NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
node_modules/uglify-js/bin/uglifyjs $< --output $@
-
 $(builddir)/dist/bundle.js: $(NODE_MODULES_JS_SRC) \
$(LOLEAFLET_PREFIX)/dist/loleaflet-src.js \
$(builddir)/dist/global.js \
-   $(builddir)/dist/l10n.js \
$(srcdir)/js/jquery.mCustomScrollbar.js \
$(srcdir)/js/w2ui-1.5.rc1.js \
$(srcdir)/js/toolbar.js \
$(srcdir)/js/main.js
@echo "Uglify loleaflet js files..."
NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
node_modules/uglify-js/bin/uglifyjs \
-   $(srcdir)/js/global.js \
-   $(L10N_IOS_ALL_JS) \
$(NODE_MODULES_JS) \
$(srcdir)/js/jquery.mCustomScrollbar.js \
$(srcdir)/js/w2ui-1.5.rc1.js \
@@ -410,11 +392,6 @@ $(builddir)/dist/loleaflet.html: 
$(srcdir)/html/loleaflet.html.m4 $(LOLEAFLET_HT
-DLOLEAFLET_CSS="$(subst 
$(SPACE),$(COMMA),$(LOLEAFLET_CSS_M4))" \
-DBUNDLE_CSS="$(abs_builddir)/dist/bundle.css" \
-DGLOBAL_JS="$(abs_builddir)/dist/global.js" \
-   -DL10N_JS="$(abs_builddir)/dist/l10n.js" \
-   
-DLOCALIZATION_JSON="$(abs_builddir)/dist/l10n/localizations.json" \
-   
-DLOCORE_LOCALIZATION_JSON="$(abs_builddir)/dist/l10n/locore-localizations.json"
 \
-   
-DHELP_LOCALIZATION_JSON="$(abs_builddir)/dist/l10n/help-localizations.json" \
-   
-DUNO_LOCALIZATION_JSON="$(abs_builddir)/dist/l10n/uno-localizations.json" \
-DLOLEAFLET_JS="$(subst $(SPACE),$(COMMA),$(NODE_MODULES_JS) \
$(call LOLEAFLET_JS,$(srcdir)/build/build.js) \
$(patsubst %.js,plugins/draw-$(DRAW_VERSION)/%.js,$(call 
LOLEAFLET_JS,$(srcdir)/plugins/draw-$(DRAW_VERSION)/build/build.js)) \
diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index 7083857e3..270db259e 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -30,10 +30,6 @@ ifelse(MOBILEAPP,[],
 }
   };
   window.addEventListener('message', PostMessageReadyListener, false);
-  window.__globalL10n = syscmd([cat ]LOCALIZATION_JSON);
-  window.__locoreL10n = syscmd([cat ]LOCORE_LOCALIZATION_JSON);
-  window.__helpL10n = syscmd([cat ]HELP_LOCALIZATION_JSON);
-  window.__unoL10n = syscmd([cat ]UNO_LOCALIZATION_JSON);
 ])dnl
 
 var Base64ToArrayBuffer = function(base64Str) {
@@ -165,11 +161,6 @@ ifelse(MOBILEAPP,[true],
   window.idleTimeoutSecs = <%IDLE_TIMEOUT_SECS%>;
   window.tileSize = 256;])
 syscmd([cat ]GLOBAL_JS)dnl
-sys

[Libreoffice-commits] online.git: loleaflet/js

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/js/global.js |8 
 1 file changed, 8 insertions(+)

New commits:
commit 304852ccd5ad8086d43728c830534eb53ac191dc
Author: Henry Castro 
AuthorDate: Sun Feb 10 19:15:25 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 22:05:51 2019 -0400

loleaflet: fix String.locale assignment

Change-Id: I901f635ef2cb176329ef8e836a5314efabbc026b

diff --git a/loleaflet/js/global.js b/loleaflet/js/global.js
index d384409f0..b6b1c7bd4 100644
--- a/loleaflet/js/global.js
+++ b/loleaflet/js/global.js
@@ -26,6 +26,14 @@
return results === null ? '' : results[1].replace(/\+/g, ' ');
};
 
+   var lang = self.getParameterByName('lang');
+   if (lang) {
+   String.locale = lang;
+   }
+   else {
+   String.locale = 'en';
+   }
+
global._ = function (string) {
// In the mobile app case we can't use the stuff from 
l10n-for-node, as that assumes HTTP.
if (window.ThisIsTheiOSApp) {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 qadevOOo/objdsc/sc/com.sun.star.comp.office.ScDataPilotFieldObj.csv |2 --
 sc/qa/extras/scdatapilotfieldobj.cxx|9 
-
 2 files changed, 8 insertions(+), 3 deletions(-)

New commits:
commit 04f4cbd0b3e949c28382359f722872d380d98900
Author: Jens Carl 
AuthorDate: Tue Mar 5 21:20:03 2019 +
Commit: Jens Carl 
CommitDate: Wed Mar 6 03:04:36 2019 +0100

tdf#45904 Move XNamed Java tests to C++

Move XNamed Java tests to C++ for ScDataPilotFieldObj.

Change-Id: Ieecd8799f56dcfa9279d4d523d470a62d9aed203
Reviewed-on: https://gerrit.libreoffice.org/68781
Tested-by: Jenkins
Reviewed-by: Jens Carl 

diff --git 
a/qadevOOo/objdsc/sc/com.sun.star.comp.office.ScDataPilotFieldObj.csv 
b/qadevOOo/objdsc/sc/com.sun.star.comp.office.ScDataPilotFieldObj.csv
index de2cb74f71ba..17d800db4639 100644
--- a/qadevOOo/objdsc/sc/com.sun.star.comp.office.ScDataPilotFieldObj.csv
+++ b/qadevOOo/objdsc/sc/com.sun.star.comp.office.ScDataPilotFieldObj.csv
@@ -1,5 +1,3 @@
-"ScDataPilotFieldObj";"com::sun::star::container::XNamed";"getName()"
-"ScDataPilotFieldObj";"com::sun::star::container::XNamed";"setName()"
 
"ScDataPilotFieldObj";"com::sun::star::beans::XPropertySet";"getPropertySetInfo()"
 
"ScDataPilotFieldObj";"com::sun::star::beans::XPropertySet";"setPropertyValue()"
 
"ScDataPilotFieldObj";"com::sun::star::beans::XPropertySet";"getPropertyValue()"
diff --git a/sc/qa/extras/scdatapilotfieldobj.cxx 
b/sc/qa/extras/scdatapilotfieldobj.cxx
index 61a3d45c8008..46cd9a703b76 100644
--- a/sc/qa/extras/scdatapilotfieldobj.cxx
+++ b/sc/qa/extras/scdatapilotfieldobj.cxx
@@ -8,6 +8,7 @@
  */
 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -29,7 +30,8 @@ namespace sc_apitest
 class ScDataPilotFieldObj : public CalcUnoApiTest,
 public apitest::DataPilotField,
 public apitest::XDataPilotField,
-public apitest::XDataPilotFieldGrouping
+public apitest::XDataPilotFieldGrouping,
+public apitest::XNamed
 {
 public:
 virtual void setUp() override;
@@ -55,6 +57,10 @@ public:
 // see fdo#
 //CPPUNIT_TEST(testCreateDateGroup);
 
+// XNamed
+CPPUNIT_TEST(testGetName);
+CPPUNIT_TEST(testSetName);
+
 CPPUNIT_TEST_SUITE_END();
 
 private:
@@ -63,6 +69,7 @@ private:
 
 ScDataPilotFieldObj::ScDataPilotFieldObj()
 : CalcUnoApiTest("/sc/qa/extras/testdocuments")
+, XNamed("Col1")
 {
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: framework/qa qadevOOo/Jar_OOoRunner.mk qadevOOo/objdsc qadevOOo/tests sc/qa

2019-03-05 Thread Libreoffice Gerrit user
 framework/qa/complex/api_internal/api.lst   |1 
 qadevOOo/Jar_OOoRunner.mk   |1 
 qadevOOo/objdsc/sc/com.sun.star.comp.office.ScDataPilotFieldObj.csv |7 
 qadevOOo/tests/java/mod/_sc/ScDataPilotFieldObj.java|  314 
--
 sc/qa/extras/scdatapilotfieldobj.cxx|   13 
 sc/qa/unoapi/sc_1.sce   |1 
 6 files changed, 12 insertions(+), 325 deletions(-)

New commits:
commit da474e2985e8672c63e9282576bac6750ae6648c
Author: Jens Carl 
AuthorDate: Tue Mar 5 21:44:25 2019 +
Commit: Jens Carl 
CommitDate: Wed Mar 6 03:04:51 2019 +0100

tdf#45904 Move XPropertySet Java tests to C++

Move XPropertySet Java tests to C++ for ScDataPilotFieldObj.

Change-Id: I9fa5d153cced1aae8892d2422025dfcdcda73c69
Reviewed-on: https://gerrit.libreoffice.org/68782
Tested-by: Jenkins
Reviewed-by: Jens Carl 

diff --git a/framework/qa/complex/api_internal/api.lst 
b/framework/qa/complex/api_internal/api.lst
index d31c465d5559..2340ff4fc6bb 100644
--- a/framework/qa/complex/api_internal/api.lst
+++ b/framework/qa/complex/api_internal/api.lst
@@ -77,7 +77,6 @@ job80=sc.ScAutoFormatsObj
 job81=sc.ScCellFieldObj
 job85=sc.ScCellSearchObj
 job88=sc.ScDatabaseRangeObj
-job90=sc.ScDataPilotFieldObj
 job98=sc.ScHeaderFieldObj
 job99=sc.ScHeaderFieldsObj
 job126=sc.ScSheetLinkObj
diff --git a/qadevOOo/Jar_OOoRunner.mk b/qadevOOo/Jar_OOoRunner.mk
index 9a2f09514ed5..2e025ea03057 100644
--- a/qadevOOo/Jar_OOoRunner.mk
+++ b/qadevOOo/Jar_OOoRunner.mk
@@ -964,7 +964,6 @@ $(eval $(call gb_Jar_add_sourcefiles,OOoRunner,\
 qadevOOo/tests/java/mod/_sc/ScChartsObj \
 qadevOOo/tests/java/mod/_sc/ScDatabaseRangeObj \
 qadevOOo/tests/java/mod/_sc/ScDataPilotFieldGroupObj \
-qadevOOo/tests/java/mod/_sc/ScDataPilotFieldObj \
 qadevOOo/tests/java/mod/_sc/ScDataPilotItemObj \
 qadevOOo/tests/java/mod/_sc/ScDocumentConfiguration \
 qadevOOo/tests/java/mod/_sc/ScDrawPageObj \
diff --git 
a/qadevOOo/objdsc/sc/com.sun.star.comp.office.ScDataPilotFieldObj.csv 
b/qadevOOo/objdsc/sc/com.sun.star.comp.office.ScDataPilotFieldObj.csv
deleted file mode 100644
index 17d800db4639..
--- a/qadevOOo/objdsc/sc/com.sun.star.comp.office.ScDataPilotFieldObj.csv
+++ /dev/null
@@ -1,7 +0,0 @@
-"ScDataPilotFieldObj";"com::sun::star::beans::XPropertySet";"getPropertySetInfo()"
-"ScDataPilotFieldObj";"com::sun::star::beans::XPropertySet";"setPropertyValue()"
-"ScDataPilotFieldObj";"com::sun::star::beans::XPropertySet";"getPropertyValue()"
-"ScDataPilotFieldObj";"com::sun::star::beans::XPropertySet";"addPropertyChangeListener()"
-"ScDataPilotFieldObj";"com::sun::star::beans::XPropertySet";"removePropertyChangeListener()"
-"ScDataPilotFieldObj";"com::sun::star::beans::XPropertySet";"addVetoableChangeListener()"
-"ScDataPilotFieldObj";"com::sun::star::beans::XPropertySet";"removeVetoableChangeListener()"
diff --git a/qadevOOo/tests/java/mod/_sc/ScDataPilotFieldObj.java 
b/qadevOOo/tests/java/mod/_sc/ScDataPilotFieldObj.java
deleted file mode 100644
index 043e8798ac69..
--- a/qadevOOo/tests/java/mod/_sc/ScDataPilotFieldObj.java
+++ /dev/null
@@ -1,314 +0,0 @@
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-package mod._sc;
-
-import com.sun.star.beans.XPropertySet;
-import com.sun.star.container.XIndexAccess;
-import com.sun.star.container.XNamed;
-import com.sun.star.lang.XComponent;
-import com.sun.star.sheet.DataPilotFieldOrientation;
-import com.sun.star.sheet.XDataPilotDescriptor;
-import com.sun.star.sheet.XDataPilotTables;
-import com.sun.star.sheet.XDataPilotTablesSupplier;
-import com.sun.star.sheet.XSpreadsheet;
-import com.sun.star.sheet.XSpreadsheetDocument;
-import com.sun.star.sheet.XSpreadsheets;
-import com.sun.star.table.CellAddress;
-import com.sun.star.table.CellRangeAddress;
-import com.sun.star.uno.AnyConverter;
-import com.sun.star.uno.Type;
-import com.sun.star.uno.UnoRuntime;
-import com.sun.star.uno.XInterface;
-
-import java.io.PrintWriter;
-
-import lib.TestCase;
-import lib.TestEnvironment;
-import lib.TestParameters;
-
-impor

LibreOffice Online Build

2019-03-05 Thread ahmed elshreif
hello ,

I built LibreOffice before and make changes on it and built it again and no
problem happened and I left it for 2 days and return to do some changes
again and run this command
>git pull
>make
and I have this error
>>
checking for node... /usr/bin/node
checking whether the Boost::Locale library is available... yes
configure: error: Could not find a version of the library!
>
I try make clean but i have the same error then i check all Dependencies
again and run this command
>./configure --enable-silent-rules
--with-lokit-path=/home/el-shreif/Libre/core/include
--with-lo-path=/home/el-shreif/Libre/core/instdir --enable-debug
--with-poco-includes=/tmp/poco/Net/include --with-poco-libs=/tmp/poco/lib
but also the same error

thanks in advance
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice

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

2019-03-05 Thread Libreoffice Gerrit user
 sc/qa/extras/scdatapilotfieldobj.cxx |   54 +--
 1 file changed, 27 insertions(+), 27 deletions(-)

New commits:
commit 849856596cdc2342fb1672ca313915362eddb589
Author: Jens Carl 
AuthorDate: Tue Mar 5 21:11:19 2019 +
Commit: Jens Carl 
CommitDate: Wed Mar 6 02:29:34 2019 +0100

Remove unnecessary calls to Reference::is() after an UNO_QUERY_THROW

Change-Id: Icb5ab21168e91951a81c09752e7b53e11813aa1b
Reviewed-on: https://gerrit.libreoffice.org/68780
Tested-by: Jenkins
Reviewed-by: Jens Carl 

diff --git a/sc/qa/extras/scdatapilotfieldobj.cxx 
b/sc/qa/extras/scdatapilotfieldobj.cxx
index 1b9ea1a65c42..61a3d45c8008 100644
--- a/sc/qa/extras/scdatapilotfieldobj.cxx
+++ b/sc/qa/extras/scdatapilotfieldobj.cxx
@@ -1,4 +1,4 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
 /*
  * This file is part of the LibreOffice project.
  *
@@ -8,30 +8,33 @@
  */
 
 #include 
-
 #include 
 #include 
 #include 
 
+#include 
 #include 
 #include 
 #include 
 #include 
 #include 
+#include 
 
-using namespace css;
-using namespace css::uno;
+#include 
 
-namespace sc_apitest {
+using namespace css;
 
-class ScDataPilotFieldObj : public CalcUnoApiTest, public 
apitest::DataPilotField,
-   public 
apitest::XDataPilotField,
-   public 
apitest::XDataPilotFieldGrouping
+namespace sc_apitest
+{
+class ScDataPilotFieldObj : public CalcUnoApiTest,
+public apitest::DataPilotField,
+public apitest::XDataPilotField,
+public apitest::XDataPilotFieldGrouping
 {
 public:
 virtual void setUp() override;
 virtual void tearDown() override;
-virtual uno::Reference< uno::XInterface > init() override;
+virtual uno::Reference init() override;
 
 ScDataPilotFieldObj();
 
@@ -55,31 +58,29 @@ public:
 CPPUNIT_TEST_SUITE_END();
 
 private:
-uno::Reference< lang::XComponent > mxComponent;
+uno::Reference mxComponent;
 };
 
 ScDataPilotFieldObj::ScDataPilotFieldObj()
- : CalcUnoApiTest("/sc/qa/extras/testdocuments")
+: CalcUnoApiTest("/sc/qa/extras/testdocuments")
 {
 }
 
-uno::Reference< uno::XInterface > ScDataPilotFieldObj::init()
+uno::Reference ScDataPilotFieldObj::init()
 {
-uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, 
UNO_QUERY_THROW);
+uno::Reference xDoc(mxComponent, 
uno::UNO_QUERY_THROW);
+uno::Reference xIndex(xDoc->getSheets(), 
uno::UNO_QUERY_THROW);
+uno::Reference xSheet(xIndex->getByIndex(1), 
uno::UNO_QUERY_THROW);
 
-uno::Reference< container::XIndexAccess > xIndex (xDoc->getSheets(), 
UNO_QUERY_THROW);
-uno::Reference< sheet::XSpreadsheet > xSheet( xIndex->getByIndex(1), 
UNO_QUERY_THROW);
-
-CPPUNIT_ASSERT_MESSAGE("Could not create interface of type XSpreadsheet", 
xSheet.is());
-uno::Reference< sheet::XDataPilotTablesSupplier > xDPTS(xSheet, 
UNO_QUERY_THROW);
-uno::Reference< sheet::XDataPilotTables > xDPT = 
xDPTS->getDataPilotTables();
-CPPUNIT_ASSERT(xDPT.is());
+uno::Reference xDPTS(xSheet, 
uno::UNO_QUERY_THROW);
+uno::Reference xDPT(xDPTS->getDataPilotTables(), 
uno::UNO_QUERY_THROW);
 uno::Sequence aElementNames = xDPT->getElementNames();
-(void) aElementNames;
+(void)aElementNames;
 
-uno::Reference< sheet::XDataPilotDescriptor > 
xDPDsc(xDPT->getByName("DataPilot1"),UNO_QUERY_THROW);
-uno::Reference< container::XIndexAccess > xIA( 
xDPDsc->getDataPilotFields(), UNO_QUERY_THROW);
-uno::Reference< uno::XInterface > xReturnValue( xIA->getByIndex(0), 
UNO_QUERY_THROW);
+uno::Reference 
xDPDsc(xDPT->getByName("DataPilot1"),
+   uno::UNO_QUERY_THROW);
+uno::Reference xIA(xDPDsc->getDataPilotFields(), 
uno::UNO_QUERY_THROW);
+uno::Reference xReturnValue(xIA->getByIndex(0), 
uno::UNO_QUERY_THROW);
 return xReturnValue;
 }
 
@@ -90,7 +91,6 @@ void ScDataPilotFieldObj::setUp()
 OUString aFileURL;
 createFileURL("scdatapilotfieldobj.ods", aFileURL);
 mxComponent = loadFromDesktop(aFileURL, 
"com.sun.star.sheet.SpreadsheetDocument");
-
 }
 
 void ScDataPilotFieldObj::tearDown()
@@ -101,8 +101,8 @@ void ScDataPilotFieldObj::tearDown()
 
 CPPUNIT_TEST_SUITE_REGISTRATION(ScDataPilotFieldObj);
 
-}
+} // namespace sc_apitest
 
 CPPUNIT_PLUGIN_IMPLEMENT();
 
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: .gitignore

2019-03-05 Thread Libreoffice Gerrit user
 .gitignore |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit ad9e0c7c4fa01e05b61b2cb86072002577168095
Author: Henry Castro 
AuthorDate: Sun Feb 10 19:00:35 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 21:16:08 2019 -0400

ignore generated m4 files

Change-Id: I732287ca2384df1991e04a0b05cd841ca62d7c3f

diff --git a/.gitignore b/.gitignore
index ab93d7460..b6c02e3bd 100644
--- a/.gitignore
+++ b/.gitignore
@@ -50,6 +50,8 @@ cscope*
 loolwsd.log
 *.log.*.gz
 *.lo
+m4/lt*.m4
+m4/libtool.m4
 
 # loleaflet
 loleaflet/dist
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: wsd/FileServer.cpp

2019-03-05 Thread Libreoffice Gerrit user
 wsd/FileServer.cpp |   50 +++---
 1 file changed, 39 insertions(+), 11 deletions(-)

New commits:
commit b879f9dd06afec3275cb820cdc88e776978790f5
Author: Henry Castro 
AuthorDate: Sun Feb 10 18:02:44 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 21:14:04 2019 -0400

wsd: allow compression gzip for html and js resources

Change-Id: I0c6030c91e379cf1d78950516d2b6b8aa6bd018b

diff --git a/wsd/FileServer.cpp b/wsd/FileServer.cpp
index 97509813d..9626daf76 100644
--- a/wsd/FileServer.cpp
+++ b/wsd/FileServer.cpp
@@ -24,6 +24,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -701,8 +702,9 @@ void FileServerRequestHandler::preprocessFile(const 
HTTPRequest& request, Poco::
 documentSigningDiv = "";
 }
 
+std::streampos size;
 std::string lang("en");
-std::ostringstream ostr;
+std::ostringstream ostr, ogzip;
 std::istringstream istr(preprocess);
 
 auto pos = std::find_if(params.begin(), params.end(),
@@ -779,6 +781,16 @@ void FileServerRequestHandler::preprocessFile(const 
HTTPRequest& request, Poco::
 });
 
 const std::string mimeType = "text/html";
+bool gzip = request.hasToken("Accept-Encoding", "gzip");
+if (gzip)
+{
+Poco::DeflatingOutputStream deflater(ogzip, 
Poco::DeflatingStreamBuf::STREAM_GZIP, 8);
+deflater << ostr.str();
+deflater.close();
+size = ogzip.tellp();
+}
+else
+size = ostr.tellp();
 
 std::ostringstream oss;
 oss << "HTTP/1.1 200 OK\r\n"
@@ -795,6 +807,9 @@ void FileServerRequestHandler::preprocessFile(const 
HTTPRequest& request, Poco::
 
 // Document signing: if endpoint URL is configured, whitelist that for
 // iframe purposes.
+if (gzip)
+oss << "Content-Encoding: gzip\r\n";
+
 std::ostringstream cspOss;
 cspOss << "Content-Security-Policy: default-src 'none'; "
<< "frame-src 'self' blob: " << documentSigningURL << "; "
@@ -904,7 +919,7 @@ void FileServerRequestHandler::preprocessFile(const 
HTTPRequest& request, Poco::
 }
 
 oss << "\r\n"
-<< ostr.str();
+<< (gzip ? ogzip.str() : ostr.str());
 
 socket->send(oss.str());
 LOG_DBG("Sent file: " << relPath << ": " << preprocess);
@@ -1061,26 +1076,39 @@ void FileServerRequestHandler::preprocessJS(const 
HTTPRequest& request, const st
 if (pos != params.end())
 lang = pos->second;
 
-response.setContentType("application/javascript");
-response.set("User-Agent", HTTP_AGENT_STRING);
-response.set("Date", Poco::DateTimeFormatter::format(Poco::Timestamp(), 
Poco::DateTimeFormat::HTTP_FORMAT));
-response.add("X-Content-Type-Options", "nosniff");
-
 const std::string relPath = getRequestPathname(request);
 LOG_DBG("Preprocessing file: " << relPath);
 std::string preprocess = *getUncompressedFile(relPath);
 
-std::ostringstream ostr;
+std::streampos size;
+std::ostringstream oss, ostr, ogzip;
 std::istringstream istr(preprocess);
 std::locale locale(LOOLWSD::Generator(lang + ".utf8"));
 
 parse(locale, istr, ostr, [](const std::string&) { return false; });
 
-std::ostringstream oss;
+bool gzip = request.hasToken("Accept-Encoding", "gzip");
+if (gzip)
+{
+response.set("Content-Encoding", "gzip");
+Poco::DeflatingOutputStream deflater(ogzip, 
Poco::DeflatingStreamBuf::STREAM_GZIP, 8);
+deflater << ostr.str();
+deflater.close();
+size = ogzip.tellp();
+}
+else
+size = ostr.tellp();
+
+response.setContentType("application/javascript");
+response.setContentLength(static_cast(size));
+response.setChunkedTransferEncoding(false);
+response.set("User-Agent", HTTP_AGENT_STRING);
+response.set("Date", Poco::DateTimeFormatter::format(Poco::Timestamp(), 
Poco::DateTimeFormat::HTTP_FORMAT));
+response.add("X-Content-Type-Options", "nosniff");
 response.write(oss);
-oss << ostr.str();
-socket->send(oss.str());
 
+oss << (gzip ? ogzip.str() : ostr.str());
+socket->send(oss.str());
 LOG_DBG("Sent file: " << relPath);
 }
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: wsd/FileServer.cpp wsd/FileServer.hpp

2019-03-05 Thread Libreoffice Gerrit user
 wsd/FileServer.cpp |   38 +-
 wsd/FileServer.hpp |1 +
 2 files changed, 38 insertions(+), 1 deletion(-)

New commits:
commit 306b12b9bc2e0808751ea24282be792839d9ca40
Author: Henry Castro 
AuthorDate: Sun Feb 10 17:03:31 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 20:56:46 2019 -0400

wsd: preprocess javascript file for L10n

Change-Id: Ib802beca673e1e90ad5dd9c33cd5191300ae7bf8

diff --git a/wsd/FileServer.cpp b/wsd/FileServer.cpp
index b82becbf1..97509813d 100644
--- a/wsd/FileServer.cpp
+++ b/wsd/FileServer.cpp
@@ -335,7 +335,10 @@ void FileServerRequestHandler::handleRequest(const 
HTTPRequest& request, Poco::M
 const std::string fileType = endPoint.substr(extPoint + 1);
 std::string mimeType;
 if (fileType == "js")
-mimeType = "application/javascript";
+{
+preprocessJS(request, socket);
+return;
+}
 else if (fileType == "css")
 mimeType = "text/css";
 else if (fileType == "html")
@@ -1047,4 +1050,37 @@ void FileServerRequestHandler::parse(const std::locale& 
locale, std::istringstre
 ostr << varL10n.str();
 }
 }
+
+void FileServerRequestHandler::preprocessJS(const HTTPRequest& request, const 
std::shared_ptr& socket)
+{
+std::string lang("en");
+Poco::Net::HTTPResponse response;
+const Poco::URI::QueryParameters params = 
Poco::URI(request.getURI()).getQueryParameters();
+auto pos = std::find_if(params.begin(), params.end(),
+[](const std::pair& it) { return it.first == 
"lang"; });
+if (pos != params.end())
+lang = pos->second;
+
+response.setContentType("application/javascript");
+response.set("User-Agent", HTTP_AGENT_STRING);
+response.set("Date", Poco::DateTimeFormatter::format(Poco::Timestamp(), 
Poco::DateTimeFormat::HTTP_FORMAT));
+response.add("X-Content-Type-Options", "nosniff");
+
+const std::string relPath = getRequestPathname(request);
+LOG_DBG("Preprocessing file: " << relPath);
+std::string preprocess = *getUncompressedFile(relPath);
+
+std::ostringstream ostr;
+std::istringstream istr(preprocess);
+std::locale locale(LOOLWSD::Generator(lang + ".utf8"));
+
+parse(locale, istr, ostr, [](const std::string&) { return false; });
+
+std::ostringstream oss;
+response.write(oss);
+oss << ostr.str();
+socket->send(oss.str());
+
+LOG_DBG("Sent file: " << relPath);
+}
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/wsd/FileServer.hpp b/wsd/FileServer.hpp
index c5a5133cd..df33ca217 100644
--- a/wsd/FileServer.hpp
+++ b/wsd/FileServer.hpp
@@ -22,6 +22,7 @@ class FileServerRequestHandler
 
 static void getToken(std::istringstream&, std::string&);
 static void parse(const std::locale&, std::istringstream&, 
std::ostringstream&, const std::function&);
+static void preprocessJS(const Poco::Net::HTTPRequest& request, const 
std::shared_ptr& socket);
 static void preprocessFile(const Poco::Net::HTTPRequest& request, 
Poco::MemoryInputStream& message, const std::shared_ptr& socket);
 static void preprocessAdminFile(const Poco::Net::HTTPRequest& request, 
const std::shared_ptr& socket);
 public:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - svx/source

2019-03-05 Thread Libreoffice Gerrit user
 svx/source/xml/xmlgrhlp.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 36f027769ea6aaabb5e993a321d7a56775d4bee1
Author: Bartosz Kosiorek 
AuthorDate: Mon Mar 4 23:46:52 2019 +0100
Commit: Bartosz Kosiorek 
CommitDate: Wed Mar 6 01:16:21 2019 +0100

tdf#123452 EMF Re-enable compression for image/x-emf files

Change-Id: I9fd801d5eef6c65f8e68e30723415da7b493d767
Reviewed-on: https://gerrit.libreoffice.org/68716
Tested-by: Jenkins
Reviewed-by: László Németh 
(cherry picked from commit df22e97db5b7608b6d53b15b86b5a83610f9c87b)
Reviewed-on: https://gerrit.libreoffice.org/68729
Reviewed-by: Bartosz Kosiorek 

diff --git a/svx/source/xml/xmlgrhlp.cxx b/svx/source/xml/xmlgrhlp.cxx
index 3a4dc4a4493f..4e99e87b21a5 100644
--- a/svx/source/xml/xmlgrhlp.cxx
+++ b/svx/source/xml/xmlgrhlp.cxx
@@ -731,6 +731,7 @@ OUString 
SvXMLGraphicHelper::implSaveGraphic(css::uno::Referencehttps://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: wsd/FileServer.cpp wsd/LOOLWSD.cpp wsd/LOOLWSD.hpp

2019-03-05 Thread Libreoffice Gerrit user
 wsd/FileServer.cpp |   30 ++
 wsd/LOOLWSD.cpp|7 +++
 wsd/LOOLWSD.hpp|2 ++
 3 files changed, 35 insertions(+), 4 deletions(-)

New commits:
commit c2aef686012c4130553a0d36f260b12615408126
Author: Henry Castro 
AuthorDate: Sun Feb 10 15:25:37 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 19:40:58 2019 -0400

wsd: add boost::locale generation and caching

Change-Id: I75009a87038632ceaddb29094d340b6d9066d5ef

diff --git a/wsd/FileServer.cpp b/wsd/FileServer.cpp
index 409a9c540..b82becbf1 100644
--- a/wsd/FileServer.cpp
+++ b/wsd/FileServer.cpp
@@ -38,6 +38,9 @@
 #include 
 #include 
 #include 
+#include 
+#include 
+#include 
 
 #include "Auth.hpp"
 #include 
@@ -426,6 +429,18 @@ void FileServerRequestHandler::handleRequest(const 
HTTPRequest& request, Poco::M
 sendError(404, request, socket, "404 - file not found!",
   "There seems to be a problem locating");
 }
+catch (const boost::exception&  exc)
+{
+LOG_WRN("FileServerRequestHandler: " << 
boost::diagnostic_information(exc));
+sendError(404, request, socket, "404 - file not found!",
+"There seems to be a localization problem");
+}
+catch (const std::exception&  exc)
+{
+LOG_WRN("FileServerRequestHandler: " << exc.what());
+sendError(404, request, socket, "404 - file not found!",
+"Internal error");
+}
 }
 
 void FileServerRequestHandler::sendError(int errorCode, const 
Poco::Net::HTTPRequest& request,
@@ -683,11 +698,19 @@ void FileServerRequestHandler::preprocessFile(const 
HTTPRequest& request, Poco::
 documentSigningDiv = "";
 }
 
-std::string lang;
-std::locale locale;
+std::string lang("en");
 std::ostringstream ostr;
 std::istringstream istr(preprocess);
 
+auto pos = std::find_if(params.begin(), params.end(),
+[](const std::pair& it) { return it.first == 
"lang"; });
+if (pos != params.end())
+{
+lang = pos->second;
+}
+
+std::locale locale(LOOLWSD::Generator(lang + ".utf8"));
+
 parse(locale, istr, ostr, [&](const std::string& var) {
 bool result = true;
 if (var == "ACCESS_TOKEN")
@@ -977,8 +1000,7 @@ void FileServerRequestHandler::parse(const std::locale& 
locale, std::istringstre
 {
 if (state == ParseState::L10n)
 {
-LOG_INF(locale.name());
-//ostr << '\'' << 
boost::locale::gettext(varL10n.str().c_str(), locale) << '\'';
+ostr << '\'' << boost::locale::gettext(varL10n.str().c_str(), 
locale) << '\'';
 state = ParseState::None;
 }
 else ostr << token;
diff --git a/wsd/LOOLWSD.cpp b/wsd/LOOLWSD.cpp
index b135fd6bf..1f0e4dc0a 100644
--- a/wsd/LOOLWSD.cpp
+++ b/wsd/LOOLWSD.cpp
@@ -694,6 +694,7 @@ unsigned LOOLWSD::MaxConnections;
 unsigned LOOLWSD::MaxDocuments;
 std::string LOOLWSD::OverrideWatermark;
 std::set 
LOOLWSD::PluginConfigurations;
+boost::locale::generator LOOLWSD::Generator;
 
 static std::string UnitTestLibrary;
 
@@ -1012,6 +1013,12 @@ void LOOLWSD::initialize(Application& self)
 ChildRoot = getPathFromConfig("child_root_path");
 ServerName = config().getString("server_name");
 
+Generator.locale_cache_enabled(true);
+Generator.add_messages_domain("loolwsd");
+Generator.characters(boost::locale::char_facet);
+Generator.categories(boost::locale::message_facet);
+Generator.add_messages_path(config().getString("application.dir", "./") + 
"locale");
+
 FileServerRoot = getPathFromConfig("file_server_root_path");
 NumPreSpawnedChildren = getConfigValue(conf, "num_prespawn_children", 
1);
 if (NumPreSpawnedChildren < 1)
diff --git a/wsd/LOOLWSD.hpp b/wsd/LOOLWSD.hpp
index f4c2db405..73571c9f0 100644
--- a/wsd/LOOLWSD.hpp
+++ b/wsd/LOOLWSD.hpp
@@ -21,6 +21,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include "Util.hpp"
 
@@ -72,6 +73,7 @@ public:
 static unsigned MaxDocuments;
 static std::string OverrideWatermark;
 static std::set 
PluginConfigurations;
+static boost::locale::generator Generator;
 
 static std::vector getKitPids();
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 sc/source/ui/inc/printfun.hxx  |5 -
 sc/source/ui/view/printfun.cxx |   23 +--
 2 files changed, 21 insertions(+), 7 deletions(-)

New commits:
commit 9432bab9f8f4a246d205ff2a460f60aeedba8ce1
Author: Luboš Luňák 
AuthorDate: Tue Mar 5 12:41:44 2019 +0100
Commit: Tomaž Vajngerl 
CommitDate: Wed Mar 6 00:14:42 2019 +0100

do not access uninitialized values when printing (tdf#121439)

The assert in the bugreport is triggered by ScPrintFunc::CalcPages() passing
uninitialized values of nEndRow (and others). These variables apparently
get initialized only by constructors that take ScPrintState. These ctors
also set (the somewhat poorly named) bState and the call to CalcPages()
is guarded by this. However, GetPrintState() will simply create ScPrintState
filled with these uninitialized values and later on this will be used
with these ctors, so bState will be set, but nEndRow will be bogus.

Although 5217a2a0bf27e496cc429ee45dff7c239b466ae6 introduced tdf#121439,
this strange bState logic and unitialized variables has been these since
the initial commit, and the code doesn't take any precautions to check
whether the values are valid or not, so I assume this always was just lucky
enough to work and 5217a2a0bf finally triggered a problem.

Given that it's rather unclear to me how this is supposed to work properly,
just add an extra flag to both ScPrintFunc and ScPrintState marking whether
the values are set or not and make CalcPages() depends on this flag instead.

Change-Id: I0620de6562865c24f5a0edca2566b01546bf2e2b
Reviewed-on: https://gerrit.libreoffice.org/68739
Reviewed-by: Tomaž Vajngerl 
Tested-by: Jenkins

diff --git a/sc/source/ui/inc/printfun.hxx b/sc/source/ui/inc/printfun.hxx
index 7115b7f20845..7184e6e15e3a 100644
--- a/sc/source/ui/inc/printfun.hxx
+++ b/sc/source/ui/inc/printfun.hxx
@@ -150,6 +150,7 @@ struct ScPrintState //  Save 
Variables from ScPrintFunc
 SCROW   nStartRow;
 SCCOL   nEndCol;
 SCROW   nEndRow;
+boolbPrintAreaValid; // the 4 variables above are set
 sal_uInt16  nZoom;
 size_t  nPagesX;
 size_t  nPagesY;
@@ -172,6 +173,7 @@ struct ScPrintState //  Save 
Variables from ScPrintFunc
 , nStartRow(0)
 , nEndCol(0)
 , nEndRow(0)
+, bPrintAreaValid(false)
 , nZoom(0)
 , nPagesX(0)
 , nPagesY(0)
@@ -209,7 +211,7 @@ private:
 const ScRange*  pUserArea;  //  Selection, if set in dialog
 
 const SfxItemSet*   pParamSet;  //  Selected template
-boolbState; // created from State-struct
+boolbFromPrintState;// created from State-struct
 
 //  Parameter from template:
 sal_uInt16  nLeftMargin;
@@ -258,6 +260,7 @@ private:
 SCROW   nStartRow;
 SCCOL   nEndCol;
 SCROW   nEndRow;
+boolbPrintAreaValid; // the 4 variables above are set
 
 sc::PrintPageRanges m_aRanges;
 
diff --git a/sc/source/ui/view/printfun.cxx b/sc/source/ui/view/printfun.cxx
index 96248b21bd31..ca7b8a8e919a 100644
--- a/sc/source/ui/view/printfun.cxx
+++ b/sc/source/ui/view/printfun.cxx
@@ -191,7 +191,7 @@ void ScPrintFunc::Construct( const ScPrintOptions* pOptions 
)
 pParamSet = nullptr;
 }
 
-if (!bState)
+if (!bFromPrintState)
 nZoom = 100;
 nManualZoom = 100;
 bClearWin = false;
@@ -214,13 +214,14 @@ ScPrintFunc::ScPrintFunc( ScDocShell* pShell, SfxPrinter* 
pNewPrinter, SCTAB nTa
 nPageStart  ( nPage ),
 nDocPages   ( nDocP ),
 pUserArea   ( pArea ),
-bState  ( false ),
+bFromPrintState ( false ),
 bSourceRangeValid   ( false ),
 bPrintCurrentTable  ( false ),
 bMultiArea  ( false ),
 mbHasPrintRange(true),
 nTabPages   ( 0 ),
 nTotalPages ( 0 ),
+bPrintAreaValid ( false ),
 pPageData   ( pData )
 {
 pDev = pPrinter.get();
@@ -247,6 +248,7 @@ ScPrintFunc::ScPrintFunc(ScDocShell* pShell, SfxPrinter* 
pNewPrinter,
 nStartRow   = rState.nStartRow;
 nEndCol = rState.nEndCol;
 nEndRow = rState.nEndRow;
+bPrintAreaValid = rState.bPrintAreaValid;
 nZoom   = rState.nZoom;
 m_aRanges.m_nPagesX = rState.nPagesX;
 m_aRanges.m_nPagesY = rState.nPagesY;
@@ -254,7 +256,7 @@ ScPrintFunc::ScPrintFunc(ScDocShell* pShell, SfxPrinter* 
pNewPrinter,
 nTotalPages = rState.nTotalPages;
 nPageStart  = rState.nPageStart;
 nDocPages   = rState.nDocPages;
-bState  = true;
+bFromPrintState = true;
 
 if (rState.bSavedStateRanges)
 {
@@ -279,13 +281,14 @@ ScPrintFunc::ScPrintFunc( OutputDevice* p

[Libreoffice-commits] online.git: wsd/FileServer.cpp wsd/FileServer.hpp

2019-03-05 Thread Libreoffice Gerrit user
 wsd/FileServer.cpp |  254 ++---
 wsd/FileServer.hpp |1 
 2 files changed, 147 insertions(+), 108 deletions(-)

New commits:
commit fcfc257162e106f48b2864820c435fd836588a41
Author: Henry Castro 
AuthorDate: Sun Feb 10 15:19:03 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 18:53:20 2019 -0400

wsd: create a static function "parse"

Change-Id: Ifffae9a0d38bf64c41863a98395a2f41a6470441

diff --git a/wsd/FileServer.cpp b/wsd/FileServer.cpp
index 61259ac05..409a9c540 100644
--- a/wsd/FileServer.cpp
+++ b/wsd/FileServer.cpp
@@ -683,124 +683,74 @@ void FileServerRequestHandler::preprocessFile(const 
HTTPRequest& request, Poco::
 documentSigningDiv = "";
 }
 
-enum class ParseState
-{
-None,
-Subs,
-L10n
-};
-
-std::string token;
+std::string lang;
+std::locale locale;
 std::ostringstream ostr;
-std::stringstream varSubs, varL10n;
 std::istringstream istr(preprocess);
-ParseState state = ParseState::None;
 
-getToken(istr, token);
-while (!token.empty())
-{
-if (token == "<%")
+parse(locale, istr, ostr, [&](const std::string& var) {
+bool result = true;
+if (var == "ACCESS_TOKEN")
 {
-if (state == ParseState::None)
-{
-state = ParseState::Subs;
-varSubs.str("");
-varSubs.clear();
-}
-else ostr << token;
+ostr << escapedAccessToken;
 }
-else if (token == "%>")
+else if (var == "ACCESS_TOKEN_TTL")
 {
-if (state == ParseState::Subs)
-{
-std::string var = varSubs.str();
-if (var == "ACCESS_TOKEN")
-{
-ostr << escapedAccessToken;
-}
-else if (var == "ACCESS_TOKEN_TTL")
-{
-ostr << tokenTtl;
-}
-else if (var == "ACCESS_HEADER")
-{
-ostr << escapedAccessHeader;
-}
-else if (var == "HOST")
-{
-ostr << host;
-}
-else if (var == "VERSION")
-{
-ostr << LOOLWSD_VERSION_HASH;
-}
-else if (var == "SERVICE_ROOT")
-{
-ostr << LOOLWSD::ServiceRoot;
-}
-else if (var == "LOLEAFLET_LOGGING")
-{
-ostr << config.getString("loleaflet_logging", "false");
-}
-else if (var == "OUT_OF_FOCUS_TIMEOUT_SECS")
-{
-ostr << 
config.getString("per_view.out_of_focus_timeout_secs", "60");
-}
-else if (var == "IDLE_TIMEOUT_SECS")
-{
-ostr << config.getString("per_view.idle_timeout_secs", 
"900");
-}
-else if (var == "DOCUMENT_SIGNING_DIV")
-{
-ostr << documentSigningDiv;
-}
-else if (var == "DOCUMENT_SIGNING_URL")
-{
-ostr << documentSigningURL;
-}
-else if (var == "BRANDING_CSS")
-{
-ostr << brandCSS;
-}
-else if (var == "BRANDING_JS")
-{
-ostr << brandJS;
-}
-else ostr << var;
-
-state = ParseState::None;
-}
-else ostr << token;
+ostr << tokenTtl;
 }
-else
+else if (var == "ACCESS_HEADER")
 {
-switch (state)
-{
-case ParseState::None:
-ostr << token;
-break;
-
-case ParseState::Subs:
-varSubs << token;
-break;
-
-case ParseState::L10n:
-varL10n << token;
-break;
-}
+ostr << escapedAccessHeader;
 }
+else if (var == "HOST")
+{
+ostr << host;
+}
+else if (var == "VERSION")
+{
+ostr << LOOLWSD_VERSION_HASH;
+}
+else if (var == "SERVICE_ROOT")
+{
+ostr << LOOLWSD::ServiceRoot;
+}
+else if (var == "LOLEAFLET_LOGGING")
+{
+ostr << config.getString("loleaflet_logging", "false");
+}
+else if (var == "OUT_OF_FOCUS_TIMEOUT_SECS")
+{
+ostr << config.getString("per_view.out_of_focus_timeout_secs", 
"60");
+}
+else if (var == "IDLE_TIMEOUT_SECS")
+{
+ostr << config.getString("per_view.idle_timeout

[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.0' - 3 commits - filter/source sd/qa svx/source sw/qa sw/source

2019-03-05 Thread Libreoffice Gerrit user
 filter/source/svg/svgexport.cxx |   20 +---
 sd/qa/unit/SVGExportTests.cxx   |   15 +++
 sd/qa/unit/data/odp/textbox-link-javascript.odp |binary
 svx/source/xml/xmlgrhlp.cxx |1 +
 sw/qa/extras/ooxmlexport/data/tdf123705.docx|binary
 sw/qa/extras/ooxmlexport/ooxmlexport8.cxx   |4 
 sw/source/filter/ww8/docxattributeoutput.cxx|3 +++
 7 files changed, 36 insertions(+), 7 deletions(-)

New commits:
commit 6f696fd39cabfe212b60152ff11126817d77b89d
Author: Samuel Mehrbrodt 
AuthorDate: Mon Mar 4 09:38:02 2019 +0100
Commit: Andras Timar 
CommitDate: Tue Mar 5 23:38:43 2019 +0100

Check svg URLs before exporting

Reviewed-on: https://gerrit.libreoffice.org/68668
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt 
(cherry picked from commit 34ec46571701d639d9bc542b2d19f87a21a83648)

Change-Id: I3b86b6b82318b0d201c3d7db516664520eb47bed

diff --git a/filter/source/svg/svgexport.cxx b/filter/source/svg/svgexport.cxx
index 87fbbdee425d..e78f546a0c1b 100644
--- a/filter/source/svg/svgexport.cxx
+++ b/filter/source/svg/svgexport.cxx
@@ -49,6 +49,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -1957,13 +1958,18 @@ bool SVGFilter::implExportShape( const Reference< 
XShape >& rxShape, bool bMaste
 
 if( !aBookmark.isEmpty() )
 {
-mpSVGExport->AddAttribute( XML_NAMESPACE_NONE, 
"xlink:href", aBookmark);
-SvXMLElementExport alinkA( *mpSVGExport, 
XML_NAMESPACE_NONE, "a", true, true );
-mpSVGWriter->WriteMetaFile( aTopLeft, aSize, rMtf,
-0x,
-pElementId,
-&rxShape,
-pEmbeddedBitmapsMtf );
+INetURLObject aINetURLObject(aBookmark);
+if (!aINetURLObject.HasError()
+&& aINetURLObject.GetProtocol() != 
INetProtocol::Javascript)
+{
+mpSVGExport->AddAttribute( XML_NAMESPACE_NONE, 
"xlink:href", aBookmark);
+SvXMLElementExport alinkA( *mpSVGExport, 
XML_NAMESPACE_NONE, "a", true, true );
+mpSVGWriter->WriteMetaFile( aTopLeft, aSize, 
rMtf,
+0x,
+pElementId,
+&rxShape,
+
pEmbeddedBitmapsMtf );
+}
 }
 else
 {
diff --git a/sd/qa/unit/SVGExportTests.cxx b/sd/qa/unit/SVGExportTests.cxx
index 9afc5cb42a01..400d604e786c 100644
--- a/sd/qa/unit/SVGExportTests.cxx
+++ b/sd/qa/unit/SVGExportTests.cxx
@@ -110,8 +110,23 @@ public:
 assertXPath(svgDoc, MAKE_PATH_STRING( 
/SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[2]/SVG_G/SVG_TEXT/SVG_TSPAN ), 
"text-decoration", "line-through");
 }
 
+void testSVGExportJavascriptURL()
+{
+executeExport("textbox-link-javascript.odp");
+
+xmlDocPtr svgDoc = parseXml(maTempFile);
+CPPUNIT_ASSERT(svgDoc);
+
+// There should be only one child (no link to javascript url)
+assertXPathChildren(svgDoc,
+MAKE_PATH_STRING(/ SVG_SVG / SVG_G[2] / SVG_G / 
SVG_G / SVG_G / SVG_G
+ / SVG_G[4] / SVG_G),
+1);
+}
+
 CPPUNIT_TEST_SUITE(SdSVGFilterTest);
 CPPUNIT_TEST(testSVGExportTextDecorations);
+CPPUNIT_TEST(testSVGExportJavascriptURL);
 CPPUNIT_TEST_SUITE_END();
 };
 
diff --git a/sd/qa/unit/data/odp/textbox-link-javascript.odp 
b/sd/qa/unit/data/odp/textbox-link-javascript.odp
new file mode 100644
index ..c046cf0c7de5
Binary files /dev/null and b/sd/qa/unit/data/odp/textbox-link-javascript.odp 
differ
commit 03e349cbc8117a9b0c5f5b5ad7f2b7fe28a27f6a
Author: Julien Nabet 
AuthorDate: Tue Feb 26 19:06:59 2019 +0100
Commit: Andras Timar 
CommitDate: Tue Mar 5 23:38:43 2019 +0100

tdf#123705: avoid duplicate themeColor

See http://bugs.documentfoundation.org/attachment.cgi?id=149585
+ https://bugs.documentfoundation.org/show_bug.cgi?id=123705#c4

Change-Id: I3c6fb0a1ac46a62c75bb9daeaded1633889416eb
Reviewed-on: https://gerrit.libreoffice.org/68398
Reviewed-by: Julien Nabet 
(cherry picked from commit 42398e3860aafd6468688eda6c0da942323b7f82)

diff --git a/sw/qa/extras/ooxmlexport/data/tdf123705.docx 
b/sw/qa/ex

Re: logerrit error

2019-03-05 Thread Regina Henschel

Hi,

shubham goyal schrieb am 05-Mar-19 um 08:34:
Hey, I want to submit my patches in Gerrit for review. But here are some 
errors.


  ./logerrit test



First you made your changes.

Then use
git add
to tell git which files you want to commit

Then use
git commit -m " your comment"
to generate the commit.
Please notice, that in case your patch belongs to a bug, your comment 
starts with tdf#123456 (of cause not this dummy number but the actual one).

And notice, that the second line of the comment must be empty.
And notice, that there is no automatic word wrap, but you must manually 
take care, that the comment lines are shorter than 70 characters.


Then use
  ./logerrit submit master
You should then be ask for your ssh-passphrase.

Kind regards
Regina

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

[Libreoffice-commits] online.git: wsd/FileServer.cpp wsd/FileServer.hpp

2019-03-05 Thread Libreoffice Gerrit user
 wsd/FileServer.cpp |   29 -
 wsd/FileServer.hpp |2 +-
 2 files changed, 29 insertions(+), 2 deletions(-)

New commits:
commit 6144d55f44c2109d43bc45c408fe4d1ca8f42207
Author: Henry Castro 
AuthorDate: Sun Feb 10 13:40:38 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 18:27:58 2019 -0400

wsd: tokenize symbol "_('') _("")"

Change-Id: I9c0e7f30a96a355f6d69b2c5a5244dbfbd863e08

diff --git a/wsd/FileServer.cpp b/wsd/FileServer.cpp
index 7c297deb1..61259ac05 100644
--- a/wsd/FileServer.cpp
+++ b/wsd/FileServer.cpp
@@ -567,7 +567,7 @@ constexpr char BRANDING[] = "branding";
 constexpr char BRANDING_UNSUPPORTED[] = "branding-unsupported";
 #endif
 
-void FileServerRequestHandler::getToken(std::istream& istr, std::string& token)
+void FileServerRequestHandler::getToken(std::istringstream& istr, std::string& 
token)
 {
 token.clear();
 int chr = istr.get();
@@ -583,6 +583,33 @@ void FileServerRequestHandler::getToken(std::istream& 
istr, std::string& token)
 token += "%>";
 istr.get();
 }
+else if (chr == '_' && istr.peek() == '(')
+{
+token += "_(";
+istr.get();
+chr = istr.peek();
+switch (chr)
+{
+case '\"':
+chr = istr.get();
+token += (char) chr;
+break;
+case '\'':
+chr = istr.get();
+token += (char) chr;
+break;
+}
+}
+else if (chr == '"' && istr.peek() == ')')
+{
+token += "\")";
+istr.get();
+}
+else if (chr == '\'' && istr.peek() == ')')
+{
+token += "')";
+istr.get();
+}
 else token += (char) chr;
 }
 }
diff --git a/wsd/FileServer.hpp b/wsd/FileServer.hpp
index 637424468..45cf7538b 100644
--- a/wsd/FileServer.hpp
+++ b/wsd/FileServer.hpp
@@ -20,7 +20,7 @@ class FileServerRequestHandler
 {
 static std::string getRequestPathname(const Poco::Net::HTTPRequest& 
request);
 
-static void getToken(std::istream&, std::string&);
+static void getToken(std::istringstream&, std::string&);
 static void preprocessFile(const Poco::Net::HTTPRequest& request, 
Poco::MemoryInputStream& message, const std::shared_ptr& socket);
 static void preprocessAdminFile(const Poco::Net::HTTPRequest& request, 
const std::shared_ptr& socket);
 public:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

GSoC 2019 Application

2019-03-05 Thread mark rimon


Hello,





 My name is Mark Rimon, I am a Computer Engineering student at Ain Shams 
University in Cairo,  I would like to apply for your organization's project at 
Google Summer of Code as i am very interested in your idea.



   I have a strong Knowledge in C++ with object oriented programming and good 
knowledge in data structures and algorithms. I have used C++ to implement a 
command line program to do basic matrices operations similar to Matlab.



I have a good knowledge in programming with Java, i implemented few 
projects with it like a cpu scheduler and used java to develop a mini social 
network android application, and some classic security algorithms like DES 
encryption.



   I also have a good knowledge in python as my graduation project is building 
a system to aid people for driving; using neural networks models to detect 
lanes and cars.

I also have implemented few programs using a lot of python famous libraries 
like numpy, matplotlib, pandas and OpenCV.



 I have a good knowledge in sql, building EER diagrams, mapping them to 
relational databases and using sql queries.



Thanks in advance,





Best regards.


Sent from Mail for Windows 10

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

logerrit error

2019-03-05 Thread shubham goyal
Hey, I want to submit my patches in Gerrit for review. But here are some
errors.

 ./logerrit test

There seems to be trouble. Please have the output of:
ssh - logerrit
at hand when looking for help.

ssh -vvv logerrit

OpenSSH_7.6p1 Ubuntu-4ubuntu0.2, OpenSSL 1.0.2n  7 Dec 2017
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug2: resolving "logerrit" port 22
ssh: Could not resolve hostname logerrit: Name or service not known

I am following
https://wiki.documentfoundation.org/Development/gerrit#Setting_yourself_up_for_gerrit_-_the_easy_way
I also followed the alternative manual way but it didn't help.

The current git push output

ssh: Could not resolve hostname logerrit: Name or service not known
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

Please guide me set up the logerrit
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice

[Libreoffice-commits] online.git: loleaflet/html

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/html/loleaflet.html.m4 |8 
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit d3e8385fbb5020a6b5d72bcee76243c998b43bb5
Author: Henry Castro 
AuthorDate: Sun Feb 10 11:48:13 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 18:16:57 2019 -0400

loleaflet: add LANG variable parameter

Change-Id: Ie822d1d0edb80884752196fd5fe210ab95de5d74

diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index 82808132e..7083857e3 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -205,14 +205,14 @@ ifelse(ANDROIDAPP,[true],
 
 ifelse(MOBILEAPP,[true],
   ifelse(DEBUG,[true],foreachq([fileJS],[LOLEAFLET_JS],
-  [
+  [
   ]),
-  [
+  [
   ]),
   ifelse(DEBUG,[true],foreachq([fileJS],[LOLEAFLET_JS],
-  [
+  [
   ]),
-  [
+  [
   ])
 )dnl
 <%BRANDING_JS%> 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am |  167 ++
 1 file changed, 154 insertions(+), 13 deletions(-)

New commits:
commit 59241a2ea467992adadbacae00a15ec7fe0de2d9
Author: Henry Castro 
AuthorDate: Tue Mar 5 17:59:38 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 18:09:24 2019 -0400

configure:L10n: compile message catalog to binary format

Change-Id: Ia5170a70b80996623260578ece71c63db6510a25

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index 7f90ca147..e220dbd62 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -1,11 +1,142 @@
 # Version number of the bundled 'draw' thing
 DRAW_VERSION=0.2.4
 
-L10N_PO = $(wildcard $(srcdir)/po/*.po)
-
-if !ENABLE_MOBILEAPP
-L10N_JSON = $(patsubst 
$(srcdir)/po/%.po,$(builddir)/dist/l10n/%.json,$(L10N_PO))
-endif
+LANGUAGES = \
+   ab \
+   af \
+   am \
+   an \
+   anp \
+   ar \
+   as \
+   ast \
+   az \
+   bar \
+   be \
+   bg \
+   bm \
+   bn_IN \
+   bn \
+   bo \
+   br \
+   brx \
+   bs \
+   ca \
+   ca-valencia \
+   ce \
+   cs \
+   cy \
+   da \
+   de \
+   dgo \
+   dsb \
+   dz \
+   el \
+   en_AU \
+   en_GB \
+   en_ZA \
+   eo \
+   es \
+   et \
+   eu \
+   fa \
+   fi \
+   fr \
+   fur \
+   fy \
+   ga \
+   gbm \
+   gd \
+   gl \
+   gug \
+   gu \
+   he \
+   hi \
+   hr \
+   hsb \
+   hu \
+   hy \
+   id \
+   is \
+   it \
+   ja \
+   jv \
+   kab \
+   ka \
+   kk \
+   kl \
+   km \
+   kmr-Latn \
+   kn \
+   kok \
+   ko \
+   ks \
+   ky \
+   lb \
+   lo \
+   lt \
+   lv \
+   mai \
+   mk \
+   ml \
+   mni \
+   ml \
+   mr \
+   mt \
+   my \
+   nah \
+   nb \
+   ne \
+   nl \
+   nn \
+   nqo \
+   nr \
+   nso \
+   oc \
+   om \
+   or \
+   pa_IN \
+   pap_CW \
+   pl \
+   pt_BR \
+   pt \
+   ro \
+   ru \
+   rw \
+   sah \
+   sa_IN \
+   sat \
+   sd \
+   sid \
+   si \
+   sk \
+   sl \
+   sq \
+   ss \
+   st \
+   sv \
+   sw_TZ \
+   ta \
+   te \
+   tg \
+   th \
+   ti \
+   tn \
+   tr \
+   ts \
+   tt \
+   ug \
+   uk \
+   ur \
+   uz \
+   vec \
+   ve \
+   vi \
+   wo \
+   xh \
+   zh_CN \
+   zh_TW \
+   zu
 
 if ENABLE_IOSAPP
 L10N_IOS_ALL_JS = $(builddir)/dist/l10n-all.js
@@ -53,6 +184,11 @@ LOLEAFLET_ADMIN_SRC = $(shell find $(srcdir)/admin -name 
'*.html')
 LOLEAFLET_ADMIN_ALL = $(shell find $(srcdir)/admin -name '*')
 LOLEAFLET_ADMIN_DST = $(patsubst 
$(srcdir)/admin/%,$(builddir)/dist/admin/%,$(LOLEAFLET_ADMIN_SRC))
 
+define lang_target
+$(1):: $(2)
+
+endef
+
 define file_target
 $(1): $(2)
@if test -z '$(ENABLE_BROWSERSYNC)'; then \
@@ -94,8 +230,15 @@ LOLEAFLET_CSS =\
 
 LOLEAFLET_CSS_DST = $(foreach file,$(LOLEAFLET_CSS),$(builddir)/dist/$(notdir 
$(file)))
 LOLEAFLET_CSS_M4 = $(strip $(foreach file,$(LOLEAFLET_CSS),$(notdir $(file
+LOLEAFLET_MO_DST = $(foreach 
lang,$(LANGUAGES),$(top_builddir)/locale/$(lang)/LC_MESSAGES/loolwsd.mo)
 
 $(eval $(call file_targets,$(LOLEAFLET_CSS)))
+$(eval $(foreach lang,$(LANGUAGES), \
+   $(call 
lang_target,$(top_builddir)/locale/$(lang)/LC_MESSAGES/loolwsd.mo, \
+   $(srcdir)/po/help-$(lang).po $(srcdir)/po/ui-$(lang).po 
\
+   ) \
+   ) \
+)
 
 NODE_MODULES_JS =\
node_modules/hammerjs/hammer.min.js \
@@ -153,8 +296,8 @@ if !ENABLE_MOBILEAPP
 ADMIN_BUNDLE = $(builddir)/dist/admin-bundle.js
 endif
 
-build-loleaflet: | $(LOLEAFLET_L10N_DST) \
-   $(L10N_JSON) \
+build-loleaflet: | \
+   $(LOLEAFLET_MO_DST) \
$(LOLEAFLET_IMAGES_DST) \
$(JQUERY_LIGHTNESS_DIST_IMAGES) \
$(JQUERY_MINIFIED_DIST_IMAGES) \
@@ -336,13 +479,10 @@ $(builddir)/dist/images/%.png: 
$(JQUERY_MINIFIED_IMAGE_PATH)/%.png
@mkdir -p $(dir $@)
@cp $< $@
 
-$(builddir)/dist/l10n/%.json: $(srcdir)/l10n/%.json
+$(top_builddir)/locale/%/LC_MESSAGES/loolwsd.mo: $(srcdir)/po/help-%.po 
$(srcdir)/po/ui-%.po
+   @echo "INFO: compiling message catalog $@"
@mkdir -p $(dir $@)
-if ENABLE_DEBUG
-   @cp $< $@
-else
-   @tr -d '[:space:]' <$<  >$@
-endif
+   @$(MSGCAT) $^ | $(MSGFMT) -o $@ -
 
 $(builddir)/dist/l10n/%.json: $(srcdir)/po/%.po
@$(srcdir)/util/po2json.py $< -o $@
@@ -390,6 +530,7 @@ l10n: pot
 clean-local:
rm -rf node_modules
rm -rf $(builddir)/dist
+   rm -rf $(top_builddir)/locale
rm -rf $(builddir)/build/dist
 
 spec/data/load-test:
___
Libreoffi

[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.0' - desktop/inc desktop/source

2019-03-05 Thread Libreoffice Gerrit user
 desktop/inc/lib/init.hxx|3 +++
 desktop/source/lib/init.cxx |   18 --
 2 files changed, 15 insertions(+), 6 deletions(-)

New commits:
commit 338708e46cf947e6381cd3e5a5be1993c483b045
Author: Ashod Nakashian 
AuthorDate: Fri Feb 15 09:39:57 2019 -0500
Commit: Andras Timar 
CommitDate: Tue Mar 5 23:01:22 2019 +0100

LOK: reuse cached json object for ViewId where available

Change-Id: I5e29ec2863e06d3dfcbad95c55e355805f12e259
Reviewed-on: https://gerrit.libreoffice.org/68272
Reviewed-by: Andras Timar 
Tested-by: Andras Timar 

diff --git a/desktop/inc/lib/init.hxx b/desktop/inc/lib/init.hxx
index 2ba5595d8b46..013162aa990f 100644
--- a/desktop/inc/lib/init.hxx
+++ b/desktop/inc/lib/init.hxx
@@ -116,6 +116,9 @@ namespace desktop {
 /// Validate that the payload and parsed object match.
 bool validate() const;
 
+/// Returns true iff there is cached data.
+bool isCached() const { return PayloadObject.which() != 0; }
+
 int Type;
 std::string PayloadString;
 
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index b621f134b5f4..262b722ece7f 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -94,7 +94,6 @@
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 
@@ -578,6 +577,13 @@ int lcl_getViewId(const std::string& payload)
 return 0;
 }
 
+int lcl_getViewId(const desktop::CallbackFlushHandler::CallbackData& 
rCallbackData)
+{
+if (rCallbackData.isCached())
+return rCallbackData.getJson().get("viewId");
+return lcl_getViewId(rCallbackData.PayloadString);
+}
+
 std::string extractCertificate(const std::string & certificate)
 {
 const std::string header("-BEGIN CERTIFICATE-");
@@ -1079,7 +1085,7 @@ void CallbackFlushHandler::queue(const int type, const 
char* data)
 const int nViewId = lcl_getViewId(payload);
 removeAll(
 [type, nViewId] (const queue_type::value_type& elem) {
-return (elem.Type == type && nViewId == 
lcl_getViewId(elem.PayloadString));
+return (elem.Type == type && nViewId == 
lcl_getViewId(elem));
 }
 );
 }
@@ -1380,11 +1386,11 @@ void CallbackFlushHandler::Invoke()
 std::unique_lock lock(m_mutex);
 
 SAL_INFO("lok", "Flushing " << m_queue.size() << " elements.");
-for (auto& pair : m_queue)
+for (const auto& rCallbackData : m_queue)
 {
-const int type = pair.Type;
-const auto& payload = pair.PayloadString;
-const int viewId = lcl_isViewCallbackType(type) ? 
lcl_getViewId(payload) : -1;
+const int type = rCallbackData.Type;
+const auto& payload = rCallbackData.PayloadString;
+const int viewId = lcl_isViewCallbackType(type) ? 
lcl_getViewId(rCallbackData) : -1;
 
 if (viewId == -1)
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.0' - scripting/Package_ScriptsPython.mk

2019-03-05 Thread Libreoffice Gerrit user
 scripting/Package_ScriptsPython.mk |1 +
 1 file changed, 1 insertion(+)

New commits:
commit cffa813b8213122dba1206c362ec77a2343f48ba
Author: Ashod Nakashian 
AuthorDate: Sat Mar 2 15:07:05 2019 -0500
Commit: Andras Timar 
CommitDate: Tue Mar 5 23:00:57 2019 +0100

scripting: copy python/InsertText.py to the Scripts directory

Change-Id: I55e367f8fc3bbd2aa65ca9cdef2e97a3dfa3d117
Reviewed-on: https://gerrit.libreoffice.org/68762
Reviewed-by: Andras Timar 
Tested-by: Andras Timar 

diff --git a/scripting/Package_ScriptsPython.mk 
b/scripting/Package_ScriptsPython.mk
index 7612b7ba58bd..0c48839ca42d 100644
--- a/scripting/Package_ScriptsPython.mk
+++ b/scripting/Package_ScriptsPython.mk
@@ -12,6 +12,7 @@ $(eval $(call 
gb_Package_Package,scripting_ScriptsPython,$(SRCDIR)/scripting/exa
 $(eval $(call 
gb_Package_add_files_with_dir,scripting_ScriptsPython,$(LIBO_SHARE_FOLDER)/Scripts,\
python/Capitalise.py \
python/HelloWorld.py \
+   python/InsertText.py \
python/NamedRanges.py \
python/SetCellColor.py \
python/pythonSamples/TableSample.py \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: Repository.mk

2019-03-05 Thread Libreoffice Gerrit user
 Repository.mk |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 525bc99af37787cfee8408fb14a88adf2bf735b2
Author: Tor Lillqvist 
AuthorDate: Tue Mar 5 17:28:55 2019 +0200
Commit: Tor Lillqvist 
CommitDate: Tue Mar 5 22:55:05 2019 +0100

Make mysqlc conditional on MARIADBC, too

Change-Id: I7e8541b8918ea5011fe9669d11b51c941544f794
Reviewed-on: https://gerrit.libreoffice.org/68764
Tested-by: Jenkins
Reviewed-by: Tor Lillqvist 

diff --git a/Repository.mk b/Repository.mk
index c0e797b7106b..59c93c206466 100644
--- a/Repository.mk
+++ b/Repository.mk
@@ -405,7 +405,7 @@ $(eval $(call 
gb_Helper_register_libraries_for_install,OOOLIBS,ooo, \
$(call gb_Helper_optional,SCRIPTING,msforms) \
mtfrenderer \
$(call gb_Helper_optional,DBCONNECTIVITY,mysql_jdbc) \
-   $(call gb_Helper_optional,DBCONNECTIVITY,mysqlc) \
+   $(call gb_Helper_optional,MARIADBC,$(call 
gb_Helper_optional,DBCONNECTIVITY,mysqlc)) \
numbertext \
odbc \
odfflatxml \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 Makefile.am |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 21315768c05fe5fdba85bcab41c4c2032fa8e367
Author: Henry Castro 
AuthorDate: Sun Feb 10 11:42:03 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 17:42:07 2019 -0400

configure: add libraries from Boost Locale to the linker

Change-Id: Icd56a9d18cd42c0300430a5ba1ef4e866b93ccdb

diff --git a/Makefile.am b/Makefile.am
index 4fd349d76..c98d482a8 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -63,7 +63,7 @@ if !ENABLE_DEBUG
 AM_CPPFLAGS += -DNDEBUG
 endif
 
-AM_LDFLAGS = -pthread -Wl,-E,-rpath,/snap/loolwsd/current/usr/lib -lpam 
$(ZLIB_LIBS)
+AM_LDFLAGS = -pthread -Wl,-E,-rpath,/snap/loolwsd/current/usr/lib -lpam 
$(ZLIB_LIBS) $(BOOST_LOCALE_LIB)
 
 if ENABLE_SSL
 AM_LDFLAGS += -lssl -lcrypto
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 l10ntools/source/lngmerge.cxx |   35 ---
 1 file changed, 12 insertions(+), 23 deletions(-)

New commits:
commit 78404432ed784b3570cb4c223e6311c3e9859b60
Author: Matteo Casalin 
AuthorDate: Thu Feb 21 18:27:58 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:37:14 2019 +0100

Group some more common code

Change-Id: I2bf3e8afd9f330e8d7377300163a3224ed4db05c
Reviewed-on: https://gerrit.libreoffice.org/68179
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/l10ntools/source/lngmerge.cxx b/l10ntools/source/lngmerge.cxx
index f6939458c588..fdb0cf90b176 100644
--- a/l10ntools/source/lngmerge.cxx
+++ b/l10ntools/source/lngmerge.cxx
@@ -30,8 +30,14 @@
 
 namespace {
 
-OString getBracketedContent(const OString& text) {
-return text.getToken(1, '[').getToken(0, ']');
+bool lcl_isNextGroup(OString &sGroup_out, const OString &sLineTrim)
+{
+if (sLineTrim.startsWith("[") && sLineTrim.endsWith("]"))
+{
+sGroup_out = sLineTrim.getToken(1, '[').getToken(0, ']').trim();
+return true;
+}
+return false;
 }
 
 void lcl_RemoveUTF8ByteOrderMarker( OString &rString )
@@ -122,13 +128,7 @@ void LngParser::WritePO(PoOfstream &aPOStream,
 
 bool LngParser::isNextGroup(OString &sGroup_out, const OString &sLine_in)
 {
-const OString sLineTrim = sLine_in.trim();
-if (sLineTrim.startsWith("[") && sLineTrim.endsWith("]"))
-{
-sGroup_out = getBracketedContent(sLineTrim).trim();
-return true;
-}
-return false;
+return lcl_isNextGroup(sGroup_out, sLine_in.trim());
 }
 
 void LngParser::ReadLine(const OString &rLine_in,
@@ -162,16 +162,7 @@ void LngParser::Merge(
 
 // seek to next group
 while ( nPos < mvLines.size() && !bGroup )
-{
-OString sLine( mvLines[ nPos ] );
-sLine = sLine.trim();
-if ( sLine.startsWith("[") && sLine.endsWith("]") )
-{
-sGroup = getBracketedContent(sLine).trim();
-bGroup = true;
-}
-nPos ++;
-}
+bGroup = lcl_isNextGroup(sGroup, mvLines[nPos++].trim());
 
 while ( nPos < mvLines.size()) {
 OStringHashMap Text;
@@ -188,11 +179,9 @@ void LngParser::Merge(
 
 while ( nPos < mvLines.size() && !bGroup )
 {
-OString sLine( mvLines[ nPos ] );
-sLine = sLine.trim();
-if ( sLine.startsWith("[") && sLine.endsWith("]") )
+const OString sLine{ mvLines[nPos].trim() };
+if ( lcl_isNextGroup(sGroup, sLine) )
 {
-sGroup = getBracketedContent(sLine).trim();
 bGroup = true;
 nPos ++;
 sLanguagesDone = "";
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 l10ntools/source/lngmerge.cxx |   28 +++-
 1 file changed, 11 insertions(+), 17 deletions(-)

New commits:
commit 070ea7faa821a01b6a077e24724e37962173cb23
Author: Matteo Casalin 
AuthorDate: Thu Feb 21 18:25:02 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:36:20 2019 +0100

Use optimized OString concatenation

Change-Id: Iaefacf4a57398d0e88b4de7552af11832db3e881
Reviewed-on: https://gerrit.libreoffice.org/68178
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/l10ntools/source/lngmerge.cxx b/l10ntools/source/lngmerge.cxx
index 39f98747e99c..f6939458c588 100644
--- a/l10ntools/source/lngmerge.cxx
+++ b/l10ntools/source/lngmerge.cxx
@@ -209,9 +209,7 @@ void LngParser::Merge(
 {
 sLang = sLang.trim();
 
-OString sSearch( ";" );
-sSearch += sLang;
-sSearch += ";";
+OString sSearch{ ";" + sLang + ";" };
 
 if ( sLanguagesDone.indexOf( sSearch ) != -1 ) {
 mvLines.erase( mvLines.begin() + nPos );
@@ -226,14 +224,11 @@ void LngParser::Merge(
 continue;
 
 if ( !sNewText.isEmpty()) {
-OString & rLine = mvLines[ nPos ];
-
-OString sText1( sLang );
-sText1 += " = \"";
-// escape quotes, unescape double escaped 
quotes fdo#56648
-sText1 += 
sNewText.replaceAll("\"","\\\"").replaceAll("\"","\\\"");
-sText1 += "\"";
-rLine = sText1;
+mvLines[ nPos ] = sLang
++ " = \""
+// escape quotes, unescape double escaped 
quotes fdo#56648
++ 
sNewText.replaceAll("\"","\\\"").replaceAll("\"","\\\"")
++ "\"";
 Text[ sLang ] = sNewText;
 }
 }
@@ -264,12 +259,11 @@ void LngParser::Merge(
 continue;
 if ( !sNewText.isEmpty() && sCur != "x-comment")
 {
-OString sLine;
-sLine += sCur;
-sLine += " = \"";
-// escape quotes, unescape double escaped quotes 
fdo#56648
-sLine += 
sNewText.replaceAll("\"","\\\"").replaceAll("\"","\\\"");
-sLine += "\"";
+const OString sLine { sCur
++ " = \""
+// escape quotes, unescape double escaped quotes 
fdo#56648
++ 
sNewText.replaceAll("\"","\\\"").replaceAll("\"","\\\"")
++ "\"" };
 
 nLastLangPos++;
 nPos++;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 reportdesign/source/filter/xml/xmlGroup.cxx |   18 ++
 1 file changed, 6 insertions(+), 12 deletions(-)

New commits:
commit 1e1559256bf64a8f782b6dcb70f191eec767d475
Author: Matteo Casalin 
AuthorDate: Mon Feb 18 00:07:40 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:35:21 2019 +0100

Use index only where getToken() needs it

Change-Id: I28da64c9ef9b36288f380300f6622d48483e6c0d
Reviewed-on: https://gerrit.libreoffice.org/68125
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/reportdesign/source/filter/xml/xmlGroup.cxx 
b/reportdesign/source/filter/xml/xmlGroup.cxx
index 1c976c31a5e8..49f270760616 100644
--- a/reportdesign/source/filter/xml/xmlGroup.cxx
+++ b/reportdesign/source/filter/xml/xmlGroup.cxx
@@ -112,12 +112,10 @@ OXMLGroup::OXMLGroup( ORptFilter& _rImport
 ORptFilter::TGroupFunctionMap::const_iterator 
aFind = aFunctions.find(sValue);
 if ( aFind != aFunctions.end() )
 {
-sal_Int32 nIndex = 0;
 const OUString sCompleteFormula = 
aFind->second->getFormula();
-OUString sExpression = 
sCompleteFormula.getToken(1,'[',nIndex);
-nIndex = 0;
-sExpression = 
sExpression.getToken(0,']',nIndex);
-nIndex = 0;
+OUString sExpression = 
sCompleteFormula.getToken(1,'[');
+sExpression = sExpression.getToken(0,']');
+sal_Int32 nIndex = 0;
 const OUString sFormula = 
sCompleteFormula.getToken(0,'(',nIndex);
 ::sal_Int16 nGroupOn = 
report::GroupOn::DEFAULT;
 
@@ -125,8 +123,7 @@ OXMLGroup::OXMLGroup( ORptFilter& _rImport
 {
 nGroupOn = 
report::GroupOn::PREFIX_CHARACTERS;
 OUString sInterval = 
sCompleteFormula.getToken(1,';',nIndex);
-nIndex = 0;
-sInterval = 
sInterval.getToken(0,')',nIndex);
+sInterval = sInterval.getToken(0,')');
 
m_xGroup->setGroupInterval(sInterval.toInt32());
 }
 else if ( sFormula == "rpt:YEAR")
@@ -153,11 +150,8 @@ OXMLGroup::OXMLGroup( ORptFilter& _rImport
 nGroupOn = report::GroupOn::INTERVAL;
 _rImport.removeFunction(sExpression);
 sExpression = 
sExpression.copy(OUString("INT_count_").getLength());
-
-nIndex = 0;
-OUString sInterval = 
sCompleteFormula.getToken(1,'/',nIndex);
-nIndex = 0;
-sInterval = 
sInterval.getToken(0,')',nIndex);
+OUString sInterval = 
sCompleteFormula.getToken(1,'/');
+sInterval = sInterval.getToken(0,')');
 
m_xGroup->setGroupInterval(sInterval.toInt32());
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 sc/source/core/data/documen4.cxx |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit bb843223c2da5c562d189358184c11993f7b65cc
Author: Matteo Casalin 
AuthorDate: Mon Feb 18 00:04:24 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:33:58 2019 +0100

Use already available index in following getToken call

Change-Id: I1617af942d59c59039e97400a8c39bbc36c3bceb
Reviewed-on: https://gerrit.libreoffice.org/68124
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/sc/source/core/data/documen4.cxx b/sc/source/core/data/documen4.cxx
index d99561497257..b89f2f3d3ebd 100644
--- a/sc/source/core/data/documen4.cxx
+++ b/sc/source/core/data/documen4.cxx
@@ -1168,8 +1168,7 @@ void ScDocument::CompareDocument( ScDocument& rOtherDoc )
 sal_Int32 nIndex = 0;
 OUStringBuffer aProText = aTemplate.getToken( 0, '#', nIndex );
 aProText.append(aTabName);
-nIndex = 0;
-aProText.append(aTemplate.getToken( 1, '#', nIndex ));
+aProText.append(aTemplate.getToken( 0, '#', nIndex ));
 ScProgress aProgress( GetDocumentShell(),
 aProText.makeStringAndClear(), 
3*nThisEndRow, true );  // 2x FindOrder, 1x here
 long nProgressStart = 2*nThisEndRow;// start 
for here
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 sc/source/core/tool/compiler.cxx |5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit a03c8081b55f1a156a4ef6795afe8daa702589e9
Author: Matteo Casalin 
AuthorDate: Mon Feb 18 00:02:32 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:32:48 2019 +0100

Use indexed getToken()

Change-Id: I3f34ccb4253c587088f621f914b315e56f96008f
Reviewed-on: https://gerrit.libreoffice.org/68123
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index 5115f6a187bd..f2ea303e849b 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -4044,8 +4044,9 @@ void ScCompiler::AutoCorrectParsedSymbol()
 const ScAddress::Details aDetails( pConv->meConv, aPos );
 if ( nRefs == 2 )
 {
-aRef[0] = aSymbol.getToken( 0, ':' );
-aRef[1] = aSymbol.getToken( 1, ':' );
+sal_Int32 nIdx{ 0 };
+aRef[0] = aSymbol.getToken( 0, ':', nIdx );
+aRef[1] = aSymbol.getToken( 0, ':', nIdx );
 }
 else
 aRef[0] = aSymbol;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 sc/source/filter/oox/drawingbase.cxx |   32 ++--
 1 file changed, 18 insertions(+), 14 deletions(-)

New commits:
commit fe1322f8d009e45ef598ec9a8a3af8b8f738eb55
Author: Matteo Casalin 
AuthorDate: Sun Feb 17 23:56:43 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:32:15 2019 +0100

Simplify ShapeAnchor::importVmlAnchor

Change-Id: Ibee7914a0c5027b4679163e6a5108f646ad66546
Reviewed-on: https://gerrit.libreoffice.org/68122
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/sc/source/filter/oox/drawingbase.cxx 
b/sc/source/filter/oox/drawingbase.cxx
index d3ea89df7b4e..d1c670d00537 100644
--- a/sc/source/filter/oox/drawingbase.cxx
+++ b/sc/source/filter/oox/drawingbase.cxx
@@ -152,23 +152,27 @@ void ShapeAnchor::importVmlAnchor( const OUString& 
rAnchor )
 meAnchorType = ANCHOR_VML;
 meCellAnchorType = CellAnchorType::Pixel;
 
-::std::vector< OUString > aTokens;
-sal_Int32 nIndex = 0;
-while( nIndex >= 0 )
-aTokens.push_back( rAnchor.getToken( 0, ',', nIndex ).trim() );
+sal_Int32 nValues[8];
+sal_Int32 nI{ 0 };
 
-OSL_ENSURE( aTokens.size() >= 8, "ShapeAnchor::importVmlAnchor - missing 
anchor tokens" );
-if( aTokens.size() >= 8 )
+for(sal_Int32 nIndex{ 0 }; nIndex>=0;)
 {
-maFrom.mnCol   = aTokens[ 0 ].toInt32();
-maFrom.mnColOffset = aTokens[ 1 ].toInt32();
-maFrom.mnRow   = aTokens[ 2 ].toInt32();
-maFrom.mnRowOffset = aTokens[ 3 ].toInt32();
-maTo.mnCol = aTokens[ 4 ].toInt32();
-maTo.mnColOffset   = aTokens[ 5 ].toInt32();
-maTo.mnRow = aTokens[ 6 ].toInt32();
-maTo.mnRowOffset   = aTokens[ 7 ].toInt32();
+nValues[nI] = rAnchor.getToken( 0, ',', nIndex ).toInt32();
+if (++nI==8)
+{
+maFrom.mnCol   = nValues[0];
+maFrom.mnColOffset = nValues[1];
+maFrom.mnRow   = nValues[2];
+maFrom.mnRowOffset = nValues[3];
+maTo.mnCol = nValues[4];
+maTo.mnColOffset   = nValues[5];
+maTo.mnRow = nValues[6];
+maTo.mnRowOffset   = nValues[7];
+return;
+}
 }
+
+OSL_FAIL("ShapeAnchor::importVmlAnchor - missing anchor tokens" );
 }
 
 bool ShapeAnchor::isAnchorValid() const
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 configure.ac |6 ++
 1 file changed, 6 insertions(+)

New commits:
commit a6b2708ef58fd23dd536606ec8fe4778c285952f
Author: Henry Castro 
AuthorDate: Sun Feb 10 11:38:03 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 17:31:57 2019 -0400

configure: check "msgfmt" installation

Change-Id: Ib6661e3e79e4ceba6379097875d5d1e7998838e6

diff --git a/configure.ac b/configure.ac
index dc4a51977..651a0660e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -225,6 +225,12 @@ else
 fi
 AC_SUBST(ENABLE_BROWSERSYNC)
 
+AC_CHECK_PROGS(MSGFMT, [msgfmt])
+AC_CHECK_PROGS(MSGCAT, [msgcat])
+if test -z "$MSGFMT"; then
+AC_MSG_ERROR([msgfmt not found. Install GNU gettext])
+fi
+
 if test -n "$with_logfile" ; then
LOOLWSD_LOGFILE="$with_logfile"
 fi
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 oox/source/ppt/comments.cxx |   17 -
 1 file changed, 8 insertions(+), 9 deletions(-)

New commits:
commit e79377df461075815fb5d40badd81918c256c247
Author: Matteo Casalin 
AuthorDate: Sun Feb 17 23:47:00 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:31:04 2019 +0100

Use indexed getToken and improve tokenization

Third token (i.e. day) would span to the end of the string
and conversion to int works just because it stops at first
non-numeric character.

Change-Id: I4f608aafadd634c312f7cfd986966f453bfca872
Reviewed-on: https://gerrit.libreoffice.org/68121
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/oox/source/ppt/comments.cxx b/oox/source/ppt/comments.cxx
index 468a648ea99a..d803b97a7877 100644
--- a/oox/source/ppt/comments.cxx
+++ b/oox/source/ppt/comments.cxx
@@ -29,16 +29,15 @@ void CommentAuthorList::setValues(const CommentAuthorList& 
list)
 }
 
 //DateTime is saved as : 2013-01-10T15:53:26.000
-void Comment::setDateTime (const OUString& _datetime)
+void Comment::setDateTime (const OUString& sDateTime)
 {
-OUString datetime = _datetime;
-aDateTime.Year = datetime.getToken(0,'-').toInt32();
-aDateTime.Month = datetime.getToken(1,'-').toUInt32();
-aDateTime.Day = datetime.getToken(2,'-').toUInt32();
-datetime = datetime.getToken(1,'T');
-aDateTime.Hours = datetime.getToken(0,':').toUInt32();
-aDateTime.Minutes = datetime.getToken(1,':').toUInt32();
-double seconds = datetime.getToken(2,':').toDouble();
+sal_Int32 nIdx{ 0 };
+aDateTime.Year = sDateTime.getToken(0, '-', nIdx).toInt32();
+aDateTime.Month = sDateTime.getToken(0, '-', nIdx).toUInt32();
+aDateTime.Day = sDateTime.getToken(0, 'T', nIdx).toUInt32();
+aDateTime.Hours = sDateTime.getToken(0, ':', nIdx).toUInt32();
+aDateTime.Minutes = sDateTime.getToken(0, ':', nIdx).toUInt32();
+double seconds = sDateTime.copy(nIdx).toDouble();
 aDateTime.Seconds = floor(seconds);
 seconds -= aDateTime.Seconds;
 aDateTime.NanoSeconds = ::rtl::math::round(seconds * 10);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 l10ntools/source/xrmmerge.cxx |   42 --
 1 file changed, 12 insertions(+), 30 deletions(-)

New commits:
commit c7ab0bff8df23661ee9304578bd9fcf63f4d2dd0
Author: Matteo Casalin 
AuthorDate: Sun Feb 17 23:44:17 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:30:09 2019 +0100

Use optimized OString concatenation

Change-Id: I7c74e007cb382701c3d9c41f9a6fb76ff0cb19fe
Reviewed-on: https://gerrit.libreoffice.org/68120
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/l10ntools/source/xrmmerge.cxx b/l10ntools/source/xrmmerge.cxx
index b6f7d388c31f..26dee6f4540c 100644
--- a/l10ntools/source/xrmmerge.cxx
+++ b/l10ntools/source/xrmmerge.cxx
@@ -261,12 +261,8 @@ void XRMResParser::Execute( int nToken, char * pToken )
 
 OString XRMResParser::GetAttribute( const OString &rToken, const OString 
&rAttribute )
 {
-OString sTmp( rToken );
-sTmp = sTmp.replace('\t', ' ');
-
-OString sSearch( " " );
-sSearch += rAttribute;
-sSearch += "=";
+const OString sSearch{ " " + rAttribute + "=" };
+OString sTmp{ rToken.replace('\t', ' ') };
 sal_Int32 nPos = sTmp.indexOf( sSearch );
 
 if ( nPos<0 )
@@ -293,9 +289,7 @@ XRMResExport::XRMResExport(
 pOutputStream.open( rOutputFile, PoOfstream::APP );
 if (!pOutputStream.isOpen())
 {
-OString sError( "Unable to open output file: " );
-sError += rOutputFile;
-Error( sError );
+Error( "Unable to open output file: " + rOutputFile );
 }
 }
 
@@ -310,9 +304,8 @@ void XRMResExport::WorkOnDesc(
 const OString &rOpenTag,
 OString &rText )
 {
-OString sDescFileName(
-sInputFileName.replaceAll("description.xml", OString()));
-sDescFileName += GetAttribute( rOpenTag, "xlink:href" );
+const OString sDescFileName{ sInputFileName.replaceAll("description.xml", 
OString())
++ GetAttribute( rOpenTag, "xlink:href" ) };
 ifstream file (sDescFileName.getStr(), ios::in|ios::binary|ios::ate);
 if (file.is_open()) {
 int size = static_cast(file.tellg());
@@ -377,9 +370,7 @@ XRMResMerge::XRMResMerge(
 pOutputStream.open(
 rOutputFile.getStr(), std::ios_base::out | std::ios_base::trunc);
 if (!pOutputStream.is_open()) {
-OString sError( "Unable to open output file: " );
-sError += rOutputFile;
-Error( sError );
+Error( "Unable to open output file: " + rOutputFile );
 }
 }
 
@@ -405,10 +396,8 @@ void XRMResMerge::WorkOnDesc(
 ( pEntrys->GetText( sText, sCur, true )) &&
 !sText.isEmpty())
 {
-OString sAdditionalLine( "\n" );
-sAdditionalLine += rOpenTag;
-OString sSearch = sLangAttribute;
-sSearch += "=\"";
+OString sAdditionalLine{ "\n"  + rOpenTag };
+OString sSearch{ sLangAttribute + "=\"" };
 OString sReplace( sSearch );
 
 sSearch += GetAttribute( rOpenTag, sLangAttribute );
@@ -419,9 +408,7 @@ void XRMResMerge::WorkOnDesc(
 sSearch = OString("xlink:href=\"");
 sReplace = sSearch;
 
-OString sLocDescFilename = sDescFilename;
-sLocDescFilename = sLocDescFilename.replaceFirst(
-"en-US", sCur);
+const OString sLocDescFilename = 
sDescFilename.replaceFirst( "en-US", sCur);
 
 sSearch += sDescFilename;
 sReplace += sLocDescFilename;
@@ -491,20 +478,15 @@ void XRMResMerge::EndOfText(
 helper::isWellFormedXML( sContent ))
 {
 const OString& sText( sContent );
-OString sAdditionalLine( "\n" );
-sAdditionalLine += rOpenTag;
-OString sSearch = sLangAttribute;
-sSearch += "=\"";
+OString sAdditionalLine{ "\n" + rOpenTag };
+OString sSearch{ sLangAttribute + "=\"" };
 OString sReplace( sSearch );
 
 sSearch += GetAttribute( rOpenTag, sLangAttribute );
 sReplace += sCur;
 
 sAdditionalLine = sAdditionalLine.replaceFirst(
-sSearch, sReplace);
-
-sAdditionalLine += sText;
-sAdditionalLine += rCloseTag;
+sSearch, sReplace) + sText + rCloseTag;
 
 Output( sAdditionalLine );
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 l10ntools/source/xrmmerge.cxx |   11 ---
 1 file changed, 4 insertions(+), 7 deletions(-)

New commits:
commit 730df730a9425dbf4ed778dce7a95c1c0be274f6
Author: Matteo Casalin 
AuthorDate: Sun Feb 17 23:32:22 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:29:03 2019 +0100

Avoid unneeded OUString copy

Change-Id: I43d66f1bf4fc4a17f7dbea62e3fb13675dbbfb8a
Reviewed-on: https://gerrit.libreoffice.org/68119
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/l10ntools/source/xrmmerge.cxx b/l10ntools/source/xrmmerge.cxx
index 4670dc7c3ab2..b6f7d388c31f 100644
--- a/l10ntools/source/xrmmerge.cxx
+++ b/l10ntools/source/xrmmerge.cxx
@@ -269,13 +269,10 @@ OString XRMResParser::GetAttribute( const OString 
&rToken, const OString &rAttri
 sSearch += "=";
 sal_Int32 nPos = sTmp.indexOf( sSearch );
 
-if ( nPos != -1 )
-{
-sTmp = sTmp.copy( nPos );
-OString sId = sTmp.getToken(1, '"');
-return sId;
-}
-return OString();
+if ( nPos<0 )
+return OString();
+
+return sTmp.getToken(1, '"', nPos);
 }
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 sc/source/filter/oox/formulabase.cxx |4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

New commits:
commit 3cf1467379b2bad76a23e239051aa3a7852d786c
Author: Matteo Casalin 
AuthorDate: Sun Feb 17 18:25:28 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:28:13 2019 +0100

Index returned by getToken is always lower than string length

Change-Id: I7de7a3eaf7b4ae6ef97b0c23fb755ad108db19e6
Reviewed-on: https://gerrit.libreoffice.org/68118
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/sc/source/filter/oox/formulabase.cxx 
b/sc/source/filter/oox/formulabase.cxx
index d540fbf12cb3..e4cefc504b06 100644
--- a/sc/source/filter/oox/formulabase.cxx
+++ b/sc/source/filter/oox/formulabase.cxx
@@ -1685,9 +1685,7 @@ void FormulaProcessorBase::convertStringToStringList(
 if( extractString( aString, orTokens ) && !aString.isEmpty() )
 {
 ::std::vector< ApiToken > aNewTokens;
-sal_Int32 nPos = 0;
-sal_Int32 nLen = aString.getLength();
-while( (0 <= nPos) && (nPos < nLen) )
+for( sal_Int32 nPos{ 0 }; nPos>=0; )
 {
 OUString aEntry = aString.getToken( 0, cStringSep, nPos );
 if( bTrimLeadingSpaces )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 sc/source/filter/oox/pagesettings.cxx |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 9e1dfe405cd597c80d63a2138c36cebd4e98400e
Author: Matteo Casalin 
AuthorDate: Sun Feb 17 18:21:58 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:27:39 2019 +0100

Index returned by getToken is always lower than string length

Also take care of handling possibly empty strings, for which
the initial 0 index would fail the comparison.

Change-Id: I280fac697554f2a4513a641ac258b1d2baf803f4
Reviewed-on: https://gerrit.libreoffice.org/68117
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/sc/source/filter/oox/pagesettings.cxx 
b/sc/source/filter/oox/pagesettings.cxx
index 32d6ddc55478..7afa498e828e 100644
--- a/sc/source/filter/oox/pagesettings.cxx
+++ b/sc/source/filter/oox/pagesettings.cxx
@@ -823,9 +823,9 @@ void HeaderFooterParser::convertFontName( const OUString& 
rName )
 void HeaderFooterParser::convertFontStyle( const OUString& rStyle )
 {
 maFontModel.mbBold = maFontModel.mbItalic = false;
-sal_Int32 nPos = 0;
-sal_Int32 nLen = rStyle.getLength();
-while( (0 <= nPos) && (nPos < nLen) )
+if (rStyle.isEmpty())
+return;
+for( sal_Int32 nPos{ 0 }; nPos>=0; )
 {
 OString aToken = OUStringToOString( rStyle.getToken( 0, ' ', nPos ), 
RTL_TEXTENCODING_UTF8 ).toAsciiLowerCase();
 if( !aToken.isEmpty() )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 sc/source/filter/oox/worksheethelper.cxx |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 234f4ef41b6dd634471dbe0c727e468c2e328acc
Author: Matteo Casalin 
AuthorDate: Sun Feb 17 18:18:34 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:27:00 2019 +0100

Index is not needed for single getToken call

Change-Id: I46d466c0526797e5c246dea3c68a6b2f865964e0
Reviewed-on: https://gerrit.libreoffice.org/68116
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/sc/source/filter/oox/worksheethelper.cxx 
b/sc/source/filter/oox/worksheethelper.cxx
index 64c05c9442cd..dfc603078734 100644
--- a/sc/source/filter/oox/worksheethelper.cxx
+++ b/sc/source/filter/oox/worksheethelper.cxx
@@ -1057,8 +1057,7 @@ void WorksheetGlobals::finalizeValidationRanges() const
 
 try
 {
-sal_Int32 nIndex = 0;
-OUString aToken = validation.msRef.getToken( 0, ' ', nIndex );
+const OUString aToken = validation.msRef.getToken( 0, ' ' );
 
 Reference xSheet = getSheetFromDoc( 
getCurrentSheetIndex() );
 Reference xDBCellRange;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 sd/source/ui/func/fuprlout.cxx |5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit 2e70e02b8eff25b1abcfac125a46724793a6b8dd
Author: Matteo Casalin 
AuthorDate: Sun Feb 10 16:35:30 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 22:26:33 2019 +0100

Use indexed getToken()

Change-Id: I76b565d24a27eda62383df757f97d197c3b276a8
Reviewed-on: https://gerrit.libreoffice.org/67646
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/sd/source/ui/func/fuprlout.cxx b/sd/source/ui/func/fuprlout.cxx
index 13548e66b6d5..9e9eb7721596 100644
--- a/sd/source/ui/func/fuprlout.cxx
+++ b/sd/source/ui/func/fuprlout.cxx
@@ -211,7 +211,8 @@ void FuPresentationLayout::DoExecute( SfxRequest& rReq )
 
 if (bLoad)
 {
-OUString aFileName = aFile.getToken(0, DOCUMENT_TOKEN);
+sal_Int32 nIdx{ 0 };
+OUString aFileName = aFile.getToken(0, DOCUMENT_TOKEN, nIdx);
 SdDrawDocument* pTempDoc = mpDoc->OpenBookmarkDoc( aFileName );
 
 // #69581: If I chose the standard-template I got no filename and so I 
get no
@@ -219,7 +220,7 @@ void FuPresentationLayout::DoExecute( SfxRequest& rReq )
 // a NULL-pointer as a Standard-template ( look at 
SdDrawDocument::SetMasterPage )
 OUString aLayoutName;
 if( pTempDoc )
-aLayoutName = aFile.getToken(1, DOCUMENT_TOKEN);
+aLayoutName = aFile.getToken(0, DOCUMENT_TOKEN, nIdx);
 for (auto nSelectedPage : aSelectedPageNums)
 mpDoc->SetMasterPage(nSelectedPage, aLayoutName, pTempDoc, 
bMasterPage, bCheckMasters);
 mpDoc->CloseBookmarkDoc();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: m4/ax_boost_locale.m4

2019-03-05 Thread Libreoffice Gerrit user
 m4/ax_boost_locale.m4 |9 ++---
 1 file changed, 6 insertions(+), 3 deletions(-)

New commits:
commit 82207d6967349de3e4df880a5279b0efe3319f9a
Author: Henry Castro 
AuthorDate: Thu Feb 7 11:58:54 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 17:19:15 2019 -0400

m4: fix 'char exit()' conflicts with built-in declaration 'void exit(int)'

Change-Id: I87a12ac12511e044851e3189ede9c5cb76be26c5

diff --git a/m4/ax_boost_locale.m4 b/m4/ax_boost_locale.m4
index adaedf09e..30e763e78 100644
--- a/m4/ax_boost_locale.m4
+++ b/m4/ax_boost_locale.m4
@@ -84,14 +84,16 @@ AC_DEFUN([AX_BOOST_LOCALE],
 if test "x$ax_boost_user_locale_lib" = "x"; then
 for libextension in `ls $BOOSTLIBDIR/libboost_locale*.so* 
$BOOSTLIBDIR/libboost_locale*.dylib* $BOOSTLIBDIR/libboost_locale*.a* 
2>/dev/null | sed 's,.*/,,' | sed -e 's;^lib\(boost_locale.*\)\.so.*$;\1;' -e 
's;^lib\(boost_locale.*\)\.dylib.*$;\1;' -e 
's;^lib\(boost_locale.*\)\.a.*$;\1;'` ; do
  ax_lib=${libextension}
-   AC_CHECK_LIB($ax_lib, exit,
+LDFLAGS="$LDFLAGS_SAVE -l$ax_lib"
+AC_LINK_IFELSE([AC_LANG_PROGRAM([#include],[boost::locale::pgettext("test","test");])],
  [BOOST_LOCALE_LIB="-l$ax_lib"; 
AC_SUBST(BOOST_LOCALE_LIB) link_locale="yes"; break],
  [link_locale="no"])
done
 if test "x$link_locale" != "xyes"; then
 for libextension in `ls $BOOSTLIBDIR/boost_locale*.dll* 
$BOOSTLIBDIR/boost_locale*.a* 2>/dev/null | sed 's,.*/,,' | sed -e 
's;^\(boost_locale.*\)\.dll.*$;\1;' -e 's;^\(boost_locale.*\)\.a.*$;\1;'` ; do
  ax_lib=${libextension}
-   AC_CHECK_LIB($ax_lib, exit,
+LDFLAGS="$LDFLAGS_SAVE -l$ax_lib"
+AC_LINK_IFELSE([AC_LANG_PROGRAM([#include],[boost::locale::pgettext("test","test");])],
  [BOOST_LOCALE_LIB="-l$ax_lib"; 
AC_SUBST(BOOST_LOCALE_LIB) link_locale="yes"; break],
  [link_locale="no"])
done
@@ -99,7 +101,8 @@ AC_DEFUN([AX_BOOST_LOCALE],
 
 else
for ax_lib in $ax_boost_user_locale_lib 
boost_locale-$ax_boost_user_locale_lib; do
- AC_CHECK_LIB($ax_lib, exit,
+LDFLAGS="$LDFLAGS_SAVE -l$ax_lib"
+AC_LINK_IFELSE([AC_LANG_PROGRAM([#include],[boost::locale::pgettext("test","test");])],
[BOOST_LOCALE_LIB="-l$ax_lib"; 
AC_SUBST(BOOST_LOCALE_LIB) link_locale="yes"; break],
[link_locale="no"])
   done
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: include/o3tl sc/inc sc/source xmlsecurity/qa

2019-03-05 Thread Libreoffice Gerrit user
 include/o3tl/typed_flags_set.hxx|  109 ++--
 include/o3tl/underlyingenumvalue.hxx|   28 
 sc/inc/address.hxx  |5 -
 sc/source/core/tool/address.cxx |4 -
 sc/source/core/tool/reffind.cxx |6 +
 xmlsecurity/qa/unit/signing/signing.cxx |   45 -
 6 files changed, 103 insertions(+), 94 deletions(-)

New commits:
commit b612cf0e06de231b7f936269db3b51a7f0e8ae3b
Author: Stephan Bergmann 
AuthorDate: Tue Mar 5 15:41:18 2019 +0100
Commit: Stephan Bergmann 
CommitDate: Tue Mar 5 22:11:48 2019 +0100

Introduce o3tl::underlyingEnumValue

Change-Id: I6554eb86326159b0da707539f45c411f61c0f3de
Reviewed-on: https://gerrit.libreoffice.org/68761
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 

diff --git a/include/o3tl/typed_flags_set.hxx b/include/o3tl/typed_flags_set.hxx
index 188258febc58..bf795908bad5 100644
--- a/include/o3tl/typed_flags_set.hxx
+++ b/include/o3tl/typed_flags_set.hxx
@@ -25,6 +25,7 @@
 #include 
 #include 
 
+#include 
 #include 
 
 namespace o3tl {
@@ -104,10 +105,10 @@ template
 constexpr typename o3tl::typed_flags::Wrap operator ~(E rhs) {
 assert(
 o3tl::detail::isNonNegative(
-static_cast::type>(rhs)));
+o3tl::underlyingEnumValue(rhs)));
 return static_cast::Wrap>(
 o3tl::typed_flags::mask
-& ~static_cast::type>(rhs));
+& ~o3tl::underlyingEnumValue(rhs));
 }
 
 template constexpr typename o3tl::typed_flags::Wrap operator ~(
@@ -115,7 +116,7 @@ template constexpr typename 
o3tl::typed_flags::Wrap operator ~(
 {
 return static_cast::Wrap>(
 o3tl::typed_flags::mask
-& ~static_cast::type>(rhs));
+& ~o3tl::underlyingEnumValue(rhs));
 }
 
 template constexpr typename o3tl::typed_flags::Wrap operator ^(
@@ -123,13 +124,13 @@ template constexpr typename 
o3tl::typed_flags::Wrap operator ^(
 {
 assert(
 o3tl::detail::isNonNegative(
-static_cast::type>(lhs)));
+o3tl::underlyingEnumValue(lhs)));
 assert(
 o3tl::detail::isNonNegative(
-static_cast::type>(rhs)));
+o3tl::underlyingEnumValue(rhs)));
 return static_cast::Wrap>(
-static_cast::type>(lhs)
-^ static_cast::type>(rhs));
+o3tl::underlyingEnumValue(lhs)
+^ o3tl::underlyingEnumValue(rhs));
 }
 
 template constexpr typename o3tl::typed_flags::Wrap operator ^(
@@ -137,10 +138,10 @@ template constexpr typename 
o3tl::typed_flags::Wrap operator ^(
 {
 assert(
 o3tl::detail::isNonNegative(
-static_cast::type>(lhs)));
+o3tl::underlyingEnumValue(lhs)));
 return static_cast::Wrap>(
-static_cast::type>(lhs)
-^ static_cast::type>(rhs));
+o3tl::underlyingEnumValue(lhs)
+^ o3tl::underlyingEnumValue(rhs));
 }
 
 template constexpr typename o3tl::typed_flags::Wrap operator ^(
@@ -148,10 +149,10 @@ template constexpr typename 
o3tl::typed_flags::Wrap operator ^(
 {
 assert(
 o3tl::detail::isNonNegative(
-static_cast::type>(rhs)));
+o3tl::underlyingEnumValue(rhs)));
 return static_cast::Wrap>(
-static_cast::type>(lhs)
-^ static_cast::type>(rhs));
+o3tl::underlyingEnumValue(lhs)
+^ o3tl::underlyingEnumValue(rhs));
 }
 
 template constexpr
@@ -159,25 +160,21 @@ typename o3tl::typed_flags::Wrap operator ^(
 W lhs, W rhs)
 {
 return static_cast(
-static_cast<
-typename std::underlying_type::type>(
-lhs)
-^ static_cast<
-typename std::underlying_type::type>(
-rhs));
+o3tl::underlyingEnumValue(lhs)
+^ o3tl::underlyingEnumValue(rhs));
 }
 
 template
 constexpr typename o3tl::typed_flags::Wrap operator &(E lhs, E rhs) {
 assert(
 o3tl::detail::isNonNegative(
-static_cast::type>(lhs)));
+o3tl::underlyingEnumValue(lhs)));
 assert(
 o3tl::detail::isNonNegative(
-static_cast::type>(rhs)));
+o3tl::underlyingEnumValue(rhs)));
 return static_cast::Wrap>(
-static_cast::type>(lhs)
-& static_cast::type>(rhs));
+o3tl::underlyingEnumValue(lhs)
+& o3tl::underlyingEnumValue(rhs));
 }
 
 template constexpr typename o3tl::typed_flags::Wrap operator &(
@@ -185,10 +182,10 @@ template constexpr typename 
o3tl::typed_flags::Wrap operator &(
 {
 assert(
 o3tl::detail::isNonNegative(
-static_cast::type>(lhs)));
+o3tl::underlyingEnumValue(lhs)));
 return static_cast::Wrap>(
-static_cast::type>(lhs)
-& static_cast::type>(rhs));
+o3tl::underlyingEnumValue(lhs)
+& o3tl::underlyingEnumValue(rhs));
 }
 
 template constexpr typename o3tl::typed_flags::Wrap operator &(
@@ -196,10 +193,10 @@ template constexpr typename 
o3tl::typed_flags::Wrap operator &(
 {
 

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

2019-03-05 Thread Libreoffice Gerrit user
 lotuswordpro/source/filter/tocread.cxx |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit efbd217afc52390138195e06e96ef9c8f10bf37b
Author: Caolán McNamara 
AuthorDate: Tue Mar 5 13:25:16 2019 +
Commit: Caolán McNamara 
CommitDate: Tue Mar 5 22:09:26 2019 +0100

Resolves: tdf#123815 null terminator included in string

regression from...

commit 18d636063fd7be165e7888af49372a6e2b851776
Author: Caolán McNamara 
Date:   Mon Jun 19 09:46:31 2017 +0100

ofz: use OString instead of bare char*

this is no use to the reporter though, as the document format is
10 and 11 is the oldest the filter will open

Change-Id: I4cdfe92e37f047493a6eab95f0e8e9f5dced1a35
Reviewed-on: https://gerrit.libreoffice.org/68745
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/lotuswordpro/source/filter/tocread.cxx 
b/lotuswordpro/source/filter/tocread.cxx
index e2421efb0931..203fe79a466f 100644
--- a/lotuswordpro/source/filter/tocread.cxx
+++ b/lotuswordpro/source/filter/tocread.cxx
@@ -290,7 +290,9 @@ CBenTOCReader::ReadTOC()
 return Err;
 }
 
-OString sName(sBuffer, Length);
+OString sName;
+if (Length)
+sName = OString(sBuffer, Length - 1);
 
 CUtListElmt * pPrevNamedObjectListElmt;
 if (FindNamedObject(&cpContainer->GetNamedObjects(),
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: autogen.sh configure.ac .gitignore m4/ax_boost_base.m4 m4/ax_boost_locale.m4

2019-03-05 Thread Libreoffice Gerrit user
 .gitignore|1 
 autogen.sh|2 
 configure.ac  |5 
 m4/ax_boost_base.m4   |  266 ++
 m4/ax_boost_locale.m4 |  119 ++
 5 files changed, 391 insertions(+), 2 deletions(-)

New commits:
commit b1bec2f5005049204badee639ece50012d631933
Author: Henry Castro 
AuthorDate: Thu Feb 7 11:46:26 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 16:58:22 2019 -0400

configure: add Boost.Locale library

use --with-boost-libdir=LIB_DIR

Change-Id: I7c01fa33ce1dafcfc636ddcdeae46111b2ccab8e

diff --git a/.gitignore b/.gitignore
index 52ee34543..ab93d7460 100644
--- a/.gitignore
+++ b/.gitignore
@@ -31,7 +31,6 @@ libtool
 ltmain.sh
 missing
 stamp-h1
-m4
 debian/loolwsd.postinst
 common/support-public-key.hpp
 
diff --git a/autogen.sh b/autogen.sh
index f5043bec5..6ce4cbd65 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -22,7 +22,7 @@ elif test `uname -s` = Darwin; then
 glibtoolize || failed "Can't find glibtoolize. For instance use the one 
from https://brew.sh, 'brew install libtool', or build GNU libtool yourself."
 fi
 
-aclocal || failed "aclocal"
+aclocal -I m4 || failed "aclocal"
 
 autoheader || failed "autoheader"
 
diff --git a/configure.ac b/configure.ac
index b99020a7a..dc4a51977 100644
--- a/configure.ac
+++ b/configure.ac
@@ -179,6 +179,9 @@ AC_ARG_ENABLE([werror],
 AC_ARG_ENABLE([vereign],
 AS_HELP_STRING([--enable-vereign],
   [Set Vereign document_signing_url configuration key 
to the default app.vereign.com.]))
+
+AX_BOOST_BASE(1.47)
+
 # Handle options
 AS_IF([test "$enable_debug" = yes -a -n "$with_poco_libs"],
   [POCO_DEBUG_SUFFIX=d],
@@ -675,6 +678,8 @@ fi
 
 AC_SUBST(ENABLE_SETCAP)
 
+AX_BOOST_LOCALE
+
 AC_CONFIG_LINKS([discovery.xml:discovery.xml])
 AC_CONFIG_LINKS([loolkitconfig.xcu:loolkitconfig.xcu])
 AC_CONFIG_LINKS([loleaflet/package.json:loleaflet/package.json])
diff --git a/m4/ax_boost_base.m4 b/m4/ax_boost_base.m4
new file mode 100644
index 0..94909a52f
--- /dev/null
+++ b/m4/ax_boost_base.m4
@@ -0,0 +1,266 @@
+# ===
+#   http://www.gnu.org/software/autoconf-archive/ax_boost_base.html
+# ===
+#
+# SYNOPSIS
+#
+#   AX_BOOST_BASE([MINIMUM-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
+#
+# DESCRIPTION
+#
+#   Test for the Boost C++ libraries of a particular version (or newer)
+#
+#   If no path to the installed boost library is given the macro searches
+#   under /usr, /usr/local, /opt and /opt/local and evaluates the
+#   $BOOST_ROOT environment variable. Further documentation is available at
+#   .
+#
+#   This macro calls:
+#
+# AC_SUBST(BOOST_CPPFLAGS) / AC_SUBST(BOOST_LDFLAGS)
+#
+#   And sets:
+#
+# HAVE_BOOST
+#
+# LICENSE
+#
+#   Copyright (c) 2008 Thomas Porschberg 
+#   Copyright (c) 2009 Peter Adolphs
+#
+#   Copying and distribution of this file, with or without modification, are
+#   permitted in any medium without royalty provided the copyright notice
+#   and this notice are preserved. This file is offered as-is, without any
+#   warranty.
+
+#serial 20
+
+AC_DEFUN([AX_BOOST_BASE],
+[
+AC_ARG_WITH([boost],
+  [AS_HELP_STRING([--with-boost@<:@=ARG@:>@],
+[use Boost library from a standard location (ARG=yes),
+ from the specified location (ARG=),
+ or disable it (ARG=no)
+ @<:@ARG=yes@:>@ ])],
+[
+if test "$withval" = "no"; then
+want_boost="no"
+elif test "$withval" = "yes"; then
+want_boost="yes"
+ac_boost_path=""
+else
+want_boost="yes"
+ac_boost_path="$withval"
+fi
+],
+[want_boost="yes"])
+
+
+AC_ARG_WITH([boost-libdir],
+AS_HELP_STRING([--with-boost-libdir=LIB_DIR],
+[Force given directory for boost libraries. Note that this will 
override library path detection, so use this parameter only if default library 
detection fails and you know exactly where your boost libraries are located.]),
+[
+if test -d "$withval"
+then
+ac_boost_lib_path="$withval"
+else
+AC_MSG_ERROR(--with-boost-libdir expected directory name)
+fi
+],
+[ac_boost_lib_path=""]
+)
+
+if test "x$want_boost" = "xyes"; then
+boost_lib_version_req=ifelse([$1], ,1.20.0,$1)
+boost_lib_version_req_shorten=`expr $boost_lib_version_req : 
'\([[0-9]]*\.[[0-9]]*\)'`
+boost_lib_version_req_major=`expr $boost_lib_version_req : '\([[0-9]]*\)'`
+boost_lib_version_req_minor=`expr $boost_lib_version_req : 
'[[0-9]]*\.\([[0-9]]*\)'`
+boost_lib_version_req_sub_minor=`expr $boost_lib_version_req : 
'[[0-9]]*\.[[0-9]]*\.\([[0-9]]*\)'`
+if test "x$boost_lib_version_req_sub_minor" = "x" ; then
+boost_lib_version_req_sub_minor="0

[Libreoffice-commits] online.git: loleaflet/html wsd/FileServer.cpp wsd/FileServer.hpp

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/html/loleaflet.html.m4 |   30 +++
 wsd/FileServer.cpp   |  160 ++-
 wsd/FileServer.hpp   |1 
 3 files changed, 156 insertions(+), 35 deletions(-)

New commits:
commit ed89931ae8ceff62b720a31cf1e1633280fd
Author: Henry Castro 
AuthorDate: Tue Feb 5 17:03:48 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 16:31:51 2019 -0400

wsd: use a tiny parser, variable substitution

Change-Id: I821d27ef504a01d0b040f2b7ae7f66e75b16eb96

diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index 6f0322d94..82808132e 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -54,12 +54,12 @@ ifelse(MOBILEAPP,[true],
 [syscmd([cat ]BUNDLE_CSS)
   ])],
   [ifelse(DEBUG,[true],
-foreachq([fileCSS],[LOLEAFLET_CSS],[
+foreachq([fileCSS],[LOLEAFLET_CSS],[
   ]),
 [syscmd([cat ]BUNDLE_CSS)
   ])]dnl
 )dnl
- 
+<%BRANDING_CSS%> 
 
 
   
@@ -103,9 +103,9 @@ ifelse(MOBILEAPP,[true],
  
 
 
-
+<%DOCUMENT_SIGNING_DIV%>
 
-  window.documentSigningURL = '%DOCUMENT_SIGNING_URL%';
+  window.documentSigningURL = '<%DOCUMENT_SIGNING_URL%>';
 
 
 
@@ -155,14 +155,14 @@ ifelse(MOBILEAPP,[true],
   window.outOfFocusTimeoutSecs = 100;
   window.idleTimeoutSecs = 100;
   window.tileSize = 256;],
- [window.host = '%HOST%';
-  window.serviceRoot = '%SERVICE_ROOT%';
-  window.accessToken = '%ACCESS_TOKEN%';
-  window.accessTokenTTL = '%ACCESS_TOKEN_TTL%';
-  window.accessHeader = '%ACCESS_HEADER%';
-  window.loleafletLogging = '%LOLEAFLET_LOGGING%';
-  window.outOfFocusTimeoutSecs = %OUT_OF_FOCUS_TIMEOUT_SECS%;
-  window.idleTimeoutSecs = %IDLE_TIMEOUT_SECS%;
+ [window.host = '<%HOST%>';
+  window.serviceRoot = '<%SERVICE_ROOT%>';
+  window.accessToken = '<%ACCESS_TOKEN%>';
+  window.accessTokenTTL = '<%ACCESS_TOKEN_TTL%>';
+  window.accessHeader = '<%ACCESS_HEADER%>';
+  window.loleafletLogging = '<%LOLEAFLET_LOGGING%>';
+  window.outOfFocusTimeoutSecs = <%OUT_OF_FOCUS_TIMEOUT_SECS%>;
+  window.idleTimeoutSecs = <%IDLE_TIMEOUT_SECS%>;
   window.tileSize = 256;])
 syscmd([cat ]GLOBAL_JS)dnl
 syscmd([cat ]L10N_JS)dnl
@@ -210,10 +210,10 @@ ifelse(MOBILEAPP,[true],
   [
   ]),
   ifelse(DEBUG,[true],foreachq([fileJS],[LOLEAFLET_JS],
-  [
+  [
   ]),
-  [
+  [
   ])
 )dnl
- 
+<%BRANDING_JS%> 
 
diff --git a/wsd/FileServer.cpp b/wsd/FileServer.cpp
index 07ee9c4cd..7c297deb1 100644
--- a/wsd/FileServer.cpp
+++ b/wsd/FileServer.cpp
@@ -567,6 +567,26 @@ constexpr char BRANDING[] = "branding";
 constexpr char BRANDING_UNSUPPORTED[] = "branding-unsupported";
 #endif
 
+void FileServerRequestHandler::getToken(std::istream& istr, std::string& token)
+{
+token.clear();
+int chr = istr.get();
+if (chr != -1)
+{
+if (chr == '<' && istr.peek() == '%')
+{
+token += "<%";
+istr.get();
+}
+else if (chr == '%' && istr.peek() == '>')
+{
+token += "%>";
+istr.get();
+}
+else token += (char) chr;
+}
+}
+
 void FileServerRequestHandler::preprocessFile(const HTTPRequest& request, 
Poco::MemoryInputStream& message, const std::shared_ptr& socket)
 {
 const auto host = ((LOOLWSD::isSSLEnabled() || 
LOOLWSD::isSSLTermination()) ? "wss://" : "ws://") + 
(LOOLWSD::ServerName.empty() ? request.getHost() : LOOLWSD::ServerName);
@@ -611,13 +631,6 @@ void FileServerRequestHandler::preprocessFile(const 
HTTPRequest& request, Poco::
 }
 }
 
-Poco::replaceInPlace(preprocess, std::string("%ACCESS_TOKEN%"), 
escapedAccessToken);
-Poco::replaceInPlace(preprocess, std::string("%ACCESS_TOKEN_TTL%"), 
std::to_string(tokenTtl));
-Poco::replaceInPlace(preprocess, std::string("%ACCESS_HEADER%"), 
escapedAccessHeader);
-Poco::replaceInPlace(preprocess, std::string("%HOST%"), host);
-Poco::replaceInPlace(preprocess, std::string("%VERSION%"), 
std::string(LOOLWSD_VERSION_HASH));
-Poco::replaceInPlace(preprocess, std::string("%SERVICE_ROOT%"), 
LOOLWSD::ServiceRoot);
-
 static const std::string linkCSS("");
 static const std::string scriptJS("");
 
@@ -635,9 +648,6 @@ void FileServerRequestHandler::preprocessFile(const 
HTTPRequest& request, Poco::
 }
 #endif
 
-Poco::replaceInPlace(preprocess, std::string(""), 
brandCSS);
-Poco::replaceInPlace(preprocess, std::string(""), 
brandJS);
-
 // Customization related to document signing.
 std::string documentSigningDiv;
 const std::string documentSigningURL = 
config.getString("per_document.document_signing_url", "");
@@ -645,15 +655,125 @@ void FileServerRequestHandler::preprocessFile(const 
HTTPRequest& request, Poco::
 {
 documentSigningDiv = "";
 }
-Poco::replaceInPlace(preprocess, 
std::string(""), documentSi

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

2019-03-05 Thread Libreoffice Gerrit user
 vcl/inc/WidgetThemeLibraryTypes.hxx |9 +++--
 1 file changed, 3 insertions(+), 6 deletions(-)

New commits:
commit 64d287805dd941508a4fa9a9054e687212d4a6d4
Author: Stephan Bergmann 
AuthorDate: Tue Mar 5 15:37:31 2019 +0100
Commit: Stephan Bergmann 
CommitDate: Tue Mar 5 21:29:13 2019 +0100

Use o3tl::is_typed_flags for ControlState

Change-Id: If54f385e8c7e19106f03f4a52f99bc50b4878f37
Reviewed-on: https://gerrit.libreoffice.org/68760
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 

diff --git a/vcl/inc/WidgetThemeLibraryTypes.hxx 
b/vcl/inc/WidgetThemeLibraryTypes.hxx
index 91116fd6b44a..a00a867d7887 100644
--- a/vcl/inc/WidgetThemeLibraryTypes.hxx
+++ b/vcl/inc/WidgetThemeLibraryTypes.hxx
@@ -12,7 +12,8 @@
 #define INCLUDED_VCL_INC_WIDGETTHEMETYPES_HXX
 
 #include 
-#include  // Used for enum operator
+
+#include 
 
 /**
  * These types are all based on the supported variants
@@ -216,11 +217,7 @@ enum class ControlState {
 CACHING_ALLOWED = 0x8000,  ///< Set when the control is completely visible 
(i.e. not clipped).
 };
 
-inline bool operator& (const ControlState& lhs, const ControlState& rhs)
-{
-return static_cast::type>(lhs)
-   & static_cast::type>(rhs);
-}
+template<> struct o3tl::typed_flags: 
o3tl::is_typed_flags {};
 
 /* ButtonValue:
  *
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 sdext/source/minimizer/optimizerdialog.cxx |   28 +---
 1 file changed, 17 insertions(+), 11 deletions(-)

New commits:
commit 7cefe392e37d82d5df9d7a0b1462b1121bd7ef1b
Author: Matteo Casalin 
AuthorDate: Sun Feb 10 16:28:30 2019 +0100
Commit: Matteo Casalin 
CommitDate: Tue Mar 5 20:47:37 2019 +0100

OptimizerDialog: use local method to reduce OUString operations

Change-Id: I356693ba9992c691c9079b3eaa2f26e57b005e1c
Reviewed-on: https://gerrit.libreoffice.org/67640
Tested-by: Jenkins
Reviewed-by: Matteo Casalin 

diff --git a/sdext/source/minimizer/optimizerdialog.cxx 
b/sdext/source/minimizer/optimizerdialog.cxx
index 3da7dc6c2d93..eb9670a31464 100644
--- a/sdext/source/minimizer/optimizerdialog.cxx
+++ b/sdext/source/minimizer/optimizerdialog.cxx
@@ -711,6 +711,18 @@ void TextListenerFormattedField0Pg1::disposing( const 
css::lang::EventObject& /*
 {
 }
 
+namespace
+{
+
+bool lcl_mapResolution(OUString& rResolution, const OUString& rImageResolution)
+{
+if (rImageResolution.getToken(1, ';')!=rResolution)
+return false;
+rResolution = rImageResolution.getToken(0, ';');
+return true;
+}
+
+}
 
 void TextListenerComboBox0Pg1::textChanged( const TextEvent& /* rEvent */ )
 {
@@ -719,17 +731,11 @@ void TextListenerComboBox0Pg1::textChanged( const 
TextEvent& /* rEvent */ )
 if ( !(aAny >>= aString) )
 return;
 
-sal_Int32 nI0, nI1, nI2, nI3, nI4;
-nI0 = nI1 = nI2 = nI3 = nI4 = 0;
-
-if ( mrOptimizerDialog.getString( STR_IMAGE_RESOLUTION_0 ).getToken( 1, 
';', nI0 ) == aString )
-aString = mrOptimizerDialog.getString( STR_IMAGE_RESOLUTION_0 
).getToken( 0, ';', nI4 );
-else if ( mrOptimizerDialog.getString( STR_IMAGE_RESOLUTION_1 ).getToken( 
1, ';', nI1 ) == aString )
-aString = mrOptimizerDialog.getString( STR_IMAGE_RESOLUTION_1 
).getToken( 0, ';', nI4 );
-else if ( mrOptimizerDialog.getString( STR_IMAGE_RESOLUTION_2 ).getToken( 
1, ';', nI2 ) == aString )
-aString = mrOptimizerDialog.getString( STR_IMAGE_RESOLUTION_2 
).getToken( 0, ';', nI4 );
-else if ( mrOptimizerDialog.getString( STR_IMAGE_RESOLUTION_3 ).getToken( 
1, ';', nI3 ) == aString )
-aString = mrOptimizerDialog.getString( STR_IMAGE_RESOLUTION_3 
).getToken( 0, ';', nI4 );
+for (int nIR{ STR_IMAGE_RESOLUTION_0 }; nIR <= STR_IMAGE_RESOLUTION_3; 
++nIR)
+{
+if (lcl_mapResolution(aString, 
mrOptimizerDialog.getString(static_cast(nIR
+break;
+}
 
 mrOptimizerDialog.SetConfigProperty( TK_ImageResolution, Any( 
aString.toInt32() ) );
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am |6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit 88a8810ee79215f706c3394bf92072a9dea2c068
Author: Henry Castro 
AuthorDate: Fri Feb 1 10:59:29 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 15:40:59 2019 -0400

loleaflet: minify l10n files

Change-Id: I811d945e6767a0716244f8b1f42a8e1f2b727775

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index a1b860762..7f90ca147 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -336,9 +336,13 @@ $(builddir)/dist/images/%.png: 
$(JQUERY_MINIFIED_IMAGE_PATH)/%.png
@mkdir -p $(dir $@)
@cp $< $@
 
-$(builddir)/dist/l10n/%: $(srcdir)/l10n/%
+$(builddir)/dist/l10n/%.json: $(srcdir)/l10n/%.json
@mkdir -p $(dir $@)
+if ENABLE_DEBUG
@cp $< $@
+else
+   @tr -d '[:space:]' <$<  >$@
+endif
 
 $(builddir)/dist/l10n/%.json: $(srcdir)/po/%.po
@$(srcdir)/util/po2json.py $< -o $@
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am |4 
 1 file changed, 4 insertions(+)

New commits:
commit 3aebf7fea9561416a7c904a16712dba254120989
Author: Henry Castro 
AuthorDate: Thu Jan 31 15:43:22 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 15:32:59 2019 -0400

loleaflet: uglify l10n.js

Change-Id: I050d6d82e9d6b3df3cd51426931136b3f14eb730

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index ca8f63f3c..a1b860762 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -231,6 +231,10 @@ $(builddir)/dist/global.js: $(srcdir)/js/global.js
@echo "Uglify global.js file..."
@NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
node_modules/uglify-js/bin/uglifyjs $< --output $@
 
+$(builddir)/dist/l10n.js: $(srcdir)/js/l10n.js
+   @echo "Uglify l10n.js file..."
+   @NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
node_modules/uglify-js/bin/uglifyjs $< --output $@
+
 $(builddir)/dist/bundle.js: $(NODE_MODULES_JS_SRC) \
$(LOLEAFLET_PREFIX)/dist/loleaflet-src.js \
$(builddir)/dist/global.js \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 vcl/source/gdi/FileDefinitionWidgetDraw.cxx   |   21 -
 vcl/source/gdi/WidgetDefinitionReader.cxx |2 +-
 vcl/uiconfig/theme_definitions/definition.xml |8 
 3 files changed, 29 insertions(+), 2 deletions(-)

New commits:
commit 5c124597d0446bbb7cb0672a6335ebcd68520e00
Author: Tomaž Vajngerl 
AuthorDate: Tue Feb 19 14:21:42 2019 +0100
Commit: Tomaž Vajngerl 
CommitDate: Tue Mar 5 20:24:32 2019 +0100

Draw basic progress from the theme definition

Change-Id: If2c6f434dd64cf1b3bab340dc6c4d73f439bcfdf
Reviewed-on: https://gerrit.libreoffice.org/68751
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 

diff --git a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx 
b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
index 14477ef40ec5..7fa086bbd854 100644
--- a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
+++ b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
@@ -87,8 +87,10 @@ bool 
FileDefinitionWidgetDraw::isNativeControlSupported(ControlType eType, Contr
 case ControlType::Toolbar:
 case ControlType::Menubar:
 case ControlType::MenuPopup:
+return false;
 case ControlType::Progress:
 case ControlType::IntroProgress:
+return true;
 case ControlType::Tooltip:
 case ControlType::WindowBackground:
 case ControlType::Frame:
@@ -478,7 +480,24 @@ bool 
FileDefinitionWidgetDraw::drawNativeControl(ControlType eType, ControlPart
 break;
 case ControlType::Progress:
 case ControlType::IntroProgress:
-break;
+{
+std::shared_ptr pPart
+= m_aWidgetDefinition.getDefinition(eType, ePart);
+if (pPart)
+{
+auto aStates = pPart->getStates(eState, rValue);
+if (!aStates.empty())
+{
+std::shared_ptr pState = 
aStates.back();
+{
+munchDrawCommands(pState->mpDrawCommands, m_rGraphics, 
nX, nY, nWidth,
+  nHeight);
+bOK = true;
+}
+}
+}
+}
+break;
 case ControlType::Tooltip:
 break;
 case ControlType::WindowBackground:
diff --git a/vcl/source/gdi/WidgetDefinitionReader.cxx 
b/vcl/source/gdi/WidgetDefinitionReader.cxx
index 8be78889e990..3d210b1d88cd 100644
--- a/vcl/source/gdi/WidgetDefinitionReader.cxx
+++ b/vcl/source/gdi/WidgetDefinitionReader.cxx
@@ -137,7 +137,7 @@ bool getControlTypeForXmlString(OString const& rString, 
ControlType& reType)
 { "checkbox", ControlType::Checkbox }, { "combobox", 
ControlType::Combobox },
 { "editbox", ControlType::Editbox },   { "scrollbar", 
ControlType::Scrollbar },
 { "spinbox", ControlType::Spinbox },   { "slider", 
ControlType::Slider },
-{ "fixedline", ControlType::Fixedline } };
+{ "fixedline", ControlType::Fixedline },   { "progress", 
ControlType::Progress } };
 
 auto const& rIterator = aPartMap.find(rString);
 if (rIterator != aPartMap.end())
diff --git a/vcl/uiconfig/theme_definitions/definition.xml 
b/vcl/uiconfig/theme_definitions/definition.xml
index 8adfc76ae6b1..8aa959ab314e 100644
--- a/vcl/uiconfig/theme_definitions/definition.xml
+++ b/vcl/uiconfig/theme_definitions/definition.xml
@@ -214,4 +214,12 @@
 
 
 
+
+
+
+
+
+
+
+
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 vcl/source/gdi/FileDefinitionWidgetDraw.cxx |  215 +---
 1 file changed, 44 insertions(+), 171 deletions(-)

New commits:
commit 45511b361a211d463734f50297f62e62a275e2d3
Author: Tomaž Vajngerl 
AuthorDate: Wed Feb 20 11:48:14 2019 +0100
Commit: Tomaž Vajngerl 
CommitDate: Tue Mar 5 20:25:29 2019 +0100

deal with code duplication at drawing from a definition file

Change-Id: Ie2f6ace37562a251d639c5049c91a4ba09576c0b
Reviewed-on: https://gerrit.libreoffice.org/68754
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 

diff --git a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx 
b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
index fc86eb547f0c..d0743208f6fc 100644
--- a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
+++ b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
@@ -259,85 +259,34 @@ bool 
FileDefinitionWidgetDraw::drawNativeControl(ControlType eType, ControlPart
 break;
 case ControlType::Pushbutton:
 {
-std::shared_ptr pPart
-= m_aWidgetDefinition.getDefinition(eType, ePart);
-if (pPart)
-{
-auto aStates = pPart->getStates(eState, rValue);
-if (!aStates.empty())
-{
-std::shared_ptr pState = 
aStates.back();
-{
-munchDrawCommands(pState->mpDrawCommands, m_rGraphics, 
nX, nY, nWidth,
-  nHeight);
-bOK = true;
-}
-}
-}
+/*bool bIsAction = false;
+const PushButtonValue* pPushButtonValue = static_cast(&rValue);
+if (pPushButtonValue)
+bIsAction = pPushButtonValue->mbIsAction;*/
+
+bOK = resolveDefinition(eType, ePart, eState, rValue, nX, nY, 
nWidth, nHeight);
 }
 break;
 case ControlType::Radiobutton:
 {
-std::shared_ptr pPart
-= m_aWidgetDefinition.getDefinition(eType, ePart);
-if (pPart)
-{
-std::shared_ptr pState
-= pPart->getStates(eState, rValue).back();
-{
-munchDrawCommands(pState->mpDrawCommands, m_rGraphics, nX, 
nY, nWidth, nHeight);
-bOK = true;
-}
-}
+bOK = resolveDefinition(eType, ePart, eState, rValue, nX, nY, 
nWidth, nHeight);
 }
 break;
 case ControlType::Checkbox:
 {
-std::shared_ptr pPart
-= m_aWidgetDefinition.getDefinition(eType, ePart);
-if (pPart)
-{
-auto aStates = pPart->getStates(eState, rValue);
-if (!aStates.empty())
-{
-std::shared_ptr pState = 
aStates.back();
-munchDrawCommands(pState->mpDrawCommands, m_rGraphics, nX, 
nY, nWidth, nHeight);
-bOK = true;
-}
-}
+bOK = resolveDefinition(eType, ePart, eState, rValue, nX, nY, 
nWidth, nHeight);
 }
 break;
 case ControlType::Combobox:
 {
-std::shared_ptr pPart
-= m_aWidgetDefinition.getDefinition(eType, ePart);
-if (pPart)
-{
-auto aStates = pPart->getStates(eState, rValue);
-if (!aStates.empty())
-{
-std::shared_ptr pState = 
aStates.back();
-munchDrawCommands(pState->mpDrawCommands, m_rGraphics, nX, 
nY, nWidth, nHeight);
-bOK = true;
-}
-}
+bOK = resolveDefinition(eType, ePart, eState, rValue, nX, nY, 
nWidth, nHeight);
 }
 break;
 case ControlType::Editbox:
 case ControlType::EditboxNoBorder:
 case ControlType::MultilineEditbox:
 {
-std::shared_ptr pPart
-= m_aWidgetDefinition.getDefinition(eType, ePart);
-if (pPart)
-{
-std::shared_ptr pState
-= pPart->getStates(eState, rValue).back();
-{
-munchDrawCommands(pState->mpDrawCommands, m_rGraphics, nX, 
nY, nWidth, nHeight);
-bOK = true;
-}
-}
+bOK = resolveDefinition(eType, ePart, eState, rValue, nX, nY, 
nWidth, nHeight);
 }
 break;
 case ControlType::Listbox:
@@ -348,61 +297,38 @@ bool 
FileDefinitionWidgetDraw::drawNativeControl(ControlType eType, ControlPart
 {
 const SpinbuttonValue* pSpinVal = static_cast(&rValue);
 
-ControlPart eUpButtonPart = pSpinVal->mnUpperPart;
-ControlState eUpButtonState = pSpinVal->mnUpperState;
+{
+ControlPart eUpButtonPart = pSpinVal-

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

2019-03-05 Thread Libreoffice Gerrit user
 vcl/Package_theme_definitions.mk  |2 +
 vcl/source/gdi/FileDefinitionWidgetDraw.cxx   |2 -
 vcl/uiconfig/theme_definitions/definition.xml |   23 ++
 vcl/uiconfig/theme_definitions/spinbox-left.svgx  |4 +++
 vcl/uiconfig/theme_definitions/spinbox-right.svgx |4 +++
 5 files changed, 34 insertions(+), 1 deletion(-)

New commits:
commit 07cb5f46a13296cd9c84ddbbff161e5a81dd52ea
Author: Tomaž Vajngerl 
AuthorDate: Tue Feb 19 14:38:49 2019 +0100
Commit: Tomaž Vajngerl 
CommitDate: Tue Mar 5 20:25:12 2019 +0100

Add spinbox SVG buttons, but use a definition draw for now

Change-Id: Iff40c7c315ed2473e7a5bd84a6449aedcf646e2f
Reviewed-on: https://gerrit.libreoffice.org/68753
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 

diff --git a/vcl/Package_theme_definitions.mk b/vcl/Package_theme_definitions.mk
index 2e0ffa688fae..e28ae0911733 100644
--- a/vcl/Package_theme_definitions.mk
+++ b/vcl/Package_theme_definitions.mk
@@ -23,6 +23,8 @@ $(eval $(call 
gb_Package_add_files,vcl_theme_definitions,$(LIBO_SHARE_FOLDER)/th
tick-on.svgx \
tick-on-pressed.svgx \
tick-on-disabled.svgx \
+   spinbox-left.svgx \
+   spinbox-right.svgx \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx 
b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
index f2db60e4b5f0..fc86eb547f0c 100644
--- a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
+++ b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
@@ -534,7 +534,7 @@ bool FileDefinitionWidgetDraw::getNativeControlRegion(
 {
 case ControlType::Spinbox:
 {
-Size aButtonSize(44, 26);
+Size aButtonSize(32, 32);
 Point aLocation(rBoundingControlRegion.TopLeft());
 
 if (ePart == ControlPart::ButtonUp)
diff --git a/vcl/uiconfig/theme_definitions/definition.xml 
b/vcl/uiconfig/theme_definitions/definition.xml
index 13859cfa3833..308bec61f614 100644
--- a/vcl/uiconfig/theme_definitions/definition.xml
+++ b/vcl/uiconfig/theme_definitions/definition.xml
@@ -140,6 +140,29 @@
 
 
 
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
 
 
 
diff --git a/vcl/uiconfig/theme_definitions/spinbox-left.svgx 
b/vcl/uiconfig/theme_definitions/spinbox-left.svgx
new file mode 100644
index ..3f98280a106b
--- /dev/null
+++ b/vcl/uiconfig/theme_definitions/spinbox-left.svgx
@@ -0,0 +1,4 @@
+http://www.w3.org/2000/svg";>
+ 
+ 
+
diff --git a/vcl/uiconfig/theme_definitions/spinbox-right.svgx 
b/vcl/uiconfig/theme_definitions/spinbox-right.svgx
new file mode 100644
index ..07ce83c388db
--- /dev/null
+++ b/vcl/uiconfig/theme_definitions/spinbox-right.svgx
@@ -0,0 +1,4 @@
+http://www.w3.org/2000/svg";>
+ 
+ 
+
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 vcl/source/gdi/FileDefinitionWidgetDraw.cxx   |   21 ++-
 vcl/source/gdi/WidgetDefinitionReader.cxx |4 ++
 vcl/uiconfig/theme_definitions/definition.xml |   35 ++
 3 files changed, 58 insertions(+), 2 deletions(-)

New commits:
commit 67b6b526dd759d28c554880b2e728ca99c6cce7b
Author: Tomaž Vajngerl 
AuthorDate: Tue Feb 19 14:26:40 2019 +0100
Commit: Tomaž Vajngerl 
CommitDate: Tue Mar 5 20:24:51 2019 +0100

Draw basic tabbar widgets from the theme definition

Change-Id: I51f8868abff3f3e38bd70ea1fc99a9cf5aca92a6
Reviewed-on: https://gerrit.libreoffice.org/68752
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 

diff --git a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx 
b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
index 7fa086bbd854..f2db60e4b5f0 100644
--- a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
+++ b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
@@ -45,6 +45,10 @@ 
FileDefinitionWidgetDraw::FileDefinitionWidgetDraw(SalGraphics& rGraphics)
 ImplSVData* pSVData = ImplGetSVData();
 pSVData->maNWFData.mbNoFocusRects = true;
 pSVData->maNWFData.mbNoFocusRectsForFlatButtons = true;
+pSVData->maNWFData.mbNoActiveTabTextRaise = true;
+pSVData->maNWFData.mbCenteredTabs = true;
+pSVData->maNWFData.mbProgressNeedsErase = true;
+pSVData->maNWFData.mnStatusBarLowerRightOffset = 10;
 }
 
 bool FileDefinitionWidgetDraw::isNativeControlSupported(ControlType eType, 
ControlPart ePart)
@@ -71,11 +75,12 @@ bool 
FileDefinitionWidgetDraw::isNativeControlSupported(ControlType eType, Contr
 return false;
 return true;
 case ControlType::SpinButtons:
+return false;
 case ControlType::TabItem:
 case ControlType::TabPane:
 case ControlType::TabHeader:
 case ControlType::TabBody:
-return false;
+return true;
 case ControlType::Scrollbar:
 if (ePart == ControlPart::DrawBackgroundHorz
 || ePart == ControlPart::DrawBackgroundVert)
@@ -402,9 +407,15 @@ bool 
FileDefinitionWidgetDraw::drawNativeControl(ControlType eType, ControlPart
 }
 break;
 case ControlType::SpinButtons:
+break;
 case ControlType::TabItem:
+case ControlType::TabHeader:
 case ControlType::TabPane:
 case ControlType::TabBody:
+{
+bOK = resolveDefinition(eType, ePart, eState, rValue, nX, nY, 
nWidth, nHeight);
+}
+break;
 case ControlType::Scrollbar:
 {
 bOK = resolveDefinition(eType, ePart, eState, rValue, nX, nY, 
nWidth, nHeight);
@@ -568,6 +579,14 @@ bool FileDefinitionWidgetDraw::getNativeControlRegion(
 case ControlType::Radiobutton:
 rNativeContentRegion = tools::Rectangle(Point(), Size(32, 32));
 return true;
+case ControlType::TabItem:
+{
+rNativeBoundingRegion = 
tools::Rectangle(rBoundingControlRegion.TopLeft(),
+ 
Size(rBoundingControlRegion.GetWidth() + 20,
+  
rBoundingControlRegion.GetHeight() + 6));
+rNativeContentRegion = rNativeBoundingRegion;
+return true;
+}
 default:
 break;
 }
diff --git a/vcl/source/gdi/WidgetDefinitionReader.cxx 
b/vcl/source/gdi/WidgetDefinitionReader.cxx
index 3d210b1d88cd..351d0fcdc9ef 100644
--- a/vcl/source/gdi/WidgetDefinitionReader.cxx
+++ b/vcl/source/gdi/WidgetDefinitionReader.cxx
@@ -137,7 +137,9 @@ bool getControlTypeForXmlString(OString const& rString, 
ControlType& reType)
 { "checkbox", ControlType::Checkbox }, { "combobox", 
ControlType::Combobox },
 { "editbox", ControlType::Editbox },   { "scrollbar", 
ControlType::Scrollbar },
 { "spinbox", ControlType::Spinbox },   { "slider", 
ControlType::Slider },
-{ "fixedline", ControlType::Fixedline },   { "progress", 
ControlType::Progress } };
+{ "fixedline", ControlType::Fixedline },   { "progress", 
ControlType::Progress },
+{ "tabitem", ControlType::TabItem },   { "tabheader", 
ControlType::TabHeader },
+{ "tabpane", ControlType::TabPane },   { "tabbody", 
ControlType::TabBody } };
 
 auto const& rIterator = aPartMap.find(rString);
 if (rIterator != aPartMap.end())
diff --git a/vcl/uiconfig/theme_definitions/definition.xml 
b/vcl/uiconfig/theme_definitions/definition.xml
index 8aa959ab314e..13859cfa3833 100644
--- a/vcl/uiconfig/theme_definitions/definition.xml
+++ b/vcl/uiconfig/theme_definitions/definition.xml
@@ -222,4 +222,39 @@
 
 
 
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+  

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

2019-03-05 Thread Libreoffice Gerrit user
 vcl/inc/FileDefinitionWidgetDraw.hxx  |4 ++
 vcl/source/gdi/FileDefinitionWidgetDraw.cxx   |   34 +++-
 vcl/uiconfig/theme_definitions/definition.xml |   43 ++
 3 files changed, 79 insertions(+), 2 deletions(-)

New commits:
commit ae9eab1cf666a6cf58cc473e4e5bdd92088fbd30
Author: Tomaž Vajngerl 
AuthorDate: Tue Feb 19 14:12:42 2019 +0100
Commit: Tomaž Vajngerl 
CommitDate: Tue Mar 5 20:23:55 2019 +0100

Draw basic scrollbar from the theme definition

Change-Id: I2a017746f02c547413c949a1728ebbfa781a7f66
Reviewed-on: https://gerrit.libreoffice.org/68749
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 

diff --git a/vcl/inc/FileDefinitionWidgetDraw.hxx 
b/vcl/inc/FileDefinitionWidgetDraw.hxx
index ba34cbe13467..dc3ee7f8967c 100644
--- a/vcl/inc/FileDefinitionWidgetDraw.hxx
+++ b/vcl/inc/FileDefinitionWidgetDraw.hxx
@@ -24,6 +24,10 @@ private:
 SalGraphics& m_rGraphics;
 WidgetDefinition m_aWidgetDefinition;
 
+bool resolveDefinition(ControlType eType, ControlPart ePart, ControlState 
eState,
+   const ImplControlValue& rValue, long nX, long nY, 
long nWidth,
+   long nHeight);
+
 public:
 FileDefinitionWidgetDraw(SalGraphics& rGraphics);
 
diff --git a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx 
b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
index bb6756bf1b9c..317cb3455641 100644
--- a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
+++ b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
@@ -75,8 +75,12 @@ bool 
FileDefinitionWidgetDraw::isNativeControlSupported(ControlType eType, Contr
 case ControlType::TabPane:
 case ControlType::TabHeader:
 case ControlType::TabBody:
-case ControlType::Scrollbar:
 return false;
+case ControlType::Scrollbar:
+if (ePart == ControlPart::DrawBackgroundHorz
+|| ePart == ControlPart::DrawBackgroundVert)
+return false;
+return true;
 case ControlType::Slider:
 return true;
 case ControlType::Fixedline:
@@ -201,6 +205,29 @@ void 
munchDrawCommands(std::vector> const& rDrawCom
 
 } // end anonymous namespace
 
+bool FileDefinitionWidgetDraw::resolveDefinition(ControlType eType, 
ControlPart ePart,
+ ControlState eState,
+ const ImplControlValue& 
rValue, long nX, long nY,
+ long nWidth, long nHeight)
+{
+bool bOK = false;
+auto const& pPart = m_aWidgetDefinition.getDefinition(eType, ePart);
+if (pPart)
+{
+auto const& aStates = pPart->getStates(eState, rValue);
+if (!aStates.empty())
+{
+// use last defined state
+auto const& pState = aStates.back();
+{
+munchDrawCommands(pState->mpDrawCommands, m_rGraphics, nX, nY, 
nWidth, nHeight);
+bOK = true;
+}
+}
+}
+return bOK;
+}
+
 bool FileDefinitionWidgetDraw::drawNativeControl(ControlType eType, 
ControlPart ePart,
  const tools::Rectangle& 
rControlRegion,
  ControlState eState,
@@ -377,7 +404,10 @@ bool 
FileDefinitionWidgetDraw::drawNativeControl(ControlType eType, ControlPart
 case ControlType::TabPane:
 case ControlType::TabBody:
 case ControlType::Scrollbar:
-break;
+{
+bOK = resolveDefinition(eType, ePart, eState, rValue, nX, nY, 
nWidth, nHeight);
+}
+break;
 case ControlType::Slider:
 {
 {
diff --git a/vcl/uiconfig/theme_definitions/definition.xml 
b/vcl/uiconfig/theme_definitions/definition.xml
index 1286ea7fb8c9..e57404c94013 100644
--- a/vcl/uiconfig/theme_definitions/definition.xml
+++ b/vcl/uiconfig/theme_definitions/definition.xml
@@ -140,6 +140,49 @@
 
 
 
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
 
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 vcl/source/gdi/FileDefinitionWidgetDraw.cxx   |   20 +++-
 vcl/source/gdi/WidgetDefinitionReader.cxx |3 ++-
 vcl/uiconfig/theme_definitions/definition.xml |   13 +
 3 files changed, 34 insertions(+), 2 deletions(-)

New commits:
commit 16d9cfe92a60e3a7ea238ef4a656e5277231b866
Author: Tomaž Vajngerl 
AuthorDate: Tue Feb 19 14:17:54 2019 +0100
Commit: Tomaž Vajngerl 
CommitDate: Tue Mar 5 20:24:14 2019 +0100

Draw basic fixedline from the theme definition

Change-Id: I791d33e4cea14f49609434e39f681cf47864fc67
Reviewed-on: https://gerrit.libreoffice.org/68750
Reviewed-by: Tomaž Vajngerl 
Tested-by: Tomaž Vajngerl 

diff --git a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx 
b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
index 317cb3455641..14477ef40ec5 100644
--- a/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
+++ b/vcl/source/gdi/FileDefinitionWidgetDraw.cxx
@@ -82,8 +82,8 @@ bool 
FileDefinitionWidgetDraw::isNativeControlSupported(ControlType eType, Contr
 return false;
 return true;
 case ControlType::Slider:
-return true;
 case ControlType::Fixedline:
+return true;
 case ControlType::Toolbar:
 case ControlType::Menubar:
 case ControlType::MenuPopup:
@@ -453,6 +453,24 @@ bool 
FileDefinitionWidgetDraw::drawNativeControl(ControlType eType, ControlPart
 }
 break;
 case ControlType::Fixedline:
+{
+std::shared_ptr pPart
+= m_aWidgetDefinition.getDefinition(eType, ePart);
+if (pPart)
+{
+auto aStates = pPart->getStates(eState, rValue);
+if (!aStates.empty())
+{
+std::shared_ptr pState = 
aStates.back();
+{
+munchDrawCommands(pState->mpDrawCommands, m_rGraphics, 
nX, nY, nWidth,
+  nHeight);
+bOK = true;
+}
+}
+}
+}
+break;
 case ControlType::Toolbar:
 case ControlType::Menubar:
 break;
diff --git a/vcl/source/gdi/WidgetDefinitionReader.cxx 
b/vcl/source/gdi/WidgetDefinitionReader.cxx
index 9e4ed46f6f36..8be78889e990 100644
--- a/vcl/source/gdi/WidgetDefinitionReader.cxx
+++ b/vcl/source/gdi/WidgetDefinitionReader.cxx
@@ -136,7 +136,8 @@ bool getControlTypeForXmlString(OString const& rString, 
ControlType& reType)
 = { { "pushbutton", ControlType::Pushbutton }, { "radiobutton", 
ControlType::Radiobutton },
 { "checkbox", ControlType::Checkbox }, { "combobox", 
ControlType::Combobox },
 { "editbox", ControlType::Editbox },   { "scrollbar", 
ControlType::Scrollbar },
-{ "spinbox", ControlType::Spinbox },   { "slider", 
ControlType::Slider } };
+{ "spinbox", ControlType::Spinbox },   { "slider", 
ControlType::Slider },
+{ "fixedline", ControlType::Fixedline } };
 
 auto const& rIterator = aPartMap.find(rString);
 if (rIterator != aPartMap.end())
diff --git a/vcl/uiconfig/theme_definitions/definition.xml 
b/vcl/uiconfig/theme_definitions/definition.xml
index e57404c94013..8adfc76ae6b1 100644
--- a/vcl/uiconfig/theme_definitions/definition.xml
+++ b/vcl/uiconfig/theme_definitions/definition.xml
@@ -201,4 +201,17 @@
 
 
 
+
+
+
+
+
+
+
+
+
+
+
+
+
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/js loleaflet/src

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/js/l10n.js   |9 -
 loleaflet/src/errormessages.js |7 +--
 2 files changed, 9 insertions(+), 7 deletions(-)

New commits:
commit 668b837c70b1d2e8d13d97c173b7a8131fc75a04
Author: Henry Castro 
AuthorDate: Thu Jan 31 15:35:59 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 15:11:33 2019 -0400

loleaflet: load l10n files according to parameter "lang"

Change-Id: I28e6aafa7446b2ea1edbb42bddb77d6d36e68983

diff --git a/loleaflet/js/l10n.js b/loleaflet/js/l10n.js
index 0057eed74..d9ca75506 100644
--- a/loleaflet/js/l10n.js
+++ b/loleaflet/js/l10n.js
@@ -18,6 +18,7 @@ var
   undef_type = "undefined"
 , string_type = "string"
 , nav = {}
+, lang = {}
 , String_ctr = String
 , has_own_prop = Object.prototype.hasOwnProperty
 , load_queues = {}
@@ -188,6 +189,7 @@ var
 try
 {
 nav = self.navigator;
+lang = self.getParameterByName('lang');
 }
 catch(selfNotFoundException)
 {
@@ -240,7 +242,7 @@ if (!browserless && typeof XMLHttpRequest === undef_type && 
typeof ActiveXObject
 }
 
 String_ctr[$default_locale] = String_ctr[$default_locale] || "";
-String_ctr[$locale] = nav && (nav.language || nav.userLanguage) || "";
+String_ctr[$locale] = nav && lang && (lang) || "en";
 
 if (!browserless || typeof document !== undef_type) {
var
@@ -268,6 +270,11 @@ if (!browserless || typeof document !== undef_type) {
}
}
}
+
+   load(self.__globalL10n);
+   load(self.__locoreL10n);
+   load(self.__helpL10n);
+   load(self.__unoL10n);
 }
 else
 {
diff --git a/loleaflet/src/errormessages.js b/loleaflet/src/errormessages.js
index 3381b9126..c2ac2dd74 100644
--- a/loleaflet/src/errormessages.js
+++ b/loleaflet/src/errormessages.js
@@ -1,15 +1,10 @@
 /* -*- js-indent-level: 8 -*- */
 
-/* global vex _ getParameterByName */
+/* global vex _ */
 var errorMessages = {};
 
 vex.defaultOptions.className = 'vex-theme-plain';
 
-var lang = getParameterByName('lang');
-if (lang) {
-   String.locale = lang;
-}
-
 errorMessages.diskfull = _('No disk space left on server, please contact the 
server administrator to continue.');
 errorMessages.emptyhosturl = _('The host URL is empty. The loolwsd server is 
probably misconfigured, please contact the administrator.');
 errorMessages.limitreached = _('This is an unsupported version of 
{productname}. To avoid the impression that it is suitable for deployment in 
enterprises, this message appears when more than {docs} documents or 
{connections} connections are in use concurrently');
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/html

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/html/loleaflet.html.m4 |   12 
 1 file changed, 12 deletions(-)

New commits:
commit a5536109afc50bca57a5cd39f9a48f2d8d51b1d1
Author: Henry Castro 
AuthorDate: Tue Mar 5 14:59:00 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 15:04:59 2019 -0400

loleaflet: remove 'link rel="localizations"' tags

Change-Id: I4887f36344d70b3c3a1c9e28d1486673199ab169

diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index cdd52297d..6f0322d94 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -60,18 +60,6 @@ ifelse(MOBILEAPP,[true],
   ])]dnl
 )dnl
  
-ifelse(MOBILEAPP,[true],
-  [
-   
-   
-   
-   ],
-  [
-   
-   
-   
-   ]
-)dnl
 
 
   
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/html loleaflet/Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am|4 
 loleaflet/html/loleaflet.html.m4 |   12 ++--
 2 files changed, 14 insertions(+), 2 deletions(-)

New commits:
commit 70bdc4660e53154540781f32007cb044bce131b2
Author: Henry Castro 
AuthorDate: Thu Jan 31 15:33:46 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 14:56:19 2019 -0400

loleaflet: expand l10n files

Change-Id: I091cfefb57c7c5aad7a8256ae2192d62606c773f

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index 8abde148f..ca8f63f3c 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -264,6 +264,10 @@ $(builddir)/dist/loleaflet.html: 
$(srcdir)/html/loleaflet.html.m4 $(LOLEAFLET_HT
-DBUNDLE_CSS="$(abs_builddir)/dist/bundle.css" \
-DGLOBAL_JS="$(abs_builddir)/dist/global.js" \
-DL10N_JS="$(abs_builddir)/dist/l10n.js" \
+   
-DLOCALIZATION_JSON="$(abs_builddir)/dist/l10n/localizations.json" \
+   
-DLOCORE_LOCALIZATION_JSON="$(abs_builddir)/dist/l10n/locore-localizations.json"
 \
+   
-DHELP_LOCALIZATION_JSON="$(abs_builddir)/dist/l10n/help-localizations.json" \
+   
-DUNO_LOCALIZATION_JSON="$(abs_builddir)/dist/l10n/uno-localizations.json" \
-DLOLEAFLET_JS="$(subst $(SPACE),$(COMMA),$(NODE_MODULES_JS) \
$(call LOLEAFLET_JS,$(srcdir)/build/build.js) \
$(patsubst %.js,plugins/draw-$(DRAW_VERSION)/%.js,$(call 
LOLEAFLET_JS,$(srcdir)/plugins/draw-$(DRAW_VERSION)/build/build.js)) \
diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index 85105634d..cdd52297d 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -19,7 +19,7 @@ ifelse(GTKAPP,[true],[define([MOBILEAPP],[true])])
 ifelse(ANDROIDAPP,[true],[define([MOBILEAPP],[true])])
 
 ifelse(MOBILEAPP,[],
-  // Start listening for Host_PostmessageReady message and save the
+[  // Start listening for Host_PostmessageReady message and save the
   // result for future
   window.WOPIpostMessageReady = false;
   var PostMessageReadyListener = function(e) {
@@ -30,7 +30,11 @@ ifelse(MOBILEAPP,[],
 }
   };
   window.addEventListener('message', PostMessageReadyListener, false);
-)dnl
+  window.__globalL10n = syscmd([cat ]LOCALIZATION_JSON);
+  window.__locoreL10n = syscmd([cat ]LOCORE_LOCALIZATION_JSON);
+  window.__helpL10n = syscmd([cat ]HELP_LOCALIZATION_JSON);
+  window.__unoL10n = syscmd([cat ]UNO_LOCALIZATION_JSON);
+])dnl
 
 var Base64ToArrayBuffer = function(base64Str) {
   var binStr = atob(base64Str);
@@ -174,6 +178,10 @@ ifelse(MOBILEAPP,[true],
   window.tileSize = 256;])
 syscmd([cat ]GLOBAL_JS)dnl
 syscmd([cat ]L10N_JS)dnl
+  delete window.__globalL10n;
+  delete window.__locoreL10n;
+  delete window.__helpL10n;
+  delete window.__unoL10n;
 
   

[Libreoffice-commits] online.git: loleaflet/js

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/js/l10n.js |  568 +--
 1 file changed, 284 insertions(+), 284 deletions(-)

New commits:
commit ab2051cd50dc4b1bb6e579fbad15afea5a9cedf1
Author: Henry Castro 
AuthorDate: Wed Jan 30 16:16:07 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 14:38:33 2019 -0400

loleaflet: set format unix l10n.js

Change-Id: Ib5412e83b049954cb0ee56ea91f03289f539175a

diff --git a/loleaflet/js/l10n.js b/loleaflet/js/l10n.js
index 4beab6e7a..0057eed74 100644
--- a/loleaflet/js/l10n.js
+++ b/loleaflet/js/l10n.js
@@ -1,284 +1,284 @@
-/*
- * l10n.js
- * 2016-05-17
- * 
- * By Eli Grey, http://eligrey.com
- * Licensed under the MIT License
- *   See https://github.com/eligrey/l10n.js/blob/master/LICENSE.md
- */
-
-/*global XMLHttpRequest, setTimeout, document, navigator, ActiveXObject*/
-
-/*! @source http://purl.eligrey.com/github/l10n.js/blob/master/l10n.js*/
-
-(function () {
-"use strict";
-
-var
-  undef_type = "undefined"
-, string_type = "string"
-, nav = {}
-, String_ctr = String
-, has_own_prop = Object.prototype.hasOwnProperty
-, load_queues = {}
-, localizations = {}
-, FALSE = !1
-, TRUE = !0
-, browserless = FALSE
-// the official format is application/vnd.oftn.l10n+json, though l10n.js will 
also
-// accept application/x-l10n+json and application/l10n+json
-, l10n_js_media_type = 
/^\s*application\/(?:vnd\.oftn\.|x-)?l10n\+json\s*(?:$|;)/i
-, XHR
-
-// property minification aids
-, $locale = "locale"
-, $default_locale = "defaultLocale"
-, $to_locale_string = "toLocaleString"
-, $to_lowercase = "toLowerCase"
-
-, array_index_of = Array.prototype.indexOf || function (item) {
-   var
- len = this.length
-   , i   = 0
-   ;
-   
-   for (; i < len; i++) {
-   if (i in this && this[i] === item) {
-   return i;
-   }
-   }
-   
-   return -1;
-}
-, request_JSON = function (uri) {
-if(browserless)
-return loadFromDisk(uri);
-
-   var req  = new XHR(),
-   data = {};
-   
-   // sadly, this has to be blocking to allow for a graceful degrading API
-   req.open("GET", uri, FALSE);
-   req.send(null);
-   
-   // Status codes can be inconsistent across browsers so we simply try to 
parse
-   // the response text and catch any errors. This deals with failed 
requests as
-   // well as malformed json files.
-   try {
-   data = JSON.parse(req.responseText);
-   } catch(e) {
-   // warn about error without stopping execution
-   setTimeout(function () {
-   // Error messages are not localized as not to cause an 
infinite loop
-   var l10n_err = new Error("Unable to load localization 
data: " + uri);
-   l10n_err.name = "Localization Error";
-   throw l10n_err;
-   }, 0);
-   }
-
-   return data;
-}
-, load = String_ctr[$to_locale_string] = function (data) {
-   // don't handle function.toLocaleString(indentationAmount:Number)
-   if (arguments.length > 0 && typeof data !== "number") {
-   if (typeof data === string_type) {
-   load(request_JSON(data));
-   } else if (data === FALSE) {
-   // reset all localizations
-   localizations = {};
-   } else {
-   // Extend current localizations instead of completely 
overwriting them
-   var locale, localization, message;
-   for (locale in data) {
-   if (has_own_prop.call(data, locale)) {
-   localization = data[locale];
-   locale = locale[$to_lowercase]();
-   
-   if (!(locale in localizations) || 
localization === FALSE) {
-   // reset locale if not existing 
or reset flag is specified
-   localizations[locale] = {};
-   }
-   
-   if (localization === FALSE) {
-   continue;
-   }
-   
-   // URL specified
-   if (typeof localization === 
string_type) {
-   if 
(String_ctr[$locale][$to_lowercase]().indexOf(locale) === 0) {
-   localization = 
request_JSON(localization);
-   } else {
-   // queue loading locale 
if not

[Libreoffice-commits] online.git: loleaflet/.eslintignore loleaflet/html loleaflet/js loleaflet/Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/.eslintignore  |1 
 loleaflet/Makefile.am|3 
 loleaflet/html/loleaflet.html.m4 |1 
 loleaflet/js/l10n.js |  284 +++
 4 files changed, 289 insertions(+)

New commits:
commit e512924544b44421bb2cb5eb563f7c40249daf8c
Author: Henry Castro 
AuthorDate: Tue Jan 29 14:07:21 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 14:32:28 2019 -0400

loleaflet: execute l10n.js script after html parsing

Change-Id: Ia2be65348aae5ce68a96cbd0ce3ea029062ff48d

diff --git a/loleaflet/.eslintignore b/loleaflet/.eslintignore
index 6f11545b6..e4fc0c88d 100644
--- a/loleaflet/.eslintignore
+++ b/loleaflet/.eslintignore
@@ -5,3 +5,4 @@
 #
 # This is way too ugly for eslint...
 **/js/jquery.mCustomScrollbar.js
+**/js/l10n.js
diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index 36492e912..8abde148f 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -202,6 +202,7 @@ $(builddir)/dist/bundle.css: $(LOLEAFLET_CSS_DST)
 $(builddir)/dist/bundle.js: $(NODE_MODULES_JS_DST) \
$(LOLEAFLET_PREFIX)/dist/loleaflet-src.js \
$(builddir)/dist/global.js \
+   $(builddir)/dist/l10n.js \
$(builddir)/dist/w2ui-1.5.rc1.js \
$(builddir)/dist/toolbar.js \
$(builddir)/dist/main.js
@@ -233,6 +234,7 @@ $(builddir)/dist/global.js: $(srcdir)/js/global.js
 $(builddir)/dist/bundle.js: $(NODE_MODULES_JS_SRC) \
$(LOLEAFLET_PREFIX)/dist/loleaflet-src.js \
$(builddir)/dist/global.js \
+   $(builddir)/dist/l10n.js \
$(srcdir)/js/jquery.mCustomScrollbar.js \
$(srcdir)/js/w2ui-1.5.rc1.js \
$(srcdir)/js/toolbar.js \
@@ -261,6 +263,7 @@ $(builddir)/dist/loleaflet.html: 
$(srcdir)/html/loleaflet.html.m4 $(LOLEAFLET_HT
-DLOLEAFLET_CSS="$(subst 
$(SPACE),$(COMMA),$(LOLEAFLET_CSS_M4))" \
-DBUNDLE_CSS="$(abs_builddir)/dist/bundle.css" \
-DGLOBAL_JS="$(abs_builddir)/dist/global.js" \
+   -DL10N_JS="$(abs_builddir)/dist/l10n.js" \
-DLOLEAFLET_JS="$(subst $(SPACE),$(COMMA),$(NODE_MODULES_JS) \
$(call LOLEAFLET_JS,$(srcdir)/build/build.js) \
$(patsubst %.js,plugins/draw-$(DRAW_VERSION)/%.js,$(call 
LOLEAFLET_JS,$(srcdir)/plugins/draw-$(DRAW_VERSION)/build/build.js)) \
diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index 46e4d7d9c..85105634d 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -173,6 +173,7 @@ ifelse(MOBILEAPP,[true],
   window.idleTimeoutSecs = %IDLE_TIMEOUT_SECS%;
   window.tileSize = 256;])
 syscmd([cat ]GLOBAL_JS)dnl
+syscmd([cat ]L10N_JS)dnl
 
   

[Libreoffice-commits] online.git: loleaflet/Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am |4 
 1 file changed, 4 insertions(+)

New commits:
commit c801696ab1f64715f56d22453deb47db80f6a9cb
Author: Henry Castro 
AuthorDate: Sun Jan 27 16:46:41 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 14:08:53 2019 -0400

loleaflet: uglify global.js file

Change-Id: Ibcc265830c10042a918784b350fe93566147993a

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index bc23ee763..36492e912 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -226,6 +226,10 @@ $(builddir)/dist/bundle.css: $(LOLEAFLET_CSS)
@echo "Uglify loleaflet css files..."
@NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
node_modules/uglifycss/uglifycss $(LOLEAFLET_CSS) > $@
 
+$(builddir)/dist/global.js: $(srcdir)/js/global.js
+   @echo "Uglify global.js file..."
+   @NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
node_modules/uglify-js/bin/uglifyjs $< --output $@
+
 $(builddir)/dist/bundle.js: $(NODE_MODULES_JS_SRC) \
$(LOLEAFLET_PREFIX)/dist/loleaflet-src.js \
$(builddir)/dist/global.js \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/html loleaflet/js loleaflet/Makefile.am loleaflet/src

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am|8 ++
 loleaflet/html/loleaflet.html.m4 |1 
 loleaflet/js/global.js   |   52 +++
 loleaflet/js/main.js |9 ++
 loleaflet/src/core/Socket.js |   12 +
 5 files changed, 76 insertions(+), 6 deletions(-)

New commits:
commit d529a407311c692ecc84de674ded70853490bc38
Author: Henry Castro 
AuthorDate: Sun Jan 27 14:04:26 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 13:55:25 2019 -0400

loleaflet: add javascript websocket bootstrap that...

is executed after parsing html

Change-Id: Ib62de3db2449bbe9dc474469c299036259f8f2de

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index a06a33c72..bc23ee763 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -121,9 +121,6 @@ endif
 NODE_MODULES_JS_SRC = $(patsubst %.js,$(builddir)/%.js,$(NODE_MODULES_JS))
 NODE_MODULES_JS_DST = $(patsubst %.js,$(builddir)/dist/%.js,$(NODE_MODULES_JS))
 
-GLOBAL_JS =\
-   global.js
-
 LOLEAFLET_JS = $(strip $(shell NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
-e "try {console.log(require('$(1)').getFiles().join(' '))} catch(e) {}"))
 LOPLUGIN_JS = $(strip $(shell NODE_PATH=$(abs_builddir)/node_modules $(NODE) 
-e "try {console.log(require('$(1)').deps.join(' '))} catch(e) {}"))
 
@@ -231,7 +228,7 @@ $(builddir)/dist/bundle.css: $(LOLEAFLET_CSS)
 
 $(builddir)/dist/bundle.js: $(NODE_MODULES_JS_SRC) \
$(LOLEAFLET_PREFIX)/dist/loleaflet-src.js \
-   $(srcdir)/js/global.js \
+   $(builddir)/dist/global.js \
$(srcdir)/js/jquery.mCustomScrollbar.js \
$(srcdir)/js/w2ui-1.5.rc1.js \
$(srcdir)/js/toolbar.js \
@@ -259,7 +256,8 @@ $(builddir)/dist/loleaflet.html: 
$(srcdir)/html/loleaflet.html.m4 $(LOLEAFLET_HT
-DMOBILEAPPNAME="$(MOBILE_APP_NAME)" \
-DLOLEAFLET_CSS="$(subst 
$(SPACE),$(COMMA),$(LOLEAFLET_CSS_M4))" \
-DBUNDLE_CSS="$(abs_builddir)/dist/bundle.css" \
-   -DLOLEAFLET_JS="$(subst $(SPACE),$(COMMA),$(GLOBAL_JS) 
$(NODE_MODULES_JS) \
+   -DGLOBAL_JS="$(abs_builddir)/dist/global.js" \
+   -DLOLEAFLET_JS="$(subst $(SPACE),$(COMMA),$(NODE_MODULES_JS) \
$(call LOLEAFLET_JS,$(srcdir)/build/build.js) \
$(patsubst %.js,plugins/draw-$(DRAW_VERSION)/%.js,$(call 
LOLEAFLET_JS,$(srcdir)/plugins/draw-$(DRAW_VERSION)/build/build.js)) \
$(patsubst %.js,plugins/path-transform/%.js,$(call 
LOPLUGIN_JS,$(srcdir)/plugins/path-transform/build/deps.js)) \
diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index ed5cfa40a..46e4d7d9c 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -172,6 +172,7 @@ ifelse(MOBILEAPP,[true],
   window.outOfFocusTimeoutSecs = %OUT_OF_FOCUS_TIMEOUT_SECS%;
   window.idleTimeoutSecs = %IDLE_TIMEOUT_SECS%;
   window.tileSize = 256;])
+syscmd([cat ]GLOBAL_JS)dnl
 
   

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

2019-03-05 Thread Libreoffice Gerrit user
 sw/source/core/txtnode/ndtxt.cxx|3 ---
 sw/source/filter/basflt/shellio.cxx |   17 +
 sw/source/uibase/app/docsh2.cxx |   11 ---
 3 files changed, 17 insertions(+), 14 deletions(-)

New commits:
commit d55e75d9173fd0d5928bae45ed49d3c105140468
Author: Michael Stahl 
AuthorDate: Tue Mar 5 14:12:27 2019 +0100
Commit: Michael Stahl 
CommitDate: Tue Mar 5 18:35:14 2019 +0100

sw_redlinehide: fix RSID related asserts regression

Due to sw_redlinehide the SwTextNode::MakeFrame() is skipped on
SwTextNodes that are merged due to redlining. But then the
IgnoreStart/IgnoreEnd flags on the hints are not initialised and some
assert like assert(pHt->IsFormatIgnoreStart()) fails.

tdf90056-1.odt is an example document.

There doesn't appear to be a convenient place to initialise it per-node
as it is finished; the ODF import inserts APPEND_PARAGRAPH before
inserting the hints themselves.

So remove the initialisation from MakeFrame() and just do it in
SwReader::Read().

Change-Id: Ib33fe3033fc05bd2f5ef2ac8d059d587642ccf48
Reviewed-on: https://gerrit.libreoffice.org/68748
Tested-by: Jenkins
Reviewed-by: Michael Stahl 

diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index 785aac960606..2fbf5a71e60b 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -277,9 +277,6 @@ void SwTextNode::FileLoadedInitHints()
 
 SwContentFrame *SwTextNode::MakeFrame( SwFrame* pSib )
 {
-// fdo#52028: ODF file import does not result in MergePortions being called
-// for every attribute, since that would be inefficient.  So call it here.
-FileLoadedInitHints();
 SwContentFrame *pFrame = new SwTextFrame( this, pSib );
 return pFrame;
 }
diff --git a/sw/source/filter/basflt/shellio.cxx 
b/sw/source/filter/basflt/shellio.cxx
index 1c0d473cbd4c..b8596debc8ee 100644
--- a/sw/source/filter/basflt/shellio.cxx
+++ b/sw/source/filter/basflt/shellio.cxx
@@ -56,6 +56,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -63,6 +64,15 @@
 
 using namespace ::com::sun::star;
 
+static bool sw_MergePortions(SwNode *const& pNode, void *)
+{
+if (pNode->IsTextNode())
+{
+pNode->GetTextNode()->FileLoadedInitHints();
+}
+return true;
+}
+
 ErrCode SwReader::Read( const Reader& rOptions )
 {
 // copy variables
@@ -338,6 +348,13 @@ ErrCode SwReader::Read( const Reader& rOptions )
 }
 }
 
+// fdo#52028: ODF file import does not result in MergePortions being called
+// for every attribute, since that would be inefficient.  So call it here.
+// This is only necessary for formats that may contain RSIDs (ODF,MSO).
+// It's too hard to figure out which nodes were inserted in Insert->File
+// case (redlines, flys, footnotes, header/footer) so just do every node.
+mxDoc->GetNodes().ForEach(&sw_MergePortions);
+
 mxDoc->SetInReading( false );
 mxDoc->SetInXMLImport( false );
 
diff --git a/sw/source/uibase/app/docsh2.cxx b/sw/source/uibase/app/docsh2.cxx
index 13ebc3e7dbe5..e9ebabc6a912 100644
--- a/sw/source/uibase/app/docsh2.cxx
+++ b/sw/source/uibase/app/docsh2.cxx
@@ -1668,15 +1668,6 @@ SfxInPlaceClient* SwDocShell::GetIPClient( const 
::svt::EmbeddedObjectRef& xObjR
 return pResult;
 }
 
-static bool lcl_MergePortions(SwNode *const& pNode, void *)
-{
-if (pNode->IsTextNode())
-{
-pNode->GetTextNode()->FileLoadedInitHints();
-}
-return true;
-}
-
 int SwFindDocShell( SfxObjectShellRef& xDocSh,
 SfxObjectShellLock& xLockRef,
 const OUString& rFileName,
@@ -1767,8 +1758,6 @@ int SwFindDocShell( SfxObjectShellRef& xDocSh,
 xDocSh = static_cast(xLockRef);
 if (xDocSh->DoLoad(xMed.release()))
 {
-SwDoc const& rDoc(*pNew->GetDoc());
-
const_cast(rDoc).GetNodes().ForEach(&lcl_MergePortions);
 return 2;
 }
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 cui/source/customize/cfgutil.cxx |8 
 cui/source/inc/cfgutil.hxx   |4 ++--
 2 files changed, 6 insertions(+), 6 deletions(-)

New commits:
commit d9bd131b11e47c7b1b7f0ae5bc50fff28f157016
Author: Caolán McNamara 
AuthorDate: Mon Mar 4 17:34:02 2019 +
Commit: Caolán McNamara 
CommitDate: Tue Mar 5 17:35:16 2019 +0100

rename CuiConfigGroupBoxResource_Impl back to SvxConfigGroupBoxResource_Impl

Change-Id: I21e9258f5f57acd5e27cee5c1cca37b8b56f3040
Reviewed-on: https://gerrit.libreoffice.org/68702
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/cui/source/customize/cfgutil.cxx b/cui/source/customize/cfgutil.cxx
index 2510066708e8..408612685283 100644
--- a/cui/source/customize/cfgutil.cxx
+++ b/cui/source/customize/cfgutil.cxx
@@ -430,7 +430,7 @@ OUString CuiConfigFunctionListBox::GetSelectedScriptURI()
 return OUString();
 }
 
-struct CuiConfigGroupBoxResource_Impl
+struct SvxConfigGroupBoxResource_Impl
 {
 OUString m_sMyMacros;
 OUString m_sProdMacros;
@@ -438,10 +438,10 @@ struct CuiConfigGroupBoxResource_Impl
 OUString m_sDlgMacros;
 OUString m_aStrGroupStyles;
 
-CuiConfigGroupBoxResource_Impl();
+SvxConfigGroupBoxResource_Impl();
 };
 
-CuiConfigGroupBoxResource_Impl::CuiConfigGroupBoxResource_Impl() :
+SvxConfigGroupBoxResource_Impl::SvxConfigGroupBoxResource_Impl() :
 m_sMyMacros(CuiResId(RID_SVXSTR_MYMACROS)),
 m_sProdMacros(CuiResId(RID_SVXSTR_PRODMACROS)),
 m_sMacros(CuiResId(RID_SVXSTR_BASICMACROS)),
@@ -508,7 +508,7 @@ namespace
 }
 
 CuiConfigGroupListBox::CuiConfigGroupListBox(std::unique_ptr 
xTreeView)
-: xImp(new CuiConfigGroupBoxResource_Impl())
+: xImp(new SvxConfigGroupBoxResource_Impl())
 , m_pFunctionListBox(nullptr)
 , m_pStylesInfo(nullptr)
 , m_xTreeView(std::move(xTreeView))
diff --git a/cui/source/inc/cfgutil.hxx b/cui/source/inc/cfgutil.hxx
index 423cb05ef667..0d7944ffa9e8 100644
--- a/cui/source/inc/cfgutil.hxx
+++ b/cui/source/inc/cfgutil.hxx
@@ -167,10 +167,10 @@ public:
 OUString  GetCurLabel();
 };
 
-struct CuiConfigGroupBoxResource_Impl;
+struct SvxConfigGroupBoxResource_Impl;
 class CuiConfigGroupListBox
 {
-std::unique_ptr xImp;
+std::unique_ptr xImp;
 CuiConfigFunctionListBox* m_pFunctionListBox;
 SfxGroupInfoArr_Impl aArr;
 OUString m_sModuleLongName;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: cui/source cui/uiconfig extras/source include/vcl solenv/bin solenv/sanitizers vcl/source vcl/unx

2019-03-05 Thread Libreoffice Gerrit user
 cui/source/customize/acccfg.cxx|  470 ---
 cui/source/customize/cfg.cxx   |2 
 cui/source/customize/cfgutil.cxx   | 1022 -
 cui/source/inc/acccfg.hxx  |   52 -
 cui/source/inc/cfgutil.hxx |   71 -
 cui/uiconfig/ui/accelconfigpage.ui |  189 
 extras/source/glade/libreoffice-catalog.xml.in |6 
 include/vcl/treelistbox.hxx|4 
 include/vcl/weld.hxx   |3 
 solenv/bin/native-code.py  |2 
 solenv/sanitizers/ui/cui.suppr |1 
 vcl/source/app/salvtables.cxx  |   39 
 vcl/source/treelist/svlbitm.cxx|6 
 vcl/source/treelist/treelistbox.cxx|1 
 vcl/unx/gtk3/gtk3gtkinst.cxx   |   14 
 15 files changed, 651 insertions(+), 1231 deletions(-)

New commits:
commit 8ee19e3b6d8c1642da8377583482ca0fd4d30139
Author: Caolán McNamara 
AuthorDate: Sun Mar 3 21:43:07 2019 +
Commit: Caolán McNamara 
CommitDate: Tue Mar 5 17:34:34 2019 +0100

weld SfxAcceleratorConfigPage

fixes a leak in the KeyList too

Change-Id: I603218ff99481bc006df329c770ea6fe6f147483
Reviewed-on: https://gerrit.libreoffice.org/68694
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/cui/source/customize/acccfg.cxx b/cui/source/customize/acccfg.cxx
index a5a63eeba4bc..4146be2ae20d 100644
--- a/cui/source/customize/acccfg.cxx
+++ b/cui/source/customize/acccfg.cxx
@@ -779,43 +779,6 @@ static const sal_uInt16 KEYCODE_ARRAY[] =
 
 static const sal_uInt16 KEYCODE_ARRAY_SIZE = SAL_N_ELEMENTS(KEYCODE_ARRAY);
 
-// seems to be needed to layout the list box, which shows all
-// assignable shortcuts
-static const long AccCfgTabs[] =
-{
-0,
-120 // Function
-};
-
-
-class SfxAccCfgLBoxString_Impl : public SvLBoxString
-{
-public:
-explicit SfxAccCfgLBoxString_Impl(const OUString& sText);
-
-virtual void Paint(const Point& aPos, SvTreeListBox& rDevice, 
vcl::RenderContext& rRenderContext,
-   const SvViewDataEntry* pView, const SvTreeListEntry& 
rEntry) override;
-};
-
-
-SfxAccCfgLBoxString_Impl::SfxAccCfgLBoxString_Impl(const OUString& sText)
-: SvLBoxString(sText)
-{}
-
-void SfxAccCfgLBoxString_Impl::Paint(const Point& aPos, SvTreeListBox& 
/*rDevice*/, vcl::RenderContext& rRenderContext,
- const SvViewDataEntry* /*pView*/, const 
SvTreeListEntry& rEntry)
-{
-TAccInfo* pUserData = static_cast(rEntry.GetUserData());
-if (!pUserData)
-return;
-
-if (pUserData->m_bIsConfigurable)
-rRenderContext.DrawText(aPos, GetText());
-else
-rRenderContext.DrawCtrlText(aPos, GetText(), 0, -1, 
DrawTextFlags::Disable);
-
-}
-
 extern "C" SAL_DLLPUBLIC_EXPORT void 
makeSfxAccCfgTabListBox(VclPtr & rRet, VclPtr & 
pParent, VclBuilder::stringmap & rMap)
 {
 WinBits nWinBits = WB_TABSTOP;
@@ -876,8 +839,8 @@ void SfxAccCfgTabListBox_Impl::KeyInput(const KeyEvent& 
aKey)
 SvTabListBox::KeyInput(aKey);
 }
 
-SfxAcceleratorConfigPage::SfxAcceleratorConfigPage( vcl::Window* pParent, 
const SfxItemSet& aSet )
-: SfxTabPage(pParent, "AccelConfigPage", "cui/ui/accelconfigpage.ui", 
&aSet)
+SfxAcceleratorConfigPage::SfxAcceleratorConfigPage(TabPageParent pParent, 
const SfxItemSet& aSet )
+: SfxTabPage(pParent, "cui/ui/accelconfigpage.ui", "AccelConfigPage", 
&aSet)
 , m_pMacroInfoItem()
 , aLoadAccelConfigStr(CuiResId(RID_SVXSTR_LOADACCELCONFIG))
 , aSaveAccelConfigStr(CuiResId(RID_SVXSTR_SAVEACCELCONFIG))
@@ -886,70 +849,60 @@ SfxAcceleratorConfigPage::SfxAcceleratorConfigPage( 
vcl::Window* pParent, const
 , m_xGlobal()
 , m_xModule()
 , m_xAct()
+, m_aUpdateDataTimer("UpdateDataTimer")
+, m_xEntriesBox(m_xBuilder->weld_tree_view("shortcuts"))
+, m_xOfficeButton(m_xBuilder->weld_radio_button("office"))
+, m_xModuleButton(m_xBuilder->weld_radio_button("module"))
+, m_xChangeButton(m_xBuilder->weld_button("change"))
+, m_xRemoveButton(m_xBuilder->weld_button("delete"))
+, m_xGroupLBox(new 
CuiConfigGroupListBox(m_xBuilder->weld_tree_view("category")))
+, m_xFunctionBox(new 
CuiConfigFunctionListBox(m_xBuilder->weld_tree_view("function")))
+, m_xKeyBox(m_xBuilder->weld_tree_view("keys"))
+, m_xSearchEdit(m_xBuilder->weld_entry("searchEntry"))
+, m_xLoadButton(m_xBuilder->weld_button("load"))
+, m_xSaveButton(m_xBuilder->weld_button("save"))
+, m_xResetButton(m_xBuilder->weld_button("reset"))
 {
-get(m_pOfficeButton, "office");
-get(m_pModuleButton, "module");
-get(m_pChangeButton, "change");
-get(m_pRemoveButton, "delete");
-get(m_pLoadButton, "load");
-get(m_pSaveButton, "save");
-get(m_pResetButton, "reset");
-get(m_pEntriesBox, "shortcuts");
 Size aSize(LogicToPixel(Size(174, 100), MapMode(Map

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

2019-03-05 Thread Libreoffice Gerrit user
 cui/source/inc/acccfg.hxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit 4986b503eb0b50579000512787edcf0c8c8b41fc
Author: Caolán McNamara 
AuthorDate: Mon Mar 4 14:58:53 2019 +
Commit: Caolán McNamara 
CommitDate: Tue Mar 5 17:34:52 2019 +0100

unused SfxConfigGroupListBox

Change-Id: Ia31f70b0d22b4bca13e46f3fbce440288bafd26f
Reviewed-on: https://gerrit.libreoffice.org/68700
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/cui/source/inc/acccfg.hxx b/cui/source/inc/acccfg.hxx
index b4bbae860063..917c549f85f7 100644
--- a/cui/source/inc/acccfg.hxx
+++ b/cui/source/inc/acccfg.hxx
@@ -41,7 +41,6 @@
 #include "cfgutil.hxx"
 
 class SfxMacroInfoItem;
-class SfxConfigGroupListBox;
 class SfxConfigFunctionListBox;
 class SfxAcceleratorConfigPage;
 class SfxStringItem;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 include/vcl/weld.hxx |6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit db8b4d8c58e808f645a5d854b73c8a8132e2d898
Author: Caolán McNamara 
AuthorDate: Tue Mar 5 12:14:20 2019 +
Commit: Caolán McNamara 
CommitDate: Tue Mar 5 17:33:40 2019 +0100

sync get_selected_id with get_active_id

Change-Id: I983cc45d13e02a020f608b8e9abfd2f12f7b10f5
Reviewed-on: https://gerrit.libreoffice.org/68741
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/include/vcl/weld.hxx b/include/vcl/weld.hxx
index 6000bb53032c..5511879ed188 100644
--- a/include/vcl/weld.hxx
+++ b/include/vcl/weld.hxx
@@ -608,7 +608,11 @@ public:
 //by id
 virtual OUString get_id(int pos) const = 0;
 virtual int find_id(const OUString& rId) const = 0;
-OUString get_selected_id() const { return get_id(get_selected_index()); }
+OUString get_selected_id() const
+{
+int pos = get_selected_index();
+return pos == -1 ? OUString() : get_id(pos);
+}
 void select_id(const OUString& rId) { select(find_id(rId)); }
 
 //via iter
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: desktop/source sysui/desktop

2019-03-05 Thread Libreoffice Gerrit user
 desktop/source/app/cmdlinehelp.cxx |6 --
 sysui/desktop/man/libreoffice.1|7 +--
 2 files changed, 9 insertions(+), 4 deletions(-)

New commits:
commit 9d152d29e2def8c15b493b1c8915aecee272a2fd
Author: Michael Stahl 
AuthorDate: Tue Mar 5 12:04:21 2019 +0100
Commit: Stephan Bergmann 
CommitDate: Tue Mar 5 17:05:43 2019 +0100

improve documentation of soffice --accept parameter

Change-Id: I8058bad949c973981013d099dba78b3e64cee0aa
Reviewed-on: https://gerrit.libreoffice.org/68735
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 

diff --git a/desktop/source/app/cmdlinehelp.cxx 
b/desktop/source/app/cmdlinehelp.cxx
index 5d9a941c50c4..95e71998f3fb 100644
--- a/desktop/source/app/cmdlinehelp.cxx
+++ b/desktop/source/app/cmdlinehelp.cxx
@@ -98,8 +98,10 @@ namespace desktop
 "   configuration. 
 \n"
 "   --accept={UNO-URL}  Specifies an UNO-URL connect-string to create 
an UNO\n"
 "   acceptor through which other programs can 
connect to\n"
-"   access the API. UNO-URL is string the such 
kind \n"
-"   
uno:connection-type,params;protocol-name,params;ObjectName. \n"
+"   access the API. Note that API access allows 
execution   \n"
+"   of arbitrary commands. 
 \n"
+"   The syntax of an UNO-URL connect-string is:
 \n"
+"   
uno:connection-type,params;protocol-name,params;ObjectName  \n"
 "   --unaccept={UNO-URL} Closes an acceptor that was created with 
--accept. Use \n"
 "   --unaccept=all to close all open acceptors.
 \n"
 "   --language={lang}   Uses specified language, if language is not 
selected\n"
diff --git a/sysui/desktop/man/libreoffice.1 b/sysui/desktop/man/libreoffice.1
index 5291d8492e9b..5f938d3aaf48 100644
--- a/sysui/desktop/man/libreoffice.1
+++ b/sysui/desktop/man/libreoffice.1
@@ -48,8 +48,11 @@ sbase, scalc, sdraw, simpress, smath, sofficerc, swriter
 .SH OPTIONS
 .TP
 \fB\-\-accept=\fIaccept\-string\fR
-Specify a UNO connect-string to create a UNO acceptor through which other
-programs can connect to access the API.
+Specifies an UNO-URL connect-string to create a UNO acceptor through which 
other
+programs can connect to access the API. Note that API access allows execution
+of arbitrary commands.
+The syntax of an UNO-URL connect-string is:
+\fIuno:connection-type,params;protocol-name,params;ObjectName\fR
 
 .TP
 \fB\-\-base\fR
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] online.git: loleaflet/html loleaflet/Makefile.am

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/Makefile.am|1 +
 loleaflet/html/loleaflet.html.m4 |   12 ++--
 2 files changed, 7 insertions(+), 6 deletions(-)

New commits:
commit 70d9923ea9526c1bf31815979a208c7fe68eca69
Author: Henry Castro 
AuthorDate: Sun Jan 27 13:42:44 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 11:56:02 2019 -0400

loleaflet: expand inline bundle.css style into html

Change-Id: Id26180777a1b9838c3a9b5dc1e541023d0299595

diff --git a/loleaflet/Makefile.am b/loleaflet/Makefile.am
index 07f2dc886..a06a33c72 100644
--- a/loleaflet/Makefile.am
+++ b/loleaflet/Makefile.am
@@ -258,6 +258,7 @@ $(builddir)/dist/loleaflet.html: 
$(srcdir)/html/loleaflet.html.m4 $(LOLEAFLET_HT
-DANDROIDAPP=$(ENABLE_ANDROIDAPP) \
-DMOBILEAPPNAME="$(MOBILE_APP_NAME)" \
-DLOLEAFLET_CSS="$(subst 
$(SPACE),$(COMMA),$(LOLEAFLET_CSS_M4))" \
+   -DBUNDLE_CSS="$(abs_builddir)/dist/bundle.css" \
-DLOLEAFLET_JS="$(subst $(SPACE),$(COMMA),$(GLOBAL_JS) 
$(NODE_MODULES_JS) \
$(call LOLEAFLET_JS,$(srcdir)/build/build.js) \
$(patsubst %.js,plugins/draw-$(DRAW_VERSION)/%.js,$(call 
LOLEAFLET_JS,$(srcdir)/plugins/draw-$(DRAW_VERSION)/build/build.js)) \
diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index a41cb47b7..ed5cfa40a 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -44,16 +44,16 @@ var Base64ToArrayBuffer = function(base64Str) {
 
 
 ifelse(MOBILEAPP,[true],
-  ifelse(DEBUG,[true],
+  [ifelse(DEBUG,[true],
 foreachq([fileCSS],[LOLEAFLET_CSS],[
   ]),
-[
-  ]),
-  ifelse(DEBUG,[true],
+[syscmd([cat ]BUNDLE_CSS)
+  ])],
+  [ifelse(DEBUG,[true],
 foreachq([fileCSS],[LOLEAFLET_CSS],[
   ]),
-[
-  ])dnl
+[syscmd([cat ]BUNDLE_CSS)
+  ])]dnl
 )dnl
  
 ifelse(MOBILEAPP,[true],
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

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

2019-03-05 Thread Libreoffice Gerrit user
 vcl/source/app/salvtables.cxx |7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)

New commits:
commit b1df6d21bf9a608cccb7f34f6cebe9eee5cec18e
Author: Caolán McNamara 
AuthorDate: Tue Mar 5 12:11:24 2019 +
Commit: Caolán McNamara 
CommitDate: Tue Mar 5 16:43:16 2019 +0100

sync get_active_id impls

Change-Id: I6b0595f6386657afa28b2cb249ea69aa51e5fb4a
Reviewed-on: https://gerrit.libreoffice.org/68740
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/vcl/source/app/salvtables.cxx b/vcl/source/app/salvtables.cxx
index 325d320704fe..f0efbf9373e0 100644
--- a/vcl/source/app/salvtables.cxx
+++ b/vcl/source/app/salvtables.cxx
@@ -3677,7 +3677,12 @@ public:
 
 virtual OUString get_active_id() const override
 {
-const OUString* pRet = 
getEntryData(m_xComboBox->GetSelectedEntryPos());
+sal_Int32 nPos = m_xComboBox->GetSelectedEntryPos();
+const OUString* pRet;
+if (nPos != LISTBOX_ENTRY_NOTFOUND)
+pRet = getEntryData(m_xComboBox->GetSelectedEntryPos());
+else
+pRet = nullptr;
 if (!pRet)
 return OUString();
 return *pRet;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: download.lst external/harfbuzz

2019-03-05 Thread Libreoffice Gerrit user
 download.lst  |4 +--
 external/harfbuzz/UnpackedTarball_harfbuzz.mk |   13 ---
 external/harfbuzz/clang-cl.patch  |   12 --
 external/harfbuzz/harfbuzz-ios.patch  |   29 --
 external/harfbuzz/harfbuzz-rtti.patch |   11 -
 external/harfbuzz/msvc.patch  |   17 +++
 external/harfbuzz/ubsan.patch |   11 -
 7 files changed, 20 insertions(+), 77 deletions(-)

New commits:
commit b7ddc514bff9bdf682abae537f990aa01dc2c0fb
Author: Stephan Bergmann 
AuthorDate: Tue Mar 5 08:37:47 2019 +0100
Commit: Stephan Bergmann 
CommitDate: Tue Mar 5 15:31:25 2019 +0100

Upgrade to latest HarfBuzz 2.3.1

As a side-effect, this gets rid of some Clang
-fsanitize=implicit-signed-integer-truncation warnings.

The various external/harfbuzz/*.patch no longer applied and appear not to be
necessary any more.  (But a new external/harfbuzz/msvc.patch became 
necessary.)

 was downloaded 
from

,
and HARFBUZZ_SHA256SUM in download.lst matches .

Change-Id: Ic85acd14b4f488b3d88ce1bafc93be271928006e
Reviewed-on: https://gerrit.libreoffice.org/68731
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 

diff --git a/download.lst b/download.lst
index 9b85f3da8f78..c9475b474dc5 100644
--- a/download.lst
+++ b/download.lst
@@ -96,8 +96,8 @@ export GPGME_SHA256SUM := 
1b29fedb8bfad775e70eafac5b0590621683b2d9869db994568e64
 export GPGME_TARBALL := gpgme-1.9.0.tar.bz2
 export GRAPHITE_SHA256SUM := 
d47d387161db7f7ebade1920aa7cbdc797e79772597d8b55e80b58d1071bcc36
 export GRAPHITE_TARBALL := graphite2-minimal-1.3.13.tgz
-export HARFBUZZ_SHA256SUM := 
3c592f86fa0da69e2e0e98cae9f5d5b61def3bb7948aa00ca45748f27fa545fd
-export HARFBUZZ_TARBALL := harfbuzz-1.8.4.tar.bz2
+export HARFBUZZ_SHA256SUM := 
f205699d5b91374008d6f8e36c59e419ae2d9a7bb8c5d9f34041b9a5abcae468
+export HARFBUZZ_TARBALL := harfbuzz-2.3.1.tar.bz2
 export HSQLDB_SHA256SUM := 
d30b13f4ba2e3b6a2d4f020c0dee0a9fb9fc6fbcc2d561f36b78da4bf3802370
 export HSQLDB_TARBALL := 17410483b5b5f267aa18b7e00b65e6e0-hsqldb_1_8_0.zip
 export HUNSPELL_SHA256SUM := 
57be4e03ae9dd62c3471f667a0d81a14513e314d4d92081292b90435944ff951
diff --git a/external/harfbuzz/UnpackedTarball_harfbuzz.mk 
b/external/harfbuzz/UnpackedTarball_harfbuzz.mk
index 3a20f31e101f..48d7b450bc3a 100644
--- a/external/harfbuzz/UnpackedTarball_harfbuzz.mk
+++ b/external/harfbuzz/UnpackedTarball_harfbuzz.mk
@@ -16,18 +16,7 @@ $(eval $(call 
gb_UnpackedTarball_update_autoconf_configs,harfbuzz))
 $(eval $(call gb_UnpackedTarball_set_patchlevel,harfbuzz,0))
 
 $(eval $(call gb_UnpackedTarball_add_patches,harfbuzz, \
-external/harfbuzz/clang-cl.patch \
-external/harfbuzz/ubsan.patch \
-))
-
-ifneq ($(ENABLE_RUNTIME_OPTIMIZATIONS),TRUE)
-$(eval $(call gb_UnpackedTarball_add_patches,harfbuzz, \
-external/harfbuzz/harfbuzz-rtti.patch \
-))
-endif
-
-$(eval $(call gb_UnpackedTarball_add_patches,harfbuzz, \
-external/harfbuzz/harfbuzz-ios.patch \
+external/harfbuzz/msvc.patch \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/external/harfbuzz/clang-cl.patch b/external/harfbuzz/clang-cl.patch
deleted file mode 100644
index 9fbeee4114d8..
--- a/external/harfbuzz/clang-cl.patch
+++ /dev/null
@@ -1,12 +0,0 @@
 src/hb-common.h
-+++ src/hb-common.h
-@@ -346,7 +346,9 @@
-*
-*   https://lists.freedesktop.org/archives/harfbuzz/2014-March/004150.html
-*/
-+#if !defined _MSC_VER /* avoid clang-cl -Wmicrosoft-enum-value */
-   _HB_SCRIPT_MAX_VALUE= HB_TAG_MAX, /*< skip 
>*/
-+#endif
-   _HB_SCRIPT_MAX_VALUE_SIGNED = HB_TAG_MAX_SIGNED /*< skip >*/
-
- } hb_script_t;
diff --git a/external/harfbuzz/harfbuzz-ios.patch 
b/external/harfbuzz/harfbuzz-ios.patch
deleted file mode 100644
index 215800e5ab57..
--- a/external/harfbuzz/harfbuzz-ios.patch
+++ /dev/null
@@ -1,29 +0,0 @@
 src/hb-coretext.cc
-+++ src/hb-coretext.cc
-@@ -167,7 +167,7 @@
-   if (CFStringHasPrefix (cg_postscript_name, CFSTR (".SFNSText")) ||
-   CFStringHasPrefix (cg_postscript_name, CFSTR (".SFNSDisplay")))
-   {
--#if MAC_OS_X_VERSION_MIN_REQUIRED < 1080
-+#if !defined(__IPHONE_OS_VERSION_MIN_REQUIRED) && 
(MAC_OS_X_VERSION_MIN_REQUIRED < 1080)
- # define kCTFontUIFontSystem kCTFontSystemFontType
- # define kCTFontUIFontEmphasizedSystem kCTFontEmphasizedSystemFontType
- #endif
-@@ -217,7 +217,7 @@
-   }
- 
-   CFURLRef original_url = nullptr;
--#if MAC_OS_X_VERSION_MIN_REQUIRED < 1060
-+#if !defined(__IPHONE_OS_VERSION_MIN_REQUIRED) && 
(MAC_OS_X_VERSION_MIN_REQUIRED < 1060)
-   ATSFontRef atsFont;
-   FSRef fsref;
-   OSStatus statu

[Libreoffice-commits] online.git: loleaflet/html

2019-03-05 Thread Libreoffice Gerrit user
 loleaflet/html/loleaflet.html.m4 |   12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

New commits:
commit 20d781130a990b6d5c02280be22e45cc391307f9
Author: Henry Castro 
AuthorDate: Sun Jan 27 13:27:37 2019 -0400
Commit: Henry Castro 
CommitDate: Tue Mar 5 10:28:41 2019 -0400

loleaflet: add defer attribute to the script tag

A script that will not run until after the page has loaded

Change-Id: I7a835138ba22e70150db4345629231c59b84973b

diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index 4985a29ac..a41cb47b7 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -152,7 +152,7 @@ ifelse(MOBILEAPP,[true],
   
 
 
-
+