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

2016-09-19 Thread Arnaud Versini
 xmlhelp/source/cxxhelp/provider/urlparameter.cxx |   23 ++-
 1 file changed, 2 insertions(+), 21 deletions(-)

New commits:
commit a46803587d48adccfb314dc0e7e9d07daed1b313
Author: Arnaud Versini 
Date:   Sun Sep 18 16:55:38 2016 +0200

Replace local ASCII function with rtl/character.hxx

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

diff --git a/xmlhelp/source/cxxhelp/provider/urlparameter.cxx 
b/xmlhelp/source/cxxhelp/provider/urlparameter.cxx
index 4db1933..0099970 100644
--- a/xmlhelp/source/cxxhelp/provider/urlparameter.cxx
+++ b/xmlhelp/source/cxxhelp/provider/urlparameter.cxx
@@ -27,6 +27,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -46,26 +47,6 @@
 #include "urlparameter.hxx"
 #include "databases.hxx"
 
-namespace chelp {
-
-inline bool ascii_isDigit( sal_Unicode ch )
-{
-return ((ch >= 0x0030) && (ch <= 0x0039));
-}
-
-inline bool ascii_isLetter( sal_Unicode ch )
-{
-return ( ( (ch >= 0x0041) && (ch <= 0x005A) ) ||
- ( (ch >= 0x0061) && (ch <= 0x007A) ) );
-}
-
-inline bool isLetterOrDigit( sal_Unicode ch )
-{
-return ascii_isLetter( ch ) || ascii_isDigit( ch );
-}
-
-}
-
 using namespace cppu;
 using namespace com::sun::star::io;
 using namespace com::sun::star::uno;
@@ -469,7 +450,7 @@ bool URLParameter::module()
 {
 sal_Int32 idx = 0,length = m_aExpr.getLength();
 
-while( idx < length && isLetterOrDigit( (m_aExpr.getStr())[idx] ) )
+while( idx < length && rtl::isAsciiAlphanumeric( (m_aExpr.getStr())[idx] ) 
)
 ++idx;
 
 if( idx != 0 )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] help.git: source/text

2016-09-19 Thread Gabor Kelemen
 source/text/scalc/01/04060109.xhp |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit e21bf9fa94cae8ec3527bed2aa6b4c71501b65eb
Author: Gabor Kelemen 
Date:   Mon Sep 19 08:03:35 2016 +0200

tdf#97821 Add section anchors to VLOOKUP/HLOOKUP links

The missing anchors caused the links to not work

Change-Id: I4af8d0467cec347dee535f510133819987e88491
Reviewed-on: https://gerrit.libreoffice.org/29010
Reviewed-by: Adolfo Jayme Barrientos 
Tested-by: Adolfo Jayme Barrientos 

diff --git a/source/text/scalc/01/04060109.xhp 
b/source/text/scalc/01/04060109.xhp
index a2d98d3..a9061fc 100644
--- a/source/text/scalc/01/04060109.xhp
+++ b/source/text/scalc/01/04060109.xhp
@@ -426,7 +426,7 @@
 
 LOOKUP
- Returns the contents of a 
cell either from a one-row or one-column range. Optionally, the 
assigned value (of the same index) is returned in a different column and row. 
As opposed to VLOOKUP and HLOOKUP, search and result vector may be at different 
positions; they do not have to be adjacent. Additionally, the search vector for 
the LOOKUP must be sorted ascending, otherwise the search will not return any 
usable results.
+ Returns the contents of a 
cell either from a one-row or one-column range. Optionally, the 
assigned value (of the same index) is returned in a different column and row. 
As opposed to VLOOKUP and HLOOKUP, 
search and result vector may be at different positions; they do not have to be 
adjacent. Additionally, the search vector for the LOOKUP must be sorted 
ascending, otherwise the search will not return any usable results.
  If LOOKUP cannot find the search criterion, it matches the largest 
value in the search vector that is less than or equal to the search 
criterion.
  
  Syntax
  HLOOKUP(SearchCriteria; Array; Index; Sorted)
- See also:VLOOKUP (columns and rows are exchanged)
+ See also: VLOOKUP 
(columns and rows are exchanged)
  
   
   
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: helpcontent2

2016-09-19 Thread Gabor Kelemen
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 71b5a4ae856bb61aed8d91e66a43135665b9c301
Author: Gabor Kelemen 
Date:   Mon Sep 19 08:03:35 2016 +0200

Updated core
Project: help  e21bf9fa94cae8ec3527bed2aa6b4c71501b65eb

tdf#97821 Add section anchors to VLOOKUP/HLOOKUP links

The missing anchors caused the links to not work

Change-Id: I4af8d0467cec347dee535f510133819987e88491
Reviewed-on: https://gerrit.libreoffice.org/29010
Reviewed-by: Adolfo Jayme Barrientos 
Tested-by: Adolfo Jayme Barrientos 

diff --git a/helpcontent2 b/helpcontent2
index 9e65be2..e21bf9f 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit 9e65be21197548d68eca86906209f24e36ff4533
+Subproject commit e21bf9fa94cae8ec3527bed2aa6b4c71501b65eb
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/LOOLStress.cpp

2016-09-19 Thread Miklos Vajna
 loolwsd/LOOLStress.cpp |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit e2029921cbc8053ba82e32cbc90fa48d45db2b35
Author: Miklos Vajna 
Date:   Mon Sep 19 09:21:47 2016 +0200

LOOLStress: avoid multiplying at int precision, then converting to long

Change-Id: Ie79296522d09be0f337f218bede1a28e9bac3a7c

diff --git a/loolwsd/LOOLStress.cpp b/loolwsd/LOOLStress.cpp
index b4478b4..2929bee 100644
--- a/loolwsd/LOOLStress.cpp
+++ b/loolwsd/LOOLStress.cpp
@@ -53,7 +53,7 @@ public:
 ~Stress() {}
 
 static bool Benchmark;
-static int Iterations;
+static size_t Iterations;
 static bool NoDelay;
 unsigned _numClients;
 std::string _serverURI;
@@ -268,7 +268,7 @@ private:
 
 connection->load();
 
