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

2017-11-03 Thread Stephan Bergmann
 include/comphelper/windowserrorstring.hxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 3d02f5199ea239a4376dab52cb772d306c86c3a4
Author: Stephan Bergmann 
Date:   Thu Nov 2 18:39:47 2017 +0100

-Werror,-Wsign-compare (clang-cl)

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

diff --git a/include/comphelper/windowserrorstring.hxx 
b/include/comphelper/windowserrorstring.hxx
index 4e401571a2fb..bb4b16241ca5 100644
--- a/include/comphelper/windowserrorstring.hxx
+++ b/include/comphelper/windowserrorstring.hxx
@@ -47,7 +47,7 @@ inline OUString WindowsErrorStringFromHRESULT(HRESULT hr)
 // we might actually have a Win32 error code converted using 
HRESULT_FROM_WIN32 macro
 
 DWORD nErrorCode = DWORD(hr);
-if ((hr & 0x) == MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, 0) 
|| hr == S_OK)
+if (HRESULT(hr & 0x) == MAKE_HRESULT(SEVERITY_ERROR, 
FACILITY_WIN32, 0) || hr == S_OK)
 {
 nErrorCode = HRESULT_CODE(hr);
 // https://msdn.microsoft.com/en-us/library/ms679360 mentions that the 
codes might have
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-11-03 Thread Noel Grandin
 cppcanvas/source/inc/implrenderer.hxx  |6 +--
 cppcanvas/source/mtfrenderer/emfplus.cxx   |6 +--
 drawinglayer/source/processor2d/hittestprocessor2d.cxx |4 +-
 drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx |2 -
 drawinglayer/source/processor2d/vclmetafileprocessor2d.hxx |2 -
 drawinglayer/source/processor3d/defaultprocessor3d.cxx |4 +-
 drawinglayer/source/processor3d/zbufferprocessor3d.cxx |2 -
 drawinglayer/source/tools/emfpfont.hxx |8 ++---
 drawinglayer/source/tools/emfphelperdata.cxx   |6 +--
 drawinglayer/source/tools/emfphelperdata.hxx   |6 +--
 drawinglayer/source/tools/emfpstringformat.hxx |   20 ++---
 include/drawinglayer/processor2d/hittestprocessor2d.hxx|4 +-
 include/drawinglayer/processor3d/defaultprocessor3d.hxx|4 +-
 13 files changed, 37 insertions(+), 37 deletions(-)

New commits:
commit 7795907fa9434441a86e878799b04149700fe622
Author: Noel Grandin 
Date:   Thu Nov 2 15:17:06 2017 +0200

loplugin:constmethod in drawinglayer

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

diff --git a/cppcanvas/source/inc/implrenderer.hxx 
b/cppcanvas/source/inc/implrenderer.hxx
index e61f3407169a..295da4ee73d7 100644
--- a/cppcanvas/source/inc/implrenderer.hxx
+++ b/cppcanvas/source/inc/implrenderer.hxx
@@ -195,9 +195,9 @@ namespace cppcanvas
 /* EMF+ */
 static void ReadRectangle (SvStream& s, float& x, float& y, float 
, float& height, bool bCompressed = false);
 static void ReadPoint (SvStream& s, float& x, float& y, sal_uInt32 
flags);
-void MapToDevice (double , double );
-::basegfx::B2DPoint Map (double ix, double iy);
-::basegfx::B2DSize MapSize (double iwidth, double iheight);
+void MapToDevice (double , double ) const;
+::basegfx::B2DPoint Map (double ix, double iy) const;
+::basegfx::B2DSize MapSize (double iwidth, double iheight) const;
 void GraphicStatePush (GraphicStateMap& map, sal_Int32 index, 
OutDevState const & rState);
 void GraphicStatePop (GraphicStateMap& map, sal_Int32 index, 
OutDevState& rState);
 
diff --git a/cppcanvas/source/mtfrenderer/emfplus.cxx 
b/cppcanvas/source/mtfrenderer/emfplus.cxx
index 60f9f51b3e15..369ac9ccb3b9 100644
--- a/cppcanvas/source/mtfrenderer/emfplus.cxx
+++ b/cppcanvas/source/mtfrenderer/emfplus.cxx
@@ -251,14 +251,14 @@ namespace cppcanvas
 s.ReadFloat( x ).ReadFloat( y );
 }
 
-void ImplRenderer::MapToDevice (double& x, double& y)
+void ImplRenderer::MapToDevice (double& x, double& y) const
 {
 // TODO: other units
 x = 100*nMmX*x/nPixX;
 y = 100*nMmY*y/nPixY;
 }
 
-::basegfx::B2DPoint ImplRenderer::Map (double ix, double iy)
+::basegfx::B2DPoint ImplRenderer::Map (double ix, double iy) const
 {
 double x, y;
 
@@ -276,7 +276,7 @@ namespace cppcanvas
 return ::basegfx::B2DPoint (x, y);
 }
 
-::basegfx::B2DSize ImplRenderer::MapSize (double iwidth, double 
iheight)
+::basegfx::B2DSize ImplRenderer::MapSize (double iwidth, double 
iheight) const
 {
 double w, h;
 
diff --git a/drawinglayer/source/processor2d/hittestprocessor2d.cxx 
b/drawinglayer/source/processor2d/hittestprocessor2d.cxx
index ef512060cf06..d0d428370d41 100644
--- a/drawinglayer/source/processor2d/hittestprocessor2d.cxx
+++ b/drawinglayer/source/processor2d/hittestprocessor2d.cxx
@@ -75,7 +75,7 @@ namespace drawinglayer
 
 bool HitTestProcessor2D::checkHairlineHitWithTolerance(
 const basegfx::B2DPolygon& rPolygon,
-double fDiscreteHitTolerance)
+double fDiscreteHitTolerance) const
 {
 basegfx::B2DPolygon aLocalPolygon(rPolygon);
 
aLocalPolygon.transform(getViewInformation2D().getObjectToViewTransformation());
@@ -103,7 +103,7 @@ namespace drawinglayer
 
 bool HitTestProcessor2D::checkFillHitWithTolerance(
 const basegfx::B2DPolyPolygon& rPolyPolygon,
-double fDiscreteHitTolerance)
+double fDiscreteHitTolerance) const
 {
 bool bRetval(false);
 basegfx::B2DPolyPolygon aLocalPolyPolygon(rPolyPolygon);
diff --git a/drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx 
b/drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx
index e9473c3e4d23..eb984b5d9c65 100644
--- a/drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx
+++ b/drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx
@@ -282,7 +282,7 @@ namespace drawinglayer
  

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

2017-11-03 Thread Noel Grandin
 include/vcl/errcode.hxx   |7 ---
 vcl/Library_vcl.mk|1 
 vcl/source/helper/errcode.cxx |   85 ++
 3 files changed, 88 insertions(+), 5 deletions(-)

New commits:
commit 0d4891b6d1346191b56f0f8f4991cb6372e10c1d
Author: Noel Grandin 
Date:   Thu Nov 2 12:07:48 2017 +0200

improve debug printing of ErrCode

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

diff --git a/include/vcl/errcode.hxx b/include/vcl/errcode.hxx
index 9db4587baae0..31582a79d962 100644
--- a/include/vcl/errcode.hxx
+++ b/include/vcl/errcode.hxx
@@ -22,7 +22,7 @@
 
 #include 
 #include 
-#include 
+#include 
 #include 
 
 /*
@@ -144,10 +144,7 @@ private:
 sal_uInt32 m_value;
 };
 
-inline std::ostream& operator<<(std::ostream& os, const ErrCode& err)
-{
-os << sal_uInt32(err); return os;
-}
+VCL_DLLPUBLIC std::ostream& operator<<(std::ostream& os, const ErrCode& err);
 
 enum class ErrCodeArea {
 Io  = 0 ,
diff --git a/vcl/Library_vcl.mk b/vcl/Library_vcl.mk
index eb6fe73f81f4..cbe6de3afce7 100644
--- a/vcl/Library_vcl.mk
+++ b/vcl/Library_vcl.mk
@@ -311,6 +311,7 @@ $(eval $(call gb_Library_add_exception_objects,vcl,\
 vcl/source/helper/canvastools \
 vcl/source/helper/commandinfoprovider \
 vcl/source/helper/displayconnectiondispatch \
+vcl/source/helper/errcode \
 vcl/source/helper/evntpost \
 vcl/source/helper/lazydelete \
 vcl/source/helper/strhelper \
diff --git a/vcl/source/helper/errcode.cxx b/vcl/source/helper/errcode.cxx
new file mode 100644
index ..e1554020fced
--- /dev/null
+++ b/vcl/source/helper/errcode.cxx
@@ -0,0 +1,85 @@
+/* -*- 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 
+
+VCL_DLLPUBLIC std::ostream& operator<<(std::ostream& os, const ErrCode& err)
+{
+os << err.toHexString()
+   << "("
+   << (err.IsWarning() ? "Warning" : "Error");
+if (err.IsDynamic())
+os << " Dynamic";
+else
+{
+os << " Area:";
+switch (err.GetArea())
+{
+case ErrCodeArea::Io:os << "Io"; break;
+case ErrCodeArea::Sv:os << "Sv"; break;
+case ErrCodeArea::Sfx:   os << "Sfx"; break;
+case ErrCodeArea::Inet:  os << "Inet"; break;
+case ErrCodeArea::Vcl:   os << "Vcl"; break;
+case ErrCodeArea::Svx:   os << "Svx"; break;
+case ErrCodeArea::So:os << "So"; break;
+case ErrCodeArea::Sbx:   os << "Sbx"; break;
+case ErrCodeArea::Db:os << "Db"; break;
+case ErrCodeArea::Java:  os << "Java"; break;
+case ErrCodeArea::Uui:   os << "Uui"; break;
+case ErrCodeArea::Lib2:  os << "Lib2"; break;
+case ErrCodeArea::Chaos: os << "Chaos"; break;
+case ErrCodeArea::Sc:os << "Sc"; break;
+case ErrCodeArea::Sd:os << "Sd"; break;
+case ErrCodeArea::Sw:os << "Sw"; break;
+default: os << "Unknown";
+}
+os << " Class:";
+switch (err.GetClass())
+{
+case ErrCodeClass::NONE:  os << "NONE"; break;
+case ErrCodeClass::Abort: os << "Abort"; break;
+case ErrCodeClass::General:   os << "General"; break;
+case ErrCodeClass::NotExists: os << "NotExists"; break;
+case ErrCodeClass::AlreadyExists: os << "AlreadyExists"; break;
+case ErrCodeClass::Access:os << "Access"; break;
+case ErrCodeClass::Path:  os << "Path"; break;
+case ErrCodeClass::Locking:   os << "Locking"; break;
+case ErrCodeClass::Parameter: os << "Parameter"; break;
+case ErrCodeClass::Space: os << "Space"; break;
+case ErrCodeClass::NotSupported:  os << "NotSupported"; break;
+case ErrCodeClass::Read:  os << "Read"; break;
+case ErrCodeClass::Write: os << "Write"; break;
+case 

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

2017-11-03 Thread jan Iversen
 bridges/source/cpp_uno/gcc3_ios/call.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 78f6fadca5e91dc2abe4b7b9451ebefe2b29dcb0
Author: jan Iversen 
Date:   Thu Nov 2 18:57:17 2017 +0100

iOS include error in bridges

Need to use "" for call.hxx include

Change-Id: I9a30f3d3cfab83076f9ad22a5b637f8f4fc7c432

diff --git a/bridges/source/cpp_uno/gcc3_ios/call.cxx 
b/bridges/source/cpp_uno/gcc3_ios/call.cxx
index 7b50e37e510d..405ff2f953e8 100644
--- a/bridges/source/cpp_uno/gcc3_ios/call.cxx
+++ b/bridges/source/cpp_uno/gcc3_ios/call.cxx
@@ -21,7 +21,7 @@
 
 #include 
 
-#include 
+#include "call.hxx"
 
 void privateSnippetExecutor()
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-bugs] [Bug 113606] Formating symbol in Table symbol bar inoperative

2017-11-03 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=113606

Dieter Praas  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 CC||dgp-m...@gmx.de
 Resolution|--- |WORKSFORME

--- Comment #1 from Dieter Praas  ---
I don't know what symbol you think of. To eleminate the black line between the
two sells choose "Borders (Shift to overwrtite)". Press Shift and the specific
icon to remove the black line.

Set to WORKSFORME. Please change it back to UNCONFIRMED if the description
doesn't solve your problem.

-- 
You are receiving this mail because:
You are the assignee for the bug.___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


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

2017-11-03 Thread Julien Nabet
 sfx2/source/dialog/filtergrouping.cxx |   41 --
 1 file changed, 20 insertions(+), 21 deletions(-)

New commits:
commit 62896fb7a5983eb13ee87b94ae803e6552626d8d
Author: Julien Nabet 
Date:   Fri Oct 13 22:12:48 2017 +0200

Replace list by vector in filtergrouping (sfx2)

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

diff --git a/sfx2/source/dialog/filtergrouping.cxx 
b/sfx2/source/dialog/filtergrouping.cxx
index 04e09f66807b..47c10dd13eca 100644
--- a/sfx2/source/dialog/filtergrouping.cxx
+++ b/sfx2/source/dialog/filtergrouping.cxx
@@ -35,7 +35,6 @@
 #include 
 #include 
 
-#include 
 #include 
 #include 
 #include 
@@ -120,8 +119,8 @@ namespace sfx2
 
 
 typedef StringPair  FilterDescriptor;   // a 
single filter or a filter class (display name and filter mask)
-typedef ::std::list< FilterDescriptor > FilterGroup;// a list 
of single filter entries
-typedef ::std::list< FilterGroup >  GroupedFilterList;  // a list 
of all filters, already grouped
+typedef ::std::vector< FilterDescriptor >   FilterGroup;// a 
vector of single filter entries
+typedef ::std::vector< FilterGroup >GroupedFilterList;  // a 
vector of all filters, already grouped
 
 /// the logical name of a filter
 typedef OUString FilterName;
@@ -138,8 +137,8 @@ namespace sfx2
 Sequence< FilterName >  aSubFilters;// the (logical) names 
of the filter which belong to the class
 } FilterClass;
 
-typedef ::std::list< FilterClass >  
FilterClassList;
-typedef ::std::map< OUString, FilterClassList::iterator >
FilterClassReferrer;
+typedef ::std::vector< FilterClass >   
FilterClassVector;
+typedef ::std::map< OUString, FilterClassVector::iterator >
FilterClassReferrer;
 
 typedef ::std::vector< OUString >StringArray;
 
@@ -162,12 +161,12 @@ namespace sfx2
 struct CreateEmptyClassRememberPos
 {
 protected:
-FilterClassList&m_rClassList;
+FilterClassVector&  m_rClassVector;
 FilterClassReferrer&m_rClassesReferrer;
 
 public:
-CreateEmptyClassRememberPos( FilterClassList& _rClassList, 
FilterClassReferrer& _rClassesReferrer )
-:m_rClassList   ( _rClassList )
+CreateEmptyClassRememberPos( FilterClassVector& _rClassVector, 
FilterClassReferrer& _rClassesReferrer )
+:m_rClassVector   ( _rClassVector )
 ,m_rClassesReferrer ( _rClassesReferrer )
 {
 }
@@ -176,9 +175,9 @@ namespace sfx2
 void operator() ( const FilterName& _rLogicalFilterName )
 {
 // insert a new (empty) class
-m_rClassList.emplace_back( );
+m_rClassVector.emplace_back( );
 // get the position of this new entry
-FilterClassList::iterator aInsertPos = m_rClassList.end();
+FilterClassVector::iterator aInsertPos = m_rClassVector.end();
 --aInsertPos;
 // remember this position
 m_rClassesReferrer.emplace( _rLogicalFilterName, aInsertPos );
@@ -219,7 +218,7 @@ namespace sfx2
 };
 
 
-void lcl_ReadGlobalFilters( const OConfigurationNode& 
_rFilterClassification, FilterClassList& _rGlobalClasses, StringArray& 
_rGlobalClassNames )
+void lcl_ReadGlobalFilters( const OConfigurationNode& 
_rFilterClassification, FilterClassVector& _rGlobalClasses, StringArray& 
_rGlobalClassNames )
 {
 _rGlobalClasses.clear();
 _rGlobalClassNames.clear();
@@ -267,10 +266,10 @@ namespace sfx2
 {
 protected:
 OConfigurationNode  m_aClassesNode;
-FilterClassList&m_rClasses;
+FilterClassVector&m_rClasses;
 
 public:
-ReadLocalFilter( const OConfigurationNode& _rClassesNode, 
FilterClassList& _rClasses )
+ReadLocalFilter( const OConfigurationNode& _rClassesNode, 
FilterClassVector& _rClasses )
 :m_aClassesNode ( _rClassesNode )
 ,m_rClasses ( _rClasses )
 {
@@ -289,7 +288,7 @@ namespace sfx2
 };
 
 
-void lcl_ReadLocalFilters( const OConfigurationNode& 
_rFilterClassification, FilterClassList& _rLocalClasses )
+void lcl_ReadLocalFilters( const OConfigurationNode& 
_rFilterClassification, FilterClassVector& _rLocalClasses )
 {
 _rLocalClasses.clear();
 
@@ -306,7 +305,7 @@ namespace sfx2
 }
 
 
-void lcl_ReadClassification( FilterClassList& _rGlobalClasses, 
StringArray& _rGlobalClassNames, FilterClassList& _rLocalClasses )
+void lcl_ReadClassification( FilterClassVector& _rGlobalClasses, 
StringArray& _rGlobalClassNames, 

[Libreoffice-bugs] [Bug 113597] Inserting table in header and saving crashes

2017-11-03 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=113597

Julien Nabet  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #5 from Julien Nabet  ---
Don't hesitate to reopen this tracker if you still reproduce the crash.

-- 
You are receiving this mail because:
You are the assignee for the bug.___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


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

2017-11-03 Thread Julien Nabet
 sd/source/core/drawdoc.cxx |5 +
 sd/source/core/sdpage.cxx  |9 +++--
 sd/source/ui/view/drviews1.cxx |9 +++--
 3 files changed, 7 insertions(+), 16 deletions(-)

New commits:
commit c5857a0371dcc7977e68d48f08f2a3ecefb67b89
Author: Julien Nabet 
Date:   Wed Nov 1 10:31:04 2017 +0100

A first step to refactor ShapeList (sd)

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

diff --git a/sd/source/core/drawdoc.cxx b/sd/source/core/drawdoc.cxx
index 948bba6dc85d..393bc68c2e3e 100644
--- a/sd/source/core/drawdoc.cxx
+++ b/sd/source/core/drawdoc.cxx
@@ -732,12 +732,9 @@ void SdDrawDocument::NewOrLoadCompleted( SdPage* pPage, 
SdStyleSheetPool* pSPool
 
 SfxStyleSheet* pTitleSheet = 
static_cast(pSPool->GetTitleSheet(aName));
 
-SdrObject* pObj = nullptr;
-rPresentationShapes.seekShape(0);
-
 // Now look for title and outline text objects, then make those objects
 // listeners.
-while( (pObj = rPresentationShapes.getNextShape()) )
+for (auto const& pObj : rPresentationShapes.getList())
 {
 if (pObj->GetObjInventor() == SdrInventor::Default)
 {
diff --git a/sd/source/core/sdpage.cxx b/sd/source/core/sdpage.cxx
index 6d7358947ca6..3ac3b29568de 100644
--- a/sd/source/core/sdpage.cxx
+++ b/sd/source/core/sdpage.cxx
@@ -199,12 +199,9 @@ SdrObject* SdPage::GetPresObj(PresObjKind eObjKind, int 
nIndex, bool bFuzzySearc
 // first sort all matching shapes with z-order
 std::vector< SdrObject* > aMatches;
 
-SdrObject* pObj = nullptr;
-maPresentationShapeList.seekShape(0);
-
-while( (pObj = maPresentationShapeList.getNextShape()) )
+for (auto const& shape : maPresentationShapeList.getList())
 {
-SdAnimationInfo* pInfo = SdDrawDocument::GetShapeUserData(*pObj);
+SdAnimationInfo* pInfo = SdDrawDocument::GetShapeUserData(*shape);
 if( pInfo )
 {
 bool bFound = false;
@@ -231,7 +228,7 @@ SdrObject* SdPage::GetPresObj(PresObjKind eObjKind, int 
nIndex, bool bFuzzySearc
 }
 if( bFound )
 {
-aMatches.push_back( pObj );
+aMatches.push_back( shape );
 }
 }
 }
diff --git a/sd/source/ui/view/drviews1.cxx b/sd/source/ui/view/drviews1.cxx
index 976d8dd1cb7b..8c322a76ff99 100644
--- a/sd/source/ui/view/drviews1.cxx
+++ b/sd/source/ui/view/drviews1.cxx
@@ -1063,16 +1063,13 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage)
 {
 // set pages for all available handout presentation objects
 sd::ShapeList& rShapeList = 
pMaster->GetPresentationShapeList();
-SdrObject* pObj = nullptr;
-rShapeList.seekShape(0);
-
-while( (pObj = rShapeList.getNextShape()) )
+for (auto const& shape : rShapeList.getList())
 {
-if( pMaster->GetPresObjKind(pObj) == PRESOBJ_HANDOUT )
+if( pMaster->GetPresObjKind(shape) == PRESOBJ_HANDOUT )
 {
 // #i105146# We want no content to be displayed for 
PageKind::Handout,
 // so just never set a page as content
-
static_cast(pObj)->SetReferencedPage(nullptr);
+
static_cast(shape)->SetReferencedPage(nullptr);
 }
 }
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-11-03 Thread Julien Nabet
 sw/source/core/edit/edfcol.cxx |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit aa5f6764bd29939f6543c0afa02b21319f2c7c6e
Author: Julien Nabet 
Date:   Thu Nov 2 23:51:51 2017 +0100

tdf#113597: Inserting table in header and saving crashes

test xTextPortionEnumerationAccess before trying to use it
bt:
0x7fffca9201e6 in SwEditShell::CollectAdvancedClassification 
(this=this@entry=0x5790c710) at 
/home/user/libreoffice/sw/source/core/edit/edfcol.cxx:804
804 uno::Reference xTextPortions = 
xTextPortionEnumerationAccess->createEnumeration();
0  0x7fffca9201e6 in SwEditShell::CollectAdvancedClassification() 
(this=this@entry=0x5790c710) at 
/home/user/libreoffice/sw/source/core/edit/edfcol.cxx:804
1  0x7fffca927e8c in SwEditShell::ClassifyDocPerHighestParagraphClass() 
(this=0x5790c710) at 
/home/user/libreoffice/sw/source/core/edit/edfcol.cxx:1722

Regression from b480d5e4c03438487b645ae10347c5c22f36bb25

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

diff --git a/sw/source/core/edit/edfcol.cxx b/sw/source/core/edit/edfcol.cxx
index 3b9a466e660e..fdc88456f822 100644
--- a/sw/source/core/edit/edfcol.cxx
+++ b/sw/source/core/edit/edfcol.cxx
@@ -801,6 +801,8 @@ std::vector 
SwEditShell::CollectAdvancedClassificatio
 while (xParagraphs->hasMoreElements())
 {
 uno::Reference 
xTextPortionEnumerationAccess(xParagraphs->nextElement(), uno::UNO_QUERY);
+if (!xTextPortionEnumerationAccess.is())
+continue;
 uno::Reference xTextPortions = 
xTextPortionEnumerationAccess->createEnumeration();
 
 // Check font weight
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-bugs] [Bug 113597] Inserting table in header and saving crashes

2017-11-03 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=113597

Commit Notification  changed:

   What|Removed |Added

 Whiteboard||target:6.0.0

-- 
You are receiving this mail because:
You are the assignee for the bug.___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


[Libreoffice-bugs] [Bug 113597] Inserting table in header and saving crashes

2017-11-03 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=113597

--- Comment #4 from Commit Notification 
 ---
Julien Nabet committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=aa5f6764bd29939f6543c0afa02b21319f2c7c6e

tdf#113597: Inserting table in header and saving crashes

It will be available in 6.0.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.

-- 
You are receiving this mail because:
You are the assignee for the bug.___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


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

2017-11-03 Thread Julien Nabet
 vcl/inc/svdata.hxx   |6 +++---
 vcl/source/app/svapp.cxx |4 ++--
 vcl/source/components/dtranscomp.cxx |   11 +--
 vcl/source/helper/lazydelete.cxx |   10 +-
 4 files changed, 15 insertions(+), 16 deletions(-)

New commits:
commit 526c8f7240812f857d54dc23398ee7845b0be36d
Author: Julien Nabet 
Date:   Thu Nov 2 21:50:30 2017 +0100

Replace some lists by vectors (vcl)

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

diff --git a/vcl/inc/svdata.hxx b/vcl/inc/svdata.hxx
index ad09439f60e1..cf5433483c7a 100644
--- a/vcl/inc/svdata.hxx
+++ b/vcl/inc/svdata.hxx
@@ -35,7 +35,7 @@
 #include "salwtype.hxx"
 #include "displayconnectiondispatch.hxx"
 
-#include 
+#include 
 #include 
 #include 
 #include "ControlCacheKey.hxx"
@@ -130,7 +130,7 @@ struct ImplSVAppData
 LocaleConfigurationListener* mpCfgListener = nullptr;
 VclEventListeners*  mpEventListeners = nullptr; // listeners for 
vcl events (eg, extended toolkit)
 SVAppKeyListeners*  mpKeyListeners = nullptr;   // listeners for 
key events only (eg, extended toolkit)
-std::list maPostedEventList;
+std::vector maPostedEventList;
 ImplAccelManager*   mpAccelMgr = nullptr;   // Accelerator 
Manager
 OUString*   mpAppName = nullptr;// Application name
 OUString*   mpAppFileName = nullptr;// Abs. 
Application FileName
@@ -362,7 +362,7 @@ struct ImplSVData
 
 css::uno::Reference< css::lang::XComponent > mxAccessBridge;
 vcl::SettingsConfigItem* mpSettingsConfigItem = nullptr;
-std::list< vcl::DeleteOnDeinitBase* >* mpDeinitDeleteList = nullptr;
+std::vector< vcl::DeleteOnDeinitBase* >* mpDeinitDeleteList = nullptr;
 std::unordered_map< int, OUString >* mpPaperNames = nullptr;
 
 css::uno::Reference m_xCharClass;
diff --git a/vcl/source/app/svapp.cxx b/vcl/source/app/svapp.cxx
index ab5a82dee4dd..ad5beddb1c83 100644
--- a/vcl/source/app/svapp.cxx
+++ b/vcl/source/app/svapp.cxx
@@ -954,7 +954,7 @@ IMPL_STATIC_LINK( Application, PostEventHandler, void*, 
pCallData, void )
 
 // remove this event from list of posted events, watch for destruction of 
internal data
 auto svdata = ImplGetSVData();
-::std::list< ImplPostEventPair >::iterator aIter( 
svdata->maAppData.maPostedEventList.begin() );
+::std::vector< ImplPostEventPair >::iterator aIter( 
svdata->maAppData.maPostedEventList.begin() );
 
 while( aIter != svdata->maAppData.maPostedEventList.end() )
 {
@@ -974,7 +974,7 @@ void Application::RemoveMouseAndKeyEvents( vcl::Window* 
pWin )
 
 // remove all events for specific window, watch for destruction of 
internal data
 auto svdata = ImplGetSVData();
-::std::list< ImplPostEventPair >::iterator aIter( 
svdata->maAppData.maPostedEventList.begin() );
+::std::vector< ImplPostEventPair >::iterator aIter( 
svdata->maAppData.maPostedEventList.begin() );
 
 while( aIter != svdata->maAppData.maPostedEventList.end() )
 {
diff --git a/vcl/source/components/dtranscomp.cxx 
b/vcl/source/components/dtranscomp.cxx
index f0f02a97252b..46ca921d3def 100644
--- a/vcl/source/components/dtranscomp.cxx
+++ b/vcl/source/components/dtranscomp.cxx
@@ -59,7 +59,7 @@ class GenericClipboard :
 osl::Mutex  
m_aMutex;
 Reference< css::datatransfer::XTransferable >   
m_aContents;
 Reference< css::datatransfer::clipboard::XClipboardOwner >  
m_aOwner;
-std::list< Reference< css::datatransfer::clipboard::XClipboardListener > > 
m_aListeners;
+std::vector< Reference< css::datatransfer::clipboard::XClipboardListener > 
> m_aListeners;
 
 public:
 
@@ -143,7 +143,7 @@ void GenericClipboard::setContents(
 m_aContents = xTrans;
 m_aOwner = xClipboardOwner;
 
-std::list< Reference< datatransfer::clipboard::XClipboardListener > > 
aListeners( m_aListeners );
+std::vector< Reference< datatransfer::clipboard::XClipboardListener > > 
aListeners( m_aListeners );
 datatransfer::clipboard::ClipboardEvent aEv;
 aEv.Contents = m_aContents;
 
@@ -151,10 +151,9 @@ void GenericClipboard::setContents(
 
 if( xOldOwner.is() && xOldOwner != xClipboardOwner )
 xOldOwner->lostOwnership( this, xOldContents );
-for( std::list< Reference< datatransfer::clipboard::XClipboardListener > 
>::iterator it =
- aListeners.begin(); it != aListeners.end() ; ++it )
+for (auto const& listener : aListeners)
 {
-(*it)->changedContents( aEv );
+listener->changedContents( aEv );
 }
 }
 
@@ -179,7 +178,7 @@ void GenericClipboard::removeClipboardListener( const 
Reference< datatransfer::c
 {
 osl::ClearableMutexGuard aGuard( m_aMutex 

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

2017-11-03 Thread Julien Nabet
 include/ucbhelper/providerhelper.hxx |4 +--
 ucb/source/core/providermap.hxx  |4 +--
 ucb/source/ucp/cmis/children_provider.hxx|4 +--
 ucb/source/ucp/cmis/cmis_content.cxx |4 +--
 ucb/source/ucp/cmis/cmis_content.hxx |4 +--
 ucb/source/ucp/cmis/cmis_datasupplier.cxx|5 +---
 ucb/source/ucp/cmis/cmis_repo_content.cxx|   19 --
 ucb/source/ucp/cmis/cmis_repo_content.hxx|2 -
 ucb/source/ucp/gio/gio_content.hxx   |4 +--
 ucb/source/ucp/package/pkgcontent.hxx|4 +--
 ucb/source/ucp/tdoc/tdoc_content.hxx |2 -
 ucb/source/ucp/webdav-neon/webdavcontent.hxx |2 -
 ucb/source/ucp/webdav/webdavcontent.hxx  |2 -
 ucbhelper/source/client/proxydecider.cxx |   28 +++
 14 files changed, 37 insertions(+), 51 deletions(-)

New commits:
commit b80403167935550a4dd97f31b79d2bdcb97e4e88
Author: Julien Nabet 
Date:   Thu Nov 2 22:46:22 2017 +0100

Replace lists by vector or deque in ucb/ucbhelper

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

diff --git a/include/ucbhelper/providerhelper.hxx 
b/include/ucbhelper/providerhelper.hxx
index 894d6177b41b..8d3508784d10 100644
--- a/include/ucbhelper/providerhelper.hxx
+++ b/include/ucbhelper/providerhelper.hxx
@@ -20,7 +20,7 @@
 #ifndef INCLUDED_UCBHELPER_PROVIDERHELPER_HXX
 #define INCLUDED_UCBHELPER_PROVIDERHELPER_HXX
 
-#include 
+#include 
 #include 
 #include 
 #include 
@@ -45,7 +45,7 @@ namespace ucbhelper {
 
 class ContentImplHelper;
 typedef rtl::Reference< ContentImplHelper > ContentImplHelperRef;
-typedef std::list< ContentImplHelperRef > ContentRefList;
+typedef std::vector< ContentImplHelperRef > ContentRefList;
 
 /**
   * This is an abstract base class for implementations of the service
diff --git a/ucb/source/core/providermap.hxx b/ucb/source/core/providermap.hxx
index ba793aad9e73..c1b50e058820 100644
--- a/ucb/source/core/providermap.hxx
+++ b/ucb/source/core/providermap.hxx
@@ -20,7 +20,7 @@
 #ifndef INCLUDED_UCB_SOURCE_CORE_PROVIDERMAP_HXX
 #define INCLUDED_UCB_SOURCE_CORE_PROVIDERMAP_HXX
 
-#include 
+#include 
 #include 
 #include 
 
@@ -56,7 +56,7 @@ ProviderListEntry_Impl::getResolvedProvider() const
 }
 
 
-typedef std::list< ProviderListEntry_Impl > ProviderList_Impl;
+typedef std::deque< ProviderListEntry_Impl > ProviderList_Impl;
 
 
 typedef ucb_impl::RegexpMap< ProviderList_Impl > ProviderMap_Impl;
diff --git a/ucb/source/ucp/cmis/children_provider.hxx 
b/ucb/source/ucp/cmis/children_provider.hxx
index 770c29e68d11..210522a5f916 100644
--- a/ucb/source/ucp/cmis/children_provider.hxx
+++ b/ucb/source/ucp/cmis/children_provider.hxx
@@ -9,7 +9,7 @@
 #ifndef INCLUDED_UCB_SOURCE_UCP_CMIS_CHILDREN_PROVIDER_HXX
 #define INCLUDED_UCB_SOURCE_UCP_CMIS_CHILDREN_PROVIDER_HXX
 
-#include 
+#include 
 
 #include 
 
@@ -20,7 +20,7 @@ namespace cmis
 public:
 virtual ~ChildrenProvider( ) { };
 
-virtual std::list< css::uno::Reference< css::ucb::XContent > > 
getChildren( ) = 0;
+virtual std::vector< css::uno::Reference< css::ucb::XContent > > 
getChildren( ) = 0;
 };
 }
 
diff --git a/ucb/source/ucp/cmis/cmis_content.cxx 
b/ucb/source/ucp/cmis/cmis_content.cxx
index da5f779631ec..db55e200b6e5 100644
--- a/ucb/source/ucp/cmis/cmis_content.cxx
+++ b/ucb/source/ucp/cmis/cmis_content.cxx
@@ -2033,9 +2033,9 @@ namespace cmis
 return uno::Sequence< ucb::ContentInfo >();
 }
 
-list< uno::Reference< ucb::XContent > > Content::getChildren( )
+std::vector< uno::Reference< ucb::XContent > > Content::getChildren( )
 {
-list< uno::Reference< ucb::XContent > > results;
+std::vector< uno::Reference< ucb::XContent > > results;
 SAL_INFO( "ucb.ucp.cmis", "Content::getChildren() " << m_sURL );
 
 libcmis::FolderPtr pFolder = boost::dynamic_pointer_cast< 
libcmis::Folder >( getObject( uno::Reference< ucb::XCommandEnvironment >() ) );
diff --git a/ucb/source/ucp/cmis/cmis_content.hxx 
b/ucb/source/ucp/cmis/cmis_content.hxx
index acd45e8d65b6..3a83cde97b06 100644
--- a/ucb/source/ucp/cmis/cmis_content.hxx
+++ b/ucb/source/ucp/cmis/cmis_content.hxx
@@ -98,7 +98,7 @@ private:
 
 private:
 typedef rtl::Reference< Content > ContentRef;
-typedef std::list< ContentRef > ContentRefList;
+typedef std::vector< ContentRef > ContentRefList;
 
 /// @throws css::uno::Exception
 /// @throws libcmis::Exception
@@ -201,7 +201,7 @@ public:
 css::uno::Sequence< css::ucb::ContentInfo >
 queryCreatableContentsInfo( const css::uno::Reference< 
css::ucb::XCommandEnvironment >& xEnv );
 
-virtual std::list< css::uno::Reference< css::ucb::XContent > > 
getChildren( ) override;
+virtual std::vector< 

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

2017-11-03 Thread Julien Nabet
 desktop/source/deployment/registry/component/dp_compbackenddb.hxx |4 -
 desktop/source/deployment/registry/component/dp_component.cxx |   38 
--
 desktop/source/deployment/registry/configuration/dp_configuration.cxx |   13 
+--
 desktop/source/deployment/registry/dp_backenddb.cxx   |   18 
++--
 desktop/source/deployment/registry/inc/dp_backenddb.hxx   |6 -
 5 files changed, 36 insertions(+), 43 deletions(-)

New commits:
commit 42bfbc216474b4f60d5a5e52a88d95baded5191c
Author: Julien Nabet 
Date:   Thu Nov 2 20:32:43 2017 +0100

Replace remaining lists by deques (desktop)

because of addToUnoRc and addToConfigmgrIni which use push_front
(and no easy way to change this), I couldn't use vectors

+ use for range loops

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

diff --git a/desktop/source/deployment/registry/component/dp_compbackenddb.hxx 
b/desktop/source/deployment/registry/component/dp_compbackenddb.hxx
index 02d03e1b206f..56f9579f0003 100644
--- a/desktop/source/deployment/registry/component/dp_compbackenddb.hxx
+++ b/desktop/source/deployment/registry/component/dp_compbackenddb.hxx
@@ -23,7 +23,7 @@
 #include 
 #include 
 #include 
-#include 
+#include 
 #include 
 
 namespace com { namespace sun { namespace star {
@@ -75,7 +75,7 @@ public:
 {
 Data(): javaTypeLibrary(false) {};
 
-std::list< OUString> implementationNames;
+std::deque< OUString> implementationNames;
 std::vector< std::pair< OUString, OUString> >singletons;
 // map from singleton names to implementation names
 bool javaTypeLibrary;
diff --git a/desktop/source/deployment/registry/component/dp_component.cxx 
b/desktop/source/deployment/registry/component/dp_component.cxx
index fca9e143d075..a41c68d1de5e 100644
--- a/desktop/source/deployment/registry/component/dp_component.cxx
+++ b/desktop/source/deployment/registry/component/dp_component.cxx
@@ -47,7 +47,7 @@
 #include 
 #include 
 #include 
-#include 
+#include 
 #include 
 #include 
 #include 
@@ -63,7 +63,7 @@ namespace backend {
 namespace component {
 namespace {
 
-typedef std::list t_stringlist;
+typedef std::deque t_stringlist;
 typedef std::vector< std::pair > t_stringpairvec;
 
 #define IMPLEMENTATION_NAME  
"com.sun.star.comp.deployment.component.PackageRegistryBackend"
@@ -942,15 +942,14 @@ void BackendImpl::unorc_flush( 
Reference const & xCmdEnv )
 xCmdEnv, m_xComponentContext );
 ucb_content.writeStream( xData, true /* replace existing */ );
 }
-for (t_stringlist::iterator i(m_components.begin());
- i != m_components.end(); ++i)
+for (auto const& component : m_components)
 {
 if (space)
 {
 buf.append(' ');
 }
 buf.append('?');
-buf.append(OUStringToOString(*i, RTL_TEXTENCODING_UTF8));
+buf.append(OUStringToOString(component, RTL_TEXTENCODING_UTF8));
 space = true;
 }
 buf.append(LF);
@@ -992,7 +991,8 @@ void BackendImpl::removeFromUnoRc(
 const OUString rcterm( dp_misc::makeRcTerm(url_) );
 const ::osl::MutexGuard guard( getMutex() );
 unorc_verify_init( xCmdEnv );
-getRcItemList(kind).remove( rcterm );
+t_stringlist aRcItemList = getRcItemList(kind);
+aRcItemList.erase(std::remove(aRcItemList.begin(), aRcItemList.end(), 
rcterm), aRcItemList.end());
 // write immediately:
 m_unorc_modified = true;
 unorc_flush( xCmdEnv );
@@ -1192,35 +1192,33 @@ void 
BackendImpl::ComponentPackageImpl::componentLiveInsertion(
 rootContext->getServiceManager(), css::uno::UNO_QUERY_THROW);
 std::vector< css::uno::Reference< css::uno::XInterface > >::const_iterator
 factory(factories.begin());
-for (t_stringlist::const_iterator i(data.implementationNames.begin());
- i != data.implementationNames.end(); ++i)
+for (auto const& implementationName : data.implementationNames)
 {
 try {
 set->insert(css::uno::Any(*factory++));
 } catch (const container::ElementExistException &) {
-SAL_WARN("desktop.deployment", "implementation already registered 
" << *i);
+SAL_WARN("desktop.deployment", "implementation already registered 
" << implementationName);
 }
 }
 if (!data.singletons.empty()) {
 css::uno::Reference< css::container::XNameContainer > cont(
 rootContext, css::uno::UNO_QUERY_THROW);
-for (t_stringpairvec::const_iterator i(data.singletons.begin());
- i != data.singletons.end(); ++i)
+for (auto const& singleton : data.singletons)
 {
-OUString 

<    1   2   3   4   5