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

2016-04-07 Thread Tor Lillqvist
 loolwsd/UnitHTTP.hpp |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 1fcdb8beaa3375ba9ad26591e891209d9ca1dee2
Author: Tor Lillqvist 
Date:   Fri Apr 8 09:29:45 2016 +0300

expectContinue is gone in bleeding-edge Poco

Put this inside #if, add the 'override' back for current Poco. Avoids
"warning: 'expectContinue' overrides a member function but is not
marked 'override'" when compiling against current Poco.

Not sure what good it would do to define it at all if compiling
against a bleeding-edge Poco as it won't call it anyway?

diff --git a/loolwsd/UnitHTTP.hpp b/loolwsd/UnitHTTP.hpp
index 53694ff..0f4c992 100644
--- a/loolwsd/UnitHTTP.hpp
+++ b/loolwsd/UnitHTTP.hpp
@@ -55,8 +55,10 @@ public:
 { setURI(uri); }
 virtual std::istream& stream() override
 { return *(static_cast(nullptr)); }
-virtual bool expectContinue() const /*override*/ // Some Poco version 
don't have this.
+#if POCO_VERSION < 0x0200
+virtual bool expectContinue() const override
 { return false; }
+#endif
 virtual bool secure() const { return true; }
virtual const SocketAddress& clientAddress() const override
 { return _clientAddress; }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Markus Mohrhard
 oox/source/export/ColorPropertySet.cxx |   15 +--
 1 file changed, 13 insertions(+), 2 deletions(-)

New commits:
commit 753c474b199a9c12f182c89c487133f9fa88e352
Author: Markus Mohrhard 
Date:   Fri Apr 8 05:06:54 2016 +0200

fix many ooxml validation errors

This code was just horribly broken. Every requested property would
return the color value which if interepreted as an alpha value gave
invalid values.

This now contains an assert that might trigger in the next set of crash
testing.

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

diff --git a/oox/source/export/ColorPropertySet.cxx 
b/oox/source/export/ColorPropertySet.cxx
index 3fb4b9a..bab61b0 100644
--- a/oox/source/export/ColorPropertySet.cxx
+++ b/oox/source/export/ColorPropertySet.cxx
@@ -108,13 +108,20 @@ Reference< XPropertySetInfo > SAL_CALL 
ColorPropertySet::getPropertySetInfo()
 return m_xInfo;
 }
 
-void SAL_CALL ColorPropertySet::setPropertyValue( const OUString& /* 
aPropertyName */, const uno::Any& aValue )
+void SAL_CALL ColorPropertySet::setPropertyValue( const OUString& 
rPropertyName, const uno::Any& aValue )
 throw (UnknownPropertyException,
PropertyVetoException,
lang::IllegalArgumentException,
lang::WrappedTargetException,
uno::RuntimeException, std::exception)
 {
+if (rPropertyName != m_aColorPropName)
+{
+// trying to catch these cases in the next crash testing
+assert(false);
+return;
+}
+
 aValue >>= m_nColor;
 }
 
@@ -128,7 +135,10 @@ uno::Any SAL_CALL ColorPropertySet::getPropertyValue( 
const OUString& aPropertyN
 css::drawing::FillStyle aFillStyle = css::drawing::FillStyle_SOLID;
 return uno::makeAny(aFillStyle);
 }
-return uno::makeAny( m_nColor );
+else if (aPropertyName == m_aColorPropName)
+return uno::makeAny( m_nColor );
+
+throw UnknownPropertyException();
 }
 
 void SAL_CALL ColorPropertySet::addPropertyChangeListener( const OUString& /* 
aPropertyName */, const Reference< XPropertyChangeListener >& /* xListener */ )
@@ -199,6 +209,7 @@ uno::Any SAL_CALL ColorPropertySet::getPropertyDefault( 
const OUString& aPropert
 {
 if( aPropertyName.equals( m_aColorPropName ))
 return uno::makeAny( m_nDefaultColor );
+
 return uno::Any();
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Tomaž Vajngerl
 vcl/source/window/toolbox.cxx |   32 
 1 file changed, 8 insertions(+), 24 deletions(-)

New commits:
commit 5a4b01f63d3f2a7d7d6fa8cf9ca6a328c5da7a6a
Author: Tomaž Vajngerl 
Date:   Fri Apr 8 11:39:51 2016 +0900

vcl: draw toolbox grip with ellipses instead of pixels, HiDPI

Previously the non-native grip was drawn manually with filling
(lots of) pixels to get kind-of 3D effect for grips. This is not
ideal for HiDPI and can also be slow on certain backends.

This commit simplifies grip drawing by just drawng ellipses
(circles actually). This makes it easy to extend the drawing to
support HiDPI scaling and it also looks better and simpler.

Change-Id: I9df192b69f7f920cececf12b40c1f70342e6d485

diff --git a/vcl/source/window/toolbox.cxx b/vcl/source/window/toolbox.cxx
index eb3b005..34c722f 100644
--- a/vcl/source/window/toolbox.cxx
+++ b/vcl/source/window/toolbox.cxx
@@ -286,28 +286,21 @@ void ToolBox::ImplDrawGrip(vcl::RenderContext& 
rRenderContext)
 
 const StyleSettings& rStyleSettings = 
rRenderContext.GetSettings().GetStyleSettings();
 rRenderContext.SetLineColor(rStyleSettings.GetShadowColor());
+rRenderContext.SetFillColor(rStyleSettings.GetShadowColor());
 
 Size aSz(GetOutputSizePixel());
+float fScaleFactor = rRenderContext.GetDPIScaleFactor();
 
 if (meAlign == WindowAlign::Top || meAlign == WindowAlign::Bottom)
 {
 int height = (int) (0.6 * aSz.Height() + 0.5);
 int i = (aSz.Height() - height) / 2;
 height += i;
-while( i <= height )
+while (i <= height)
 {
 int x = ImplGetDragWidth(this) / 2;
-
-rRenderContext.DrawPixel( Point(x, i), 
rStyleSettings.GetDarkShadowColor() );
-rRenderContext.DrawPixel( Point(x+1, i), 
rStyleSettings.GetShadowColor() );
-
-rRenderContext.DrawPixel( Point(x, i+1), 
rStyleSettings.GetShadowColor() );
-rRenderContext.DrawPixel( Point(x+1, i+1), 
rStyleSettings.GetFaceColor() );
-rRenderContext.DrawPixel( Point(x+2, i+1), Color(COL_WHITE) );
-
-rRenderContext.DrawPixel( Point(x+1, i+2), Color(COL_WHITE) );
-rRenderContext.DrawPixel( Point(x+2, i+2), Color(COL_WHITE) );
-i+=4;
+rRenderContext.DrawEllipse(Rectangle(Point(x, i), Size(2 * 
fScaleFactor, 2 * fScaleFactor)));
+i += 4 * fScaleFactor;
 }
 }
 else
@@ -315,20 +308,11 @@ void ToolBox::ImplDrawGrip(vcl::RenderContext& 
rRenderContext)
 int width = (int) (0.6 * aSz.Width() + 0.5);
 int i = (aSz.Width() - width) / 2;
 width += i;
-while( i <= width )
+while (i <= width)
 {
 int y = ImplGetDragWidth(this) / 2;
-
-rRenderContext.DrawPixel( Point(i, y), 
rStyleSettings.GetDarkShadowColor() );
-rRenderContext.DrawPixel( Point(i+1, y), 
rStyleSettings.GetShadowColor() );
-
-rRenderContext.DrawPixel( Point(i, y+1), 
rStyleSettings.GetShadowColor() );
-rRenderContext.DrawPixel( Point(i+1, y+1), 
rStyleSettings.GetFaceColor() );
-rRenderContext.DrawPixel( Point(i+2, y+1), Color(COL_WHITE) );
-
-rRenderContext.DrawPixel( Point(i+1, y+2), Color(COL_WHITE) );
-rRenderContext.DrawPixel( Point(i+2, y+2), Color(COL_WHITE) );
-i+=4;
+rRenderContext.DrawEllipse(Rectangle(Point(i, y), Size(2 * 
fScaleFactor, 2 * fScaleFactor)));
+i += 4 * fScaleFactor;
 }
 }
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Ashod Nakashian
 loolwsd/UnitHTTP.hpp |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 703febc2e26962c88c5753476f04fc145a96aa8b
Author: Ashod Nakashian 
Date:   Thu Apr 7 20:29:27 2016 -0400

loolwsd: compatibility fixes with Poco master

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

diff --git a/loolwsd/UnitHTTP.hpp b/loolwsd/UnitHTTP.hpp
index ea00b85..53694ff 100644
--- a/loolwsd/UnitHTTP.hpp
+++ b/loolwsd/UnitHTTP.hpp
@@ -55,8 +55,9 @@ public:
 { setURI(uri); }
 virtual std::istream& stream() override
 { return *(static_cast(nullptr)); }
-virtual bool expectContinue() const override
+virtual bool expectContinue() const /*override*/ // Some Poco version 
don't have this.
 { return false; }
+virtual bool secure() const { return true; }
virtual const SocketAddress& clientAddress() const override
 { return _clientAddress; }
virtual const SocketAddress& serverAddress() const override
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Henry Castro
 loleaflet/dist/loleaflet.html |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit b6aeee816c66a725bb4283846fbf8c507e62af3f
Author: Henry Castro 
Date:   Thu Apr 7 17:33:14 2016 -0400

loleaflet: restore default example title

diff --git a/loleaflet/dist/loleaflet.html b/loleaflet/dist/loleaflet.html
index a74339a..bc6abfa 100644
--- a/loleaflet/dist/loleaflet.html
+++ b/loleaflet/dist/loleaflet.html
@@ -1,7 +1,7 @@
 
 
 
-Collabora Online
+Document Simple Example
 
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: 2 commits - loolwsd/DocumentBroker.cpp loolwsd/LOOLWSD.cpp loolwsd/Makefile.am loolwsd/Storage.cpp loolwsd/Storage.hpp loolwsd/test loolwsd/Unit.hpp loolwsd/UnitHTTP.

2016-04-07 Thread Michael Meeks
 loolwsd/DocumentBroker.cpp   |   22 -
 loolwsd/LOOLWSD.cpp  |   36 +++---
 loolwsd/Makefile.am  |3 +
 loolwsd/Storage.cpp  |   28 +
 loolwsd/Storage.hpp  |   28 ++---
 loolwsd/Unit.hpp |   26 +++
 loolwsd/UnitHTTP.hpp |   70 +++
 loolwsd/test/Makefile.am |9 +++--
 loolwsd/test/UnitStorage.cpp |   46 
 loolwsd/test/run_unit.sh |2 -
 10 files changed, 227 insertions(+), 43 deletions(-)

New commits:
commit 7d62c74b8388170b3284e7128f19618b49853e10
Author: Michael Meeks 
Date:   Thu Apr 7 21:59:27 2016 +0100

Fix segv on failure to create a storage, and add unit test infra.

diff --git a/loolwsd/DocumentBroker.cpp b/loolwsd/DocumentBroker.cpp
index 90f60bc..b8cfa61 100644
--- a/loolwsd/DocumentBroker.cpp
+++ b/loolwsd/DocumentBroker.cpp
@@ -81,7 +81,7 @@ DocumentBroker::DocumentBroker(const Poco::URI& uriPublic,
 void DocumentBroker::validate(const Poco::URI& uri)
 {
 Log::info("Validating: " + uri.toString());
-auto storage = createStorage("", "", uri);
+auto storage = StorageBase::create("", "", uri);
 if (storage == nullptr || !storage->getFileInfo(uri).isValid())
 {
 throw std::runtime_error("Invalid URI or access denied.");
@@ -111,15 +111,21 @@ bool DocumentBroker::load(const std::string& jailId)
 
 Log::info("jailPath: " + jailPath.toString() + ", jailRoot: " + jailRoot);
 
-auto storage = createStorage("", "", _uriPublic);
-const auto fileInfo = storage->getFileInfo(_uriPublic);
-_tileCache.reset(new TileCache(_uriPublic.toString(), 
fileInfo.ModifiedTime, _cacheRoot));
+auto storage = StorageBase::create("", "", _uriPublic);
+if (storage)
+{
+const auto fileInfo = storage->getFileInfo(_uriPublic);
+_tileCache.reset(new TileCache(_uriPublic.toString(), 
fileInfo.ModifiedTime, _cacheRoot));
+
+_storage = StorageBase::create(jailRoot, jailPath.toString(), 
_uriPublic);
 
-_storage = createStorage(jailRoot, jailPath.toString(), _uriPublic);
+const auto localPath = _storage->loadStorageFileToLocal();
+_uriJailed = Poco::URI(Poco::URI("file://"), localPath);
 
-const auto localPath = _storage->loadStorageFileToLocal();
-_uriJailed = Poco::URI(Poco::URI("file://"), localPath);
-return true;
+return true;
+}
+else
+return false;
 }
 
 bool DocumentBroker::save()
diff --git a/loolwsd/LOOLWSD.cpp b/loolwsd/LOOLWSD.cpp
index 3c497db..08076c2 100644
--- a/loolwsd/LOOLWSD.cpp
+++ b/loolwsd/LOOLWSD.cpp
@@ -50,7 +50,6 @@
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 
@@ -93,6 +92,7 @@
 #include "IoUtil.hpp"
 #include "Util.hpp"
 #include "Unit.hpp"
+#include "UnitHTTP.hpp"
 
 using namespace LOOLProtocol;
 
@@ -240,7 +240,7 @@ class ClientRequestHandler: public HTTPRequestHandler
 {
 private:
 
-void handlePostRequest(HTTPServerRequest& request, HTTPServerResponse& 
response, const std::string& id)
+static void handlePostRequest(HTTPServerRequest& request, 
HTTPServerResponse& response, const std::string& id)
 {
 Log::info("Post request: [" + request.getURI() + "]");
 StringTokenizer tokens(request.getURI(), "/?");
@@ -425,7 +425,7 @@ private:
 }
 }
 
-void handleGetRequest(HTTPServerRequest& request, HTTPServerResponse& 
response, const std::string& id)
+static void handleGetRequest(HTTPServerRequest& request, 
HTTPServerResponse& response, const std::string& id)
 {
 Log::info("Starting GET request handler for session [" + id + "].");
 
@@ -546,7 +546,7 @@ private:
 }
 }
 
-void handleGetDiscovery(HTTPServerRequest& request, HTTPServerResponse& 
response)
+static void handleGetDiscovery(HTTPServerRequest& request, 
HTTPServerResponse& response)
 {
 DOMParser parser;
 DOMWriter writer;
@@ -583,6 +583,11 @@ public:
 
 void handleRequest(HTTPServerRequest& request, HTTPServerResponse& 
response) override
 {
+handleClientRequest(request,response);
+}
+
+static void handleClientRequest(HTTPServerRequest& request, 
HTTPServerResponse& response)
+{
 const auto id = LOOLWSD::GenSessionId();
 
 Util::setThreadName("client_ws_" + id);
@@ -632,6 +637,11 @@ public:
 
 void handleRequest(HTTPServerRequest& request, HTTPServerResponse& 
response) override
 {
+handlePrisonerRequest(request, response);
+}
+
+static void handlePrisonerRequest(HTTPServerRequest& request, 
HTTPServerResponse& response)
+{
 Util::setThreadName("prison_ws");
 
 Log::debug("Child connection with URI [" + request.getURI() + "].");
@@ -1395,6 +1405,8 @@ int LOOLWSD::main(const std::vector& 
/*args*/)
 int status = 0;
 while (!TerminationFlag && !LOOLWSD::DoTest)
 {
+UnitHooks::ge

[Libreoffice-commits] online.git: loleaflet/dist loolwsd/FileServer.hpp

2016-04-07 Thread Henry Castro
 loleaflet/dist/loleaflet.html |   23 +++--
 loolwsd/FileServer.hpp|   45 +-
 2 files changed, 52 insertions(+), 16 deletions(-)

New commits:
commit dd96c6a4de756505cc1d456272a4b279f5020b4d
Author: Henry Castro 
Date:   Thu Apr 7 17:16:40 2016 -0400

loolwsd: handle a POST request in loleaflet

diff --git a/loleaflet/dist/loleaflet.html b/loleaflet/dist/loleaflet.html
index 656fd0d..a74339a 100644
--- a/loleaflet/dist/loleaflet.html
+++ b/loleaflet/dist/loleaflet.html
@@ -1,7 +1,7 @@
 
 
 
-Document Simple Example
+Collabora Online
 
 
 
@@ -260,23 +260,16 @@
 

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

2016-04-07 Thread Noel Grandin
 basic/source/sbx/sbxarray.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit ba95e61314fb310575fe1dfd035234f4d6d7ca02
Author: Noel Grandin 
Date:   Thu Apr 7 11:21:49 2016 +0200

fix bug in SbxArray::Merge

bug was recently introduced by
commit a5c232831395f8987a8395816c5a60105a52b6a0
"BASIC: Store directly SbxVarEntry in SbxArray"

bug was found by clang-tidy

Change-Id: Ibcce6d6024ac60eb143cd873760586a7f6231858
Reviewed-on: https://gerrit.libreoffice.org/23890
Reviewed-by: Michael Stahl 
Tested-by: Michael Stahl 

diff --git a/basic/source/sbx/sbxarray.cxx b/basic/source/sbx/sbxarray.cxx
index 11faaef..f78c376 100644
--- a/basic/source/sbx/sbxarray.cxx
+++ b/basic/source/sbx/sbxarray.cxx
@@ -343,7 +343,7 @@ void SbxArray::Merge( SbxArray* p )
 {
 // Take this element and clear the original.
 rEntry2.mpVar = rEntry1.mpVar;
-rEntry2.mpVar.Clear();
+rEntry1.mpVar.Clear();
 break;
 }
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Takeshi Abe
 starmath/source/node.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 6f1df6dca04579dea5e54113cc9c0003ee98ebfe
Author: Takeshi Abe 
Date:   Tue Mar 29 16:48:51 2016 +0900

starmath: Assert that SmAlignNode must have only one child

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

diff --git a/starmath/source/node.cxx b/starmath/source/node.cxx
index f7dec45..b0cecfa 100644
--- a/starmath/source/node.cxx
+++ b/starmath/source/node.cxx
@@ -1725,9 +1725,10 @@ void SmOperNode::Arrange(OutputDevice &rDev, const 
SmFormat &rFormat)
 void SmAlignNode::Arrange(OutputDevice &rDev, const SmFormat &rFormat)
 // set alignment within the entire subtree (including current node)
 {
-OSL_ENSURE(GetNumSubNodes() > 0, "Sm: missing subnode");
+assert(GetNumSubNodes() == 1);
 
 SmNode  *pNode = GetSubNode(0);
+assert(pNode);
 
 RectHorAlign  eHorAlign = RectHorAlign::Center;
 switch (GetToken().eType)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: cui/source sd/source sfx2/source vcl/unx

2016-04-07 Thread Muhammet Kara
 cui/source/dialogs/cuigaldlg.cxx|2 +-
 cui/source/tabpages/backgrnd.cxx|2 +-
 sd/source/core/drawdoc4.cxx |2 +-
 sfx2/source/dialog/templdlg.cxx |2 +-
 vcl/unx/generic/print/genprnpsp.cxx |2 +-
 5 files changed, 5 insertions(+), 5 deletions(-)

New commits:
commit e88ba02a70c3f2279ed7ceefeb94f843537bcf8e
Author: Muhammet Kara 
Date:   Thu Apr 7 11:02:03 2016 +0300

tdf#97087 - Give Idles comprehensible and unique names

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

diff --git a/cui/source/dialogs/cuigaldlg.cxx b/cui/source/dialogs/cuigaldlg.cxx
index a2abaad..92d5423 100644
--- a/cui/source/dialogs/cuigaldlg.cxx
+++ b/cui/source/dialogs/cuigaldlg.cxx
@@ -461,7 +461,7 @@ short ActualizeProgress::Execute()
 {
 short nRet;
 
-pIdle = new Idle;
+pIdle = new Idle("ActualizeProgressTimeout");
 pIdle->SetIdleHdl( LINK( this, ActualizeProgress, TimeoutHdl ) );
 pIdle->SetPriority( SchedulerPriority::LOWEST );
 pIdle->Start();
diff --git a/cui/source/tabpages/backgrnd.cxx b/cui/source/tabpages/backgrnd.cxx
index 6504b11..2256096 100644
--- a/cui/source/tabpages/backgrnd.cxx
+++ b/cui/source/tabpages/backgrnd.cxx
@@ -951,7 +951,7 @@ void SvxBackgroundTabPage::ShowSelector()
 m_pBtnPosition->SetClickHdl( HDL(RadioClickHdl_Impl) );
 
 // delayed loading via timer (because of UI-Update)
-pPageImpl->pLoadIdle = new Idle;
+pPageImpl->pLoadIdle = new Idle("DelayedLoad");
 pPageImpl->pLoadIdle->SetPriority( SchedulerPriority::LOWEST );
 pPageImpl->pLoadIdle->SetIdleHdl(
 LINK( this, SvxBackgroundTabPage, LoadIdleHdl_Impl ) );
diff --git a/sd/source/core/drawdoc4.cxx b/sd/source/core/drawdoc4.cxx
index f02acee..e476ef3 100644
--- a/sd/source/core/drawdoc4.cxx
+++ b/sd/source/core/drawdoc4.cxx
@@ -772,7 +772,7 @@ void SdDrawDocument::StartOnlineSpelling(bool 
bForceSpelling)
 }
 
 mpOnlineSpellingList->seekShape(0);
-mpOnlineSpellingIdle = new Idle();
+mpOnlineSpellingIdle = new Idle("OnlineSpelling");
 mpOnlineSpellingIdle->SetIdleHdl( LINK(this, SdDrawDocument, 
OnlineSpellingHdl) );
 mpOnlineSpellingIdle->SetPriority(SchedulerPriority::LOWEST);
 mpOnlineSpellingIdle->Start();
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index 86af63d..9bc9d6f 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -1535,7 +1535,7 @@ void SfxCommonTemplateDialog_Impl::Notify(SfxBroadcaster& 
/*rBC*/, const SfxHint
 {
 if(!pIdle)
 {
-pIdle=new Idle;
+pIdle=new Idle("SfxCommonTemplate");
 pIdle->SetPriority(SchedulerPriority::LOWEST);
 pIdle->SetIdleHdl(LINK(this,SfxCommonTemplateDialog_Impl,TimeOut));
 }
diff --git a/vcl/unx/generic/print/genprnpsp.cxx 
b/vcl/unx/generic/print/genprnpsp.cxx
index 45e3e16..d9799f2 100644
--- a/vcl/unx/generic/print/genprnpsp.cxx
+++ b/vcl/unx/generic/print/genprnpsp.cxx
@@ -1325,7 +1325,7 @@ void PrinterUpdate::update(SalGenericInstance &rInstance)
 doUpdate();
 else if( ! pPrinterUpdateIdle )
 {
-pPrinterUpdateIdle = new Idle();
+pPrinterUpdateIdle = new Idle("PrinterUpdateTimer");
 pPrinterUpdateIdle->SetPriority( SchedulerPriority::LOWEST );
 pPrinterUpdateIdle->SetIdleHdl( LINK( nullptr, PrinterUpdate, 
UpdateTimerHdl ) );
 pPrinterUpdateIdle->Start();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Muhammet Kara
 vcl/source/app/svapp.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit e943da4189e829c7b65b6d171bd6d16ca5e0b425
Author: Muhammet Kara 
Date:   Thu Apr 7 10:09:46 2016 +0300

Fix simple typo in SAL_INFO tdf#97087

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

diff --git a/vcl/source/app/svapp.cxx b/vcl/source/app/svapp.cxx
index 9c874a9..ef785b8 100644
--- a/vcl/source/app/svapp.cxx
+++ b/vcl/source/app/svapp.cxx
@@ -510,7 +510,7 @@ inline bool ImplYield(bool i_bWait, bool i_bAllEvents, 
sal_uLong const nReleased
 i_bWait && !pSVData->maAppData.mbAppQuit,
 i_bAllEvents, nReleased);
 
-SAL_INFO("vcl.schedule", "DoYield with " << (bHasActiveIdles ? "active 
idles" : "no ides") <<
+SAL_INFO("vcl.schedule", "DoYield with " << (bHasActiveIdles ? "active 
idles" : "no idles") <<
  " returns: " << (eResult == SalYieldResult::EVENT ? "processed 
event" : "timeout"));
 
 pSVData->maAppData.mnDispatchLevel--;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Takeshi Abe
 vcl/source/edit/textdat2.hxx |5 +++--
 vcl/source/edit/textdoc.hxx  |4 +++-
 2 files changed, 6 insertions(+), 3 deletions(-)

New commits:
commit fa94cdc7fae33987b49985405d84a483010421f0
Author: Takeshi Abe 
Date:   Thu Apr 7 18:35:00 2016 +0900

vcl: Make it noncopyable by deleting copy ctor & co

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

diff --git a/vcl/source/edit/textdat2.hxx b/vcl/source/edit/textdat2.hxx
index 076d955..2788d36 100644
--- a/vcl/source/edit/textdat2.hxx
+++ b/vcl/source/edit/textdat2.hxx
@@ -174,12 +174,13 @@ private:
 boolmbInvalid;
 boolmbSimple;   // only type linearly
 
-TEParaPortion( const TEParaPortion& ) {;}
-
 public:
 TEParaPortion( TextNode* pNode );
 ~TEParaPortion();
 
+TEParaPortion( const TEParaPortion& ) = delete;
+void operator=( const TEParaPortion& ) = delete;
+
 boolIsInvalid() const   { return mbInvalid; }
 boolIsSimpleInvalid() const { return mbSimple; }
 voidSetNotSimpleInvalid()   { mbSimple = false; }
diff --git a/vcl/source/edit/textdoc.hxx b/vcl/source/edit/textdoc.hxx
index 4e7097c..91ff2ac 100644
--- a/vcl/source/edit/textdoc.hxx
+++ b/vcl/source/edit/textdoc.hxx
@@ -67,7 +67,6 @@ private:
 OUStringmaText;
 TextCharAttribList  maCharAttribs;
 
-TextNode( const TextNode& ) {;}
 protected:
 voidExpandAttribs( sal_Int32 nIndex, sal_Int32 nNewChars );
 voidCollapsAttribs( sal_Int32 nIndex, sal_Int32 nDelChars 
);
@@ -75,6 +74,9 @@ protected:
 public:
 TextNode( const OUString& rText );
 
+TextNode( const TextNode& ) = delete;
+void operator=( const TextNode& ) = delete;
+
 const OUString& GetText() const { return maText; }
 
 const TextCharAttrib&   GetCharAttrib(sal_uInt16 nPos) const  { return 
maCharAttribs.GetAttrib(nPos); }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Caolán McNamara
 vcl/unx/gtk3/gtk3salnativewidgets-gtk.cxx |   30 ++
 1 file changed, 2 insertions(+), 28 deletions(-)

New commits:
commit 70cc48f17a61296021c035f351c3db68bc5e08ad
Author: Caolán McNamara 
Date:   Thu Apr 7 21:02:37 2016 +0100

gtk3: the list/combo box hack to get internal buttons no longer works

with gtk3-3.20.2

Change-Id: I608f3476a82233cb49e0b43c95f5a984d7c89c92

diff --git a/vcl/unx/gtk3/gtk3salnativewidgets-gtk.cxx 
b/vcl/unx/gtk3/gtk3salnativewidgets-gtk.cxx
index caaa767..ef3e61c 100644
--- a/vcl/unx/gtk3/gtk3salnativewidgets-gtk.cxx
+++ b/vcl/unx/gtk3/gtk3salnativewidgets-gtk.cxx
@@ -284,9 +284,7 @@ static GtkWidget* gDumbContainer;
 static GtkWidget* gSpinBox;
 static GtkWidget* gEntryBox;
 static GtkWidget* gComboBox;
-static GtkWidget* gComboBoxButtonWidget;
 static GtkWidget* gListBox;
-static GtkWidget* gListBoxButtonWidget;
 static GtkWidget* gMenuBarWidget;
 static GtkWidget* gMenuItemMenuBarWidget;
 static GtkWidget* gCheckMenuItemWidget;
@@ -2315,22 +2313,6 @@ void GtkData::deInitNWF()
 gtk_widget_destroy(gCacheWindow);
 }
 
-static void get_combo_box_entry_inner_widgets(GtkWidget *widget, gpointer)
-{
-if (GTK_IS_TOGGLE_BUTTON(widget))
-{
-gComboBoxButtonWidget = widget;
-}
-}
-
-void get_combo_box_inner_button(GtkWidget *widget, gpointer)
-{
-if (GTK_IS_TOGGLE_BUTTON(widget))
-{
-gListBoxButtonWidget = widget;
-}
-}
-
 GtkSalGraphics::GtkSalGraphics( GtkSalFrame *pFrame, GtkWidget *pWindow )
 : SvpSalGraphics(),
   mpFrame( pFrame ),
@@ -2436,21 +2418,13 @@ GtkSalGraphics::GtkSalGraphics( GtkSalFrame *pFrame, 
GtkWidget *pWindow )
 /* Combobox */
 gComboBox = gtk_combo_box_text_new_with_entry();
 getStyleContext(&mpComboboxStyle, gComboBox);
-/* Get ComboBox Entry and Button */
-gtk_container_forall(GTK_CONTAINER(gComboBox),
- get_combo_box_entry_inner_widgets,
- nullptr);
-mpComboboxButtonStyle = 
gtk_widget_get_style_context(gComboBoxButtonWidget);
+mpComboboxButtonStyle = createStyleContext(GtkControlPart::Button, 
mpComboboxStyle);
 
 /* Listbox */
 gListBox = gtk_combo_box_text_new();
 gtk_combo_box_text_append_text(GTK_COMBO_BOX_TEXT(gListBox), "sample");
 getStyleContext(&mpListboxStyle, gListBox);
-/* Get ComboBox Button */
-gtk_container_forall(GTK_CONTAINER(gListBox),
- get_combo_box_inner_button,
- nullptr);
-mpListboxButtonStyle = gtk_widget_get_style_context(gListBoxButtonWidget);
+mpListboxButtonStyle = createStyleContext(GtkControlPart::Button, 
mpListboxStyle);
 
 /* Frames */
 mpFrameOutStyle = mpFrameInStyle = 
createStyleContext(GtkControlPart::FrameBorder);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Caolán McNamara
 sc/source/ui/unoobj/chart2uno.cxx |7 ++-
 vcl/unx/gtk3/gtk3salnativewidgets-gtk.cxx |5 -
 2 files changed, 6 insertions(+), 6 deletions(-)

New commits:
commit 42adbfea50385d5af68040bf67149d0007a1e7bf
Author: Caolán McNamara 
Date:   Thu Apr 7 20:55:51 2016 +0100

don't need gComboBoxEntryWidget anymore

Change-Id: Ia48817eb1476ef6479c3b8e53666e63198cc9310

diff --git a/vcl/unx/gtk3/gtk3salnativewidgets-gtk.cxx 
b/vcl/unx/gtk3/gtk3salnativewidgets-gtk.cxx
index 131ab4d..caaa767 100644
--- a/vcl/unx/gtk3/gtk3salnativewidgets-gtk.cxx
+++ b/vcl/unx/gtk3/gtk3salnativewidgets-gtk.cxx
@@ -285,7 +285,6 @@ static GtkWidget* gSpinBox;
 static GtkWidget* gEntryBox;
 static GtkWidget* gComboBox;
 static GtkWidget* gComboBoxButtonWidget;
-static GtkWidget* gComboBoxEntryWidget;
 static GtkWidget* gListBox;
 static GtkWidget* gListBoxButtonWidget;
 static GtkWidget* gMenuBarWidget;
@@ -2322,10 +2321,6 @@ static void get_combo_box_entry_inner_widgets(GtkWidget 
*widget, gpointer)
 {
 gComboBoxButtonWidget = widget;
 }
-else if (GTK_IS_ENTRY(widget))
-{
-gComboBoxEntryWidget = widget;
-}
 }
 
 void get_combo_box_inner_button(GtkWidget *widget, gpointer)
commit dfa05574ea01eca00f69822f872146f0da5d0303
Author: Caolán McNamara 
Date:   Thu Apr 7 16:48:45 2016 +0100

coverity#1358119 Uninitialized scalar field

arguably a false positive seeing as coverity ignores implicit default ctors 
but
not explicit ones

Change-Id: Id01f6a2728c197239563081c92275d44869b5d96

diff --git a/sc/source/ui/unoobj/chart2uno.cxx 
b/sc/source/ui/unoobj/chart2uno.cxx
index d331f2c..84bbe70 100644
--- a/sc/source/ui/unoobj/chart2uno.cxx
+++ b/sc/source/ui/unoobj/chart2uno.cxx
@@ -148,7 +148,12 @@ struct TokenTable
 TokenTable(const TokenTable&) = delete;
 const TokenTable& operator=(const TokenTable&) = delete;
 
-TokenTable() = default;
+TokenTable()
+: mnRowCount(0)
+, mnColCount(0)
+{
+}
+
 void init( SCCOL nColCount, SCROW nRowCount )
 {
 mnColCount = nColCount;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Stephan Bergmann
 framework/inc/classes/converter.hxx   |2 
 framework/inc/classes/filtercachedata.hxx |   14 +--
 framework/inc/classes/protocolhandlercache.hxx|2 
 framework/inc/stdtypes.h  |   18 
 framework/source/accelerators/presethandler.cxx   |4 -
 framework/source/accelerators/storageholder.cxx   |   20 ++---
 framework/source/fwi/classes/converter.cxx|4 -
 framework/source/fwi/classes/protocolhandlercache.cxx |2 
 framework/source/inc/accelerators/keymapping.hxx  |4 -
 framework/source/inc/accelerators/presethandler.hxx   |4 -
 framework/source/inc/accelerators/storageholder.hxx   |2 
 framework/source/jobs/jobexecutor.cxx |6 -
 framework/source/services/pathsettings.cxx|   70 +-
 13 files changed, 66 insertions(+), 86 deletions(-)

New commits:
commit a0c96b0aa845866ce412427a55a25941712ab3cf
Author: Stephan Bergmann 
Date:   Thu Apr 7 21:50:52 2016 +0200

Remove unused Int32HashCode

Change-Id: I0f43db050155b231dda8f78ed8f8144609c7125b

diff --git a/framework/inc/stdtypes.h b/framework/inc/stdtypes.h
index 0f1f28f..9cc1807 100644
--- a/framework/inc/stdtypes.h
+++ b/framework/inc/stdtypes.h
@@ -38,14 +38,6 @@ namespace framework{
 Own hash functions used for stl-structures ... e.g. hash tables/maps ...
 */
 
-struct Int32HashCode
-{
-size_t operator()( const ::sal_Int32& nValue ) const
-{
-return (size_t)nValue;
-}
-};
-
 struct KeyEventHashCode
 {
 size_t operator()( const css::awt::KeyEvent& aEvent ) const
commit 031d314eae926244246565b401d86396eb5b73d6
Author: Stephan Bergmann 
Date:   Thu Apr 7 21:49:06 2016 +0200

Just use the hash default

Change-Id: Ice2c0cbf382997c2d07cc8cd4a7b085a153fffef

diff --git a/framework/inc/stdtypes.h b/framework/inc/stdtypes.h
index dd0afe9..0f1f28f 100644
--- a/framework/inc/stdtypes.h
+++ b/framework/inc/stdtypes.h
@@ -38,14 +38,6 @@ namespace framework{
 Own hash functions used for stl-structures ... e.g. hash tables/maps ...
 */
 
-struct ShortHashCode
-{
-size_t operator()( const ::sal_Int16& nShort ) const
-{
-return (size_t)nShort;
-}
-};
-
 struct Int32HashCode
 {
 size_t operator()( const ::sal_Int32& nValue ) const
diff --git a/framework/source/inc/accelerators/keymapping.hxx 
b/framework/source/inc/accelerators/keymapping.hxx
index 4edc268..d86917e 100644
--- a/framework/source/inc/accelerators/keymapping.hxx
+++ b/framework/source/inc/accelerators/keymapping.hxx
@@ -55,9 +55,7 @@ class KeyMapping
 typedef std::unordered_map 
Identifier2CodeHash;
 
 /** @short  hash structure to map key codes to identifier. */
-typedef std::unordered_map< sal_Int16,
-OUString  ,
-ShortHashCode > Code2IdentifierHash;
+typedef std::unordered_map Code2IdentifierHash;
 
 // member
 
commit 4be81de0d623571d81c167f326dfb913fdb08df6
Author: Stephan Bergmann 
Date:   Thu Apr 7 21:44:02 2016 +0200

Resolve OUStringList typedef

Change-Id: Ifb5dc5128b5619abb83eea427c7fb1115fd825f3

diff --git a/framework/inc/classes/converter.hxx 
b/framework/inc/classes/converter.hxx
index 3409403..cf8adf1 100644
--- a/framework/inc/classes/converter.hxx
+++ b/framework/inc/classes/converter.hxx
@@ -39,7 +39,7 @@ class FWI_DLLPUBLIC Converter
 static css::uno::Sequence< css::beans::NamedValue >
convert_seqPropVal2seqNamedVal  ( const css::uno::Sequence< 
css::beans::PropertyValue >& lSource );
 
 // Seq => Vector
-static OUStringList
convert_seqOUString2OUStringList( const css::uno::Sequence< OUString >& 
  lSource );
+static std::vector convert_seqOUString2OUStringList( const 
css::uno::Sequence< OUString >&   lSource );
 
 static OUString 
convert_DateTime2ISO8601( const DateTime&   
 aSource );
 };
diff --git a/framework/inc/classes/filtercachedata.hxx 
b/framework/inc/classes/filtercachedata.hxx
index e16b73a..5f7f6a3 100644
--- a/framework/inc/classes/filtercachedata.hxx
+++ b/framework/inc/classes/filtercachedata.hxx
@@ -113,8 +113,8 @@ struct FileType
 OUStringsMediaType;
 OUStringsClipboardFormat;
 sal_Int32   nDocumentIconID;
-OUStringListlURLPattern;
-OUStringListlExtensions;
+std::vector lURLPattern;
+std::vector lExtensions;
 };
 
 // These struct describe a filter which is registered for one type.
@@ -179,7 +179,7 @@ struct Filter
 OUString sFilterService;
 OUString sUIComponent;
 sal_Int32   nFlags;
-OUStringListlUserData;
+std::vector lUserData;
 sal_Int32

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

2016-04-07 Thread Stephan Bergmann
 framework/inc/classes/filtercachedata.hxx |   12 ++--
 framework/inc/stdtypes.h  |6 --
 2 files changed, 6 insertions(+), 12 deletions(-)

New commits:
commit 02041335d89cfb23b59218c9201ff16baf423b81
Author: Stephan Bergmann 
Date:   Thu Apr 7 21:32:41 2016 +0200

vector::clear is just fine

Change-Id: I5d8ec98d437913861b584cf3077618a2d6b0a0be

diff --git a/framework/inc/classes/filtercachedata.hxx 
b/framework/inc/classes/filtercachedata.hxx
index 928ce99..e16b73a 100644
--- a/framework/inc/classes/filtercachedata.hxx
+++ b/framework/inc/classes/filtercachedata.hxx
@@ -86,8 +86,8 @@ struct FileType
 sClipboardFormat.clear();
 nDocumentIconID = 0;
 lUINames.clear();
-framework::free(lURLPattern);
-framework::free(lExtensions);
+lURLPattern.clear();
+lExtensions.clear();
 }
 
 inline FileType& impl_copy( const FileType& rCopy )
@@ -148,7 +148,7 @@ struct Filter
 nFileFormatVersion  = 0;
 sTemplateName.clear();
 lUINames.clear();
-framework::free(lUserData);
+lUserData.clear();
 }
 
 inline Filter& impl_copy( const Filter& rCopy )
@@ -205,7 +205,7 @@ struct Detector
 inline void impl_clear()
 {
 sName.clear();
-framework::free(lTypes);
+lTypes.clear();
 }
 
 inline Detector& impl_copy( const Detector& rCopy )
@@ -245,7 +245,7 @@ struct Loader
 {
 sName.clear();
 lUINames.clear();
-framework::free(lTypes);
+lTypes.clear();
 }
 
 inline Loader& impl_copy( const Loader& rCopy )
@@ -285,7 +285,7 @@ struct ContentHandler
 inline void impl_clear()
 {
 sName.clear();
-framework::free(lTypes);
+lTypes.clear();
 }
 
 inline ContentHandler& impl_copy( const ContentHandler& rCopy )
diff --git a/framework/inc/stdtypes.h b/framework/inc/stdtypes.h
index b87247e..c58c2b7 100644
--- a/framework/inc/stdtypes.h
+++ b/framework/inc/stdtypes.h
@@ -81,12 +81,6 @@ struct KeyEventEqualsFunc
 
 typedef ::std::vector< OUString > OUStringList;
 
-template 
-void free(std::vector& vec)
-{
-OUStringList().swap(vec);
-}
-
 /**
 Basic OUString hash.
 Key and values are OUStrings.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Stephan Bergmann
 framework/inc/classes/protocolhandlercache.hxx |2 --
 1 file changed, 2 deletions(-)

New commits:
commit b24937c11477af44789c3c80d1d79a966895dc44
Author: Stephan Bergmann 
Date:   Thu Apr 7 21:21:10 2016 +0200

Remove junk that erroneously remained in previous commit

Change-Id: I18ca0d4daf44eafe88d6f812fa17576edbfb8dfd

diff --git a/framework/inc/classes/protocolhandlercache.hxx 
b/framework/inc/classes/protocolhandlercache.hxx
index 61896c2..930ce17 100644
--- a/framework/inc/classes/protocolhandlercache.hxx
+++ b/framework/inc/classes/protocolhandlercache.hxx
@@ -61,8 +61,6 @@ struct FWI_DLLPUBLIC ProtocolHandler
 to search for a key by using a full qualified URL on list of all possible 
pattern keys.
 */
 typedef std::unordered_map PatternHash;
-FWI_DLLPUBLIC PatternHash::iterator findPatternKey(
-PatternHash const & hash, const OUString& sURL);
 
 /**
 This hash holds protocol handler structs by her names.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Stephan Bergmann
 framework/inc/classes/protocolhandlercache.hxx|   10 +++---
 framework/source/fwi/classes/protocolhandlercache.cxx |   12 
 2 files changed, 11 insertions(+), 11 deletions(-)

New commits:
commit 9a2dea064082465ba912391f637d4710ad355a64
Author: Stephan Bergmann 
Date:   Thu Apr 7 21:15:55 2016 +0200

dllexport class deriving from template means trouble with MSVC

Change-Id: I9d170168eac26c52fd6ca8d22124e8ff78b81226

diff --git a/framework/inc/classes/protocolhandlercache.hxx 
b/framework/inc/classes/protocolhandlercache.hxx
index cb9c66a..61896c2 100644
--- a/framework/inc/classes/protocolhandlercache.hxx
+++ b/framework/inc/classes/protocolhandlercache.hxx
@@ -60,13 +60,9 @@ struct FWI_DLLPUBLIC ProtocolHandler
 uno implementation names as value. Overloading of the index operator makes 
it possible
 to search for a key by using a full qualified URL on list of all possible 
pattern keys.
 */
-class FWI_DLLPUBLIC PatternHash : public std::unordered_map
-{
-/* interface */
-public:
-
-PatternHash::iterator findPatternKey( const OUString& sURL );
-};
+typedef std::unordered_map PatternHash;
+FWI_DLLPUBLIC PatternHash::iterator findPatternKey(
+PatternHash const & hash, const OUString& sURL);
 
 /**
 This hash holds protocol handler structs by her names.
diff --git a/framework/source/fwi/classes/protocolhandlercache.cxx 
b/framework/source/fwi/classes/protocolhandlercache.cxx
index ef48ef0..20b26f4 100644
--- a/framework/source/fwi/classes/protocolhandlercache.cxx
+++ b/framework/source/fwi/classes/protocolhandlercache.cxx
@@ -49,10 +49,12 @@ namespace framework{
 @return An iterator which points to the found item inside the hash or 
PatternHash::end()
 if no pattern match this given sURL.
  */
-PatternHash::iterator PatternHash::findPatternKey( const OUString& sURL )
+namespace {
+
+PatternHash::const_iterator findPatternKey(PatternHash const * hash, const 
OUString& sURL)
 {
-PatternHash::iterator pItem = this->begin();
-while( pItem!=this->end() )
+auto pItem = hash->begin();
+while( pItem!=hash->end() )
 {
 WildCard aPattern(pItem->first);
 if (aPattern.Matches(sURL))
@@ -62,6 +64,8 @@ PatternHash::iterator PatternHash::findPatternKey( const 
OUString& sURL )
 return pItem;
 }
 
+}
+
 /**
 @short  initialize static member of class HandlerCache
 @descr  We use a singleton pattern to implement this handler cache.
@@ -131,7 +135,7 @@ bool HandlerCache::search( const OUString& sURL, 
ProtocolHandler* pReturn ) cons
 
 SolarMutexGuard aGuard;
 
-PatternHash::const_iterator pItem = m_pPattern->findPatternKey(sURL);
+PatternHash::const_iterator pItem = findPatternKey(m_pPattern, sURL);
 if (pItem!=m_pPattern->end())
 {
 *pReturn = (*m_pHandler)[pItem->second];
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Michael Meeks
 loolwsd/test/UnitPrefork.cpp |   15 +--
 loolwsd/test/run_unit.sh |4 ++--
 2 files changed, 15 insertions(+), 4 deletions(-)

New commits:
commit 8d7a26547912b35b94d65f6bdd06baa9bea74289
Author: Michael Meeks 
Date:   Thu Apr 7 20:15:18 2016 +0100

Print preload time.

diff --git a/loolwsd/test/UnitPrefork.cpp b/loolwsd/test/UnitPrefork.cpp
index 6bca7b9..4133468 100644
--- a/loolwsd/test/UnitPrefork.cpp
+++ b/loolwsd/test/UnitPrefork.cpp
@@ -10,13 +10,19 @@
 #include 
 #include 
 #include 
+#include 
+
 #include "Util.hpp"
 #include "Unit.hpp"
 
+#include 
+using Poco::Timestamp;
+
 class UnitPrefork : public UnitHooks
 {
 int _numStarted;
 const int _numToPrefork;
+Timestamp _startTime;
 public:
 UnitPrefork()
 : _numStarted(0),
@@ -26,14 +32,19 @@ public:
 virtual void preSpawnCount(int &numPrefork) override
 {
 numPrefork = _numToPrefork;
-Log::error("Hello world");
 }
-
 virtual void newChild() override
 {
 _numStarted++;
 if (_numStarted >= _numToPrefork + 1)
+{
 exitTest(TestResult::TEST_OK);
+
+Poco::Timestamp::TimeDiff elapsed = _startTime.elapsed();
+
+std::cout << "Launched " << _numStarted << " in "
+  << (1.0 * elapsed)/Poco::Timestamp::resolution() << 
std::endl;
+}
 }
 };
 
diff --git a/loolwsd/test/run_unit.sh b/loolwsd/test/run_unit.sh
index 8f2a79a..8c67750 100755
--- a/loolwsd/test/run_unit.sh
+++ b/loolwsd/test/run_unit.sh
@@ -9,8 +9,8 @@ echo > run_unit.sh.trs
 
 for tst in prefork; do
 tst_log="test_output/$tst.log"
-echo "Running test: $tst | $tst_log";
-if ../loolwsd --systemplate=${systemplate} --lotemplate="${LO_PATH}" 
--childroot="${jails}" --unitlib=".libs/unit-$tst.so" >& "$tst_log"; then
+echo "Running test: $tst | $tst_log ...";
+if ../loolwsd --systemplate=${systemplate} --lotemplate="${LO_PATH}" 
--childroot="${jails}" --unitlib=".libs/unit-$tst.so" 2> "$tst_log"; then
echo "Test $tst passed."
echo ":test-result: PASS $tst" >> run_unit.sh.trs
 else
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Markus Mohrhard
 sc/qa/unit/data/xls/validation.xls |binary
 sc/qa/unit/subsequent_filters-test.cxx |   31 +++
 2 files changed, 31 insertions(+)

New commits:
commit 8b9207f49f436a886bcb94ae902e16c47484b3cb
Author: Markus Mohrhard 
Date:   Thu Apr 7 21:11:04 2016 +0200

add test for tdf#99093

Change-Id: Id47abea42867f418e80a40357baa5f6435ecbdd6

diff --git a/sc/qa/unit/data/xls/validation.xls 
b/sc/qa/unit/data/xls/validation.xls
new file mode 100644
index 000..46bbbf7
Binary files /dev/null and b/sc/qa/unit/data/xls/validation.xls differ
diff --git a/sc/qa/unit/subsequent_filters-test.cxx 
b/sc/qa/unit/subsequent_filters-test.cxx
index efd1859..8106d21 100644
--- a/sc/qa/unit/subsequent_filters-test.cxx
+++ b/sc/qa/unit/subsequent_filters-test.cxx
@@ -206,6 +206,7 @@ public:
 void testEditEngStrikeThroughXLSX();
 void testRefStringXLSX();
 void testHiddenSheetsXLSX();
+void testRelFormulaValidationXLS();
 
 void testBnc762542();
 
@@ -304,6 +305,7 @@ public:
 CPPUNIT_TEST(testErrorOnExternalReferences);
 CPPUNIT_TEST(testEditEngStrikeThroughXLSX);
 CPPUNIT_TEST(testRefStringXLSX);
+CPPUNIT_TEST(testRelFormulaValidationXLS);
 
 CPPUNIT_TEST(testBnc762542);
 
@@ -3197,6 +3199,35 @@ void ScFiltersTest::testHiddenSheetsXLSX()
 xDocSh->DoClose();
 }
 
+namespace {
+
+void checkValidationFormula(const ScAddress& rPos, ScDocument& rDoc, const 
OUString& rExpectedFormula)
+{
+const SfxUInt32Item* pItem = static_cast(rDoc.GetAttr(rPos, ATTR_VALIDDATA) );
+CPPUNIT_ASSERT(pItem);
+sal_uLong nKey = pItem->GetValue();
+const ScValidationData* pData = rDoc.GetValidationEntry(nKey);
+CPPUNIT_ASSERT(pData);
+
+OUString aFormula = pData->GetExpression(rPos, 0);
+CPPUNIT_ASSERT_EQUAL(rExpectedFormula, aFormula);
+}
+
+}
+
+void ScFiltersTest::testRelFormulaValidationXLS()
+{
+ScDocShellRef xDocSh = loadDoc("validation.", FORMAT_XLS);
+CPPUNIT_ASSERT_MESSAGE("Failed to open doc", xDocSh.Is());
+
+ScDocument& rDoc = xDocSh->GetDocument();
+
+checkValidationFormula(ScAddress(3, 4, 0), rDoc, "Sheet1.C5");
+checkValidationFormula(ScAddress(5, 8, 0), rDoc, "Sheet1.D7");
+
+xDocSh->DoClose();
+}
+
 ScFiltersTest::ScFiltersTest()
   : ScBootstrapFixture( "sc/qa/unit/data" )
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: 6 commits - loleaflet/.gitignore loolwsd/configure.ac loolwsd/.gitignore loolwsd/LOOLKit.hpp loolwsd/LOOLWSD.cpp loolwsd/Makefile.am loolwsd/test loolwsd/Unit.cpp loo

2016-04-07 Thread Michael Meeks
 loleaflet/.gitignore |1 
 loolwsd/.gitignore   |   44 +++-
 loolwsd/LOOLKit.hpp  |1 
 loolwsd/LOOLWSD.cpp  |   31 --
 loolwsd/Makefile.am  |4 +
 loolwsd/Unit.cpp |   90 ++
 loolwsd/Unit.hpp |   53 +
 loolwsd/Util.cpp |   91 ---
 loolwsd/configure.ac |   37 +
 loolwsd/test/.gitignore  |   10 ++--
 loolwsd/test/Makefile.am |   50 ++-
 loolwsd/test/UnitPrefork.cpp |   45 +
 loolwsd/test/run_unit.sh |   25 +++
 13 files changed, 430 insertions(+), 52 deletions(-)

New commits:
commit cd47b5e044893994a534c7b94b3fa11b87cfaeca
Author: Michael Meeks 
Date:   Thu Apr 7 17:43:26 2016 +0100

Signal safe signal handlers.

diff --git a/loolwsd/Util.cpp b/loolwsd/Util.cpp
index 2d73562..678b1d7 100644
--- a/loolwsd/Util.cpp
+++ b/loolwsd/Util.cpp
@@ -18,6 +18,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 
@@ -89,6 +90,8 @@ namespace rng
 }
 }
 
+static char LogPrefix[256] = { '\0' };
+
 namespace Log
 {
 static const Poco::Int64 epochStart = 
Poco::Timestamp().epochMicroseconds();
@@ -135,7 +138,6 @@ namespace Log
 return stream.str();
 }
 
-
 void initialize(const std::string& name)
 {
 Source.name = name;
@@ -143,6 +145,8 @@ namespace Log
 oss << Source.name << '-'
 << std::setw(5) << std::setfill('0') << Poco::Process::id();
 Source.id = oss.str();
+assert (sizeof (LogPrefix) > strlen(oss.str().c_str()) + 1);
+strcpy(LogPrefix, oss.str().c_str());
 
 auto channel = (isatty(fileno(stdout)) || std::getenv("LOOL_LOGCOLOR")
  ? static_cast(new 
Poco::ColorConsoleChannel())
@@ -356,19 +360,38 @@ namespace Util
 }
 }
 
+// We need a signal safe means of writing messages
+//   $ man 7 signal
+static
+void log_signal(const char *message)
+{
+while (true) {
+int length = strlen(message);
+int written = write (STDERR_FILENO, message, length);
+if (written < 0)
+{
+if (errno == EINTR)
+continue; // ignore.
+else
+break;
+}
+message += written;
+if (message[0] == '\0')
+break;
+}
+}
+
 static
 void handleTerminationSignal(const int signal)
 {
 if (!TerminationFlag)
 {
-// Poco::Log takes a lock that isn't recursive.
-// If we are signaled while having that lock,
-// logging again will deadlock on it.
 TerminationFlag = true;
 
-Log::info() << "Termination signal received: "
-<< Util::signalName(signal) << " "
-<< strsignal(signal) << Log::end;
+log_signal(LogPrefix);
+log_signal(" Termination signal received: ");
+log_signal(strsignal(signal));
+log_signal("\n");
 }
 }
 
@@ -386,19 +409,19 @@ namespace Util
 sigaction(SIGHUP, &action, nullptr);
 }
 
+static char FatalGdbString[256] = { '\0' };
+
 static
 void handleFatalSignal(const int signal)
 {
-Log::error() << "Fatal signal received: "
- << Util::signalName(signal) << " "
- << strsignal(signal) << Log::end;
+log_signal(LogPrefix);
+log_signal(" Fatal signal received: ");
+log_signal(strsignal(signal));
+log_signal("\n");
 
 if (std::getenv("LOOL_DEBUG"))
 {
-Log::error() << "\nFatal signal! Attach debugger with:\n"
- << "sudo gdb --pid=" << Poco::Process::id() << "\n or 
\n"
- << "sudo gdb --q --n --ex 'thread apply all backtrace 
full' --batch --pid="
- << Poco::Process::id() << "\n" << Log::end;
+log_signal(FatalGdbString);
 sleep(30);
 }
 
@@ -426,6 +449,16 @@ namespace Util
 sigaction(SIGABRT, &action, NULL);
 sigaction(SIGILL, &action, NULL);
 sigaction(SIGFPE, &action, NULL);
+
+// prepare this in advance just in case.
+std::ostringstream stream;
+stream << "\nFatal signal! Attach debugger with:\n"
+   << "sudo gdb --pid=" << Poco::Process::id() << "\n or \n"
+   << "sudo gdb --q --n --ex 'thread apply all backtrace full' 
--batch --pid="
+   << Poco::Process::id() << "\n";
+std::string streamStr = stream.str();
+assert (sizeof (FatalGdbString) > strlen(streamStr.c_str()) + 1);
+strcpy(FatalGdbString, streamStr.c_str());
 }
 
 int getChildStatus(const int code)
commit a454a3c407825cf5ab

[Libreoffice-commits] online.git: 8 commits - loolwsd/Admin.cpp loolwsd/ChildProcessSession.cpp loolwsd/Common.hpp loolwsd/IoUtil.cpp loolwsd/IoUtil.hpp loolwsd/LOOLKit.cpp loolwsd/LOOLWSD.cpp

2016-04-07 Thread Tor Lillqvist
 loolwsd/Admin.cpp   |7 +
 loolwsd/ChildProcessSession.cpp |4 ---
 loolwsd/Common.hpp  |1 
 loolwsd/IoUtil.cpp  |   50 
 loolwsd/IoUtil.hpp  |7 -
 loolwsd/LOOLKit.cpp |   14 ---
 loolwsd/LOOLWSD.cpp |   23 +-
 7 files changed, 27 insertions(+), 79 deletions(-)

New commits:
commit c71d12ae63b43636f9424632a9132305036c1d26
Author: Tor Lillqvist 
Date:   Thu Apr 7 20:22:32 2016 +0300

Process name and id are already part of each logging output line

diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index 5dee1a9..50637ec 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -1005,7 +1005,7 @@ void lokit_main(const std::string& childRoot,
 std::exit(Application::EXIT_SOFTWARE);
 }
 
-Log::info("loolkit [" + std::to_string(Process::id()) + "] is ready.");
+Log::info("Process is ready.");
 
 // Open websocket connection between the child process and WSD.
 HTTPClientSession cs("127.0.0.1", MASTER_PORT_NUMBER);
commit 557ca90be14b495a27007883038f951426ee6b3e
Author: Tor Lillqvist 
Date:   Thu Apr 7 20:18:22 2016 +0300

Remove unused IoUtil::readMessage()

diff --git a/loolwsd/IoUtil.cpp b/loolwsd/IoUtil.cpp
index 871f0dd..35a8e24 100644
--- a/loolwsd/IoUtil.cpp
+++ b/loolwsd/IoUtil.cpp
@@ -244,27 +244,6 @@ ssize_t readFIFO(int pipe, char* buffer, ssize_t size)
 return bytes;
 }
 
-ssize_t readMessage(const int pipe, char* buffer, const ssize_t size, const 
size_t timeoutSec)
-{
-struct pollfd pollPipe;
-
-pollPipe.fd = pipe;
-pollPipe.events = POLLIN;
-pollPipe.revents = 0;
-
-const int nPoll = poll(&pollPipe, 1, timeoutSec * 1000);
-if ( nPoll < 0 )
-return -1;
-
-if ( nPoll == 0 )
-errno = ETIME;
-
-if( (pollPipe.revents & POLLIN) != 0 )
-return readFIFO(pipe, buffer, size);
-
-return -1;
-}
-
 /// Reads a single line from a pipe.
 /// Returns 0 for timeout, <0 for error, and >0 on success.
 /// On success, line will contain the read message.
diff --git a/loolwsd/IoUtil.hpp b/loolwsd/IoUtil.hpp
index c01e814..4ad06f5 100644
--- a/loolwsd/IoUtil.hpp
+++ b/loolwsd/IoUtil.hpp
@@ -40,9 +40,6 @@ namespace IoUtil
 
 ssize_t readFIFO(int pipe, char* buffer, ssize_t size);
 
-ssize_t readMessage(const int pipe, char* buffer, const ssize_t size,
-const size_t timeoutSec = CHILD_TIMEOUT_SECS);
-
 class PipeReader
 {
 public:
commit 16034f66853947b309a610c49779466e68b56f50
Author: Tor Lillqvist 
Date:   Thu Apr 7 20:09:35 2016 +0300

Bin unused INTERVAL_PROBES

diff --git a/loolwsd/Common.hpp b/loolwsd/Common.hpp
index 89e780b..1423251 100644
--- a/loolwsd/Common.hpp
+++ b/loolwsd/Common.hpp
@@ -18,7 +18,6 @@ constexpr int MAX_SESSIONS = 1024;
 
 constexpr int DEFAULT_CLIENT_PORT_NUMBER = 9980;
 constexpr int MASTER_PORT_NUMBER = 9981;
-constexpr int INTERVAL_PROBES = 10;
 constexpr int MAINTENANCE_INTERVAL = 1;
 constexpr int CHILD_TIMEOUT_SECS = 10;
 constexpr int POLL_TIMEOUT_MS = 1000;
commit 4ed3393f164fd55f6c4ff9a227cbb5972600966d
Author: Tor Lillqvist 
Date:   Thu Apr 7 20:03:26 2016 +0300

Nothing ever passed for the pollTimeoutMs parameter so use the default 
value in-line

diff --git a/loolwsd/IoUtil.cpp b/loolwsd/IoUtil.cpp
index 632d2bc..871f0dd 100644
--- a/loolwsd/IoUtil.cpp
+++ b/loolwsd/IoUtil.cpp
@@ -40,13 +40,12 @@ namespace IoUtil
 void SocketProcessor(std::shared_ptr ws,
  Poco::Net::HTTPResponse& response,
  std::function&)> handler,
- std::function stopPredicate,
- const size_t pollTimeoutMs)
+ std::function stopPredicate)
 {
 Log::info("SocketProcessor starting.");
 
 // Timeout given is in microseconds.
-const Poco::Timespan waitTime(pollTimeoutMs * 1000);
+const Poco::Timespan waitTime(POLL_TIMEOUT_MS * 1000);
 try
 {
 ws->setReceiveTimeout(0);
diff --git a/loolwsd/IoUtil.hpp b/loolwsd/IoUtil.hpp
index 42b1f8c..c01e814 100644
--- a/loolwsd/IoUtil.hpp
+++ b/loolwsd/IoUtil.hpp
@@ -26,8 +26,7 @@ namespace IoUtil
 void SocketProcessor(std::shared_ptr ws,
  Poco::Net::HTTPResponse& response,
  std::function&)> handler,
- std::function stopPredicate,
- const size_t pollTimeoutMs = POLL_TIMEOUT_MS);
+ std::function stopPredicate);
 
 /// Call WebSocket::shutdown() ignoring Poco::IOException.
 void shutdownWebSocket(std::shared_ptr ws);
commit 584a8057813f1354238ae2d4f998be9a9004ec8e
Author: Tor Lillqvist 
Date:   Thu Apr 7 20:00:57 2016 +0300

The SocketProcessor() 'name' parameter can now be dropped

diff --git a/loolwsd/IoUtil.cpp b/loolwsd/IoUtil.cpp
index 081d410..632d2bc 100644
--- a/loolwsd/IoU

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

2016-04-07 Thread Stephan Bergmann
 framework/inc/classes/filtercachedata.hxx |6 ++--
 framework/inc/classes/protocolhandlercache.hxx|4 +-
 framework/inc/stdtypes.h  |   21 --
 framework/inc/uiconfiguration/graphicnameaccess.hxx   |2 -
 framework/inc/uielement/commandinfo.hxx   |2 -
 framework/inc/uielement/toolbarmanager.hxx|2 -
 framework/source/dispatch/dispatchinformationprovider.cxx |7 ++--
 framework/source/fwi/classes/protocolhandlercache.cxx |4 --
 framework/source/inc/accelerators/acceleratorcache.hxx|2 -
 framework/source/inc/accelerators/keymapping.hxx  |2 -
 framework/source/services/frame.cxx   |4 +-
 framework/source/services/pathsettings.cxx|2 -
 12 files changed, 17 insertions(+), 41 deletions(-)

New commits:
commit f57c9921de4d64fbe27e80e2e7c13dea23853089
Author: Stephan Bergmann 
Date:   Thu Apr 7 18:14:32 2016 +0200

Get rid of BaseHash wrapper (to unbreak Windows build)

Change-Id: Ieae7d6af7a4753958ebf2aeae9d2ae6fafe5efe9

diff --git a/framework/inc/classes/filtercachedata.hxx 
b/framework/inc/classes/filtercachedata.hxx
index f671678..928ce99 100644
--- a/framework/inc/classes/filtercachedata.hxx
+++ b/framework/inc/classes/filtercachedata.hxx
@@ -85,7 +85,7 @@ struct FileType
 sMediaType.clear();
 sClipboardFormat.clear();
 nDocumentIconID = 0;
-lUINames.free   ();
+lUINames.clear();
 framework::free(lURLPattern);
 framework::free(lExtensions);
 }
@@ -147,7 +147,7 @@ struct Filter
 nFlags  = 0;
 nFileFormatVersion  = 0;
 sTemplateName.clear();
-lUINames.free();
+lUINames.clear();
 framework::free(lUserData);
 }
 
@@ -244,7 +244,7 @@ struct Loader
 inline void impl_clear()
 {
 sName.clear();
-lUINames.free();
+lUINames.clear();
 framework::free(lTypes);
 }
 
diff --git a/framework/inc/classes/protocolhandlercache.hxx 
b/framework/inc/classes/protocolhandlercache.hxx
index 9537677..cb9c66a 100644
--- a/framework/inc/classes/protocolhandlercache.hxx
+++ b/framework/inc/classes/protocolhandlercache.hxx
@@ -60,7 +60,7 @@ struct FWI_DLLPUBLIC ProtocolHandler
 uno implementation names as value. Overloading of the index operator makes 
it possible
 to search for a key by using a full qualified URL on list of all possible 
pattern keys.
 */
-class FWI_DLLPUBLIC PatternHash : public BaseHash< OUString >
+class FWI_DLLPUBLIC PatternHash : public std::unordered_map
 {
 /* interface */
 public:
@@ -71,7 +71,7 @@ class FWI_DLLPUBLIC PatternHash : public BaseHash< OUString >
 /**
 This hash holds protocol handler structs by her names.
 */
-typedef BaseHash< ProtocolHandler > HandlerHash;
+typedef std::unordered_map 
HandlerHash;
 
 /**
 @short  this hash makes it easy to find a protocol handler by 
using his uno implementation name.
diff --git a/framework/inc/stdtypes.h b/framework/inc/stdtypes.h
index 407ecfa..b87247e 100644
--- a/framework/inc/stdtypes.h
+++ b/framework/inc/stdtypes.h
@@ -88,29 +88,10 @@ void free(std::vector& vec)
 }
 
 /**
-Basic hash based on a std::unordered_map() which provides key=[OUString] 
and value=[template type] pairs
-It implements some additional funtionality which can be useful but
-is missing at the normal hash implementation.
-*/
-template< class TType >
-class BaseHash : public std::unordered_map< OUString,
-TType  
,
-OUStringHash >
-{
-public:
-
-// the only way to free used memory really!
-void free()
-{
-BaseHash().swap( *this );// get rid of reserved capacity
-}
-};
-
-/**
 Basic OUString hash.
 Key and values are OUStrings.
 */
-typedef BaseHash< OUString > OUStringHashMap;
+typedef std::unordered_map OUStringHashMap;
 
 /**
 It can be used to map names (e.g. of properties) to her corresponding 
handles.
diff --git a/framework/inc/uiconfiguration/graphicnameaccess.hxx 
b/framework/inc/uiconfiguration/graphicnameaccess.hxx
index b299b84..b18ab5c 100644
--- a/framework/inc/uiconfiguration/graphicnameaccess.hxx
+++ b/framework/inc/uiconfiguration/graphicnameaccess.hxx
@@ -52,7 +52,7 @@ namespace framework
 throw(css::uno::RuntimeException, std::exception) override;
 
 private:
-typedef BaseHash< css::uno::Reference< css::graphic::XGraphic > > 
NameGraphicHashMap;
+typedef std::unordered_map, OUStringHash> NameGraphicHashMap;
 NameGraphicHashMap  m_aNameToElementMap;
 css::uno::Sequence< OUString >  m_aSeq;
 

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

2016-04-07 Thread Miklos Vajna
 writerfilter/source/dmapper/PropertyMap.cxx |   55 ++--
 writerfilter/source/dmapper/PropertyMap.hxx |3 +
 2 files changed, 39 insertions(+), 19 deletions(-)

New commits:
commit d56deaeb2a1e8007e50fc2334f416fddd4e3cde3
Author: Miklos Vajna 
Date:   Thu Apr 7 16:47:23 2016 +0200

tdf#99140 Factor out FloatingTableConversion() from CloseSectionGroup()

No logic changes intended, but makes it easier to add new rules when
making the decision.

Change-Id: I84d8e6a2b8a4b9ae6fe5cefd381292c2f68be45f
Reviewed-on: https://gerrit.libreoffice.org/23901
Reviewed-by: Miklos Vajna 
Tested-by: Jenkins 

diff --git a/writerfilter/source/dmapper/PropertyMap.cxx 
b/writerfilter/source/dmapper/PropertyMap.cxx
index 56e99b6..ff8e5f3 100644
--- a/writerfilter/source/dmapper/PropertyMap.cxx
+++ b/writerfilter/source/dmapper/PropertyMap.cxx
@@ -1038,34 +1038,51 @@ void 
SectionPropertyMap::HandleMarginsHeaderFooter(DomainMapper_Impl& rDM_Impl)
 PrepareHeaderFooterProperties( false );
 }
 
+bool SectionPropertyMap::FloatingTableConversion(FloatingTableInfo& rInfo)
+{
+// Note that this is just a list of heuristics till sw core can have a
+// table that is floating and can span over multiple pages at the same
+// time.
+
+sal_Int32 nTextAreaWidth = GetPageWidth() - GetLeftMargin() - 
GetRightMargin();
+// Count the layout width of the table.
+sal_Int32 nTableWidth = rInfo.m_nTableWidth;
+sal_Int32 nLeftMargin = 0;
+if (rInfo.getPropertyValue("LeftMargin") >>= nLeftMargin)
+nTableWidth += nLeftMargin;
+sal_Int32 nRightMargin = 0;
+if (rInfo.getPropertyValue("RightMargin") >>= nRightMargin)
+nTableWidth += nRightMargin;
+
+// If the table is wider than the text area, then don't create a fly
+// for the table: no wrapping will be performed anyway, but multi-page
+// tables will be broken.
+if (nTableWidth < nTextAreaWidth)
+return true;
+
+// If the position is relative to the edge of the page, then we always
+// create the fly.
+if (rInfo.getPropertyValue("HoriOrientRelation") == 
text::RelOrientation::PAGE_FRAME)
+return true;
+
+// If there are columns, always create the fly, otherwise the columns would
+// restrict geometry of the table.
+if (ColumnCount() + 1 >= 2)
+return true;
+
+return false;
+}
+
 void SectionPropertyMap::CloseSectionGroup( DomainMapper_Impl& rDM_Impl )
 {
 // Text area width is known at the end of a section: decide if tables 
should be converted or not.
 std::vector& rPendingFloatingTables = 
rDM_Impl.m_aPendingFloatingTables;
-sal_Int32 nTextAreaWidth = GetPageWidth() - GetLeftMargin() - 
GetRightMargin();
 uno::Reference xBodyText( 
rDM_Impl.GetBodyText(), uno::UNO_QUERY );
 for (size_t i = 0; i < rPendingFloatingTables.size(); ++i)
 {
 FloatingTableInfo& rInfo = rPendingFloatingTables[i];
 
-// Count the layout width of the table.
-sal_Int32 nTableWidth = rInfo.m_nTableWidth;
-sal_Int32 nLeftMargin = 0;
-if (rInfo.getPropertyValue("LeftMargin") >>= nLeftMargin)
-nTableWidth += nLeftMargin;
-sal_Int32 nRightMargin = 0;
-if (rInfo.getPropertyValue("RightMargin") >>= nRightMargin)
-nTableWidth += nRightMargin;
-
-// If the table is wider than the text area, then don't create a fly
-// for the table: no wrapping will be performed anyway, but multi-page
-// tables will be broken.
-// If the position is relative to the edge of the page, then we always
-// create the fly.
-// If there are columns, always create the fly, otherwise the columns 
would
-// restrict geometry of the table.
-if ( ( rInfo.getPropertyValue("HoriOrientRelation") == 
text::RelOrientation::PAGE_FRAME ) ||
- nTableWidth < nTextAreaWidth || ColumnCount() + 1 >= 2 )
+if (FloatingTableConversion(rInfo))
 xBodyText->convertToTextFrame(rInfo.m_xStart, rInfo.m_xEnd, 
rInfo.m_aFrameProperties);
 }
 rPendingFloatingTables.clear();
diff --git a/writerfilter/source/dmapper/PropertyMap.hxx 
b/writerfilter/source/dmapper/PropertyMap.hxx
index a3a9be1..ac2b8b5 100644
--- a/writerfilter/source/dmapper/PropertyMap.hxx
+++ b/writerfilter/source/dmapper/PropertyMap.hxx
@@ -57,6 +57,7 @@ namespace com{namespace sun{namespace star{
 namespace writerfilter {
 namespace dmapper{
 class DomainMapper_Impl;
+struct FloatingTableInfo;
 
 enum BorderPosition
 {
@@ -267,6 +268,8 @@ class SectionPropertyMap : public PropertyMap
sal_Int32 nDistance,
sal_Int32 nOffsetFrom,
sal_uInt32 nLineWidth);
+/// Determintes if conversion of a given floating table is wanted or not.
+bool FloatingTableConversion(FloatingTableInfo& rInfo);
 
 public:
 explicit SectionPropertyMap(bool bIsFirst

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

2016-04-07 Thread Marco Cecchetti
 vcl/win/gdi/winlayout.cxx |   11 ++-
 1 file changed, 10 insertions(+), 1 deletion(-)

New commits:
commit 92e33ae10d63b5acd8643d33c032dbb022bd75be
Author: Marco Cecchetti 
Date:   Thu Apr 7 12:10:29 2016 +0200

tdf#98710 - catch exception due to crash in dwrite

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

diff --git a/vcl/win/gdi/winlayout.cxx b/vcl/win/gdi/winlayout.cxx
index 12df505..1ee9d02 100644
--- a/vcl/win/gdi/winlayout.cxx
+++ b/vcl/win/gdi/winlayout.cxx
@@ -4002,7 +4002,16 @@ bool D2DWriteTextOutRenderer::DrawGlyphs(const Point & 
origin, uint16_t * pGid,
 
 bool D2DWriteTextOutRenderer::GetDWriteFaceFromHDC(HDC hDC, IDWriteFontFace ** 
ppFontFace, float * lfSize) const
 {
-bool const succeeded = SUCCEEDED(mpGdiInterop->CreateFontFaceFromHdc(hDC, 
ppFontFace));
+bool succeeded = false;
+try
+{
+succeeded = SUCCEEDED(mpGdiInterop->CreateFontFaceFromHdc(hDC, 
ppFontFace));
+}
+catch (const std::exception& e)
+{
+SAL_WARN("vcl.gdi.opengl", "Error in dwrite while creating font face: 
" << e.what());
+return false;
+}
 
 if (succeeded)
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: framework/inc framework/Library_fwi.mk framework/source

2016-04-07 Thread Stephan Bergmann
 framework/Library_fwi.mk   |1 
 framework/inc/classes/propertysethelper.hxx|  193 -
 framework/source/fwi/classes/propertysethelper.cxx |  338 -
 framework/source/services/frame.cxx|  413 -
 4 files changed, 400 insertions(+), 545 deletions(-)

New commits:
commit e2ef26991681d6e24c32f08660382af4ca48475c
Author: Stephan Bergmann 
Date:   Thu Apr 7 17:33:26 2016 +0200

Fold PropertySetHelper into its only use, Frame

Change-Id: I148e15c2c91a985cd110f5589adbf26c102b1cfb

diff --git a/framework/Library_fwi.mk b/framework/Library_fwi.mk
index f48ef2d..5e82963 100644
--- a/framework/Library_fwi.mk
+++ b/framework/Library_fwi.mk
@@ -52,7 +52,6 @@ $(eval $(call gb_Library_use_libraries,fwi,\
 
 $(eval $(call gb_Library_add_exception_objects,fwi,\
 framework/source/fwi/classes/converter \
-framework/source/fwi/classes/propertysethelper \
 framework/source/fwi/classes/protocolhandlercache \
 framework/source/fwi/helper/mischelper \
 framework/source/fwi/helper/networkdomain \
diff --git a/framework/inc/classes/propertysethelper.hxx 
b/framework/inc/classes/propertysethelper.hxx
deleted file mode 100644
index e09c071..000
--- a/framework/inc/classes/propertysethelper.hxx
+++ /dev/null
@@ -1,193 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#ifndef INCLUDED_FRAMEWORK_INC_CLASSES_PROPERTYSETHELPER_HXX
-#define INCLUDED_FRAMEWORK_INC_CLASSES_PROPERTYSETHELPER_HXX
-
-#include 
-#include 
-#include 
-
-#include 
-#include 
-#include 
-#include 
-
-#include 
-#include 
-
-namespace framework{
-
-/** supports the API XPropertySet and XPropertySetInfo.
- *
- *  It must be used as baseclass. The internal list of supported
- *  properties can be changed every time so dynamic property set's
- *  can be implemented.
- *
- *  Further the derived and this base class share the same lock.
- *  So it's possible to be threadsafe if it's needed.
-*/
-class FWI_DLLPUBLIC PropertySetHelper : public css::beans::XPropertySet
-, public css::beans::XPropertySetInfo
-{
-
-/* types */
-protected:
-
-typedef BaseHash< css::beans::Property > TPropInfoHash;
-
-/* member */
-protected:
-
-PropertySetHelper::TPropInfoHash m_lProps;
-
-ListenerHash m_lSimpleChangeListener;
-ListenerHash m_lVetoChangeListener;
-
-// hold it weak ... otherwise this helper has to be "killed" 
explicitly .-)
-css::uno::WeakReference< css::uno::XInterface > m_xBroadcaster;
-
-TransactionManager& m_rTransactionManager;
-
-/* native interface */
-public:
-
-/** initialize new instance of this helper.
- *
- *  @param  pExternalTransactionManager
- *  this helper must be used as a baseclass ...
- *  but then it should synchronize its own calls
- *  with the same transaction manager then it's superclass.
- */
-PropertySetHelper(  osl::Mutex & mutex,
-TransactionManager*
 pExternalTransactionManager);
-
-/** free all needed memory.
- */
-virtual ~PropertySetHelper();
-
-/** set a new owner for this helper.
- *
- *  This owner is used as source for all broadcasted events.
- *  Further we hold it weak, because we don't wish to be disposed() .-)
- */
-void impl_setPropertyChangeBroadcaster(const css::uno::Reference< 
css::uno::XInterface >& xBroadcaster);
-
-/** add a new property info to the set of supported ones.
- *
- *  @param  aProperty
- *  describes the new property.
- *
- *  @throw  [css::beans::PropertyExistException]
- *  if a property with the same name already exists.
- *
- *  Note:   The consistence of the whole set of properties is not 
checked here.
- *  Means e.g. ... a handle which exists more than once is not 
detected.
- * 

Crash test update

2016-04-07 Thread Crashtest VM
New crashtest update available at 
http://dev-builds.libreoffice.org/crashtest/871f49e7fadb863b55c96c3f58ea7cc8fb033b40/


exportCrashes.csv
Description: Binary data


importCrash.csv
Description: Binary data


validationErrors.csv
Description: Binary data
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: minutes of ESC call ...

2016-04-07 Thread Bjoern Michaelsen
On Thu, Apr 07, 2016 at 03:36:07PM +0100, Michael Meeks wrote:
> + Made some progress on writer regressions (Bjoern)
> + could close some - have commits, but not closed.

+ count is at 6 currently (all severity minor):
+ 2 SimpleWinLayout still (was reverted already?)
+ 2 more with committed fixes
+ 1 more Windows only
+ 1 general
+ 
http://nabble.documentfoundation.org/Getting-LibreOffice-Writer-5-0-6-bibisected-regression-free-against-LibreOffice-4-4-0-was-LibreOffic-td4179580.html#a4179743

Assuming 2 SimpleWinLayout bugs can be closed as can those with committed
fixes, we are left with only 2 bibisected writer regressions (1 on non-windows)
left open from LibreOffice 5.0.0.

Best,

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


minutes of ESC call ...

2016-04-07 Thread Michael Meeks
* Present:
+ Lionel, Stephan, Sophie, Stefan W., Andras, Kendy, Bjoern, Miklos, Caolán,
  Olivier, Christian, Michael M, Bubli, Michael S, David, Armin, NoelG
 
* Completed Action Items:
+ provide Italo some data:
"thanks to 10,000 UI survey respondants in last year" (thanks to Heiko)
 
* Pending Action Items:
+ accept invite for GSOC mentoring (Muthu)
+ switch lcov profile to system-nss (Norbert)
+ investigate clobberring glew instead of lots of #ifdefs: (Marco, Oliver)
+ add UI guys as reviewers fo rgerrit UI patches (JanI)
[ 7 open right now, will update them shortly. ]
+ tweak UI and get LiveConnect API key / build case for board (Christian)
+ ask QA to re-test http://tdf.io/mmregressions (Robinson)
 [ testing underway ]
+ attempt to re-build a recent gstreamer 1.0 / core spec file
  on our CentOS6 base (tdf#94508) (Christian)
+ script XML / l10n string translation changes (Christian)
 [ still pending => ignore translating it for now (Cloph) ].
 
* Release Engineering update (Christian)
+ 5.0.6 RC1 - due April 12th.
+ last 5.0.x release (Bjoern)
+ 5.1.2.2 status
+ announced as final today.
+ 5.1.3 RC1 - due April 18th
+ 5.2 Alpha - ~end of week of April 18th
+ a milestone for early testing.
+ Android & iOS Remote
+ new Material-design for android / theming pending review.
+ will update mavern bits later today.
 
* Documentation (Olivier)
+ 2 Patches in Helpcontent
+ New chapter of Getting Started 5.1 : Styles & Templates
+ Wiki page comparing alternatives to Helpcontent for ESC
  
https://wiki.documentfoundation.org/Documentation/Help_content_technologies
+ no need to deep-dive here (Kendy)
   + conclusion: XHP still a reasonable source for now.
   + no huge need to move away from it - if it's more editable.
   + hope to improve it with the tender for shared on-line editing of 
it.
 
* l10n (Sophie)
+ quiet, WIP.
 
* GSoC 2016 (JanI)
+ We currently have 17 proposals selected and 23 mentors
+ We need to submit a number no later than April 11th
+ All proposals with a mentor are star marked, and mailed to all mentors 
with questions.
+ concern wrt. mentor/student ratio in some cases.
+ go to https://summerofcode.withgoogle.com/dashboard/proposals/shared/
+ tool can no longer do ranking; what's the plan (Michael)
+ we will want an ordering - done in a spreadsheet
  or somesuch for slot requests.
AI: + copy-paste proposals into a spreadsheet (Michael)
 
* UX Update (Kendy)
+ lots of GSOC discussion
+ planning a good way of co-mentoring with developers.
+ hope is that day-to-day poking, testing is ~non-technical.
+ worked well last year with Jay (Bubli)
+ good to get UX people closer to the code (Michael)
+ draw survey agreed & published
+ sidebar survey results in, prepping for publication.
+ talked wrt. notebookbar & single toolbar mode.
+ useful to use the .ui file as well.
 
* Crashtest update (Caolan)
+ 9 import failures, 1 export failures, 7 coverity
+ prolly all fixed; couldn't reproduce manually.
+ new crashtest pending
+ various people squashing warnings while Caolan away.
+ fuzzing stuff run for 2x weeks while away
+ more fixes coming.
+ hunspell update coming too.
 
* Gran Canaria hack-fest update (Thorsten/JanI etc.)
+ https://wiki.documentfoundation.org/Events/LibreOffice_Espania_Summit
   + sadly no-one on the call.
   + having talks according to Thorsten's twitter (Bjoern)
 https://twitter.com/thooorsten/status/718076286816677888
 
* Hackfests (Bjoern)
+ next venues / suggestions
+ Ankara, Turkey
+ April 30th - May 1st.
+ https://wiki.documentfoundation.org/Hackfest/Ankara2016
+ plan do an overview talk on Friday (Michael)
+ Germany, Munich, LiMux; End of May 2016 (Jan-Marek)
+ Orga: https://wiki.debian.org/BSP/2016/05/de/Munich
+ 27-29 May (parallel to the Debian Sun Camp)
 
* Mentoring Update (JanI)
+ gerrit: 146 open patches of which 94 can be merged if no open comments
 74 from new contributors of which 39 can be merged if no open 
comments
+ had a busy GSoC week helping mentors
+ Have a backlog of mentoring work
+ started discussion on how to secure new contributors can successfully 
build master
 
* Commit Access
 
* Developer Certification (Stephan/Bjoern/Kendy/Thorsten)
+ after GSOC storm.
 
* Jenkins / CI update (Norbert)
from:Thu Mar 31 14:13:43 2016
master linux rel  jobs: 171 ok: 166 ko:   4 fail ratio:  2.34 % break:   4 
broken duration: 0.65%
master linux dbg  jobs: 143 ok: 129 ko:  14 fail ratio:  9.79 % break:  11 
broken duration: 6.07%
master mac reljobs: 160 ok: 156 ko:   4 fail rati

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

2016-04-07 Thread Ashod Nakashian
 loolwsd/loolwsd.xml |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit d014589692dfb09a1b88096a0626b0de1f83e20f
Author: Ashod Nakashian 
Date:   Thu Apr 7 09:11:30 2016 -0400

loolwsd: added default LO install path in the config

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

diff --git a/loolwsd/loolwsd.xml b/loolwsd/loolwsd.xml
index dfa909c..6b57c5a 100644
--- a/loolwsd/loolwsd.xml
+++ b/loolwsd/loolwsd.xml
@@ -2,7 +2,7 @@
 
 
 
-
+
 
 lo
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: framework/Library_fwk.mk framework/source framework/util

2016-04-07 Thread Stephan Bergmann
 framework/Library_fwk.mk   |1 
 framework/source/services/tabwindowservice.cxx |  537 -
 framework/util/fwk.component   |4 
 3 files changed, 542 deletions(-)

New commits:
commit d6d86237b1b438919609988049ac4a152612fee1
Author: Stephan Bergmann 
Date:   Thu Apr 7 15:22:42 2016 +0200

[API CHANGE] Remove undocumented TabContainerWindow service

It originally got introduced with b1da5a57d93e8e9b43b9bba9fabc3b7e61289edc
"CWS-TOOLING: integrate CWS alf01" but appears to have never been used.

Curiously, there were two commits to its code
(f565a4b3d9b47ca3336df4f8d8d56d4e2dcceec5 "#i107087# TabWindowService must 
set
member pointer to zero on VCLEVENT_OBJECT_DYING. The window life time is
controlled by the docking window! Adding missing RemoveEventListener call" 
and
84c0ebe7d3e7dbc3796967d52f9535fecc9e6947 "#i107087# Remove event listener 
from
tab window on TabWindowService dtor") that mention
 "button merged in 
standard
toolbar + own UI caused office crash", but the description of which ("when i
merge a toolbar button in a standard toolbar and provide own UI (via the
toolkit) the office crashed sometimes") doesn't give a hint how this service
would have been used.  (Maybe it was intended to be used by extensions, but
never got documented neither in offapi's UNOIDL nor in

.)

Change-Id: I86746f73ee99ebe7f5afbc902204a9353e5ccb7b

diff --git a/framework/Library_fwk.mk b/framework/Library_fwk.mk
index f4a2aed..d1927cd 100644
--- a/framework/Library_fwk.mk
+++ b/framework/Library_fwk.mk
@@ -110,7 +110,6 @@ $(eval $(call gb_Library_add_exception_objects,fwk,\
 framework/source/services/pathsettings \
 framework/source/services/sessionlistener \
 framework/source/services/substitutepathvars \
-framework/source/services/tabwindowservice \
 framework/source/services/taskcreatorsrv \
 framework/source/services/urltransformer \
 framework/source/uiconfiguration/globalsettings \
diff --git a/framework/source/services/tabwindowservice.cxx 
b/framework/source/services/tabwindowservice.cxx
deleted file mode 100644
index 06aff9f..000
--- a/framework/source/services/tabwindowservice.cxx
+++ /dev/null
@@ -1,537 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include 
-#include 
-#include 
-
-#include 
-#include 
-#include 
-#include 
-#include 
-
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-
-using namespace framework;
-
-namespace {
-
-struct TTabPageInfo
-{
-public:
-
-TTabPageInfo()
-: m_nIndex  ( -1  )
-, m_bCreated(false)
-, m_lProperties ( )
-{}
-
-explicit TTabPageInfo(::sal_Int32 nID)
-: m_nIndex  ( nID )
-, m_bCreated(false)
-, m_lProperties ( )
-{}
-
-public:
-
-::sal_Int32   m_nIndex;
-bool  m_bCreated;
-css::uno::Sequence< css::beans::NamedValue >  m_lProperties;
-};
-
-typedef std::unordered_map< ::sal_Int32,
-TTabPageInfo   ,
-Int32HashCode > TTabPageInfoHash;
-
-/*-
-@short  implements a helper service providing a dockable tab control window
-*//*-*/
-
-class TabWindowService :  public css::lang::XTypeProvider
- ,  public css::lang::XServiceInfo
- ,  public css::awt::XSimpleTabController
- ,  public css::

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

2016-04-07 Thread Krunoslav Šebetić
 extras/source/autocorr/lang/hr/DocumentList.xml   |  541 --
 extras/source/autocorr/lang/hr/SentenceExceptList.xml |  176 +
 2 files changed, 173 insertions(+), 544 deletions(-)

New commits:
commit 07cedfb6c8b98d1d3483cec18eba0bf4e5a79d63
Author: Krunoslav Šebetić 
Date:   Thu Apr 7 13:37:07 2016 +0200

tdf#98771 Update DocumentList.xml and SentenceExceptionList.xml for Croatian

Change-Id: I3af29ce57f3c2ed62da63c5a3e9075c582a95d94
Reviewed-on: https://gerrit.libreoffice.org/23896
Tested-by: Jenkins 
Reviewed-by: Andras Timar 

diff --git a/extras/source/autocorr/lang/hr/DocumentList.xml 
b/extras/source/autocorr/lang/hr/DocumentList.xml
index de70c18..04ef508 100644
--- a/extras/source/autocorr/lang/hr/DocumentList.xml
+++ b/extras/source/autocorr/lang/hr/DocumentList.xml
@@ -1,546 +1,5 @@
 
 http://openoffice.org/2001/block-list";>
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  http://"/>
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
   
   
   
diff --git a/extras/source/autocorr/lang/hr/SentenceExceptList.xml 
b/extras/source/autocorr/lang/hr/SentenceExceptList.xml
index ef336ba..5fff8d7 100644
--- a/extras/source/autocorr/lang/hr/SentenceExceptList.xml
+++ b/extras/source/autocorr/lang/hr/SentenceExceptList.xml
@@ -1,6 +1,176 @@
 
 http://openoffice.org/2001/block-list";>
-  
-  
-  
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: 2 commits - loolwsd/Admin.cpp loolwsd/ChildProcessSession.cpp loolwsd/LOOLKit.cpp loolwsd/LOOLWSD.cpp loolwsd/QueueHandler.hpp

2016-04-07 Thread Tor Lillqvist
 loolwsd/Admin.cpp   |8 
 loolwsd/ChildProcessSession.cpp |4 ++--
 loolwsd/LOOLKit.cpp |   10 +-
 loolwsd/LOOLWSD.cpp |   10 +-
 loolwsd/QueueHandler.hpp|4 ++--
 5 files changed, 18 insertions(+), 18 deletions(-)

New commits:
commit 711674f7cec26a0dad8bcf4f733ca76e90e619bf
Author: Tor Lillqvist 
Date:   Thu Apr 7 15:56:23 2016 +0300

Use Log::debug() here, too, for consistency

diff --git a/loolwsd/Admin.cpp b/loolwsd/Admin.cpp
index 893f9dc..3bb963e 100644
--- a/loolwsd/Admin.cpp
+++ b/loolwsd/Admin.cpp
@@ -453,7 +453,7 @@ void Admin::run()
 
 Util::setThreadName(thread_name);
 
-Log::info("Thread started.");
+Log::debug("Thread started.");
 
 _memStatsTimer.cancel();
 _cpuStatsTimer.cancel();
commit 4fdd6d684f060701aeb9a063aed60133f0e6cfab
Author: Tor Lillqvist 
Date:   Thu Apr 7 15:51:49 2016 +0300

Reduce redundant information in logging

The logging functions already display the thread name on all output
lines. No need to mention it another time in the thread start and
finish logging messages.

diff --git a/loolwsd/Admin.cpp b/loolwsd/Admin.cpp
index 2d7e2a8..893f9dc 100644
--- a/loolwsd/Admin.cpp
+++ b/loolwsd/Admin.cpp
@@ -337,7 +337,7 @@ void AdminRequestHandler::handleRequest(HTTPServerRequest& 
request, HTTPServerRe
 
 Util::setThreadName(thread_name);
 
-Log::debug("Thread [" + thread_name + "] started.");
+Log::debug("Thread started.");
 
 try
 {
@@ -367,7 +367,7 @@ void AdminRequestHandler::handleRequest(HTTPServerRequest& 
request, HTTPServerRe
 response.setContentLength(0);
 response.send();
 }
-Log::debug("Thread [" + thread_name + "] finished.");
+Log::debug("Thread finished.");
 }
 
 /// An admin command processor.
@@ -453,12 +453,12 @@ void Admin::run()
 
 Util::setThreadName(thread_name);
 
-Log::info("Thread [" + thread_name + "] started.");
+Log::info("Thread started.");
 
 _memStatsTimer.cancel();
 _cpuStatsTimer.cancel();
 
-Log::debug("Thread [" + thread_name + "] finished.");
+Log::debug("Thread finished.");
 }
 
 AdminModel& Admin::getModel()
diff --git a/loolwsd/ChildProcessSession.cpp b/loolwsd/ChildProcessSession.cpp
index 4d46330..2e4ecd4 100644
--- a/loolwsd/ChildProcessSession.cpp
+++ b/loolwsd/ChildProcessSession.cpp
@@ -202,7 +202,7 @@ public:
 
 Util::setThreadName(thread_name);
 
-Log::debug("Thread [" + thread_name + "] started.");
+Log::debug("Thread started.");
 
 while (!_stop && !TerminationFlag)
 {
@@ -233,7 +233,7 @@ public:
 break;
 }
 
-Log::debug("Thread [" + thread_name + "] finished.");
+Log::debug("Thread finished.");
 }
 
 void stop()
diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index 205a1ad..5a0f453 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -281,7 +281,7 @@ public:
 
 Util::setThreadName(thread_name);
 
-Log::debug("Thread [" + thread_name + "] started.");
+Log::debug("Thread started.");
 
 try
 {
@@ -357,7 +357,7 @@ public:
 Log::error("Connection::run:: Unexpected exception");
 }
 
-Log::debug("Thread [" + thread_name + "] finished.");
+Log::debug("Thread finished.");
 }
 
 private:
@@ -898,11 +898,11 @@ void lokit_main(const std::string& childRoot,
 
 Util::setThreadName(process_name);
 
+Log::debug("Process started.");
+
 Util::setTerminationSignals();
 Util::setFatalSignals();
 
-Log::debug("Process [" + process_name + "] started.");
-
 static const std::string instdir_path = "/" + loSubPath + "/program";
 LibreOfficeKit* loKit = nullptr;
 
@@ -1079,7 +1079,7 @@ void lokit_main(const std::string& childRoot,
 Log::error(std::string("Exception: ") + exc.what());
 }
 
-Log::info("Process [" + process_name + "] finished.");
+Log::info("Process finished.");
 _exit(Application::EXIT_OK);
 }
 
diff --git a/loolwsd/LOOLWSD.cpp b/loolwsd/LOOLWSD.cpp
index 0df0813..055a164 100644
--- a/loolwsd/LOOLWSD.cpp
+++ b/loolwsd/LOOLWSD.cpp
@@ -587,7 +587,7 @@ public:
 
 Util::setThreadName(thread_name);
 
-Log::debug("Thread [" + thread_name + "] started.");
+Log::debug("Thread started.");
 
 try
 {
@@ -621,7 +621,7 @@ public:
 Log::error("ClientRequestHandler::handleRequest: Unexpected 
exception");
 }
 
-Log::debug("Thread [" + thread_name + "] finished.");
+Log::debug("Thread finished.");
 }
 };
 
@@ -701,7 +701,7 @@ public:
 
 // Misleading debug message, we obviously started already a while 
ago and have done lots
 // of stuff already.
-Log::debug("Thread [" + thread_name + "] started.");
+Log::debug("Thread started.");
 
 Log::debug("Child socket for SessionId: " + sessionId + ", ja

Re: Implementing SVG attribute "stroke-miterlimit" ( tdf#48066)

2016-04-07 Thread Regina Henschel

Hi all,

I have made some progress. But a new problem comes up.

I have changed WinSalGraphicsImpl::drawPolyLine [3] so that it gets an 
additional parameter fMiterMinimumAngle (same meaning as in 
createAreaGeometryForJoin) and uses it for gdi+. The rendering in 
edit-mode in Draw and Impress is correct then with gdi+ on Windows. Even 
Text in SVG works out of the box. [BTW: The current rendering using gdi+ 
is wrong, see my report bug#99102.]


The behavior of gdi+ is described in [1]. To get the same kind of 
behavior as in LO, when the miter limit is exceeded, the LineJoin type 
'LineJoinMiterClipped' has to be used.


Being only in LibreOffice and SVG, that would be no problem. But MS 
seems to use different defaults. The rendering in PowerPoint looks like 
gdi+ type 'LineJoinMiter'. The specification for 'lim' in ECMA-376, Part 
1, chapter 20.1.8.43, has no details, and I have not found details 
otherwhere.


This gdi+ type 'LineJoinMiter' kind of clipping (see the image in the 
article [1]) will be used in SVG 2 [2] too under the identifier 
'miter-clip'.


So my question: Ignore interoperability with MS? If not, how to solve it?

Kind regards
Regina

[1] 
https://msdn.microsoft.com/en-us/library/windows/desktop/ms534148%28v=vs.85%29.aspx


[2] https://www.w3.org/TR/svg-strokes/#StrokeShape

[3]
diff --git a/vcl/win/gdi/gdiimpl.cxx b/vcl/win/gdi/gdiimpl.cxx
index 7febbe8..36ecb31 100644
--- a/vcl/win/gdi/gdiimpl.cxx
+++ b/vcl/win/gdi/gdiimpl.cxx
@@ -2031,7 +2031,8 @@ bool WinSalGraphicsImpl::drawPolyLine(
 double fTransparency,
 const basegfx::B2DVector& rLineWidths,
 basegfx::B2DLineJoin eLineJoin,
-css::drawing::LineCap eLineCap)
+css::drawing::LineCap eLineCap,
+double fMiterMinimumAngle)
 {
 const sal_uInt32 nCount(rPolygon.count());

@@ -2064,9 +2065,9 @@ bool WinSalGraphicsImpl::drawPolyLine(
 }
 case basegfx::B2DLineJoin::Miter :
 {
-const Gdiplus::REAL aMiterLimit(15.0);
+const Gdiplus::REAL 
aMiterLimit(1/sin(fMiterMinimumAngle/2.0));
 Gdiplus::DllExports::GdipSetPenMiterLimit(pTestPen, 
aMiterLimit);
-Gdiplus::DllExports::GdipSetPenLineJoin(pTestPen, 
Gdiplus::LineJoinMiter);
+Gdiplus::DllExports::GdipSetPenLineJoin(pTestPen, 
Gdiplus::LineJoinMiterClipped);

 break;
 }
 case basegfx::B2DLineJoin::Round :

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


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

2016-04-07 Thread Rohan Kumar
 include/sal/log-areas.dox  |1 +
 include/vcl/lazydelete.hxx |   17 +++--
 2 files changed, 4 insertions(+), 14 deletions(-)

New commits:
commit c829898453d75c0f13ff589b7f8adf8fb062a39f
Author: Rohan Kumar 
Date:   Thu Apr 7 13:56:53 2016 +0530

tdf#91794 remove OSL_DEBUG_LEVEL > 1 conditionals

I disentangled my previous patch and converted fprintf statements to
SAL_INFOs

Change-Id: I4b993e00f82bdf904586ab5e7c954c4ee3ff1bac
Reviewed-on: https://gerrit.libreoffice.org/22925
Tested-by: Jenkins 
Reviewed-by: Björn Michaelsen 

diff --git a/include/sal/log-areas.dox b/include/sal/log-areas.dox
index e76e948..ec874bc 100644
--- a/include/sal/log-areas.dox
+++ b/include/sal/log-areas.dox
@@ -429,6 +429,7 @@ certain functionality.
 @li @c vcl.kde - KDE
 @li @c vcl.kde4 - KDE4
 @li @c vcl.layout - Widget layout
+@li @c vcl.lazydelete
 @li @c vcl.pdfwriter
 @li @c vcl.plugadapt - the Unix/X11 backend plugin mechanism
 @li @c vcl.opengl
diff --git a/include/vcl/lazydelete.hxx b/include/vcl/lazydelete.hxx
index 1f1235d..0c2840f 100644
--- a/include/vcl/lazydelete.hxx
+++ b/include/vcl/lazydelete.hxx
@@ -28,10 +28,7 @@
 #include 
 #include 
 
-#if OSL_DEBUG_LEVEL > 2
 #include 
-#include 
-#endif
 
 #include 
 
@@ -128,10 +125,7 @@ namespace vcl
 LazyDeletor()  { LazyDelete::addDeletor( this ); }
 virtual ~LazyDeletor()
 {
-#if OSL_DEBUG_LEVEL > 2
-fprintf( stderr, "%s %p deleted\n",
- typeid(*this).name(), this );
-#endif
+SAL_INFO("vcl.lazydelete", typeid(*this).name() << std::hex << 
this << " deleted");
 if( s_pOneInstance == this ) // sanity check
 s_pOneInstance = nullptr;
 
@@ -151,12 +145,8 @@ namespace vcl
 nCount = aRealDelete.size();
 for( unsigned int n = 0; n < nCount; n++ )
 {
-#if OSL_DEBUG_LEVEL > 2
-fprintf( stderr, "%s deletes object %p of type %s\n",
- typeid(*this).name(),
- aRealDelete[n],
- typeid(*aRealDelete[n]).name() );
-#endif
+SAL_INFO("vcl.lazydelete", typeid(*this).name() << " deletes 
object " << aRealDelete[n] << " of type "
+ << typeid(*aRealDelete[n]).name());
 // check if the object to be deleted is not already destroyed
 // as a side effect of a previous lazily destroyed object
 if( ! m_aObjects[ m_aPtrToIndex[ 
reinterpret_cast(aRealDelete[n].get()) ] ].m_bDeleted )
@@ -296,5 +286,4 @@ namespace vcl
 }
 
 #endif
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Rohan Kumar
 canvas/source/directx/dx_canvashelper_texturefill.cxx |2 +-
 canvas/source/directx/dx_spritecanvashelper.cxx   |2 +-
 canvas/source/tools/surfaceproxy.cxx  |   13 ++---
 canvas/source/vcl/canvashelper_texturefill.cxx|4 ++--
 canvas/source/vcl/spritecanvashelper.cxx  |4 ++--
 5 files changed, 8 insertions(+), 17 deletions(-)

New commits:
commit f0de4374fffe7fb72ce0e9006af57092834dfe1e
Author: Rohan Kumar 
Date:   Thu Apr 7 13:45:11 2016 +0530

tdf#91794 remove OSL_DEBUG_LEVEL > 1 conditionals

I removed the OSL_DEBUG_LEVEL > 1 conditionals with OSL_DEBUG_LEVEL > 0
or SAL_INFO macros

Change-Id: Ia2a483ea0f992bf182a6beed2b4558a4fb7c5680
Reviewed-on: https://gerrit.libreoffice.org/23079
Tested-by: Jenkins 
Reviewed-by: Björn Michaelsen 

diff --git a/canvas/source/directx/dx_canvashelper_texturefill.cxx 
b/canvas/source/directx/dx_canvashelper_texturefill.cxx
index 826bf69..0e9eb4d 100644
--- a/canvas/source/directx/dx_canvashelper_texturefill.cxx
+++ b/canvas/source/directx/dx_canvashelper_texturefill.cxx
@@ -407,7 +407,7 @@ namespace dxcanvas
 rGraphics->FillPath( pGradientBrush.get(), pFillPath.get() );
 }
 
-#if OSL_DEBUG_LEVEL > 2
+#if OSL_DEBUG_LEVEL > 0
 Gdiplus::Pen aPen( Gdiplus::Color( 255, 255, 0, 0 ),
0.0001f );
 
diff --git a/canvas/source/directx/dx_spritecanvashelper.cxx 
b/canvas/source/directx/dx_spritecanvashelper.cxx
index 66ea028..3803671 100644
--- a/canvas/source/directx/dx_spritecanvashelper.cxx
+++ b/canvas/source/directx/dx_spritecanvashelper.cxx
@@ -70,7 +70,7 @@ namespace dxcanvas
 maScrapRect(),
 mbShowSpriteBounds( false )
 {
-#if OSL_DEBUG_LEVEL > 2
+#if OSL_DEBUG_LEVEL > 0
 // inverse default for verbose debug mode
 mbShowSpriteBounds = true;
 #endif
diff --git a/canvas/source/tools/surfaceproxy.cxx 
b/canvas/source/tools/surfaceproxy.cxx
index fd5b8e2..e809ec9 100644
--- a/canvas/source/tools/surfaceproxy.cxx
+++ b/canvas/source/tools/surfaceproxy.cxx
@@ -114,18 +114,9 @@ namespace canvas
 const ::basegfx::B2DPolygon& rTriangulatedPolygon(
 ::basegfx::triangulator::triangulate(rClipPoly));
 
-#if OSL_DEBUG_LEVEL > 2
 // dump polygons
-OSL_TRACE( "Original clip polygon: %s\n"
-   "Triangulated polygon: %s\n",
-   OUStringToOString(
-   basegfx::tools::exportToSvgD( rClipPoly, true, true, 
false ),
-   RTL_TEXTENCODING_ASCII_US).getStr(),
-   OUStringToOString(
-   basegfx::tools::exportToSvgD(
-   basegfx::B2DPolyPolygon(rTriangulatedPolygon), 
true, true, false ),
-   RTL_TEXTENCODING_ASCII_US).getStr() );
-#endif
+SAL_INFO("canvas", "Orignal clip polygon: " <<  
basegfx::tools::exportToSvgD( rClipPoly, true, true, false ));
+SAL_INFO("canvas", "Triangulated polygon: " <<  
basegfx::tools::exportToSvgD(basegfx::B2DPolyPolygon(rTriangulatedPolygon), 
true, true, false ));
 
 for( const auto& rSurfacePtr : maSurfaceList )
 rSurfacePtr->drawWithClip( fAlpha, rPos, rTriangulatedPolygon, 
rTransform );
diff --git a/canvas/source/vcl/canvashelper_texturefill.cxx 
b/canvas/source/vcl/canvashelper_texturefill.cxx
index 9064345..462ae47 100644
--- a/canvas/source/vcl/canvashelper_texturefill.cxx
+++ b/canvas/source/vcl/canvashelper_texturefill.cxx
@@ -437,7 +437,7 @@ namespace vclcanvas

(sal_uInt8)(basegfx::tools::lerp(rColors[nIndex].GetGreen(),rColors[nIndex+1].GetGreen(),fAlpha)),

(sal_uInt8)(basegfx::tools::lerp(rColors[nIndex].GetBlue(),rColors[nIndex+1].GetBlue(),fAlpha))
 ));
 
-#if OSL_DEBUG_LEVEL > 2
+#if OSL_DEBUG_LEVEL > 0
 if( i && !(i % 10) )
 rOutDev.SetFillColor( COL_RED );
 #endif
@@ -626,7 +626,7 @@ namespace vclcanvas
 }
 }
 
-#if OSL_DEBUG_LEVEL > 3
+#ifdef DEBUG_CANVAS_CANVASHELPER_TEXTUREFILL
 // extra-verbosity
 {
 ::basegfx::B2DRectangle aRect(0.0, 0.0, 1.0, 1.0);
diff --git a/canvas/source/vcl/spritecanvashelper.cxx 
b/canvas/source/vcl/spritecanvashelper.cxx
index 65d1141..775e538 100644
--- a/canvas/source/vcl/spritecanvashelper.cxx
+++ b/canvas/source/vcl/spritecanvashelper.cxx
@@ -124,7 +124,7 @@ namespace vclcanvas
 mbShowSpriteBounds( false ),
 mbIsUnsafeScrolling( false )
 {
-#if OSL_DEBUG_LEVEL > 2
+#if OSL_DEBUG_LEVEL > 0
 // inverse defaults for verbose debug mode
 mbShowSpriteBounds = mbShowFrameInfo = true;
 #endif
@@ -290,7 +290,7 @@ namespace vclcanvas
 renderMemUsage( rOutDev );
 }
 
-#if OSL_DEBUG_LEVEL > 2
+#if OSL_DEBUG_LEVEL > 0
 static ::canvas::tools::ElapsedTime aElapsedTime;
 

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

2016-04-07 Thread Markus Mohrhard
 sc/source/filter/excel/xicontent.cxx |   59 +--
 1 file changed, 37 insertions(+), 22 deletions(-)

New commits:
commit e214df32fb3637bd7810a299fb8b38810b1a3874
Author: Markus Mohrhard 
Date:   Thu Apr 7 08:20:12 2016 +0200

we need the position in the formula converter, tdf#99093

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

diff --git a/sc/source/filter/excel/xicontent.cxx 
b/sc/source/filter/excel/xicontent.cxx
index edef22d..84c43e0 100644
--- a/sc/source/filter/excel/xicontent.cxx
+++ b/sc/source/filter/excel/xicontent.cxx
@@ -789,34 +789,21 @@ void XclImpValidationManager::ReadDV( XclImpStream& rStrm 
)
 rStrm.SetNulSubstChar( '\n' );
 ::std::unique_ptr< ScTokenArray > xTokArr1;
 
-sal_uInt16 nLen = 0;
-nLen = rStrm.ReaduInt16();
+// We can't import the formula directly because we need the range
+sal_uInt16 nLenFormula1 = rStrm.ReaduInt16();
 rStrm.Ignore( 2 );
-if( nLen > 0 )
-{
-const ScTokenArray* pTokArr = nullptr;
-rFmlaConv.Reset();
-rFmlaConv.Convert( pTokArr, rStrm, nLen, false, FT_CondFormat );
-// formula converter owns pTokArr -> create a copy of the token array
-if( pTokArr )
-xTokArr1.reset( pTokArr->Clone() );
-}
-rStrm.SetNulSubstChar();// back to default
+XclImpStreamPos aPosFormula1;
+rStrm.StorePosition(aPosFormula1);
+rStrm.Ignore(nLenFormula1);
 
 // second formula
 ::std::unique_ptr< ScTokenArray > xTokArr2;
 
-nLen = rStrm.ReaduInt16();
+sal_uInt16 nLenFormula2 = rStrm.ReaduInt16();
 rStrm.Ignore( 2 );
-if( nLen > 0 )
-{
-const ScTokenArray* pTokArr = nullptr;
-rFmlaConv.Reset();
-rFmlaConv.Convert( pTokArr, rStrm, nLen, false, FT_CondFormat );
-// formula converter owns pTokArr -> create a copy of the token array
-if( pTokArr )
-xTokArr2.reset( pTokArr->Clone() );
-}
+XclImpStreamPos aPosFormula2;
+rStrm.StorePosition(aPosFormula2);
+rStrm.Ignore(nLenFormula2);
 
 // read all cell ranges
 XclRangeList aXclRanges;
@@ -830,6 +817,34 @@ void XclImpValidationManager::ReadDV( XclImpStream& rStrm )
 if ( aScRanges.empty() )
 return;
 
+ScRange aCombinedRange = aScRanges.Combine();
+
+XclImpStreamPos aCurrentPos;
+rStrm.StorePosition(aCurrentPos);
+rStrm.RestorePosition(aPosFormula1);
+if( nLenFormula1 > 0 )
+{
+const ScTokenArray* pTokArr = nullptr;
+rFmlaConv.Reset(aCombinedRange.aStart);
+rFmlaConv.Convert( pTokArr, rStrm, nLenFormula1, false, FT_CondFormat 
);
+// formula converter owns pTokArr -> create a copy of the token array
+if( pTokArr )
+xTokArr1.reset( pTokArr->Clone() );
+}
+rStrm.SetNulSubstChar();// back to default
+if (nLenFormula2 > 0)
+{
+rStrm.RestorePosition(aPosFormula2);
+const ScTokenArray* pTokArr = nullptr;
+rFmlaConv.Reset(aCombinedRange.aStart);
+rFmlaConv.Convert( pTokArr, rStrm, nLenFormula2, false, FT_CondFormat 
);
+// formula converter owns pTokArr -> create a copy of the token array
+if( pTokArr )
+xTokArr2.reset( pTokArr->Clone() );
+}
+
+rStrm.RestorePosition(aCurrentPos);
+
 bool bIsValid = true;   // valid settings in flags field
 
 ScValidationMode eValMode = SC_VALID_ANY;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Stephan Bergmann
 sc/inc/textuno.hxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit 013090d5f6855da3220fcb841c8a31952664
Author: Stephan Bergmann 
Date:   Thu Apr 7 13:58:59 2016 +0200

ScHeaderFooterTextData default ctor had been added in error

...with be3c2ff9233e8d4c5afe9c696cb5a60b24b25efc "tdf#94306 Replace
boost::noncopyable with plain C++11 deleted copy ctors"

Change-Id: I817b96fea3056f5d9914e5d1c829d07ca9755d34

diff --git a/sc/inc/textuno.hxx b/sc/inc/textuno.hxx
index 3316e75..bb32420 100644
--- a/sc/inc/textuno.hxx
+++ b/sc/inc/textuno.hxx
@@ -119,7 +119,6 @@ private:
 boolbDataValid;
 
 public:
-ScHeaderFooterTextData() = default;
 ScHeaderFooterTextData(const ScHeaderFooterTextData&) = delete;
 const ScHeaderFooterTextData& operator=(const ScHeaderFooterTextData&) = 
delete;
 ScHeaderFooterTextData(
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Miklos Vajna
 sw/inc/pagedesc.hxx  |1 
 sw/qa/extras/ww8import/data/tdf99100.doc |binary
 sw/qa/extras/ww8import/data/tdf99120.doc |binary
 sw/qa/extras/ww8import/ww8import.cxx |   18 +
 sw/source/filter/ww8/ww8par.cxx  |3 +-
 sw/source/filter/ww8/ww8par.hxx  |2 +
 sw/source/filter/ww8/ww8par5.cxx |   42 +--
 7 files changed, 63 insertions(+), 3 deletions(-)

New commits:
commit f47143222ab5bacc48bc9a61b9d247e4a062fe9e
Author: Miklos Vajna 
Date:   Wed Apr 6 08:34:28 2016 +0200

tdf#99100 DOC import: handle subset of STYLEREF natively

Commit 4215bca95511af8e4ee96e3c8f521b35f638aef3 (export 'Chapter' field
type as 'StyleRef' into .doc, 2015-08-21) mapped SwChapterField to
STYLEREF in the DOC export. This field type was handled as a field mark
on import. Instead of always handling it as a field mark, recognize the
case when it's the subset we write and we can handle natively, and in
that case create an SwChapterField again on import.

Leave the complex case unchanged as before and keep using field marks
for that.

Also (because the header where STYLEREF is used is completely empty
otherwise):

tdf#99120 DOC import: fix lack of first share after odd section break

Commit 848b1a05c5c41b5e7ff19c984f60c297a8143990 (fix for bnc#659631,
2011-02-04) made wwSectionManager::InsertSegments() use
SwPageDesc::WriteUseOn() directly, instead of going via
SwPageDesc::SetUseOn() that takes care of not throwing away the higher
share bits of the bitfield. This way the "is first shared" flag of the
bitfield got cleared, even when the input document had no title page
declared, so first header/footer must be shared.

Fix the problem by using SetUseOn() in the DOC import as well when it
comes to handling odd/even page section breaks.

(cherry picked from commits d635b351849b8b576c907abf22500d0fa89ab54f and
44a3eb37cd982c59f8350d53db3798b675230b35)

Conflicts:
sw/source/filter/ww8/ww8par5.cxx

Change-Id: Icfa8c4be6538da5e02e2d5071af30a46ccfa712b
Reviewed-on: https://gerrit.libreoffice.org/23889
Tested-by: Jenkins 
Reviewed-by: Andras Timar 

diff --git a/sw/inc/pagedesc.hxx b/sw/inc/pagedesc.hxx
index 5bdb738..50fcb7f 100644
--- a/sw/inc/pagedesc.hxx
+++ b/sw/inc/pagedesc.hxx
@@ -186,6 +186,7 @@ public:
 bool IsHidden() const { return m_IsHidden; }
 void SetHidden(bool const bValue) { m_IsHidden = bValue; }
 
+/// Same as WriteUseOn(), but the >= PD_HEADERSHARE part of the bitfield 
is not modified.
 inline void  SetUseOn( UseOnPage eNew );
 inline UseOnPage GetUseOn() const;
 
diff --git a/sw/qa/extras/ww8import/data/tdf99100.doc 
b/sw/qa/extras/ww8import/data/tdf99100.doc
new file mode 100644
index 000..6352ae3
Binary files /dev/null and b/sw/qa/extras/ww8import/data/tdf99100.doc differ
diff --git a/sw/qa/extras/ww8import/data/tdf99120.doc 
b/sw/qa/extras/ww8import/data/tdf99120.doc
new file mode 100644
index 000..a93721c
Binary files /dev/null and b/sw/qa/extras/ww8import/data/tdf99120.doc differ
diff --git a/sw/qa/extras/ww8import/ww8import.cxx 
b/sw/qa/extras/ww8import/ww8import.cxx
index 3a0860d..37bb2c2 100644
--- a/sw/qa/extras/ww8import/ww8import.cxx
+++ b/sw/qa/extras/ww8import/ww8import.cxx
@@ -535,6 +535,24 @@ DECLARE_WW8IMPORT_TEST(testfdo68963, "fdo68963.doc")
 CPPUNIT_ASSERT ( -1 == 
parseDump("/root/page/body/txt[24]/Special[2]","rText").indexOf("Reference 
source not found"));
 }
 
+DECLARE_WW8IMPORT_TEST(testTdf99100, "tdf99100.doc")
+{
+uno::Reference xHeaderText = getProperty< 
uno::Reference >(getStyles("PageStyles")->getByName("Standard"), 
"HeaderText");
+auto xField = getProperty< uno::Reference 
>(getRun(getParagraphOfText(1, xHeaderText), 2), "TextField");
+// This failed: the second text portion wasn't a field.
+CPPUNIT_ASSERT(xField.is());
+
CPPUNIT_ASSERT(xField->supportsService("com.sun.star.text.textfield.Chapter"));
+}
+
+DECLARE_WW8IMPORT_TEST(testTdf99120, "tdf99120.doc")
+{
+CPPUNIT_ASSERT_EQUAL(OUString("Section 1, odd."),  
parseDump("/root/page[1]/header/txt/text()"));
+CPPUNIT_ASSERT_EQUAL(OUString("Section 1, even."),  
parseDump("/root/page[2]/header/txt/text()"));
+// This failed: the header was empty on the 3rd page, as the first page 
header was shown.
+CPPUNIT_ASSERT_EQUAL(OUString("Section 2, odd."),  
parseDump("/root/page[3]/header/txt/text()"));
+CPPUNIT_ASSERT_EQUAL(OUString("Section 2, even."),  
parseDump("/root/page[4]/header/txt/text()"));
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index f431305..59ff292 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -4527,7 +4527,8 @@ void wwSectionManager::InsertSegme

Re: Libre Office online

2016-04-07 Thread Andrew McGlashan
Hi,

On 6/04/2016 4:44 PM, Muhammad Asad wrote:
> I have successfully setup LibreOffice online, Kudos to you guys. I just
> have a simple question, can i give a url to a document in file_path
> query string param ? When i am giving it a url to a document with http
> or https it says socket closed.
> 
> file_path=file:///home/administrator/test.docx this works fine.
> file_path=http://mydomain.com/myfile.docs this doesn;t work.
> 
> So just wanted to ask is this something which is currently supported or not?

Not sure, but I think this is the kind of thing you might do in
conjunction with an ownCloud URL.

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


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

2016-04-07 Thread Stephan Bergmann
 io/source/acceptor/acc_socket.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit aea456a37445f402f1fb3eb1415ca6af7046cf1e
Author: Stephan Bergmann 
Date:   Thu Apr 7 13:06:22 2016 +0200

clean up

Change-Id: Ibf0df59d2773a3356b21e1b4c70889511b373e56

diff --git a/io/source/acceptor/acc_socket.cxx 
b/io/source/acceptor/acc_socket.cxx
index b1a30a1..0a1edc5 100644
--- a/io/source/acceptor/acc_socket.cxx
+++ b/io/source/acceptor/acc_socket.cxx
@@ -203,8 +203,8 @@ namespace io_acceptor {
 aReadBytes.realloc( nBytesToRead );
 }
 
-sal_Int32 i = 0;
-i = m_socket.read( aReadBytes.getArray()  , aReadBytes.getLength() 
);
+sal_Int32 i = m_socket.read(
+aReadBytes.getArray(), aReadBytes.getLength());
 
 if(i != nBytesToRead)
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Tor Lillqvist
 vcl/win/gdi/salfont.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit e821558b2e233a9c04712555a6bdcb5020c1209f
Author: Tor Lillqvist 
Date:   Mon Mar 28 16:38:24 2016 +0300

No need for  here

Change-Id: I809143b0c2b5fe36ce01f44e6eca2f33ae36198f

diff --git a/vcl/win/gdi/salfont.cxx b/vcl/win/gdi/salfont.cxx
index 4b844c3..d7c9627 100644
--- a/vcl/win/gdi/salfont.cxx
+++ b/vcl/win/gdi/salfont.cxx
@@ -21,7 +21,6 @@
 #include 
 
 #include 
-#include 
 #include 
 #include 
 #include 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Stephan Bergmann
 io/source/acceptor/acc_socket.cxx  |   10 --
 io/source/connector/ctr_pipe.cxx   |9 ++---
 io/source/connector/ctr_socket.cxx |7 ++-
 3 files changed, 8 insertions(+), 18 deletions(-)

New commits:
commit dee0a619bff88776d2b6c5b824fc8e8950418f70
Author: Stephan Bergmann 
Date:   Thu Apr 7 12:24:28 2016 +0200

Revert "reduce unnecessary realloc'ing"

This reverts commit 9f6e6fabcd5718e0b65437c5ce398e520f47aae1, which is 
wrong, as
it would cause the functions to now try to read aReadBytes.getLength() 
bytes if
that is initially larger than nBytesToRead.

diff --git a/io/source/acceptor/acc_socket.cxx 
b/io/source/acceptor/acc_socket.cxx
index 3fe29f3..b1a30a1 100644
--- a/io/source/acceptor/acc_socket.cxx
+++ b/io/source/acceptor/acc_socket.cxx
@@ -198,12 +198,13 @@ namespace io_acceptor {
 {
 notifyListeners(this, &_started, callStarted);
 
-if( aReadBytes.getLength() < nBytesToRead )
+if( aReadBytes.getLength() != nBytesToRead )
 {
 aReadBytes.realloc( nBytesToRead );
 }
 
-sal_Int32 i = m_socket.read( aReadBytes.getArray()  , 
aReadBytes.getLength() );
+sal_Int32 i = 0;
+i = m_socket.read( aReadBytes.getArray()  , aReadBytes.getLength() 
);
 
 if(i != nBytesToRead)
 {
@@ -219,10 +220,7 @@ namespace io_acceptor {
 
 throw ioException;
 }
-if( i < aReadBytes.getLength() )
-{
-aReadBytes.realloc( i );
-}
+
 return i;
 }
 else
diff --git a/io/source/connector/ctr_pipe.cxx b/io/source/connector/ctr_pipe.cxx
index dafdc42..df15291 100644
--- a/io/source/connector/ctr_pipe.cxx
+++ b/io/source/connector/ctr_pipe.cxx
@@ -49,16 +49,11 @@ namespace stoc_connector {
 {
 if( ! m_nStatus )
 {
-if( aReadBytes.getLength() < nBytesToRead )
+if( aReadBytes.getLength() != nBytesToRead )
 {
 aReadBytes.realloc( nBytesToRead );
 }
-sal_Int32 n = m_pipe.read( aReadBytes.getArray()  , 
aReadBytes.getLength() );
-if( n < aReadBytes.getLength() )
-{
-aReadBytes.realloc( n );
-}
-return n;
+return m_pipe.read( aReadBytes.getArray()  , 
aReadBytes.getLength() );
 }
 else {
 throw IOException();
diff --git a/io/source/connector/ctr_socket.cxx 
b/io/source/connector/ctr_socket.cxx
index 787a470..2c0d3f6 100644
--- a/io/source/connector/ctr_socket.cxx
+++ b/io/source/connector/ctr_socket.cxx
@@ -123,7 +123,7 @@ namespace stoc_connector {
 {
 notifyListeners(this, &_started, callStarted);
 
-if( aReadBytes.getLength() < nBytesToRead )
+if( aReadBytes.getLength() != nBytesToRead )
 {
 aReadBytes.realloc( nBytesToRead );
 }
@@ -143,10 +143,7 @@ namespace stoc_connector {
 
 throw ioException;
 }
-if( i < aReadBytes.getLength() )
-{
-aReadBytes.realloc( i );
-}
+
 return i;
 }
 else
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Tor Lillqvist
 shell/inc/basereader.hxx  |   72 
 shell/inc/columninfo.hxx  |   71 
 shell/inc/config.hxx  |   92 ++
 shell/inc/contentreader.hxx   |  121 
+++
 shell/inc/fileextensions.hxx  |   62 
 shell/inc/global.hxx  |   35 ++
 shell/inc/i_xml_parser_event_handler.hxx  |   63 
 shell/inc/infotips.hxx|   94 ++
 shell/inc/internal/basereader.hxx |   72 
 shell/inc/internal/columninfo.hxx |   71 
 shell/inc/internal/config.hxx |   92 --
 shell/inc/internal/contentreader.hxx  |  121 
---
 shell/inc/internal/fileextensions.hxx |   62 
 shell/inc/internal/global.hxx |   35 --
 shell/inc/internal/i_xml_parser_event_handler.hxx |   63 
 shell/inc/internal/infotips.hxx   |   94 --
 shell/inc/internal/iso8601_converter.hxx  |   41 --
 shell/inc/internal/metainforeader.hxx |  143 
-
 shell/inc/internal/propertyhdl.hxx|  117 
---
 shell/inc/internal/propsheets.hxx |   88 -
 shell/inc/internal/registry.hxx   |   63 
 shell/inc/internal/resource.h |   72 
 shell/inc/internal/shlxthdl.hxx   |   49 ---
 shell/inc/internal/stream_helper.hxx  |   53 ---
 shell/inc/internal/thumbviewer.hxx|  114 
---
 shell/inc/internal/types.hxx  |   81 -
 shell/inc/internal/utilities.hxx  |  135 

 shell/inc/internal/xml_parser.hxx |  109 
---
 shell/inc/internal/zipfile.hxx|  152 
--
 shell/inc/iso8601_converter.hxx   |   41 ++
 shell/inc/metainforeader.hxx  |  143 
+
 shell/inc/propertyhdl.hxx |  117 
+++
 shell/inc/propsheets.hxx  |   88 +
 shell/inc/registry.hxx|   63 
 shell/inc/resource.h  |   72 
 shell/inc/shlxthdl.hxx|   49 +++
 shell/inc/stream_helper.hxx   |   53 +++
 shell/inc/thumbviewer.hxx |  114 
+++
 shell/inc/types.hxx   |   81 +
 shell/inc/utilities.hxx   |  135 

 shell/inc/xml_parser.hxx  |  109 
+++
 shell/inc/zipfile.hxx |  152 
++
 shell/qa/zip/testzipimpl.hxx  |2 
 shell/qa/zip/ziptest.cxx  |2 
 shell/source/all/xml_parser.cxx   |6 
 shell/source/unix/sysshell/recently_used_file_handler.cxx |4 
 shell/source/win32/ooofilereader/basereader.cxx   |4 
 shell/source/win32/ooofilereader/contentreader.cxx|2 
 shell/source/win32/ooofilereader/itag.hxx |4 
 shell/source/win32/ooofilereader/metainforeader.cxx   |2 
 shell/source/win32/shlxthandler/classfactory.cxx  |   12 
 shell/source/win32/shlxthandler/columninfo/columninfo.cxx |   12 
 shell/source/win32/shlxthandler/infotips/infotips.cxx |   24 -
 shell/source/win32/shlxthandler/ooofilt/ooofilt.cxx   |   10 
 shell/source/win32/shlxthandler/ooofilt/ooofilt.hxx   |2 
 shell/source/win32/shlxthandler/ooofilt/stream_helper.cxx |2 
 shell/source/win32/shlxthandler/prophdl/propertyhdl.cxx   |   14 
 shell/source/win32/shlxthandler/propsheets/document_statistic.cxx |   12 
 shell/source/win32/shlxthandler/propsheets/document_statistic.hxx |2 
 shell/source/win32/shlxthandler/propsheets/listviewbuilder.cxx|6 
 shell/source/win32/shlxthandler/propsheets/propsheets.cxx |   10 
 shell/source/win32/shlxthandler/res/rcheader.txt  |2 
 shell/source/win32/shlxthandler/shlxthdl.cxx  |   12 
 shell/source/win32/shlxthandler/thum

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

2016-04-07 Thread Eike Rathke
 sc/source/core/data/document.cxx |   36 +++-
 1 file changed, 35 insertions(+), 1 deletion(-)

New commits:
commit 94a95dce43e07b40350ed849db148b2946e3fd5e
Author: Eike Rathke 
Date:   Thu Apr 7 10:51:51 2016 +0100

Resolves: tdf#97897 (re)broadcast if formula groups were split

DeleteSelection() and DeleteSelectionTab() remove listeners for split
formula groups, broadcast change after listeners of new groups have been
established.

Change-Id: I017e92b5cbc5f866768f3732e9997028c0c065fa

diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
index 67a882a..605cf2e 100644
--- a/sc/source/core/data/document.cxx
+++ b/sc/source/core/data/document.cxx
@@ -1839,7 +1839,6 @@ void ScDocument::DeleteArea(
 {
 aRange.aStart.SetTab(i);
 aRange.aEnd.SetTab(i);
-
 SetDirty( aRange, true);
 }
 }
@@ -5788,6 +5787,21 @@ void ScDocument::DeleteSelection( InsertDeleteFlags 
nDelFlag, const ScMarkData&
 // Re-start listeners on those top bottom groups that have been split.
 SetNeedsListeningGroups(aGroupPos);
 StartNeededListeners();
+
+// If formula groups were split their listeners were destroyed and may
+// need to be notified now that they're restored,
+// ScTable::DeleteSelection() couldn't do that.
+if (!aGroupPos.empty())
+{
+ScRangeList aRangeList;
+rMark.FillRangeListWithMarks( &aRangeList, false);
+for (size_t i = 0; i < aRangeList.size(); ++i)
+{
+const ScRange* pRange = aRangeList[i];
+if (pRange)
+SetDirty( *pRange, true);
+}
+}
 }
 }
 
@@ -5829,6 +5843,26 @@ void ScDocument::DeleteSelectionTab(
 // Re-start listeners on those top bottom groups that have been 
split.
 SetNeedsListeningGroups(aGroupPos);
 StartNeededListeners();
+
+// If formula groups were split their listeners were destroyed and 
may
+// need to be notified now that they're restored,
+// ScTable::DeleteSelection() couldn't do that.
+if (!aGroupPos.empty())
+{
+ScRangeList aRangeList;
+rMark.FillRangeListWithMarks( &aRangeList, false);
+for (size_t i = 0; i < aRangeList.size(); ++i)
+{
+const ScRange* pRange = aRangeList[i];
+if (pRange && pRange->aStart.Tab() <= nTab && nTab <= 
pRange->aEnd.Tab())
+{
+ScRange aRange( *pRange);
+aRange.aStart.SetTab( nTab);
+aRange.aEnd.SetTab( nTab);
+SetDirty( aRange, true);
+}
+}
+}
 }
 }
 else
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Tor Lillqvist
 sal/inc/internal/misc.hxx |   18 --
 sal/inc/internal/oslmemory.h  |   30 
 sal/inc/internal/oslrandom.h  |   25 
 sal/inc/internal/rtllifecycle.h   |   47 --
 sal/inc/internal/signalshared.hxx |   44 ---
 sal/inc/misc.hxx  |   18 ++
 sal/inc/oslmemory.h   |   30 
 sal/inc/oslrandom.h   |   25 
 sal/inc/pch/precompiled_sal.hxx   |2 -
 sal/inc/rtllifecycle.h|   47 ++
 sal/inc/signalshared.hxx  |   44 +++
 sal/osl/all/log.cxx   |2 -
 sal/osl/all/signalshared.cxx  |2 -
 sal/osl/unx/backtraceapi.cxx  |2 -
 sal/osl/unx/memory.cxx|2 -
 sal/osl/unx/random.cxx|2 -
 sal/osl/unx/signal.cxx|2 -
 sal/osl/w32/backtrace.cxx |2 -
 sal/osl/w32/dllentry.c|2 -
 sal/osl/w32/memory.c  |2 -
 sal/osl/w32/signal.cxx|2 -
 sal/rtl/alloc_arena.cxx   |2 -
 sal/rtl/alloc_cache.cxx   |   32 -
 sal/rtl/alloc_fini.cxx|2 -
 sal/rtl/alloc_global.cxx  |4 +--
 sal/rtl/locale.cxx|2 -
 sal/rtl/random.cxx|2 -
 27 files changed, 182 insertions(+), 212 deletions(-)

New commits:
commit c5e119f51bd07fb11ac04a58dacf3f79695d02a9
Author: Tor Lillqvist 
Date:   Thu Apr 7 12:37:56 2016 +0300

Drop pointless "internal" directory level for already internal include files

Change-Id: I496fdbab3e17c806c2d16513412c4c1b9120bc3c

diff --git a/sal/inc/internal/misc.hxx b/sal/inc/misc.hxx
similarity index 100%
rename from sal/inc/internal/misc.hxx
rename to sal/inc/misc.hxx
diff --git a/sal/inc/internal/oslmemory.h b/sal/inc/oslmemory.h
similarity index 100%
rename from sal/inc/internal/oslmemory.h
rename to sal/inc/oslmemory.h
diff --git a/sal/inc/internal/oslrandom.h b/sal/inc/oslrandom.h
similarity index 100%
rename from sal/inc/internal/oslrandom.h
rename to sal/inc/oslrandom.h
diff --git a/sal/inc/pch/precompiled_sal.hxx b/sal/inc/pch/precompiled_sal.hxx
index 13cf7bb..0db8378 100644
--- a/sal/inc/pch/precompiled_sal.hxx
+++ b/sal/inc/pch/precompiled_sal.hxx
@@ -91,6 +91,6 @@
 #include 
 #include 
 #include 
-#include 
+#include 
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sal/inc/internal/rtllifecycle.h b/sal/inc/rtllifecycle.h
similarity index 100%
rename from sal/inc/internal/rtllifecycle.h
rename to sal/inc/rtllifecycle.h
diff --git a/sal/inc/internal/signalshared.hxx b/sal/inc/signalshared.hxx
similarity index 100%
rename from sal/inc/internal/signalshared.hxx
rename to sal/inc/signalshared.hxx
diff --git a/sal/osl/all/log.cxx b/sal/osl/all/log.cxx
index a010c33..20efa68 100644
--- a/sal/osl/all/log.cxx
+++ b/sal/osl/all/log.cxx
@@ -25,7 +25,7 @@
 #include "sal/detail/log.h"
 #include "sal/log.hxx"
 #include "sal/types.h"
-#include "internal/misc.hxx"
+#include "misc.hxx"
 
 #include "logformat.hxx"
 
diff --git a/sal/osl/all/signalshared.cxx b/sal/osl/all/signalshared.cxx
index f444f37..d4615b3 100644
--- a/sal/osl/all/signalshared.cxx
+++ b/sal/osl/all/signalshared.cxx
@@ -19,7 +19,7 @@
 
 #include 
 
-#include 
+#include 
 
 #include 
 
diff --git a/sal/osl/unx/backtraceapi.cxx b/sal/osl/unx/backtraceapi.cxx
index a2a2cac..1895c43 100644
--- a/sal/osl/unx/backtraceapi.cxx
+++ b/sal/osl/unx/backtraceapi.cxx
@@ -10,7 +10,7 @@
 #include 
 
 #include 
-#include "internal/misc.hxx"
+#include "misc.hxx"
 
 // FIXME: no-op for now; it needs implementing, cf. above.
 rtl_uString *osl_backtraceAsString()
diff --git a/sal/osl/unx/memory.cxx b/sal/osl/unx/memory.cxx
index c016baa9..db376ec 100644
--- a/sal/osl/unx/memory.cxx
+++ b/sal/osl/unx/memory.cxx
@@ -7,7 +7,7 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
  */
 
-#include 
+#include 
 
 #include 
 #ifdef __ANDROID__
diff --git a/sal/osl/unx/random.cxx b/sal/osl/unx/random.cxx
index a0fb73c..f9c9775 100644
--- a/sal/osl/unx/random.cxx
+++ b/sal/osl/unx/random.cxx
@@ -8,7 +8,7 @@
  */
 
 #include "system.hxx"
-#include "internal/oslrandom.h"
+#include "oslrandom.h"
 
 #include 
 
diff --git a/sal/osl/unx/signal.cxx b/sal/osl/unx/signal.cxx
index 73bb19d..fa8e3f2 100644
--- a/sal/osl/unx/signal.cxx
+++ b/sal/osl/unx/signal.cxx
@@ -19,7 +19,7 @@
 
 #include 
 
-#include 
+#include 
 
 #include 
 
diff --git a/sal/osl/w32/backtrace.cxx b/sal/osl/w32/backtrace.cxx
index 750cb15..5095d20 100644
--- a/sal/osl/w32/backtrace.cxx
+++ b/sal/osl/w32/backtrace.cxx
@@ -7,7 +7,7 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
  */
 
-#include "internal/misc.hxx"
+#include "misc.hxx"
 
 #include 
 #include 
diff --git a/sal/osl/w32/dllentry.c b/sal/osl/w32/dllentry.c
index c6e4fb6.

[Libreoffice-commits] core.git: Branch 'libreoffice-5-1' - include/svx sw/qa writerfilter/source

2016-04-07 Thread Miklos Vajna
 include/svx/pageitem.hxx   |4 +++-
 sw/qa/extras/rtfimport/data/tdf65642.rtf   |   23 +++
 sw/qa/extras/rtfimport/rtfimport.cxx   |8 
 writerfilter/source/dmapper/DomainMapper.cxx   |   12 
 writerfilter/source/dmapper/PropertyMap.cxx|4 
 writerfilter/source/dmapper/PropertyMap.hxx|3 +++
 writerfilter/source/rtftok/rtfdocumentimpl.cxx |   10 +-
 7 files changed, 62 insertions(+), 2 deletions(-)

New commits:
commit 8aa9fac23bc8f29de5e91293352f96c99418ddfc
Author: Miklos Vajna 
Date:   Tue Mar 22 08:09:01 2016 +0100

tdf#65642 RTF filter: import \pgnrestart and \pgnucltr

This implicitly adds support for DOCX import of  as well.

(cherry picked from commits abaf6bde4ee91c628bd55a7ec2e876a5d0ecff6e and
d29b75c402ea635b3865501e43c9f349885913af)

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

Change-Id: Ib19ecb8f7ca0c867ae3be2b41e49ac4cacfd5bb6
Reviewed-on: https://gerrit.libreoffice.org/23730
Tested-by: Jenkins 
Reviewed-by: Andras Timar 

diff --git a/include/svx/pageitem.hxx b/include/svx/pageitem.hxx
index 0a2b0c3..4c3ca3c 100644
--- a/include/svx/pageitem.hxx
+++ b/include/svx/pageitem.hxx
@@ -32,7 +32,9 @@ enum SvxNumType
 SVX_ARABIC,
 SVX_NUMBER_NONE,
 SVX_CHAR_SPECIAL,
-SVX_PAGEDESC
+SVX_PAGEDESC,
+SVX_BITMAP,
+SVX_CHARS_UPPER_LETTER_N
 };
 
 /*
diff --git a/sw/qa/extras/rtfimport/data/tdf65642.rtf 
b/sw/qa/extras/rtfimport/data/tdf65642.rtf
new file mode 100644
index 000..f13d221
--- /dev/null
+++ b/sw/qa/extras/rtfimport/data/tdf65642.rtf
@@ -0,0 +1,23 @@
+{\rtf1
+\pard\plain \ltrpar\ql 
\li0\ri0\sa200\sl276\slmult1\widctlpar\wrapdefault\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0
 \rtlch\fcs1 \af31507\afs22\alang1025 \ltrch\fcs0
+{\field\fldedit
+{\*\fldinst
+{ PAGE   \\* MERGEFORMAT }
+}
+{\fldrslt
+{1}
+}
+}
+\sect
+\sectd\pgnrestart\pgnucltr
+{\field\fldedit
+{\*\fldinst
+{\rtlch\fcs1 \af31507 \ltrch\fcs0 \insrsid525329  PAGE   \\* MERGEFORMAT }
+}
+{\fldrslt
+{\rtlch\fcs1 \af31507 \ltrch\fcs0 \lang1024\langfe1024\noproof\insrsid9597790 
A}
+}
+}
+{\rtlch\fcs1 \af31507 \ltrch\fcs0 \insrsid13321744
+\par }
+}
diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx 
b/sw/qa/extras/rtfimport/rtfimport.cxx
index 7573e96..1525c4a 100644
--- a/sw/qa/extras/rtfimport/rtfimport.cxx
+++ b/sw/qa/extras/rtfimport/rtfimport.cxx
@@ -2504,6 +2504,14 @@ DECLARE_RTFIMPORT_TEST(testTdf87034, "tdf87034.rtf")
 CPPUNIT_ASSERT_EQUAL(OUString("A1B3C4D"), getParagraph(1)->getString());
 }
 
+DECLARE_RTFIMPORT_TEST(testTdf65642, "tdf65642.rtf")
+{
+// The second page's numbering type: this was style::NumberingType::ARABIC.
+CPPUNIT_ASSERT_EQUAL(style::NumberingType::CHARS_UPPER_LETTER_N, 
getProperty(getStyles("PageStyles")->getByName("Converted1"), 
"NumberingType"));
+// The second page's restart value: this was 0.
+CPPUNIT_ASSERT_EQUAL(static_cast(1), 
getProperty(getParagraph(2), "PageNumberOffset"));
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/writerfilter/source/dmapper/DomainMapper.cxx 
b/writerfilter/source/dmapper/DomainMapper.cxx
index e350e2d..840e0e4 100644
--- a/writerfilter/source/dmapper/DomainMapper.cxx
+++ b/writerfilter/source/dmapper/DomainMapper.cxx
@@ -964,6 +964,18 @@ void DomainMapper::lcl_attribute(Id nName, Value & val)
 if (pSectionContext != nullptr)
 pSectionContext->SetPageNumber(nIntValue);
 break;
+case NS_ooxml::LN_CT_PageNumber_fmt:
+if (pSectionContext)
+{
+switch (nIntValue)
+{
+case NS_ooxml::LN_Value_ST_NumberFormat_upperLetter:
+// A, B, ...
+
pSectionContext->SetPageNumberType(style::NumberingType::CHARS_UPPER_LETTER_N);
+break;
+}
+}
+break;
 case NS_ooxml::LN_CT_FtnEdn_type:
 // This is the "separator" footnote, ignore its linebreak.
 if (static_cast(nIntValue) == 
NS_ooxml::LN_Value_doc_ST_FtnEdn_separator)
diff --git a/writerfilter/source/dmapper/PropertyMap.cxx 
b/writerfilter/source/dmapper/PropertyMap.cxx
index 90c4da3..3d712ba 100644
--- a/writerfilter/source/dmapper/PropertyMap.cxx
+++ b/writerfilter/source/dmapper/PropertyMap.cxx
@@ -404,6 +404,7 @@ SectionPropertyMap::SectionPropertyMap(bool 
bIsFirstSection) :
 ,m_bIsLandscape( false )
 ,m_bPageNoRestart( false )
 ,m_nPageNumber( -1 )
+,m_nPageNumberType(-1)
 ,m_nBreakType( -1 )
 ,m_nPaperBin( -1 )
 ,m_nFirstPaperBin( -1 )
@@ -1192,6 +1193,9 @@ void SectionPropertyMap::CloseSectionGroup( 
DomainMapper_Impl& rDM_Impl )
 nRubyHeight = 0;
 Insert(PROP_GRID_RUBY_HEIGHT, uno::makeAny( nRubyHeight ))

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

2016-04-07 Thread Miklos Vajna
 sw/inc/pagedesc.hxx  |1 
 sw/qa/extras/ww8import/data/tdf99100.doc |binary
 sw/qa/extras/ww8import/data/tdf99120.doc |binary
 sw/qa/extras/ww8import/ww8import.cxx |   18 +
 sw/source/filter/ww8/ww8par.cxx  |3 +-
 sw/source/filter/ww8/ww8par.hxx  |2 +
 sw/source/filter/ww8/ww8par5.cxx |   42 +--
 7 files changed, 63 insertions(+), 3 deletions(-)

New commits:
commit c945d4166087e09798d812a466a85d424482e08b
Author: Miklos Vajna 
Date:   Wed Apr 6 08:34:28 2016 +0200

tdf#99100 DOC import: handle subset of STYLEREF natively

Commit 4215bca95511af8e4ee96e3c8f521b35f638aef3 (export 'Chapter' field
type as 'StyleRef' into .doc, 2015-08-21) mapped SwChapterField to
STYLEREF in the DOC export. This field type was handled as a field mark
on import. Instead of always handling it as a field mark, recognize the
case when it's the subset we write and we can handle natively, and in
that case create an SwChapterField again on import.

Leave the complex case unchanged as before and keep using field marks
for that.

Also (because the header where STYLEREF is used is completely empty
otherwise):

tdf#99120 DOC import: fix lack of first share after odd section break

Commit 848b1a05c5c41b5e7ff19c984f60c297a8143990 (fix for bnc#659631,
2011-02-04) made wwSectionManager::InsertSegments() use
SwPageDesc::WriteUseOn() directly, instead of going via
SwPageDesc::SetUseOn() that takes care of not throwing away the higher
share bits of the bitfield. This way the "is first shared" flag of the
bitfield got cleared, even when the input document had no title page
declared, so first header/footer must be shared.

Fix the problem by using SetUseOn() in the DOC import as well when it
comes to handling odd/even page section breaks.

(cherry picked from commits d635b351849b8b576c907abf22500d0fa89ab54f and
44a3eb37cd982c59f8350d53db3798b675230b35)

Change-Id: Icfa8c4be6538da5e02e2d5071af30a46ccfa712b
Reviewed-on: https://gerrit.libreoffice.org/23888
Tested-by: Jenkins 
Reviewed-by: Andras Timar 

diff --git a/sw/inc/pagedesc.hxx b/sw/inc/pagedesc.hxx
index db943eb..74551aa 100644
--- a/sw/inc/pagedesc.hxx
+++ b/sw/inc/pagedesc.hxx
@@ -189,6 +189,7 @@ public:
 bool IsHidden() const { return m_IsHidden; }
 void SetHidden(bool const bValue) { m_IsHidden = bValue; }
 
+/// Same as WriteUseOn(), but the >= PD_HEADERSHARE part of the bitfield 
is not modified.
 inline void  SetUseOn( UseOnPage eNew );
 inline UseOnPage GetUseOn() const;
 
diff --git a/sw/qa/extras/ww8import/data/tdf99100.doc 
b/sw/qa/extras/ww8import/data/tdf99100.doc
new file mode 100644
index 000..6352ae3
Binary files /dev/null and b/sw/qa/extras/ww8import/data/tdf99100.doc differ
diff --git a/sw/qa/extras/ww8import/data/tdf99120.doc 
b/sw/qa/extras/ww8import/data/tdf99120.doc
new file mode 100644
index 000..a93721c
Binary files /dev/null and b/sw/qa/extras/ww8import/data/tdf99120.doc differ
diff --git a/sw/qa/extras/ww8import/ww8import.cxx 
b/sw/qa/extras/ww8import/ww8import.cxx
index 7e9307b..1df4a6c 100644
--- a/sw/qa/extras/ww8import/ww8import.cxx
+++ b/sw/qa/extras/ww8import/ww8import.cxx
@@ -535,6 +535,24 @@ DECLARE_WW8IMPORT_TEST(testfdo68963, "fdo68963.doc")
 CPPUNIT_ASSERT ( -1 == 
parseDump("/root/page/body/txt[24]/Special[2]","rText").indexOf("Reference 
source not found"));
 }
 
+DECLARE_WW8IMPORT_TEST(testTdf99100, "tdf99100.doc")
+{
+uno::Reference xHeaderText = getProperty< 
uno::Reference >(getStyles("PageStyles")->getByName("Standard"), 
"HeaderText");
+auto xField = getProperty< uno::Reference 
>(getRun(getParagraphOfText(1, xHeaderText), 2), "TextField");
+// This failed: the second text portion wasn't a field.
+CPPUNIT_ASSERT(xField.is());
+
CPPUNIT_ASSERT(xField->supportsService("com.sun.star.text.textfield.Chapter"));
+}
+
+DECLARE_WW8IMPORT_TEST(testTdf99120, "tdf99120.doc")
+{
+CPPUNIT_ASSERT_EQUAL(OUString("Section 1, odd."),  
parseDump("/root/page[1]/header/txt/text()"));
+CPPUNIT_ASSERT_EQUAL(OUString("Section 1, even."),  
parseDump("/root/page[2]/header/txt/text()"));
+// This failed: the header was empty on the 3rd page, as the first page 
header was shown.
+CPPUNIT_ASSERT_EQUAL(OUString("Section 2, odd."),  
parseDump("/root/page[3]/header/txt/text()"));
+CPPUNIT_ASSERT_EQUAL(OUString("Section 2, even."),  
parseDump("/root/page[4]/header/txt/text()"));
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index 95e6424..ee072bf 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -4526,7 +4526,8 @@ void wwSectionManager::InsertSegments()
 if ( aIter->maSep.bkc == 4 ) // Odd ( 

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

2016-04-07 Thread Stephan Bergmann
 include/svx/tbxcolorupdate.hxx |3 +++
 1 file changed, 3 insertions(+)

New commits:
commit 8faf41a1d5572f2360ac79396310b6250a470528
Author: Stephan Bergmann 
Date:   Thu Apr 7 11:24:04 2016 +0200

Prevent MSVC from emitting special member functions of dllexport class

...that fail instantiation when ToolBox is incomplete (which is normally 
hidden
by --enable-pch).

Change-Id: I49ea33cecae9f44dfcd9c7bd8bf0f00f3548ed94

diff --git a/include/svx/tbxcolorupdate.hxx b/include/svx/tbxcolorupdate.hxx
index ed807b5..34e1689 100644
--- a/include/svx/tbxcolorupdate.hxx
+++ b/include/svx/tbxcolorupdate.hxx
@@ -51,6 +51,9 @@ namespace svx
 voidUpdate( const Color& rColor, bool bForceUpdate = false );
 
 private:
+ToolboxButtonColorUpdater(ToolboxButtonColorUpdater &) = delete;
+void operator =(ToolboxButtonColorUpdater) = delete;
+
 sal_uInt16  mnBtnId;
 sal_uInt16  mnSlotId;
 VclPtr mpTbx;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Stephan Bergmann
 external/hunspell/UnpackedTarball_hunspell.mk |1 +
 external/hunspell/ubsan.patch.0   |   11 +++
 2 files changed, 12 insertions(+)

New commits:
commit 16048590bb486ffa3b0a257c31390dc500f7360a
Author: Stephan Bergmann 
Date:   Thu Apr 7 11:08:55 2016 +0200

external/hunspell: -fsanitize=shift

Change-Id: Ifc78a8f1a0a6fa29ef9becc5432e581f42241467

diff --git a/external/hunspell/UnpackedTarball_hunspell.mk 
b/external/hunspell/UnpackedTarball_hunspell.mk
index e70e33f..7ce4aea 100644
--- a/external/hunspell/UnpackedTarball_hunspell.mk
+++ b/external/hunspell/UnpackedTarball_hunspell.mk
@@ -14,6 +14,7 @@ $(eval $(call 
gb_UnpackedTarball_set_tarball,hunspell,$(HUNSPELL_TARBALL)))
 $(eval $(call gb_UnpackedTarball_add_patches,hunspell,\
external/hunspell/hunspell-solaris.patch \
external/hunspell/hunspell-windows.patch \
+   external/hunspell/ubsan.patch.0 \
 ))
 
 ifeq ($(COM),MSC)
diff --git a/external/hunspell/ubsan.patch.0 b/external/hunspell/ubsan.patch.0
new file mode 100644
index 000..af25d6a
--- /dev/null
+++ b/external/hunspell/ubsan.patch.0
@@ -0,0 +1,11 @@
+--- src/hunspell/csutil.cxx
 src/hunspell/csutil.cxx
+@@ -281,7 +281,7 @@
+   u2->h = ((*u8 & 0x0f) << 4) + ((*(u8 + 1) & 0x3f) >> 2);
+   u8++;
+   if ((*(u8 + 1) & 0xc0) == 0x80) {
+-u2->l = (*u8 << 6) + (*(u8 + 1) & 0x3f);
++u2->l = (static_cast(*u8) << 6) + (*(u8 + 1) & 
0x3f);
+ u8++;
+   } else {
+ HUNSPELL_WARNING(stderr,
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Michael Stahl
 sw/inc/pch/precompiled_msword.hxx   |1 -
 sw/inc/pch/precompiled_sw.hxx   |1 -
 sw/inc/pch/precompiled_swui.hxx |1 -
 sw/inc/pch/precompiled_vbaswobj.hxx |1 -
 sw/source/core/doc/tblafmt.cxx  |7 ---
 sw/source/filter/ww8/wrtw8sty.cxx   |6 --
 sw/source/filter/ww8/wrtww8.cxx |   11 ---
 sw/source/filter/ww8/ww8par.cxx |6 --
 sw/source/filter/ww8/ww8par.hxx |   19 +++
 sw/source/filter/ww8/ww8par2.cxx|   12 +---
 sw/source/filter/xml/xmlimpit.cxx   |6 --
 sw/source/ui/dbui/dbinsdlg.cxx  |6 --
 sw/source/uibase/app/swdllimpl.hxx  |6 --
 sw/source/uibase/sidebar/SwPanelFactory.cxx |   10 ++
 sw/source/uibase/uno/unomailmerge.cxx   |   13 +
 15 files changed, 71 insertions(+), 35 deletions(-)

New commits:
commit 082005bf81b1c72da042193449974bbb610ca85f
Author: Michael Stahl 
Date:   Wed Apr 6 17:47:34 2016 +0200

sw: replace boost::noncopyable with C++11 delete

Change-Id: Iac20763c7d1db467420f9c2fbb3cd636839d4c80

diff --git a/sw/inc/pch/precompiled_sw.hxx b/sw/inc/pch/precompiled_sw.hxx
index 53ad3c2..e085bba 100644
--- a/sw/inc/pch/precompiled_sw.hxx
+++ b/sw/inc/pch/precompiled_sw.hxx
@@ -52,7 +52,6 @@
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 
diff --git a/sw/inc/pch/precompiled_swui.hxx b/sw/inc/pch/precompiled_swui.hxx
index f49478c..480012e 100644
--- a/sw/inc/pch/precompiled_swui.hxx
+++ b/sw/inc/pch/precompiled_swui.hxx
@@ -61,7 +61,6 @@
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 
diff --git a/sw/source/core/doc/tblafmt.cxx b/sw/source/core/doc/tblafmt.cxx
index 9edc798..a9e3d58 100644
--- a/sw/source/core/doc/tblafmt.cxx
+++ b/sw/source/core/doc/tblafmt.cxx
@@ -41,8 +41,6 @@
 #include 
 #include 
 
-#include 
-
 #include 
 #include 
 
@@ -130,7 +128,7 @@ namespace
 
 See also: BeginSwBlock and EndSwBlock.
 */
-class WriterSpecificAutoFormatBlock : private ::boost::noncopyable
+class WriterSpecificAutoFormatBlock
 {
 public:
 explicit WriterSpecificAutoFormatBlock(SvStream &rStream) : 
_rStream(rStream)
@@ -144,6 +142,9 @@ namespace
 }
 
 private:
+WriterSpecificAutoFormatBlock(WriterSpecificAutoFormatBlock const&) = 
delete;
+WriterSpecificAutoFormatBlock& operator=(WriterSpecificAutoFormatBlock 
const&) = delete;
+
 SvStream &_rStream;
 sal_uInt64 _whereToWriteEndOfBlock;
 };
diff --git a/sw/source/ui/dbui/dbinsdlg.cxx b/sw/source/ui/dbui/dbinsdlg.cxx
index ae4abb0..b0153bd 100644
--- a/sw/source/ui/dbui/dbinsdlg.cxx
+++ b/sw/source/ui/dbui/dbinsdlg.cxx
@@ -91,7 +91,6 @@
 
 #include 
 
-#include 
 #include 
 #include 
 
@@ -157,7 +156,7 @@ struct DB_Column
 }
 };
 
-struct DB_ColumnConfigData: private boost::noncopyable
+struct DB_ColumnConfigData
 {
 SwInsDBColumns aDBColumns;
 OUString sSource;
@@ -171,6 +170,9 @@ struct DB_ColumnConfigData: private boost::noncopyable
  bIsHeadlineOn : 1,
  bIsEmptyHeadln : 1;
 
+DB_ColumnConfigData(DB_ColumnConfigData const&) = delete;
+DB_ColumnConfigData& operator=(DB_ColumnConfigData const&) = delete;
+
 DB_ColumnConfigData()
 {
 bIsTable = bIsHeadlineOn = true;
diff --git a/sw/source/uibase/app/swdllimpl.hxx 
b/sw/source/uibase/app/swdllimpl.hxx
index 06f277c..57a34be 100644
--- a/sw/source/uibase/app/swdllimpl.hxx
+++ b/sw/source/uibase/app/swdllimpl.hxx
@@ -12,12 +12,11 @@
 
 #include 
 
-#include 
 #include 
 
 namespace sw { class Filters; }
 
-class SwDLL: private boost::noncopyable
+class SwDLL
 {
 public:
 static void RegisterFactories();
@@ -30,6 +29,9 @@ public:
 sw::Filters & getFilters();
 
 private:
+SwDLL(SwDLL const&) = delete;
+SwDLL& operator=(SwDLL const&) = delete;
+
 std::unique_ptr< sw::Filters > filters_;
 };
 
diff --git a/sw/source/uibase/sidebar/SwPanelFactory.cxx 
b/sw/source/uibase/sidebar/SwPanelFactory.cxx
index dc048745..ed9263b 100644
--- a/sw/source/uibase/sidebar/SwPanelFactory.cxx
+++ b/sw/source/uibase/sidebar/SwPanelFactory.cxx
@@ -37,7 +37,6 @@
 #include 
 #include 
 
-#include 
 
 using namespace css;
 using namespace css::uno;
@@ -49,10 +48,13 @@ typedef ::cppu::WeakComponentImplHelper <
 > PanelFactoryInterfaceBase;
 
 class SwPanelFactory
-: private ::boost::noncopyable,
-  private ::cppu::BaseMutex,
-  public PanelFactoryInterfaceBase
+: private ::cppu::BaseMutex
+, public PanelFactoryInterfaceBase
 {
+private:
+SwPanelFactory(SwPanelFactory const&) = delete;
+SwPanelFactory& operator=(SwPanelFactory const&) = delete;
+
 public:
 SwPanelFactory();
 virtual ~SwPanelFactory();
diff --git a/sw/source/uibase/uno/unomailmerge.cxx 
b/sw/source/uibase/uno/unomailmerge.cxx
index d29be10..7c8a602 100644
-

[Libreoffice-commits] online.git: 10 commits - loolwsd/Admin.cpp loolwsd/Admin.hpp loolwsd/ChildProcessSession.cpp loolwsd/debian loolwsd/DocumentBroker.hpp loolwsd/IoUtil.cpp loolwsd/LOOLForKit.cpp l

2016-04-07 Thread Tor Lillqvist
 loolwsd/Admin.cpp|   13 ++---
 loolwsd/Admin.hpp|   10 +---
 loolwsd/ChildProcessSession.cpp  |5 --
 loolwsd/DocumentBroker.hpp   |2 
 loolwsd/IoUtil.cpp   |3 -
 loolwsd/LOOLForKit.cpp   |   43 +++---
 loolwsd/LOOLKit.cpp  |   33 ++
 loolwsd/LOOLSession.cpp  |4 -
 loolwsd/LOOLWSD.cpp  |   91 +++
 loolwsd/LOOLWSD.hpp  |4 -
 loolwsd/MasterProcessSession.cpp |2 
 loolwsd/QueueHandler.hpp |3 -
 loolwsd/README   |   50 ++---
 loolwsd/Util.cpp |   26 ++-
 loolwsd/Util.hpp |7 ++-
 loolwsd/debian/loolwsd.postinst  |2 
 loolwsd/loolstat |2 
 loolwsd/loolwsd.spec.in  |2 
 18 files changed, 144 insertions(+), 158 deletions(-)

New commits:
commit 175bd4c9e2b31dbd1d5cfbfcf0c91261b56ce085
Author: Tor Lillqvist 
Date:   Thu Apr 7 11:52:48 2016 +0300

Use the actual current process names here, too

diff --git a/loolwsd/loolstat b/loolwsd/loolstat
index 642c891..2c0e3f2 100755
--- a/loolwsd/loolstat
+++ b/loolwsd/loolstat
@@ -64,7 +64,7 @@ fi
 $PSTREE -a -c -h -A -p $LOOLWSD_PID;
 
 # get the number of running processes.
-PROCESS=$($PSTREE -a -h -A -p $LOOLWSD_PID | $SED -e "s/\`//g" | $TR -d ' |-' 
| $GREP -E '^loolwsd|^loolbroker|^libreofficekit' | $WC -l);
+PROCESS=$($PSTREE -a -h -A -p $LOOLWSD_PID | $SED -e "s/\`//g" | $TR -d ' |-' 
| $GREP -E '^loolwsd|^loolforkit|^loolkit' | $WC -l);
 
 # get the number of running threads.
 THREADS=$($PSTREE -a -h -A -p $LOOLWSD_PID | $GREP -o '{.*}' | $WC -l);
commit 931550b43512f7d6f7e9075ab9fc1b10aad7604b
Author: Tor Lillqvist 
Date:   Thu Apr 7 11:49:26 2016 +0300

Quite essential to change loolbroker to loolforkit here, too

diff --git a/loolwsd/debian/loolwsd.postinst b/loolwsd/debian/loolwsd.postinst
index d2b50ec..7363fd6 100755
--- a/loolwsd/debian/loolwsd.postinst
+++ b/loolwsd/debian/loolwsd.postinst
@@ -4,7 +4,7 @@ set -e
 
 case "$1" in
 configure)
-   setcap cap_fowner,cap_mknod,cap_sys_chroot=ep /usr/bin/loolbroker || 
true
+   setcap cap_fowner,cap_mknod,cap_sys_chroot=ep /usr/bin/loolforkit || 
true
 
adduser --quiet --system --group --home /opt/lool lool
mkdir -p /var/cache/loolwsd && chown lool: /var/cache/loolwsd
diff --git a/loolwsd/loolwsd.spec.in b/loolwsd/loolwsd.spec.in
index bae0835..555a6fd 100644
--- a/loolwsd/loolwsd.spec.in
+++ b/loolwsd/loolwsd.spec.in
@@ -69,7 +69,7 @@ echo "0 0 */1 * * root find /var/cache/loolwsd -name 
\"*.png\" -a -atime +10 -ex
 %service_add_pre loolwsd.service
 
 %post
-setcap cap_fowner,cap_mknod,cap_sys_chroot=ep /usr/bin/loolbroker
+setcap cap_fowner,cap_mknod,cap_sys_chroot=ep /usr/bin/loolforkit
 
 getent group %{group} >/dev/null || groupadd -r %{group}
 getent passwd %{owner} >/dev/null || useradd -g %{group} -r %{owner}
commit 84cd6bbcebdb47503a049434359ab0369fff3626
Author: Tor Lillqvist 
Date:   Thu Apr 7 11:27:43 2016 +0300

Try to be more consistent in terminology

The "Broker" process is called "ForKit" now. The only things called
"broker" now are the DocumentBroker objects in the WSD process.

diff --git a/loolwsd/Admin.cpp b/loolwsd/Admin.cpp
index e884550..2d7e2a8 100644
--- a/loolwsd/Admin.cpp
+++ b/loolwsd/Admin.cpp
@@ -126,7 +126,7 @@ void 
AdminRequestHandler::handleWSRequests(HTTPServerRequest& request, HTTPServe
 if (tokens[0] == "stats")
 {
 //TODO: Collect stats and reply back to admin.
-// We need to ask Broker to give us some numbers on 
docs/clients/etc.
+// We need to ask ForKit to give us some numbers on 
docs/clients/etc.
 // But we can also collect some memory info using 
system calls.
 
 std::string statsResponse;
@@ -194,7 +194,7 @@ void 
AdminRequestHandler::handleWSRequests(HTTPServerRequest& request, HTTPServe
 {
 if (std::stoi(tokens[1]))
 {
-IoUtil::writeFIFO(LOOLWSD::BrokerWritePipe, 
firstLine + "\n");
+IoUtil::writeFIFO(LOOLWSD::ForKitWritePipe, 
firstLine + "\n");
 }
 }
 catch(std::exception& e)
@@ -424,7 +424,7 @@ void Admin::rescheduleCpuTimer(unsigned interval)
 
 unsigned Admin::getTotalMemoryUsage(AdminModel& model)
 {
-unsigned totalMem = Util::getMemoryUsage(_brokerPid);
+unsigned totalMem = Util::getMemoryUsage(_forKitPid);
 totalMem += model.getTotalMemoryUsage();
 totalMem += Util::getMemoryUsage(Poco::Process::id());
 
diff --git a/loolwsd/Admin.hpp b/loolwsd/Admin.hpp
index a235669..c5a6258 100644
--- a/loolwsd/Admin.hpp
+++ b/loolw

[Libreoffice-commits] core.git: desktop/unx

2016-04-07 Thread Bjoern Michaelsen
 desktop/unx/source/file_image_unx.c |   30 +++---
 1 file changed, 11 insertions(+), 19 deletions(-)

New commits:
commit 71aa80300c89c726254049f775d1c48518b6dfe4
Author: Bjoern Michaelsen 
Date:   Thu Apr 7 01:32:05 2016 +0200

refactor pagein, as it still seems to cause rare crashes

Change-Id: I51e6cdf79c19c3709e00dc10175527ec6583a758
Reviewed-on: https://gerrit.libreoffice.org/23872
Tested-by: Jenkins 
Reviewed-by: Michael Meeks 
Tested-by: Michael Meeks 

diff --git a/desktop/unx/source/file_image_unx.c 
b/desktop/unx/source/file_image_unx.c
index 522c491..ec229f9 100644
--- a/desktop/unx/source/file_image_unx.c
+++ b/desktop/unx/source/file_image_unx.c
@@ -74,37 +74,29 @@ cleanup_and_leave:
  */
 int file_image_pagein (file_image * image)
 {
-file_imagew;
-long  s;
-size_tk;
-// force touching of each page despite the optimizer
+long s = -1;
 volatile char c =0;
+size_t idx;
 
 if (image == NULL)
 return EINVAL;
-
-if ((w.m_base = image->m_base) == NULL)
+if (image->m_base == NULL)
 return EINVAL;
-if ((w.m_size = image->m_size) == 0)
+if (image->m_size == 0)
 return 0;
 
-if (madvise (w.m_base, w.m_size, MADV_WILLNEED) == -1)
+if (madvise (image->m_base, image->m_size, MADV_WILLNEED) == -1)
 return errno;
 
-if ((s = sysconf (_SC_PAGESIZE)) == -1)
+s = sysconf (_SC_PAGESIZE);
+if (s == -1)
 s = 0x1000;
-
-k = (size_t)(s);
-while (w.m_size > k)
-{
-c ^= ((char*)(w.m_base))[0];
-w.m_base  = (char*)(w.m_base) + k;
-w.m_size -= k;
-}
-if (w.m_size > 0)
+// force touching of each page despite the optimizer
+for(idx = 0; idx < image->m_size; idx += (size_t)s)
 {
-c ^= ((char*)(w.m_base))[0];
+c ^= ((volatile const char*)(image->m_base))[idx];
 }
+c ^= ((volatile const char*)(image->m_base))[image->m_size-1];
 
 return 0;
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Jan Holesovsky
 sw/uiconfig/swriter/ui/notebookbar.ui | 3202 --
 1 file changed, 3092 insertions(+), 110 deletions(-)

New commits:
commit b8454666ec08cab835af56ba473843397052156a
Author: Jan Holesovsky 
Date:   Thu Apr 7 10:26:17 2016 +0200

notebookbar: Reduce the vertical space between buttons.

Change-Id: I6cb7761503e36cfce421b23275dd0bd71f5179ca

diff --git a/sw/uiconfig/swriter/ui/notebookbar.ui 
b/sw/uiconfig/swriter/ui/notebookbar.ui
index a7bf8b9..1eac9e5 100644
--- a/sw/uiconfig/swriter/ui/notebookbar.ui
+++ b/sw/uiconfig/swriter/ui/notebookbar.ui
@@ -33,7 +33,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -948,7 +947,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -1087,7 +1085,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -1273,7 +1270,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -1555,7 +1551,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -1616,7 +1611,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -1733,7 +1727,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -2145,7 +2138,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -2248,7 +2240,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -2376,7 +2367,6 @@
 True
 False
 vertical
-6
 
   
 
@@ -2618,7 +2608,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -2679,7 +2668,6 @@
 True
 False
 vertical
-6
 True
 
   
@@ -2725,7 +2713,6 @@
 True
 False
 vertical
-6
 True
 
   
@@ -2928,7 +2915,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -3038,7 +3024,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -3156,7 +3141,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -3231,7 +3215,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -3305,7 +3288,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -3363,7 +3345,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -3440,7 +3421,6 @@
 True
 False
 vertical
-6
 
   
 True
@@ -3498,7 +3478,6 @@
  

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

2016-04-07 Thread Noel Grandin
 sw/source/ui/misc/num.cxx|   15 +++
 sw/source/uibase/inc/num.hxx |3 +++
 2 files changed, 18 insertions(+)

New commits:
commit f664089b0692c649d3a88e2a0817544f70ac271a
Author: Noel Grandin 
Date:   Tue Apr 5 09:40:43 2016 +0200

tdf#98647 fix bug in tools->outline-numbering

fallout from
commit e85b2333bce7b1dcae73861df6d90b48b9f4efe5
"convert Link<> to typed"

Change-Id: I8f98bcf6d1eff596e139f9f3a2e3d32fcce67d11
(cherry picked from commit c10d56c6c33ad27d9f4fb12e499a8b246d88da9f)
Reviewed-on: https://gerrit.libreoffice.org/23837
Tested-by: Jenkins 
Reviewed-by: David Tardon 

diff --git a/sw/source/ui/misc/num.cxx b/sw/source/ui/misc/num.cxx
index 272e789..b0e4ae9 100644
--- a/sw/source/ui/misc/num.cxx
+++ b/sw/source/ui/misc/num.cxx
@@ -131,16 +131,19 @@ SwNumPositionTabPage::SwNumPositionTabPage(vcl::Window* 
pParent,
 m_pLabelFollowedByLB->SetSelectHdl( LINK(this, SwNumPositionTabPage, 
LabelFollowedByHdl_Impl) );
 
 aLk = LINK(this, SwNumPositionTabPage, ListtabPosHdl_Impl);
+aLk2 = LINK(this, SwNumPositionTabPage, ListtabPosFocusHdl_Impl);
 m_pListtabMF->SetUpHdl(aLk);
 m_pListtabMF->SetDownHdl(aLk);
 m_pListtabMF->SetLoseFocusHdl(aLk2);
 
 aLk = LINK(this, SwNumPositionTabPage, AlignAtHdl_Impl);
+aLk2 = LINK(this, SwNumPositionTabPage, AlignAtFocusHdl_Impl);
 m_pAlignedAtMF->SetUpHdl(aLk);
 m_pAlignedAtMF->SetDownHdl(aLk);
 m_pAlignedAtMF->SetLoseFocusHdl(aLk2);
 
 aLk = LINK(this, SwNumPositionTabPage, IndentAtHdl_Impl);
+aLk2 = LINK(this, SwNumPositionTabPage, IndentAtFocusHdl_Impl);
 m_pIndentAtMF->SetUpHdl(aLk);
 m_pIndentAtMF->SetDownHdl(aLk);
 m_pIndentAtMF->SetLoseFocusHdl(aLk2);
@@ -818,6 +821,10 @@ IMPL_LINK_NOARG_TYPED(SwNumPositionTabPage, 
LabelFollowedByHdl_Impl, ListBox&, v
 SetModified();
 }
 
+IMPL_LINK_TYPED( SwNumPositionTabPage, ListtabPosFocusHdl_Impl, Control&, 
rControl, void )
+{
+ListtabPosHdl_Impl(static_cast(rControl));
+}
 IMPL_LINK_TYPED( SwNumPositionTabPage, ListtabPosHdl_Impl, SpinField&, rSpin, 
void )
 {
 MetricField& rField = static_cast(rSpin);
@@ -840,6 +847,10 @@ IMPL_LINK_TYPED( SwNumPositionTabPage, ListtabPosHdl_Impl, 
SpinField&, rSpin, vo
 SetModified();
 }
 
+IMPL_LINK_TYPED( SwNumPositionTabPage, AlignAtFocusHdl_Impl, Control&, 
rControl, void )
+{
+AlignAtHdl_Impl(static_cast(rControl));
+}
 IMPL_LINK_TYPED( SwNumPositionTabPage, AlignAtHdl_Impl, SpinField&, rSpin, 
void )
 {
 MetricField& rField = static_cast(rSpin);
@@ -863,6 +874,10 @@ IMPL_LINK_TYPED( SwNumPositionTabPage, AlignAtHdl_Impl, 
SpinField&, rSpin, void
 SetModified();
 }
 
+IMPL_LINK_TYPED( SwNumPositionTabPage, IndentAtFocusHdl_Impl, Control&, 
rControl, void )
+{
+IndentAtHdl_Impl(static_cast(rControl));
+}
 IMPL_LINK_TYPED( SwNumPositionTabPage, IndentAtHdl_Impl, SpinField&, rSpin, 
void )
 {
 MetricField& rField = static_cast(rSpin);
diff --git a/sw/source/uibase/inc/num.hxx b/sw/source/uibase/inc/num.hxx
index fb5880b..59fa929 100644
--- a/sw/source/uibase/inc/num.hxx
+++ b/sw/source/uibase/inc/num.hxx
@@ -96,8 +96,11 @@ class SwNumPositionTabPage : public SfxTabPage
 
 DECL_LINK_TYPED(LabelFollowedByHdl_Impl, ListBox&, void);
 DECL_LINK_TYPED( ListtabPosHdl_Impl, SpinField&, void );
+DECL_LINK_TYPED( ListtabPosFocusHdl_Impl, Control&, void );
 DECL_LINK_TYPED( AlignAtHdl_Impl, SpinField&, void );
+DECL_LINK_TYPED( AlignAtFocusHdl_Impl, Control&, void );
 DECL_LINK_TYPED( IndentAtHdl_Impl, SpinField&, void );
+DECL_LINK_TYPED( IndentAtFocusHdl_Impl, Control&, void );
 
 using SfxTabPage::ActivatePage;
 using SfxTabPage::DeactivatePage;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Build problems for Libreoffice on Windows 7

2016-04-07 Thread Stephan Bergmann

On 04/06/2016 02:17 PM, jan iversen wrote:

it turned out to be a rather general problem for building master on
Windows < 8 since Monday, fixed now with commit
279c31469ff2d6fe7c32b43827f6f88ddff1916e


Which sort of highlights, my other email about having a buildable master, 
somehow.


Which sort of highlights that "buildable" is a rather fuzzy predicate, 
in that what builds fine for a bot (e.g., running Windows 8) not 
necessarily builds fine for somebody else (e.g., running Windows 7).

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


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

2016-04-07 Thread Miklos Vajna
 sw/inc/pagedesc.hxx  |1 +
 sw/qa/extras/ww8import/data/tdf99120.doc |binary
 sw/qa/extras/ww8import/ww8import.cxx |9 +
 sw/source/filter/ww8/ww8par.cxx  |3 ++-
 4 files changed, 12 insertions(+), 1 deletion(-)

New commits:
commit 44a3eb37cd982c59f8350d53db3798b675230b35
Author: Miklos Vajna 
Date:   Thu Apr 7 09:06:15 2016 +0200

tdf#99120 DOC import: fix lack of first share after odd section break

Commit 848b1a05c5c41b5e7ff19c984f60c297a8143990 (fix for bnc#659631,
2011-02-04) made wwSectionManager::InsertSegments() use
SwPageDesc::WriteUseOn() directly, instead of going via
SwPageDesc::SetUseOn() that takes care of not throwing away the higher
share bits of the bitfield. This way the "is first shared" flag of the
bitfield got cleared, even when the input document had no title page
declared, so first header/footer must be shared.

Fix the problem by using SetUseOn() in the DOC import as well when it
comes to handling odd/even page section breaks.

Change-Id: If167f4582919fa177840ed81e0a53aa379485598
Reviewed-on: https://gerrit.libreoffice.org/23885
Reviewed-by: Miklos Vajna 
Tested-by: Jenkins 

diff --git a/sw/inc/pagedesc.hxx b/sw/inc/pagedesc.hxx
index 16c54bd..4553d81 100644
--- a/sw/inc/pagedesc.hxx
+++ b/sw/inc/pagedesc.hxx
@@ -189,6 +189,7 @@ public:
 bool IsHidden() const { return m_IsHidden; }
 void SetHidden(bool const bValue) { m_IsHidden = bValue; }
 
+/// Same as WriteUseOn(), but the >= PD_HEADERSHARE part of the bitfield 
is not modified.
 inline void  SetUseOn( UseOnPage eNew );
 inline UseOnPage GetUseOn() const;
 
diff --git a/sw/qa/extras/ww8import/data/tdf99120.doc 
b/sw/qa/extras/ww8import/data/tdf99120.doc
new file mode 100644
index 000..a93721c
Binary files /dev/null and b/sw/qa/extras/ww8import/data/tdf99120.doc differ
diff --git a/sw/qa/extras/ww8import/ww8import.cxx 
b/sw/qa/extras/ww8import/ww8import.cxx
index 689cd86..8727a00 100644
--- a/sw/qa/extras/ww8import/ww8import.cxx
+++ b/sw/qa/extras/ww8import/ww8import.cxx
@@ -544,6 +544,15 @@ DECLARE_WW8IMPORT_TEST(testTdf99100, "tdf99100.doc")
 
CPPUNIT_ASSERT(xField->supportsService("com.sun.star.text.textfield.Chapter"));
 }
 
+DECLARE_WW8IMPORT_TEST(testTdf99120, "tdf99120.doc")
+{
+CPPUNIT_ASSERT_EQUAL(OUString("Section 1, odd."),  
parseDump("/root/page[1]/header/txt/text()"));
+CPPUNIT_ASSERT_EQUAL(OUString("Section 1, even."),  
parseDump("/root/page[2]/header/txt/text()"));
+// This failed: the header was empty on the 3rd page, as the first page 
header was shown.
+CPPUNIT_ASSERT_EQUAL(OUString("Section 2, odd."),  
parseDump("/root/page[3]/header/txt/text()"));
+CPPUNIT_ASSERT_EQUAL(OUString("Section 2, even."),  
parseDump("/root/page[4]/header/txt/text()"));
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index 7088a0b..72919f6 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -4536,7 +4536,8 @@ void wwSectionManager::InsertSegments()
 if ( aIter->maSep.bkc == 4 ) // Odd ( right ) Section break
 eUseOnPage = nsUseOnPage::PD_RIGHT;
 
-aDesc.GetPageDesc()->WriteUseOn( eUseOnPage );
+// Keep the share flags.
+aDesc.GetPageDesc()->SetUseOn( eUseOnPage );
 aDesc.GetPageDesc()->SetFollow( aFollow.GetPageDesc() );
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dictionaries.git: hr_HR/description.xml hr_HR/hr_HR.aff hr_HR/hr_HR.dic hr_HR/README_hr_HR.txt

2016-04-07 Thread Krunoslav Šebetić
 hr_HR/README_hr_HR.txt |   17 
 hr_HR/description.xml  |2 
 hr_HR/hr_HR.aff| 1204 
 hr_HR/hr_HR.dic|125190 
-
 4 files changed, 63512 insertions(+), 62901 deletions(-)

New commits:
commit de93f4fc07eba5fac0ae40bb45cc8e6acb331743
Author: Krunoslav Šebetić 
Date:   Sun Apr 3 22:56:44 2016 +0200

Update Croatian dictionary

- Corrected few words, added part of the speech, replaced some incomplete 
classes.
- Added new author
- Large update of AFF-file
  It was necessary to restructure the file to be able to do regular and 
systematic
  updates. Added new sections like ICONV, updated REP section, added quite 
a few
  sfx classes and more.
- Changed 'Version value' field to 2016.04.03.

Change-Id: I6d17729f52f4204e93342a35bfbcb60cdf8ce414
Reviewed-on: https://gerrit.libreoffice.org/23845
Reviewed-by: Kruno 
Reviewed-by: David Tardon 
Tested-by: David Tardon 

diff --git a/hr_HR/README_hr_HR.txt b/hr_HR/README_hr_HR.txt
index 0ecb3a3..f4d6f16 100644
--- a/hr_HR/README_hr_HR.txt
+++ b/hr_HR/README_hr_HR.txt
@@ -1,6 +1,15 @@
-OpenOffice dictionary
---
+Husnpellov rječnik za računalnu provjeru pravopisa hrvatskog jezika
+
+Ovaj je rječnik nadopuna i nadogradnja rječnika D. L. iz 2003. g. [1]
+
+Language: Croatian (hr HR).
+License: LGPL/SISSL license, 2016
+Author:   k r u n o . s e [ a t ] g m x . c o m   (Kruno)
+
 
 Language: Croatian (hr HR).
-License:  LGPL/SISSL license, 2003
-Author:   dela...@linux.hr (Denis Lackovic)
+License: LGPL/SISSL license, 2003
+Author:   d e l a c k o [ a t ] l i n u x . h r   (Denis Lackovic)
+
+
+[1] http://cvs.linux.hr/spell/
diff --git a/hr_HR/description.xml b/hr_HR/description.xml
index ef3e474..8fd8c40 100644
--- a/hr_HR/description.xml
+++ b/hr_HR/description.xml
@@ -1,6 +1,6 @@
 
 http://openoffice.org/extensions/description/2006"; 
xmlns:d="http://openoffice.org/extensions/description/2006";  
xmlns:xlink="http://www.w3.org/1999/xlink";>
-
+
 
 
 Croatian spelling dictionary, and hyphenation 
rules
diff --git a/hr_HR/hr_HR.aff b/hr_HR/hr_HR.aff
index 18b0d84..d4a00ec 100644
--- a/hr_HR/hr_HR.aff
+++ b/hr_HR/hr_HR.aff
@@ -1,21 +1,150 @@
 SET UTF-8
 
-TRY ABCDEFGHIJKLMNOPQRSTUVWXYćĆčČđĐžŽabcdefghijklmnopqrstuvwxy
+TRY abcčćdđefghijklmnoprsštuvzžqwxyABCČĆDĐEFGHIJKLMNOPRSŠTUVQWXY-
 
-NEEDAFFIX Z
+# budući da su riječi u rječnik upisivane bez naglasaka, ovo slova s 
naglaskom tretira kao slova bez naglasaka pa onda provjerava pravopis i u 
naglašenih riječi (ali ne može provjeravati naglasak jer bi to tražilo da 
se rječni u rječnik upisuju naglašene, ova tablica kaže: [ȁ, â, à, á, 
ā] = a; odnosno bȁr = bâr = bar. Namjera i nije ispravljati naglaske nego 
_ne podcrtavati_ naglašene riječi ako je naglašena riječ točno napisana 
[zanemarujući točnost naglaska, to je na onome tko naglaske piše])
+ICONV 28
+ICONV ȁ a
+ICONV â a
+ICONV à a
+ICONV á a
+ICONV ā a
+ICONV ȅ e
+ICONV ȇ e
+ICONV è e
+ICONV é e
+ICONV ē e
+ICONV ȉ i
+ICONV î i
+ICONV ì i
+ICONV í i
+ICONV Ä« i
+ICONV ȍ o
+ICONV ô o
+ICONV ò o
+ICONV ó o
+ICONV ō o
+ICONV ȕ u
+ICONV û u
+ICONV ù u
+ICONV ú u
+ICONV Å« u
+ICONV ȑ r
+ICONV ȓ r
+ICONV ŕ r
 
-REP 33
+FLAG long
+
+NEEDAFFIX ZZ   #1
+CIRCUMFIX ZY   #2
+KEEPCASE ZX#3
+ONLYINCOMPOUND ZW  #4
+COMPOUNDFLAG ZV#5
+COMPOUNDBEGIN ZU   #6
+COMPOUNDMIDDLE ZT  #7
+COMPOUNDEND ZS #8
+COMPOUNDPERMITFLAG ZR  #9
+COMPOUNDFORBIDFLAG ZQ  #10
+
+NOSUGGEST ZP   #11
+SUBSTANDARD ZO #12
+
+FORBIDDENWORD ZN   #13
+WARN ZM#14
+#FORBIDWARN
+
+BREAK 2
+BREAK ^-
+BREAK -$
+
+WORDCHARS -0123456789
+
+COMPOUNDMIN 1
+COMPOUNDRULE 7
+COMPOUNDRULE (YB)(YE)  # jednoznamenkasti brojevi: 4-ih, 9-oga
+COMPOUNDRULE (YD)(YF)  # broje tri: 3-ih, 3-ega
+COMPOUNDRULE (YA)*(YC)(YD)(YE) # bilo koji broj koji završava na 13: 13-ih, 
13-oga
+COMPOUNDRULE (YA)*(YG)(YD)(YF) # bilo koji broj koji završava na tri, ali da 
to ipak nije trinaest: 123-ih, 123-ega
+COMPOUNDRULE (YA)*(YB)(YE) # bilo koji broj koji ne završava na tri: 
221-ih, 221-oga
+COMPOUNDRULE (YH)(YJ)(YK)  # a-mol i drugi molovi
+COMPOUNDRULE (YI)(YJ)(YL)  # G-dur i drugi durovi
+# tu će trebati dodavati i druge riječi koje se mogu tvoriti s brojevima - 
recimo 'postotni' > 20-postotni i sl.
+
+REP 99
 REP x ks
 REP xy ksi
+REP dk tk
+REP tc dc
+REP c k
 REP c ds
 REP c ts
+REP č ć
+REP ć č
 REP đ dž
 REP dž đ
+REP dž č
 REP e ije
-REP iš$ išta
-REP eš$ ešto
-REP aš$ ašto
+REP je ije
+REP ije je
+REP iju i
+REP i je
+REP ia ija
+REP is ijs
+REP zš š
+REP zč šč
+REP zc sc
+REP zk sk
+REP zi$ gi
+REP ci$ ki
+REP ki$ ci
+REP bč pč
+REP gi zi
+REP bs ps
+REP dk tk
+REP pt bd
+REP sd zd
+REP tš dš
+REP st tst
+REP ts ds
+REP ^čiž čiz
+REP žc šc
+REP Å¡t Å¡
+REP st s
+REP sč šč
+REP sk stk
+REP vn mn
+REP nc ns
+REP ml

[Libreoffice-commits] core.git: dictionaries

2016-04-07 Thread Krunoslav Šebetić
 dictionaries |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit a3eadcd418b3768b3438c31cf47015270ec3a1f5
Author: Krunoslav Šebetić 
Date:   Sun Apr 3 22:56:44 2016 +0200

Updated core
Project: dictionaries  de93f4fc07eba5fac0ae40bb45cc8e6acb331743

Update Croatian dictionary

- Corrected few words, added part of the speech, replaced some incomplete 
classes.
- Added new author
- Large update of AFF-file
  It was necessary to restructure the file to be able to do regular and 
systematic
  updates. Added new sections like ICONV, updated REP section, added quite 
a few
  sfx classes and more.
- Changed 'Version value' field to 2016.04.03.

Change-Id: I6d17729f52f4204e93342a35bfbcb60cdf8ce414
Reviewed-on: https://gerrit.libreoffice.org/23845
Reviewed-by: Kruno 
Reviewed-by: David Tardon 
Tested-by: David Tardon 

diff --git a/dictionaries b/dictionaries
index 8b0fc35..de93f4f 16
--- a/dictionaries
+++ b/dictionaries
@@ -1 +1 @@
-Subproject commit 8b0fc351153d8a56d0cb4f424c501ad1695e1cd2
+Subproject commit de93f4fc07eba5fac0ae40bb45cc8e6acb331743
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Douglas Mencken
 sw/source/filter/ww8/wrtww8.cxx |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 06a0f80114c92de9d113fd75c3250fbd44752a39
Author: Douglas Mencken 
Date:   Wed Apr 6 10:04:04 2016 -0400

drop double check of the same

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

diff --git a/sw/source/filter/ww8/wrtww8.cxx b/sw/source/filter/ww8/wrtww8.cxx
index 81a9f2d..a872f68 100644
--- a/sw/source/filter/ww8/wrtww8.cxx
+++ b/sw/source/filter/ww8/wrtww8.cxx
@@ -3735,13 +3735,13 @@ void WW8Export::WriteFormData( const 
::sw::mark::IFieldmark& rFieldmark )
 const ::sw::mark::IFieldmark* pFieldmark = &rFieldmark;
 const ::sw::mark::ICheckboxFieldmark* pAsCheckbox = dynamic_cast< const 
::sw::mark::ICheckboxFieldmark* >( pFieldmark );
 
-OSL_ENSURE(rFieldmark.GetFieldname() == ODF_FORMTEXT ||
-rFieldmark.GetFieldname() == ODF_FORMDROPDOWN ||
-rFieldmark.GetFieldname() == ODF_FORMCHECKBOX, "Unknown field 
type!!!");
 if ( ! ( rFieldmark.GetFieldname() == ODF_FORMTEXT ||
 rFieldmark.GetFieldname() == ODF_FORMDROPDOWN ||
 rFieldmark.GetFieldname() == ODF_FORMCHECKBOX ) )
+{
+SAL_WARN( "sw.ww8", "unknown field type" );
 return;
+}
 
 int type = 0; // TextFieldmark
 if ( pAsCheckbox )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2016-04-07 Thread Jochen Nitschke
 canvas/source/cairo/cairo_canvasfont.hxx |7 ---
 canvas/source/cairo/cairo_canvashelper.hxx   |7 +--
 canvas/source/cairo/cairo_devicehelper.hxx   |8 +---
 canvas/source/cairo/cairo_spritedevicehelper.hxx |2 --
 canvas/source/cairo/cairo_textlayout.hxx |9 +
 canvas/source/directx/dx_9rm.cxx |8 +---
 canvas/source/directx/dx_bitmapcanvashelper.hxx  |2 --
 canvas/source/directx/dx_canvasfont.hxx  |7 ---
 canvas/source/directx/dx_canvashelper.hxx|8 +---
 canvas/source/directx/dx_devicehelper.hxx|7 +--
 canvas/source/directx/dx_graphicsprovider.hxx|7 +--
 canvas/source/directx/dx_spritedevicehelper.hxx  |2 --
 canvas/source/directx/dx_textlayout.hxx  |8 
 canvas/source/opengl/ogl_canvasfont.hxx  |9 +
 canvas/source/opengl/ogl_spritedevicehelper.hxx  |7 +--
 canvas/source/opengl/ogl_textlayout.hxx  |9 +
 canvas/source/vcl/canvas.cxx |7 ---
 canvas/source/vcl/canvasfont.hxx |9 +
 canvas/source/vcl/canvashelper.hxx   |8 +---
 canvas/source/vcl/devicehelper.hxx   |8 +---
 canvas/source/vcl/spritedevicehelper.hxx |2 --
 canvas/source/vcl/textlayout.hxx |9 +
 canvas/source/vcl/windowoutdevholder.hxx |8 
 23 files changed, 90 insertions(+), 68 deletions(-)

New commits:
commit f9b200ce54cd67ddc04747f9676568a86e14d864
Author: Jochen Nitschke 
Date:   Wed Apr 6 18:32:13 2016 +0200

tdf#94306 replace boost::noncopyable in canvas

Replace with C++11 delete copy-constructur
and copy-assignment.
Some helper classes had boost/noncopyable.hpp
included but didn't use it.

Change-Id: I339f2c413a944649d9d63c046e8b7f7ee6e46791
Reviewed-on: https://gerrit.libreoffice.org/23866
Reviewed-by: Jochen Nitschke 
Reviewed-by: Noel Grandin 
Tested-by: Noel Grandin 

diff --git a/canvas/source/cairo/cairo_canvasfont.hxx 
b/canvas/source/cairo/cairo_canvasfont.hxx
index 276277e..80604b5 100644
--- a/canvas/source/cairo/cairo_canvasfont.hxx
+++ b/canvas/source/cairo/cairo_canvasfont.hxx
@@ -34,7 +34,6 @@
 
 #include "cairo_spritecanvas.hxx"
 
-#include 
 
 
 /* Definition of CanvasFont class */
@@ -45,11 +44,13 @@ namespace cairocanvas
  css::lang::XServiceInfo > 
CanvasFont_Base;
 
 class CanvasFont : public ::comphelper::OBaseMutex,
-   public CanvasFont_Base,
-   private ::boost::noncopyable
+   public CanvasFont_Base
 {
 public:
 typedef rtl::Reference Reference;
+/// make noncopyable
+CanvasFont(const CanvasFont&) = delete;
+const CanvasFont& operator=(const CanvasFont&) = delete;
 
 CanvasFont( const css::rendering::FontRequest& 
 fontRequest,
 const css::uno::Sequence< css::beans::PropertyValue >& 
extraFontProperties,
diff --git a/canvas/source/cairo/cairo_canvashelper.hxx 
b/canvas/source/cairo/cairo_canvashelper.hxx
index f03f9d3..f86a27d 100644
--- a/canvas/source/cairo/cairo_canvashelper.hxx
+++ b/canvas/source/cairo/cairo_canvashelper.hxx
@@ -30,7 +30,6 @@
 
 #include 
 #include 
-#include 
 
 #include 
 #include "cairo_surfaceprovider.hxx"
@@ -51,9 +50,13 @@ namespace cairocanvas
 Clip
 };
 
-class CanvasHelper : private ::boost::noncopyable
+class CanvasHelper
 {
 public:
+/// make noncopyable
+CanvasHelper(const CanvasHelper&) = delete;
+const CanvasHelper& operator=(const CanvasHelper&) = delete;
+
 CanvasHelper();
 
 /// Release all references
diff --git a/canvas/source/cairo/cairo_devicehelper.hxx 
b/canvas/source/cairo/cairo_devicehelper.hxx
index f6264fd..6e6e46f 100644
--- a/canvas/source/cairo/cairo_devicehelper.hxx
+++ b/canvas/source/cairo/cairo_devicehelper.hxx
@@ -24,8 +24,6 @@
 #include 
 #include 
 
-#include 
-
 #include 
 #include 
 
@@ -35,9 +33,13 @@
 
 namespace cairocanvas
 {
-class DeviceHelper : private ::boost::noncopyable
+class DeviceHelper
 {
 public:
+/// make noncopyable
+DeviceHelper(const DeviceHelper&) = delete;
+const DeviceHelper& operator=(const DeviceHelper&) = delete;
+
 DeviceHelper();
 
 /** init helper
diff --git a/canvas/source/cairo/cairo_spritedevicehelper.hxx 
b/canvas/source/cairo/cairo_spritedevicehelper.hxx
index dcd2b8e..d0f1648 100644
--- a/canvas/source/cairo/cairo_spritedevicehelper.hxx
+++ b/canvas/source/cairo/cairo_spritedevicehelper.hxx
@@ -24,8 +24,6 @@
 #include 
 #include 
 
-#include 
-
 #include 
 #include 
 #include 
diff --git a/canvas/source/cairo/cairo_textlayout.hxx 
b/canvas/source/cairo/cairo_textlayout.hxx
index 5

Re: Broken master and newcomers.

2016-04-07 Thread Wols Lists
On 07/04/16 00:17, Norbert Thiebaud wrote:
> On Wed, Apr 6, 2016 at 6:14 PM, Anthonys Lists  
> wrote:
>> On 07/04/2016 00:08, Norbert Thiebaud wrote:

 Imho, IF we do something like this, we should use the git facilities to
> create a shallow clone backup, that people can then use ftp or rsync or
> some
> other interruptible protocol to download.
>>>
>>> We have been doing that for years:
>>>
>>> http://dev-www.libreoffice.org/bundles/
>>>
>> That should then make this whole discussion moot then? Just modify the
>> instructtions to warn newcomers that master *can* be broken, and if they
>> want a known-good build to start with, go and get a bundle rather than using
>> clone. Once thye've got a good build they can "git pull" and go from there.
> 
> the bundle is not guarantee to build anymore than a random master...
> 
> It is just that we regularly (in fact is a cron iirc) tar-gz core.git
> and other repo, precisely for people that have trouble doing a git
> clone on a big repo
> 
In that case, rather than firing it on a cron job, is there any chance
that we could adjust the build job so that - if the most recent bundle
is more than say one day out (dunno what time limit you have on your
cron job) - it fires off the tar job after a clean build.

And you make it sound like it's just a tar. If it's for people who have
problems with git clone, shouldn't we make it a shallow clone?

Minimal change (famous last words) for maximal impact, hopefully :-)

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