-for (auto i = 0; i < Stress::Iterations; ++i)
+for (size_t i = 0; i < Stress::Iterations; ++i)
 {
 renderTile(connection);
 
@@ -405,7 +405,7 @@ private:
 
 bool Stress::NoDelay = false;
 bool Stress::Benchmark = false;
-int Stress::Iterations = 100;
+size_t Stress::Iterations = 100;
 
 Stress::Stress() :
 _numClients(1),
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Zdeněk Crhonek
 sc/qa/unit/data/functions/fods/ftest.fods | 5338 ++
 1 file changed, 5338 insertions(+)

New commits:
commit 4165e3fae6dce408c52aedda8319fc5cd8e93dc8
Author: Zdeněk Crhonek 
Date:   Sun Sep 18 12:18:59 2016 +0200

add FTEST test case

Change-Id: Icae9ed5dee0f9b230e4629b47d9a3eaff0328534
Reviewed-on: https://gerrit.libreoffice.org/28988
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/sc/qa/unit/data/functions/fods/ftest.fods 
b/sc/qa/unit/data/functions/fods/ftest.fods
new file mode 100644
index 000..34caf84
--- /dev/null
+++ b/sc/qa/unit/data/functions/fods/ftest.fods
@@ -0,0 +1,5338 @@
+
+
+http://www.w3.org/1999/xlink"; 
xmlns:dc="http://purl.org/dc/elements/1.1/"; 
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" 
xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" 
xmlns:presentation="urn:oasis:names:tc:opendocument:xmlns:presentation:1.0" 
xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" 
xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" 
xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" 
xmlns:math="http://www.w3.org/1998/Math/MathML"; 
xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:scr
 ipt="urn:oasis:names:tc:opendocument:xmlns:script:1.0" 
xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0" 
xmlns:ooo="http://openoffice.org/2004/office"; 
xmlns:ooow="http://openoffice.org/2004/writer"; 
xmlns:oooc="http://openoffice.org/2004/calc"; 
xmlns:dom="http://www.w3.org/2001/xml-events"; 
xmlns:xforms="http://www.w3.org/2002/xforms"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:rpt="http://openoffice.org/2005/report"; 
xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" 
xmlns:xhtml="http://www.w3.org/1999/xhtml"; 
xmlns:grddl="http://www.w3.org/2003/g/data-view#"; 
xmlns:tableooo="http://openoffice.org/2009/table"; 
xmlns:drawooo="http://openoffice.org/2010/draw"; 
xmlns:calcext="urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0"
 
xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0"
 xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" 
xmlns:form
 x="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0" 
xmlns:css3t="http://www.w3.org/TR/css3-text/"; office:version="1.2" 
office:mimetype="application/vnd.oasis.opendocument.spreadsheet">
+ 
2016-07-24T08:15:55.36200P0D1LibreOfficeDev/5.3.0.0.alpha0$Linux_X86_64
 
LibreOffice_project/7b660e1423554928350e1de2cd4cb7eb577a27ec
+ 
+  
+   0
+   0
+   102310
+   20630
+   
+
+ view1
+ 
+  
+   2
+   8
+   0
+   0
+   0
+   0
+   2
+   0
+   0
+   0
+   0
+   0
+   75
+   60
+   true
+   false
+  
+  
+   4
+   1
+   0
+   0
+   0
+   0
+   2
+   0
+   0
+   0
+   0
+   0
+   75
+   60
+   true
+   false
+  
+ 
+ Sheet1
+ 1241
+ 0
+ 75
+ 60
+ false
+ true
+ true
+ true
+ 12632256
+ true
+ true
+ true
+ true
+ true
+ false
+ false
+ 1270
+ 1270
+ 1
+ 1
+ true
+ false
+
+   
+  
+  
+   7
+   false
+   false
+   true
+   true
+   false
+   false
+   false
+   1270
+   1270
+   true
+   true
+   true
+   true
+   true
+   false
+   12632256
+   false
+   Lexmark-E352dn
+   
+
+ cs
+ CZ
+ 
+ 
+ 
+
+
+ de
+ DE
+ 
+ 
+ 
+
+
+ en
+ US
+ 
+ 
+ 
+
+
+ nl
+ NL
+ 
+ 
+ 
+
+   
+   true
+   true
+   3
+   1
+   true
+   1
+   true
+   sgH+/0xleG1hcmstRTM1MmRuQ1VQUzpMZXhtYXJrLUUzNTJkbgAWAAMA0wAIAFZUAAAkbQAASm9iRGF0YSAxCnByaW50ZXI9TGV4bWFyay1FMzUyZG4Kb3JpZW50YXRpb249UG9ydHJhaXQKY29waWVzPTEKY29sbGF0ZT1mYWxzZQptYXJnaW5kYWp1c3RtZW50PTAsMCwwLDAKY29sb3JkZXB0aD0yNApwc2xldmVsPTAKcGRmZGV2aWNlPTEKY29sb3JkZXZpY2U9MApQUERDb250ZXhEYXRhCkR1cGxleDpOb25lAElucHV0U2xvdDpUcmF5MQBQYWdlU2l6ZTpMZXR0ZXIAABIAQ09NUEFUX0RVUExFWF9NT0RFDwBEdXBsZXhNb2RlOjpPZmY=
+   false
+   0
+  
+ 
+ 
+  
+   http://openoffice.org/2004/office"; 
xmlns:xlink="http://www.w3.org/1999/xlink";>
+
+   
+  
+ 
+ 
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+ 
+ 
+  
+   
+   
+  
+  
+   
+  
+  
+   
+
+   Kč
+  
+  
+   
+   -
+   
+
+   Kč
+   
+  
+  
+
+   
+
+  
+  
+
+   (
+   
+   )
+  
+  
+
+   -
+   
+
+  
+  
+   
+
+   
+   
+   
+  
+  
+   
+  
+  
+   
+  
+  
+   
+
+   Kč
+  
+  
+   -
+   
+
+   Kč
+   
+  
+  
+   
+
+   Kč
+  
+  
+   -
+   
+
+   Kč
+   
+  
+  
+

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

2016-09-19 Thread Zdeněk Crhonek
 sc/qa/unit/data/functions/fods/beta.dist.fods | 4141 ++
 1 file changed, 4141 insertions(+)

New commits:
commit 01542bf662fc83564e5d40eaa3a79dd1d8b0ec67
Author: Zdeněk Crhonek 
Date:   Sun Sep 18 17:50:44 2016 +0200

add BETA.DIST test case

Change-Id: I514e06585fac3c16a40318f8d51d389fd13c9c5a
Reviewed-on: https://gerrit.libreoffice.org/28997
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/sc/qa/unit/data/functions/fods/beta.dist.fods 
b/sc/qa/unit/data/functions/fods/beta.dist.fods
new file mode 100644
index 000..0ffec57
--- /dev/null
+++ b/sc/qa/unit/data/functions/fods/beta.dist.fods
@@ -0,0 +1,4141 @@
+
+
+http://www.w3.org/1999/xlink"; 
xmlns:dc="http://purl.org/dc/elements/1.1/"; 
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" 
xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" 
xmlns:presentation="urn:oasis:names:tc:opendocument:xmlns:presentation:1.0" 
xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" 
xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" 
xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" 
xmlns:math="http://www.w3.org/1998/Math/MathML"; 
xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:scr
 ipt="urn:oasis:names:tc:opendocument:xmlns:script:1.0" 
xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0" 
xmlns:ooo="http://openoffice.org/2004/office"; 
xmlns:ooow="http://openoffice.org/2004/writer"; 
xmlns:oooc="http://openoffice.org/2004/calc"; 
xmlns:dom="http://www.w3.org/2001/xml-events"; 
xmlns:xforms="http://www.w3.org/2002/xforms"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:rpt="http://openoffice.org/2005/report"; 
xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" 
xmlns:xhtml="http://www.w3.org/1999/xhtml"; 
xmlns:grddl="http://www.w3.org/2003/g/data-view#"; 
xmlns:tableooo="http://openoffice.org/2009/table"; 
xmlns:drawooo="http://openoffice.org/2010/draw"; 
xmlns:calcext="urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0"
 
xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0"
 xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" 
xmlns:form
 x="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0" 
xmlns:css3t="http://www.w3.org/TR/css3-text/"; office:version="1.2" 
office:mimetype="application/vnd.oasis.opendocument.spreadsheet">
+ 
2016-07-24T08:15:55.36200P0D1LibreOfficeDev/5.3.0.0.alpha0$Linux_X86_64
 
LibreOffice_project/3287bc2f91438085b7604773d5e0346fc3c3f452
+ 
+  
+   0
+   0
+   85982
+   17817
+   
+
+ view1
+ 
+  
+   2
+   8
+   0
+   0
+   0
+   0
+   2
+   0
+   0
+   0
+   0
+   0
+   75
+   60
+   true
+   false
+  
+  
+   2
+   21
+   0
+   0
+   0
+   0
+   2
+   0
+   0
+   0
+   9
+   0
+   75
+   60
+   true
+   false
+  
+ 
+ Sheet2
+ 1241
+ 0
+ 75
+ 60
+ false
+ true
+ true
+ true
+ 12632256
+ true
+ true
+ true
+ true
+ true
+ false
+ false
+ 1270
+ 1270
+ 1
+ 1
+ true
+ false
+
+   
+  
+  
+   7
+   false
+   false
+   true
+   true
+   false
+   false
+   false
+   1270
+   1270
+   true
+   true
+   true
+   true
+   true
+   false
+   12632256
+   false
+   Lexmark-E352dn
+   
+
+ cs
+ CZ
+ 
+ 
+ 
+
+
+ en
+ US
+ 
+ 
+ 
+
+
+ nl
+ NL
+ 
+ 
+ 
+
+   
+   true
+   true
+   3
+   1
+   true
+   1
+   true
+   sgH+/0xleG1hcmstRTM1MmRuQ1VQUzpMZXhtYXJrLUUzNTJkbgAWAAMA0wAIAFZUAAAkbQAASm9iRGF0YSAxCnByaW50ZXI9TGV4bWFyay1FMzUyZG4Kb3JpZW50YXRpb249UG9ydHJhaXQKY29waWVzPTEKY29sbGF0ZT1mYWxzZQptYXJnaW5kYWp1c3RtZW50PTAsMCwwLDAKY29sb3JkZXB0aD0yNApwc2xldmVsPTAKcGRmZGV2aWNlPTEKY29sb3JkZXZpY2U9MApQUERDb250ZXhEYXRhCkR1cGxleDpOb25lAElucHV0U2xvdDpUcmF5MQBQYWdlU2l6ZTpMZXR0ZXIAABIAQ09NUEFUX0RVUExFWF9NT0RFDwBEdXBsZXhNb2RlOjpPZmY=
+   false
+   0
+  
+ 
+ 
+  
+   http://openoffice.org/2004/office"; 
xmlns:xlink="http://www.w3.org/1999/xlink";>
+
+   
+  
+ 
+ 
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+ 
+ 
+  
+   
+   
+  
+  
+   
+  
+  
+   
+
+   Kč
+  
+  
+   
+   -
+   
+
+   Kč
+   
+  
+  
+
+   
+
+  
+  
+
+   (
+   
+   )
+  
+  
+
+   -
+   
+
+  
+  
+   
+
+   
+   
+   
+  
+  
+   
+
+   Kč
+  
+  
+   -
+   
+
+   Kč
+   
+  
+  
+   
+
+   Kč
+  
+  
+   -
+   
+
+   Kč
+   
+  
+  
+   
+
+   Kč
+  
+  
+   
+   -
+   
+
+   Kč
+   
+  

[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-5.1' - sd/qa sd/source

2016-09-19 Thread Miklos Vajna
 sd/qa/unit/tiledrendering/tiledrendering.cxx |4 
 sd/source/ui/view/ViewShellBase.cxx  |   11 +++
 2 files changed, 15 insertions(+)

New commits:
commit 681dcf0063f8a22d9acbc617067832c50c84c2fe
Author: Miklos Vajna 
Date:   Fri Sep 16 17:15:05 2016 +0200

sd draw text: emit LOK_CALLBACK_VIEW_LOCK from registerCallback()

This is similar to commit 7b784e4e3927d91a96cd0b54fc43c9b488822e47 (sw
draw text: emit LOK_CALLBACK_VIEW_LOCK from registerCallback(),
2016-09-14), but this fix is for Impress.

Change-Id: I995d2ed223aa6ce7845c440039d176b6beada84e
(cherry picked from commit d53bb5c044f039bd2fd38977a85012b03abbe32c)

diff --git a/sd/qa/unit/tiledrendering/tiledrendering.cxx 
b/sd/qa/unit/tiledrendering/tiledrendering.cxx
index 38e9174..4c92622 100644
--- a/sd/qa/unit/tiledrendering/tiledrendering.cxx
+++ b/sd/qa/unit/tiledrendering/tiledrendering.cxx
@@ -1054,7 +1054,11 @@ void SdTiledRenderingTest::testCursorViews()
 // second view as well, even if the second view was created after begin
 // text edit in the first view.
 ViewCallback aView2;
+aView2.m_bViewLock = false;
 
SfxViewShell::Current()->registerLibreOfficeKitViewCallback(&ViewCallback::callback,
 &aView2);
+// This failed: the second view didn't get a lock notification, even if the
+// first view already started text edit.
+CPPUNIT_ASSERT(aView2.m_bViewLock);
 SfxLokHelper::setView(nView1);
 aView2.m_bTilesInvalidated = false;
 pXImpressDocument->postKeyEvent(LOK_KEYEVENT_KEYINPUT, 'x', 0);
diff --git a/sd/source/ui/view/ViewShellBase.cxx 
b/sd/source/ui/view/ViewShellBase.cxx
index ad60dd7..b14774e 100644
--- a/sd/source/ui/view/ViewShellBase.cxx
+++ b/sd/source/ui/view/ViewShellBase.cxx
@@ -1071,6 +1071,17 @@ void ViewShellBase::NotifyCursor(SfxViewShell* 
pOtherShell) const
 rEditView.RegisterOtherShell(nullptr);
 // Text selection, if any.
 rEditView.DrawSelection(pOtherShell);
+
+// Shape text lock.
+if (OutlinerView* pOutlinerView = pDrawView->GetTextEditOutlinerView())
+{
+Rectangle aRectangle = pOutlinerView->GetOutputArea();
+vcl::Window* pWin = pThisShell->GetActiveWindow();
+if (pWin && pWin->GetMapMode().GetMapUnit() == MAP_100TH_MM)
+aRectangle = OutputDevice::LogicToLogic(aRectangle, 
MAP_100TH_MM, MAP_TWIP);
+OString sRectangle = aRectangle.toString();
+SfxLokHelper::notifyOtherView(&pDrawViewShell->GetViewShellBase(), 
pOtherShell, LOK_CALLBACK_VIEW_LOCK, "rectangle", sRectangle);
+}
 }
 else
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Thorsten Behrens
 include/o3tl/cow_wrapper.hxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 5a7dbe1ec161a5683086d22ec13506396dca
Author: Thorsten Behrens 
Date:   Mon Sep 19 01:46:10 2016 +0200

o3tl: refcounts should be native platform int width

Change-Id: I19854d85b680612733557c42ee58b35adb5ea4c3
Reviewed-on: https://gerrit.libreoffice.org/29002
Reviewed-by: Thorsten Behrens 
Tested-by: Thorsten Behrens 

diff --git a/include/o3tl/cow_wrapper.hxx b/include/o3tl/cow_wrapper.hxx
index 7e9c3af..425a166 100644
--- a/include/o3tl/cow_wrapper.hxx
+++ b/include/o3tl/cow_wrapper.hxx
@@ -34,7 +34,7 @@ namespace o3tl
  */
 struct UnsafeRefCountingPolicy
 {
-typedef sal_uInt32 ref_count_t;
+typedef sal_Size ref_count_t;
 static void incrementCount( ref_count_t& rCount ) { ++rCount; }
 static bool decrementCount( ref_count_t& rCount ) { return --rCount != 
0; }
 };
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Miklos Vajna
 external/liborcus/UnpackedTarball_liborcus.mk |5 +
 external/liborcus/android-workaround.patch|   22 ++
 2 files changed, 27 insertions(+)

New commits:
commit c2673a358c78b864c1276f7956d5a348003b7a02
Author: Miklos Vajna 
Date:   Mon Sep 19 10:14:50 2016 +0200

liborcus: fix Android build

stoi() is missing in the std namespace on the broken Android toolchain,
work it around.

Change-Id: I9ea4f89bea346a4383fbb99e03b09ebae43d21e5

diff --git a/external/liborcus/UnpackedTarball_liborcus.mk 
b/external/liborcus/UnpackedTarball_liborcus.mk
index 08f3423..09b3c28 100644
--- a/external/liborcus/UnpackedTarball_liborcus.mk
+++ b/external/liborcus/UnpackedTarball_liborcus.mk
@@ -23,6 +23,11 @@ $(eval $(call gb_UnpackedTarball_add_patches,liborcus,\
external/liborcus/windows-constants-hack.patch \
 ))
 endif
+ifeq ($(OS),ANDROID)
+$(eval $(call gb_UnpackedTarball_add_patches,liborcus,\
+   external/liborcus/android-workaround.patch \
+))
+endif
 
 
 # vim: set noet sw=4 ts=4:
diff --git a/external/liborcus/android-workaround.patch 
b/external/liborcus/android-workaround.patch
new file mode 100644
index 000..f9d047d
--- /dev/null
+++ b/external/liborcus/android-workaround.patch
@@ -0,0 +1,22 @@
+diff --git a/src/parser/sax_parser_base.cpp b/src/parser/sax_parser_base.cpp
+index 743130d..2624bd5 100644
+--- a/src/parser/sax_parser_base.cpp
 b/src/parser/sax_parser_base.cpp
+@@ -12,6 +12,17 @@
+ #include 
+ #include 
+ 
++#ifdef __ANDROID__
++namespace std
++{
++int stoi(const std::string& str, std::size_t* /*pos*/ = 0, int base = 10)
++{
++char* end;
++return strtol(str.c_str(), &end, base);
++}
++}
++#endif
++
+ namespace orcus { namespace sax {
+ 
+ malformed_xml_error::malformed_xml_error(const std::string& msg, 
std::ptrdiff_t offset) :
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Caolán McNamara
 vcl/inc/unx/gtk/gtkinst.hxx   |3 +++
 vcl/unx/gtk/gtkinst.cxx   |   21 -
 vcl/unx/gtk/gtksalframe.cxx   |   16 +++-
 vcl/unx/gtk3/gtk3gtkframe.cxx |   16 +++-
 4 files changed, 53 insertions(+), 3 deletions(-)

New commits:
commit 29c55564070aa1fa7846448a6ca90fe47c38bd0a
Author: Caolán McNamara 
Date:   Mon Sep 19 09:26:22 2016 +0100

Related: rhbz#1373933 gtk3 emits a lot of style-updateds signals

so don't throw away font settings every time, check if the font settings
changed and only emit FontChanged if they differ from the last seen 
settings.

Change-Id: I129887e3e866f395da3b906a38cf568abea5de8e

diff --git a/vcl/inc/unx/gtk/gtkinst.hxx b/vcl/inc/unx/gtk/gtkinst.hxx
index 490cf69..514b13f 100644
--- a/vcl/inc/unx/gtk/gtkinst.hxx
+++ b/vcl/inc/unx/gtk/gtkinst.hxx
@@ -242,6 +242,8 @@ public:
 #endif
 
 virtual const cairo_font_options_t* GetCairoFontOptions() override;
+const cairo_font_options_t* GetLastSeenCairoFontOptions();
+   void ResetLastSeenCairoFontOptions();
 
 voidRemoveTimer (SalTimer *pTimer);
 
@@ -254,6 +256,7 @@ private:
 #endif
 boolIsTimerExpired();
 boolbNeedsInit;
+cairo_font_options_t*   m_pLastCairoFontOptions;
 
 mutable std::shared_ptr m_xPrintWrapper;
 };
diff --git a/vcl/unx/gtk/gtkinst.cxx b/vcl/unx/gtk/gtkinst.cxx
index 0f62467..9a535f0 100644
--- a/vcl/unx/gtk/gtkinst.cxx
+++ b/vcl/unx/gtk/gtkinst.cxx
@@ -155,6 +155,7 @@ GtkInstance::GtkInstance( SalYieldMutex* pMutex )
 : X11SalInstance( pMutex )
 #endif
 , bNeedsInit(true)
+, m_pLastCairoFontOptions(nullptr)
 {
 }
 
@@ -200,6 +201,7 @@ GtkInstance::~GtkInstance()
 while( !m_aTimers.empty() )
 delete *m_aTimers.begin();
 DeInitAtkBridge();
+ResetLastSeenCairoFontOptions();
 }
 
 SalFrame* GtkInstance::CreateFrame( SalFrame* pParent, SalFrameStyleFlags 
nStyle )
@@ -483,7 +485,24 @@ GtkInstance::getPrintWrapper() const
 
 const cairo_font_options_t* GtkInstance::GetCairoFontOptions()
 {
-return gdk_screen_get_font_options(gdk_screen_get_default());
+const cairo_font_options_t* pCairoFontOptions = 
gdk_screen_get_font_options(gdk_screen_get_default());
+if (!m_pLastCairoFontOptions && pCairoFontOptions)
+m_pLastCairoFontOptions = cairo_font_options_copy(pCairoFontOptions);
+return pCairoFontOptions;
+}
+
+const cairo_font_options_t* GtkInstance::GetLastSeenCairoFontOptions()
+{
+return m_pLastCairoFontOptions;
+}
+
+void GtkInstance::ResetLastSeenCairoFontOptions()
+{
+if (m_pLastCairoFontOptions)
+{
+cairo_font_options_destroy(m_pLastCairoFontOptions);
+m_pLastCairoFontOptions = nullptr;
+}
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/unx/gtk/gtksalframe.cxx b/vcl/unx/gtk/gtksalframe.cxx
index 0d872cf..9167a3f 100644
--- a/vcl/unx/gtk/gtksalframe.cxx
+++ b/vcl/unx/gtk/gtksalframe.cxx
@@ -3235,7 +3235,21 @@ void GtkSalFrame::signalStyleSet( GtkWidget*, GtkStyle* 
pPrevious, gpointer fram
 // so post user event to safely dispatch the SalEvent::SettingsChanged
 // note: settings changed for multiple frames is avoided in 
winproc.cxx ImplHandleSettings
 GtkSalFrame::getDisplay()->SendInternalEvent( pThis, nullptr, 
SalEvent::SettingsChanged );
-GtkSalFrame::getDisplay()->SendInternalEvent( pThis, nullptr, 
SalEvent::FontChanged );
+
+// fire off font-changed when the system cairo font hints change
+GtkInstance *pInstance = 
static_cast(GetSalData()->m_pInstance);
+const cairo_font_options_t* pLastCairoFontOptions = 
pInstance->GetLastSeenCairoFontOptions();
+const cairo_font_options_t* pCurrentCairoFontOptions = 
gdk_screen_get_font_options(gdk_screen_get_default());
+bool bFontSettingsChanged = true;
+if (pLastCairoFontOptions && pCurrentCairoFontOptions)
+bFontSettingsChanged = 
!cairo_font_options_equal(pLastCairoFontOptions, pCurrentCairoFontOptions);
+else if (!pLastCairoFontOptions && !pCurrentCairoFontOptions)
+bFontSettingsChanged = false;
+if (bFontSettingsChanged)
+{
+pInstance->ResetLastSeenCairoFontOptions();
+GtkSalFrame::getDisplay()->SendInternalEvent( pThis, nullptr, 
SalEvent::FontChanged );
+}
 }
 
 /* #i64117# gtk sets a nice background pixmap
diff --git a/vcl/unx/gtk3/gtk3gtkframe.cxx b/vcl/unx/gtk3/gtk3gtkframe.cxx
index 49bce84..3d3fc9e 100644
--- a/vcl/unx/gtk3/gtk3gtkframe.cxx
+++ b/vcl/unx/gtk3/gtk3gtkframe.cxx
@@ -3107,7 +3107,21 @@ void GtkSalFrame::signalStyleUpdated(GtkWidget*, 
gpointer frame)
 
 // note: settings changed for multiple frames is avoided in winproc.cxx 
ImplHandleSettings
 GtkSalFrame::getDisplay()->SendInternalEvent( pThis, nullptr, 
SalEvent::SettingsChanged );
-GtkSalFr

[Libreoffice-commits] core.git: Branch 'refs/notes/commits' - a4/4afc71e63fe8c61b20d30effa1acb7dcaf07c1

2016-09-19 Thread Caolán McNamara
 a4/4afc71e63fe8c61b20d30effa1acb7dcaf07c1 |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 83edeeac69fde7e458a4d9583986be009082691c
Author: Caolán McNamara 
Date:   Mon Sep 19 09:30:32 2016 +0100

Notes added by 'git notes add'

diff --git a/a4/4afc71e63fe8c61b20d30effa1acb7dcaf07c1 
b/a4/4afc71e63fe8c61b20d30effa1acb7dcaf07c1
new file mode 100644
index 000..8e5c182
--- /dev/null
+++ b/a4/4afc71e63fe8c61b20d30effa1acb7dcaf07c1
@@ -0,0 +1 @@
+ignore: aoo
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: readlicense_oo/license

2016-09-19 Thread Caolán McNamara
 readlicense_oo/license/NOTICE |6 --
 1 file changed, 6 deletions(-)

New commits:
commit c9805c52264eb99b3d73f9038da716ac94501502
Author: Caolán McNamara 
Date:   Mon Sep 19 09:48:28 2016 +0100

Remove mention of NSIS from NOTICE cause we don't use it...

since

commit 2ba4a4bf6384cd57664d316dd479bddfa38760d6
Author: Andras Timar 
Date:   Tue Dec 6 19:28:21 2011 +0100

remove NSIS support

Change-Id: I2388acbcefbb9d7422d49c28e1a0a24f80fc1c1d

diff --git a/readlicense_oo/license/NOTICE b/readlicense_oo/license/NOTICE
index be31ed4..46b7fcc 100644
--- a/readlicense_oo/license/NOTICE
+++ b/readlicense_oo/license/NOTICE
@@ -124,12 +124,6 @@ the MX4J package, which is open source software.  The
 original software and related information is available
 at http://mx4j.sourceforge.net/.
 
-The Windows Installer is built with the Nullsoft
-Scriptable Install System (NSIS), which is
-open source software.  The original software and
-related information is available at
-http://nsis.sourceforge.net/.
-
 Java compilation software for JSP pages is provided by Eclipse, 
 which is open source software.  The original software and 
 related information is available at
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: How to keep UNO applications connected after closing LibreOffice

2016-09-19 Thread Stephan Bergmann

On 09/16/2016 03:39 PM, Samuel Mehrbrodt wrote:

We have the following case:
You have an application conntected to LO via UNO. The user then
separately starts a (Start center) window. When he closes it, LO gets
terminated and the external application loses the connection. We want to
prevent thatso that the external application keeps working.


The usual pragmatic solution is to use an explicit UserInstallation for 
the external application.



We could use a TerminationVetoException

in the external application to prevent LO from terminating. But this has
the side effect that the user can no longer close the Start center.

Basically we have two options how to fix this:

 1. Change the behavior of LO such that the TerminationVetoException
allows closing the last window, but still prevents terminating the
soffice process


At least for desktop environments that do not clearly indicate that an 
app is still running when its last window is closed, one downside of 
this could be that users might not be aware of LO still running when 
they intended to close it.



 2. Change the behavior of LO such that an open UNO connection counts as
an open window, and the process doesn't get terminated until all
connections are closed.
This option would not need a TerminationVetoException.

Both options do change existing behavior and will possible break
existing applications/workflows out there. So the decision should be
made carefully.

I probably would go for the first one, since the
TerminationVetoException suggests that it will prevent termination. It
shouldn't affect closing a window.
Although I would also consider it as a bug that LO terminates (when
closing a window) while it still has active connections.

Any input on this?


I think I'd be fine with improvements in either direction.

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


[Libreoffice-commits] online.git: loolwsd/ChildSession.cpp loolwsd/ChildSession.hpp loolwsd/ClientSession.cpp loolwsd/ClientSession.hpp loolwsd/DocumentBroker.cpp loolwsd/LOOLForKit.cpp loolwsd/LOOLKi

2016-09-19 Thread Tor Lillqvist
 loolwsd/ChildSession.cpp|   80 ---
 loolwsd/ChildSession.hpp|1 
 loolwsd/ClientSession.cpp   |   13 +--
 loolwsd/ClientSession.hpp   |9 --
 loolwsd/DocumentBroker.cpp  |   77 ++
 loolwsd/LOOLForKit.cpp  |3 
 loolwsd/LOOLKit.cpp |   57 +---
 loolwsd/PrisonerSession.cpp |3 
 loolwsd/sysconfig.loolwsd   |1 
 loolwsd/test/httpwstest.cpp |  149 
 10 files changed, 90 insertions(+), 303 deletions(-)

New commits:
commit df3cc99025139e7e47e82d855b520df6a1548224
Author: Tor Lillqvist 
Date:   Mon Sep 19 10:03:31 2016 +0300

Don't require the LOK_VIEW_CALLLBACK env var any more

Act as if it was always set.

The ChildSession::_multiView field will always be true, so factor it
out. Ditto for Document::_multiView.

The ClientSession::_haveEditLock will also be always true, so factor
it out. This means the ClientSession::isEditLocked() will always
return true, so factor it out, too.

ClientSession::markEditLock() always will always set _haveEditLock to
true (which it will be from the constructor already anyway) so it can
be removed.

ClientSession::setEditLock() does not need a parameter as the
parameter was actually only used for misleading logging. The msg
variable constructed in the function used isEditLocked(), not the
parameter.

We still generate and handle editlock messages. Not sure whether that
makes any sense, though.

diff --git a/loolwsd/ChildSession.cpp b/loolwsd/ChildSession.cpp
index 2e44eeb..a5a7778 100644
--- a/loolwsd/ChildSession.cpp
+++ b/loolwsd/ChildSession.cpp
@@ -39,7 +39,6 @@ ChildSession::ChildSession(const std::string& id,
const std::string& jailId,
IDocumentManager& docManager) :
 LOOLSession(id, Kind::ToMaster, ws),
-_multiView(std::getenv("LOK_VIEW_CALLBACK")),
 _jailId(jailId),
 _docManager(docManager),
 _viewId(-1),
@@ -94,8 +93,7 @@ bool ChildSession::_handleInput(const char *buffer, int 
length)
 // Send invalidation and other sync-up messages.
 std::unique_lock lock(Mutex); //TODO: Move to 
top of function?
 
-if (_multiView)
-_loKitDocument->setView(_viewId);
+_loKitDocument->setView(_viewId);
 
 // Refresh the viewIds.
 sendTextFrame("remallviews:");
@@ -323,20 +321,17 @@ bool ChildSession::loadDocument(const char * /*buffer*/, 
int /*length*/, StringT
 return false;
 }
 
-if (_multiView)
-{
-std::ostringstream ossViewInfo;
-const auto viewId = std::to_string(_viewId);
+std::ostringstream ossViewInfo;
+const auto viewId = std::to_string(_viewId);
 
-// Create a message object
-Object::Ptr viewInfoObj = new Object();
-viewInfoObj->set("id", viewId);
-viewInfoObj->set("username", _userName);
-viewInfoObj->stringify(ossViewInfo);
+// Create a message object
+Object::Ptr viewInfoObj = new Object();
+viewInfoObj->set("id", viewId);
+viewInfoObj->set("username", _userName);
+viewInfoObj->stringify(ossViewInfo);
 
-Log::info("Created new view with viewid: [" + viewId + "] for 
username: [" + _userName + "].");
-_docManager.notifyOtherSessions(getId(), "addview: " + 
ossViewInfo.str());
-}
+Log::info("Created new view with viewid: [" + viewId + "] for username: [" 
+ _userName + "].");
+_docManager.notifyOtherSessions(getId(), "addview: " + ossViewInfo.str());
 
 _docType = LOKitHelper::getDocumentTypeAsString(_loKitDocument->get());
 if (_docType != "text" && part != -1)
@@ -373,8 +368,7 @@ bool ChildSession::sendFontRendering(const char* 
/*buffer*/, int /*length*/, Str
 
 std::unique_lock lock(Mutex);
 
-if (_multiView)
-   _loKitDocument->setView(_viewId);
+_loKitDocument->setView(_viewId);
 
 URI::decode(font, decodedFont);
 std::string response = "renderfont: " + Poco::cat(std::string(" "), 
tokens.begin() + 1, tokens.end()) + "\n";
@@ -403,8 +397,7 @@ bool ChildSession::getStatus(const char* /*buffer*/, int 
/*length*/)
 {
 std::unique_lock lock(Mutex);
 
-if (_multiView)
-_loKitDocument->setView(_viewId);
+_loKitDocument->setView(_viewId);
 
 const auto status = LOKitHelper::documentStatus(_loKitDocument->get());
 if (status.empty())
@@ -429,8 +422,7 @@ bool ChildSession::getCommandValues(const char* /*buffer*/, 
int /*length*/, Stri
 
 std::unique_lock lock(Mutex);
 
-if (_multiView)
-_loKitDocument->setView(_viewId);
+_loKitDocument->setView(_viewId);
 
 if (command == ".uno:DocumentRepair")
 {
@@ -456,8 +448,7 @@ bool ChildSession::getPartPageRectangles(const char* 
/*buffer*/, int /*length*/)
 {
 std::unique_lock lock(Mutex);
 
-if (_multiView)
-_loKitDocument->setView(_viewId);
+_loKitDo

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

2016-09-19 Thread Miklos Vajna
 sw/source/core/access/accportions.cxx |  272 +-
 sw/source/core/access/accportions.hxx |   30 +--
 2 files changed, 151 insertions(+), 151 deletions(-)

New commits:
commit 96646c351e20fa6699fa368457a05ee70f76f103
Author: Miklos Vajna 
Date:   Mon Sep 19 09:07:48 2016 +0200

sw: prefix members of SwAccessiblePortionData

Change-Id: Ia41a57b11e2df5261657855e92701dce4cbe95aa

diff --git a/sw/source/core/access/accportions.cxx 
b/sw/source/core/access/accportions.cxx
index 315b83f..2efc1f6 100644
--- a/sw/source/core/access/accportions.cxx
+++ b/sw/source/core/access/accportions.cxx
@@ -69,78 +69,78 @@ SwAccessiblePortionData::SwAccessiblePortionData(
 const SwTextNode* pTextNd,
 const SwViewOption* pViewOpt ) :
 SwPortionHandler(),
-pTextNode( pTextNd ),
-aBuffer(),
-nModelPosition( 0 ),
-pViewOptions( pViewOpt ),
-sAccessibleString(),
-aLineBreaks(),
-aModelPositions(),
-aAccessiblePositions(),
-aFieldPosition(),
-aAttrFieldType(),
-aPortionAttrs(),
-pSentences( nullptr ),
-nBeforePortions( 0 ),
-bFinished( false ),
-bLastIsSpecial( false )
-{
-OSL_ENSURE( pTextNode != nullptr, "Text node is needed!" );
+m_pTextNode( pTextNd ),
+m_aBuffer(),
+m_nModelPosition( 0 ),
+m_pViewOptions( pViewOpt ),
+m_sAccessibleString(),
+m_aLineBreaks(),
+m_aModelPositions(),
+m_aAccessiblePositions(),
+m_aFieldPosition(),
+m_aAttrFieldType(),
+m_aPortionAttrs(),
+m_pSentences( nullptr ),
+m_nBeforePortions( 0 ),
+m_bFinished( false ),
+m_bLastIsSpecial( false )
+{
+OSL_ENSURE( m_pTextNode != nullptr, "Text node is needed!" );
 
 // reserve some space to reduce memory allocations
-aLineBreaks.reserve( 5 );
-aModelPositions.reserve( 10 );
-aAccessiblePositions.reserve( 10 );
+m_aLineBreaks.reserve( 5 );
+m_aModelPositions.reserve( 10 );
+m_aAccessiblePositions.reserve( 10 );
 
 // always include 'first' line-break position
-aLineBreaks.push_back( 0 );
+m_aLineBreaks.push_back( 0 );
 }
 
 SwAccessiblePortionData::~SwAccessiblePortionData()
 {
-delete pSentences;
+delete m_pSentences;
 }
 
 void SwAccessiblePortionData::Text(sal_Int32 nLength, sal_uInt16 nType, 
sal_Int32 /*nHeight*/, sal_Int32 /*nWidth*/)
 {
-OSL_ENSURE( (nModelPosition + nLength) <= pTextNode->GetText().getLength(),
+OSL_ENSURE( (m_nModelPosition + nLength) <= 
m_pTextNode->GetText().getLength(),
 "portion exceeds model string!" );
 
-OSL_ENSURE( !bFinished, "We are already done!" );
+OSL_ENSURE( !m_bFinished, "We are already done!" );
 
 // ignore zero-length portions
 if( nLength == 0 )
 return;
 
 // store 'old' positions
-aModelPositions.push_back( nModelPosition );
-aAccessiblePositions.push_back( aBuffer.getLength() );
+m_aModelPositions.push_back( m_nModelPosition );
+m_aAccessiblePositions.push_back( m_aBuffer.getLength() );
 
 // store portion attributes
 sal_uInt8 nAttr = IsGrayPortionType(nType) ? PORATTR_GRAY : 0;
-aPortionAttrs.push_back( nAttr );
+m_aPortionAttrs.push_back( nAttr );
 
 // update buffer + nModelPosition
-aBuffer.append( pTextNode->GetText().copy(nModelPosition, nLength) );
-nModelPosition += nLength;
+m_aBuffer.append( m_pTextNode->GetText().copy(m_nModelPosition, nLength) );
+m_nModelPosition += nLength;
 
-bLastIsSpecial = false;
+m_bLastIsSpecial = false;
 }
 
 void SwAccessiblePortionData::SetAttrFieldType( sal_uInt16 nAttrFieldType )
 {
-aAttrFieldType.push_back(nAttrFieldType);
+m_aAttrFieldType.push_back(nAttrFieldType);
 return;
 }
 
 void SwAccessiblePortionData::Special(
 sal_Int32 nLength, const OUString& rText, sal_uInt16 nType, sal_Int32 
/*nHeight*/, sal_Int32 /*nWidth*/, const SwFont* /*pFont*/)
 {
-OSL_ENSURE( nModelPosition >= 0, "illegal position" );
-OSL_ENSURE( (nModelPosition + nLength) <= pTextNode->GetText().getLength(),
+OSL_ENSURE( m_nModelPosition >= 0, "illegal position" );
+OSL_ENSURE( (m_nModelPosition + nLength) <= 
m_pTextNode->GetText().getLength(),
 "portion exceeds model string!" );
 
-OSL_ENSURE( !bFinished, "We are already done!" );
+OSL_ENSURE( !m_bFinished, "We are already done!" );
 
 // construct string with representation; either directly from
 // rText, or use resources for special case portions
@@ -160,15 +160,15 @@ void SwAccessiblePortionData::Special(
 sDisplay = OUString(sal_Unicode(0xfffc));
 else
 sDisplay = rText;
-aFieldPosition.push_back(aBuffer.getLength());
-aFieldPosition.push_back(aBuffer.getLength() + rText.getLength());
+m_aFieldPosition.push_back(m_aBuffer.getLength());
+m_aFieldPosition.push_back(m_aBuffer.getLength() + 
rText.getLength());
 break;
 case POR_FTN

Re: Test File: sc/qa/unit/data/functions/fods/chiinv.fods: fails with Assertion

2016-09-19 Thread Alex McMurchy

I shall give this a whirl.

Stephan Bergmann wrote


Turns out, the relevant GCC switches are

  -mfpmath=sse -msse2


Alex

On 16/09/16 11:05, Stephan Bergmann wrote:

On 09/07/2016 10:37 PM, Eike Rathke wrote:

You could do us a favour, are you willing to invest some machine time
and try if passing either -msse or -msse2 as compiler flags would solve
the failing function tests problem? For this you'd need to do

make clean
make ENVCFLAGS=-msse ENVCFLAGSCXX=-msse && make sc.check

and if that still fails try

make clean
make ENVCFLAGS=-msse2 ENVCFLAGSCXX=-msse2 && make sc.check


Turns out, the relevant GCC switches are

  -mfpmath=sse -msse2

-mfpmath=sse (instead of the x86-32 default of -mfpmath=387) prevents 
usage of the extended 80-bit precision for temporary results. (Which 
caused e.g. the subtraction in ScChiDistFunction::GetValue, 
sc/source/core/tool/interpr3.cxx, to produce results different from 
IEEE double, causing the computation of CHIINV(0.999, 
1.00E+001) in sc/qa/unit/data/functions/fods/chiinv.fods 
to produce unexpected results.) 
 
also claims: "The resulting code should be considerably faster 
[compared to -mfpmath=387] in the majority of cases and avoid the 
numerical instability problems of 387 code [...]"


But -mfpmath=sse only takes effect when compiling for an architecture 
that actually supports the relevant SSE instructions (otherwise 
silently falling back to the "387" instructions, it appears).  So we 
need an additional -msse2 to enable the instructions relevant for 
64-bit double (-msse would only enable instructions relevant for 
32-bit float).


SSE2 support reportedly got added with Pentium 4, around 2001. Any 
thoughts on whether we'd want to enforce that for 32-bit x86 Linux 
builds (or already effectively enforce anyway)?  In which case we 
could add the relevant flags to 
solenv/gbuild/platform/LINUX_INTEL_GCC.mk and revert 
 
"sc: disable function test documents for 32-bit PLATFORMID=linux_x86" 
again.


(Notwithstanding the fact that tests that rely on Calc doing 
computations in a specific way, when Calc doesn't give any guarantees 
of how those computations should be carried out exactly AFAIK, are 
dubious and a pain at best.)

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


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


[Libreoffice-commits] online.git: 2 commits - loleaflet/src loolwsd/ChildSession.cpp

2016-09-19 Thread Pranav Kant
 loleaflet/src/control/Control.DocumentRepair.js |2 +-
 loolwsd/ChildSession.cpp|3 +++
 2 files changed, 4 insertions(+), 1 deletion(-)

New commits:
commit 1fbceb9f683957a42984d408d859da306a634c32
Author: Pranav Kant 
Date:   Mon Sep 19 14:45:15 2016 +0530

loolwsd: Forward REDLINE_TABLE_ENTRY_MODIFIED messages

Change-Id: Ib666c1ebf9165c795fcefb56a2ea3919d60c8ac4

diff --git a/loolwsd/ChildSession.cpp b/loolwsd/ChildSession.cpp
index a5a7778..17cf397 100644
--- a/loolwsd/ChildSession.cpp
+++ b/loolwsd/ChildSession.cpp
@@ -1070,6 +1070,9 @@ void ChildSession::loKitCallback(const int nType, const 
std::string& rPayload)
 case LOK_CALLBACK_REDLINE_TABLE_SIZE_CHANGED:
 sendTextFrame("redlinetablechanged: " + rPayload);
 break;
+case LOK_CALLBACK_REDLINE_TABLE_ENTRY_MODIFIED:
+sendTextFrame("redlinetablemodified: " + rPayload);
+break;
 default:
 Log::error("Unknown callback event (" + std::to_string(nType) + "): " 
+ rPayload);
 }
commit f5a9e8e33d7c921575b0354070bbcb4cea02a3fc
Author: Pranav Kant 
Date:   Sun Sep 18 22:22:38 2016 +0530

loleaflet: l10n: Repair Document

Change-Id: I3b320547a25094fbfa2d1538b4fa1e91b2cf41ad

diff --git a/loleaflet/src/control/Control.DocumentRepair.js 
b/loleaflet/src/control/Control.DocumentRepair.js
index 36fbc53..365d21d 100644
--- a/loleaflet/src/control/Control.DocumentRepair.js
+++ b/loleaflet/src/control/Control.DocumentRepair.js
@@ -29,7 +29,7 @@ L.Control.DocumentRepair = L.Control.extend({
var wrapper = L.DomUtil.create('div', 
'leaflet-popup-content-wrapper', this._container);
var content = L.DomUtil.create('div', 'leaflet-popup-content', 
wrapper);
var labelTitle = document.createElement('span');
-   labelTitle.innerHTML = 'Repair Document';
+   labelTitle.innerHTML = '' + _('Repair Document') + '';
content.appendChild(labelTitle);
content.appendChild(document.createElement('br'));
content.appendChild(document.createElement('br'));
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Markus Mohrhard
 sc/Library_sc.mk  |1 
 sc/inc/scabstdlg.hxx  |4 
 sc/inc/scitems.hxx|3 
 sc/source/ui/app/msgpool.cxx  |4 
 sc/source/ui/attrdlg/scdlgfact.cxx|7 
 sc/source/ui/attrdlg/scdlgfact.hxx|4 
 sc/source/ui/condformat/condformatdlg.cxx |  214 +++---
 sc/source/ui/condformat/condformatdlgitem.cxx |   77 +
 sc/source/ui/condformat/condformatmgr.cxx |   13 +
 sc/source/ui/inc/condformatdlg.hxx|   33 
 sc/source/ui/inc/condformatdlgitem.hxx|   68 
 sc/source/ui/inc/condformatmgr.hxx|3 
 sc/source/ui/inc/msgpool.hxx  |2 
 sc/source/ui/view/cellsh1.cxx |   74 +---
 sc/source/ui/view/tabvwshc.cxx|   47 +
 15 files changed, 299 insertions(+), 255 deletions(-)

New commits:
commit 5b8c22379e2eae74f7ed78326ab89483db5c6624
Author: Markus Mohrhard 
Date:   Sun Sep 18 16:14:35 2016 +0200

tdf#96453, tdf#100793 rework transfer of data between cond format dlgs

The xml based transfer of information was a bad idea from the start. It
can obviously not transport the temporary conditional format information
from the manager dialog. Therefore the whole handling here was
completely broken and deleted formats came back, changed formats were
not saved and added formats got applied directly to the document.

Now the document fornat list and the one from the manager are indepedent
again and as long as the manager has not been closed with ok nothing is
written to the document.

Change-Id: I9802be11cd15c2d2d877e55c91d836735fe0e0ff
Reviewed-on: https://gerrit.libreoffice.org/28995
Reviewed-by: Markus Mohrhard 
Tested-by: Markus Mohrhard 

diff --git a/sc/Library_sc.mk b/sc/Library_sc.mk
index fd20f76..bf75fb1 100644
--- a/sc/Library_sc.mk
+++ b/sc/Library_sc.mk
@@ -388,6 +388,7 @@ $(eval $(call gb_Library_add_exception_objects,sc,\
 sc/source/ui/cctrl/tbzoomsliderctrl \
 sc/source/ui/condformat/condformatdlg \
 sc/source/ui/condformat/condformatdlgentry \
+sc/source/ui/condformat/condformatdlgitem \
 sc/source/ui/condformat/condformathelper \
 sc/source/ui/condformat/colorformat \
 sc/source/ui/dbgui/asciiopt \
diff --git a/sc/inc/scabstdlg.hxx b/sc/inc/scabstdlg.hxx
index b601d5f..bf939b9 100644
--- a/sc/inc/scabstdlg.hxx
+++ b/sc/inc/scabstdlg.hxx
@@ -79,7 +79,9 @@ class AbstractScCondFormatManagerDlg : public 
VclAbstractDialog
 public:
 virtual ScConditionalFormatList* GetConditionalFormatList() = 0;
 
-virtual bool CondFormatsChanged() = 0;
+virtual bool CondFormatsChanged() const = 0;
+
+virtual void SetModified() = 0;
 
 virtual ScConditionalFormat* GetCondFormatSelected() = 0;
 };
diff --git a/sc/inc/scitems.hxx b/sc/inc/scitems.hxx
index 4e7adb1..6664e91 100644
--- a/sc/inc/scitems.hxx
+++ b/sc/inc/scitems.hxx
@@ -41,8 +41,9 @@
 #define SCITEM_SOLVEDATA1107
 #define SCITEM_USERLIST 1108
 #define SCITEM_PRINTWARN1109
+#define SCITEM_CONDFORMATDLGDATA1110
 
-#define MSGPOOL_END 1109
+#define MSGPOOL_END 1110
 
 // Item-IDs for attributes:
 
diff --git a/sc/source/ui/app/msgpool.cxx b/sc/source/ui/app/msgpool.cxx
index 9eac708..5509647 100644
--- a/sc/source/ui/app/msgpool.cxx
+++ b/sc/source/ui/app/msgpool.cxx
@@ -53,7 +53,8 @@ ScMessagePool::ScMessagePool()
 aGlobalSolveItem( ScSolveItem   ( SCITEM_SOLVEDATA, 
nullptr ) ),
 aGlobalUserListItem ( ScUserListItem( SCITEM_USERLIST ) ),
 
-aPrintWarnItem  ( SfxBoolItem   ( SCITEM_PRINTWARN, false 
) )
+aPrintWarnItem  ( SfxBoolItem   ( SCITEM_PRINTWARN, false 
) ),
+aCondFormatDlgItem  ( ScCondFormatDlgItem   ( nullptr, -1, false ) )
 {
 ppPoolDefaults = new SfxPoolItem*[MSGPOOL_END - MSGPOOL_START + 1];
 
@@ -67,6 +68,7 @@ ScMessagePool::ScMessagePool()
 ppPoolDefaults[SCITEM_SOLVEDATA - MSGPOOL_START] = 
&aGlobalSolveItem;
 ppPoolDefaults[SCITEM_USERLIST  - MSGPOOL_START] = 
&aGlobalUserListItem;
 ppPoolDefaults[SCITEM_PRINTWARN - MSGPOOL_START] = &aPrintWarnItem;
+ppPoolDefaults[SCITEM_CONDFORMATDLGDATA - MSGPOOL_START] = 
&aCondFormatDlgItem;
 
 SetDefaults( ppPoolDefaults );
 
diff --git a/sc/source/ui/attrdlg/scdlgfact.cxx 
b/sc/source/ui/attrdlg/scdlgfact.cxx
index 91258f7..e2bd407 100644
--- a/sc/source/ui/attrdlg/scdlgfact.cxx
+++ b/sc/source/ui/attrdlg/scdlgfact.cxx
@@ -422,11 +422,16 @@ ScConditionalFormatList* 
AbstractScCondFormatManagerDlg_Impl::GetConditionalForm
 return pDlg->GetConditionalFormatList();
 }
 
-bool AbstractScCondFormatManagerDlg_Impl::CondFormatsChanged()
+bool AbstractScCondFormatManagerDlg_Impl::CondFormatsChanged() const
 {
 return pDlg->CondFormatsChan

[Libreoffice-commits] core.git: Changes to 'feature/fixes36'

2016-09-19 Thread Stephan Bergmann
New branch 'feature/fixes36' available with the following commits:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Code Contributor Statement

2016-09-19 Thread Jan Iversen
WELCOME
Thanks for your license statement.

I have added you to our wiki:
https://wiki.documentfoundation.org/Development/Developers

If you want help to get started or have any questions, then please contact me. 
I am here to help you (and others) in getting their first patch submitted.

LibreOffice is a very big program and getting it built, setting up gerrit, and 
getting the first patch right can be a bit challenging, therefore do not 
hesitate to email me if you want help.

We have made a step by step guide to help you get started:
https://wiki.documentfoundation.org/Development/GetInvolved

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


[Libreoffice-commits] online.git: 2 commits - loolwsd/test

2016-09-19 Thread Tor Lillqvist
 loolwsd/test/httpwstest.cpp |   23 ---
 1 file changed, 12 insertions(+), 11 deletions(-)

New commits:
commit 2f12308ca211d597b012159cf41f9bba16542b3e
Author: Tor Lillqvist 
Date:   Mon Sep 19 13:09:35 2016 +0300

Presumably a graphicviewselection: message is OK, too

Fixes the testInactiveClient unit test.

diff --git a/loolwsd/test/httpwstest.cpp b/loolwsd/test/httpwstest.cpp
index abadbb4..14ecd3d 100644
--- a/loolwsd/test/httpwstest.cpp
+++ b/loolwsd/test/httpwstest.cpp
@@ -1020,6 +1020,7 @@ void HTTPWSTest::testInactiveClient()
 token == "cursorvisible:" ||
 token == "editlock:" ||
 token == "graphicselection:" ||
+token == "graphicviewselection:" ||
 token == "invalidatecursor:" ||
 token == "invalidatetiles:" ||
 token == "invalidateviewcursor:" ||
commit 1febbe72ae9f152ed7a37341392f880ebdcce93b
Author: Tor Lillqvist 
Date:   Mon Sep 19 13:09:12 2016 +0300

Sort lines for sanity

diff --git a/loolwsd/test/httpwstest.cpp b/loolwsd/test/httpwstest.cpp
index 37e03ec..abadbb4 100644
--- a/loolwsd/test/httpwstest.cpp
+++ b/loolwsd/test/httpwstest.cpp
@@ -1016,21 +1016,21 @@ void HTTPWSTest::testInactiveClient()
 {
 const auto token = LOOLProtocol::getFirstToken(msg);
 CPPUNIT_ASSERT_MESSAGE("unexpected message: " + msg,
-token == "setpart:" ||
-token == "textselection:" ||
-token == "textselectionstart:" ||
-token == "textselectionend:" ||
-token == "invalidatetiles:" ||
-token == "invalidatecursor:" ||
-token == "statechanged:" ||
-token == "graphicselection:" ||
+token == "addview:" ||
 token == "cursorvisible:" ||
 token == "editlock:" ||
-token == "addview:" ||
-token == "remview:" ||
+token == "graphicselection:" ||
+token == "invalidatecursor:" ||
+token == "invalidatetiles:" ||
+token == "invalidateviewcursor:" ||
 token == "remallviews:" ||
+token == "remview:" ||
+token == "setpart:" ||
+token == "statechanged:" ||
+token == "textselection:" ||
+token == "textselectionend:" ||
+token == "textselectionstart:" ||
 token == "textviewselection:" ||
-token == "invalidateviewcursor:" ||
 token == "viewcursorvisible:");
 
 // End when we get state changed.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: license statement

2016-09-19 Thread Jan Iversen
WELCOME
Thanks for your license statement.

I have added you to our wiki:
https://wiki.documentfoundation.org/Development/Developers

If you want help to get started or have any questions, then please contact me. 
I am here to help you (and others) in getting their first patch submitted.

LibreOffice is a very big program and getting it built, setting up gerrit, and 
getting the first patch right can be a bit challenging, therefore do not 
hesitate to email me if you want help.

We have made a step by step guide to help you get started:
https://wiki.documentfoundation.org/Development/GetInvolved

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


[Libreoffice-commits] core.git: helpcontent2

2016-09-19 Thread Katarina Behrens
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 6e02ee608c79806d2c08ea131c2bc0fb5d245b29
Author: Katarina Behrens 
Date:   Fri Sep 2 11:27:36 2016 +0200

Updated core
Project: help  da9f009d25a28d75b0c8dabdf57c0e72e505941e

Add couple of screenshots to help files

Change-Id: I5cfe4c7bb48c588aaecb1e9299e8e2b59c680fda
Reviewed-on: https://gerrit.libreoffice.org/28613
Reviewed-by: Eike Rathke 
Tested-by: Eike Rathke 

diff --git a/helpcontent2 b/helpcontent2
index e21bf9f..da9f009 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit e21bf9fa94cae8ec3527bed2aa6b4c71501b65eb
+Subproject commit da9f009d25a28d75b0c8dabdf57c0e72e505941e
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] help.git: 2 commits - source/media source/text

2016-09-19 Thread Gabor Kelemen
 source/media/screenshots/cui/ui/charnamepage/CharNamePage.png  
|binary
 source/media/screenshots/cui/ui/pageformatpage/PageFormatPage.png  
|binary
 source/media/screenshots/modules/scalc/ui/deletecells/DeleteCellsDialog.png
|binary
 source/media/screenshots/modules/sdraw/ui/dlgsnap/SnapObjectDialog.png 
|binary
 
source/media/screenshots/modules/simpress/ui/headerfooterdialog/HeaderFooterDialog.png
 |binary
 source/text/scalc/01/0216.xhp  
|1 +
 source/text/scalc/01/04060109.xhp  
|8 
 source/text/shared/01/05020100.xhp 
|1 +
 source/text/shared/01/05040200.xhp 
|2 ++
 source/text/simpress/01/03152000.xhp   
|1 +
 source/text/simpress/01/0403.xhp   
|1 +
 11 files changed, 10 insertions(+), 4 deletions(-)

New commits:
commit 939edb112114cf3e740012a429d1f69a0d1d9bdb
Author: Gabor Kelemen 
Date:   Mon Sep 19 09:58:08 2016 +0200

tdf#97823 Change VLOOKUP parameter SortOrder to Sorted

Sync with HLOOKUP's Sorted parameter. This is a boolean
indicating if the data is sorted or not, not the order
like ascending or descending.

Change-Id: Ic48de6597c6b1997502c4dffb4a5bb15cbe49d74
Reviewed-on: https://gerrit.libreoffice.org/29013
Reviewed-by: Eike Rathke 
Tested-by: Eike Rathke 

diff --git a/source/text/scalc/01/04060109.xhp 
b/source/text/scalc/01/04060109.xhp
index a9061fc..f1af725 100644
--- a/source/text/scalc/01/04060109.xhp
+++ b/source/text/scalc/01/04060109.xhp
@@ -296,11 +296,11 @@
 
 VLOOKUP
- Vertical search with 
reference to adjacent cells to the right. This function checks if a 
specific value is contained in the first column of an array. The function then 
returns the value in the same row of the column named by Index. If the SortOrder 
parameter is omitted or set to TRUE or one, it is assumed that the data is 
sorted in ascending order. In this case, if the exact SearchCriterion is not found, the last value that is 
smaller than the criterion will be returned. If SortOrder is set to FALSE or zero, an exact match must be 
found, otherwise the error Error: Value Not Available will be the 
result. Thus with a value of zero the data does not need to be sorted in 
ascending order.
+ Vertical search with 
reference to adjacent cells to the right. This function checks if a 
specific value is contained in the first column of an array. The function then 
returns the value in the same row of the column named by Index. If the Sorted 
parameter is omitted or set to TRUE or one, it is assumed that the data is 
sorted in ascending order. In this case, if the exact SearchCriterion is not found, the last value that is 
smaller than the criterion will be returned. If Sorted is set to FALSE or zero, an exact match must be 
found, otherwise the error Error: Value Not Available will be the 
result. Thus with a value of zero the data does not need to be sorted in 
ascending order.
  
  Syntax
- =VLOOKUP(SearchCriterion; Array; Index; SortOrder)
+ =VLOOKUP(SearchCriterion; Array; Index; Sorted)
  
 SearchCriterion is the value searched for in the 
first column of the array.
  
@@ -308,11 +308,11 @@
  
 Index is the number of the column in the array that 
contains the value to be returned. The first column has the number 
1.
  
-SortOrder is an optional parameter that indicates 
whether the first column in the array is sorted in ascending order. Enter the 
Boolean value FALSE or zero if the first column is not sorted in ascending 
order. Sorted columns can be searched much faster and the function always 
returns a value, even if the search value was not matched exactly, if it is 
between the lowest and highest value of the sorted list. In unsorted lists, the 
search value must be matched exactly. Otherwise the function will return this 
message: Error: Value Not Available.
+Sorted is an optional parameter that indicates 
whether the first column in the array is sorted in ascending order. Enter the 
Boolean value FALSE or zero if the first column is not sorted in ascending 
order. Sorted columns can be searched much faster and the function always 
returns a value, even if the search value was not matched exactly, if it is 
between the lowest and highest value of the sorted list. In unsorted lists, the 
search value must be matched exactly. Otherwise the function will return this 
message: Error: Value Not Available.
  
  Example
- You want to enter the number of a dish on the menu in cell 
A1, and the name of the dish is

[Libreoffice-commits] core.git: helpcontent2

2016-09-19 Thread Gabor Kelemen
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit c76366f8b1718d7e658b8bc51921c6c37c386aa2
Author: Gabor Kelemen 
Date:   Mon Sep 19 09:58:08 2016 +0200

Updated core
Project: help  939edb112114cf3e740012a429d1f69a0d1d9bdb

tdf#97823 Change VLOOKUP parameter SortOrder to Sorted

Sync with HLOOKUP's Sorted parameter. This is a boolean
indicating if the data is sorted or not, not the order
like ascending or descending.

Change-Id: Ic48de6597c6b1997502c4dffb4a5bb15cbe49d74
Reviewed-on: https://gerrit.libreoffice.org/29013
Reviewed-by: Eike Rathke 
Tested-by: Eike Rathke 

diff --git a/helpcontent2 b/helpcontent2
index da9f009..939edb1 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit da9f009d25a28d75b0c8dabdf57c0e72e505941e
+Subproject commit 939edb112114cf3e740012a429d1f69a0d1d9bdb
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] help.git: source/text

2016-09-19 Thread Gabor Kelemen
 source/text/scalc/01/04060109.xhp |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f3339c932c24d48eb854399d92cd7ca64fe3ea1c
Author: Gabor Kelemen 
Date:   Mon Sep 19 10:05:39 2016 +0200

tdf#97823 Change SearchCriteria parameter of HLOOKUP

VLOOKUP uses singular, as it looks for one value.
Change it at HLOOKUP so it's both grammatically correct
and matches the parameter in the linked VLOOKUP description.

Change-Id: I4b8247ccb90fb726e3526675b4eba2f6fb51c29e
Reviewed-on: https://gerrit.libreoffice.org/29014
Reviewed-by: Eike Rathke 
Tested-by: Eike Rathke 

diff --git a/source/text/scalc/01/04060109.xhp 
b/source/text/scalc/01/04060109.xhp
index f1af725..8c9688f 100644
--- a/source/text/scalc/01/04060109.xhp
+++ b/source/text/scalc/01/04060109.xhp
@@ -502,7 +502,7 @@
  
  Syntax
- HLOOKUP(SearchCriteria; Array; Index; Sorted)
+ HLOOKUP(SearchCriterion; Array; Index; Sorted)
  See also: VLOOKUP 
(columns and rows are exchanged)
  
   
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: helpcontent2

2016-09-19 Thread Gabor Kelemen
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 2d31990ad0806e74f92841fb8f87db101e1a8fc3
Author: Gabor Kelemen 
Date:   Mon Sep 19 10:05:39 2016 +0200

Updated core
Project: help  f3339c932c24d48eb854399d92cd7ca64fe3ea1c

tdf#97823 Change SearchCriteria parameter of HLOOKUP

VLOOKUP uses singular, as it looks for one value.
Change it at HLOOKUP so it's both grammatically correct
and matches the parameter in the linked VLOOKUP description.

Change-Id: I4b8247ccb90fb726e3526675b4eba2f6fb51c29e
Reviewed-on: https://gerrit.libreoffice.org/29014
Reviewed-by: Eike Rathke 
Tested-by: Eike Rathke 

diff --git a/helpcontent2 b/helpcontent2
index 939edb1..f3339c9 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit 939edb112114cf3e740012a429d1f69a0d1d9bdb
+Subproject commit f3339c932c24d48eb854399d92cd7ca64fe3ea1c
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Stephan Bergmann
 cppuhelper/source/gcc3.map |5 +
 cppuhelper/source/weak.cxx |   10 ++
 include/cppuhelper/weakref.hxx |9 +
 3 files changed, 24 insertions(+)

New commits:
commit 4f86b7a86cae630c19f6f0d1b4d6672c25e2eb3c
Author: Stephan Bergmann 
Date:   Mon Sep 19 12:40:51 2016 +0200

cid#1371142: Move semantics for css::uno::WeakReferenceHelper

Change-Id: I442b2d8061bd7d50cbf832b345a7a63461e26224

diff --git a/cppuhelper/source/gcc3.map b/cppuhelper/source/gcc3.map
index 12c29834a..f1537e8 100644
--- a/cppuhelper/source/gcc3.map
+++ b/cppuhelper/source/gcc3.map
@@ -430,6 +430,11 @@ global:
 
_ZN4cppu15supportsServiceEPN3com3sun4star4lang12XServiceInfoERKN3rtl8OUStringE; 
# cppu::supportsService(com::sun::star::lang::XServiceInfo*, rtl::OUString 
const&)
 } UDK_3.8;
 
+LIBO_UDK_5.3 { # LibO 5.3
+global:
+_ZN3com3sun4star3uno19WeakReferenceHelperaSEOS3_; # 
com::sun::star::uno::WeakReferenceHelper::operator=(com::sun::star::uno::WeakReferenceHelper&&)
+} LIBO_UDK_3.9;
+
 # Unique libstdc++ symbols:
 GLIBCXX_3.4 {
 global:
diff --git a/cppuhelper/source/weak.cxx b/cppuhelper/source/weak.cxx
index 1c9b57c..9a3a8ba 100644
--- a/cppuhelper/source/weak.cxx
+++ b/cppuhelper/source/weak.cxx
@@ -24,7 +24,9 @@
 #include 
 #include 
 #include 
+
 #include 
+#include 
 
 using namespace osl;
 using namespace com::sun::star::uno;
@@ -485,6 +487,14 @@ WeakReferenceHelper& WeakReferenceHelper::operator=(const 
WeakReferenceHelper& r
 return operator = ( xInt );
 }
 
+WeakReferenceHelper & WeakReferenceHelper::operator =(
+WeakReferenceHelper && other)
+{
+clear();
+std::swap(m_pImpl, other.m_pImpl);
+return *this;
+}
+
 WeakReferenceHelper & SAL_CALL
 WeakReferenceHelper::operator= (const Reference< XInterface > & xInt)
 {
diff --git a/include/cppuhelper/weakref.hxx b/include/cppuhelper/weakref.hxx
index 11095b7..250bb81 100644
--- a/include/cppuhelper/weakref.hxx
+++ b/include/cppuhelper/weakref.hxx
@@ -63,6 +63,11 @@ public:
 */
 WeakReferenceHelper( const WeakReferenceHelper & rWeakRef );
 
+#if defined LIBO_INTERNAL_ONLY
+WeakReferenceHelper(WeakReferenceHelper && other): m_pImpl(other.m_pImpl)
+{ other.m_pImpl = nullptr; }
+#endif
+
 /** Initialize this reference with the hard interface reference xInt. If 
the implementation
 behind xInt does not support XWeak or xInt is null then this reference 
will be null.
 
@@ -80,6 +85,10 @@ public:
 */
 WeakReferenceHelper & SAL_CALL operator = ( const WeakReferenceHelper & 
rWeakRef );
 
+#if defined LIBO_INTERNAL_ONLY
+WeakReferenceHelper & operator =(WeakReferenceHelper && other);
+#endif
+
 /** Releases this reference and takes over hard reference xInt.
 If the implementation behind xInt does not support XWeak
 or XInt is null, then this reference is null.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: minutes of ESC call ...

2016-09-19 Thread Xisco Fauli

Hello


El 15/09/16 a les 17:06, Michael Meeks ha escrit:

+ Keywords - what is their meaning ?

  + NeedsDevEval vs. needAdvise

  + used randomly apparently.

=> prefer needsDevEval

  => replace all needAdvise -> needsDevEval.

|| ||

||+ UNCONFIRMED: 813||

 + up 100 over the last two weeks.

||+ enhancements: 90||

||+ needsUXEval: 52||

||+ needsDevEval at 73||

|| ||

 + needsDevEval - looking at (JanI)

 + if not an easy-hack, and multiple ways to solve a problem.

 + needs a core dev to say: "this problem should be solved in XYZ
place"

 + easy hacks shouldn't contain needsDevEval ? (Xisco)

 + if missing code pointers, set to NEEDINFO

 + ping people to provide pointers on NEEDINFOs (JanI


After the meeting, Jan, Beluga and I had a long conversation in IRC with 
regards to needAdvise/needsDevEval keywords and we arrive to the 
following conclusions:


- needAdvise: Used when help from developers in needed to confirm 
an UNCONFIRMED bug. Info: 
https://wiki.documentfoundation.org/QA/Bugzilla/Fields/Keywords#needAdvice.

* Problem 1: Name is confusing.
+ Action: Rename it to 'needsConfirmationAdvise'
* Problem 2: No New or resolved bugs should use it.
+ Action: Clean it up and create a new gardening task.

- needsDevEval: Should be used when a plausible easyhack lacks the 
code pointer, the difficulty, the topic or the skill and a developer 
needs to provide the information missing.
* Problem 1: It has been used to propose easyhacks over the 
last months.
+ Action: Update the wiki accordingly: 
https://wiki.documentfoundation.org/QA/Bugzilla/Fields/Keywords#needsDevEval 
and 
https://wiki.documentfoundation.org/Development/EasyHacks/Creating_a_new_Easy_Hack


* Problem 2: Name is confusing.
+ Action: Rename it to 'needsEasyHackValidation'

* Problem 3: The combination of NEEDINFO + easyhack has been 
used instead. NEEDINFO should only be used when feedback from the bug 
reporters is needed.
+ Action: Change all NEEDINFO + easyhack to 
'needsEasyHackValidation'


* Problem 4: 476 bugs use the keyword 'needsDevEval' nowadays.
+ Action: Evaluate one by one to see whether they're 
actually an easyhack or not. If so, change 'needsDevEval' keyword to 
'easyhack' and if possible, add the topic, code pointer, skill and 
difficulty. Adding Jan as CC helps too. In case the topic, the code 
pointer, the skill or the difficulty couldn't be provided for lack of 
knowledge, Jan could help on that as he's monitoring all easyhacks. If 
he couldn't, then the 'needsEasyHackValidation' keyword should be used.


NOTE: In order to propose new easyhacks, the same procedure as in 
Problem 4 should be followed.


Feel free to ask if you have any question.

Regards

--
Xisco Faulí
Libreoffice QA Team

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


[Libreoffice-commits] core.git: compilerplugins/clang dbaccess/source filter/source idlc/inc include/basic include/editeng include/filter include/registry include/sfx2 include/sot include/svtools incl

2016-09-19 Thread Noel Grandin
 compilerplugins/clang/unusedenumvalues.py  |1 
 dbaccess/source/ui/inc/dbwizsetup.hxx  |1 
 filter/source/config/cache/filtercache.hxx |3 
 idlc/inc/astdeclaration.hxx|7 -
 include/basic/sbxdef.hxx   |3 
 include/editeng/svxenum.hxx|3 
 include/filter/msfilter/escherex.hxx   |  121 -
 include/filter/msfilter/util.hxx   |8 -
 include/registry/regtype.h |   19 
 include/sfx2/mailmodelapi.hxx  |8 -
 include/sfx2/objsh.hxx |3 
 include/sot/exchange.hxx   |3 
 include/svtools/ivctrl.hxx |3 
 include/svx/cube3d.hxx |5 -
 include/svx/frmsel.hxx |4 
 include/svx/pageitem.hxx   |3 
 include/tools/stream.hxx   |1 
 include/tools/wintypes.hxx |3 
 vcl/source/control/button.cxx  |3 
 19 files changed, 12 insertions(+), 190 deletions(-)

New commits:
commit 1658bd231bc662504a072097dc614c29fe2e116d
Author: Noel Grandin 
Date:   Mon Sep 19 09:48:19 2016 +0200

loplugin:unusedenumvalues

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

diff --git a/compilerplugins/clang/unusedenumvalues.py 
b/compilerplugins/clang/unusedenumvalues.py
index 5e113da..eb31585 100755
--- a/compilerplugins/clang/unusedenumvalues.py
+++ b/compilerplugins/clang/unusedenumvalues.py
@@ -20,6 +20,7 @@ excludedSourceFiles = set([
 excludedTypes = set([
 "SwVarFormat", "RES_FIELDS", "SwFillOrder", "SwIoDetect", 
"SwDocumentSettingsPropertyHandles",
 "SalGenericDataType", "SwDateSubFormat", "XclFutureRecType", "ds_status", 
"MediaCommand",
+"EmfPlusHatchStyle"
 ])
 
 # clang does not always use exactly the same numbers in the type-parameter 
vars it generates
diff --git a/dbaccess/source/ui/inc/dbwizsetup.hxx 
b/dbaccess/source/ui/inc/dbwizsetup.hxx
index 7828e59..225f26b 100644
--- a/dbaccess/source/ui/inc/dbwizsetup.hxx
+++ b/dbaccess/source/ui/inc/dbwizsetup.hxx
@@ -137,7 +137,6 @@ protected:
 enum ApplyResult
 {
 AR_LEAVE_MODIFIED,  // something was modified and has successfully 
been committed
-AR_LEAVE_UNCHANGED, // no changes were made
 AR_KEEP // don't leave the page (e.g. because an error 
occurred)
 };
 
diff --git a/filter/source/config/cache/filtercache.hxx 
b/filter/source/config/cache/filtercache.hxx
index 0e6c8da..e34dc2f 100644
--- a/filter/source/config/cache/filtercache.hxx
+++ b/filter/source/config/cache/filtercache.hxx
@@ -102,8 +102,7 @@ class FilterCache : public BaseLock
 E_CONTAINS_TYPES= 2,
 E_CONTAINS_FILTERS  = 4,
 E_CONTAINS_FRAMELOADERS = 8,
-E_CONTAINS_CONTENTHANDLERS  = 16,
-E_CONTAINS_ALL  = 31 // must be a combination of all 
excepting E_CONTAINS_NOTHING! Please update if items will be added or removed 
...
+E_CONTAINS_CONTENTHANDLERS  = 16
 };
 
 
diff --git a/idlc/inc/astdeclaration.hxx b/idlc/inc/astdeclaration.hxx
index c6a76d9..9cbd8c9 100644
--- a/idlc/inc/astdeclaration.hxx
+++ b/idlc/inc/astdeclaration.hxx
@@ -27,12 +27,11 @@ class AstScope;
 // Enum defining the different kinds of Ast nodes
 enum NodeType
 {
-NT_object,  // Denotes an object
-NT_service, // Denotes an servcie
+NT_service, // Denotes a service
 NT_interface_member,// Denotes an interface which is exported from 
object
-NT_service_member,  // Denotes an service which is exported from object
+NT_service_member,  // Denotes a service which is exported from object
 NT_observes,// Denotes an observed interface
-NT_needs,   // Denotes an needed service
+NT_needs,   // Denotes a needed service
 NT_module,  // Denotes a module
 NT_root,// Denotes the root of AST
 NT_interface,   // Denotes an interface
diff --git a/include/basic/sbxdef.hxx b/include/basic/sbxdef.hxx
index 24341c6..4286398 100644
--- a/include/basic/sbxdef.hxx
+++ b/include/basic/sbxdef.hxx
@@ -81,9 +81,6 @@ enum SbxDataType {
 SbxVECTOR = 0x1000,  // simple counted array
 SbxARRAY  = 0x2000,  // array
 SbxBYREF  = 0x4000,  // access by reference
-
-SbxUSER1  = 256, // first user defined data type
-SbxUSERn  = 2047 // last user defined data type
 };
 
 const sal_uInt32 SBX_TYPE_WITH_EVENTS_FLAG = 0x1;
diff --git a/include/editeng/svxenum.hxx b/include/editeng/svxenum.hxx
index 16147c2..0ad9fd1 100644
--- a/include/editeng/svxenum.hxx
+++ b/include/editeng/svxenum.hxx
@@ -62,8 +62,7 @@ enum class SvxLineSpaceRule
 {
 Auto,
 Fix

[Libreoffice-commits] core.git: 3 commits - include/store registry/source store/source sw/inc sw/source

2016-09-19 Thread Noel Grandin
 include/store/store.h  |6 +++---
 include/store/types.h  |   14 +++---
 registry/source/keyimpl.cxx|   32 
 registry/source/regimpl.cxx|   30 +++---
 store/source/lockbyte.cxx  |   12 ++--
 store/source/storbios.cxx  |   12 ++--
 store/source/stordir.cxx   |2 +-
 store/source/store.cxx |2 +-
 store/source/storlckb.cxx  |   10 +-
 store/source/storpage.cxx  |6 +++---
 sw/inc/ndhints.hxx |7 ++-
 sw/source/core/inc/UndoManager.hxx |4 ++--
 sw/source/core/txtnode/ndtxt.cxx   |2 +-
 sw/source/core/txtnode/thints.cxx  |8 
 sw/source/core/undo/docundo.cxx|8 
 15 files changed, 76 insertions(+), 79 deletions(-)

New commits:
commit e58324aaca6875dbfe7c6c8333d747d2bfd9d089
Author: Noel Grandin 
Date:   Mon Sep 19 10:50:47 2016 +0200

convert storeAccessMode to scoped enum

Change-Id: I67705cdff0440487019a2992571147d648be1bfc

diff --git a/include/store/store.h b/include/store/store.h
index 61dc1e17..bd6027b 100644
--- a/include/store/store.h
+++ b/include/store/store.h
@@ -74,10 +74,10 @@ STORE_DLLPUBLIC storeError SAL_CALL store_createMemoryFile (
 /** Open a file.
 @param  pFilename [in] the filename as URL or system path.
 @param  eAccessMode [in] the access mode.
-store_AccessCreate truncate existing and create,
+storeAccessMode::Create truncate existing and create,
 store_AccessReadCreate create not existing,
-store_AccessReadWrite  write existing,
-store_AccessReadOnly   never modifies.
+storeAccessMode::ReadWrite  write existing,
+storeAccessMode::ReadOnly   never modifies.
 @param  nPageSize [in] the creation page size,
 integer multiple of minimum page size.
 @param  phFile [out] the File Handle.
diff --git a/include/store/types.h b/include/store/types.h
index 1b1724e..fe8c1e0 100644
--- a/include/store/types.h
+++ b/include/store/types.h
@@ -59,14 +59,14 @@ extern "C" {
 @see store_openDirectory()
 @see store_openStream()
  */
-typedef enum
+enum class storeAccessMode
 {
-store_AccessCreate,
-store_AccessReadCreate,
-store_AccessReadWrite,
-store_AccessReadOnly,
-store_Access_FORCE_EQUAL_SIZE = SAL_MAX_ENUM
-} storeAccessMode;
+Create,
+ReadCreate,
+ReadWrite,
+ReadOnly,
+FORCE_EQUAL_SIZE = SAL_MAX_ENUM
+};
 
 
 /** Error Code enumeration.
diff --git a/registry/source/keyimpl.cxx b/registry/source/keyimpl.cxx
index 9fa3dab..2aeb310 100644
--- a/registry/source/keyimpl.cxx
+++ b/registry/source/keyimpl.cxx
@@ -219,11 +219,11 @@ RegError ORegKey::getValueInfo(const OUString& valueName, 
RegValueType* pValueTy
 {
 OStoreStreamrValue;
 sal_uInt8*  pBuffer;
-storeAccessMode accessMode = store_AccessReadWrite;
+storeAccessMode accessMode = storeAccessMode::ReadWrite;
 
 if (m_pRegistry->isReadOnly())
 {
-accessMode = store_AccessReadOnly;
+accessMode = storeAccessMode::ReadOnly;
 }
 
 OUString sImplValueName( VALUE_PREFIX );
@@ -301,7 +301,7 @@ RegError ORegKey::setValue(const OUString& valueName, 
RegValueType vType, RegVal
 
 REG_GUARD(m_pRegistry->m_mutex);
 
-if ( rValue.create(getStoreFile(), m_name + m_pRegistry->ROOT , 
sImplValueName, store_AccessCreate) )
+if ( rValue.create(getStoreFile(), m_name + m_pRegistry->ROOT , 
sImplValueName, storeAccessMode::Create) )
 {
 return RegError::SET_VALUE_FAILED;
 }
@@ -371,7 +371,7 @@ RegError ORegKey::setLongListValue(const OUString& 
valueName, sal_Int32* pValueL
 
 REG_GUARD(m_pRegistry->m_mutex);
 
-if (rValue.create(getStoreFile(), m_name + m_pRegistry->ROOT, 
sImplValueName, store_AccessCreate) )
+if (rValue.create(getStoreFile(), m_name + m_pRegistry->ROOT, 
sImplValueName, storeAccessMode::Create) )
 {
 return RegError::SET_VALUE_FAILED;
 }
@@ -430,7 +430,7 @@ RegError ORegKey::setStringListValue(const OUString& 
valueName, sal_Char** pValu
 
 REG_GUARD(m_pRegistry->m_mutex);
 
-if (rValue.create(getStoreFile(), m_name + m_pRegistry->ROOT, 
sImplValueName, store_AccessCreate) )
+if (rValue.create(getStoreFile(), m_name + m_pRegistry->ROOT, 
sImplValueName, storeAccessMode::Create) )
 {
 return RegError::SET_VALUE_FAILED;
 }
@@ -498,7 +498,7 @@ RegError ORegKey::setUnicodeListValue(const OUString& 
valueName, sal_Unicode** p
 
 REG_GUARD(m_pRegistry->m_mutex);
 
-if (rValue.create(getStoreFile(), m_name + m_pRegistry->ROOT, 
sImplValueName, store_AccessCreate) )
+if (rValue.create(getStoreFile(), m_name + m_pRegistry->ROOT, 
sImplValueName, storeAccessMode::Create) )
 {
 return RegError::SET_VALUE_FAILED;
 }
@@ -557,11 +557,11 @@ RegError ORegKey::getValue(const O

[Libreoffice-commits] online.git: loolwsd/test

2016-09-19 Thread Tor Lillqvist
 loolwsd/test/helpers.hpp |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit d654c464df309cb8a3a60b568c7cb9f51e1417ec
Author: Tor Lillqvist 
Date:   Mon Sep 19 13:53:14 2016 +0300

Don't log the contents of CLOSE frames

diff --git a/loolwsd/test/helpers.hpp b/loolwsd/test/helpers.hpp
index 32f009b..2af9070 100644
--- a/loolwsd/test/helpers.hpp
+++ b/loolwsd/test/helpers.hpp
@@ -296,7 +296,8 @@ std::vector getResponseMessage(Poco::Net::WebSocket& 
ws, const std::string
 break;
 }
 
-std::cerr << name << "Ignored: " << message << std::endl;
+if ((flags & Poco::Net::WebSocket::FRAME_OP_BITMASK) != 
Poco::Net::WebSocket::FRAME_OP_CLOSE)
+std::cerr << name << "Ignored: " << message << std::endl;
 }
 else
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/test

2016-09-19 Thread Tor Lillqvist
 loolwsd/test/httpwstest.cpp |4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

New commits:
commit f24417127cf6e650c518773362586f9a2185902d
Author: Tor Lillqvist 
Date:   Mon Sep 19 14:02:05 2016 +0300

Avoid a couple of pointless const variables used just once

I truly cannot understand what purpose using these variables served.

diff --git a/loolwsd/test/httpwstest.cpp b/loolwsd/test/httpwstest.cpp
index 14ecd3d..858f58d 100644
--- a/loolwsd/test/httpwstest.cpp
+++ b/loolwsd/test/httpwstest.cpp
@@ -1438,9 +1438,7 @@ void HTTPWSTest::testCalcEditRendering()
 const auto testname = "calcEditRendering ";
 auto socket = loadDocAndGetSocket("calc_render.xls", _uri, testname);
 
-const std::string x = "5000";
-const std::string y = "5";
-sendTextFrame(socket, "mouse type=buttondown x=" + x + " y=" + y + " 
count=1 buttons=1 modifier=0");
+sendTextFrame(socket, "mouse type=buttondown x=5000 y=5 count=1 buttons=1 
modifier=0");
 sendTextFrame(socket, "key type=input char=97 key=0");
 sendTextFrame(socket, "key type=input char=98 key=0");
 sendTextFrame(socket, "key type=input char=99 key=0");
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: How to keep UNO applications connected after closing LibreOffice

2016-09-19 Thread Samuel Mehrbrodt
Hi Stephan, *


We have the following case:
You have an application conntected to LO via UNO. The user then
separately starts a (Start center) window. When he closes it, LO gets
terminated and the external application loses the connection. We want to
prevent thatso that the external application keeps working.



The usual pragmatic solution is to use an explicit UserInstallation for
the external application.

That doesn't work in our case since we want the same user settings in both 
scenarios (embedded vs. standalone).

We could use a TerminationVetoException

in the external application to prevent LO from terminating. But this has
the side effect that the user can no longer close the Start center.

Basically we have two options how to fix this:

 1. Change the behavior of LO such that the TerminationVetoException
allows closing the last window, but still prevents terminating the
soffice process



At least for desktop environments that do not clearly indicate that an
app is still running when its last window is closed, one downside of
this could be that users might not be aware of LO still running when
they intended to close it.



 2. Change the behavior of LO such that an open UNO connection counts as
an open window, and the process doesn't get terminated until all
connections are closed.
This option would not need a TerminationVetoException.

Both options do change existing behavior and will possible break
existing applications/workflows out there. So the decision should be
made carefully.

I probably would go for the first one, since the
TerminationVetoException suggests that it will prevent termination. It
shouldn't affect closing a window.
Although I would also consider it as a bug that LO terminates (when
closing a window) while it still has active connections.

Any input on this?



I think I'd be fine with improvements in either direction.

Thanks for your comment.

I went with the first option and created this patch: 
https://gerrit.libreoffice.org/#/c/29018
Review appreciated.

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


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

2016-09-19 Thread Caolán McNamara
 sd/source/core/drawdoc3.cxx |7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)

New commits:
commit 914d72ee1edb351e4975a516240a38696f619217
Author: Caolán McNamara 
Date:   Mon Sep 19 12:24:02 2016 +0100

Related: rhbz#1353069 don't clear XATTR_FILL* from stylesheet if...

This is similar to de4908eb4d2f1f2ce38a37eea18a9efc4a0073b1 where

the master page is not the sole owner. Which happens when copying
and pasting slides which bring along a duplicate master page to
an already existing one, and the attempt to remove the duplicate
strips the fill properties from the shared stylesheet in use by
the other

regression from...

commit b876bbe2cacce8af379b10d82da6c7e7d229b361
Author: David Tardon 
Date:   Tue Apr 26 09:17:11 2016 +0200

rbhz#1326602 avoid exp. bg bitmaps from deleted slides

Change-Id: I0a3a34ade2ad8464b1edb67a6e28dab45c761a2c

diff --git a/sd/source/core/drawdoc3.cxx b/sd/source/core/drawdoc3.cxx
index 2c090c0..0db59dd 100644
--- a/sd/source/core/drawdoc3.cxx
+++ b/sd/source/core/drawdoc3.cxx
@@ -1243,6 +1243,7 @@ void SdDrawDocument::RemoveUnnecessaryMasterPages(SdPage* 
pMasterPage, bool bOnl
 {
 // Do not delete master pages that have their precious flag set
 bool bDeleteMaster = !pMaster->IsPrecious();
+bool bSoleOwnerOfStyleSheet = true;
 OUString aLayoutName = pMaster->GetLayoutName();
 
 if(bOnlyDuplicatePages )
@@ -1257,6 +1258,10 @@ void 
SdDrawDocument::RemoveUnnecessaryMasterPages(SdPage* pMasterPage, bool bOnl
 {
 // duplicate page found -> remove it
 bDeleteMaster = true;
+
+const SfxStyleSheet* pRefSheet = 
pMaster->getSdrPageProperties().GetStyleSheet();
+const SfxStyleSheet* pTestSheet = 
pMPg->getSdrPageProperties().GetStyleSheet();
+bSoleOwnerOfStyleSheet = pRefSheet != pTestSheet;
 }
 }
 }
@@ -1290,7 +1295,7 @@ void SdDrawDocument::RemoveUnnecessaryMasterPages(SdPage* 
pMasterPage, bool bOnl
 delete pNotesMaster;
 
 if( bUndo )
-
AddUndo(GetSdrUndoFactory().CreateUndoDeletePage(*pMaster));
+AddUndo(GetSdrUndoFactory().CreateUndoDeletePage(*pMaster, 
bSoleOwnerOfStyleSheet));
 
 RemoveMasterPage( pMaster->GetPageNum() );
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/LOOLKit.cpp loolwsd/LOOLWSD.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/LOOLKit.cpp |5 -
 loolwsd/LOOLWSD.cpp |8 
 2 files changed, 13 deletions(-)

New commits:
commit f0c09238ce0aa9772b182b1461af0a448332dda4
Author: Ashod Nakashian 
Date:   Sat Sep 17 08:42:25 2016 -0400

loolwsd: fail fast rather than catch all

Change-Id: Ib38924bf823315d211eb467d90f364fdc225ba2e
Reviewed-on: https://gerrit.libreoffice.org/29005
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index 2e3fdb9..74ef66b 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -289,7 +289,6 @@ public:
 Util::setThreadName("kit_ws_" + _sessionId);
 
 Log::debug("Thread started.");
-
 try
 {
 auto queue = std::make_shared();
@@ -333,10 +332,6 @@ public:
 {
 Log::error(std::string("Connection::run: Exception: ") + 
exc.what());
 }
-catch (...)
-{
-Log::error("Connection::run:: Unexpected exception");
-}
 
 Log::debug("Thread finished.");
 }
diff --git a/loolwsd/LOOLWSD.cpp b/loolwsd/LOOLWSD.cpp
index 57b996b..b496a1b 100644
--- a/loolwsd/LOOLWSD.cpp
+++ b/loolwsd/LOOLWSD.cpp
@@ -995,10 +995,6 @@ public:
 Log::error(std::string("ClientRequestHandler::handleRequest: 
Exception: ") + exc.what());
 
response.setStatusAndReason(HTTPResponse::HTTP_SERVICE_UNAVAILABLE);
 }
-catch (...)
-{
-Log::error("ClientRequestHandler::handleRequest:: Unexpected 
exception");
-}
 
 if (!responded)
 {
@@ -1190,10 +1186,6 @@ public:
 {
 Log::error(std::string("PrisonerRequestHandler::handleRequest: 
Exception: ") + exc.what());
 }
-catch (...)
-{
-Log::error("PrisonerRequestHandler::handleRequest:: Unexpected 
exception");
-}
 
 if (!jailId.empty())
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/.gitignore

2016-09-19 Thread Ashod Nakashian
 loolwsd/.gitignore |4 
 1 file changed, 4 insertions(+)

New commits:
commit 88fb1e1978678e629e286591a20fb7968c865b14
Author: Ashod Nakashian 
Date:   Sat Sep 17 08:45:14 2016 -0400

loolwsd: gitignore auto-complete and yavide dot files

Change-Id: Ied01b78c76478d980947f6c5dd595809e515ae4f
Reviewed-on: https://gerrit.libreoffice.org/29004
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/.gitignore b/loolwsd/.gitignore
index 20cf7d3..52945b4 100644
--- a/loolwsd/.gitignore
+++ b/loolwsd/.gitignore
@@ -5,6 +5,10 @@
 # Autofoo
 .deps
 .dirstamp
+.clang_complete
+.cxx_tags
+.yavide_proj
+.yavide_session
 Makefile
 Makefile.in
 loolwsd.spec
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/IoUtil.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/IoUtil.cpp |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 258b768218a699e1ab84cf35de89b113637f23e8
Author: Ashod Nakashian 
Date:   Sat Sep 17 21:43:31 2016 -0400

loolwsd: break receiveFrame on TerminationFlag

Change-Id: Id6d71951660431abea1a393fc7fe91a88552fc04
Reviewed-on: https://gerrit.libreoffice.org/29006
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/IoUtil.cpp b/loolwsd/IoUtil.cpp
index 1e5db62..bb861dd 100644
--- a/loolwsd/IoUtil.cpp
+++ b/loolwsd/IoUtil.cpp
@@ -40,7 +40,7 @@ namespace IoUtil
 
 int receiveFrame(WebSocket& socket, void* buffer, int length, int& flags)
 {
-while (true)
+while (!TerminationFlag)
 {
 int n = socket.receiveFrame(buffer, length, flags);
 if ((flags & WebSocket::FRAME_OP_BITMASK) == WebSocket::FRAME_OP_PING)
@@ -56,6 +56,8 @@ int receiveFrame(WebSocket& socket, void* buffer, int length, 
int& flags)
 return n;
 }
 }
+
+return -1;
 }
 
 // Synchronously process WebSocket requests and dispatch to handler.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/test

2016-09-19 Thread Ashod Nakashian
 loolwsd/test/httpwstest.cpp |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 1fc7ec0be558bd5461d10f46fe0a4db30e4aae0e
Author: Ashod Nakashian 
Date:   Sat Sep 17 21:47:24 2016 -0400

loolwsd: add graphicviewselection to expected messages in unittests

Change-Id: I2f2e009c970839f380d7501c7a45ffdc0936e5f7
Reviewed-on: https://gerrit.libreoffice.org/29007
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/test/httpwstest.cpp b/loolwsd/test/httpwstest.cpp
index 858f58d..fe348ad 100644
--- a/loolwsd/test/httpwstest.cpp
+++ b/loolwsd/test/httpwstest.cpp
@@ -1032,7 +1032,8 @@ void HTTPWSTest::testInactiveClient()
 token == "textselectionend:" ||
 token == "textselectionstart:" ||
 token == "textviewselection:" ||
-token == "viewcursorvisible:");
+token == "viewcursorvisible:" ||
+token == "graphicviewselection:");
 
 // End when we get state changed.
 return (token != "statechanged:");
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/LOOLKit.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/LOOLKit.cpp |5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit 7fff96039118e29ebc125f65b94560332cd41355
Author: Ashod Nakashian 
Date:   Mon Sep 19 00:20:02 2016 -0400

loolwsd: stop the tile-queue when exiting

Change-Id: I49276c9639e8826d145a31eb476b41eb64baf88a
Reviewed-on: https://gerrit.libreoffice.org/29009
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index 74ef66b..29d84f4 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -426,6 +426,9 @@ public:
 _callbackQueue.wakeUpAll();
 _callbackThread.join();
 
+_tileQueue->put("eof");
+_tilesThread.join();
+
 // Flag all connections to stop.
 for (auto aIterator : _connections)
 {
@@ -1218,7 +1221,7 @@ private:
 
 try
 {
-while (true)
+while (!pThis->_stop)
 {
 const auto input = pThis->_tileQueue->get();
 const std::string message(input.data(), input.size());
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/test

2016-09-19 Thread Ashod Nakashian
 loolwsd/test/httpwstest.cpp |9 -
 1 file changed, 4 insertions(+), 5 deletions(-)

New commits:
commit d1d5bf28e780a9da286ea4d50517527a43a2f832
Author: Ashod Nakashian 
Date:   Sat Sep 17 21:48:35 2016 -0400

loolwsd: log sender/receiver in inactiveClient unittest

Change-Id: I138eb19d5252472edad5272b2764a7c263a224e4
Reviewed-on: https://gerrit.libreoffice.org/29008
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/test/httpwstest.cpp b/loolwsd/test/httpwstest.cpp
index fe348ad..ab1b528 100644
--- a/loolwsd/test/httpwstest.cpp
+++ b/loolwsd/test/httpwstest.cpp
@@ -997,21 +997,20 @@ void HTTPWSTest::testInactiveClient()
 {
 std::string documentPath, documentURL;
 getDocumentPathAndURL("hello.odt", documentPath, documentURL);
-Poco::Net::HTTPRequest request(Poco::Net::HTTPRequest::HTTP_GET, 
documentURL);
 
 auto socket1 = loadDocAndGetSocket(_uri, documentURL, 
"inactiveClient-1 ");
 
 // Connect another and go inactive.
 std::cerr << "Connecting second client." << std::endl;
 auto socket2 = loadDocAndGetSocket(_uri, documentURL, 
"inactiveClient-2 ", true);
-sendTextFrame(socket2, "userinactive");
+sendTextFrame(socket2, "userinactive", "inactiveClient-2 ");
 
 // While second is inactive, make some changes.
-sendTextFrame(socket1, "uno .uno:SelectAll");
-sendTextFrame(socket1, "uno .uno:Delete");
+sendTextFrame(socket1, "uno .uno:SelectAll", "inactiveClient-1 ");
+sendTextFrame(socket1, "uno .uno:Delete", "inactiveClient-1 ");
 
 // Activate second.
-sendTextFrame(socket2, "useractive");
+sendTextFrame(socket2, "useractive", "inactiveClient-2 ");
 SocketProcessor("Second ", socket2, [&](const std::string& msg)
 {
 const auto token = LOOLProtocol::getFirstToken(msg);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/test

2016-09-19 Thread Ashod Nakashian
 loolwsd/test/httpwstest.cpp |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit e1cd116abd4bde3f0286c63b703f9f28c46e146f
Author: Ashod Nakashian 
Date:   Mon Sep 19 08:12:38 2016 -0400

loolwsd: duplicate command name removed

Change-Id: Iad7b440ec4ab30e832cf3ae2d4c64760fcb1db5d
Reviewed-on: https://gerrit.libreoffice.org/29022
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/test/httpwstest.cpp b/loolwsd/test/httpwstest.cpp
index ab1b528..2877797 100644
--- a/loolwsd/test/httpwstest.cpp
+++ b/loolwsd/test/httpwstest.cpp
@@ -1031,8 +1031,7 @@ void HTTPWSTest::testInactiveClient()
 token == "textselectionend:" ||
 token == "textselectionstart:" ||
 token == "textviewselection:" ||
-token == "viewcursorvisible:" ||
-token == "graphicviewselection:");
+token == "viewcursorvisible:");
 
 // End when we get state changed.
 return (token != "statechanged:");
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: WIP: new VCL scheduler feature branch

2016-09-19 Thread Jan-Marek Glogowski
Hi Noel,

thanks for the feedback.

Am 17.09.2016 um 13:54 schrieb Noel Grandin:
> Nice work!
> 
> Some random low priority comments:
> 
> In "Just walk the task list once per timeout"
> https://cgit.freedesktop.org/libreoffice/core/commit/?h=feature/new-vcl-scheduler&id=435e21fe0330436e76e5e053d5d5d94df734a554
> The evaluate_entry label doesn't make the code any easier to read.

So you're suggestion is? Introduce an other level of indention for the
if? The while loop is short enough and the goto labels are just used in
there. If you think it improves readability, I can change it.

> In "Reorganize Scheduler priority classes"
> https://cgit.freedesktop.org/libreoffice/core/commit/?h=feature/new-vcl-scheduler&id=5e4361e84607fc6d7623b31630505da7c934b945
>  (1) you haven't used a consistent mapping from old to new - sometimes
> LOW maps to HIGH_IDLE, sometimes HIGHEST maps to HIGH_IDLE. Perhaps
> there is a reason for this?

From naming and code reading I tried to guess, if the idle should be
processed before drawing. As I wrote I would like to get a comment or
annotation for all non-default priorities, i.e. all calls to "SetPriority".

I have no idea, if my guesses are correct, just that mail merge is much
faster now and LO is still usable while the mail merge runs. Actually
you can see the slowdown of mail merge when doing stuff in LO :-)

> (2) I would call HIGH_IDLE, either PRE_RESIZE or BEFORE_RESIZE, because
> it's not any kind of IDLE anymore. I would call DEFAULT_IDLE just IDLE.

I just took the priority names from glib. I would keep the DEFAULT_IDLE,
or rename DEFAULT to TIMER? OTOH the Scheduler class sets the default
priority...

> In "Handle all main loop and task events"
> https://cgit.freedesktop.org/libreoffice/core/commit/?h=feature/new-vcl-scheduler&id=102c41c2e429bee489334361536779aa298bc181
> -bProcessedEvent = bProcessedEvent || bScheduledEevent;
> +bProcessedEvent |= bScheduledEevent;

Will do.

> In "Run Idle tasks immediatly"
> https://cgit.freedesktop.org/libreoffice/core/commit/?h=feature/new-vcl-scheduler&id=a1ecb280872c5487615558f8d140a380ef3e0d36
> It occurs to me that when we get an overload condition, it would be very
> helpful to dump the names of the current events.

Dumping the current event would probably not help much. But we could
dump the whole scheduler event state. OTOH you can dump it in GDB with

p *ImplGetSVData()->mpFirstSchedulerData

BTW: there are some LOK-Tests, which generate more then 1000 events. The
1000 is arbitrary from my POV. Probably checking the runtime of
ProcessAllPendingEvents() would be better?

Thanks,

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


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sw/source

2016-09-19 Thread Jan-Marek Glogowski
 sw/source/ui/misc/bookmark.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 89c87ab94bb5960187c178f556f871b2c1bfde8f
Author: Jan-Marek Glogowski 
Date:   Fri Sep 16 22:13:02 2016 +0200

tdf#101359 Just advance list box for BOOKMARKs

Since the list box just contains MarkType::BOOKMARK, just advance
the list box position for marks of this type.

Change-Id: I7b8743abb1ffb2fda2242c5e7301b3ff15ae355b
(cherry picked from commit 96454829f7dc6480f9ddd4262bc03d5ccabadea4)
Reviewed-on: https://gerrit.libreoffice.org/28971
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/sw/source/ui/misc/bookmark.cxx b/sw/source/ui/misc/bookmark.cxx
index 6798738..1395fc1 100644
--- a/sw/source/ui/misc/bookmark.cxx
+++ b/sw/source/ui/misc/bookmark.cxx
@@ -257,8 +257,8 @@ bool SwInsertBookmarkDlg::HaveBookmarksChanged()
 if (aTableBookmark.first != ppBookmark->get() ||
 aTableBookmark.second != ppBookmark->get()->GetName())
 return true;
+++ppBookmark;
 }
-++ppBookmark;
 }
 return false;
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Giuseppe Castagno
 ucb/source/ucp/webdav-neon/DAVTypes.cxx  |   29 +
 ucb/source/ucp/webdav-neon/DAVTypes.hxx  |8 +++
 ucb/source/ucp/webdav-neon/webdavcontent.cxx |   56 +++
 ucb/source/ucp/webdav-neon/webdavcontent.hxx |3 -
 4 files changed, 88 insertions(+), 8 deletions(-)

New commits:
commit 2a148e2b5ea11fd371042e836fa95438ffa738e7
Author: Giuseppe Castagno 
Date:   Sat Aug 27 17:31:06 2016 +0200

tdf#101094 (32): Use a partial GET as a fall-back for HEAD...

... partial GET means a GET with no data returned, to test for
resource 'real' availability in case HEAD fails or is disabled.
At  the same time disable use of HEAD method on the resource
for the whole access procedure.

This change is needed to manage web servers that don't permit the
use of either HEAD or OPTIONS methods.
To accomodate pure web sites that enable only GET to fetch contents.

Change-Id: If52316ddd6ce637fb7d2ef518423de246ee2dcfb
Reviewed-on: https://gerrit.libreoffice.org/28992
Tested-by: Giuseppe Castagno 
Reviewed-by: Giuseppe Castagno 

diff --git a/ucb/source/ucp/webdav-neon/DAVTypes.cxx 
b/ucb/source/ucp/webdav-neon/DAVTypes.cxx
index af1079c..8756994 100644
--- a/ucb/source/ucp/webdav-neon/DAVTypes.cxx
+++ b/ucb/source/ucp/webdav-neon/DAVTypes.cxx
@@ -24,6 +24,7 @@ DAVOptions::DAVOptions() :
 m_isClass1( false ),
 m_isClass2( false ),
 m_isClass3( false ),
+m_isHeadAllowed( true ),
 m_isLocked( false ),
 m_aAllowedMethods(),
 m_nStaleTime( 0 ),
@@ -38,6 +39,7 @@ DAVOptions::DAVOptions( const DAVOptions & rOther ) :
 m_isClass1( rOther.m_isClass1 ),
 m_isClass2( rOther.m_isClass2 ),
 m_isClass3( rOther.m_isClass3 ),
+m_isHeadAllowed( rOther.m_isHeadAllowed ),
 m_isLocked( rOther.m_isLocked ),
 m_aAllowedMethods( rOther.m_aAllowedMethods ),
 m_nStaleTime( rOther.m_nStaleTime ),
@@ -173,5 +175,32 @@ bool DAVOptionsCache::isResourceFound( const OUString & 
rURL )
 return true;
 }
 
+bool DAVOptionsCache::isHeadAllowed( const OUString & rURL )
+{
+osl::MutexGuard aGuard( m_aMutex );
+OUString aEncodedUrl( ucb_impl::urihelper::encodeURI( NeonUri::unescape( 
rURL ) ) );
+normalizeURLLastChar( aEncodedUrl );
+
+DAVOptionsMap::iterator it;
+it = m_aTheCache.find( aEncodedUrl );
+if ( it != m_aTheCache.end() )
+{
+// first check for stale
+TimeValue t1;
+osl_getSystemTime( &t1 );
+if( (*it).second.getStaleTime() < t1.Seconds )
+{
+m_aTheCache.erase( it );
+return true; // to force again OPTIONS method
+}
+
+// check if the resource was present on server
+return (*it).second.isHeadAllowed();
+}
+// this value is needed because some web server don't implement
+// OPTIONS method, so the resource is considered found,
+// until detected otherwise
+return true;
+}
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/ucb/source/ucp/webdav-neon/DAVTypes.hxx 
b/ucb/source/ucp/webdav-neon/DAVTypes.hxx
index 53bc739..037e68f 100644
--- a/ucb/source/ucp/webdav-neon/DAVTypes.hxx
+++ b/ucb/source/ucp/webdav-neon/DAVTypes.hxx
@@ -81,6 +81,8 @@ namespace webdav_ucp
 boolm_isClass1;
 boolm_isClass2;
 boolm_isClass3;
+// for server that do not implement it
+boolm_isHeadAllowed;
 // Internally used to maintain locked stated of the resource, only
 // if it's a Class 2 resource
 boolm_isLocked;
@@ -111,6 +113,9 @@ namespace webdav_ucp
 bool isClass3() { return m_isClass3; };
 void setClass3( bool Class3 = true ) { m_isClass3 = Class3; };
 
+bool isHeadAllowed() { return m_isHeadAllowed; };
+void setHeadAllowed( bool HeadAllowed = true ) { m_isHeadAllowed = 
HeadAllowed; };
+
 sal_uInt32  getStaleTime() const { return m_nStaleTime ; };
 void setStaleTime( const sal_uInt32 nStaleTime ) { m_nStaleTime = 
nStaleTime; };
 
@@ -133,6 +138,7 @@ namespace webdav_ucp
 m_isClass1 = false;
 m_isClass2 = false;
 m_isClass3 = false;
+m_isHeadAllowed = true;
 m_isLocked = false;
 m_aAllowedMethods.clear();
 m_nStaleTime = 0;
@@ -177,6 +183,8 @@ namespace webdav_ucp
 */
 bool isResourceFound( const OUString & rURL );
 
+bool isHeadAllowed( const OUString & rURL );
+
 private:
 
 /// remove the last '/' in aUrl, if it exists
diff --git a/ucb/source/ucp/webdav-neon/webdavcontent.cxx 
b/ucb/source/ucp/webdav-neon/webdavcontent.cxx
index be32582..a5d6406 100644
--- a/ucb/source/ucp/webdav-neon/webdavcontent.cxx
+++ b/ucb/source/ucp/webdav-neon/webdavcontent.cxx
@@ -1589,6 +1589,10 @@ uno::Reference< sdbc::XRow > Content::getPropertyValues(
 // clean cached value of 

[Libreoffice-commits] online.git: loolwsd/LOOLKit.cpp

2016-09-19 Thread Miklos Vajna
 loolwsd/LOOLKit.cpp |   28 ++--
 1 file changed, 18 insertions(+), 10 deletions(-)

New commits:
commit ea274bcf6b94400cd4e3f13f1ac954ed5c24a36c
Author: Miklos Vajna 
Date:   Mon Sep 19 16:04:23 2016 +0200

Document::ViewCallback: don't fail on EMPTY cell cursor

Change-Id: I67bee2a1f1332bfb82963e0fb3a0e761054f826e

diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index 29d84f4..d5d3fc9 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -814,12 +814,16 @@ private:
 nType == LOK_CALLBACK_CELL_CURSOR)
 {
 Poco::StringTokenizer tokens(payload, ",", 
Poco::StringTokenizer::TOK_IGNORE_EMPTY | Poco::StringTokenizer::TOK_TRIM);
-auto cursorX = std::stoi(tokens[0]);
-auto cursorY = std::stoi(tokens[1]);
-auto cursorWidth = std::stoi(tokens[2]);
-auto cursorHeight = std::stoi(tokens[3]);
+// Payload may be 'EMPTY'.
+if (tokens.count() == 4)
+{
+auto cursorX = std::stoi(tokens[0]);
+auto cursorY = std::stoi(tokens[1]);
+auto cursorWidth = std::stoi(tokens[2]);
+auto cursorHeight = std::stoi(tokens[3]);
 
-pDescr->Doc->_tileQueue->updateCursorPosition(0, 0, cursorX, 
cursorY, cursorWidth, cursorHeight);
+pDescr->Doc->_tileQueue->updateCursorPosition(0, 0, cursorX, 
cursorY, cursorWidth, cursorHeight);
+}
 }
 else if (nType == LOK_CALLBACK_INVALIDATE_VIEW_CURSOR ||
  nType == LOK_CALLBACK_CELL_VIEW_CURSOR)
@@ -831,12 +835,16 @@ private:
 auto part = command->get("part").toString();
 auto text = command->get("rectangle").toString();
 Poco::StringTokenizer tokens(text, ",", 
Poco::StringTokenizer::TOK_IGNORE_EMPTY | Poco::StringTokenizer::TOK_TRIM);
-auto cursorX = std::stoi(tokens[0]);
-auto cursorY = std::stoi(tokens[1]);
-auto cursorWidth = std::stoi(tokens[2]);
-auto cursorHeight = std::stoi(tokens[3]);
+// Payload may be 'EMPTY'.
+if (tokens.count() == 4)
+{
+auto cursorX = std::stoi(tokens[0]);
+auto cursorY = std::stoi(tokens[1]);
+auto cursorWidth = std::stoi(tokens[2]);
+auto cursorHeight = std::stoi(tokens[3]);
 
-pDescr->Doc->_tileQueue->updateCursorPosition(std::stoi(viewId), 
std::stoi(part), cursorX, cursorY, cursorWidth, cursorHeight);
+
pDescr->Doc->_tileQueue->updateCursorPosition(std::stoi(viewId), 
std::stoi(part), cursorX, cursorY, cursorWidth, cursorHeight);
+}
 }
 
 // Forward to the same view only.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Julien Nabet
 android/source/res/values/strings.xml |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f0207e3d2dec9f3e9e0c944e23bee92f467641f7
Author: Julien Nabet 
Date:   Sat Sep 17 23:14:56 2016 +0200

tdf#101919: rename ownCloud to Remote server

Change-Id: I217fdc805ce425f8a4a17d0d0e924e532ec070de
Reviewed-on: https://gerrit.libreoffice.org/28983
Reviewed-by: Michael Meeks 
Tested-by: Michael Meeks 

diff --git a/android/source/res/values/strings.xml 
b/android/source/res/values/strings.xml
index c4d1bae..9ac37be 100644
--- a/android/source/res/values/strings.xml
+++ b/android/source/res/values/strings.xml
@@ -53,7 +53,7 @@
 Local file system
 External SD
 OTG device (experimental)
-ownCloud
+Remote server
 
 Cannot connect to ownCloud 
server. Check your configuration.
 Cannot log into ownCloud server. 
Check your configuration.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'aoo/trunk' - svtools/inc

2016-09-19 Thread Tsutomu Uchino
 svtools/inc/svtools/treelist.hxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 9265749be4b0ba24f04c39d78354109e5fcedcfc
Author: Tsutomu Uchino 
Date:   Mon Sep 19 13:29:14 2016 +

#i125762# fix null pointer reference while accessibility related call

diff --git a/svtools/inc/svtools/treelist.hxx b/svtools/inc/svtools/treelist.hxx
index 3aaf412..81d7959 100644
--- a/svtools/inc/svtools/treelist.hxx
+++ b/svtools/inc/svtools/treelist.hxx
@@ -404,7 +404,7 @@ inline sal_Bool SvListView::IsExpanded( SvListEntry* pEntry 
) const
 DBG_ASSERT(pEntry,"IsExpanded:No Entry");
 SvViewData* pData = (SvViewData*)aDataTable.Get( (sal_uLong)pEntry );
 DBG_ASSERT(pData,"Entry not in Table");
-return pData->IsExpanded();
+return pData && pData->IsExpanded();
 }
 inline sal_Bool SvListView::IsSelected( SvListEntry* pEntry ) const
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'feature/new-vcl-scheduler' - 105 commits - android/source avmedia/source basctl/source chart2/source compilerplugins/clang configure.ac cppuhelper/source cui/so

2016-09-19 Thread Jan-Marek Glogowski
Rebased ref, commits from common ancestor:
commit effc80ebe31aec12b821dd72c4afaa6e4a571cda
Author: Jan-Marek Glogowski 
Date:   Tue Sep 13 11:03:08 2016 +0200

Round-robin invoked / started tasks

And some simple round-robin to the task processing, so equal
priority (auto) tasks won't always be scheduled, if there are
multiple with the same priority.

Currently breaks LO, which indicates dependencies in the same
priority class, which must not exist!

Change-Id: If84496bff68aec42d0fa63c2b7e05c3202f67b2c

diff --git a/vcl/source/app/scheduler.cxx b/vcl/source/app/scheduler.cxx
index 647dbb4..be7440d 100644
--- a/vcl/source/app/scheduler.cxx
+++ b/vcl/source/app/scheduler.cxx
@@ -30,9 +30,6 @@ void ImplSchedulerData::Invoke()
 if ( !mpScheduler || mbInScheduler )
 return;
 
-// tdf#92036 Reset the period to avoid re-firing immediately.
-mpScheduler->mpSchedulerData->mnUpdateTime = tools::Time::GetSystemTicks();
-
 Scheduler *sched = mpScheduler;
 
 // prepare Scheduler Object for deletion after handling
@@ -173,6 +170,7 @@ bool Scheduler::ProcessTaskScheduling( IdleRunPolicy 
eIdleRunPolicy )
 
 ImplSchedulerData* pSchedulerData = pSVData->mpFirstSchedulerData;
 ImplSchedulerData* pPrevSchedulerData = nullptr;
+ImplSchedulerData *pPrevMostUrgent = nullptr;
 ImplSchedulerData *pMostUrgent = nullptr;
 sal_uInt64 nMinPeriod = InfiniteTimeoutMs;
 
@@ -203,12 +201,15 @@ bool Scheduler::ProcessTaskScheduling( IdleRunPolicy 
eIdleRunPolicy )
 // if the priority of the current task is higher (numerical value is 
lower) than
 // the priority of the most urgent, the current task becomes the new 
most urgent
 if ( !pMostUrgent )
+{
+pPrevMostUrgent = pPrevSchedulerData;
 pMostUrgent = pSchedulerData;
 goto next_entry;
 }
 else if ( pSchedulerData->mpScheduler->GetPriority() < 
pMostUrgent->mpScheduler->GetPriority() )
 {
 UpdateMinPeriod( pMostUrgent, nTime, nMinPeriod );
+pPrevMostUrgent = pPrevSchedulerData;
 pMostUrgent = pSchedulerData;
 goto next_entry;
 }
@@ -225,6 +226,9 @@ next_entry:
 
 if ( pMostUrgent )
 {
+assert( pPrevMostUrgent != pMostUrgent );
+assert( !pPrevMostUrgent || (pPrevMostUrgent->mpNext == pMostUrgent) );
+
 pMostUrgent->mnUpdateTime = nTime;
 UpdateMinPeriod( pMostUrgent, nTime, nMinPeriod );
 
@@ -234,6 +238,21 @@ next_entry:
 pMostUrgent->Invoke();
 SAL_INFO_IF( !pMostUrgent->mpScheduler, "vcl.schedule", 
tools::Time::GetSystemTicks()
  << " " << pMostUrgent <<  "  tag-rm " );
+
+// do some simple round-robin scheduling
+// nothing to do, if we're already the last element
+if ( pMostUrgent->mpScheduler && pMostUrgent->mpNext )
+{
+if ( pPrevMostUrgent )
+pPrevMostUrgent->mpNext = pMostUrgent->mpNext;
+else
+pSVData->mpFirstSchedulerData = pMostUrgent->mpNext;
+// Invoke might have added tasks to the end of the list
+while ( pPrevSchedulerData->mpNext )
+pPrevSchedulerData = pPrevSchedulerData->mpNext;
+pPrevSchedulerData->mpNext = pMostUrgent;
+pMostUrgent->mpNext = nullptr;
+}
 }
 
 if ( nMinPeriod != InfiniteTimeoutMs
@@ -272,26 +291,40 @@ void Scheduler::Start()
 mpSchedulerData = new ImplSchedulerData;
 mpSchedulerData->mpScheduler   = this;
 mpSchedulerData->mbInScheduler = false;
+mpSchedulerData->mpNext = nullptr;
 
 // insert last due to SFX!
-ImplSchedulerData* pPrev = nullptr;
 ImplSchedulerData* pData = pSVData->mpFirstSchedulerData;
-while ( pData )
+if ( pData )
 {
-pPrev = pData;
-pData = pData->mpNext;
+while ( pData->mpNext )
+pData = pData->mpNext;
+pData->mpNext = mpSchedulerData;
 }
-mpSchedulerData->mpNext = nullptr;
-if ( pPrev )
-pPrev->mpNext = mpSchedulerData;
 else
 pSVData->mpFirstSchedulerData = mpSchedulerData;
 SAL_INFO( "vcl.schedule", tools::Time::GetSystemTicks() << " " << 
mpSchedulerData
  <<  "  added  " << (int) mePriority << " " << mpDebugName );
 }
 else
-SAL_INFO( "vcl.schedule", tools::Time::GetSystemTicks() << " " << 
mpSchedulerData
- <<  "  restarted  " << (int) mePriority << " " << mpDebugName );
+{
+if ( mpSchedulerData->mpNext )
+{
+ImplSchedulerData* pData = pSVData->mpFirstSchedulerData;
+while ( pData->mpNext != mpSchedulerData )
+pData = pData->mpNext;
+pData->mpNext = mpSchedulerData->mpNext;
+mpSchedulerData->mpNext = nullpt

[Libreoffice-commits] core.git: .editorconfig

2016-09-19 Thread Samuel Mehrbrodt
 .editorconfig |   25 +
 1 file changed, 25 insertions(+)

New commits:
commit b1e9c9ae07bcdffb23925162e261633be2ee9bfe
Author: Samuel Mehrbrodt 
Date:   Fri Sep 16 15:54:57 2016 +0200

Add .editorconfig file

See http://editorconfig.org

Change-Id: Ia571ca5d53fb9f02bd8d208b922c8ec5ef1939e5
Reviewed-on: https://gerrit.libreoffice.org/28962
Reviewed-by: Samuel Mehrbrodt 
Tested-by: Samuel Mehrbrodt 

diff --git a/.editorconfig b/.editorconfig
new file mode 100644
index 000..4a5babf
--- /dev/null
+++ b/.editorconfig
@@ -0,0 +1,25 @@
+# EditorConfig: http://EditorConfig.org
+
+# top-most EditorConfig file
+root = true
+
+# General settings
+[*]
+end_of_line = lf
+insert_final_newline = true
+charset = utf-8
+trim_trailing_whitespace = true
+
+# Source code files
+[*.{c,cxx,cpp,h,hxx,hpp,java,py}]
+indent_style = space
+indent_size = 4
+
+# Makefiles
+[{Makefile,*.mk}]
+indent_style = tab
+trim_trailing_whitespace = false
+
+# Patch files
+[*.patch.*]
+trim_trailing_whitespace = false
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/test

2016-09-19 Thread Miklos Vajna
 loolwsd/test/httpwstest.cpp |   23 +++
 1 file changed, 23 insertions(+)

New commits:
commit 21f8b072f33d5dbd9939bc5d91432ae2a663488c
Author: Miklos Vajna 
Date:   Mon Sep 19 16:32:13 2016 +0200

Add EMPTY cell cursor testcase

Change-Id: I8d1e86a72eb3383d8d012d884a24233f8ee3079c

diff --git a/loolwsd/test/httpwstest.cpp b/loolwsd/test/httpwstest.cpp
index 2877797..bf4eee1 100644
--- a/loolwsd/test/httpwstest.cpp
+++ b/loolwsd/test/httpwstest.cpp
@@ -80,6 +80,7 @@ class HTTPWSTest : public CPPUNIT_NS::TestFixture
 CPPUNIT_TEST(testInactiveClient);
 CPPUNIT_TEST(testMaxColumn);
 CPPUNIT_TEST(testMaxRow);
+CPPUNIT_TEST(testEmptyCellCursor);
 CPPUNIT_TEST(testInsertAnnotationWriter);
 CPPUNIT_TEST(testEditAnnotationWriter);  // Broken with multiview.
 CPPUNIT_TEST(testInsertAnnotationCalc);
@@ -120,6 +121,7 @@ class HTTPWSTest : public CPPUNIT_NS::TestFixture
 void testInactiveClient();
 void testMaxColumn();
 void testMaxRow();
+void testEmptyCellCursor();
 void testInsertAnnotationWriter();
 void testEditAnnotationWriter();
 void testInsertAnnotationCalc();
@@ -1125,6 +1127,27 @@ void HTTPWSTest::testMaxRow()
 }
 }
 
+void HTTPWSTest::testEmptyCellCursor()
+{
+// Load a document, and make sure a cell cursor shows up.
+std::string docPath;
+std::string docURL;
+getDocumentPathAndURL("setclientpart.ods", docPath, docURL);
+Poco::Net::HTTPRequest request(Poco::Net::HTTPRequest::HTTP_GET, docURL);
+std::shared_ptr socket = loadDocAndGetSocket(_uri, 
docURL);
+std::string response;
+getResponseMessage(socket, "cellcursor:", response, false);
+
+// Begin text edit of a cell.
+sendTextFrame(socket, "key type=input char=115 key=97");
+
+// Make sure the cell cursor is now hidden.
+getResponseMessage(socket, "cellcursor: ", response, false);
+// This failed as response was "", not "EMPTY", because code in
+// Document::ViewCallback() crashed.
+CPPUNIT_ASSERT_EQUAL(std::string("EMPTY"), response);
+}
+
 void HTTPWSTest::testNoExtraLoolKitsLeft()
 {
 const auto countNow = countLoolKitProcesses(InitialLoolKitCount);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Caolán McNamara
 sw/source/core/crsr/bookmrk.cxx |3 ++-
 writerfilter/source/rtftok/rtftokenizer.cxx |   15 ---
 2 files changed, 6 insertions(+), 12 deletions(-)

New commits:
commit c708c9351bf2ef578e2f200ee834731c31d80261
Author: Caolán McNamara 
Date:   Mon Sep 19 15:57:02 2016 +0100

fftester: isAsciiLowerCase has a isUnicodeCodePoint assert

which is not helpful when the data is incoming from the outside
world

Change-Id: I00304ed0d577944a33f5fa6af155f1d130ab7d59

diff --git a/writerfilter/source/rtftok/rtftokenizer.cxx 
b/writerfilter/source/rtftok/rtftokenizer.cxx
index 8ca7433..5727b14 100644
--- a/writerfilter/source/rtftok/rtftokenizer.cxx
+++ b/writerfilter/source/rtftok/rtftokenizer.cxx
@@ -170,24 +170,17 @@ int RTFTokenizer::asHex(char ch)
 ret = ch - '0';
 else
 {
-if (rtl::isAsciiLowerCase(ch))
-{
-if (ch < 'a' || ch > 'f')
-return -1;
+if (ch >= 'a' && ch <= 'f')
 ret = ch - 'a';
-}
-else
-{
-if (ch < 'A' || ch > 'F')
-return -1;
+else if (ch >= 'A' && ch <= 'F')
 ret = ch - 'A';
-}
+else
+return -1;
 ret += 10;
 }
 return ret;
 }
 
-
 void RTFTokenizer::pushGroup()
 {
 m_nGroup++;
commit 8d5db645ca0c910fc624d3513be7d312aea4a49c
Author: Caolán McNamara 
Date:   Mon Sep 19 15:38:09 2016 +0100

fftester: only decrement if there's a valid position before it

Change-Id: I64bddeb805ac5c2ad6d76e2b3271ae8a216d603f

diff --git a/sw/source/core/crsr/bookmrk.cxx b/sw/source/core/crsr/bookmrk.cxx
index 08594bc..26ec9f9 100644
--- a/sw/source/core/crsr/bookmrk.cxx
+++ b/sw/source/core/crsr/bookmrk.cxx
@@ -133,7 +133,8 @@ namespace
 if ( ch_end == aEndMark )
 {
 SwPaM aEnd(rEnd, rEnd);
---aEnd.Start()->nContent;
+if (aEnd.Start()->nContent > 0)
+--aEnd.Start()->nContent;
 io_pDoc->getIDocumentContentOperations().DeleteRange(aEnd);
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'refs/notes/commits' - 92/65749be4b0ba24f04c39d78354109e5fcedcfc

2016-09-19 Thread Caolán McNamara
 92/65749be4b0ba24f04c39d78354109e5fcedcfc |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 4adc429010dce33045523837332a5939c2ddd3a7
Author: Caolán McNamara 
Date:   Mon Sep 19 16:01:36 2016 +0100

Notes added by 'git notes add'

diff --git a/92/65749be4b0ba24f04c39d78354109e5fcedcfc 
b/92/65749be4b0ba24f04c39d78354109e5fcedcfc
new file mode 100644
index 000..39b7cd1
--- /dev/null
+++ b/92/65749be4b0ba24f04c39d78354109e5fcedcfc
@@ -0,0 +1 @@
+prefer: 6692eeca9a3ba7a9ba461564172275fbb78992e9
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: How to keep UNO applications connected after closing LibreOffice

2016-09-19 Thread Samuel Mehrbrodt

I went with the first option and created this patch: 
https://gerrit.libreoffice.org/#/c/29018

It turned out we need to implement both. The first option was fine when only 
closing the window - but we also want to be able to close the visible frames 
with "File->Exit" while keeping the process running.
So I changed the semantics of the TerminationVetoException accordingly: 
https://gerrit.libreoffice.org/#/c/29031
With that patch, the TerminationVetoException lets you close the windows, but 
vetoes the termination. Before it also vetoed the closing of the windows.

If one still need to veto closing documents/frames, one could use the 
CloseVetoException.

I will of course document the new behavior in the release notes (if no 
objections come in).

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


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

2016-09-19 Thread Markus Mohrhard
 sc/source/core/data/document10.cxx |7 +--
 1 file changed, 5 insertions(+), 2 deletions(-)

New commits:
commit 3a9917b66d6820ec9f2844f8292a46d8b0b9180b
Author: Markus Mohrhard 
Date:   Mon Sep 19 17:18:21 2016 +0200

tdf#100393, handle copying one cell to multiple cols with cond format

The same fix has been applied for rows already.

Change-Id: I77300680a657fb874d07641fbae928eb6c210acd

diff --git a/sc/source/core/data/document10.cxx 
b/sc/source/core/data/document10.cxx
index be9c855..0bad66d 100644
--- a/sc/source/core/data/document10.cxx
+++ b/sc/source/core/data/document10.cxx
@@ -126,8 +126,11 @@ bool ScDocument::CopyOneCellFromClip(
 if (rCxt.getInsertFlag() & InsertDeleteFlags::ATTRIB)
 for (SCROW nRow = nRow1; nRow <= nRow2; ++nRow)
 {
-maTabs[i]->CopyConditionalFormat(nCol1, nRow, nCol2, nRow, 
nCol1 - aClipRange.aStart.Col(),
-nRow - aClipRange.aStart.Row(), pSrcTab);
+for (SCCOL nCol = nCol1; nCol <= nCol2; ++nCol)
+{
+maTabs[i]->CopyConditionalFormat(nCol, nRow, nCol, nRow, 
nCol - aClipRange.aStart.Col(),
+nRow - aClipRange.aStart.Row(), pSrcTab);
+}
 }
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: writerperfect/Library_wpftdraw.mk

2016-09-19 Thread Jan-Marek Glogowski
 writerperfect/Library_wpftdraw.mk |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 5c8ad526447934a5eae94fa5f40584083a874d9f
Author: Jan-Marek Glogowski 
Date:   Mon Sep 12 11:54:51 2016 +0200

Fix '--as-needed' build for zmf with system libpng

Change-Id: I92378dae4a515a587c897fff83b15d8e836b0aa2
Reviewed-on: https://gerrit.libreoffice.org/28974
Tested-by: Jenkins 
Reviewed-by: Jan-Marek Glogowski 

diff --git a/writerperfect/Library_wpftdraw.mk 
b/writerperfect/Library_wpftdraw.mk
index ec9057c..cff3090 100644
--- a/writerperfect/Library_wpftdraw.mk
+++ b/writerperfect/Library_wpftdraw.mk
@@ -50,6 +50,7 @@ $(eval $(call gb_Library_use_externals,wpftdraw,\
mspub \
mwaw \
odfgen \
+   zmf \
png \
pagemaker \
revenge \
@@ -58,7 +59,6 @@ $(eval $(call gb_Library_use_externals,wpftdraw,\
wpg \
wpd \
zlib \
-   zmf \
lcms2 \
libxml2 \
icui18n \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: How to keep UNO applications connected after closing LibreOffice

2016-09-19 Thread Stephan Bergmann

On 09/19/2016 05:17 PM, Samuel Mehrbrodt wrote:

It turned out we need to implement both. The first option was fine when
only closing the window - but we also want to be able to close the
visible frames with "File->Exit" while keeping the process running.


Do we?  I think there is probably a difference in what we can imply as 
user-expected behavior between closing the last window (via "Window - 
Close Window" or whatever desktop-environment--specific trigger) and 
terminating LO (via "File - Exit LibreOffice").

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


[Libreoffice-commits] core.git: Branch 'feature/new-vcl-scheduler' - 11 commits - avmedia/source basctl/source cui/source dbaccess/source desktop/qa desktop/source editeng/source formula/source framew

2016-09-19 Thread Jan-Marek Glogowski
Rebased ref, commits from common ancestor:
commit 31cb634f3bd1c5d87537079c7d5a00ddfa313877
Author: Jan-Marek Glogowski 
Date:   Tue Sep 13 11:03:08 2016 +0200

Round-robin invoked / started tasks

And some simple round-robin to the task processing, so equal
priority (auto) tasks won't always be scheduled, if there are
multiple with the same priority.

Currently breaks LO, which indicates dependencies in the same
priority class, which must not exist!

Change-Id: If84496bff68aec42d0fa63c2b7e05c3202f67b2c

diff --git a/vcl/source/app/scheduler.cxx b/vcl/source/app/scheduler.cxx
index 647dbb4..be7440d 100644
--- a/vcl/source/app/scheduler.cxx
+++ b/vcl/source/app/scheduler.cxx
@@ -30,9 +30,6 @@ void ImplSchedulerData::Invoke()
 if ( !mpScheduler || mbInScheduler )
 return;
 
-// tdf#92036 Reset the period to avoid re-firing immediately.
-mpScheduler->mpSchedulerData->mnUpdateTime = tools::Time::GetSystemTicks();
-
 Scheduler *sched = mpScheduler;
 
 // prepare Scheduler Object for deletion after handling
@@ -173,6 +170,7 @@ bool Scheduler::ProcessTaskScheduling( IdleRunPolicy 
eIdleRunPolicy )
 
 ImplSchedulerData* pSchedulerData = pSVData->mpFirstSchedulerData;
 ImplSchedulerData* pPrevSchedulerData = nullptr;
+ImplSchedulerData *pPrevMostUrgent = nullptr;
 ImplSchedulerData *pMostUrgent = nullptr;
 sal_uInt64 nMinPeriod = InfiniteTimeoutMs;
 
@@ -203,12 +201,15 @@ bool Scheduler::ProcessTaskScheduling( IdleRunPolicy 
eIdleRunPolicy )
 // if the priority of the current task is higher (numerical value is 
lower) than
 // the priority of the most urgent, the current task becomes the new 
most urgent
 if ( !pMostUrgent )
+{
+pPrevMostUrgent = pPrevSchedulerData;
 pMostUrgent = pSchedulerData;
 goto next_entry;
 }
 else if ( pSchedulerData->mpScheduler->GetPriority() < 
pMostUrgent->mpScheduler->GetPriority() )
 {
 UpdateMinPeriod( pMostUrgent, nTime, nMinPeriod );
+pPrevMostUrgent = pPrevSchedulerData;
 pMostUrgent = pSchedulerData;
 goto next_entry;
 }
@@ -225,6 +226,9 @@ next_entry:
 
 if ( pMostUrgent )
 {
+assert( pPrevMostUrgent != pMostUrgent );
+assert( !pPrevMostUrgent || (pPrevMostUrgent->mpNext == pMostUrgent) );
+
 pMostUrgent->mnUpdateTime = nTime;
 UpdateMinPeriod( pMostUrgent, nTime, nMinPeriod );
 
@@ -234,6 +238,21 @@ next_entry:
 pMostUrgent->Invoke();
 SAL_INFO_IF( !pMostUrgent->mpScheduler, "vcl.schedule", 
tools::Time::GetSystemTicks()
  << " " << pMostUrgent <<  "  tag-rm " );
+
+// do some simple round-robin scheduling
+// nothing to do, if we're already the last element
+if ( pMostUrgent->mpScheduler && pMostUrgent->mpNext )
+{
+if ( pPrevMostUrgent )
+pPrevMostUrgent->mpNext = pMostUrgent->mpNext;
+else
+pSVData->mpFirstSchedulerData = pMostUrgent->mpNext;
+// Invoke might have added tasks to the end of the list
+while ( pPrevSchedulerData->mpNext )
+pPrevSchedulerData = pPrevSchedulerData->mpNext;
+pPrevSchedulerData->mpNext = pMostUrgent;
+pMostUrgent->mpNext = nullptr;
+}
 }
 
 if ( nMinPeriod != InfiniteTimeoutMs
@@ -272,26 +291,40 @@ void Scheduler::Start()
 mpSchedulerData = new ImplSchedulerData;
 mpSchedulerData->mpScheduler   = this;
 mpSchedulerData->mbInScheduler = false;
+mpSchedulerData->mpNext = nullptr;
 
 // insert last due to SFX!
-ImplSchedulerData* pPrev = nullptr;
 ImplSchedulerData* pData = pSVData->mpFirstSchedulerData;
-while ( pData )
+if ( pData )
 {
-pPrev = pData;
-pData = pData->mpNext;
+while ( pData->mpNext )
+pData = pData->mpNext;
+pData->mpNext = mpSchedulerData;
 }
-mpSchedulerData->mpNext = nullptr;
-if ( pPrev )
-pPrev->mpNext = mpSchedulerData;
 else
 pSVData->mpFirstSchedulerData = mpSchedulerData;
 SAL_INFO( "vcl.schedule", tools::Time::GetSystemTicks() << " " << 
mpSchedulerData
  <<  "  added  " << (int) mePriority << " " << mpDebugName );
 }
 else
-SAL_INFO( "vcl.schedule", tools::Time::GetSystemTicks() << " " << 
mpSchedulerData
- <<  "  restarted  " << (int) mePriority << " " << mpDebugName );
+{
+if ( mpSchedulerData->mpNext )
+{
+ImplSchedulerData* pData = pSVData->mpFirstSchedulerData;
+while ( pData->mpNext != mpSchedulerData )
+pData = pData->mpNext;
+pData->mpNext = mpSchedulerData->mpNext;
+mpSchedulerData->mpNext = nullpt

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

2016-09-19 Thread Eike Rathke
 sc/source/core/tool/interpr4.cxx |   26 --
 1 file changed, 24 insertions(+), 2 deletions(-)

New commits:
commit 388014fc19b2a785f887cdfee91100fc9ab8d58d
Author: Eike Rathke 
Date:   Mon Sep 19 18:04:54 2016 +0200

Resolves: tdf#100409 do not return coded double error for single matrix 
value

Change-Id: I94477bf64ee7972e9822921a8a15d935cb01e53b

diff --git a/sc/source/core/tool/interpr4.cxx b/sc/source/core/tool/interpr4.cxx
index 5c39c81..09a4b83 100644
--- a/sc/source/core/tool/interpr4.cxx
+++ b/sc/source/core/tool/interpr4.cxx
@@ -2021,14 +2021,36 @@ double ScInterpreter::GetDoubleFromMatrix(const 
ScMatrixRef& pMat)
 return 0.0;
 
 if ( !pJumpMatrix )
-return pMat->GetDoubleWithStringConversion( 0, 0);
+{
+double fVal = pMat->GetDoubleWithStringConversion( 0, 0);
+sal_uInt16 nErr = GetDoubleErrorValue( fVal);
+if (nErr)
+{
+// Do not propagate the coded double error, but set nGlobalError in
+// case the matrix did not have an error interpreter set.
+SetError( nErr);
+fVal = 0.0;
+}
+return fVal;
+}
 
 SCSIZE nCols, nRows, nC, nR;
 pMat->GetDimensions( nCols, nRows);
 pJumpMatrix->GetPos( nC, nR);
 // Use vector replication for single row/column arrays.
 if ( (nC < nCols || nCols == 1) && (nR < nRows || nRows == 1) )
-return pMat->GetDoubleWithStringConversion( nC, nR);
+{
+double fVal = pMat->GetDoubleWithStringConversion( nC, nR);
+sal_uInt16 nErr = GetDoubleErrorValue( fVal);
+if (nErr)
+{
+// Do not propagate the coded double error, but set nGlobalError in
+// case the matrix did not have an error interpreter set.
+SetError( nErr);
+fVal = 0.0;
+}
+return fVal;
+}
 
 SetError( errNoValue);
 return 0.0;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'feature/fixes36' - vcl/inc vcl/source

2016-09-19 Thread Tomaž Vajngerl
 vcl/inc/opengl/watchdog.hxx|   35 +
 vcl/inc/opengl/zone.hxx|1 
 vcl/source/opengl/OpenGLHelper.cxx |   51 ++---
 3 files changed, 78 insertions(+), 9 deletions(-)

New commits:
commit a3ec258976fb305a4b38012a45fd9f591faedf5d
Author: Tomaž Vajngerl 
Date:   Mon Sep 19 18:03:47 2016 +0200

vcl: relax timeout timings for the GL watchdog

Some OS/GPU combinations need more relaxed watchdog timeout timings
as the shader compilation takes too long to complete.

Change-Id: Ifd9ff7ecfa4b004d5411d6d364dd01a389a3fcec

diff --git a/vcl/inc/opengl/watchdog.hxx b/vcl/inc/opengl/watchdog.hxx
index 0213efb..ce97064 100644
--- a/vcl/inc/opengl/watchdog.hxx
+++ b/vcl/inc/opengl/watchdog.hxx
@@ -14,6 +14,41 @@
 #include 
 #include 
 #include 
+#include 
+
+struct WatchdogTimings
+{
+osl::Mutex maMutex;
+
+int mnMode;
+
+std::vector maDisableEntries;
+std::vector maAbortAfter;
+
+WatchdogTimings();
+
+void relax();
+
+int getMode()
+{
+return mnMode;
+}
+
+void setMode(int nMode)
+{
+mnMode = nMode;
+}
+
+int getDisableEntries()
+{
+   return maDisableEntries[mnMode];
+}
+
+int getAbortAfter()
+{
+return maAbortAfter[mnMode];
+}
+};
 
 class OpenGLWatchdogThread : private salhelper::Thread
 {
diff --git a/vcl/inc/opengl/zone.hxx b/vcl/inc/opengl/zone.hxx
index 11f6ed0..65a7249 100644
--- a/vcl/inc/opengl/zone.hxx
+++ b/vcl/inc/opengl/zone.hxx
@@ -38,6 +38,7 @@ public:
 ~OpenGLZone() { gnLeaveCount++; }
 static bool isInZone() { return gnEnterCount != gnLeaveCount; }
 static void hardDisable();
+static void relaxWatchdogTimings();
 };
 
 /// Create this to not only enter the zone, but set VCL context.
diff --git a/vcl/source/opengl/OpenGLHelper.cxx 
b/vcl/source/opengl/OpenGLHelper.cxx
index 5dff689..38317e5 100644
--- a/vcl/source/opengl/OpenGLHelper.cxx
+++ b/vcl/source/opengl/OpenGLHelper.cxx
@@ -780,6 +780,13 @@ bool OpenGLHelper::isDeviceBlacklisted()
 #elif defined( _WIN32 )
 WinOpenGLDeviceInfo aInfo;
 bBlacklisted = aInfo.isDeviceBlocked();
+
+if (aInfo.GetWindowsVersion() == 0x00060001 && /* Windows 7 */
+aInfo.GetAdapterVendorID() == "0x1022")/* AMD */
+{
+SAL_INFO("vcl.opengl", "Relaxing watchdog timings.");
+OpenGLZone::relaxWatchdogTimings();
+}
 #else
 bBlacklisted = false;
 #endif
@@ -806,9 +813,27 @@ void OpenGLZone::leave() { gnLeaveCount++; }
 namespace {
 static volatile bool gbWatchdogFiring = false;
 static oslCondition gpWatchdogExit = nullptr;
+static WatchdogTimings gWatchdogTimings;
 static rtl::Reference gxWatchdog;
 }
 
+WatchdogTimings::WatchdogTimings()
+: mnMode(0)
+, maDisableEntries({ 6 /* 1.5s */,  20 /* 5s */ })
+, maAbortAfter({ 20 /* 5s */, 120 /* 30s */ })
+{}
+
+void WatchdogTimings::relax()
+{
+osl::MutexGuard g(maMutex);
+
+maDisableEntries[0] = 20; /*  5s */
+maDisableEntries[1] = 60; /* 15s */
+
+maAbortAfter[0] = 40;  /* 10s */
+maAbortAfter[1] = 240; /* 60s */
+}
+
 OpenGLWatchdogThread::OpenGLWatchdogThread()
 : salhelper::Thread("OpenGL Watchdog")
 {
@@ -821,20 +846,23 @@ void OpenGLWatchdogThread::execute()
 static const int nAbortAfter[2] = { 20 /* 10s */, 120 /* 30s */ };
 
 int nUnchanged = 0; // how many unchanged nEnters
-TimeValue aHalfSecond(0, 1000*1000*1000*0.25);
+TimeValue aQuarterSecond(0, 1000*1000*1000*0.25);
 bool bAbortFired = false;
 
 do {
 sal_uInt64 nLastEnters = OpenGLZone::gnEnterCount;
 
-osl_waitCondition(gpWatchdogExit, &aHalfSecond);
+osl_waitCondition(gpWatchdogExit, &aQuarterSecond);
 
 if (OpenGLZone::isInZone())
 {
-int nType = 0;
+osl::MutexGuard g(gWatchdogTimings.maMutex);
+
 // The shader compiler can take a long time, first time.
 if (gbInShaderCompile)
-nType = 1;
+gWatchdogTimings.setMode(1);
+else
+gWatchdogTimings.setMode(0);
 
 if (nLastEnters == OpenGLZone::gnEnterCount)
 nUnchanged++;
@@ -843,12 +871,12 @@ void OpenGLWatchdogThread::execute()
 SAL_INFO("vcl.opengl", "GL watchdog - unchanged " <<
  nUnchanged << " enter count " <<
  OpenGLZone::gnEnterCount << " type " <<
- (nType ? "in shader" : "normal gl") <<
- "breakpoints mid: " << nDisableEntries[nType] <<
- " max " << nAbortAfter[nType]);
+ (gWatchdogTimings.getMode() ? "in shader" : "normal gl") 
<<
+ "breakpoints mid: " << 
gWatchdogTimings.getDisableEntries() <<
+ " max " << gWatchdogTimings.getAbortAfter());
 
 // Not making progress
-   

[Libreoffice-commits] core.git: Changes to 'private/jmux/new-vcl-scheduler+kde4'

2016-09-19 Thread Jan-Marek Glogowski
New branch 'private/jmux/new-vcl-scheduler+kde4' available with the following 
commits:
commit 88b92fb7d131113a390ec385dd63fc0e7ced5e88
Author: Jan-Marek Glogowski 
Date:   Wed Oct 29 15:54:29 2014 +0100

KDE4: Switch default image color to transparent...

and just fill the painted image once at the beginning.

Also adapt background based on the control information from Qt4.

Change-Id: I39c03b2ca779381920e2597b4bea7973fea6ae2a

___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Eike Rathke
 sc/source/core/tool/interpr4.cxx |   19 ---
 1 file changed, 12 insertions(+), 7 deletions(-)

New commits:
commit aa51bf1e17dfb4a0a95a24e7de7f55d2b44b9472
Author: Eike Rathke 
Date:   Mon Sep 19 18:49:03 2016 +0200

in GetInt...() check !isFinite() instead of isNan()

... and propagate coded double error instead of setting
errIllegalArgument.

Change-Id: I28456c3b0320181a80fe255e875a0bd78216c279

diff --git a/sc/source/core/tool/interpr4.cxx b/sc/source/core/tool/interpr4.cxx
index 09a4b83..d94c74c 100644
--- a/sc/source/core/tool/interpr4.cxx
+++ b/sc/source/core/tool/interpr4.cxx
@@ -2149,9 +2149,9 @@ double ScInterpreter::GetDoubleWithDefault(double 
nDefault)
 sal_Int32 ScInterpreter::GetInt32()
 {
 double fVal = GetDouble();
-if (rtl::math::isNan(fVal))
+if (!rtl::math::isFinite(fVal))
 {
-SetError(errIllegalArgument);
+SetError( GetDoubleErrorValue( fVal));
 return SAL_MAX_INT32;
 }
 if (fVal > 0.0)
@@ -2178,9 +2178,9 @@ sal_Int32 ScInterpreter::GetInt32()
 sal_Int32 ScInterpreter::GetInt32WithDefault( sal_Int32 nDefault )
 {
 double fVal = GetDoubleWithDefault( nDefault);
-if (rtl::math::isNan(fVal))
+if (!rtl::math::isFinite(fVal))
 {
-SetError(errIllegalArgument);
+SetError( GetDoubleErrorValue( fVal));
 return SAL_MAX_INT32;
 }
 if (fVal > 0.0)
@@ -2207,9 +2207,9 @@ sal_Int32 ScInterpreter::GetInt32WithDefault( sal_Int32 
nDefault )
 sal_Int16 ScInterpreter::GetInt16()
 {
 double fVal = GetDouble();
-if (rtl::math::isNan(fVal))
+if (!rtl::math::isFinite(fVal))
 {
-SetError(errIllegalArgument);
+SetError( GetDoubleErrorValue( fVal));
 return SAL_MAX_INT16;
 }
 if (fVal > 0.0)
@@ -2236,7 +2236,12 @@ sal_Int16 ScInterpreter::GetInt16()
 sal_uInt32 ScInterpreter::GetUInt32()
 {
 double fVal = rtl::math::approxFloor( GetDouble());
-if (rtl::math::isNan(fVal) || fVal < 0.0 || fVal > SAL_MAX_UINT32)
+if (!rtl::math::isFinite(fVal))
+{
+SetError( GetDoubleErrorValue( fVal));
+return SAL_MAX_UINT32;
+}
+if (fVal < 0.0 || fVal > SAL_MAX_UINT32)
 {
 SetError( errIllegalArgument);
 return SAL_MAX_UINT32;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Miklos Vajna
 desktop/source/lib/init.cxx |1 
 libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx |   18 +++-
 sfx2/source/control/unoctitm.cxx|3 +-
 sw/qa/extras/tiledrendering/tiledrendering.cxx  |   28 +++-
 sw/source/uibase/uiview/viewstat.cxx|   25 +
 5 files changed, 65 insertions(+), 10 deletions(-)

New commits:
commit 288013f25d2e52a76f7ce5368c505a6ccb3b64a2
Author: Miklos Vajna 
Date:   Mon Sep 19 17:56:35 2016 +0200

sw: emit LOK_CALLBACK_STATE_CHANGED when cursor enters/leaves a redline

For now only care about the start of the cursor, which can be only at a
single redline.

Add matching testcase + expose it in the gtktiledviewer status bar for
interactive manual testing.

Change-Id: Ib61757412d6b54bef64361d4a8563795ca0bab6c

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 39e6c65..47a5ca7 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -1203,6 +1203,7 @@ static void doc_iniUnoCommands ()
 OUString(".uno:SortAscending"),
 OUString(".uno:SortDescending"),
 OUString(".uno:TrackChanges"),
+OUString(".uno:AcceptTrackedChange"),
 };
 
 util::URL aCommandURL;
diff --git a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx 
b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
index 2576f99..385203d 100644
--- a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
+++ b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
@@ -97,6 +97,7 @@ public:
 GtkWidget* m_pStatusBar;
 GtkWidget* m_pProgressBar;
 GtkWidget* m_pStatusbarLabel;
+GtkWidget* m_pRedlineLabel;
 GtkWidget* m_pZoomLabel;
 GtkToolItem* m_pSaveButton;
 GtkToolItem* m_pCopyButton;
@@ -145,6 +146,7 @@ public:
 m_pStatusBar(nullptr),
 m_pProgressBar(nullptr),
 m_pStatusbarLabel(nullptr),
+m_pRedlineLabel(nullptr),
 m_pZoomLabel(nullptr),
 m_pSaveButton(nullptr),
 m_pCopyButton(nullptr),
@@ -786,7 +788,7 @@ static void changeZoom( GtkWidget* pButton, gpointer /* 
pItem */ )
 lok_doc_view_set_visible_area(LOK_DOC_VIEW(pDocView), 
&aVisibleArea);
 }
 }
-std::string aZoom = std::to_string(int(fZoom * 100)) + std::string("%");
+std::string aZoom = std::string("Zoom: ") + std::to_string(int(fZoom * 
100)) + std::string("%");
 gtk_label_set_text(GTK_LABEL(rWindow.m_pZoomLabel), aZoom.c_str());
 }
 
@@ -1159,6 +1161,15 @@ static void signalCommand(LOKDocView* pLOKDocView, char* 
pPayload, gpointer /*pD
 rWindow.m_aToolItemSensitivities[pItem] = bSensitive;
 }
 }
+else if (aKey == ".uno:TrackedChangeIndex")
+{
+std::string aText = std::string("Current redline: ");
+if (aValue.empty())
+aText += "none";
+else
+aText += aValue;
+gtk_label_set_text(GTK_LABEL(rWindow.m_pRedlineLabel), 
aText.c_str());
+}
 }
 }
 
@@ -1800,7 +1811,9 @@ static GtkWidget* createWindow(TiledWindow& rWindow)
 gtk_widget_set_hexpand(rWindow.m_pStatusbarLabel, TRUE);
 gtk_container_add(GTK_CONTAINER(pStatusBar), rWindow.m_pStatusbarLabel);
 
-rWindow.m_pZoomLabel = gtk_label_new("100%");
+rWindow.m_pRedlineLabel = gtk_label_new("Current redline: none");
+gtk_container_add(GTK_CONTAINER(pStatusBar), rWindow.m_pRedlineLabel);
+rWindow.m_pZoomLabel = gtk_label_new("Zoom: 100%");
 gtk_container_add(GTK_CONTAINER(pStatusBar), rWindow.m_pZoomLabel);
 
 gtk_widget_show_all(pWindow);
@@ -1813,6 +1826,7 @@ static GtkWidget* createWindow(TiledWindow& rWindow)
 gtk_widget_hide(rWindow.m_pFormulabarEntry);
 // Hide the non-progressbar children of the status bar by default.
 gtk_widget_hide(rWindow.m_pStatusbarLabel);
+gtk_widget_hide(rWindow.m_pRedlineLabel);
 gtk_widget_hide(rWindow.m_pZoomLabel);
 
 g_aWindows[pWindow] = rWindow;
diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx
index 9c3ed15..49d9c40 100644
--- a/sfx2/source/control/unoctitm.cxx
+++ b/sfx2/source/control/unoctitm.cxx
@@ -971,7 +971,8 @@ static void InterceptLOKStateChangeEvent(const 
SfxViewFrame* pViewFrame, const c
 aEvent.FeatureURL.Path == "Strikeout" ||
 aEvent.FeatureURL.Path == "Underline" ||
 aEvent.FeatureURL.Path == "ModifiedStatus" ||
-aEvent.FeatureURL.Path == "TrackChanges")
+aEvent.FeatureURL.Path == "TrackChanges" ||
+aEvent.FeatureURL.Path == "AcceptTrackedChange")
 {
 bool bTemp = false;
 aEvent.State >>= bTemp;
diff --git a/sw/qa/extras/tiledrendering/tiledrendering.cxx 
b/sw/qa/extras/tiledrendering/tiledrendering.cxx
index 69f965c..f203fca 100644
--- a/sw/qa/extras/tiledrendering/tiledrendering.cxx
+++ b/sw/qa/extras/tiledrendering/tiledrendering.cxx
@@ -27,6 +2

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

2016-09-19 Thread Milos Sramek
 writerfilter/inc/dmapper/resourcemodel.hxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 5c71ae07229b1a76b6ad54c485c8cde55ea309e5
Author: Milos Sramek 
Date:   Mon Sep 19 17:13:52 2016 +0200

Explanation of the SPRM acronym added to definition of the Sprm class

Change-Id: I536cd6ba2d531292d5148819dfd914b76f4b
Reviewed-on: https://gerrit.libreoffice.org/29032
Reviewed-by: Katarina Behrens 
Tested-by: Katarina Behrens 

diff --git a/writerfilter/inc/dmapper/resourcemodel.hxx 
b/writerfilter/inc/dmapper/resourcemodel.hxx
index 043c160..252d833 100644
--- a/writerfilter/inc/dmapper/resourcemodel.hxx
+++ b/writerfilter/inc/dmapper/resourcemodel.hxx
@@ -347,7 +347,7 @@ public:
 };
 
 /**
-   An SPRM.
+   An SPRM: Section, Paragraph and Run Modifier
 
  */
 class Sprm
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Caolán McNamara
 sd/source/ui/func/futext.cxx |   15 +++
 1 file changed, 15 insertions(+)

New commits:
commit 38a61ddaf63768ebe19c92d561eac6f50d67ded7
Author: Caolán McNamara 
Date:   Mon Sep 19 21:21:58 2016 +0100

Resolves: tdf#102293 triple click results in visually unselected word

in previously unselected textboxes in impress

started happening after...

commit 16c7f8916661df24f4681ec82f6bd4d7ad85d141
Date:   Tue Jan 12 16:36:49 2016 +

tdf#97075 - don't render sdr overlays before we paint

in impress instead flush the overlay after activating the edit object
if we go on to put the cursor in there. Seems to work.

Change-Id: Ib746c36d1074aee09771a3dc1d69834ce80a9c08

diff --git a/sd/source/ui/func/futext.cxx b/sd/source/ui/func/futext.cxx
index 72f6ae2..9b0979b 100644
--- a/sd/source/ui/func/futext.cxx
+++ b/sd/source/ui/func/futext.cxx
@@ -21,6 +21,8 @@
 #include 
 #include 
 #include 
+#include 
+#include 
 #include 
 #include 
 #include 
@@ -1064,6 +1066,19 @@ void FuText::SetInEditMode(const MouseEvent& rMEvt, bool 
bQuickDrag)
 
 if (mpView->SdrBeginTextEdit(pTextObj, pPV, mpWindow, 
true, pOutl) && mxTextObj->GetObjInventor() == SdrInventor)
 {
+//tdf#102293 flush overlay before going on to pass 
clicks down to
+//the outline view which will want to paint selections
+for (sal_uInt32 b = 0; b < pPV->PageWindowCount(); ++b)
+{
+const SdrPageWindow& rPageWindow = 
*pPV->GetPageWindow(b);
+if (!rPageWindow.GetPaintWindow().OutputToWindow())
+continue;
+rtl::Reference< sdr::overlay::OverlayManager > 
xManager = rPageWindow.GetOverlayManager();
+if (!xManager.is())
+continue;
+xManager->flush();
+}
+
 bFirstObjCreated = true;
 DeleteDefaultText();
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


dbg build error on start for missing shared libraries

2016-09-19 Thread Cor Nouws
Hi,

Downloaded and unpacked
http://dev-builds.libreoffice.org/daily/master/Linux-rpm_deb-x86@71-TDF-dbg/current/master_dbg~2016-09-18_23.51.47_LibreOfficeDev_5.3.0.0.alpha0_Linux_x86_archive.tar.gz


& /program/soffice
/home/cono/lotest/TM/LibreOfficeDev_5.3.0.0.alpha0_Linux_x86_archive/program/oosplash:
error while loading shared libraries: libXinerama.so.1: cannot open
shared object file: No such file or directory

Despite the return message, I doubt this is something that I need to fix
with gathering all kind of libraries.. Can someone pls confirm?


-- 
Cor Nouws
GPD key ID: 0xB13480A6 - 591A 30A7 36A0 CE3C 3D28  A038 E49D 7365 B134 80A6
- vrijwilliger http://nl.libreoffice.org
- volunteer http://www.libreoffice.org
- The Document Foundation Membership Committee Member
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: ulsdegyzwkzdepkhzrlh

2016-09-19 Thread zwonibgf
-->> $16283...
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: Branch 'private/jmux/new-vcl-scheduler+kde4' - 35 commits - android/source avmedia/source basctl/source chart2/source cui/source dbaccess/source desktop/qa desktop/sour

2016-09-19 Thread Jan-Marek Glogowski
Rebased ref, commits from common ancestor:
commit be5282827e39dc65b33c785dbd760b0a59df8513
Author: Jan-Marek Glogowski 
Date:   Mon Sep 19 22:47:37 2016 +0200

KDE4 no more progress bar flickering

This will always redraw the progress bar over the last one.
It stops the flickering at least in KDE4 from re-painting the
background, but obvously will break any transparent or alaiasing
effect, if it was used.

There is actually a mbProgressNeedsErase in the global settings,
so actually use it when setting a new progress value.

Change-Id: Ic62784da4f6d08bf0e03a9e04848a5cc687ee236

diff --git a/vcl/source/window/status.cxx b/vcl/source/window/status.cxx
index 0035714..70778b0 100644
--- a/vcl/source/window/status.cxx
+++ b/vcl/source/window/status.cxx
@@ -1352,7 +1352,8 @@ void StatusBar::SetProgressValue( sal_uInt16 nNewPercent )
 &&   IsReallyVisible()
 &&   (!mnPercent || (mnPercent != nNewPercent)) )
 {
-Invalidate(maPrgsFrameRect);
+bool bNeedErase = ImplGetSVData()->maNWFData.mbProgressNeedsErase;
+Invalidate(maPrgsFrameRect, bNeedErase ? InvalidateFlags::NONE : 
InvalidateFlags::NoErase);
 Flush();
 }
 mnPercent = nNewPercent;
commit 5f190ff5b8ab049a35e21d8513c868ebd6bf10f8
Author: Jan-Marek Glogowski 
Date:   Mon Sep 19 22:31:17 2016 +0200

tdf#94172 KDE4 fix gradient toolbars

Bug introduced by commit 4f5fe008a3d5f0b5ddfa656299306cff9d57d802.
The code was moved from ImplInitSettings to ApplySettings and somehow
a not (!) got lost.

Change-Id: Ie3fa4fb99d030d106aab712cd6bdafada8c6d423

diff --git a/vcl/source/window/dockingarea.cxx 
b/vcl/source/window/dockingarea.cxx
index 1806519..a1de6bc 100644
--- a/vcl/source/window/dockingarea.cxx
+++ b/vcl/source/window/dockingarea.cxx
@@ -149,7 +149,7 @@ void DockingAreaWindow::ApplySettings(vcl::RenderContext& 
rRenderContext)
 
 rRenderContext.SetBackground(aWallpaper);
 }
-else if (rRenderContext.IsNativeControlSupported(ControlType::Toolbar, 
ControlPart::Entire))
+else if (!rRenderContext.IsNativeControlSupported(ControlType::Toolbar, 
ControlPart::Entire))
 {
 Wallpaper aWallpaper;
 aWallpaper.SetStyle(WallpaperStyle::ApplicationGradient);
commit e21bbabd7e5cc4422b87847ee89b06f1977c016f
Author: Jan-Marek Glogowski 
Date:   Mon Sep 19 22:24:12 2016 +0200

tdf#94112 KDE4 use disabled WindowText color

Libre office just has a general disabled color. Instead of the
general QPalette::Mid, use the color QPalette::WindowText of
the palette QPalette::Disabled.

Change-Id: Ie6943b455d3e6545289b241ee4ab85128f4fd7ab

diff --git a/vcl/unx/kde4/KDESalFrame.cxx b/vcl/unx/kde4/KDESalFrame.cxx
index 9edeb11..a1086ba 100644
--- a/vcl/unx/kde4/KDESalFrame.cxx
+++ b/vcl/unx/kde4/KDESalFrame.cxx
@@ -243,7 +243,7 @@ void KDESalFrame::UpdateSettings( AllSettings& rSettings )
 style.SetTabHighlightTextColor( aButn );
 
 // Disable color
-style.SetDisableColor( aMid );
+style.SetDisableColor( toColor( pal.color( QPalette::Disabled, 
QPalette::WindowText ) ) );
 
 // Workspace
 style.SetWorkspaceColor( aMid );
commit 3a6d4d136246352239f26696852560b42160fb68
Author: Jan-Marek Glogowski 
Date:   Wed Oct 29 15:54:29 2014 +0100

KDE4: Switch default image color to transparent...

and just fill the painted image once at the beginning.

Also adapt background based on the control information from Qt4.

Change-Id: I39c03b2ca779381920e2597b4bea7973fea6ae2a

diff --git a/vcl/unx/kde4/KDESalGraphics.cxx b/vcl/unx/kde4/KDESalGraphics.cxx
index 76f8a58..9cdd627 100644
--- a/vcl/unx/kde4/KDESalGraphics.cxx
+++ b/vcl/unx/kde4/KDESalGraphics.cxx
@@ -220,13 +220,46 @@ bool KDESalGraphics::drawNativeControl( ControlType type, 
ControlPart part,
 {
 m_image.reset(new QImage( widgetRect.width(), widgetRect.height(), 
QImage::Format_ARGB32 ) );
 }
-m_image->fill(KApplication::palette().color(QPalette::Window).rgb());
+
+// Default image color - just once
+switch (type)
+{
+case ControlType::MenuPopup:
+if( part == ControlPart::MenuItemCheckMark || part == 
ControlPart::MenuItemRadioMark )
+{
+// it is necessary to fill the background transparently first, 
as this
+// is painted after menuitem highlight, otherwise there would 
be a grey area
+m_image->fill( Qt::transparent );
+break;
+}
+SAL_FALLTHROUGH; // QPalette::Window
+case ControlType::Menubar:
+case ControlType::WindowBackground:
+m_image->fill( 
KApplication::palette().color(QPalette::Window).rgb() );
+break;
+case ControlType::Tooltip:
+
m_image->fill(KApplication::palette().color(QPalette::ToolTipBase).rgb());
+break;
+case ControlType::Pushbutton:
+
m_image->fil

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

2016-09-19 Thread Tomaž Vajngerl
 vcl/inc/opengl/watchdog.hxx|   36 
 vcl/inc/opengl/zone.hxx|1 
 vcl/source/opengl/OpenGLHelper.cxx |   55 -
 3 files changed, 79 insertions(+), 13 deletions(-)

New commits:
commit e5c3c69423c0f32bf4bee147936e58ba4d3be181
Author: Tomaž Vajngerl 
Date:   Mon Sep 19 18:03:47 2016 +0200

tdf#102295: relax timeout timings for the GL watchdog

Some OS/GPU combinations need more relaxed watchdog timeout timings
as the shader compilation takes too long to complete.

Change-Id: Ifd9ff7ecfa4b004d5411d6d364dd01a389a3fcec

diff --git a/vcl/inc/opengl/watchdog.hxx b/vcl/inc/opengl/watchdog.hxx
index 0213efb..ced3cf2 100644
--- a/vcl/inc/opengl/watchdog.hxx
+++ b/vcl/inc/opengl/watchdog.hxx
@@ -14,6 +14,42 @@
 #include 
 #include 
 #include 
+#include 
+
+struct WatchdogTimings
+{
+osl::Mutex maMutex;
+
+int mnMode;
+
+/// delays to take various actions in 1/4 of a second increments.
+std::vector maDisableEntries;
+std::vector maAbortAfter;
+
+WatchdogTimings();
+
+void relax();
+
+int getMode()
+{
+return mnMode;
+}
+
+void setMode(int nMode)
+{
+mnMode = nMode;
+}
+
+int getDisableEntries()
+{
+   return maDisableEntries[mnMode];
+}
+
+int getAbortAfter()
+{
+return maAbortAfter[mnMode];
+}
+};
 
 class OpenGLWatchdogThread : private salhelper::Thread
 {
diff --git a/vcl/inc/opengl/zone.hxx b/vcl/inc/opengl/zone.hxx
index 11f6ed0..65a7249 100644
--- a/vcl/inc/opengl/zone.hxx
+++ b/vcl/inc/opengl/zone.hxx
@@ -38,6 +38,7 @@ public:
 ~OpenGLZone() { gnLeaveCount++; }
 static bool isInZone() { return gnEnterCount != gnLeaveCount; }
 static void hardDisable();
+static void relaxWatchdogTimings();
 };
 
 /// Create this to not only enter the zone, but set VCL context.
diff --git a/vcl/source/opengl/OpenGLHelper.cxx 
b/vcl/source/opengl/OpenGLHelper.cxx
index f713cf8..fa1c532 100644
--- a/vcl/source/opengl/OpenGLHelper.cxx
+++ b/vcl/source/opengl/OpenGLHelper.cxx
@@ -780,6 +780,13 @@ bool OpenGLHelper::isDeviceBlacklisted()
 #elif defined( _WIN32 )
 WinOpenGLDeviceInfo aInfo;
 bBlacklisted = aInfo.isDeviceBlocked();
+
+if (aInfo.GetWindowsVersion() == 0x00060001 && /* Windows 7 */
+aInfo.GetAdapterVendorID() == "0x1022")/* AMD */
+{
+SAL_INFO("vcl.opengl", "Relaxing watchdog timings.");
+OpenGLZone::relaxWatchdogTimings();
+}
 #else
 bBlacklisted = false;
 #endif
@@ -806,9 +813,27 @@ void OpenGLZone::leave() { gnLeaveCount++; }
 namespace {
 static volatile bool gbWatchdogFiring = false;
 static oslCondition gpWatchdogExit = nullptr;
+static WatchdogTimings gWatchdogTimings;
 static rtl::Reference gxWatchdog;
 }
 
+WatchdogTimings::WatchdogTimings()
+: mnMode(0)
+, maDisableEntries({ 6 /* 1.5s */,  20 /* 5s */ })
+, maAbortAfter({ 20 /* 5s */, 120 /* 30s */ })
+{}
+
+void WatchdogTimings::relax()
+{
+osl::MutexGuard g(maMutex);
+
+maDisableEntries[0] = 180; /* 45s */
+maDisableEntries[1] = 180; /* 45s */
+
+maAbortAfter[0] = 240; /* 60s */
+maAbortAfter[1] = 240; /* 60s */
+}
+
 OpenGLWatchdogThread::OpenGLWatchdogThread()
 : salhelper::Thread("OpenGL Watchdog")
 {
@@ -816,25 +841,24 @@ OpenGLWatchdogThread::OpenGLWatchdogThread()
 
 void OpenGLWatchdogThread::execute()
 {
-// delays to take various actions in 1/4 of a second increments.
-static const int nDisableEntries[2] = { 6 /* 1.5s */, 20 /* 5s */ };
-static const int nAbortAfter[2] = { 20 /* 10s */, 120 /* 30s */ };
-
 int nUnchanged = 0; // how many unchanged nEnters
-TimeValue aHalfSecond(0, 1000*1000*1000*0.25);
+TimeValue aQuarterSecond(0, 1000*1000*1000*0.25);
 bool bAbortFired = false;
 
 do {
 sal_uInt64 nLastEnters = OpenGLZone::gnEnterCount;
 
-osl_waitCondition(gpWatchdogExit, &aHalfSecond);
+osl_waitCondition(gpWatchdogExit, &aQuarterSecond);
 
 if (OpenGLZone::isInZone())
 {
-int nType = 0;
+osl::MutexGuard g(gWatchdogTimings.maMutex);
+
 // The shader compiler can take a long time, first time.
 if (gbInShaderCompile)
-nType = 1;
+gWatchdogTimings.setMode(1);
+else
+gWatchdogTimings.setMode(0);
 
 if (nLastEnters == OpenGLZone::gnEnterCount)
 nUnchanged++;
@@ -843,12 +867,12 @@ void OpenGLWatchdogThread::execute()
 SAL_INFO("vcl.opengl", "GL watchdog - unchanged " <<
  nUnchanged << " enter count " <<
  OpenGLZone::gnEnterCount << " type " <<
- (nType ? "in shader" : "normal gl") <<
- "breakpoints mid: " << nDisableEntries[nType] <<
- " max " << nAbortAfter[nType]);
+   

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

2016-09-19 Thread Markus Mohrhard
 sc/source/filter/excel/xecontent.cxx |   12 
 1 file changed, 12 insertions(+)

New commits:
commit 11370a0ce5a8ca503927cff38d79b38e513123fe
Author: Markus Mohrhard 
Date:   Mon Sep 19 23:20:22 2016 +0200

try to generate more excel compliant files, tdf#41722

§18.3.1.10 says for the operator attribute: "The operator in a "cell
value is" conditional formatting rule. This attribute is ignored if
type is not equal to cellIs"

but checking §18.18.15 there are at least 4 attribute values that are
not related to cellIs. I have added them now but need to test that this
really helps.

Change-Id: Id15efc7e0148b4e3b54404d1ffd911adc56b11ec

diff --git a/sc/source/filter/excel/xecontent.cxx 
b/sc/source/filter/excel/xecontent.cxx
index 86a19f7..cfa6c5a 100644
--- a/sc/source/filter/excel/xecontent.cxx
+++ b/sc/source/filter/excel/xecontent.cxx
@@ -836,6 +836,18 @@ const char* GetOperatorString(ScConditionMode eMode, bool& 
bFrmla2)
 case SC_COND_NOTDUPLICATE:
 pRet = nullptr;
 break;
+case SC_COND_BEGINS_WITH:
+pRet = "beginsWith";
+break;
+case SC_COND_ENDS_WITH:
+pRet = "endsWith";
+break;
+case SC_COND_CONTAINS_TEXT:
+pRet = "containsText";
+break;
+case SC_COND_NOT_CONTAINS_TEXT:
+pRet = "notContains";
+break;
 case SC_COND_DIRECT:
 break;
 case SC_COND_NONE:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'feature/fixes36' - vcl/inc vcl/source

2016-09-19 Thread Jan Holesovsky
 vcl/inc/opengl/watchdog.hxx|1 +
 vcl/source/opengl/OpenGLHelper.cxx |   10 +++---
 2 files changed, 4 insertions(+), 7 deletions(-)

New commits:
commit 86adf461d56dc46056c4fdf31d77d4b509076ca4
Author: Jan Holesovsky 
Date:   Tue Sep 20 00:16:10 2016 +0200

tdf#102295: relax timeout timings for the GL watchdog

Some OS/GPU combinations need more relaxed watchdog timeout timings
as the shader compilation takes too long to complete.

Change-Id: Ifd9ff7ecfa4b004d5411d6d364dd01a389a3fcec
(cherry picked from commit e5c3c69423c0f32bf4bee147936e58ba4d3be181)

diff --git a/vcl/inc/opengl/watchdog.hxx b/vcl/inc/opengl/watchdog.hxx
index ce97064..ced3cf2 100644
--- a/vcl/inc/opengl/watchdog.hxx
+++ b/vcl/inc/opengl/watchdog.hxx
@@ -22,6 +22,7 @@ struct WatchdogTimings
 
 int mnMode;
 
+/// delays to take various actions in 1/4 of a second increments.
 std::vector maDisableEntries;
 std::vector maAbortAfter;
 
diff --git a/vcl/source/opengl/OpenGLHelper.cxx 
b/vcl/source/opengl/OpenGLHelper.cxx
index 38317e5..f36b4da 100644
--- a/vcl/source/opengl/OpenGLHelper.cxx
+++ b/vcl/source/opengl/OpenGLHelper.cxx
@@ -827,10 +827,10 @@ void WatchdogTimings::relax()
 {
 osl::MutexGuard g(maMutex);
 
-maDisableEntries[0] = 20; /*  5s */
-maDisableEntries[1] = 60; /* 15s */
+maDisableEntries[0] = 180; /* 45s */
+maDisableEntries[1] = 180; /* 45s */
 
-maAbortAfter[0] = 40;  /* 10s */
+maAbortAfter[0] = 240; /* 60s */
 maAbortAfter[1] = 240; /* 60s */
 }
 
@@ -841,10 +841,6 @@ OpenGLWatchdogThread::OpenGLWatchdogThread()
 
 void OpenGLWatchdogThread::execute()
 {
-// delays to take various actions in 1/4 of a second increments.
-static const int nDisableEntries[2] = { 6 /* 1.5s */, 20 /* 5s */ };
-static const int nAbortAfter[2] = { 20 /* 10s */, 120 /* 30s */ };
-
 int nUnchanged = 0; // how many unchanged nEnters
 TimeValue aQuarterSecond(0, 1000*1000*1000*0.25);
 bool bAbortFired = false;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/loolwsd.xml.in

2016-09-19 Thread Ashod Nakashian
 loolwsd/loolwsd.xml.in |   10 ++
 1 file changed, 10 insertions(+)

New commits:
commit 6f7115ebc6302abed9c50d89679d786f50ad3575
Author: Ashod Nakashian 
Date:   Mon Sep 19 20:52:05 2016 -0400

loolwsd: added config for logging to file

Change-Id: Ib4942af2e9875018fbb27e1666912ca8f8b4e901
Reviewed-on: https://gerrit.libreoffice.org/29058
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/loolwsd.xml.in b/loolwsd/loolwsd.xml.in
index 6ddba26..56de388 100644
--- a/loolwsd/loolwsd.xml.in
+++ b/loolwsd/loolwsd.xml.in
@@ -21,6 +21,16 @@
 
 true
 trace
+
+loolwsd.log
+never
+timestamp
+true
+10 days
+10
+true
+false
+
 
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/DocumentBroker.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/DocumentBroker.cpp |   15 ++-
 1 file changed, 10 insertions(+), 5 deletions(-)

New commits:
commit b0f20ea35f604494df28ad6b2e2b377b60185f52
Author: Ashod Nakashian 
Date:   Mon Sep 19 19:18:07 2016 -0400

loolwsd: proper tracing of outgoing tile messages

Change-Id: I875743cac144bd4bc357038aa58c9cfe7a3988aa
Reviewed-on: https://gerrit.libreoffice.org/29059
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/DocumentBroker.cpp b/loolwsd/DocumentBroker.cpp
index 182a72c..cd4639f 100644
--- a/loolwsd/DocumentBroker.cpp
+++ b/loolwsd/DocumentBroker.cpp
@@ -472,19 +472,24 @@ size_t DocumentBroker::removeSession(const std::string& 
id)
 
 bool DocumentBroker::handleInput(const std::vector& payload)
 {
-Log::trace("DocumentBroker got child message: [" + 
LOOLProtocol::getAbbreviatedMessage(payload) + "].");
+const auto msg = LOOLProtocol::getAbbreviatedMessage(payload);
+Log::trace("DocumentBroker got child message: [" + msg + "].");
 
-const auto command = LOOLProtocol::getFirstToken(payload);
-LOOLWSD::dumpOutgoingTrace(getJailId(), "0", command);
+LOOLWSD::dumpOutgoingTrace(getJailId(), "0", msg);
 
-if (command == "tile:")
+if (msg.find("tile:") == 0)
 {
 handleTileResponse(payload);
 }
-else if (command == "tilecombine:")
+else if (msg.find("tilecombine:") == 0)
 {
handleTileCombinedResponse(payload);
 }
+else
+{
+Log::error("Unexpected message: [" + msg + "].");
+return false;
+}
 
 return true;
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/loolwsd.xml.in loolwsd/TraceFile.hpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/TraceFile.hpp  |7 +++
 loolwsd/loolwsd.xml.in |2 +-
 2 files changed, 8 insertions(+), 1 deletion(-)

New commits:
commit 74f796d91ab2871ad8da9025a59a8449dc4375fb
Author: Ashod Nakashian 
Date:   Mon Sep 19 18:48:30 2016 -0400

loolwsd: flush trace file on events

This reduces chances of data loss and gives
more up-to-date data to the user.

Also include tile messages in the trace recording,
since they are useful for debugging. Should be
disabled to reduce excessive trace generation.

Change-Id: I223144660698843f4e94564e049883db898c0064
Reviewed-on: https://gerrit.libreoffice.org/29060
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/TraceFile.hpp b/loolwsd/TraceFile.hpp
index 576121f..8c32d47 100644
--- a/loolwsd/TraceFile.hpp
+++ b/loolwsd/TraceFile.hpp
@@ -71,6 +71,7 @@ public:
 void writeEvent(const std::string& pId, const std::string& sessionId, 
const std::string& data)
 {
 write(pId, sessionId, data, 
static_cast(TraceFileRecord::Direction::Event));
+flush();
 }
 
 void writeIncoming(const std::string& pId, const std::string& sessionId, 
const std::string& data)
@@ -89,6 +90,12 @@ public:
 }
 }
 
+void flush()
+{
+_deflater.flush();
+_stream.flush();
+}
+
 private:
 void write(const std::string& pId, const std::string& sessionId, const 
std::string& data, const char delim)
 {
diff --git a/loolwsd/loolwsd.xml.in b/loolwsd/loolwsd.xml.in
index 56de388..20b1dd7 100644
--- a/loolwsd/loolwsd.xml.in
+++ b/loolwsd/loolwsd.xml.in
@@ -36,7 +36,7 @@
 
 /tmp/looltrace.gz
 
-tile.*
+
 
 
 false
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/LOOLKit.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/LOOLKit.cpp |   39 ++-
 1 file changed, 18 insertions(+), 21 deletions(-)

New commits:
commit bad8ae9ed99879dbdac6cb37d425c922ba047d5b
Author: Ashod Nakashian 
Date:   Sat Sep 17 09:18:33 2016 -0400

loolwsd: one anonymous namespace per file is enough

Change-Id: I12b4967a321de45fc50ad314775d01499b5edd80
Reviewed-on: https://gerrit.libreoffice.org/29061
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index d5d3fc9..252cfb3 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -231,6 +231,24 @@ namespace
 cap_free(caps);
 }
 
+void symlinkPathToJail(const Path& jailPath, const std::string &loTemplate,
+   const std::string &loSubPath)
+{
+Path symlinkSource(jailPath, Path(loTemplate.substr(1)));
+File(symlinkSource.parent()).createDirectories();
+
+std::string symlinkTarget;
+for (auto i = 0; i < Path(loTemplate).depth(); i++)
+symlinkTarget += "../";
+symlinkTarget += loSubPath;
+
+Log::debug("symlink(\"" + symlinkTarget + "\",\"" + 
symlinkSource.toString() + "\")");
+if (symlink(symlinkTarget.c_str(), symlinkSource.toString().c_str()) 
== -1)
+{
+Log::syserror("symlink(\"" + symlinkTarget + "\",\"" + 
symlinkSource.toString() + "\") failed");
+throw Exception("symlink() failed");
+}
+}
 }
 
 /// Connection thread with a client (via WSD).
@@ -1292,27 +1310,6 @@ private:
 std::atomic_size_t _clientViews;
 };
 
-namespace {
-void symlinkPathToJail(const Path& jailPath, const std::string &loTemplate,
-   const std::string &loSubPath)
-{
-Path symlinkSource(jailPath, Path(loTemplate.substr(1)));
-File(symlinkSource.parent()).createDirectories();
-
-std::string symlinkTarget;
-for (auto i = 0; i < Path(loTemplate).depth(); i++)
-symlinkTarget += "../";
-symlinkTarget += loSubPath;
-
-Log::debug("symlink(\"" + symlinkTarget + "\",\"" + 
symlinkSource.toString() + "\")");
-if (symlink(symlinkTarget.c_str(), symlinkSource.toString().c_str()) 
== -1)
-{
-Log::syserror("symlink(\"" + symlinkTarget + "\",\"" + 
symlinkSource.toString() + "\") failed");
-throw Exception("symlink() failed");
-}
-}
-}
-
 void lokit_main(const std::string& childRoot,
 const std::string& sysTemplate,
 const std::string& loTemplate,
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/Connect.cpp loolwsd/LOOLWSD.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/Connect.cpp |4 +++-
 loolwsd/LOOLWSD.cpp |2 +-
 2 files changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 53ba8a130785778603db65d454e4f7ea158588f5
Author: Ashod Nakashian 
Date:   Sat Sep 17 09:48:39 2016 -0400

loolwsd: use std sleep_for rather than POSIX or Poco

Change-Id: Icce28f2ee61035534431bb8b5d7df93b00ad2fc3
Reviewed-on: https://gerrit.libreoffice.org/29062
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/Connect.cpp b/loolwsd/Connect.cpp
index 5b10efa..eb91903 100644
--- a/loolwsd/Connect.cpp
+++ b/loolwsd/Connect.cpp
@@ -14,6 +14,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -200,7 +201,8 @@ protected:
 std::unique_lock lock(coutMutex);
 std::cout << "Sleeping " << sleepTime << " seconds" << 
std::endl;
 }
-Thread::sleep(sleepTime * 1000);
+
+std::this_thread::sleep_for(std::chrono::seconds(sleepTime));
 }
 else if (line == "exit")
 {
diff --git a/loolwsd/LOOLWSD.cpp b/loolwsd/LOOLWSD.cpp
index b496a1b..9f1d6d7 100644
--- a/loolwsd/LOOLWSD.cpp
+++ b/loolwsd/LOOLWSD.cpp
@@ -1923,7 +1923,7 @@ int LOOLWSD::main(const std::vector& 
/*args*/)
 }
 }
 
-sleep(WSD_SLEEP_SECS);
+std::this_thread::sleep_for(std::chrono::seconds(WSD_SLEEP_SECS));
 
 // Make sure we have sufficient reserves.
 prespawnChildren();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/LOOLKit.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/LOOLKit.cpp |   25 ++---
 1 file changed, 22 insertions(+), 3 deletions(-)

New commits:
commit 23ef612970ff5e90ffc8da63f503170aef9a56be
Author: Ashod Nakashian 
Date:   Sat Sep 17 10:04:28 2016 -0400

loolwsd: ensure that the connection thread is running

If the connection thread is not running when loading a
document, the callback will drop events. This can happen
when the thread is too slow to spawn, but we return from
the createSession function and process client messages.

This should solve the race where we lose notifications of
other views when a new view is created.

Change-Id: Ia79739889b2f01fbb374d48eb33620084f4ed1c1
Reviewed-on: https://gerrit.libreoffice.org/29063
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index 252cfb3..51c33f3 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -28,6 +28,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #define LOK_USE_UNSTABLE_API
 #include 
@@ -279,6 +280,16 @@ public:
 void start()
 {
 _thread.start(*this);
+
+// Busy-wait until we run.
+// This is important to make sure we can process
+// callbacks, which if we're late to start will
+// be dropped. No need for async notification here.
+constexpr auto delay = COMMAND_TIMEOUT_MS / 20;
+for (auto i = 0; i < 20 && !isRunning(); ++i)
+{
+std::this_thread::sleep_for(std::chrono::milliseconds(delay));
+}
 }
 
 bool isRunning()
@@ -871,15 +882,23 @@ private:
 bool isFound = false;
 for (auto& it : pDescr->Doc->_connections)
 {
-if (it.second->isRunning())
+auto session = it.second->getSession();
+if (session && session->getViewId() == pDescr->ViewId)
 {
-auto session = it.second->getSession();
-if (session && session->getViewId() == pDescr->ViewId)
+if (it.second->isRunning())
 {
 isFound = true;
 auto pNotif = new CallbackNotification(session, nType, 
payload);
 pDescr->Doc->_callbackQueue.enqueueNotification(pNotif);
 }
+else
+{
+Log::error() << "Connection thread for session " << 
it.second->getSessionId() << " for view "
+ << pDescr->ViewId << " is not running. 
Dropping [" << LOKitHelper::kitCallbackTypeToString(nType)
+ << "] payload [" << payload << "]." << 
Log::end;
+}
+
+break;
 }
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/DocumentBroker.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/DocumentBroker.cpp |   29 +
 1 file changed, 5 insertions(+), 24 deletions(-)

New commits:
commit 7a8248875dcf6627e302b918c105438673ed0112
Author: Ashod Nakashian 
Date:   Fri Sep 2 07:29:59 2016 -0400

loolwsd: don't combine tiles by row to allow for better culling

Reviewed-on: https://gerrit.libreoffice.org/28615
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 
(cherry picked from commit 99d0ee2ac111e7199626f6c17fb7ce723dac9126)

Change-Id: Ibfe6b7430cbdf78bc13b42d19789ce23226a5a5a
Reviewed-on: https://gerrit.libreoffice.org/29064
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/DocumentBroker.cpp b/loolwsd/DocumentBroker.cpp
index cd4639f..709c2a0 100644
--- a/loolwsd/DocumentBroker.cpp
+++ b/loolwsd/DocumentBroker.cpp
@@ -549,8 +549,7 @@ void 
DocumentBroker::handleTileCombinedRequest(TileCombined& tileCombined,
 Log::trace() << "TileCombined request for " << tileCombined.serialize() << 
Log::end;
 
 // Satisfy as many tiles from the cache.
-// The rest, group by rows.
-std::map> rows;
+std::vector tiles;
 for (auto& tile : tileCombined.getTiles())
 {
 std::unique_ptr cachedTile = 
_tileCache->lookupTile(tile);
@@ -604,34 +603,16 @@ void 
DocumentBroker::handleTileCombinedRequest(TileCombined& tileCombined,
 }
 }
 
-const auto tilePosY = tile.getTilePosY();
-auto it = rows.lower_bound(tilePosY);
-if (it != rows.end())
-{
-it->second.emplace_back(tile);
-}
-else
-{
-rows.emplace_hint(it, tilePosY, std::vector({ tile }));
-}
+tiles.push_back(tile);
 }
 
-if (rows.empty())
+for (auto& tile : tiles)
 {
-// Done.
-return;
-}
-
-auto& tiles = tileCombined.getTiles();
-for (auto& row : rows)
-{
-tiles = row.second;
-const auto tileMsg = tileCombined.serialize();
+const auto tileMsg = tile.serialize("tile ");
 Log::debug() << "TileCombined residual request for " << tileMsg << 
Log::end;
 
 // Forward to child to render.
-const std::string request = "tilecombine " + tileMsg;
-_childProcess->getWebSocket()->sendFrame(request.data(), 
request.size());
+_childProcess->getWebSocket()->sendFrame(tileMsg.data(), 
tileMsg.size());
 }
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/DocumentBroker.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/DocumentBroker.cpp |   24 ++--
 1 file changed, 2 insertions(+), 22 deletions(-)

New commits:
commit 1255cc11d894685362249d48063f000e75adc0d3
Author: Ashod Nakashian 
Date:   Mon Sep 19 20:29:40 2016 -0400

loolwsd: version each tile and simplify tilecombine request handling

Change-Id: I369b05a747182cb387141d09ecb5098e1dd16901
Reviewed-on: https://gerrit.libreoffice.org/29065
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/DocumentBroker.cpp b/loolwsd/DocumentBroker.cpp
index 709c2a0..1e58e76 100644
--- a/loolwsd/DocumentBroker.cpp
+++ b/loolwsd/DocumentBroker.cpp
@@ -545,11 +545,9 @@ void 
DocumentBroker::handleTileCombinedRequest(TileCombined& tileCombined,
 {
 std::unique_lock lock(_mutex);
 
-tileCombined.setVersion(++_tileVersion);
 Log::trace() << "TileCombined request for " << tileCombined.serialize() << 
Log::end;
 
 // Satisfy as many tiles from the cache.
-std::vector tiles;
 for (auto& tile : tileCombined.getTiles())
 {
 std::unique_ptr cachedTile = 
_tileCache->lookupTile(tile);
@@ -577,12 +575,11 @@ void 
DocumentBroker::handleTileCombinedRequest(TileCombined& tileCombined,
 cachedTile->close();
 
 session->sendBinaryFrame(output.data(), output.size());
-continue;
 }
 else
 {
 // Not cached, needs rendering.
-tile.setVersion(_tileVersion);
+tile.setVersion(++_tileVersion);
 const auto ver = tileCache().subscribeToTileRendering(tile, 
session);
 if (ver <= 0)
 {
@@ -590,29 +587,12 @@ void 
DocumentBroker::handleTileCombinedRequest(TileCombined& tileCombined,
 continue;
 }
 else
-if (tile.intersectsWithRect(_cursorPosX, _cursorPosY,
-_cursorWidth, _cursorHeight))
 {
-// If this tile is right under the cursor, give it priority.
 const auto req = tile.serialize("tile");
-Log::debug() << "Priority tile request: " << req << Log::end;
+Log::debug() << "Tile request: " << req << Log::end;
 _childProcess->getWebSocket()->sendFrame(req.data(), 
req.size());
-
-// No need to process with the group anymore.
-continue;
 }
 }
-
-tiles.push_back(tile);
-}
-
-for (auto& tile : tiles)
-{
-const auto tileMsg = tile.serialize("tile ");
-Log::debug() << "TileCombined residual request for " << tileMsg << 
Log::end;
-
-// Forward to child to render.
-_childProcess->getWebSocket()->sendFrame(tileMsg.data(), 
tileMsg.size());
 }
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/ClientSession.cpp loolwsd/ClientSession.hpp loolwsd/DocumentBroker.cpp loolwsd/LOOLWSD.cpp loolwsd/test loolwsd/TileCache.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/ClientSession.cpp  |2 --
 loolwsd/ClientSession.hpp  |9 -
 loolwsd/DocumentBroker.cpp |6 --
 loolwsd/LOOLWSD.cpp|   28 ++--
 loolwsd/TileCache.cpp  |   27 ---
 loolwsd/test/Makefile.am   |1 +
 6 files changed, 31 insertions(+), 42 deletions(-)

New commits:
commit e7272019dc28da7b66a7db145bda9a9c3db1380c
Author: Ashod Nakashian 
Date:   Wed Aug 31 23:34:41 2016 -0400

loolwsd: remove tile queue and simplify tile response

Tile queue was used to process canceltiles commands.
Since those are handled by TileCache, there is no need
for queues and the threads that pump them.

But because these queues were also used to buffer between
WSD internals and clients, such that a slow client wouldn't
block WSD while sending back tiles, it is necessary
to reword that logic.
In subsequent commits that will change as well.

With this change not only do we save a thread per client,
but we also reduce latency of tile, and improve typing
responsiveness, by almost 3x or more! Latencies are
down to ~15ms from almost 50ms.

Reviewed-on: https://gerrit.libreoffice.org/28575
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 
(cherry picked from commit 59eaacd2f87f46c4c4d2963ef54f4d20d346b2d0)

Change-Id: I77813267a95a724491165792ec020ae00953c05e
Reviewed-on: https://gerrit.libreoffice.org/29066
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/ClientSession.cpp b/loolwsd/ClientSession.cpp
index 533844f..b493c58 100644
--- a/loolwsd/ClientSession.cpp
+++ b/loolwsd/ClientSession.cpp
@@ -37,11 +37,9 @@ using Poco::StringTokenizer;
 ClientSession::ClientSession(const std::string& id,
  std::shared_ptr ws,
  std::shared_ptr docBroker,
- std::shared_ptr queue,
  bool readOnly) :
 LOOLSession(id, Kind::ToClient, ws),
 _docBroker(std::move(docBroker)),
-_queue(std::move(queue)),
 _isReadOnly(readOnly),
 _loadFailed(false),
 _loadPart(-1)
diff --git a/loolwsd/ClientSession.hpp b/loolwsd/ClientSession.hpp
index e6f3098..a285efe 100644
--- a/loolwsd/ClientSession.hpp
+++ b/loolwsd/ClientSession.hpp
@@ -23,7 +23,6 @@ public:
 ClientSession(const std::string& id,
   std::shared_ptr ws,
   std::shared_ptr docBroker,
-  std::shared_ptr queue,
   bool isReadOnly = false);
 
 virtual ~ClientSession();
@@ -58,11 +57,6 @@ public:
 _loadFailed = true;
 }
 
-void sendToInputQueue(const std::string& message)
-{
-_queue->put(message);
-}
-
 std::shared_ptr getDocumentBroker() const { return 
_docBroker; }
 
 private:
@@ -83,9 +77,6 @@ private:
 
 std::shared_ptr _docBroker;
 
-/// The incoming message queue.
-std::shared_ptr _queue;
-
 // Whether the session is opened as readonly
 bool _isReadOnly;
 
diff --git a/loolwsd/DocumentBroker.cpp b/loolwsd/DocumentBroker.cpp
index 1e58e76..78cc9e7 100644
--- a/loolwsd/DocumentBroker.cpp
+++ b/loolwsd/DocumentBroker.cpp
@@ -364,8 +364,10 @@ bool DocumentBroker::sendUnoSave(const bool 
dontSaveIfUnmodified)
 // arguments end
 oss << "}";
 
-Log::debug(".uno:Save arguments: " + oss.str());
-sessionIt.second->sendToInputQueue("uno .uno:Save " + oss.str());
+const auto saveArgs = oss.str();
+Log::trace(".uno:Save arguments: " + saveArgs);
+const auto command = "uno .uno:Save " + saveArgs;
+sessionIt.second->handleInput(command.data(), command.size());
 return true;
 }
 
diff --git a/loolwsd/LOOLWSD.cpp b/loolwsd/LOOLWSD.cpp
index 9f1d6d7..266ac7c 100644
--- a/loolwsd/LOOLWSD.cpp
+++ b/loolwsd/LOOLWSD.cpp
@@ -399,7 +399,7 @@ private:
 
 // Load the document.
 std::shared_ptr ws;
-auto session = std::make_shared(id, ws, 
docBroker, nullptr);
+auto session = std::make_shared(id, ws, 
docBroker);
 
 // Request the child to connect to us and add this session.
 auto sessionsCount = docBroker->addSession(session);
@@ -686,10 +686,7 @@ private:
 std::shared_ptr session;
 try
 {
-// For ToClient sessions, we store incoming messages in a queue 
and have a separate
-// thread to pump them. This is to empty the queue when we get a 
"canceltiles" message.
-auto queue = std::make_shared();
-session = std::make_shared(id, ws, docBroker, 
queue, isReadOnly);
+session = std::make_shared(id, ws, docBroker, 
isReadOnly);
 if (!fileinfo._userName.empty())
 {
 Log::debug(uriPublic.toString() + " requested with username [" 
+ file

[Libreoffice-commits] online.git: loolwsd/LOOLKit.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/LOOLKit.cpp |   28 +++-
 1 file changed, 11 insertions(+), 17 deletions(-)

New commits:
commit a9fbfe8d8ac802086844e307dff979a8e1436ba2
Author: Ashod Nakashian 
Date:   Sat Sep 17 10:09:47 2016 -0400

loolwsd: remove queue thread from child socket handler

Change-Id: Ib6b4890db1f331b2e2cdcfafb57366ff62e3a13d
Reviewed-on: https://gerrit.libreoffice.org/29067
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index 51c33f3..02919e6 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -57,7 +57,6 @@
 #include "LibreOfficeKit.hpp"
 #include "Log.hpp"
 #include "Png.hpp"
-#include "QueueHandler.hpp"
 #include "Rectangle.hpp"
 #include "TileDesc.hpp"
 #include "Unit.hpp"
@@ -320,27 +319,21 @@ public:
 Log::debug("Thread started.");
 try
 {
-auto queue = std::make_shared();
-QueueHandler handler(queue, _session, "kit_queue_" + 
_session->getId());
-
-Thread queueHandlerThread;
-queueHandlerThread.start(handler);
-std::shared_ptr session = _session;
-
 IoUtil::SocketProcessor(_ws,
-[&queue](const std::vector& payload)
+[this](const std::vector& payload)
 {
-queue->put(payload);
+if (!_session->handleInput(payload.data(), payload.size()))
+{
+Log::info("Socket handler flagged for finishing.");
+return false;
+}
+
 return true;
 },
-[&session]() { session->closeFrame(); },
-[&queueHandlerThread]() { return TerminationFlag || 
!queueHandlerThread.isRunning(); });
-
-queue->clear();
-queue->put("eof");
-queueHandlerThread.join();
+[this]() { _session->closeFrame(); },
+[]() { return !!TerminationFlag; });
 
-if (session->isCloseFrame())
+if (_session->isCloseFrame())
 {
 Log::trace("Normal close handshake.");
 _ws->shutdown();
@@ -1503,6 +1496,7 @@ void lokit_main(const std::string& childRoot,
 requestUrl += "&version=" + encodedVersionStr;
 free(versionInfo);
 }
+
 HTTPRequest request(HTTPRequest::HTTP_GET, requestUrl);
 HTTPResponse response;
 auto ws = std::make_shared(cs, request, response);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/DocumentBroker.cpp loolwsd/test loolwsd/TileCache.cpp loolwsd/TileCache.hpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/DocumentBroker.cpp  |8 ++--
 loolwsd/TileCache.cpp   |   14 +-
 loolwsd/TileCache.hpp   |2 +-
 loolwsd/test/TileCacheTests.cpp |2 +-
 4 files changed, 9 insertions(+), 17 deletions(-)

New commits:
commit ec4b4898859f2849ba7888b04dc688f804cb6975
Author: Ashod Nakashian 
Date:   Mon Sep 19 20:21:18 2016 -0400

loolwsd: remove unused priority flag from saveTileAndNotify

Change-Id: I49309bb80a6b9e9e8265da8f8db966b98e362f0a
Reviewed-on: https://gerrit.libreoffice.org/29068
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/DocumentBroker.cpp b/loolwsd/DocumentBroker.cpp
index 78cc9e7..5ef3f60 100644
--- a/loolwsd/DocumentBroker.cpp
+++ b/loolwsd/DocumentBroker.cpp
@@ -609,13 +609,9 @@ void DocumentBroker::handleTileResponse(const 
std::vector& payload)
 
 if (firstLine.size() < static_cast(length) - 1)
 {
-// If the tile right under the cursor, give it priority.
-const bool priority = tile.intersectsWithRect(
-_cursorPosX, _cursorPosY,
-_cursorWidth, _cursorHeight);
 tileCache().saveTileAndNotify(
 tile, buffer + firstLine.size() + 1,
-length - firstLine.size() - 1, priority);
+length - firstLine.size() - 1);
 }
 else
 {
@@ -648,7 +644,7 @@ void DocumentBroker::handleTileCombinedResponse(const 
std::vector& payload
 {
 for (const auto& tile : tileCombined.getTiles())
 {
-tileCache().saveTileAndNotify(tile, buffer + offset, 
tile.getImgSize(), false);
+tileCache().saveTileAndNotify(tile, buffer + offset, 
tile.getImgSize());
 offset += tile.getImgSize();
 }
 }
diff --git a/loolwsd/TileCache.cpp b/loolwsd/TileCache.cpp
index 9e3bca7..c7dfd6e 100644
--- a/loolwsd/TileCache.cpp
+++ b/loolwsd/TileCache.cpp
@@ -140,19 +140,11 @@ std::unique_ptr TileCache::lookupTile(const 
TileDesc& tile)
 return nullptr;
 }
 
-void TileCache::saveTileAndNotify(const TileDesc& tile, const char *data, 
const size_t size, const bool /* priority */)
+void TileCache::saveTileAndNotify(const TileDesc& tile, const char *data, 
const size_t size)
 {
 std::unique_lock lock(_tilesBeingRenderedMutex);
 
 std::shared_ptr tileBeingRendered = 
findTileBeingRendered(tile);
-#if 0
-if (!priority && tileBeingRendered && tileBeingRendered->getVersion() != 
tile.getVersion())
-{
-Log::trace() << "Skipping unexpected tile ver: " << tile.getVersion()
- << ", waiting for ver " << 
tileBeingRendered->getVersion() << Log::end;
-return;
-}
-#endif
 
 // Save to disk.
 const auto cachedName = (tileBeingRendered ? 
tileBeingRendered->getCacheName()
@@ -197,6 +189,10 @@ void TileCache::saveTileAndNotify(const TileDesc& tile, 
const char *data, const
 }
 }
 }
+else
+{
+Log::debug("No subscribers for: " + cachedName);
+}
 
 // Remove subscriptions.
 if (tileBeingRendered->getVersion() == tile.getVersion())
diff --git a/loolwsd/TileCache.hpp b/loolwsd/TileCache.hpp
index bbe5aa0..08b14e0 100644
--- a/loolwsd/TileCache.hpp
+++ b/loolwsd/TileCache.hpp
@@ -44,7 +44,7 @@ public:
 
 std::unique_ptr lookupTile(const TileDesc& tile);
 
-void saveTileAndNotify(const TileDesc& tile, const char *data, const 
size_t size, const bool priority);
+void saveTileAndNotify(const TileDesc& tile, const char *data, const 
size_t size);
 
 std::string getTextFile(const std::string& fileName);
 
diff --git a/loolwsd/test/TileCacheTests.cpp b/loolwsd/test/TileCacheTests.cpp
index a4d3527..b9f8900 100644
--- a/loolwsd/test/TileCacheTests.cpp
+++ b/loolwsd/test/TileCacheTests.cpp
@@ -159,7 +159,7 @@ void TileCacheTests::testSimple()
 // Cache Tile
 const auto size = 1024;
 const auto data = genRandomData(size);
-tc.saveTileAndNotify(tile, data.data(), size, true);
+tc.saveTileAndNotify(tile, data.data(), size);
 
 // Find Tile
 file = tc.lookupTile(tile);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/TileDesc.hpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/TileDesc.hpp |9 +++--
 1 file changed, 7 insertions(+), 2 deletions(-)

New commits:
commit 454b2b71c18ace94f16dcf1f203c4d20cf9f1dce
Author: Ashod Nakashian 
Date:   Mon Sep 19 20:30:35 2016 -0400

loolwsd: don't generate imgsize in tile when 0

Change-Id: I469bdbfbb5efd8230808e6c68f58f505acef3993
Reviewed-on: https://gerrit.libreoffice.org/29069
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/TileDesc.hpp b/loolwsd/TileDesc.hpp
index e4d2c36..0258645 100644
--- a/loolwsd/TileDesc.hpp
+++ b/loolwsd/TileDesc.hpp
@@ -81,8 +81,13 @@ public:
 << " tileposy=" << _tilePosY
 << " tilewidth=" << _tileWidth
 << " tileheight=" << _tileHeight
-<< " ver=" << _ver
-<< " imgsize=" << _imgSize;
+<< " ver=" << _ver;
+
+if (_imgSize > 0)
+{
+oss << " imgsize=" << _imgSize;
+}
+
 if (_id >= 0)
 {
 oss << " id=" << _id;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loolwsd/TileCache.cpp

2016-09-19 Thread Ashod Nakashian
 loolwsd/TileCache.cpp |   21 -
 1 file changed, 12 insertions(+), 9 deletions(-)

New commits:
commit faf6cf7ce414fd61c948058e085c9856d87edd6e
Author: Ashod Nakashian 
Date:   Mon Sep 19 20:51:10 2016 -0400

loolwsd: better logging in subscribeToTileRendering

Change-Id: I5b94cda02e4f0e1154de81fc7bb4380332f2eeeb
Reviewed-on: https://gerrit.libreoffice.org/29070
Reviewed-by: Ashod Nakashian 
Tested-by: Ashod Nakashian 

diff --git a/loolwsd/TileCache.cpp b/loolwsd/TileCache.cpp
index c7dfd6e..ba20c8d 100644
--- a/loolwsd/TileCache.cpp
+++ b/loolwsd/TileCache.cpp
@@ -423,26 +423,30 @@ void TileCache::saveLastModified(const Timestamp& 
timestamp)
 // FIXME: to be further simplified when we centralize tile messages.
 int TileCache::subscribeToTileRendering(const TileDesc& tile, const 
std::shared_ptr &subscriber)
 {
+assert(subscriber->getKind() == LOOLSession::Kind::ToClient);
+
 std::unique_lock lock(_tilesBeingRenderedMutex);
 
 std::shared_ptr tileBeingRendered = 
findTileBeingRendered(tile);
 
+std::ostringstream oss;
+oss << '(' << tile.getPart() << ',' << tile.getTilePosX() << ',' << 
tile.getTilePosY() << ')';
+const auto name = oss.str();
+
 if (tileBeingRendered)
 {
-Log::debug() << "Subscribing to tile (" << tile.getPart() << ',' << 
tile.getTilePosX() << ','
- << tile.getTilePosY() << ") which has "
- << tileBeingRendered->_subscribers.size()
- << " subscribers already. Adding one more." << Log::end;
-assert(subscriber->getKind() == LOOLSession::Kind::ToClient);
-
 for (const auto &s : tileBeingRendered->_subscribers)
 {
 if (s.lock().get() == subscriber.get())
 {
-Log::debug("Redundant request to re-subscribe on a tile");
+Log::debug("Redundant request to subscribe on tile " + name);
 return 0;
 }
 }
+
+Log::debug() << "Subscribing to tile " << name << " which has "
+ << tileBeingRendered->_subscribers.size()
+ << " subscribers already. Adding one more." << Log::end;
 tileBeingRendered->_subscribers.push_back(subscriber);
 
 const auto duration = (std::chrono::steady_clock::now() - 
tileBeingRendered->getStartTime());
@@ -456,8 +460,7 @@ int TileCache::subscribeToTileRendering(const TileDesc& 
tile, const std::shared_
 }
 else
 {
-Log::debug() << "Subscribing to tile (" << tile.getPart() << ',' << 
tile.getTilePosX() << ','
- << tile.getTilePosY() << ") which has no subscribers. 
Subscribing for ver: "
+Log::debug() << "Subscribing to tile " << name << " which has no 
subscribers. Subscribing for ver: "
  << tile.getVersion() << "." << Log::end;
 
 const std::string cachedName = cacheFileName(tile);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: helpcontent2

2016-09-19 Thread Gabor Kelemen
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit e57baf08d6b1911ac151e5485b2ea8331725324f
Author: Gabor Kelemen 
Date:   Mon Sep 19 15:10:00 2016 +0200

Updated core
Project: help  e8cbb3daf90aa2a6f2e68c01841535b49d53d066

tdf#97105 Fix location of the Freze Rows and Columns menu item

This is now under View -> Freeze Cells

Change-Id: I6968ee93a1d2f12451791b297b9497eae6e93cd6
Reviewed-on: https://gerrit.libreoffice.org/29024
Reviewed-by: Adolfo Jayme Barrientos 
Tested-by: Adolfo Jayme Barrientos 

diff --git a/helpcontent2 b/helpcontent2
index f3339c9..e8cbb3d 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit f3339c932c24d48eb854399d92cd7ca64fe3ea1c
+Subproject commit e8cbb3daf90aa2a6f2e68c01841535b49d53d066
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] help.git: source/text

2016-09-19 Thread Gabor Kelemen
 source/text/scalc/00/0407.xhp|2 +-
 source/text/scalc/guide/line_fix.xhp |6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit e8cbb3daf90aa2a6f2e68c01841535b49d53d066
Author: Gabor Kelemen 
Date:   Mon Sep 19 15:10:00 2016 +0200

tdf#97105 Fix location of the Freze Rows and Columns menu item

This is now under View -> Freeze Cells

Change-Id: I6968ee93a1d2f12451791b297b9497eae6e93cd6
Reviewed-on: https://gerrit.libreoffice.org/29024
Reviewed-by: Adolfo Jayme Barrientos 
Tested-by: Adolfo Jayme Barrientos 

diff --git a/source/text/scalc/00/0407.xhp 
b/source/text/scalc/00/0407.xhp
index 6574661..2021aeb 100644
--- a/source/text/scalc/00/0407.xhp
+++ b/source/text/scalc/00/0407.xhp
@@ -30,7 +30,7 @@
 
 Window 
Menu
 Choose View - Split 
Window
-Choose View - Freeze Rows and 
Columns
+Choose View - Freeze Cells - Freeze Rows and 
Columns
 
 
 
diff --git a/source/text/scalc/guide/line_fix.xhp 
b/source/text/scalc/guide/line_fix.xhp
index 400debb..2dc7810 100644
--- a/source/text/scalc/guide/line_fix.xhp
+++ b/source/text/scalc/guide/line_fix.xhp
@@ -49,15 +49,15 @@
 To freeze 
both horizontally and vertically, select the cell that is below 
the row and to the right of the column that you want to freeze.
   
   
-Choose 
View - Freeze Rows and Columns.
-To 
deactivate, choose View - Freeze Rows and Columns 
again.
+Choose 
View - Freeze Cells - Freeze Rows and 
Columns.
+To 
deactivate, choose View - Freeze Cells - Freeze Rows and 
Columns again.
   
 
 If the area defined 
is to be scrollable, apply the View - Split Window 
command.
 If you want to 
print a certain row on all pages of a document, choose Format - Print ranges - Edit.
 
 
-View - 
Freeze Rows and Columns
+View - Freeze Cells - Freeze Rows and Columns
 View - Split 
Window
 
 Format - 
Print ranges - Edit
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: helpcontent2

2016-09-19 Thread Adolfo Jayme Barrientos
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit ece7079f77efea3fcbd205209fb16f6c9a12bf3f
Author: Adolfo Jayme Barrientos 
Date:   Mon Sep 19 23:21:09 2016 -0500

Updated core
Project: help  229282b80660a023077e5330afbbae51398b9690

It’s called an asterisk

Change-Id: If15846de1cd0df1023198bff74711419ec3137f5

diff --git a/helpcontent2 b/helpcontent2
index e8cbb3d..229282b 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit e8cbb3daf90aa2a6f2e68c01841535b49d53d066
+Subproject commit 229282b80660a023077e5330afbbae51398b9690
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] help.git: source/text

2016-09-19 Thread Adolfo Jayme Barrientos
 source/text/shared/01/05020301.xhp |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 229282b80660a023077e5330afbbae51398b9690
Author: Adolfo Jayme Barrientos 
Date:   Mon Sep 19 23:21:09 2016 -0500

It’s called an asterisk

Change-Id: If15846de1cd0df1023198bff74711419ec3137f5

diff --git a/source/text/shared/01/05020301.xhp 
b/source/text/shared/01/05020301.xhp
index ad4310d..df8c1f5 100644
--- a/source/text/shared/01/05020301.xhp
+++ b/source/text/shared/01/05020301.xhp
@@ -206,7 +206,7 @@
 
 Spaces
 To use a 
character to define the width of a space in a number format, type an underscore 
( _ ) followed by the character. The width of the space varies according to the 
width of the character that you choose. For example, _M creates a 
wider space than _i.
-To fill free 
space with a given character, use star character (*) followed by this 
character. For instance:
+To fill free 
space with a given character, use an asterisk (*) followed by this character. 
For instance:
 *\0
 will display 
integer value (0) preceded by as many as needed backslash characters (\) to 
fill column width. For accounting representation, you may left align currency 
symbol with a format similar to:
 $_-* 0.--;$-* 
0.--;$_-* -
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-09-19 Thread Pranav Kant
 loleaflet/dist/toolbar/toolbar.js |   60 ++
 loleaflet/main.js |2 -
 loleaflet/src/layer/tile/TileLayer.js |   16 -
 3 files changed, 6 insertions(+), 72 deletions(-)

New commits:
commit 77e219ceff24dd4a566dfdf4f82a6929fe9a563e
Author: Pranav Kant 
Date:   Tue Sep 20 10:57:39 2016 +0530

loleaflet: Kill editlock code, completely

Editlock buttons have already been removed; most of this code is
unreachable/useless anyways.

Don't listen to editlock messages anymore, and always set the map
permission to edit unless specified.

Change-Id: I2ee672e72beaa48a7c6cd0bbd1c548ff10a251d1

diff --git a/loleaflet/dist/toolbar/toolbar.js 
b/loleaflet/dist/toolbar/toolbar.js
index f6597f2..8e4e6aa 100644
--- a/loleaflet/dist/toolbar/toolbar.js
+++ b/loleaflet/dist/toolbar/toolbar.js
@@ -123,13 +123,6 @@ function onClick(id, item, subItem) {
map.setPart(id);
}
}
-   else if (id === 'takeedit') {
-   if (!item.checked) {
-   map._socket.sendMessage('takeedit');
-   // And advertise which page we're on.
-   map._socket.sendMessage('setclientpart part=' + 
map._docLayer._selectedPart);
-   }
-   }
else if (id === 'searchprev') {
map.search(L.DomUtil.get('search-input').value, true);
}
@@ -496,8 +489,6 @@ var formatButtons = {
'incrementindent': true, 'decrementindent': true, 'insertgraphic': true
 };
 
-var takeEditPopupMessage = '' + _('You are viewing now.') + '' + 
_('Click here to take edit.') + '';
-var takeEditPopupTimeout = null;
 var userJoinedPopupMessage = '' + _('%user has joined') + '';
 var userLeftPopupMessage = '' + _('%user has left') + '';
 var userPopupTimeout = null;
@@ -1004,7 +995,9 @@ map.on('commandstatechanged', function (e) {
}
// only store the state for now;
// buttons with stored state === enabled will
-   // be enabled when we get the editlock
+   // be enabled later (if we are in editmode)
+   // If we are in viewmode, these store states will be used
+   // when we get the edit access
else if (state === 'enabled') {
formatButtons[id] = true;
}
@@ -1012,8 +1005,7 @@ map.on('commandstatechanged', function (e) {
formatButtons[id] = false;
}
 
-   // Change the toolbar button state immediately
-   // if we already have the editlock
+   // Change the toolbar button states immediately if we are in 
editmode
if (map._permission === 'edit' && (state === 'enabled' || state 
=== 'disabled')) {
// in case some buttons are in toolbar-up-more, find
// them and en/dis-able them.
@@ -1211,33 +1203,7 @@ map.on('hyperlinkclicked', function (e) {
 });
 
 map.on('updatepermission', function (e) {
-   var toolbar = w2ui['toolbar-down'];
-   if (e.perm === 'edit') {
-   toolbar.disable('takeedit');
-   toolbar.set('takeedit', {hint: _('You are editing (others can 
only view)'), caption: _('EDITING')});
-   }
-   else if (e.perm === 'view') {
-   toolbar.enable('takeedit');
-   toolbar.set('takeedit', {hint: _('Take edit lock (others can 
only view)'), caption: _('VIEWING')});
-   $('#tb_toolbar-down_item_takeedit')
-   .w2overlay({
-   class: 'loleaflet-font',
-   html: takeEditPopupMessage,
-   style: 'padding: 5px'
-   });
-   clearTimeout(takeEditPopupTimeout);
-   takeEditPopupTimeout = setTimeout(function() {
-   $('#tb_toolbar-down_item_takeedit').w2overlay('');
-   clearTimeout(takeEditPopupTimeout);
-   takeEditPopupTimeout = null;
-   }, 3000);
-   }
-   else if (e.perm === 'readonly') {
-   toolbar.disable('takeedit');
-   toolbar.set('takeedit', {hint: _('You are locked in readonly 
mode'), caption: _('READONLY')});
-   }
-
-   toolbar = w2ui['toolbar-up'];
+   var toolbar = w2ui['toolbar-up'];
var toolbarUpMore = w2ui['toolbar-up-more'];
// {En,Dis}able toolbar buttons
for (var id in formatButtons) {
@@ -1317,22 +1283,6 @@ map.on('updatepermission', function (e) {
}
 });
 
-map.on('mouseup keypress', function() {
-   if (map._permission === 'view') {
-   $('#tb_toolbar-down_item_takeedit')
-   .w2overlay({
-   html: takeEditPopupMessage,
-   style: 'padding: 5px'
-  

[Libreoffice-commits] core.git: 2 commits - connectivity/source include/comphelper mysqlc/source odk/examples vcl/source

2016-09-19 Thread Stephan Bergmann
 connectivity/source/drivers/firebird/SubComponent.hxx  |   25 
+-
 include/comphelper/proparrhlp.hxx  |   25 
+-
 mysqlc/source/mysqlc_subcomponent.hxx  |   24 
+
 odk/examples/DevelopersGuide/Database/DriverSkeleton/OSubComponent.hxx |   24 
+
 vcl/source/window/taskpanelist.cxx |5 
+-
 5 files changed, 57 insertions(+), 46 deletions(-)

New commits:
commit d5f1e7c5adac5f38379c56b536640f3aaf9ec7d5
Author: Stephan Bergmann 
Date:   Mon Sep 19 21:30:51 2016 +0200

Obsolete workaround for SUNPRO 5 compiler

Change-Id: Ib51f08e1d0e0dff066b06ecd85976b777d722a33

diff --git a/vcl/source/window/taskpanelist.cxx 
b/vcl/source/window/taskpanelist.cxx
index 21b94d2..b5d1738 100644
--- a/vcl/source/window/taskpanelist.cxx
+++ b/vcl/source/window/taskpanelist.cxx
@@ -28,7 +28,8 @@
 #include 
 #include 
 
-// can't have static linkage because SUNPRO 5.2 complains
+namespace {
+
 Point ImplTaskPaneListGetPos( const vcl::Window *w )
 {
 Point pos;
@@ -47,6 +48,8 @@ Point ImplTaskPaneListGetPos( const vcl::Window *w )
 return pos;
 }
 
+}
+
 // compares window pos left-to-right
 struct LTRSort : public ::std::binary_function< const vcl::Window*, const 
vcl::Window*, bool >
 {
commit 07339d03afe742c53c22cb4ff5f73fe3132cff54
Author: Stephan Bergmann 
Date:   Mon Sep 19 21:18:23 2016 +0200

Remove obsolete workaround for SUNPRO 5 compiler

...copy/pasted into three more places

Change-Id: I6661244d0248af509cd867fc3e8c451551068a78

diff --git a/connectivity/source/drivers/firebird/SubComponent.hxx 
b/connectivity/source/drivers/firebird/SubComponent.hxx
index 7a86cf1..5c87097 100644
--- a/connectivity/source/drivers/firebird/SubComponent.hxx
+++ b/connectivity/source/drivers/firebird/SubComponent.hxx
@@ -68,17 +68,7 @@ namespace connectivity
 
 public:
 OPropertyArrayUsageHelper();
-virtual ~OPropertyArrayUsageHelper()
-{   // ARGHHH . would like to implement this in 
proparrhlp_impl.hxx (as we do with all other methods)
-// but SUNPRO 5 compiler (linker) doesn't like this
-::osl::MutexGuard aGuard(s_aMutex);
-OSL_ENSURE(s_nRefCount > 0, 
"OPropertyArrayUsageHelper::~OPropertyArrayUsageHelper : suspicious call : have 
a refcount of 0 !");
-if (!--s_nRefCount)
-{
-delete s_pProps;
-s_pProps = nullptr;
-}
-}
+virtual ~OPropertyArrayUsageHelper();
 
 /** call this in the getInfoHelper method of your derived class. 
The method returns the array helper of the
 class, which is created if necessary.
@@ -117,6 +107,19 @@ namespace connectivity
 
 
 template 
+OPropertyArrayUsageHelper::~OPropertyArrayUsageHelper()
+{
+::osl::MutexGuard aGuard(s_aMutex);
+OSL_ENSURE(s_nRefCount > 0, 
"OPropertyArrayUsageHelper::~OPropertyArrayUsageHelper : suspicious call : have 
a refcount of 0 !");
+if (!--s_nRefCount)
+{
+delete s_pProps;
+s_pProps = nullptr;
+}
+}
+
+
+template 
 ::cppu::IPropertyArrayHelper* 
OPropertyArrayUsageHelper::getArrayHelper()
 {
 OSL_ENSURE(s_nRefCount, "OPropertyArrayUsageHelper::getArrayHelper 
: suspicious call : have a refcount of 0 !");
diff --git a/include/comphelper/proparrhlp.hxx 
b/include/comphelper/proparrhlp.hxx
index 0f8fe7e..507c51b 100644
--- a/include/comphelper/proparrhlp.hxx
+++ b/include/comphelper/proparrhlp.hxx
@@ -45,18 +45,7 @@ protected:
 
 public:
 OPropertyArrayUsageHelper();
-virtual ~OPropertyArrayUsageHelper()
-{   // ARGHHH . would like to implement this after the class
-// definition (as we do with all other methods) but SUNPRO 5 compiler
-// (linker) doesn't like this
-::osl::MutexGuard aGuard(OPropertyArrayUsageHelperMutex::get());
-OSL_ENSURE(s_nRefCount > 0, 
"OPropertyArrayUsageHelper::~OPropertyArrayUsageHelper : suspicious call : have 
a refcount of 0 !");
-if (!--s_nRefCount)
-{
-delete s_pProps;
-s_pProps = nullptr;
-}
-}
+virtual ~OPropertyArrayUsageHelper();
 
 /** call this in the getInfoHelper method of your derived class. The 
method returns the array helper of the
 class, which is created if necessary.
@@ -125,6 +114,18 @@ 
OPropertyArrayUsageHelper::OPropertyArrayUsageHelper()
 }
 
 template 
+OPropertyArrayUsageHelper::~OPropertyArrayUsageHelper()
+{
+::osl::MutexGuard aGuard(OPropertyArrayUsageHelperMutex::get());
+OSL_ENSURE(s_nRefCount > 0, 
"OPropertyArrayUsageHelper::~OPropertyArrayUsageHelper : suspicious call : have 
a refcount of 0 !");
+if (!--s_nR

Re: How to keep UNO applications connected after closing LibreOffice

2016-09-19 Thread Samuel Mehrbrodt
Am 19.09.2016 um 17:29 schrieb Stephan Bergmann:

On 09/19/2016 05:17 PM, Samuel Mehrbrodt wrote:


It turned out we need to implement both. The first option was fine when
only closing the window - but we also want to be able to close the
visible frames with "File->Exit" while keeping the process running.



Do we?  I think there is probably a difference in what we can imply as
user-expected behavior between closing the last window (via "Window -
Close Window" or whatever desktop-environment--specific trigger) and
terminating LO (via "File - Exit LibreOffice").

Well, with my patches, there will be a difference. Closing the window will 
leave the process running, and chosing File->Exit will kill the process.

What I did change in my second patch is the behavior of File->Exit when using 
the TerminationVetoException.
Before it prevented closing the windows and terminating the process - after my 
patch it only prevents termination.

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


Re: How to keep UNO applications connected after closing LibreOffice

2016-09-19 Thread Tor Lillqvist
How does this interact with the options --headless, --invisible, and
--quickstart ? Could the same end result be achieved by starting
LibreOffice with one of them?

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


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

2016-09-19 Thread Takeshi Abe
 starmath/qa/extras/mmlexport-test.cxx |   12 
 starmath/source/mathmlexport.cxx  |   16 
 starmath/source/mathmlexport.hxx  |1 +
 3 files changed, 29 insertions(+)

New commits:
commit 3a8035bcb6cf081572d86813021bbccab265a935
Author: Takeshi Abe 
Date:   Mon Sep 19 09:26:41 2016 +0900

tdf#97049 Export "intd" to MathML

Change-Id: Ie1fc33e18958e73d4876b2b5daceec127011c3cc
Reviewed-on: https://gerrit.libreoffice.org/29003
Tested-by: Jenkins 
Reviewed-by: Takeshi Abe 

diff --git a/starmath/qa/extras/mmlexport-test.cxx 
b/starmath/qa/extras/mmlexport-test.cxx
index f13ee9d..3a2d222 100644
--- a/starmath/qa/extras/mmlexport-test.cxx
+++ b/starmath/qa/extras/mmlexport-test.cxx
@@ -35,9 +35,11 @@ public:
 virtual void setUp() override;
 virtual void tearDown() override;
 
+void testTdf97049();
 void testTdf101022();
 
 CPPUNIT_TEST_SUITE(MathMLExportTest);
+CPPUNIT_TEST(testTdf97049);
 CPPUNIT_TEST(testTdf101022);
 CPPUNIT_TEST_SUITE_END();
 
@@ -85,6 +87,16 @@ xmlDocPtr MathMLExportTest::exportAndParse()
 return pDoc;
 }
 
+void MathMLExportTest::testTdf97049()
+{
+mxDocShell->SetText("intd {{1 over x} dx}");
+xmlDocPtr pDoc = exportAndParse();
+assertXPath(pDoc, "/m:math/m:semantics/m:mrow/m:mo[1]", "stretchy", 
"true");
+auto aContent = getXPathContent(pDoc, 
"/m:math/m:semantics/m:mrow/m:mo[1]");
+CPPUNIT_ASSERT_EQUAL(sal_Int32(1), aContent.getLength());
+CPPUNIT_ASSERT_EQUAL(sal_Unicode(0x222B), aContent[0]);
+}
+
 void MathMLExportTest::testTdf101022()
 {
 #define CHECK_MATHVARIANT(capital, small) do\
diff --git a/starmath/source/mathmlexport.cxx b/starmath/source/mathmlexport.cxx
index 0567181..2aab226 100644
--- a/starmath/source/mathmlexport.cxx
+++ b/starmath/source/mathmlexport.cxx
@@ -811,6 +811,11 @@ void SmXMLExport::ExportMath(const SmNode *pNode, int 
/*nLevel*/)
 AddAttribute(XML_NAMESPACE_MATH, XML_MATHVARIANT, XML_NORMAL);
 pMath = new SvXMLElementExport(*this, XML_NAMESPACE_MATH, XML_MI, 
true, false);
 }
+else if (pNode->GetType() == NDYNINTSYMBOL)
+{
+AddAttribute(XML_NAMESPACE_MATH, XML_STRETCHY, XML_TRUE);
+pMath = new SvXMLElementExport(*this, XML_NAMESPACE_MATH, XML_MO, 
true, false);
+}
 else
 {
 // Export NMATHIDENT and NPLACE symbols as  elements:
@@ -1456,6 +1461,13 @@ void SmXMLExport::ExportMatrix(const SmNode *pNode, int 
nLevel)
 }
 }
 
+void SmXMLExport::ExportDynIntegral(const SmDynIntegralNode *pNode, int nLevel)
+{
+SvXMLElementExport aRow(*this, XML_NAMESPACE_MATH, XML_MROW, true, true);
+ExportNodes(pNode->Symbol(), nLevel+1);
+ExportNodes(pNode->Body(), nLevel+1);
+}
+
 void SmXMLExport::ExportNodes(const SmNode *pNode, int nLevel)
 {
 if (!pNode)
@@ -1520,6 +1532,7 @@ void SmXMLExport::ExportNodes(const SmNode *pNode, int 
nLevel)
 case NSPECIAL: //NSPECIAL requires some sort of Entity preservation in 
the XML engine.
 case NMATHIDENT :
 case NPLACE:
+case NDYNINTSYMBOL:
 ExportMath(pNode, nLevel);
 break;
 case NBINHOR:
@@ -1561,6 +1574,9 @@ void SmXMLExport::ExportNodes(const SmNode *pNode, int 
nLevel)
 case NBLANK:
 ExportBlank(pNode, nLevel);
 break;
+case NDYNINT:
+ExportDynIntegral(static_cast(pNode), 
nLevel);
+break;
default:
 SAL_WARN("starmath", "Warning: failed to export a node?");
 break;
diff --git a/starmath/source/mathmlexport.hxx b/starmath/source/mathmlexport.hxx
index 4581db8..19a29cb 100644
--- a/starmath/source/mathmlexport.hxx
+++ b/starmath/source/mathmlexport.hxx
@@ -92,6 +92,7 @@ protected:
 void ExportVerticalBrace(const SmVerticalBraceNode *pNode, int nLevel);
 void ExportMatrix(const SmNode *pNode, int nLevel);
 void ExportBlank(const SmNode *pNode, int nLevel);
+void ExportDynIntegral(const SmDynIntegralNode *pNode, int nLevel);
 
 public:
 SmXMLExport(
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits