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

2021-01-03 Thread Julien Nabet (via logerrit)
 external/nss/ExternalProject_nss.mk |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 61d9a4a24405b151d212fa19e5c1edb09f5f2a42
Author: Julien Nabet 
AuthorDate: Sun Jan 3 14:09:46 2021 +0100
Commit: Julien Nabet 
CommitDate: Sun Jan 3 17:20:27 2021 +0100

Fix nss build on Raspberry pi4

In file included from gcm-arm32-neon.c:16:
/usr/lib/llvm-11/lib/clang/11.0.0/include/arm_neon.h:32:2: error: "NEON 
support not enabled"
error "NEON support not enabled"
 ^

gcm-arm32-neon.c:21:5: warning: implicit declaration of function 'vst1_u8' 
is invalid in C99 [-Wimplicit-function-declaration]
vst1_u8(outbuf, vrev64_u8(vcreate_u8(ghash->x_high)));
^
gcm-arm32-neon.c:21:21: warning: implicit declaration of function 
'vrev64_u8' is invalid in C99 [-Wimplicit-function-declaration]
vst1_u8(outbuf, vrev64_u8(vcreate_u8(ghash->x_high)));
^
gcm-arm32-neon.c:21:31: warning: implicit declaration of function 
'vcreate_u8' is invalid in C99 [-Wimplicit-function-declaration]
vst1_u8(outbuf, vrev64_u8(vcreate_u8(ghash->x_high)));
  ^
gcm-arm32-neon.c:27:15: error: unknown type name 'uint8x16_t'; did you mean 
'uint16_t'?
static inline uint8x16_t
  ^~
  uint16_t
/usr/include/arm-linux-gnueabihf/bits/stdint-uintn.h:25:20: note: 
'uint16_t' declared here
typedef __uint16_t uint16_t;
   ^
gcm-arm32-neon.c:28:13: error: unknown type name 'uint8x8_t'; did you mean 
'uint8_t'?
clmul(const uint8x8_t a, const uint8x8_t b)
^
uint8_t
etc.

Change-Id: I1e241cea5becb159f8b0f898270dc88f93f68670
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108634
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/external/nss/ExternalProject_nss.mk 
b/external/nss/ExternalProject_nss.mk
index 19831b6c3633..c7738ca2d759 100644
--- a/external/nss/ExternalProject_nss.mk
+++ b/external/nss/ExternalProject_nss.mk
@@ -54,6 +54,7 @@ $(call gb_ExternalProject_get_state_target,nss,build): $(call 
gb_ExternalExecuta
NSS_USE_SYSTEM_SQLITE=1) \
$(if $(filter LINUX,$(OS)),$(if 
$(ENABLE_DBGUTIL),,BUILD_OPT=1)) \
$(if $(filter SOLARIS,$(OS)),NS_USE_GCC=1) \
+   $(if $(filter ARM,$(CPUNAME)),NSS_DISABLE_ARM32_NEON=1) \
$(if $(CROSS_COMPILING),\
CROSS_COMPILE=1 \
NSPR_CONFIGURE_OPTS="--build=$(BUILD_PLATFORM) 
--host=$(HOST_PLATFORM)") \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-05 Thread Julien Nabet (via logerrit)
 extras/source/autocorr/lang/fr/DocumentList.xml |   11 +--
 1 file changed, 5 insertions(+), 6 deletions(-)

New commits:
commit 8000c2b4bbba1448d5c438eca4b29160ba650437
Author: Julien Nabet 
AuthorDate: Tue Jan 5 13:12:54 2021 +0100
Commit: Julien Nabet 
CommitDate: Tue Jan 5 19:06:07 2021 +0100

Fix duplicates in French autocorrect

"oeil" was a duplicate for key and value, so one entry has been removed
The other were key dups. For these I checked value appeared to know what 
key to keep
and what key to change so there's no regression.

Change-Id: Ic88d0034718bb21e4cab1cddf6cd07d26aca99e5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108801
Reviewed-by: Sophie Gautier 
Reviewed-by: Julien Nabet 
Tested-by: Jenkins

diff --git a/extras/source/autocorr/lang/fr/DocumentList.xml 
b/extras/source/autocorr/lang/fr/DocumentList.xml
index 4d1e05d1d835..9dec60f62e07 100644
--- a/extras/source/autocorr/lang/fr/DocumentList.xml
+++ b/extras/source/autocorr/lang/fr/DocumentList.xml
@@ -378,7 +378,6 @@
   
   
   
-  
   
   
   
@@ -568,7 +567,7 @@
   
   
   
-  
+  
   
   
   
@@ -599,7 +598,7 @@
   
   
   
-  
+  
   
   
   
@@ -1126,7 +1125,7 @@
   
   
   
-  
+  
   
   
   
@@ -1325,7 +1324,7 @@
   
   
   
-  
+  
   
   
   
@@ -1709,7 +1708,7 @@
   
   
   
-  
+  
   
   
   
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-10 Thread Julien Nabet (via logerrit)
 editeng/source/misc/svxacorr.cxx |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit ae56dc05b27f05ffcee99845d661a237e70a7a51
Author: Julien Nabet 
AuthorDate: Sat Jan 9 20:47:24 2021 +0100
Commit: Julien Nabet 
CommitDate: Sun Jan 10 09:38:23 2021 +0100

tdf#96787: AutoCorrect: after deleting a replacement entry, it's still used

If specific acor.dat exists in "user", don't use the initial one 
in "share"
since the initial one will still contain the deleted entry.

See detailed explanation here:
https://bugs.documentfoundation.org/show_bug.cgi?id=96787#c21
Change-Id: Ic349159c93d9fc327f38a1d4e8187e3bdc16d08a

Change-Id: If6b16641d04721f2945a8e920e2933d1b8baa90f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109039
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx
index ae6dceb33adf..0f048114462b 100644
--- a/editeng/source/misc/svxacorr.cxx
+++ b/editeng/source/misc/svxacorr.cxx
@@ -1941,6 +1941,8 @@ const SvxAutocorrWord* SvxAutoCorrect::SearchWordsInList(
 rLang = aLanguageTag;
 return pRet;
 }
+else
+return nullptr;
 }
 
 // If it still could not be found here, then keep on searching
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - editeng/source

2021-01-10 Thread Julien Nabet (via logerrit)
 editeng/source/misc/svxacorr.cxx |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 6046b52ba01dc7dcde4140973c06bec19dadf2a3
Author: Julien Nabet 
AuthorDate: Sat Jan 9 20:47:24 2021 +0100
Commit: Adolfo Jayme Barrientos 
CommitDate: Sun Jan 10 13:38:03 2021 +0100

tdf#96787: AutoCorrect: after deleting a replacement entry, it's still used

If specific acor.dat exists in "user", don't use the initial one 
in "share"
since the initial one will still contain the deleted entry.

See detailed explanation here:
https://bugs.documentfoundation.org/show_bug.cgi?id=96787#c21
Change-Id: Ic349159c93d9fc327f38a1d4e8187e3bdc16d08a

Change-Id: If6b16641d04721f2945a8e920e2933d1b8baa90f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109039
Tested-by: Jenkins
Reviewed-by: Julien Nabet 
(cherry picked from commit ae56dc05b27f05ffcee99845d661a237e70a7a51)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108999
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx
index df6e8985e11e..57f8611335a9 100644
--- a/editeng/source/misc/svxacorr.cxx
+++ b/editeng/source/misc/svxacorr.cxx
@@ -1943,6 +1943,8 @@ const SvxAutocorrWord* SvxAutoCorrect::SearchWordsInList(
 rLang = aLanguageTag;
 return pRet;
 }
+else
+return nullptr;
 }
 
 // If it still could not be found here, then keep on searching
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - editeng/source

2021-01-10 Thread Julien Nabet (via logerrit)
 editeng/source/misc/svxacorr.cxx |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 8f2f805b07ddb3450b48e32dc7171625d81d8a84
Author: Julien Nabet 
AuthorDate: Sat Jan 9 20:47:24 2021 +0100
Commit: Adolfo Jayme Barrientos 
CommitDate: Sun Jan 10 13:37:43 2021 +0100

tdf#96787: AutoCorrect: after deleting a replacement entry, it's still used

If specific acor.dat exists in "user", don't use the initial one 
in "share"
since the initial one will still contain the deleted entry.

See detailed explanation here:
https://bugs.documentfoundation.org/show_bug.cgi?id=96787#c21
Change-Id: Ic349159c93d9fc327f38a1d4e8187e3bdc16d08a

Change-Id: If6b16641d04721f2945a8e920e2933d1b8baa90f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109039
Tested-by: Jenkins
Reviewed-by: Julien Nabet 
(cherry picked from commit ae56dc05b27f05ffcee99845d661a237e70a7a51)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108998
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx
index feab628d7f04..a888f4474a34 100644
--- a/editeng/source/misc/svxacorr.cxx
+++ b/editeng/source/misc/svxacorr.cxx
@@ -1941,6 +1941,8 @@ const SvxAutocorrWord* SvxAutoCorrect::SearchWordsInList(
 rLang = aLanguageTag;
 return pRet;
 }
+else
+return nullptr;
 }
 
 // If it still could not be found here, then keep on searching
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-10 Thread Julien Nabet (via logerrit)
 filter/source/msfilter/msdffimp.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit dfc4c3ed17bf8e4ad775b9092f235ec35e6c9072
Author: Julien Nabet 
AuthorDate: Sun Jan 10 21:02:44 2021 +0100
Commit: Noel Grandin 
CommitDate: Mon Jan 11 07:42:40 2021 +0100

loplugin:loopvartoosmall msdffimp (filter)

Detected on Raspberry pi 4
/home/pi/lo/libreoffice/filter/source/msfilter/msdffimp.cxx:5947:61: error: 
loop index type 'sal_uLong' (aka 'unsigned long') is narrower than length type 
'sal_uInt64' (aka 'unsigned long long') [loplugin:loopvartoosmall]
while( ( rStCtrl.GetError() == ERRCODE_NONE ) && ( nPos < nMaxStrPos ) 
&& bOk );
   ~^~~~

Change-Id: Ic7649b4428d969d0f8814d2e00aa5af0dd781416
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109064
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/filter/source/msfilter/msdffimp.cxx 
b/filter/source/msfilter/msdffimp.cxx
index a69b7a31b615..404dd3aff6bc 100644
--- a/filter/source/msfilter/msdffimp.cxx
+++ b/filter/source/msfilter/msdffimp.cxx
@@ -5909,7 +5909,7 @@ void SvxMSDffManager::GetCtrlData(sal_uInt32 nOffsDggL)
 sal_uInt32  nLength;
 if( !ReadCommonRecordHeader( rStCtrl, nVer, nInst, nFbt, nLength ) ) 
return;
 
-sal_uLong nPos = nOffsDggL + DFF_COMMON_RECORD_HEADER_SIZE;
+sal_uInt64 nPos = nOffsDggL + DFF_COMMON_RECORD_HEADER_SIZE;
 
 // case A: first Drawing Group Container, then n times Drawing Container
 if( DFF_msofbtDggContainer != nFbt )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-11 Thread Julien Nabet (via logerrit)
 sw/source/core/access/accdoc.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 003b45624788610fba98e3f3334f99140017e472
Author: Julien Nabet 
AuthorDate: Sun Jan 10 15:42:31 2021 +0100
Commit: Michael Stahl 
CommitDate: Mon Jan 11 10:46:28 2021 +0100

Related tdf#123632: fix crash in accdoc (sw)

Make sure to use gtk3 rendering
- Open https://bugs.documentfoundation.org/attachment.cgi?id=149492
- Click F5 to open the navigator
- Go to Images
- Try double click the third and last image at least 15 times
-> crash, here's part of bt:
Thread 1 "soffice.bin" received signal SIGSEGV, Segmentation fault.
SwFrame::IsInTab (this=0x0) at sw/source/core/inc/frame.hxx:938
938 if ( mbInfInvalid )
(gdb) bt
0  SwFrame::IsInTab() const (this=0x0) at sw/source/core/inc/frame.hxx:938
1  0x7fd7e78caf9c in SwAccessibleDocument::getExtendedAttributes() 
(this=0x7e4e090) at sw/source/core/access/accdoc.cxx:596
2  0x7fd7e78cbf9d in non-virtual thunk to 
SwAccessibleDocument::getExtendedAttributes() () at 
sw/source/core/access/accdoc.cxx:708
3  0x7fd7f18f90ad in 
attribute_set_new_from_extended_attributes(com::sun::star::uno::Reference
 const&)
(rExtendedAttributes=uno::Reference to (SwAccessibleDocument *) 
0x7e4e180) at vcl/unx/gtk3/a11y/gtk3atktextattributes.cxx:1229
4  0x7fd7f19113f3 in wrapper_get_attributes(_AtkObject*) 
(atk_obj=0x7df37d0) at vcl/unx/gtk3/a11y/gtk3atkwrapper.cxx:394

I put "Related" because I don't know if it corresponds to the initial bug
but I used the attached file of the bugtracker

Change-Id: Ief9fda9f7bcf277d18490169eee2e43fb046a1bf
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109051
Tested-by: Jenkins
Reviewed-by: Michael Stahl 

diff --git a/sw/source/core/access/accdoc.cxx b/sw/source/core/access/accdoc.cxx
index a1661bb468d5..7d920afc7d17 100644
--- a/sw/source/core/access/accdoc.cxx
+++ b/sw/source/core/access/accdoc.cxx
@@ -582,7 +582,7 @@ uno::Any SAL_CALL 
SwAccessibleDocument::getExtendedAttributes()
 {
 if (!(pCurrTextFrame->IsInTab() || pCurrTextFrame->IsInFootnote()))
 {
-while( pTextFrame != pCurrTextFrame )
+while( pTextFrame && pTextFrame != pCurrTextFrame )
 {
 //check header/footer
 pFrame = pTextFrame;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-14 Thread Julien Nabet (via logerrit)
 sc/source/ui/inc/optsolver.hxx  |2 +-
 sc/source/ui/miscdlgs/optsolver.cxx |6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 27c5135744aa0654eec37f45e94024317e92a76a
Author: Julien Nabet 
AuthorDate: Wed Jan 13 20:37:52 2021 +0100
Commit: Caolán McNamara 
CommitDate: Thu Jan 14 10:10:58 2021 +0100

Rename m_xBtnCancel->m_xBtnClose (sc/optsolver)

Since it corresponds to id="close" gtk-close, response close
in sc/uiconfig/scalc/ui/solverdlg.ui

Change-Id: I909f8f7a5d08784bda786eb86d92f88831749f23
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109246
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 

diff --git a/sc/source/ui/inc/optsolver.hxx b/sc/source/ui/inc/optsolver.hxx
index e76bbcb465f8..892c68869b0e 100644
--- a/sc/source/ui/inc/optsolver.hxx
+++ b/sc/source/ui/inc/optsolver.hxx
@@ -177,7 +177,7 @@ private:
 std::unique_ptr m_xScrollBar;
 
 std::unique_ptr m_xBtnOpt;
-std::unique_ptr m_xBtnCancel;
+std::unique_ptr m_xBtnClose;
 std::unique_ptr m_xBtnSolve;
 std::unique_ptr m_xBtnResetAll;
 
diff --git a/sc/source/ui/miscdlgs/optsolver.cxx 
b/sc/source/ui/miscdlgs/optsolver.cxx
index c25cdd5c7dce..dec0442b5d2a 100644
--- a/sc/source/ui/miscdlgs/optsolver.cxx
+++ b/sc/source/ui/miscdlgs/optsolver.cxx
@@ -200,7 +200,7 @@ ScOptSolverDlg::ScOptSolverDlg(SfxBindings* pB, 
SfxChildWindow* pCW, weld::Windo
 , m_xBtnDel4(m_xBuilder->weld_button("del4"))
 , m_xScrollBar(m_xBuilder->weld_scrolled_window("scrollbar", true))
 , m_xBtnOpt(m_xBuilder->weld_button("options"))
-, m_xBtnCancel(m_xBuilder->weld_button("close"))
+, m_xBtnClose(m_xBuilder->weld_button("close"))
 , m_xBtnSolve(m_xBuilder->weld_button("ok"))
 , m_xBtnResetAll(m_xBuilder->weld_button("resetall"))
 , m_xResultFT(m_xBuilder->weld_label("result"))
@@ -272,7 +272,7 @@ void ScOptSolverDlg::Init(const ScAddress& rCursorPos)
 pButton->set_image(xDelNm);
 
 m_xBtnOpt->connect_clicked( LINK( this, ScOptSolverDlg, BtnHdl ) );
-m_xBtnCancel->connect_clicked( LINK( this, ScOptSolverDlg, BtnHdl ) );
+m_xBtnClose->connect_clicked( LINK( this, ScOptSolverDlg, BtnHdl ) );
 m_xBtnSolve->connect_clicked( LINK( this, ScOptSolverDlg, BtnHdl ) );
 m_xBtnResetAll->connect_clicked( LINK( this, ScOptSolverDlg, BtnHdl ) );
 
@@ -507,7 +507,7 @@ bool ScOptSolverDlg::IsRefInputMode() const
 
 IMPL_LINK(ScOptSolverDlg, BtnHdl, weld::Button&, rBtn, void)
 {
-if ( == m_xBtnSolve.get() ||  == m_xBtnCancel.get())
+if ( == m_xBtnSolve.get() ||  == m_xBtnClose.get())
 {
 bool bSolve = (  == m_xBtnSolve.get() );
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - forms/source

2021-01-15 Thread Julien Nabet (via logerrit)
 forms/source/component/clickableimage.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 45963cfb6b453cf18aaa7534f20c35a38975dc89
Author: Julien Nabet 
AuthorDate: Wed Dec 2 00:05:14 2020 +0100
Commit: Lionel Mamane 
CommitDate: Sat Jan 16 01:47:14 2021 +0100

tdf#46579: fix form fields 'Image Button' in Forms

urls have this form:
.uno:FormController/moveToFirst
.uno:FormController/moveToPrev
etc.

So we must use these links for hyperlinks
+ interceptor with ControlFeatureInterception

+ includes https://gerrit.libreoffice.org/c/core/+/107158

Change-Id: I9cff19833d859624239ca6c76152cc88f9cbb278
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107037
Reviewed-by: Julien Nabet 
(cherry picked from commit 07be45d03f80fa681c697ca9f5a13084a81c7a26)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107099
Tested-by: Jenkins
Reviewed-by: Eike Rathke 
Reviewed-by: Lionel Mamane 

diff --git a/forms/source/component/clickableimage.cxx 
b/forms/source/component/clickableimage.cxx
index 68861e42cf30..bc2a2ba739e5 100644
--- a/forms/source/component/clickableimage.cxx
+++ b/forms/source/component/clickableimage.cxx
@@ -310,9 +310,9 @@ namespace frm
 }
 else
 {
-URL aHyperLink = 
m_pFeatureInterception->getTransformer().getStrictURLFromAscii( 
".uno:OpenHyperlink" );
+URL aHyperLink = 
m_pFeatureInterception->getTransformer().getStrictURL(aURL.Complete);
 
-Reference< XDispatch >  xDisp = Reference< 
XDispatchProvider > (xFrame,UNO_QUERY_THROW)->queryDispatch(aHyperLink, 
OUString() , 0);
+Reference< XDispatch > xDisp =  
m_pFeatureInterception->queryDispatch(aHyperLink);
 
 if ( xDisp.is() )
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-14 Thread Julien Nabet (via logerrit)
 svx/source/dialog/rubydialog.cxx |2 +-
 svx/uiconfig/ui/asianphoneticguidedialog.ui  |4 ++--
 sw/qa/uitest/writer_tests2/asianPhoneticGuide.py |2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 6a80183743d71b1a03a67e6dc4657dea6d56e6fe
Author: Julien Nabet 
AuthorDate: Wed Jan 13 23:00:22 2021 +0100
Commit: Caolán McNamara 
CommitDate: Thu Jan 14 16:55:44 2021 +0100

Asian phonetic guide dialog uses "close" widget

and not cancel one.
widget response = -7 corresponds to GTK_RESPONSE_CLOSE
See https://gtk.developpez.com/doc/en/gtk/GtkDialog.html
label is "gtk-close" and the variable name is "m_xClosePB"

Change-Id: I6ac8e1814ff3c594498d81e99e864939b6a2c23a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109252
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 

diff --git a/svx/source/dialog/rubydialog.cxx b/svx/source/dialog/rubydialog.cxx
index 2c74895c0bb1..4302d4f6b41d 100644
--- a/svx/source/dialog/rubydialog.cxx
+++ b/svx/source/dialog/rubydialog.cxx
@@ -205,7 +205,7 @@ SvxRubyDialog::SvxRubyDialog(SfxBindings* pBind, 
SfxChildWindow* pCW, weld::Wind
 , m_xCharStyleLB(m_xBuilder->weld_combo_box("stylelb"))
 , m_xStylistPB(m_xBuilder->weld_button("styles"))
 , m_xApplyPB(m_xBuilder->weld_button("ok"))
-, m_xClosePB(m_xBuilder->weld_button("cancel"))
+, m_xClosePB(m_xBuilder->weld_button("close"))
 , m_xContentArea(m_xDialog->weld_content_area())
 , m_xGrid(m_xBuilder->weld_widget("grid"))
 , m_xPreviewWin(new RubyPreview)
diff --git a/svx/uiconfig/ui/asianphoneticguidedialog.ui 
b/svx/uiconfig/ui/asianphoneticguidedialog.ui
index 8c4e4c9237bf..96d2dc04cb65 100644
--- a/svx/uiconfig/ui/asianphoneticguidedialog.ui
+++ b/svx/uiconfig/ui/asianphoneticguidedialog.ui
@@ -35,7 +35,7 @@
   
 
 
-  
+  
 gtk-close
 True
 True
@@ -487,7 +487,7 @@
 
 
   ok
-  cancel
+  close
   help
 
 
diff --git a/sw/qa/uitest/writer_tests2/asianPhoneticGuide.py 
b/sw/qa/uitest/writer_tests2/asianPhoneticGuide.py
index 4722541e6e66..1af2bfe94933 100644
--- a/sw/qa/uitest/writer_tests2/asianPhoneticGuide.py
+++ b/sw/qa/uitest/writer_tests2/asianPhoneticGuide.py
@@ -42,7 +42,7 @@ class asianPhoneticGuide(UITestCase):
 xApplyBtn = xDialog.getChild("ok")
 xApplyBtn.executeAction("CLICK", tuple())
 
-xCloseBtn = xDialog.getChild("cancel")
+xCloseBtn = xDialog.getChild("close")
 self.ui_test.close_dialog_through_button(xCloseBtn)
 
 self.assertEqual(document.Text.String[0:1], "a")
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-16 Thread Julien Nabet (via logerrit)
 include/o3tl/safeint.hxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit ebb0ac4c922b51191979ca376f7c7d7581ace62e
Author: Julien Nabet 
AuthorDate: Fri Jan 15 10:01:51 2021 +0100
Commit: Julien Nabet 
CommitDate: Sat Jan 16 11:19:23 2021 +0100

Fix o3tl::checked_multiply for Raspberry pi 4b

usr/bin/ld : /usr/bin/ld: Erreur DWARF: ne peut repérer la spécification de 
variable au décalage 8953
/usr/bin/ld: Erreur DWARF: ne peut repérer la spécification de variable au 
décalage 93da
/usr/bin/ld: Erreur DWARF: ne peut repérer la spécification de variable au 
décalage 967a
/usr/bin/ld: Erreur DWARF: ne peut repérer la spécification de variable au 
décalage 991a
/home/pi/lo/libreoffice/workdir/CxxObject/sw/source/filter/xml/xmlimp.o : 
dans la fonction « bool o3tl::checked_multiply(long long, long long, 
long long&) » :
/home/pi/lo/libreoffice/include/o3tl/safeint.hxx:121 : référence indéfinie 
vers « __mulodi4 »
/usr/bin/ld : /home/pi/lo/libreoffice/include/o3tl/safeint.hxx:121 : 
référence indéfinie vers « __mulodi4 »
/usr/bin/ld : /home/pi/lo/libreoffice/include/o3tl/safeint.hxx:121 : 
référence indéfinie vers « __mulodi4 »
/usr/bin/ld : /home/pi/lo/libreoffice/include/o3tl/safeint.hxx:121 : 
référence indéfinie vers « __mulodi4 »
clang: error: linker command failed with exit code 1 (use -v to see 
invocation)
make[1]: *** [/home/pi/lo/libreoffice/sw/Library_sw.mk:20 : 
/home/pi/lo/libreoffice/instdir/program/libswlo.so] Erreur 1

DWARF Error: can't find spec of var at offset 8953

undefined reference to "__mulodi4"

Change-Id: I1c88a1567e25370eb5759912ea4918d7183f3786
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109322
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/include/o3tl/safeint.hxx b/include/o3tl/safeint.hxx
index 0ed36c910fa3..9df92ea1a9d1 100644
--- a/include/o3tl/safeint.hxx
+++ b/include/o3tl/safeint.hxx
@@ -113,7 +113,7 @@ template inline bool checked_sub(T a, T b, T& 
result)
 return !msl::utilities::SafeSubtract(a, b, result);
 }
 
-#elif (defined __GNUC__ && !defined __clang__) || 
(__has_builtin(__builtin_mul_overflow) && !(defined ANDROID && defined 
__clang__) && !(defined(__clang__) && defined(__i386__)))
+#elif (defined __GNUC__ && !defined __clang__) || 
(__has_builtin(__builtin_mul_overflow) && !(defined ANDROID && defined 
__clang__) && !(defined(__clang__) && (defined(__arm__) || defined(__i386__
 // 32-bit clang fails with undefined reference to `__mulodi4'
 
 template inline bool checked_multiply(T a, T b, T& result)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-16 Thread Julien Nabet (via logerrit)
 vcl/uiconfig/ui/screenshotparent.ui |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit ffc8409024c0de97cd1cb5fadbe72d90c3fd7d3b
Author: Julien Nabet 
AuthorDate: Fri Jan 15 21:47:28 2021 +0100
Commit: Caolán McNamara 
CommitDate: Sat Jan 16 16:08:35 2021 +0100

Cancel action here vcl/screenshotparent

Change-Id: I136fa04e873932621b92004e8eafd7b3a32ef945
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109423
Tested-by: Jenkins
Tested-by: Caolán McNamara 
Reviewed-by: Caolán McNamara 

diff --git a/vcl/uiconfig/ui/screenshotparent.ui 
b/vcl/uiconfig/ui/screenshotparent.ui
index 620338c80cf8..629b1741b5de 100644
--- a/vcl/uiconfig/ui/screenshotparent.ui
+++ b/vcl/uiconfig/ui/screenshotparent.ui
@@ -23,7 +23,7 @@
 end
 
   
-_Close
+_Cancel
 True
 True
 True
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-16 Thread Julien Nabet (via logerrit)
 helpcontent2  |2 +-
 vcl/source/gdi/pdfwriter_impl.cxx |2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 1cc0fc1f3cdae597912d7204256427e060fcde61
Author: Julien Nabet 
AuthorDate: Sat Jan 16 14:32:42 2021 +0100
Commit: Julien Nabet 
CommitDate: Sat Jan 16 16:35:17 2021 +0100

tdf#139643: fix missing PDF/UA flag

Regression from:

https://cgit.freedesktop.org/libreoffice/core/commit/vcl/source/gdi/pdfwriter_impl.cxx?id=a795886762a6a4aabd601183598c4e6c819bcb1f
author  Arnaud Versini  2019-09-20 19:01:34 
+0200
committer   Arnaud Versini  2020-02-08 
15:03:07 +0100
commit  a795886762a6a4aabd601183598c4e6c819bcb1f (patch)
tree93a58d738bf27a0c5f75f80dc7e651763916ee5f 
/vcl/source/gdi/pdfwriter_impl.cxx
parent  a2f62a861ba7036e689070c47f72214b1bdd49d4 (diff)
Add minimum support for PDF/A3

here:
 sal_Int32 PDFWriterImpl::emitDocumentMetadata()
 {
-if (!m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_UA)
+if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 )

Change-Id: Id4b3b9a74ccf5a5abd9e7149cb09b3475dd4ffee
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109437
Tested-by: Julien Nabet 
Reviewed-by: Julien Nabet 

diff --git a/vcl/source/gdi/pdfwriter_impl.cxx 
b/vcl/source/gdi/pdfwriter_impl.cxx
index aee37877c7f6..7339c4cbeb19 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -5236,7 +5236,7 @@ static void lcl_assignMeta(const OUString& aValue, 
OString& aMeta)
 // emits the document metadata
 sal_Int32 PDFWriterImpl::emitDocumentMetadata()
 {
-if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 )
+if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 && !m_bIsPDF_UA)
 return 0;
 
 //get the object number for all the destinations
commit 208a2e51c32a8918388216bf2f47b513948ebd7d
Author: Ilmari Lauhakangas 
AuthorDate: Sat Jan 16 17:35:09 2021 +0200
Commit: Gerrit Code Review 
CommitDate: Sat Jan 16 16:35:09 2021 +0100

Update git submodules

* Update helpcontent2 from branch 'master'
  to 91413eacbe8790505dfd4cc452b0fa2e5589ac33
  - Use switches for Ctrl vs. Command on macOS

Change-Id: I13829b216081021ae321a5c7111de0e11e65a7ee
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/109440
Tested-by: Jenkins
Reviewed-by: Olivier Hallot 

diff --git a/helpcontent2 b/helpcontent2
index 942c4de7eb85..91413eacbe87 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit 942c4de7eb854bb99e3ed79caa283608ec1891a7
+Subproject commit 91413eacbe8790505dfd4cc452b0fa2e5589ac33
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - sc/source sc/uiconfig

2021-01-18 Thread Julien Nabet (via logerrit)
 sc/source/ui/dbgui/pvfundlg.cxx|2 +-
 sc/uiconfig/scalc/ui/datafieldoptionsdialog.ui |4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 430454fb5d30aa2767d12b90afd8e45a19daa9a6
Author: Julien Nabet 
AuthorDate: Tue Jan 12 20:09:40 2021 +0100
Commit: Szymon Kłos 
CommitDate: Mon Jan 18 13:57:19 2021 +0100

Revert "pivot table: make options cancel button working" + fix crash again

In the dialog, you have 3 buttons "Help", "Cancel" and "OK"
Using "Cancel" will call "close" which doesn't revert back changes.
To test this:
- Launch Calc
- Create an array with 2 cols (qtX and qtY) and put 2 rows of values
- Create a pivot dialog
- Put qtX in "Filters" part
- Double click on qtX (=> "Data Field" dialog appears)
- Click "Options..." (=> "Data Field Options" dialog appears)
- Enable any checkbox (eg: Empty line after each time) + click "OK" (=> 
dialog "Data Field Options" closes)
- Click "Options..." again (the checkbox is still enabled as expected)
- Disable the checkbox + click "Cancel" (=> dialog "Data Field Options" 
closes)
- Click "Options..." again (the checkbox is still enabled as NOT expected)

So revert the below quoted commit and fix this by using "cancel" in:
- action-widget response
- id for the GtkButton
- the use of the id to initialize m_xBtnCancel with m_xBuilder->weld_button

This reverts commit c2a349bc1482482d3e5ec06232c166d77fe9b602.

Change-Id: I555a90706de635e90b0ee397dfd958df55b5c40a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109193
Tested-by: Jenkins
Reviewed-by: Szymon Kłos 
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109255
Tested-by: Jenkins CollaboraOffice 

diff --git a/sc/source/ui/dbgui/pvfundlg.cxx b/sc/source/ui/dbgui/pvfundlg.cxx
index af4ecb1e0b5d..19c924e6982f 100644
--- a/sc/source/ui/dbgui/pvfundlg.cxx
+++ b/sc/source/ui/dbgui/pvfundlg.cxx
@@ -667,7 +667,7 @@ ScDPSubtotalOptDlg::ScDPSubtotalOptDlg(weld::Window* 
pParent, ScDPObject& rDPObj
 , m_xFtHierarchy(m_xBuilder->weld_label("hierarchyft"))
 , m_xLbHierarchy(m_xBuilder->weld_combo_box("hierarchy"))
 , m_xBtnOk(m_xBuilder->weld_button("ok"))
-, m_xBtnCancel(m_xBuilder->weld_button("close"))
+, m_xBtnCancel(m_xBuilder->weld_button("cancel"))
 , mrDPObj(rDPObj)
 , maLabelData(rLabelData)
 {
diff --git a/sc/uiconfig/scalc/ui/datafieldoptionsdialog.ui 
b/sc/uiconfig/scalc/ui/datafieldoptionsdialog.ui
index 51ae488105f5..67c46233e97a 100644
--- a/sc/uiconfig/scalc/ui/datafieldoptionsdialog.ui
+++ b/sc/uiconfig/scalc/ui/datafieldoptionsdialog.ui
@@ -61,7 +61,7 @@
   
 
 
-  
+  
 gtk-cancel
 True
 True
@@ -587,7 +587,7 @@
 
 
   ok
-  close
+  cancel
   help
 
   
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-13 Thread Julien Nabet (via logerrit)
 connectivity/source/inc/hsqldb/HStorageAccess.hxx |7 +++
 connectivity/source/inc/hsqldb/HStorageMap.hxx|9 +
 connectivity/source/inc/java/LocalRef.hxx |8 +++-
 connectivity/source/inc/java/tools.hxx|7 +++
 4 files changed, 30 insertions(+), 1 deletion(-)

New commits:
commit 2b157a5bd6731ce213411806a39344365a56af71
Author: Julien Nabet 
AuthorDate: Wed Jan 13 18:52:31 2021 +0100
Commit: Julien Nabet 
CommitDate: Wed Jan 13 18:54:23 2021 +0100

Fix some warnings for Raspberry pi 4 (part6)

Change-Id: I1114968f38a5309862723dde9554e3df97309f23
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109239
Tested-by: Julien Nabet 
Reviewed-by: Julien Nabet 

diff --git a/connectivity/source/inc/hsqldb/HStorageAccess.hxx 
b/connectivity/source/inc/hsqldb/HStorageAccess.hxx
index 457d1eaffc73..feab18e412c6 100644
--- a/connectivity/source/inc/hsqldb/HStorageAccess.hxx
+++ b/connectivity/source/inc/hsqldb/HStorageAccess.hxx
@@ -22,7 +22,14 @@
 
 #include 
 
+#if defined __clang__
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wunknown-attributes"
+#endif
 #include 
+#if defined __clang__
+#pragma clang diagnostic pop
+#endif
 
 namespace connectivity::hsqldb
 {
diff --git a/connectivity/source/inc/hsqldb/HStorageMap.hxx 
b/connectivity/source/inc/hsqldb/HStorageMap.hxx
index 05044b75cf47..15aecc02cfe4 100644
--- a/connectivity/source/inc/hsqldb/HStorageMap.hxx
+++ b/connectivity/source/inc/hsqldb/HStorageMap.hxx
@@ -30,7 +30,16 @@
 #include 
 #include 
 #include 
+
+#if defined __clang__
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wunknown-attributes"
+#endif
 #include 
+#if defined __clang__
+#pragma clang diagnostic pop
+#endif
+
 #include 
 
 namespace connectivity::hsqldb
diff --git a/connectivity/source/inc/java/LocalRef.hxx 
b/connectivity/source/inc/java/LocalRef.hxx
index 5973405acea5..dc9531507ee2 100644
--- a/connectivity/source/inc/java/LocalRef.hxx
+++ b/connectivity/source/inc/java/LocalRef.hxx
@@ -20,8 +20,14 @@
 #ifndef INCLUDED_CONNECTIVITY_SOURCE_INC_JAVA_LOCALREF_HXX
 #define INCLUDED_CONNECTIVITY_SOURCE_INC_JAVA_LOCALREF_HXX
 
+#if defined __clang__
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wunknown-attributes"
+#endif
 #include 
-
+#if defined __clang__
+#pragma clang diagnostic pop
+#endif
 
 namespace connectivity::jdbc
 {
diff --git a/connectivity/source/inc/java/tools.hxx 
b/connectivity/source/inc/java/tools.hxx
index aa7cb20cad9b..e17fa9c42ebb 100644
--- a/connectivity/source/inc/java/tools.hxx
+++ b/connectivity/source/inc/java/tools.hxx
@@ -23,7 +23,14 @@
 #include 
 #include 
 
+#if defined __clang__
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wunknown-attributes"
+#endif
 #include 
+#if defined __clang__
+#pragma clang diagnostic pop
+#endif
 
 #include 
 #include 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-14 Thread Julien Nabet (via logerrit)
 sw/source/ui/dbui/mmoutputtypepage.cxx |6 +++---
 sw/source/ui/inc/mmresultdialogs.hxx   |4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

New commits:
commit 25c5894885f1382a3fb2c7bcc08e3bdd69368865
Author: Julien Nabet 
AuthorDate: Thu Jan 14 18:10:31 2021 +0100
Commit: Caolán McNamara 
CommitDate: Thu Jan 14 21:13:59 2021 +0100

Rename m_xClose->mxCancel + CloseHdl_Impl->CancelHdl_Impl (sw/mailmerge)

In sw/uiconfig/swriter/ui/mmsendmails.ui
we got:
id="cancel"
gtk-cancel
cancel
+
in sw/source/ui/dbui/mmoutputtypepage.cxx
IMPL_LINK_NOARG(SwSendMailDialog, CancelHdl_Impl, weld::Button&, void)
we got:
if (m_bDestructionEnabled)
m_xDialog->response(RET_CANCEL);

we want to cancel the process to send (of course what's already be sent 
can't be undone)

Change-Id: If221ecc20366f0634079ab515613757cc019c8ed
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109300
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 

diff --git a/sw/source/ui/dbui/mmoutputtypepage.cxx 
b/sw/source/ui/dbui/mmoutputtypepage.cxx
index d56e369eb85b..7a8730acfe34 100644
--- a/sw/source/ui/dbui/mmoutputtypepage.cxx
+++ b/sw/source/ui/dbui/mmoutputtypepage.cxx
@@ -217,7 +217,7 @@ SwSendMailDialog::SwSendMailDialog(weld::Window *pParent, 
SwMailMergeConfigItem&
 , m_xErrorStatus(m_xBuilder->weld_label("errorstatus"))
 , m_xStatus(m_xBuilder->weld_tree_view("container"))
 , m_xStop(m_xBuilder->weld_button("stop"))
-, m_xClose(m_xBuilder->weld_button("cancel"))
+, m_xCancel(m_xBuilder->weld_button("cancel"))
 , m_xExpander(m_xBuilder->weld_expander("details"))
 {
 m_sStop = m_xStop->get_label();
@@ -229,7 +229,7 @@ SwSendMailDialog::SwSendMailDialog(weld::Window *pParent, 
SwMailMergeConfigItem&
 m_xStatus->set_size_request(aSize.Width(), aSize.Height());
 
 m_xStop->connect_clicked(LINK( this, SwSendMailDialog, StopHdl_Impl));
-m_xClose->connect_clicked(LINK( this, SwSendMailDialog, CloseHdl_Impl));
+m_xCancel->connect_clicked(LINK( this, SwSendMailDialog, CancelHdl_Impl));
 
 std::vector aWidths;
 aWidths.push_back(m_xStatus->get_checkbox_column_width());
@@ -296,7 +296,7 @@ IMPL_LINK( SwSendMailDialog, StopHdl_Impl, weld::Button&, 
rButton, void )
 }
 }
 
-IMPL_LINK_NOARG(SwSendMailDialog, CloseHdl_Impl, weld::Button&, void)
+IMPL_LINK_NOARG(SwSendMailDialog, CancelHdl_Impl, weld::Button&, void)
 {
 m_xDialog->hide();
 
diff --git a/sw/source/ui/inc/mmresultdialogs.hxx 
b/sw/source/ui/inc/mmresultdialogs.hxx
index 1e78fc80203f..18151a810f99 100644
--- a/sw/source/ui/inc/mmresultdialogs.hxx
+++ b/sw/source/ui/inc/mmresultdialogs.hxx
@@ -160,11 +160,11 @@ class SwSendMailDialog : public 
weld::GenericDialogController
 std::unique_ptr m_xErrorStatus;
 std::unique_ptr m_xStatus;
 std::unique_ptr m_xStop;
-std::unique_ptr m_xClose;
+std::unique_ptr m_xCancel;
 std::unique_ptr m_xExpander;
 
 DECL_LINK( StopHdl_Impl, weld::Button&, void );
-DECL_LINK( CloseHdl_Impl, weld::Button& , void);
+DECL_LINK( CancelHdl_Impl, weld::Button& , void);
 DECL_STATIC_LINK( SwSendMailDialog, StartSendMails, void*, void );
 DECL_STATIC_LINK( SwSendMailDialog, StopSendMails, void*, void );
 DECL_LINK( RemoveThis, Timer*, void );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-14 Thread Julien Nabet (via logerrit)
 sw/uiconfig/swriter/ui/tocdialog.ui |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit a9af05467ef43dd53ec1666ce35f70a439065c89
Author: Julien Nabet 
AuthorDate: Thu Jan 14 18:27:01 2021 +0100
Commit: Caolán McNamara 
CommitDate: Thu Jan 14 21:08:55 2021 +0100

Replace gtk-close to gtk-cancel (sw TOC dialog)

In sw/uiconfig/swriter/ui/tocdialog.ui
we got:
id="cancel"
cancel

In sw/source/ui/index/cnttab.cxx
we got:
SfxTabDialogController(pParent, "modules/swriter/ui/tocdialog.ui", 
"TocDialog", )
which contains std::unique_ptr m_xCancelBtn;

and finally if you change some options in the TOC dialog and click on 
"Close"
then open again the dialog, all the changed options are reverted.

=> UI impact, the button is renamed "Cancel" instead of "Close"

Change-Id: Ia99e7c8a10da51f258faf0833ea1931ce62364bb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109301
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 

diff --git a/sw/uiconfig/swriter/ui/tocdialog.ui 
b/sw/uiconfig/swriter/ui/tocdialog.ui
index 9cc5485f2bd0..b60995274956 100644
--- a/sw/uiconfig/swriter/ui/tocdialog.ui
+++ b/sw/uiconfig/swriter/ui/tocdialog.ui
@@ -55,7 +55,7 @@
 
 
   
-gtk-close
+gtk-cancel
 True
 True
 True
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - vcl/source

2021-01-17 Thread Julien Nabet (via logerrit)
 vcl/source/gdi/pdfwriter_impl.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f1d7be7863e7d2d5aa3c3008bb9ec04780d5eb95
Author: Julien Nabet 
AuthorDate: Sat Jan 16 14:32:42 2021 +0100
Commit: Adolfo Jayme Barrientos 
CommitDate: Sun Jan 17 14:07:18 2021 +0100

tdf#139643: fix missing PDF/UA flag

Regression from:

https://cgit.freedesktop.org/libreoffice/core/commit/vcl/source/gdi/pdfwriter_impl.cxx?id=a795886762a6a4aabd601183598c4e6c819bcb1f
author  Arnaud Versini  2019-09-20 19:01:34 
+0200
committer   Arnaud Versini  2020-02-08 
15:03:07 +0100
commit  a795886762a6a4aabd601183598c4e6c819bcb1f (patch)
tree93a58d738bf27a0c5f75f80dc7e651763916ee5f 
/vcl/source/gdi/pdfwriter_impl.cxx
parent  a2f62a861ba7036e689070c47f72214b1bdd49d4 (diff)
Add minimum support for PDF/A3

here:
 sal_Int32 PDFWriterImpl::emitDocumentMetadata()
 {
-if (!m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_UA)
+if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 )

Change-Id: Id4b3b9a74ccf5a5abd9e7149cb09b3475dd4ffee
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109399
Reviewed-by: Tomaž Vajngerl 
Reviewed-by: Adolfo Jayme Barrientos 
Tested-by: Jenkins

diff --git a/vcl/source/gdi/pdfwriter_impl.cxx 
b/vcl/source/gdi/pdfwriter_impl.cxx
index 11de3436e531..951cda0f29da 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -5237,7 +5237,7 @@ static void lcl_assignMeta(const OUString& aValue, 
OString& aMeta)
 // emits the document metadata
 sal_Int32 PDFWriterImpl::emitDocumentMetadata()
 {
-if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 )
+if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 && !m_bIsPDF_UA)
 return 0;
 
 //get the object number for all the destinations
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-17 Thread Julien Nabet (via logerrit)
 cui/source/dialogs/FontFeaturesDialog.cxx |7 ---
 1 file changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 648edf96cde392545749923dc0c748e0bb31b5f6
Author: Julien Nabet 
AuthorDate: Sun Jan 17 11:02:12 2021 +0100
Commit: Julien Nabet 
CommitDate: Sun Jan 17 11:53:43 2021 +0100

Try to fix Windows TB

by using std::max and std::min

Change-Id: I07c93227cf040f159d1977ca94988169ecd6dc14
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109464
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/cui/source/dialogs/FontFeaturesDialog.cxx 
b/cui/source/dialogs/FontFeaturesDialog.cxx
index 71c9e34d3e73..333cf1087f05 100644
--- a/cui/source/dialogs/FontFeaturesDialog.cxx
+++ b/cui/source/dialogs/FontFeaturesDialog.cxx
@@ -76,9 +76,10 @@ void FontFeaturesDialog::initialize()
 fillGrid(rFilteredFontFeatures);
 
 m_xContentWindow->set_size_request(
--1, std::min(std::max(m_xContentWindow->get_preferred_size().Height(),
-  m_xContentGrid->get_preferred_size().Height()),
- 300L));
+-1,
+
std::min(std::max(m_xContentWindow->get_preferred_size().Height(),
+
m_xContentGrid->get_preferred_size().Height()),
+  300));
 
 updateFontPreview();
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - vcl/source

2021-01-17 Thread Julien Nabet (via logerrit)
 vcl/source/gdi/pdfwriter_impl.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit e819872ebc1f7f005cea3916561dae03c43f8552
Author: Julien Nabet 
AuthorDate: Sat Jan 16 14:32:42 2021 +0100
Commit: Adolfo Jayme Barrientos 
CommitDate: Sun Jan 17 14:06:45 2021 +0100

tdf#139643: fix missing PDF/UA flag

Regression from:

https://cgit.freedesktop.org/libreoffice/core/commit/vcl/source/gdi/pdfwriter_impl.cxx?id=a795886762a6a4aabd601183598c4e6c819bcb1f
author  Arnaud Versini  2019-09-20 19:01:34 
+0200
committer   Arnaud Versini  2020-02-08 
15:03:07 +0100
commit  a795886762a6a4aabd601183598c4e6c819bcb1f (patch)
tree93a58d738bf27a0c5f75f80dc7e651763916ee5f 
/vcl/source/gdi/pdfwriter_impl.cxx
parent  a2f62a861ba7036e689070c47f72214b1bdd49d4 (diff)
Add minimum support for PDF/A3

here:
 sal_Int32 PDFWriterImpl::emitDocumentMetadata()
 {
-if (!m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_UA)
+if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 )

Change-Id: Id4b3b9a74ccf5a5abd9e7149cb09b3475dd4ffee
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109400
Reviewed-by: Tomaž Vajngerl 
Reviewed-by: Adolfo Jayme Barrientos 
Tested-by: Jenkins

diff --git a/vcl/source/gdi/pdfwriter_impl.cxx 
b/vcl/source/gdi/pdfwriter_impl.cxx
index 7e02762d6e36..375a4fcba0d7 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -5135,7 +5135,7 @@ static void lcl_assignMeta(const OUString& aValue, 
OString& aMeta)
 // emits the document metadata
 sal_Int32 PDFWriterImpl::emitDocumentMetadata()
 {
-if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 )
+if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 && !m_bIsPDF_UA)
 return 0;
 
 //get the object number for all the destinations
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-17 Thread Julien Nabet (via logerrit)
 sal/osl/unx/process.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit ad55d51486264260a135b36c85973a728e006de7
Author: Julien Nabet 
AuthorDate: Sun Jan 17 13:42:50 2021 +0100
Commit: Julien Nabet 
CommitDate: Sun Jan 17 15:15:47 2021 +0100

cppcheck: zerodivcond

I don't know if it can happen or if it's a false positive
but at least, we're sure now it won't fail

Change-Id: Id4620d74c0893b308b9fb45be71ca6c425066ae4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109470
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sal/osl/unx/process.cxx b/sal/osl/unx/process.cxx
index 861324963dec..f75534fdc311 100644
--- a/sal/osl/unx/process.cxx
+++ b/sal/osl/unx/process.cxx
@@ -1067,7 +1067,7 @@ oslProcessError SAL_CALL osl_getProcessInfo(oslProcess 
Process, oslProcessData F
 unsigned long systemseconds;
 
 clktck = sysconf(_SC_CLK_TCK);
-if (clktck < 0) {
+if (clktck <= 0) {
 return osl_Process_E_Unknown;
 }
 hz = static_cast(clktck);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-17 Thread Julien Nabet (via logerrit)
 drawinglayer/source/primitive2d/svggradientprimitive2d.cxx |4 ++--
 sw/source/uibase/docvw/FrameControlsManager.cxx|2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 95f2c4c6396c826b5cf94adcc848c0df4dc76030
Author: Julien Nabet 
AuthorDate: Sun Jan 17 13:16:04 2021 +0100
Commit: Julien Nabet 
CommitDate: Sun Jan 17 15:16:12 2021 +0100

cppcheck: Prefer prefix ++/-- operators for non-primitive types

Change-Id: I85b596a37c1e111fad8afeb9d4cb4d75c257
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109469
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/drawinglayer/source/primitive2d/svggradientprimitive2d.cxx 
b/drawinglayer/source/primitive2d/svggradientprimitive2d.cxx
index 7c9eb8441306..116c2c6c03db 100644
--- a/drawinglayer/source/primitive2d/svggradientprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/svggradientprimitive2d.cxx
@@ -186,7 +186,7 @@ namespace drawinglayer::primitive2d
 const bool bMirror(SpreadMethod::Reflect == getSpreadMethod() && 0 
!= rInt % 2);
 const SvgGradientEntryVector& rCurrent(bMirror ? 
getMirroredGradientEntries() : getGradientEntries());
 
-for(SvgGradientEntryVector::const_reverse_iterator 
aIter(rCurrent.rbegin()); aIter != rCurrent.rend(); aIter++)
+for(SvgGradientEntryVector::const_reverse_iterator 
aIter(rCurrent.rbegin()); aIter != rCurrent.rend(); ++aIter)
 {
if(basegfx::fTools::lessOrEqual(aIter->getOffset(), fFrac))
{
@@ -208,7 +208,7 @@ namespace drawinglayer::primitive2d
 const bool bMirror(SpreadMethod::Reflect == getSpreadMethod() && 0 
!= rInt % 2);
 const SvgGradientEntryVector& rCurrent(bMirror ? 
getMirroredGradientEntries() : getGradientEntries());
 
-for(SvgGradientEntryVector::const_iterator 
aIter(rCurrent.begin()); aIter != rCurrent.end(); aIter++)
+for(SvgGradientEntryVector::const_iterator 
aIter(rCurrent.begin()); aIter != rCurrent.end(); ++aIter)
 {
if(basegfx::fTools::more(aIter->getOffset(), fFrac))
{
diff --git a/sw/source/uibase/docvw/FrameControlsManager.cxx 
b/sw/source/uibase/docvw/FrameControlsManager.cxx
index 61bd5ca4badf..c9503e2a06d6 100644
--- a/sw/source/uibase/docvw/FrameControlsManager.cxx
+++ b/sw/source/uibase/docvw/FrameControlsManager.cxx
@@ -203,7 +203,7 @@ void 
SwFrameControlsManager::SetOutlineContentVisibilityButtons()
 it = m_aTextNodeContentFrameMap.erase(it);
 }
 else
-it++;
+++it;
 }
 for (SwNode* pNd : 
m_pEditWin->GetView().GetWrtShell().GetNodes().GetOutLineNds())
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-17 Thread Julien Nabet (via logerrit)
 xmloff/source/text/txtimp.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit 79e471dc116f0b662e48d915d395d398057d137f
Author: Julien Nabet 
AuthorDate: Sun Jan 17 15:31:08 2021 +0100
Commit: Julien Nabet 
CommitDate: Sun Jan 17 16:32:47 2021 +0100

duplicate break (xmloff/txtimp)

Change-Id: I17c63ec5d8accf6f9d2f33ef92cfa63acbd02f3c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109473
Reviewed-by: Noel Grandin 
Reviewed-by: Julien Nabet 
Tested-by: Jenkins

diff --git a/xmloff/source/text/txtimp.cxx b/xmloff/source/text/txtimp.cxx
index 9642eb83d6da..dc6612b113b1 100644
--- a/xmloff/source/text/txtimp.cxx
+++ b/xmloff/source/text/txtimp.cxx
@@ -1767,7 +1767,6 @@ SvXMLImportContext 
*XMLTextImportHelper::CreateTextChildContext(
 pContext = new XMLNumberedParaContext(
 rImport, nElement, xAttrList );
 break;
-break;
 case XML_ELEMENT(TEXT, XML_LIST):
 pContext = new XMLTextListBlockContext( rImport, *this,
 xAttrList );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-1-0' - vcl/source

2021-01-18 Thread Julien Nabet (via logerrit)
 vcl/source/gdi/pdfwriter_impl.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 1965de60afe96235f99683714fdb6403972bcf45
Author: Julien Nabet 
AuthorDate: Sat Jan 16 14:32:42 2021 +0100
Commit: Michael Stahl 
CommitDate: Mon Jan 18 11:37:35 2021 +0100

tdf#139643: fix missing PDF/UA flag

Regression from:

https://cgit.freedesktop.org/libreoffice/core/commit/vcl/source/gdi/pdfwriter_impl.cxx?id=a795886762a6a4aabd601183598c4e6c819bcb1f
author  Arnaud Versini  2019-09-20 19:01:34 
+0200
committer   Arnaud Versini  2020-02-08 
15:03:07 +0100
commit  a795886762a6a4aabd601183598c4e6c819bcb1f (patch)
tree93a58d738bf27a0c5f75f80dc7e651763916ee5f 
/vcl/source/gdi/pdfwriter_impl.cxx
parent  a2f62a861ba7036e689070c47f72214b1bdd49d4 (diff)
Add minimum support for PDF/A3

here:
 sal_Int32 PDFWriterImpl::emitDocumentMetadata()
 {
-if (!m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_UA)
+if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 )

Change-Id: Id4b3b9a74ccf5a5abd9e7149cb09b3475dd4ffee
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109399
Reviewed-by: Tomaž Vajngerl 
Reviewed-by: Adolfo Jayme Barrientos 
Tested-by: Jenkins
(cherry picked from commit f1d7be7863e7d2d5aa3c3008bb9ec04780d5eb95)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109515
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/vcl/source/gdi/pdfwriter_impl.cxx 
b/vcl/source/gdi/pdfwriter_impl.cxx
index 11de3436e531..951cda0f29da 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -5237,7 +5237,7 @@ static void lcl_assignMeta(const OUString& aValue, 
OString& aMeta)
 // emits the document metadata
 sal_Int32 PDFWriterImpl::emitDocumentMetadata()
 {
-if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 )
+if( !m_bIsPDF_A1 && !m_bIsPDF_A2 && !m_bIsPDF_A3 && !m_bIsPDF_UA)
 return 0;
 
 //get the object number for all the destinations
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-17 Thread Julien Nabet (via logerrit)
 sfx2/source/view/classificationhelper.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 5bd90f7f5852056342f1a81a1285b474d468eadd
Author: Julien Nabet 
AuthorDate: Sun Jan 17 15:38:27 2021 +0100
Commit: Julien Nabet 
CommitDate: Sun Jan 17 18:13:03 2021 +0100

cppcheck: derefInvalidIteratorRedundantCheck (sfx2/classificationhelper)

Change-Id: I25fc7eac5b323e5918f03d8bfb410ca6a860219d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109476
Reviewed-by: Noel Grandin 
Reviewed-by: Julien Nabet 
Tested-by: Jenkins

diff --git a/sfx2/source/view/classificationhelper.cxx 
b/sfx2/source/view/classificationhelper.cxx
index 523fe75571bb..85e7f3d55dde 100644
--- a/sfx2/source/view/classificationhelper.cxx
+++ b/sfx2/source/view/classificationhelper.cxx
@@ -700,14 +700,14 @@ InfobarType SfxClassificationHelper::GetImpactLevelType()
 
 SfxClassificationCategory& rCategory = itCategory->second;
 auto it = rCategory.m_aLabels.find(PROP_PREFIX_INTELLECTUALPROPERTY() + 
PROP_IMPACTSCALE());
-OUString aScale = it->second;
 if (it == rCategory.m_aLabels.end())
 return aRet;
+OUString aScale = it->second;
 
 it = rCategory.m_aLabels.find(PROP_PREFIX_INTELLECTUALPROPERTY() + 
PROP_IMPACTLEVEL());
-OUString aLevel = it->second;
 if (it == rCategory.m_aLabels.end())
 return aRet;
+OUString aLevel = it->second;
 
 // The spec defines two valid scale values: FIPS-199 and UK-Cabinet.
 if (aScale == "UK-Cabinet")
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-13 Thread Julien Nabet (via logerrit)
 sc/source/ui/dbgui/pvfundlg.cxx|2 +-
 sc/uiconfig/scalc/ui/datafieldoptionsdialog.ui |4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit cf93998eb5abc193d95ae5433bf4dfd11a9d62d8
Author: Julien Nabet 
AuthorDate: Tue Jan 12 20:09:40 2021 +0100
Commit: Caolán McNamara 
CommitDate: Wed Jan 13 16:12:09 2021 +0100

Revert "pivot table: make options cancel button working" + fix crash again

In the dialog, you have 3 buttons "Help", "Cancel" and "OK"
Using "Cancel" will call "close" which doesn't revert back changes.
To test this:
- Launch Calc
- Create an array with 2 cols (qtX and qtY) and put 2 rows of values
- Create a pivot dialog
- Put qtX in "Filters" part
- Double click on qtX (=> "Data Field" dialog appears)
- Click "Options..." (=> "Data Field Options" dialog appears)
- Enable any checkbox (eg: Empty line after each time) + click "OK" (=> 
dialog "Data Field Options" closes)
- Click "Options..." again (the checkbox is still enabled as expected)
- Disable the checkbox + click "Cancel" (=> dialog "Data Field Options" 
closes)
- Click "Options..." again (the checkbox is still enabled as NOT expected)

So revert the below quoted commit and fix this by using "cancel" in:
- action-widget response
- id for the GtkButton
- the use of the id to initialize m_xBtnCancel with m_xBuilder->weld_button

This reverts commit c2a349bc1482482d3e5ec06232c166d77fe9b602.

Change-Id: I555a90706de635e90b0ee397dfd958df55b5c40a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109193
Tested-by: Jenkins
Reviewed-by: Szymon Kłos 

diff --git a/sc/source/ui/dbgui/pvfundlg.cxx b/sc/source/ui/dbgui/pvfundlg.cxx
index d8f5eaf0c46a..431ef89407de 100644
--- a/sc/source/ui/dbgui/pvfundlg.cxx
+++ b/sc/source/ui/dbgui/pvfundlg.cxx
@@ -651,7 +651,7 @@ ScDPSubtotalOptDlg::ScDPSubtotalOptDlg(weld::Window* 
pParent, ScDPObject& rDPObj
 , m_xFtHierarchy(m_xBuilder->weld_label("hierarchyft"))
 , m_xLbHierarchy(m_xBuilder->weld_combo_box("hierarchy"))
 , m_xBtnOk(m_xBuilder->weld_button("ok"))
-, m_xBtnCancel(m_xBuilder->weld_button("close"))
+, m_xBtnCancel(m_xBuilder->weld_button("cancel"))
 , mrDPObj(rDPObj)
 , maLabelData(rLabelData)
 {
diff --git a/sc/uiconfig/scalc/ui/datafieldoptionsdialog.ui 
b/sc/uiconfig/scalc/ui/datafieldoptionsdialog.ui
index 9a11dc9645f3..5a543f479508 100644
--- a/sc/uiconfig/scalc/ui/datafieldoptionsdialog.ui
+++ b/sc/uiconfig/scalc/ui/datafieldoptionsdialog.ui
@@ -58,7 +58,7 @@
   
 
 
-  
+  
 gtk-cancel
 True
 True
@@ -623,7 +623,7 @@
 
 
   ok
-  close
+  cancel
   help
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-13 Thread Julien Nabet (via logerrit)
 vcl/unx/gtk3/gtk3gtkinst.cxx |9 +++--
 1 file changed, 7 insertions(+), 2 deletions(-)

New commits:
commit e027a91010a4517cfa907f3d80c9188f026b3823
Author: Julien Nabet 
AuthorDate: Tue Jan 12 21:22:51 2021 +0100
Commit: Caolán McNamara 
CommitDate: Wed Jan 13 15:51:09 2021 +0100

Check gtk_builder_add_from_file result and log if needed (vcl/gtk3)

Change-Id: Ic9af6a59a8ffb7fa835026dc44c8431ec412f44a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109200
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 

diff --git a/vcl/unx/gtk3/gtk3gtkinst.cxx b/vcl/unx/gtk3/gtk3gtkinst.cxx
index b36d7d713e86..39c826823d01 100644
--- a/vcl/unx/gtk3/gtk3gtkinst.cxx
+++ b/vcl/unx/gtk3/gtk3gtkinst.cxx
@@ -16777,9 +16777,14 @@ public:
 osl::FileBase::getSystemPathFromFileURL(aUri, aPath);
 m_pBuilder = gtk_builder_new();
 m_nNotifySignalId = g_signal_connect_data(G_OBJECT(m_pBuilder), 
"notify", G_CALLBACK(signalNotify), this, nullptr, G_CONNECT_AFTER);
-auto rc = gtk_builder_add_from_file(m_pBuilder, 
OUStringToOString(aPath, RTL_TEXTENCODING_UTF8).getStr(), nullptr);
+GError *err = nullptr;
+auto rc = gtk_builder_add_from_file(m_pBuilder, 
OUStringToOString(aPath, RTL_TEXTENCODING_UTF8).getStr(), );
+if (!rc)
+{
+SAL_WARN( "vcl.gtk", "GtkInstanceBuilder: error when calling 
gtk_builder_add_from_file: " << err->message);
+g_error_free(err);
+}
 assert(rc && "could not load UI file");
-(void) rc;
 
 m_pObjectList = gtk_builder_get_objects(m_pBuilder);
 g_slist_foreach(m_pObjectList, postprocess, this);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-02 Thread Julien Nabet (via logerrit)
 bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx |   11 +++
 bridges/source/cpp_uno/gcc3_linux_arm/except.cxx  |   32 ++---
 bridges/source/cpp_uno/gcc3_linux_arm/rtti.hxx|   33 --
 3 files changed, 21 insertions(+), 55 deletions(-)

New commits:
commit 610ceb05025c9c7a9a34dddcb0dac506b8eab441
Author: Julien Nabet 
AuthorDate: Sat Jan 2 15:15:38 2021 +0100
Commit: Julien Nabet 
CommitDate: Sat Jan 2 15:20:39 2021 +0100

Fix some warnings for Raspberry pi 4 (part4)

Fix similar pbs as previous commits

Change-Id: Ib2964329f75402cd5457e4bf3362076c0d4f4ea2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108572
Tested-by: Julien Nabet 
Reviewed-by: Julien Nabet 

diff --git a/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx 
b/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx
index aaba8ffb7b6d..103f2b492e3a 100644
--- a/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx
+++ b/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx
@@ -272,8 +272,7 @@ namespace
 }
 if (pReturnTypeDescr)
 {
-typelib_TypeClass eRet =
-
static_cast(pReturnTypeDescr->eTypeClass);
+typelib_TypeClass eRet = pReturnTypeDescr->eTypeClass;
 TYPELIB_DANGER_RELEASE( pReturnTypeDescr );
 return eRet;
 }
@@ -381,7 +380,7 @@ namespace
 {
 typelib_TypeDescription * pTD = nullptr;
 TYPELIB_DANGER_GET(,
-reinterpret_cast(pCallStack[2])->getTypeLibType());
+static_cast(pCallStack[2])->getTypeLibType());
 if (pTD)
 {
 XInterface * pInterface = nullptr;
@@ -393,7 +392,7 @@ namespace
 if (pInterface)
 {
 ::uno_any_construct(
-reinterpret_cast< uno_Any * >( pCallStack[0] ),
+static_cast< uno_Any * >( pCallStack[0] ),
 , pTD, cpp_acquire );
 pInterface->release();
 TYPELIB_DANGER_RELEASE( pTD );
@@ -576,8 +575,8 @@ void bridges::cpp_uno::shared::VtableFactory::flushCode(
 {
 #ifndef ANDROID
static void (*clear_cache)(unsigned char const*, unsigned char const*)
-   = (void (*)(unsigned char const*, unsigned char const*))
-   dlsym(RTLD_DEFAULT, "__clear_cache");
+   = reinterpret_cast
+   (dlsym(RTLD_DEFAULT, "__clear_cache"));
(*clear_cache)(beg, end);
 #else
cacheflush((long) beg, (long) end, 0);
diff --git a/bridges/source/cpp_uno/gcc3_linux_arm/except.cxx 
b/bridges/source/cpp_uno/gcc3_linux_arm/except.cxx
index 367604f3ed11..14bffa75ad7f 100644
--- a/bridges/source/cpp_uno/gcc3_linux_arm/except.cxx
+++ b/bridges/source/cpp_uno/gcc3_linux_arm/except.cxx
@@ -31,7 +31,6 @@
 #include 
 #include 
 #include 
-#include "rtti.hxx"
 #include "share.hxx"
 
 
@@ -86,6 +85,7 @@ namespace CPPU_CURRENT_NAMESPACE
 #endif
 }
 
+namespace {
 class RTTI
 {
 typedef std::unordered_map< OUString, type_info * > t_rtti_map;
@@ -104,10 +104,11 @@ namespace CPPU_CURRENT_NAMESPACE
 
 type_info * getRTTI(typelib_CompoundTypeDescription *);
 };
+}
 
 RTTI::RTTI()
 #ifndef ANDROID
-: m_hApp( dlopen( 0, RTLD_LAZY ) )
+: m_hApp( dlopen( nullptr, RTLD_LAZY ) )
 #endif
 {
 }
@@ -124,7 +125,7 @@ namespace CPPU_CURRENT_NAMESPACE
 {
 type_info * rtti;
 
-OUString const & unoName = *(OUString const 
*)>aBase.pTypeName;
+OUString const & unoName = *reinterpret_cast(>aBase.pTypeName);
 
 MutexGuard guard( m_mutex );
 t_rtti_map::const_iterator iFind( m_rttis.find( unoName ) );
@@ -146,7 +147,7 @@ namespace CPPU_CURRENT_NAMESPACE
 
 OString symName( buf.makeStringAndClear() );
 #ifndef ANDROID
-rtti = (type_info *)dlsym( m_hApp, symName.getStr() );
+rtti = static_cast(dlsym( m_hApp, symName.getStr() ));
 #else
 rtti = (type_info *)dlsym( RTLD_DEFAULT, symName.getStr() );
 #endif
@@ -185,10 +186,9 @@ namespace CPPU_CURRENT_NAMESPACE
 if (pTypeDescr->pBaseTypeDescription)
 {
 // ensure availability of base
-type_info * base_rtti = getRTTI(
-(typelib_CompoundTypeDescription 
*)pTypeDescr->pBaseTypeDescription );
+type_info * base_rtti = getRTTI( 
pTypeDescr->pBaseTypeDescription );
 rtti = new __si_class_type_info(
-strdup( rttiName ), (__class_type_info *)base_rtti 
);
+strdup( rttiName ), static_cast<__class_type_info 
*>(base_rtti) );
 }
 else
 {
@@ -218,8 +218,8 @@ namespace 

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

2021-01-02 Thread Julien Nabet (via logerrit)
 bridges/source/cpp_uno/gcc3_linux_arm/call.hxx|   28 ++
 bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx |   95 +++---
 bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx |   82 +-
 3 files changed, 117 insertions(+), 88 deletions(-)

New commits:
commit dd91d3389c26645459d3b80649941d65efa4f63f
Author: Julien Nabet 
AuthorDate: Sat Jan 2 14:36:44 2021 +0100
Commit: Julien Nabet 
CommitDate: Sat Jan 2 14:47:03 2021 +0100

Fix some warnings for Raspberry pi 4 (part3)

fix for these kinds of things:

/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:494:17:
 error:
C-style cast from 'sal_uInt32 *' (aka 'unsigned long *') to 'double *' 
(BitCast) [loplugin:cstylecast]
INSERT_DOUBLE( pCppArgs[nPos], nGPR, pGPR, pStack, 
pStackStart );

^~~~

/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:365:14:
 note: expanded from macro 'INSERT_DOUBLE'
*(double *)pDS = *reinterpret_cast( pSV );\
 ^

/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:645:18:
 error:
C-style cast from 'const typelib_TypeDescription *' (aka 'const 
_typelib_TypeDescription *') to 'typelib_InterfaceAttributeTypeDescription *' 
(aka '_typelib_InterfaceAttributeTypeDescription *') (BitCast) 
[loplugin:cstylecast]
((typelib_InterfaceAttributeTypeDescription 
*)pMemberDescr)->pAttributeTypeRef,
 ^

/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:655:31:
 error: use 'true' instead of 'sal_True' [loplugin:fakebool]
aParam.bIn  = sal_True;
  ^~~~

/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:656:31:
 error: use 'false' instead of 'sal_False' [loplugin:fakebool]
aParam.bOut = sal_False;


/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:112:47:
 error: NullToPointer ValueDependentIsNotNull ZeroLiteral -> nullptr 
[loplugin:nullptr]
typelib_TypeDescription * t = 0;
  ^

/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:123:40:
 error: NullToPointer ValueDependentIsNotNull ZeroLiteral -> nullptr 
[loplugin:nullptr]
if (p->pBaseTypeDescription != 0)
   ^

/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:148:52:
 error: NullToPointer ValueDependentIsNotNull ZeroLiteral -> nullptr 
[loplugin:nullptr]
typelib_TypeDescription * pTypeDescr = 0;
   ^

Change-Id: Ibca65077131277380ddeefa994b52c7c1193c1f4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108570
Tested-by: Julien Nabet 
Reviewed-by: Julien Nabet 

diff --git a/bridges/source/cpp_uno/gcc3_linux_arm/call.hxx 
b/bridges/source/cpp_uno/gcc3_linux_arm/call.hxx
new file mode 100644
index ..dde56f6f59f0
--- /dev/null
+++ b/bridges/source/cpp_uno/gcc3_linux_arm/call.hxx
@@ -0,0 +1,28 @@
+/* -*- 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 .
+ */
+
+#pragma once
+
+#include 
+
+#include 
+
+extern "C" sal_Int64 cpp_vtable_call(long* pFunctionAndOffset, void** 
pCallStack);
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx 
b/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx
index 7abaed395488..aaba8ffb7b6d 100644
--- a/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx
+++ b/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx
@@ -33,6 +33,7 @@
 #include 
 
 #include "share.hxx"
+#include "call.hxx"
 
 #include 
 
@@ -46,7 +47,7 @@ using namespace ::com::sun::star::uno;
 namespace
 {
 
-static typelib_TypeClass cpp2uno_call(
+typelib_TypeClass cpp2uno_call(
 

[Libreoffice-commits] core.git: bean/native bridges/source include/jvmaccess include/jvmfwk javaunohelper/source jurt/source jvmfwk/plugins

2021-01-02 Thread Julien Nabet (via logerrit)
 bean/native/unix/com_sun_star_comp_beans_LocalOfficeWindow.c|   10 ++
 bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx   |2 
 bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx   |   40 
+-
 include/jvmaccess/classpath.hxx |7 +
 include/jvmaccess/virtualmachine.hxx|7 +
 include/jvmfwk/framework.hxx|7 +
 javaunohelper/source/preload.cxx|7 +
 jurt/source/pipe/com_sun_star_lib_connections_pipe_PipeConnection.c |8 ++
 jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx |8 ++
 9 files changed, 78 insertions(+), 18 deletions(-)

New commits:
commit 6e3424ca1131fe371f63e456267de476b5eb0eae
Author: Julien Nabet 
AuthorDate: Sat Jan 2 11:03:12 2021 +0100
Commit: Julien Nabet 
CommitDate: Sat Jan 2 11:40:47 2021 +0100

Fix some warnings for Raspberry pi 4 (part2)

Fix these kinds:

/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:103:10:
 error:
externally available entity 'is_complex_struct' is not previously declared 
in an included file
(if it is only used in this translation unit, make it static; otherwise, 
provide a declaration of it in an included file) [loplugin:external]
bool is_complex_struct(const typelib_TypeDescription * type)
~^~~

/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:129:10:
 error:
externally available entity 'is_float_only_struct' is not previously 
declared in an included file
(if it is only used in this translation unit, make it static; otherwise, 
provide a declaration of it in an included file) [loplugin:external]
bool is_float_only_struct(const typelib_TypeDescription * type)
~^~

/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:168:6:
 error:
externally available entity 'MapReturn' is not previously declared in an 
included file
(if it is only used in this translation unit, make it static; otherwise, 
provide a declaration of it in an included file) [loplugin:external]
void MapReturn(sal_uInt32 r0, sal_uInt32 r1, 
typelib_TypeDescriptionReference * pReturnType, sal_uInt32* pRegisterReturn)


/home/pi/lo/libreoffice/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx:446:32:
 error:
static_cast from 'void **' to 'sal_Int32 *' (aka 'long *') is not allowed
sal_Int32 * pTempIndices = static_cast(pCppArgs + nParams);
   ^~~~

or some of these:
In file included from

/home/pi/lo/libreoffice/bean/native/unix/com_sun_star_comp_beans_LocalOfficeWindow.c:26:
/usr/lib/jvm/java-11-openjdk-armhf/include/jni.h:1945:1: error: unknown
attribute 'externally_visible' ignored [-Werror,-Wunknown-attributes]
_JNI_IMPORT_OR_EXPORT_ jint JNICALL
^
/usr/lib/jvm/java-11-openjdk-armhf/include/jni.h:1943:32: note: expanded
from macro '_JNI_IMPORT_OR_EXPORT_'
define _JNI_IMPORT_OR_EXPORT_ JNIIMPORT
   ^
/usr/lib/jvm/java-11-openjdk-armhf/include/linux/jni_md.h:35:42: note:
expanded from macro 'JNIIMPORT'
define JNIIMPORT
__attribute__((externally_visible,visibility("default")))

Change-Id: I7cae1c52ee10306da666c9c234b9af7248efd04e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108567
Tested-by: Julien Nabet 
Reviewed-by: Julien Nabet 

diff --git a/bean/native/unix/com_sun_star_comp_beans_LocalOfficeWindow.c 
b/bean/native/unix/com_sun_star_comp_beans_LocalOfficeWindow.c
index 069bb1ee050e..f908d8f63c90 100644
--- a/bean/native/unix/com_sun_star_comp_beans_LocalOfficeWindow.c
+++ b/bean/native/unix/com_sun_star_comp_beans_LocalOfficeWindow.c
@@ -23,10 +23,20 @@
 #include 
 #include 
 
+// to deal with gcc specific attribute "externally_visible" used in
+// /usr/lib/jvm/java-11-openjdk-armhf/include/linux/jni_md.h:35
+// via /usr/lib/jvm/java-11-openjdk-armhf/include/jni.h
+#if defined __clang__
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wunknown-attributes"
+#endif
 #include 
 
 #include 
 #include 
+#if defined __clang__
+#pragma clang diagnostic pop
+#endif
 
 #include 
 
diff --git a/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx 
b/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx
index 9a59044ba8b3..7abaed395488 100644
--- a/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx
+++ b/bridges/source/cpp_uno/gcc3_linux_arm/cpp2uno.cxx
@@ -28,7 +28,7 @@
 #include 
 
 #include 
-#include "cppinterfaceproxy.hxx"
+#include 
 #include 
 #include 
 
diff --git a/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx 
b/bridges/source/cpp_uno/gcc3_linux_arm/uno2cpp.cxx
index 

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

2021-01-04 Thread Julien Nabet (via logerrit)
 sw/source/ui/misc/titlepage.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit e7a9d06d7d9f8dcad48c55df35de10d8e1196c56
Author: Julien Nabet 
AuthorDate: Fri Dec 25 10:46:51 2020 +0100
Commit: Xisco Fauli 
CommitDate: Mon Jan 4 18:48:15 2021 +0100

tdf#139218: Title Page: fix "Reset page number", put default at 1

Change-Id: Ic3758d8eeeb1818e3be3ca5d815fa601a34e8dd9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108279
Tested-by: Jenkins
Reviewed-by: Julien Nabet 
(cherry picked from commit b905937211154b0e923312641f09629e68ed7901)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108294
Reviewed-by: Xisco Fauli 

diff --git a/sw/source/ui/misc/titlepage.cxx b/sw/source/ui/misc/titlepage.cxx
index bba63c73c264..149c8f4a8046 100644
--- a/sw/source/ui/misc/titlepage.cxx
+++ b/sw/source/ui/misc/titlepage.cxx
@@ -201,10 +201,10 @@ SwTitlePageDlg::SwTitlePageDlg(weld::Window *pParent)
 m_xDocumentStartRB->connect_toggled(aStartPageHdl);
 m_xPageStartRB->connect_toggled(aStartPageHdl);
 
+m_xRestartNumberingNF->set_value(nResetPage);
 if (bMaybeResetNumbering && nResetPage > 0)
 {
 m_xRestartNumberingCB->set_active(true);
-m_xRestartNumberingNF->set_value(nResetPage);
 }
 m_xRestartNumberingNF->set_sensitive(m_xRestartNumberingCB->get_active());
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-01-02 Thread Julien Nabet (via logerrit)
 external/python3/ExternalPackage_python3.mk |7 +++
 1 file changed, 7 insertions(+)

New commits:
commit 8aae3b37a6553d645bfc94855adbbd1859e07692
Author: Julien Nabet 
AuthorDate: Sat Jan 2 16:40:01 2021 +0100
Commit: Julien Nabet 
CommitDate: Sat Jan 2 22:09:52 2021 +0100

Fix build error in Python3 for Raspberry pi4b

/home/pi/lo/libreoffice/external/python3/ExternalPackage_python3.mk:48:
*** file 
/home/pi/lo/libreoffice/workdir/UnpackedTarball/python3/LO_lib/_sysconfigdata__linux_armv7l-unknown-linux-gnueabihf.py
does not exist in the tarball. Arrêt.

Change-Id: If348c9f55883c1afcc37ff38e84361786bef1845
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108595
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/external/python3/ExternalPackage_python3.mk 
b/external/python3/ExternalPackage_python3.mk
index 5f1fd5ae70ea..8448d24db3b0 100644
--- a/external/python3/ExternalPackage_python3.mk
+++ b/external/python3/ExternalPackage_python3.mk
@@ -140,10 +140,17 @@ endif
 # note: python configure overrides config.guess with something that doesn't
 # put -pc in its linux platform triplets, so filter that...
 ifneq ($(OS),WNT)
+ifeq ($(CPUNAME),ARM)
+$(eval $(call 
gb_ExternalPackage_add_files,python3,$(LIBO_BIN_FOLDER)/python-core-$(PYTHON_VERSION)/lib,\
+   LO_lib/_sysconfigdata_$(if 
$(ENABLE_DBGUTIL),d)_$(python3_MACHDEP)_$(subst i686,i386,$(subst 
v7l-unknown,,$(HOST_PLATFORM))).py \
+))
+else
 $(eval $(call 
gb_ExternalPackage_add_files,python3,$(LIBO_BIN_FOLDER)/python-core-$(PYTHON_VERSION)/lib,\
LO_lib/_sysconfigdata_$(if 
$(ENABLE_DBGUTIL),d)_$(python3_MACHDEP)_$(subst i686,i386,$(subst 
-pc,,$(HOST_PLATFORM))).py \
 ))
 endif
+endif
+
 
 # packages not shipped:
 # dbm, sqlite3 - need some database stuff
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-29 Thread Julien Nabet (via logerrit)
 vcl/source/window/window.cxx |   26 --
 1 file changed, 16 insertions(+), 10 deletions(-)

New commits:
commit c0eee433e079d8e3413f4691607e075b99af92b0
Author: Julien Nabet 
AuthorDate: Tue Dec 29 10:45:50 2020 +0100
Commit: Julien Nabet 
CommitDate: Tue Dec 29 23:28:48 2020 +0100

Expand macro COMPAT_BODY in vcl

Change-Id: I598ba7a6f8c51958d8130448529d21073004aad6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108448
Tested-by: Julien Nabet 
Reviewed-by: Julien Nabet 

diff --git a/vcl/source/window/window.cxx b/vcl/source/window/window.cxx
index cc3899e8fa4d..81dbbf63670c 100644
--- a/vcl/source/window/window.cxx
+++ b/vcl/source/window/window.cxx
@@ -3900,30 +3900,36 @@ void Window::RequestDoubleBuffering(bool bRequest)
  * dispose and this altered a lot of code paths, that
  * are better left unchanged for now.
  */
-#define COMPAT_BODY(method,args) \
-if (!mpWindowImpl || mpWindowImpl->mbInDispose) \
-Window::method args; \
-else \
-method args;
-
 void Window::CompatGetFocus()
 {
-COMPAT_BODY(GetFocus,())
+if (!mpWindowImpl || mpWindowImpl->mbInDispose)
+Window::GetFocus();
+else
+GetFocus();
 }
 
 void Window::CompatLoseFocus()
 {
-COMPAT_BODY(LoseFocus,())
+if (!mpWindowImpl || mpWindowImpl->mbInDispose)
+Window::LoseFocus();
+else
+LoseFocus();
 }
 
 void Window::CompatStateChanged( StateChangedType nStateChange )
 {
-COMPAT_BODY(StateChanged,(nStateChange))
+if (!mpWindowImpl || mpWindowImpl->mbInDispose)
+Window::StateChanged(nStateChange);
+else
+StateChanged(nStateChange);
 }
 
 void Window::CompatDataChanged( const DataChangedEvent& rDCEvt )
 {
-COMPAT_BODY(DataChanged,(rDCEvt))
+if (!mpWindowImpl || mpWindowImpl->mbInDispose)
+Window::DataChanged(rDCEvt);
+else
+DataChanged(rDCEvt);
 }
 
 bool Window::CompatPreNotify( NotifyEvent& rNEvt )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: basegfx/test chart2/source connectivity/source sc/source sdext/source

2021-06-11 Thread Julien Nabet (via logerrit)
 basegfx/test/basegfxtools.cxx  |9 ---
 chart2/source/tools/InternalData.cxx   |4 -
 chart2/source/tools/InternalDataProvider.cxx   |4 -
 connectivity/source/drivers/postgresql/pq_databasemetadata.cxx |4 -
 sc/source/core/data/column3.cxx|4 -
 sc/source/filter/excel/xestream.cxx|   24 +---
 sdext/source/presenter/PresenterScreen.cxx |   28 
+-
 sdext/source/presenter/PresenterTheme.cxx  |   17 ++
 8 files changed, 43 insertions(+), 51 deletions(-)

New commits:
commit b49fce18d0b05a8b5f462ba9bf6c84f0bb107d93
Author: Julien Nabet 
AuthorDate: Fri Jun 11 15:44:56 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 11 18:12:48 2021 +0200

Simplify vector initializations

Change-Id: Icf8972be204799e9b3b3824ab18d8584911fe1c4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117061
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/basegfx/test/basegfxtools.cxx b/basegfx/test/basegfxtools.cxx
index a768357c13a5..9c6075919333 100644
--- a/basegfx/test/basegfxtools.cxx
+++ b/basegfx/test/basegfxtools.cxx
@@ -32,14 +32,7 @@ class KeyStopLerpTest : public CppUnit::TestFixture
 {
 utils::KeyStopLerp maKeyStops;
 
-static std::vector getTestVector()
-{
-std::vector aStops(3);
-aStops[0] = 0.1;
-aStops[1] = 0.5;
-aStops[2] = 0.9;
-return aStops;
-}
+static std::vector getTestVector() { return { 0.1, 0.5, 0.9 }; }
 
 public:
 KeyStopLerpTest()
diff --git a/chart2/source/tools/InternalData.cxx 
b/chart2/source/tools/InternalData.cxx
index c5f9490f01f7..35c615fe2873 100644
--- a/chart2/source/tools/InternalData.cxx
+++ b/chart2/source/tools/InternalData.cxx
@@ -56,9 +56,7 @@ struct lcl_NumberedStringGenerator
 }
 vector< uno::Any > operator()()
 {
-vector< uno::Any > aRet(1);
-aRet[0] <<= m_aStub.replaceAt( m_nStubStartIndex, m_nWildcardLength, 
OUString::number( ++m_nCounter ));
-return aRet;
+return { uno::Any(m_aStub.replaceAt( m_nStubStartIndex, 
m_nWildcardLength, OUString::number( ++m_nCounter ))) };
 }
 private:
 OUString m_aStub;
diff --git a/chart2/source/tools/InternalDataProvider.cxx 
b/chart2/source/tools/InternalDataProvider.cxx
index 9595cf2375d7..e9beeb6d1d41 100644
--- a/chart2/source/tools/InternalDataProvider.cxx
+++ b/chart2/source/tools/InternalDataProvider.cxx
@@ -369,9 +369,7 @@ InternalDataProvider::InternalDataProvider(
 aNewCategories.reserve( nLength );
 for( sal_Int32 nN=0; nN aVector(1);
-aVector[0] <<= aSimplecategories[nN];
-aNewCategories.push_back( aVector );
+aNewCategories.push_back( { 
uno::Any(aSimplecategories[nN]) } );
 }
 }
 }
diff --git a/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx 
b/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx
index 07e0e85815c1..8f2021608830 100644
--- a/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx
+++ b/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx
@@ -1251,9 +1251,7 @@ css::uno::Reference< XResultSet > 
DatabaseMetaData::getSchemas(  )
 std::vector< std::vector > vec;
 while( rs->next() )
 {
-std::vector row(1);
-row[0] <<= xRow->getString(1);
-vec.push_back( row );
+vec.push_back( { Any(xRow->getString(1)) } );
 }
 
 // sort public first, sort internal schemas last, sort rest in alphabetic 
order
diff --git a/sc/source/core/data/column3.cxx b/sc/source/core/data/column3.cxx
index 365cba4d8489..73a2ed613548 100644
--- a/sc/source/core/data/column3.cxx
+++ b/sc/source/core/data/column3.cxx
@@ -723,9 +723,7 @@ void ScColumn::AttachNewFormulaCells( const 
sc::CellStoreType::position_type& aP
 {
 // Merge into one span.
 // The original two spans are ordered from top to bottom.
-std::vector aRows(2);
-aRows[0] = std::min( rNewSharedRows[0], nTopRow);
-aRows[1] = std::max( rNewSharedRows[3], nBotRow);
+std::vector aRows { std::min( rNewSharedRows[0], nTopRow), 
std::max( rNewSharedRows[3], nBotRow) };
 rNewSharedRows.swap( aRows);
 }
 else
diff --git a/sc/source/filter/excel/xestream.cxx 
b/sc/source/filter/excel/xestream.cxx
index 6c79d99469f1..ac63d34414b5 100644
--- a/sc/source/filter/excel/xestream.cxx
+++ b/sc/source/filter/excel/xestream.cxx
@@ -22,6 +22,7 @@
 #include 
 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -490,26 +491,29 @@ void XclExpBiff8Encrypter::GetDocId( sal_uInt8 
pnDocId[16] ) const
 
 void XclExpBiff8Encrypter::Encrypt( SvStream& rStrm, sal_uInt8 

[Libreoffice-commits] core.git: dbaccess/source filter/source fpicker/source sfx2/source sot/source svtools/source

2021-06-11 Thread Julien Nabet (via logerrit)
 dbaccess/source/core/dataaccess/datasource.cxx |4 +---
 filter/source/t602/t602filter.cxx  |   12 +++-
 fpicker/source/win32/VistaFilePicker.cxx   |4 +---
 sfx2/source/appl/appopen.cxx   |5 +
 sfx2/source/doc/sfxbasemodel.cxx   |4 +---
 sot/source/sdstor/ucbstorage.cxx   |6 +-
 svtools/source/config/extcolorcfg.cxx  |4 +---
 7 files changed, 13 insertions(+), 26 deletions(-)

New commits:
commit c384c7d7ae39495a9cfd55c3d610133f97db1304
Author: Julien Nabet 
AuthorDate: Fri Jun 11 16:02:26 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 11 18:55:00 2021 +0200

Simplify Sequence/vector initializations

Change-Id: Ib02e25b4600666185cf0f8d0cc8d5c64186789c5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117064
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/dbaccess/source/core/dataaccess/datasource.cxx 
b/dbaccess/source/core/dataaccess/datasource.cxx
index 9ce895bae875..83a45afa3e2d 100644
--- a/dbaccess/source/core/dataaccess/datasource.cxx
+++ b/dbaccess/source/core/dataaccess/datasource.cxx
@@ -240,10 +240,8 @@ void SAL_CALL OAuthenticationContinuation::setAccount( 
const OUString& )
 
 Sequence< RememberAuthentication > SAL_CALL 
OAuthenticationContinuation::getRememberAccountModes( RememberAuthentication& 
_reDefault )
 {
-Sequence < RememberAuthentication > aReturn(1);
-aReturn[0] = RememberAuthentication_NO;
 _reDefault = RememberAuthentication_NO;
-return aReturn;
+return { RememberAuthentication_NO };
 }
 
 void SAL_CALL OAuthenticationContinuation::setRememberAccount( 
RememberAuthentication /*Remember*/ )
diff --git a/filter/source/t602/t602filter.cxx 
b/filter/source/t602/t602filter.cxx
index 9f96f18c1a96..f71d1c681af6 100644
--- a/filter/source/t602/t602filter.cxx
+++ b/filter/source/t602/t602filter.cxx
@@ -950,11 +950,13 @@ bool T602ImportFilterDialog::OptionsDlg()
 propBool_(xPSetCodeLB,"Dropdown",true);
 propBool_(xPSetCodeLB,"MultiSelection",false);
 
-Sequence< OUString > ous(4);
-ous[0] = getResStr(T602FILTER_STR_ENCODING_AUTO);
-ous[1] = getResStr(T602FILTER_STR_ENCODING_CP852);
-ous[2] = getResStr(T602FILTER_STR_ENCODING_CP895);
-ous[3] = getResStr(T602FILTER_STR_ENCODING_KOI8CS2);
+Sequence< OUString > ous
+{
+getResStr(T602FILTER_STR_ENCODING_AUTO),
+getResStr(T602FILTER_STR_ENCODING_CP852),
+getResStr(T602FILTER_STR_ENCODING_CP895),
+getResStr(T602FILTER_STR_ENCODING_KOI8CS2)
+};
 any <<= ous;
 xPSetCodeLB->setPropertyValue("StringItemList", any);
 
diff --git a/fpicker/source/win32/VistaFilePicker.cxx 
b/fpicker/source/win32/VistaFilePicker.cxx
index 367f938dd3a6..0c360f1bc33d 100644
--- a/fpicker/source/win32/VistaFilePicker.cxx
+++ b/fpicker/source/win32/VistaFilePicker.cxx
@@ -210,9 +210,7 @@ void VistaFilePicker::ensureInit()
 }
 else
 {
-css::uno::Sequence < css::uno::Any > aInitArguments(1);
-aInitArguments[0] <<= 
css::ui::dialogs::TemplateDescription::FILEOPEN_SIMPLE;
-initialize(aInitArguments);
+initialize( { 
css::uno::Any(css::ui::dialogs::TemplateDescription::FILEOPEN_SIMPLE) });
 }
 }
 }
diff --git a/sfx2/source/appl/appopen.cxx b/sfx2/source/appl/appopen.cxx
index 03a94e0811b1..08431c29eaaa 100644
--- a/sfx2/source/appl/appopen.cxx
+++ b/sfx2/source/appl/appopen.cxx
@@ -866,11 +866,8 @@ void SfxApplication::OpenDocExec_Impl( SfxRequest& rReq )
 else
 {
 // check for "internal" protocols that should not be 
forwarded to the system
-std::vector < OUString > aProtocols(2);
-
 // add special protocols that always should be treated as 
internal
-aProtocols[0] = "private:*";
-aProtocols[1] = "vnd.sun.star.*";
+std::vector < OUString > aProtocols { "private:*", 
"vnd.sun.star.*" };
 
 // get registered protocol handlers from configuration
 Reference < XNameAccess > 
xAccess(officecfg::Office::ProtocolHandler::HandlerSet::get());
diff --git a/sfx2/source/doc/sfxbasemodel.cxx b/sfx2/source/doc/sfxbasemodel.cxx
index 35e4bd106635..c95c068463cd 100644
--- a/sfx2/source/doc/sfxbasemodel.cxx
+++ b/sfx2/source/doc/sfxbasemodel.cxx
@@ -3876,9 +3876,7 @@ void SfxBaseModel::impl_getPrintHelper()
 return;
 m_pData->m_xPrintable = new SfxPrintHelper();
 Reference < lang::XInitialization > xInit( m_pData->m_xPrintable, 
UNO_QUERY );
-Sequence < Any > aValues(1);
-aValues[0] <<= Reference < frame::XModel > (static_cast< frame::XModel* 
>(this), UNO_QUERY );
-xInit->initialize( aValues );
+xInit->initialize( { Any(Reference < frame::XModel > (static_cast< 
frame::XModel* >(this), UNO_QUERY )) } );
 Reference < 

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

2021-06-11 Thread Julien Nabet (via logerrit)
 vbahelper/source/msforms/vbalistbox.cxx  |3 +--
 vbahelper/source/vbahelper/vbadialogbase.cxx |3 +--
 vbahelper/source/vbahelper/vbashape.cxx  |   10 ++
 vbahelper/source/vbahelper/vbashapes.cxx |3 +--
 4 files changed, 5 insertions(+), 14 deletions(-)

New commits:
commit 92889bc98f4e822715874cb80346d8370e9da8e6
Author: Julien Nabet 
AuthorDate: Fri Jun 11 13:00:59 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 11 16:02:57 2021 +0200

Simplify Sequences initializations (vbahelper)

Change-Id: I9bbcf97acd59e7430758e05ae949f7e494afc704
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117051
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/vbahelper/source/msforms/vbalistbox.cxx 
b/vbahelper/source/msforms/vbalistbox.cxx
index 8c2ea52332db..9dcef8a77225 100644
--- a/vbahelper/source/msforms/vbalistbox.cxx
+++ b/vbahelper/source/msforms/vbalistbox.cxx
@@ -81,10 +81,9 @@ ScVbaListBox::setValue( const uno::Any& _value )
 if( nValue == -1 )
 throw uno::RuntimeException( "Attribute use invalid." );
 
-uno::Sequence< sal_Int16 > nSelectedIndices(1);
+uno::Sequence< sal_Int16 > nSelectedIndices { nValue };
 uno::Sequence< sal_Int16 > nOldSelectedIndices;
 m_xProps->getPropertyValue( "SelectedItems" ) >>= nOldSelectedIndices;
-nSelectedIndices[ 0 ] = nValue;
 m_xProps->setPropertyValue( "SelectedItems", uno::makeAny( 
nSelectedIndices ) );
 if ( nSelectedIndices != nOldSelectedIndices )
 fireClickEvent();
diff --git a/vbahelper/source/vbahelper/vbadialogbase.cxx 
b/vbahelper/source/vbahelper/vbadialogbase.cxx
index a1aa0b053436..9b9087bd264d 100644
--- a/vbahelper/source/vbahelper/vbadialogbase.cxx
+++ b/vbahelper/source/vbahelper/vbadialogbase.cxx
@@ -31,8 +31,7 @@ void SAL_CALL VbaDialogBase::Show()
 if (aURL.isEmpty())
 throw uno::RuntimeException("Unable to open the specified dialog");
 
-uno::Sequence dispatchProps(0);
-dispatchRequests(m_xModel, aURL, dispatchProps);
+dispatchRequests(m_xModel, aURL, {});
 }
 }
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vbahelper/source/vbahelper/vbashape.cxx 
b/vbahelper/source/vbahelper/vbashape.cxx
index 8f16865eff8c..67998de7f6f3 100644
--- a/vbahelper/source/vbahelper/vbashape.cxx
+++ b/vbahelper/source/vbahelper/vbashape.cxx
@@ -389,10 +389,7 @@ ScVbaShape::TextFrame()
 if( xServiceInfo->supportsService( 
"com.sun.star.sheet.SpreadsheetDocument" ) )
 {
 uno::Reference< uno::XComponentContext > xContext = 
comphelper::getProcessComponentContext();
-uno::Sequence< uno::Any > aArgs(2);
-aArgs[0] <<= getParent();
-aArgs[1] <<= m_xShape;
-uno::Reference< uno::XInterface > xTextFrame = 
xContext->getServiceManager()->createInstanceWithArgumentsAndContext( 
"ooo.vba.excel.TextFrame" , aArgs, xContext );
+uno::Reference< uno::XInterface > xTextFrame = 
xContext->getServiceManager()->createInstanceWithArgumentsAndContext( 
"ooo.vba.excel.TextFrame" , { uno::Any(getParent()), uno::Any(m_xShape) }, 
xContext );
 return uno::makeAny( xTextFrame );
 }
 
@@ -726,10 +723,7 @@ ScVbaShape::WrapFormat()
 if( xServiceInfo->supportsService( "com.sun.star.text.TextDocument" ))
 {
 uno::Reference< uno::XComponentContext > xContext = 
comphelper::getProcessComponentContext();
-uno::Sequence< uno::Any > aArgs(2);
-aArgs[0] <<= getParent();
-aArgs[1] <<= m_xShape;
-uno::Reference< uno::XInterface > xWrapFormat = 
xContext->getServiceManager()->createInstanceWithArgumentsAndContext( 
"ooo.vba.word.WrapFormat" , aArgs, xContext );
+uno::Reference< uno::XInterface > xWrapFormat = 
xContext->getServiceManager()->createInstanceWithArgumentsAndContext( 
"ooo.vba.word.WrapFormat" ,{ uno::Any(getParent()), uno::Any(m_xShape) }, 
xContext );
 return uno::makeAny( xWrapFormat );
 }
 throw uno::RuntimeException( "Not implemented" );
diff --git a/vbahelper/source/vbahelper/vbashapes.cxx 
b/vbahelper/source/vbahelper/vbashapes.cxx
index c14f81791f95..552365da3861 100644
--- a/vbahelper/source/vbahelper/vbashapes.cxx
+++ b/vbahelper/source/vbahelper/vbashapes.cxx
@@ -180,8 +180,7 @@ ScVbaShapes::Range( const uno::Any& shapes )
 else
 {
 // wrap single index into a sequence
-uno::Sequence< uno::Any > sIndices(1);
-sIndices[ 0 ] = shapes;
+uno::Sequence< uno::Any > sIndices { shapes };
 uno::Any aIndex;
 aIndex <<= sIndices;
 xShapes = getShapesByArrayIndices( aIndex );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: writerfilter/source writerperfect/source xmlhelp/source xmloff/source xmlscript/source xmlsecurity/source

2021-06-11 Thread Julien Nabet (via logerrit)
 writerfilter/source/dmapper/SettingsTable.cxx  |3 --
 writerperfect/source/common/WPXSvInputStream.cxx   |5 
 xmlhelp/source/cxxhelp/provider/resultsetbase.cxx  |   15 
 xmloff/source/chart/SchXMLSeriesHelper.cxx |9 +--
 xmloff/source/core/DomBuilderContext.cxx   |   10 +---
 xmloff/source/core/xmlexp.cxx  |3 --
 xmloff/source/draw/XMLImageMapContext.cxx  |3 --
 xmloff/source/draw/sdxmlimp.cxx|3 --
 xmloff/source/draw/ximpshap.cxx|4 ---
 xmloff/source/draw/ximpstyl.cxx|6 +---
 xmloff/source/meta/xmlmetai.cxx|4 ---
 xmloff/source/script/XMLEventImportHelper.cxx  |7 -
 xmloff/source/style/prstylei.cxx   |6 
 xmloff/source/style/xmlbahdl.cxx   |   10 
 xmloff/source/text/XMLSectionSourceDDEImportContext.cxx|   16 +
 xmlscript/source/xmldlg_imexp/xmldlg_import.cxx|   10 +---
 xmlsecurity/source/component/documentdigitalsignatures.cxx |4 +--
 17 files changed, 32 insertions(+), 86 deletions(-)

New commits:
commit 57796f2724f004679f78eb144a93b9a03968317c
Author: Julien Nabet 
AuthorDate: Fri Jun 11 14:52:29 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 11 16:03:10 2021 +0200

Simplify Sequences initializations (writerfilter/writerperfect/x*)

Change-Id: I1bd31fe6cf0f8aaf4f2cfe1d3d49e61a0633f361
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117057
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/writerfilter/source/dmapper/SettingsTable.cxx 
b/writerfilter/source/dmapper/SettingsTable.cxx
index 12ec66a54152..47a2d7269efd 100644
--- a/writerfilter/source/dmapper/SettingsTable.cxx
+++ b/writerfilter/source/dmapper/SettingsTable.cxx
@@ -777,8 +777,7 @@ void 
SettingsTable::ApplyProperties(uno::Reference const& x
 {
 // use dummy protection key to forbid disabling of Record changes 
without a notice
 // (extending the recent GrabBag support)TODO support password 
verification...
-css::uno::Sequence aDummyKey(1);
-aDummyKey[0] = 1;
+css::uno::Sequence aDummyKey { 1 };
 xDocProps->setPropertyValue("RedlineProtectionKey", uno::makeAny( 
aDummyKey ));
 }
 }
diff --git a/writerperfect/source/common/WPXSvInputStream.cxx 
b/writerperfect/source/common/WPXSvInputStream.cxx
index 9f7ea9caecf1..22d7dc8d3950 100644
--- a/writerperfect/source/common/WPXSvInputStream.cxx
+++ b/writerperfect/source/common/WPXSvInputStream.cxx
@@ -776,14 +776,11 @@ bool WPXSvInputStreamImpl::isZip()
 
 try
 {
-Sequence aArgs(1);
-aArgs[0] <<= mxStream;
-
 const Reference 
xContext(comphelper::getProcessComponentContext(),
 UNO_SET_THROW);
 const Reference xZip(
 
xContext->getServiceManager()->createInstanceWithArgumentsAndContext(
-"com.sun.star.packages.zip.ZipFileAccess", aArgs, 
xContext),
+"com.sun.star.packages.zip.ZipFileAccess", { Any(mxStream) 
}, xContext),
 UNO_QUERY_THROW);
 mpZipStorage.reset(new ZipStorageImpl(xZip));
 }
diff --git a/xmlhelp/source/cxxhelp/provider/resultsetbase.cxx 
b/xmlhelp/source/cxxhelp/provider/resultsetbase.cxx
index 90c928bbc789..ddb982985c65 100644
--- a/xmlhelp/source/cxxhelp/provider/resultsetbase.cxx
+++ b/xmlhelp/source/cxxhelp/provider/resultsetbase.cxx
@@ -392,16 +392,11 @@ private:
 uno::Reference< beans::XPropertySetInfo > SAL_CALL
 ResultSetBase::getPropertySetInfo()
 {
-uno::Sequence< beans::Property > seq(2);
-seq[0].Name = "RowCount";
-seq[0].Handle = -1;
-seq[0].Type = cppu::UnoType::get();
-seq[0].Attributes = beans::PropertyAttribute::READONLY;
-
-seq[1].Name = "IsRowCountFinal";
-seq[1].Handle = -1;
-seq[1].Type = cppu::UnoType::get();
-seq[1].Attributes = beans::PropertyAttribute::READONLY;
+uno::Sequence< beans::Property > seq
+{
+{ "RowCount", -1, cppu::UnoType::get(), 
beans::PropertyAttribute::READONLY },
+{ "IsRowCountFinal", -1, cppu::UnoType::get(), 
beans::PropertyAttribute::READONLY }
+};
 
 //t
 return uno::Reference< beans::XPropertySetInfo > ( new 
XPropertySetInfoImpl( seq ) );
diff --git a/xmloff/source/chart/SchXMLSeriesHelper.cxx 
b/xmloff/source/chart/SchXMLSeriesHelper.cxx
index 380830b40fc6..9bccc3f83950 100644
--- a/xmloff/source/chart/SchXMLSeriesHelper.cxx
+++ b/xmloff/source/chart/SchXMLSeriesHelper.cxx
@@ -170,9 +170,7 @@ uno::Reference< beans::XPropertySet > 
SchXMLSeriesHelper::createOldAPISeriesProp
 Reference< 

[Libreoffice-commits] core.git: Branch 'libreoffice-7-2' - sw/UIConfig_swriter.mk

2021-06-16 Thread Julien Nabet (via logerrit)
 sw/UIConfig_swriter.mk |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 9656cc894673af9db77a29376a94d3029370d127
Author: Julien Nabet 
AuthorDate: Tue Jun 15 20:42:19 2021 +0200
Commit: Xisco Fauli 
CommitDate: Wed Jun 16 09:28:56 2021 +0200

tdf#142860: fix crash: press Page Columns Button on Tab UI

See bt here:
https://bugs.documentfoundation.org/attachment.cgi?id=172924

Change-Id: I477ad78e943934d83cf48620f5ed2573558901e9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117268
Tested-by: Jenkins
Reviewed-by: Julien Nabet 
(cherry picked from commit b89ebf135818ccaa45bbfb164099a6e199bd7d11)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117228
Reviewed-by: Xisco Fauli 

diff --git a/sw/UIConfig_swriter.mk b/sw/UIConfig_swriter.mk
index b0b94c9979ff..ce3058308d6e 100644
--- a/sw/UIConfig_swriter.mk
+++ b/sw/UIConfig_swriter.mk
@@ -236,6 +236,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/swriter,\
sw/uiconfig/swriter/ui/notebookbar_groupedbar_full \
sw/uiconfig/swriter/ui/notebookbar_groupedbar_compact \
sw/uiconfig/swriter/ui/notebookbar_online \
+   sw/uiconfig/swriter/ui/pagecolumncontrol \
sw/uiconfig/swriter/ui/pagemargincontrol \
sw/uiconfig/swriter/ui/pageorientationcontrol \
sw/uiconfig/swriter/ui/pagesizecontrol \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-14 Thread Julien Nabet (via logerrit)
 sd/source/ui/app/optsitem.cxx |4 ++--
 sd/source/ui/inc/optsitem.hxx |   12 ++--
 2 files changed, 8 insertions(+), 8 deletions(-)

New commits:
commit bc63b8a94d95cf86da142bfd4f8d0a6b3ba3d83f
Author: Julien Nabet 
AuthorDate: Sun Jun 13 15:06:08 2021 +0200
Commit: Julien Nabet 
CommitDate: Mon Jun 14 21:42:16 2021 +0200

Fix Exception from PutProperties in unotools

Launch Impress, click on "Animation" icon and check/uncheck "Automatic 
Preview" checkbox (at bottom right)
Close Impress and notice this twice:
warn:unotools.config:9155:9155:unotools/source/config/configitem.cxx:487:
Exception from PutProperties com.sun.star.lang.IllegalArgumentException 
message:
configmgr inappropriate property value 
/home/julien/lo/libreoffice/configmgr/source/access.cxx:1497 ArgumentPosition: 
-1

Investigating a bit, I noticed:
officecfg/registry/schema/org/openoffice/Office/Impress.xcs
673 
680 

officecfg/registry/schema/org/openoffice/Office/Draw.xcs
429 
436 

sd/source/ui/app/optsitem.cxx:479:"DefaultObjectSize/Width",
sd/source/ui/app/optsitem.cxx:480:"DefaultObjectSize/Height",

Change-Id: I608b882cdff03e464fdb9886d5ba28dd33bfe229
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117095
Reviewed-by: Noel Grandin 
Reviewed-by: Julien Nabet 
Tested-by: Julien Nabet 

diff --git a/sd/source/ui/app/optsitem.cxx b/sd/source/ui/app/optsitem.cxx
index 9b628aa0d6c5..47a92c21df90 100644
--- a/sd/source/ui/app/optsitem.cxx
+++ b/sd/source/ui/app/optsitem.cxx
@@ -517,8 +517,8 @@ bool SdOptionsMisc::ReadData( const Any* pValues )
 if( pValues[6].hasValue() ) SetDoubleClickTextEdit( 
*o3tl::doAccess(pValues[ 6 ]) );
 if( pValues[7].hasValue() ) SetClickChangeRotation( 
*o3tl::doAccess(pValues[ 7 ]) );
 if( pValues[9].hasValue() ) SetSolidDragging( 
*o3tl::doAccess(pValues[ 9 ]) );
-if( pValues[10].hasValue() ) SetDefaultObjectSizeWidth( 
*o3tl::doAccess(pValues[ 10 ]) );
-if( pValues[11].hasValue() ) SetDefaultObjectSizeHeight( 
*o3tl::doAccess(pValues[ 11 ]) );
+if( pValues[10].hasValue() ) SetDefaultObjectSizeWidth( 
*o3tl::doAccess(pValues[ 10 ]) );
+if( pValues[11].hasValue() ) SetDefaultObjectSizeHeight( 
*o3tl::doAccess(pValues[ 11 ]) );
 if( pValues[12].hasValue() ) SetPrinterIndependentLayout( 
*o3tl::doAccess(pValues[ 12 ]) );
 
 if( pValues[13].hasValue() )
diff --git a/sd/source/ui/inc/optsitem.hxx b/sd/source/ui/inc/optsitem.hxx
index 011e45ba2142..979b90b78425 100644
--- a/sd/source/ui/inc/optsitem.hxx
+++ b/sd/source/ui/inc/optsitem.hxx
@@ -182,8 +182,8 @@ class SD_DLLPUBLIC SdOptionsMisc : public SdOptionsGeneric
 {
 private:
 
-sal_uLong   nDefaultObjectSizeWidth;
-sal_uLong   nDefaultObjectSizeHeight;
+sal_Int32   nDefaultObjectSizeWidth;
+sal_Int32   nDefaultObjectSizeHeight;
 
 boolbStartWithTemplate  : 1;// Misc/NewDoc/AutoPilot
 boolbMarkedHitMovesAlways   : 1;// Misc/ObjectMoveable
@@ -259,8 +259,8 @@ public:
 sal_uInt16  GetPrinterIndependentLayout() const { Init(); return 
mnPrinterIndependentLayout; };
 boolIsShowUndoDeleteWarning() const { Init(); return 
bShowUndoDeleteWarning; }
 boolIsSlideshowRespectZOrder() const { Init(); return 
bSlideshowRespectZOrder; }
-sal_uLong   GetDefaultObjectSizeWidth() const { Init(); return 
nDefaultObjectSizeWidth; }
-sal_uLong   GetDefaultObjectSizeHeight() const { Init(); return 
nDefaultObjectSizeHeight; }
+sal_Int32   GetDefaultObjectSizeWidth() const { Init(); return 
nDefaultObjectSizeWidth; }
+sal_Int32   GetDefaultObjectSizeHeight() const { Init(); return 
nDefaultObjectSizeHeight; }
 
 boolIsPreviewNewEffects() const { Init(); return bPreviewNewEffects; }
 boolIsPreviewChangedEffects() const { Init(); return 
bPreviewChangedEffects; }
@@ -299,8 +299,8 @@ public:
 voidSetSolidDragging( bool bOn ) { if( bSolidDragging != bOn ) { 
OptionsChanged(); bSolidDragging = bOn; } }
 voidSetShowUndoDeleteWarning( bool bOn ) { if( bShowUndoDeleteWarning 
!= bOn ) { OptionsChanged(); bShowUndoDeleteWarning = bOn; } }
 voidSetSlideshowRespectZOrder( bool bOn ) { if( 
bSlideshowRespectZOrder != bOn ) { OptionsChanged(); bSlideshowRespectZOrder = 
bOn; } }
-voidSetDefaultObjectSizeWidth( sal_uLong nWidth ) { if( 
nDefaultObjectSizeWidth != nWidth ) { OptionsChanged(); nDefaultObjectSizeWidth 
= nWidth; } }
-voidSetDefaultObjectSizeHeight( sal_uLong nHeight ) { if( 
nDefaultObjectSizeHeight != nHeight ) { OptionsChanged(); 
nDefaultObjectSizeHeight = nHeight; } }
+voidSetDefaultObjectSizeWidth( sal_Int32 nWidth ) { if( 
nDefaultObjectSizeWidth != nWidth ) { OptionsChanged(); nDefaultObjectSizeWidth 
= nWidth; } }
+voidSetDefaultObjectSizeHeight( sal_Int32 nHeight ) { if( 
nDefaultObjectSizeHeight != 

[Libreoffice-commits] core.git: sw/UIConfig_swriter.mk

2021-06-15 Thread Julien Nabet (via logerrit)
 sw/UIConfig_swriter.mk |1 +
 1 file changed, 1 insertion(+)

New commits:
commit b89ebf135818ccaa45bbfb164099a6e199bd7d11
Author: Julien Nabet 
AuthorDate: Tue Jun 15 20:42:19 2021 +0200
Commit: Julien Nabet 
CommitDate: Tue Jun 15 21:49:03 2021 +0200

tdf#142860: fix crash: press Page Columns Button on Tab UI

See bt here:
https://bugs.documentfoundation.org/attachment.cgi?id=172924

Change-Id: I477ad78e943934d83cf48620f5ed2573558901e9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117268
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sw/UIConfig_swriter.mk b/sw/UIConfig_swriter.mk
index b0b94c9979ff..ce3058308d6e 100644
--- a/sw/UIConfig_swriter.mk
+++ b/sw/UIConfig_swriter.mk
@@ -236,6 +236,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/swriter,\
sw/uiconfig/swriter/ui/notebookbar_groupedbar_full \
sw/uiconfig/swriter/ui/notebookbar_groupedbar_compact \
sw/uiconfig/swriter/ui/notebookbar_online \
+   sw/uiconfig/swriter/ui/pagecolumncontrol \
sw/uiconfig/swriter/ui/pagemargincontrol \
sw/uiconfig/swriter/ui/pageorientationcontrol \
sw/uiconfig/swriter/ui/pagesizecontrol \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-08 Thread Julien Nabet (via logerrit)
 reportdesign/source/core/api/ReportDefinition.cxx |   13 ++---
 reportdesign/source/core/api/Shape.cxx|6 +-
 reportdesign/source/ui/inspection/DataProviderHandler.cxx |3 +--
 reportdesign/source/ui/inspection/GeometryHandler.cxx |   14 --
 4 files changed, 12 insertions(+), 24 deletions(-)

New commits:
commit bd536744ec947090819d59e0f0ec9f2c454aa428
Author: Julien Nabet 
AuthorDate: Tue Jun 8 22:00:41 2021 +0200
Commit: Julien Nabet 
CommitDate: Wed Jun 9 07:43:32 2021 +0200

Simplify Sequences initializations (reportdesign)

Change-Id: I06f2675ee1270f04c6107761fbfc26a5570cc9c7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116866
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/reportdesign/source/core/api/ReportDefinition.cxx 
b/reportdesign/source/core/api/ReportDefinition.cxx
index 2fda942e438b..fd6bf1bb56c1 100644
--- a/reportdesign/source/core/api/ReportDefinition.cxx
+++ b/reportdesign/source/core/api/ReportDefinition.cxx
@@ -1926,10 +1926,7 @@ void SAL_CALL OReportDefinition::setMimeType( const 
OUString& _mimetype )
 
 uno::Sequence< OUString > SAL_CALL OReportDefinition::getAvailableMimeTypes(  )
 {
-uno::Sequence< OUString > s_aList(2);
-s_aList[0] = MIMETYPE_OASIS_OPENDOCUMENT_TEXT_ASCII;
-s_aList[1] = MIMETYPE_OASIS_OPENDOCUMENT_SPREADSHEET_ASCII;
-return s_aList;
+return { MIMETYPE_OASIS_OPENDOCUMENT_TEXT_ASCII, 
MIMETYPE_OASIS_OPENDOCUMENT_SPREADSHEET_ASCII };
 }
 
 // css::XUnoTunnel
@@ -2649,13 +2646,7 @@ uno::Any SAL_CALL OReportDefinition::getTransferData( 
const datatransfer::DataFl
 
 uno::Sequence< datatransfer::DataFlavor > SAL_CALL 
OReportDefinition::getTransferDataFlavors(  )
 {
-uno::Sequence< datatransfer::DataFlavor > aRet(1);
-
-aRet[0] = datatransfer::DataFlavor( "image/png",
-"PNG",
-cppu::UnoType>::get() );
-
-return aRet;
+return { { "image/png", "PNG", cppu::UnoType>::get() } };
 }
 
 sal_Bool SAL_CALL OReportDefinition::isDataFlavorSupported( const 
datatransfer::DataFlavor& aFlavor )
diff --git a/reportdesign/source/core/api/Shape.cxx 
b/reportdesign/source/core/api/Shape.cxx
index 8c37f99afda9..464d7ac46cbc 100644
--- a/reportdesign/source/core/api/Shape.cxx
+++ b/reportdesign/source/core/api/Shape.cxx
@@ -137,11 +137,7 @@ uno::Sequence< OUString > SAL_CALL 
OShape::getSupportedServiceNames(  )
 }
 else
 {
-uno::Sequence< OUString > aServices(2);
-aServices.getArray()[0] = SERVICE_SHAPE;
-aServices.getArray()[1] = m_sServiceName;
-
-return aServices;
+return { SERVICE_SHAPE, m_sServiceName };
 }
 }
 
diff --git a/reportdesign/source/ui/inspection/DataProviderHandler.cxx 
b/reportdesign/source/ui/inspection/DataProviderHandler.cxx
index dd770ff9fd5b..ef1c58ada24f 100644
--- a/reportdesign/source/ui/inspection/DataProviderHandler.cxx
+++ b/reportdesign/source/ui/inspection/DataProviderHandler.cxx
@@ -226,8 +226,7 @@ void DataProviderHandler::impl_updateChartTitle_throw(const 
uno::Any& _aValue)
 OUString sStr;
 _aValue >>= sStr;
 xFormatted->setString(sStr);
-uno::Sequence< uno::Reference< chart2::XFormattedString> > aArgs(1);
-aArgs[0] = xFormatted;
+uno::Sequence< uno::Reference< chart2::XFormattedString> > aArgs { 
xFormatted };
 xTitle->setText(aArgs);
 }
 }
diff --git a/reportdesign/source/ui/inspection/GeometryHandler.cxx 
b/reportdesign/source/ui/inspection/GeometryHandler.cxx
index 512b6837be30..280e9060e67f 100644
--- a/reportdesign/source/ui/inspection/GeometryHandler.cxx
+++ b/reportdesign/source/ui/inspection/GeometryHandler.cxx
@@ -1354,12 +1354,14 @@ uno::Sequence< OUString > SAL_CALL 
GeometryHandler::getActuatingProperties()
 {
 ::osl::MutexGuard aGuard( m_aMutex );
 
-uno::Sequence< OUString > aSeq(5);
-aSeq[0] = PROPERTY_BACKTRANSPARENT;
-aSeq[1] = PROPERTY_CONTROLBACKGROUNDTRANSPARENT;
-aSeq[2] = PROPERTY_FORMULALIST;
-aSeq[3] = PROPERTY_TYPE;
-aSeq[4] = PROPERTY_DATAFIELD;
+uno::Sequence< OUString > aSeq
+{
+PROPERTY_BACKTRANSPARENT,
+PROPERTY_CONTROLBACKGROUNDTRANSPARENT,
+PROPERTY_FORMULALIST,
+PROPERTY_TYPE,
+PROPERTY_DATAFIELD
+};
 
 return 
::comphelper::concatSequences(m_xFormComponentHandler->getActuatingProperties(),aSeq);
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-09 Thread Julien Nabet (via logerrit)
 reportdesign/source/ui/inspection/DataProviderHandler.cxx |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 92556e330ede97e11ae2cbc487bb298e6bbcb6bf
Author: Julien Nabet 
AuthorDate: Wed Jun 9 09:18:20 2021 +0200
Commit: Julien Nabet 
CommitDate: Wed Jun 9 10:22:39 2021 +0200

Even more simplification in initializations (reportdesign)

following 
https://cgit.freedesktop.org/libreoffice/core/commit/?id=bd536744ec947090819d59e0f0ec9f2c454aa428
author  Julien Nabet   2021-06-08 22:00:41 +0200
committer   Julien Nabet   2021-06-09 07:43:32 
+0200
commit  bd536744ec947090819d59e0f0ec9f2c454aa428 (patch)
treec970950805e3953e5b7c663fa8095cbd20beb737
parent  96f8ed6619a73655f9c3b94e6a4a3979cc67f551 (diff)
Simplify Sequences initializations (reportdesign)

Thank you Mike!

Change-Id: Ib1dbcb3def89c2060534e30304cd8f35e5486efd
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116880
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/reportdesign/source/ui/inspection/DataProviderHandler.cxx 
b/reportdesign/source/ui/inspection/DataProviderHandler.cxx
index ef1c58ada24f..d9665d6883dc 100644
--- a/reportdesign/source/ui/inspection/DataProviderHandler.cxx
+++ b/reportdesign/source/ui/inspection/DataProviderHandler.cxx
@@ -226,8 +226,7 @@ void DataProviderHandler::impl_updateChartTitle_throw(const 
uno::Any& _aValue)
 OUString sStr;
 _aValue >>= sStr;
 xFormatted->setString(sStr);
-uno::Sequence< uno::Reference< chart2::XFormattedString> > aArgs { 
xFormatted };
-xTitle->setText(aArgs);
+xTitle->setText({ xFormatted });
 }
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-09 Thread Julien Nabet (via logerrit)
 i18npool/source/localedata/localedata.cxx  |   39 
+++---
 i18npool/source/transliteration/transliteration_Ignore.cxx |   18 
 i18npool/source/transliteration/transliteration_body.cxx   |5 -
 i18npool/source/transliteration/transliteration_caseignore.cxx |   12 ---
 linguistic/source/gciterator.cxx   |9 --
 oox/source/drawingml/textparagraphproperties.cxx   |3 
 oox/source/export/drawingml.cxx|   19 ++--
 oox/source/ppt/pptfilterhelpers.cxx|   10 +-
 package/source/zippackage/ZipPackage.cxx   |   16 +---
 9 files changed, 44 insertions(+), 87 deletions(-)

New commits:
commit 7af40a445551a07c6918f835da20ca461a6bd4ee
Author: Julien Nabet 
AuthorDate: Tue Jun 8 21:39:34 2021 +0200
Commit: Julien Nabet 
CommitDate: Wed Jun 9 10:49:26 2021 +0200

Simplify Sequences initializations (i*->p*)

Change-Id: I6bf0eaa2233de2487d90a2f9ae7de263b4ddf1bd
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116865
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/i18npool/source/localedata/localedata.cxx 
b/i18npool/source/localedata/localedata.cxx
index 0f3b03a2689a..33da5647adc3 100644
--- a/i18npool/source/localedata/localedata.cxx
+++ b/i18npool/source/localedata/localedata.cxx
@@ -784,8 +784,7 @@ LocaleDataImpl::getAllCalendars2( const Locale& rLocale )
 return calendarsSeq;
 }
 else {
-Sequence< Calendar2 > seq1(0);
-return seq1;
+return {};
 }
 }
 
@@ -828,8 +827,7 @@ LocaleDataImpl::getAllCurrencies2( const Locale& rLocale )
 return seq;
 }
 else {
-Sequence< Currency2 > seq1(0);
-return seq1;
+return {};
 }
 }
 
@@ -910,8 +908,7 @@ LocaleDataImpl::getDateAcceptancePatterns( const Locale& 
rLocale )
 }
 else
 {
-Sequence< OUString > seq(0);
-return seq;
+return {};
 }
 }
 
@@ -954,8 +951,7 @@ LocaleDataImpl::getCollatorImplementations( const Locale& 
rLocale )
 return seq;
 }
 else {
-Sequence< Implementation > seq1(0);
-return seq1;
+return {};
 }
 }
 
@@ -974,8 +970,7 @@ LocaleDataImpl::getCollationOptions( const Locale& rLocale )
 return seq;
 }
 else {
-Sequence< OUString > seq1(0);
-return seq1;
+return {};
 }
 }
 
@@ -994,8 +989,7 @@ LocaleDataImpl::getSearchOptions( const Locale& rLocale )
 return seq;
 }
 else {
-Sequence< OUString > seq1(0);
-return seq1;
+return {};
 }
 }
 
@@ -1023,8 +1017,7 @@ LocaleDataImpl::getIndexAlgorithm( const Locale& rLocale )
 return seq;
 }
 else {
-Sequence< OUString > seq1(0);
-return seq1;
+return {};
 }
 }
 
@@ -1108,8 +1101,7 @@ LocaleDataImpl::getUnicodeScripts( const Locale& rLocale )
 return seq;
 }
 else {
-Sequence< UnicodeScript > seq1(0);
-return seq1;
+return {};
 }
 }
 
@@ -1128,8 +1120,7 @@ LocaleDataImpl::getFollowPageWords( const Locale& rLocale 
)
 return seq;
 }
 else {
-Sequence< OUString > seq1(0);
-return seq1;
+return {};
 }
 }
 
@@ -1150,8 +1141,7 @@ LocaleDataImpl::getTransliterations( const Locale& 
rLocale )
 return seq;
 }
 else {
-Sequence< OUString > seq1(0);
-return seq1;
+return {};
 }
 
 
@@ -1229,8 +1219,7 @@ LocaleDataImpl::getBreakIteratorRules( const Locale& 
rLocale  )
 return seq;
 }
 else {
-Sequence< OUString > seq1(0);
-return seq1;
+return {};
 }
 }
 
@@ -1251,8 +1240,7 @@ LocaleDataImpl::getReservedWord( const Locale& rLocale  )
 return seq;
 }
 else {
-Sequence< OUString > seq1(0);
-return seq1;
+return {};
 }
 }
 
@@ -1427,8 +1415,7 @@ LocaleDataImpl::getOutlineNumberingLevels( const 
lang::Locale& rLocale )
 return aRet;
 }
 else {
-Sequence< Reference > seq1(0);
-return seq1;
+return {};
 }
 }
 
diff --git a/i18npool/source/transliteration/transliteration_Ignore.cxx 
b/i18npool/source/transliteration/transliteration_Ignore.cxx
index 946e2979b0da..c3faeb11ed0f 100644
--- a/i18npool/source/transliteration/transliteration_Ignore.cxx
+++ b/i18npool/source/transliteration/transliteration_Ignore.cxx
@@ -66,10 +66,7 @@ transliteration_Ignore::transliterateRange( const OUString& 
str1, const OUString
 if (str1.isEmpty() || str2.isEmpty())
 throw RuntimeException();
 
-Sequence< OUString > r(2);
-r[0] = str1.copy(0, 1);
-r[1] = str2.copy(0, 1);
-return r;
+return { str1.copy(0, 1), str2.copy(0, 1) };
 }
 
 
@@ -103,18 +100,9 @@ transliteration_Ignore::transliterateRange( const 
OUString& str1, const OUString
 OUString s22 = 

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

2021-06-08 Thread Julien Nabet (via logerrit)
 chart2/source/model/main/ChartModel.cxx   |8 ++--
 chart2/source/model/template/BarChartType.cxx |6 +-
 chart2/source/model/template/BubbleChartType.cxx  |   12 ++--
 chart2/source/model/template/ChartType.cxx|5 +
 chart2/source/model/template/ColumnChartType.cxx  |6 +-
 chart2/source/model/template/PieChartType.cxx |6 +-
 chart2/source/model/template/ScatterChartType.cxx |6 +-
 chart2/source/tools/CommonConverters.cxx  |   12 ++--
 chart2/source/tools/DataSourceHelper.cxx  |   18 ++
 chart2/source/view/charttypes/ConfigAccess.cxx|3 +--
 10 files changed, 18 insertions(+), 64 deletions(-)

New commits:
commit 5895be734d1872c9c014aca5fe77813dd78cfd14
Author: Julien Nabet 
AuthorDate: Mon Jun 7 21:54:42 2021 +0200
Commit: Julien Nabet 
CommitDate: Tue Jun 8 10:25:12 2021 +0200

Simplify Sequences initializations (chart2)(part1)

Change-Id: I97ddde9659f337932b4165b794a769b83882126d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116802
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/chart2/source/model/main/ChartModel.cxx 
b/chart2/source/model/main/ChartModel.cxx
index 164daeed7c3d..01bf592f7f34 100644
--- a/chart2/source/model/main/ChartModel.cxx
+++ b/chart2/source/model/main/ChartModel.cxx
@@ -1080,13 +1080,9 @@ uno::Any SAL_CALL ChartModel::getTransferData( const 
datatransfer::DataFlavor& a
 
 Sequence< datatransfer::DataFlavor > SAL_CALL 
ChartModel::getTransferDataFlavors()
 {
-uno::Sequence< datatransfer::DataFlavor > aRet(1);
-
-aRet[0] = datatransfer::DataFlavor( lcl_aGDIMetaFileMIMETypeHighContrast,
+return { datatransfer::DataFlavor( lcl_aGDIMetaFileMIMETypeHighContrast,
 "GDIMetaFile",
-cppu::UnoType>::get() );
-
-return aRet;
+cppu::UnoType>::get() ) };
 }
 
 sal_Bool SAL_CALL ChartModel::isDataFlavorSupported( const 
datatransfer::DataFlavor& aFlavor )
diff --git a/chart2/source/model/template/BarChartType.cxx 
b/chart2/source/model/template/BarChartType.cxx
index 87675e3f140d..d32aa6efeca3 100644
--- a/chart2/source/model/template/BarChartType.cxx
+++ b/chart2/source/model/template/BarChartType.cxx
@@ -53,11 +53,7 @@ OUString SAL_CALL BarChartType::getChartType()
 
 uno::Sequence< OUString > BarChartType::getSupportedPropertyRoles()
 {
-uno::Sequence< OUString > aPropRoles(2);
-aPropRoles[0] = "FillColor";
-aPropRoles[1] = "BorderColor";
-
-return aPropRoles;
+return { "FillColor", "BorderColor" };
 }
 
 OUString SAL_CALL BarChartType::getImplementationName()
diff --git a/chart2/source/model/template/BubbleChartType.cxx 
b/chart2/source/model/template/BubbleChartType.cxx
index 4abdbb826467..1998eb9e4dc7 100644
--- a/chart2/source/model/template/BubbleChartType.cxx
+++ b/chart2/source/model/template/BubbleChartType.cxx
@@ -147,20 +147,12 @@ OUString SAL_CALL BubbleChartType::getChartType()
 
 uno::Sequence< OUString > SAL_CALL 
BubbleChartType::getSupportedMandatoryRoles()
 {
-uno::Sequence< OUString > aMandRolesSeq(4);
-aMandRolesSeq[0] = "label";
-aMandRolesSeq[1] = "values-x";
-aMandRolesSeq[2] = "values-y";
-aMandRolesSeq[3] = "values-size";
-return aMandRolesSeq;
+return { "label", "values-x", "values-y", "values-size" };
 }
 
 uno::Sequence< OUString > SAL_CALL BubbleChartType::getSupportedPropertyRoles()
 {
-uno::Sequence< OUString > aPropertyRoles(2);
-aPropertyRoles[0] = "FillColor";
-aPropertyRoles[1] = "BorderColor";
-return aPropertyRoles;
+return { "FillColor", "BorderColor" };
 }
 
 OUString SAL_CALL BubbleChartType::getRoleOfSequenceForSeriesLabel()
diff --git a/chart2/source/model/template/ChartType.cxx 
b/chart2/source/model/template/ChartType.cxx
index 177eb4f1372d..5eb0adca0f06 100644
--- a/chart2/source/model/template/ChartType.cxx
+++ b/chart2/source/model/template/ChartType.cxx
@@ -98,10 +98,7 @@ Reference< chart2::XCoordinateSystem > SAL_CALL
 
 Sequence< OUString > SAL_CALL ChartType::getSupportedMandatoryRoles()
 {
-Sequence< OUString > aDefaultSeq(2);
-aDefaultSeq[0] = "label";
-aDefaultSeq[1] = "values-y";
-return aDefaultSeq;
+return { "label", "values-y" };
 }
 
 Sequence< OUString > SAL_CALL ChartType::getSupportedOptionalRoles()
diff --git a/chart2/source/model/template/ColumnChartType.cxx 
b/chart2/source/model/template/ColumnChartType.cxx
index 4c95b1c1b0b8..487cf8977099 100644
--- a/chart2/source/model/template/ColumnChartType.cxx
+++ b/chart2/source/model/template/ColumnChartType.cxx
@@ -149,11 +149,7 @@ OUString SAL_CALL ColumnChartType::getChartType()
 
 uno::Sequence< OUString > ColumnChartType::getSupportedPropertyRoles()
 {
-uno::Sequence< OUString > aPropRoles(2);
-aPropRoles[0] = "FillColor";
-aPropRoles[1] = "BorderColor";
-
-return aPropRoles;
+return { "FillColor", "BorderColor" };
 }
 
 //  OPropertySet 
diff --git 

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

2021-06-08 Thread Julien Nabet (via logerrit)
 chart2/source/view/main/ChartView.cxx |   15 +--
 1 file changed, 5 insertions(+), 10 deletions(-)

New commits:
commit 2d5fb75274fc34f71c45b8e483684086bb50c686
Author: Julien Nabet 
AuthorDate: Tue Jun 8 09:50:18 2021 +0200
Commit: Julien Nabet 
CommitDate: Tue Jun 8 10:47:27 2021 +0200

Simplify Sequences initializations (chart2)(part 2)

Change-Id: If03d2f7f22c65aaebe236d9b33e6609d31660387
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116810
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/chart2/source/view/main/ChartView.cxx 
b/chart2/source/view/main/ChartView.cxx
index 143d0bcfc798..f6642c920968 100644
--- a/chart2/source/view/main/ChartView.cxx
+++ b/chart2/source/view/main/ChartView.cxx
@@ -1192,16 +1192,11 @@ uno::Any SAL_CALL ChartView::getTransferData( const 
datatransfer::DataFlavor& aF
 }
 uno::Sequence< datatransfer::DataFlavor > SAL_CALL 
ChartView::getTransferDataFlavors()
 {
-uno::Sequence< datatransfer::DataFlavor > aRet(2);
-
-aRet[0] = datatransfer::DataFlavor( lcl_aGDIMetaFileMIMEType,
-"GDIMetaFile",
-cppu::UnoType>::get() );
-aRet[1] = datatransfer::DataFlavor( lcl_aGDIMetaFileMIMETypeHighContrast,
-"GDIMetaFile",
-cppu::UnoType>::get() );
-
-return aRet;
+return
+{
+{ lcl_aGDIMetaFileMIMEType, "GDIMetaFile", 
cppu::UnoType>::get() },
+{ lcl_aGDIMetaFileMIMETypeHighContrast, "GDIMetaFile", 
cppu::UnoType>::get() }
+};
 }
 sal_Bool SAL_CALL ChartView::isDataFlavorSupported( const 
datatransfer::DataFlavor& aFlavor )
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: sot/source stoc/test svl/source svtools/source svx/source

2021-06-10 Thread Julien Nabet (via logerrit)
 sot/source/sdstor/ucbstorage.cxx   |   10 +---
 stoc/test/testregistry.cxx |7 -
 svl/source/passwordcontainer/passwordcontainer.cxx |   26 -
 svtools/source/control/inettbc.cxx |   15 +---
 svx/source/accessibility/charmapacc.cxx|8 +-
 svx/source/fmcomp/gridcell.cxx |   15 
 svx/source/form/formcontroller.cxx |   13 +-
 svx/source/xml/xmleohlp.cxx|2 -
 8 files changed, 25 insertions(+), 71 deletions(-)

New commits:
commit 159030991c70fc3c4018ef28abf1814902a0aebb
Author: Julien Nabet 
AuthorDate: Wed Jun 9 23:17:41 2021 +0200
Commit: Julien Nabet 
CommitDate: Thu Jun 10 08:30:12 2021 +0200

Simplify Sequences initializations (sot/stock/svl/svtools/svx)

Change-Id: Iec21851d69f4a8d5f557e9ed2d30e5f680cd62c2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116943
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sot/source/sdstor/ucbstorage.cxx b/sot/source/sdstor/ucbstorage.cxx
index 162748e5b5d2..460b3c650fe3 100644
--- a/sot/source/sdstor/ucbstorage.cxx
+++ b/sot/source/sdstor/ucbstorage.cxx
@@ -1670,20 +1670,14 @@ void UCBStorage_Impl::ReadContent()
 
 m_bListCreated = true;
 
-// create cursor for access to children
-Sequence< OUString > aProps(4);
-aProps[0] = "Title";
-aProps[1] = "IsFolder";
-aProps[2] = "MediaType";
-aProps[3] = "Size";
-
 try
 {
 GetContent();
 if ( !m_pContent )
 return;
 
-Reference< XResultSet > xResultSet = m_pContent->createCursor( aProps, 
::ucbhelper::INCLUDE_FOLDERS_AND_DOCUMENTS );
+// create cursor for access to children
+Reference< XResultSet > xResultSet = m_pContent->createCursor( { 
"Title", "IsFolder", "MediaType", "Size" }, 
::ucbhelper::INCLUDE_FOLDERS_AND_DOCUMENTS );
 Reference< XRow > xRow( xResultSet, UNO_QUERY );
 if ( xResultSet.is() )
 {
diff --git a/stoc/test/testregistry.cxx b/stoc/test/testregistry.cxx
index d81328ac6f37..ef0d0a91d551 100644
--- a/stoc/test/testregistry.cxx
+++ b/stoc/test/testregistry.cxx
@@ -513,12 +513,7 @@ void test_DefaultRegistry(
 OSL_ENSURE( seqValue.getArray()[2] == "come",
   "test_DefaultRegistry error 13" );
 
-Sequence seqLong(3);
-seqLong.getArray()[0] = 1234;
-seqLong.getArray()[1] = 4567;
-seqLong.getArray()[2] = 7890;
-
-xKey->setLongListValue(seqLong);
+xKey->setLongListValue({ 1234, 4567, 7890 });
 
 Sequence seqLongValue = xKey->getLongListValue();
 
diff --git a/svl/source/passwordcontainer/passwordcontainer.cxx 
b/svl/source/passwordcontainer/passwordcontainer.cxx
index 596a6e413db3..99f94c5eb809 100644
--- a/svl/source/passwordcontainer/passwordcontainer.cxx
+++ b/svl/source/passwordcontainer/passwordcontainer.cxx
@@ -231,15 +231,11 @@ PassMap StorageItem::getInfo()
 
 void StorageItem::setUseStorage( bool bUse )
 {
-Sequence< OUString > sendNames(1);
 Sequence< uno::Any > sendVals(1);
-
-sendNames[0] = "UseStorage";
-
 sendVals[0] <<= bUse;
 
 ConfigItem::SetModified();
-ConfigItem::PutProperties( sendNames, sendVals );
+ConfigItem::PutProperties( { "UseStorage" }, sendVals );
 }
 
 
@@ -293,18 +289,14 @@ bool StorageItem::getEncodedMP( OUString& aResult )
 
 void StorageItem::setEncodedMP( const OUString& aEncoded, bool bAcceptEmpty )
 {
-Sequence< OUString > sendNames(2);
 Sequence< uno::Any > sendVals(2);
 
-sendNames[0] = "HasMaster";
-sendNames[1] = "Master";
-
 bool bHasMaster = ( !aEncoded.isEmpty() || bAcceptEmpty );
 sendVals[0] <<= bHasMaster;
 sendVals[1] <<= aEncoded;
 
 ConfigItem::SetModified();
-ConfigItem::PutProperties( sendNames, sendVals );
+ConfigItem::PutProperties( { "HasMaster", "Master" }, sendVals );
 
 hasEncoded = bHasMaster;
 mEncoded = aEncoded;
@@ -313,13 +305,8 @@ void StorageItem::setEncodedMP( const OUString& aEncoded, 
bool bAcceptEmpty )
 
 void StorageItem::remove( const OUString& aURL, const OUString& aName )
 {
-std::vector < OUString > forIndex;
-forIndex.push_back( aURL );
-forIndex.push_back( aName );
-
-Sequence< OUString > sendSeq(1);
-
-sendSeq[0] = createIndex( forIndex );
+std::vector < OUString > forIndex { aURL, aName };
+Sequence< OUString > sendSeq { createIndex( forIndex ) };
 
 ConfigItem::ClearNodeElements( "Store", sendSeq );
 }
@@ -673,18 +660,15 @@ UrlRecord SAL_CALL PasswordContainer::findForName( const 
OUString& aURL, const O
 
 Sequence< UserRecord > PasswordContainer::FindUsr( const std::vector< 
NamePassRecord >& userlist, std::u16string_view aName, const Reference< 
XInteractionHandler >& aHandler )
 {
-sal_uInt32 nInd = 0;
 for (auto const& aNPIter : userlist)
 {
  

[Libreoffice-commits] core.git: Branch 'libreoffice-7-2' - sc/uiconfig

2021-06-20 Thread Julien Nabet (via logerrit)
 sc/uiconfig/scalc/ui/notebookbar.ui|4 ++--
 sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui |4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit d23b3992a4df64d2dfd7d2c593b1589dadd68d40
Author: Julien Nabet 
AuthorDate: Tue Jun 15 22:06:48 2021 +0200
Commit: Julien Nabet 
CommitDate: Sun Jun 20 09:05:55 2021 +0200

tdf#142873: Fix print preview zoom-out zoom-in buttons

.uno:ZoomOut has been renamed .uno:ZoomMinus
.uno:ZoomIn has been renamed .uno:ZoomPlus

Change-Id: I06e7e66550399e53032a0df39a98846982acba48
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117279
Tested-by: Jenkins
Reviewed-by: Jim Raykowski 
(cherry picked from commit c21398066b6bf630070ed291456f2663e06d94b9)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117424

diff --git a/sc/uiconfig/scalc/ui/notebookbar.ui 
b/sc/uiconfig/scalc/ui/notebookbar.ui
index 3626b2da0dc0..ef2886b0d28f 100644
--- a/sc/uiconfig/scalc/ui/notebookbar.ui
+++ b/sc/uiconfig/scalc/ui/notebookbar.ui
@@ -15018,7 +15018,7 @@
   
 True
 False
-.uno:ZoomOut
+.uno:ZoomMinus
   
   
 False
@@ -15042,7 +15042,7 @@
   
 True
 False
-.uno:ZoomIn
+.uno:ZoomPlus
   
   
 False
diff --git a/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui 
b/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui
index 84f390bb5461..4ff33a943a9a 100644
--- a/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui
+++ b/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui
@@ -11061,7 +11061,7 @@
   
 True
 False
-.uno:ZoomOut
+.uno:ZoomMinus
   
   
 False
@@ -11087,7 +11087,7 @@
   
 True
 False
-.uno:ZoomIn
+.uno:ZoomPlus
   
   
 False
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - sc/uiconfig

2021-06-20 Thread Julien Nabet (via logerrit)
 sc/uiconfig/scalc/ui/notebookbar.ui|4 ++--
 sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui |4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit c82178535780df2b54c80b084e9d9e6eb453fac2
Author: Julien Nabet 
AuthorDate: Tue Jun 15 22:06:48 2021 +0200
Commit: Adolfo Jayme Barrientos 
CommitDate: Mon Jun 21 05:30:48 2021 +0200

tdf#142873: Fix print preview zoom-out zoom-in buttons

.uno:ZoomOut has been renamed .uno:ZoomMinus
.uno:ZoomIn has been renamed .uno:ZoomPlus

Change-Id: I06e7e66550399e53032a0df39a98846982acba48
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117279
Tested-by: Jenkins
Reviewed-by: Jim Raykowski 
(cherry picked from commit c21398066b6bf630070ed291456f2663e06d94b9)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117427
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/sc/uiconfig/scalc/ui/notebookbar.ui 
b/sc/uiconfig/scalc/ui/notebookbar.ui
index ba90157318e1..cfba28457b65 100644
--- a/sc/uiconfig/scalc/ui/notebookbar.ui
+++ b/sc/uiconfig/scalc/ui/notebookbar.ui
@@ -14795,7 +14795,7 @@
   
 True
 False
-.uno:ZoomOut
+.uno:ZoomMinus
   
   
 False
@@ -14820,7 +14820,7 @@
   
 True
 False
-.uno:ZoomIn
+.uno:ZoomPlus
   
   
 False
diff --git a/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui 
b/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui
index fa97921c36ab..8161fffdc2ee 100644
--- a/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui
+++ b/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui
@@ -11064,7 +11064,7 @@
   
 True
 False
-.uno:ZoomOut
+.uno:ZoomMinus
   
   
 False
@@ -11091,7 +11091,7 @@
   
 True
 False
-.uno:ZoomIn
+.uno:ZoomPlus
   
   
 False
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - sc/source

2021-06-22 Thread Julien Nabet (via logerrit)
 sc/source/core/data/table7.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 0a8131d098e24842480c9c42b5e47accc7c59ce0
Author: Julien Nabet 
AuthorDate: Sat Jun 19 13:51:28 2021 +0200
Commit: Xisco Fauli 
CommitDate: Tue Jun 22 21:45:18 2021 +0200

tdf#142932: fix crash when pasting cells with comments+"skip empty cells"

See bt here:
https://bugs.documentfoundation.org/attachment.cgi?id=173011

4  0x7fc4b0cdbb3d in ScColContainer::operator[](unsigned long) 
(this=0x872e1e0, nIndex=64) at sc/inc/colcontainer.hxx:43
5  0x7fc4b120d82b in 
ScTable::DeleteBeforeCopyFromClip(sc::CopyFromClipContext&, ScTable const&, 
sc::ColumnSpanSet&) (this=0x872e1e0, rCxt=..., rClipTab=..., 
rBroadcastSpans=...)
   at sc/source/core/data/table7.cxx:118
6  0x7fc4b0e42939 in 
ScDocument::DeleteBeforeCopyFromClip(sc::CopyFromClipContext&, ScMarkData 
const&, sc::ColumnSpanSet&) (this=0x3bffa60, rCxt=..., rMark=..., 
rBroadcastSpans=...)
   at sc/source/core/data/document10.cxx:75
7  0x7fc4b0e0b67b in ScDocument::CopyFromClip(ScRange const&, 
ScMarkData const&, InsertDeleteFlags, ScDocument*, ScDocument*, bool, bool, 
bool, bool, ScRangeList const*)
   (this=0x3bffa60, rDestRange=..., rMark=..., nInsFlag=7, pRefUndoDoc=0x0, 
pClipDoc=0x7d3bb40, bResetCut=true, bAsLink=false, bIncludeFiltered=false, 
bSkipAttrForEmpty=true, pDestRanges=0x7fff4a3da4b0)
   at sc/source/core/data/document.cxx:2916
8  0x7fc4b2412dc3 in ScViewFunc::PasteFromClip(InsertDeleteFlags, 
ScDocument*, ScPasteFunc, bool, bool, bool, InsCellCmd, InsertDeleteFlags, 
bool) (this=
   0x41a29e0, nFlags=7, pClipDoc=0x7d3bb40, nFunction=ScPasteFunc::NONE, 
bSkipEmpty=true, bTranspose=false, bAsLink=false, eMoveMode=INS_NONE, 
nUndoExtraFlags=InsertDeleteFlags::NONE, bAllowDialogs=true)
   at sc/source/ui/view/viewfun3.cxx:1312

Change-Id: Ic119cb5d414a35a9ba18b0564d7adf83154eb9d7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117497
Tested-by: Jenkins
Reviewed-by: Noel Grandin 
(cherry picked from commit a6d269ed9478b20f611912bf9711c2683e7bc924)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117632
Reviewed-by: Xisco Fauli 
(cherry picked from commit bb59b4165456d13eda800098be8b875d93b093d3)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117637

diff --git a/sc/source/core/data/table7.cxx b/sc/source/core/data/table7.cxx
index fc821133ef65..b75751ff7de4 100644
--- a/sc/source/core/data/table7.cxx
+++ b/sc/source/core/data/table7.cxx
@@ -108,7 +108,8 @@ void ScTable::DeleteBeforeCopyFromClip(
 ScRange aClipRange = rCxt.getClipDoc()->GetClipParam().getWholeRange();
 SCCOL nClipCol = aClipRange.aStart.Col();
 {
-for (SCCOL nCol = aRange.mnCol1; nCol <= aRange.mnCol2; ++nCol, 
++nClipCol)
+const SCCOL nMaxCol2 = std::min( aRange.mnCol2, aCol.size() - 1 
);
+for (SCCOL nCol = aRange.mnCol1; nCol <= nMaxCol2; ++nCol, ++nClipCol)
 {
 if (nClipCol > aClipRange.aEnd.Col())
 nClipCol = aClipRange.aStart.Col(); // loop through columns.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'distro/collabora/co-2021' - 12 commits - dbaccess/source extras/CustomTarget_tpldraw.mk extras/Package_tpldraw.mk include/sfx2 officecfg/registry sc/source sc/u

2021-06-23 Thread Julien Nabet (via logerrit)
 dbaccess/source/ui/browser/unodatbr.cxx|2 
 dbaccess/source/ui/control/dbtreelistbox.cxx   |4 
 dbaccess/source/ui/inc/dbtreelistbox.hxx   |2 
 extras/CustomTarget_tpldraw.mk |   12 +-
 extras/Package_tpldraw.mk  |2 
 include/sfx2/sidebar/SidebarController.hxx |1 
 officecfg/registry/schema/org/openoffice/Office/UI/Sidebar.xcs |7 +
 sc/source/core/data/table7.cxx |3 
 sc/uiconfig/scalc/ui/notebookbar.ui|4 
 sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui |4 
 sd/source/ui/unoidl/randomnode.cxx |7 -
 sfx2/source/sidebar/SidebarController.cxx  |5 
 svx/source/sidebar/possize/PosSizePropertyPanel.cxx|2 
 svx/uiconfig/ui/sidebarpossize.ui  |1 
 sw/qa/core/layout/data/birt_min.odt|binary
 sw/qa/core/layout/layout.cxx   |6 +
 sw/source/core/doc/htmltbl.cxx |2 
 sw/source/core/inc/layact.hxx  |5 
 sw/source/core/inc/tabfrm.hxx  |   13 --
 sw/source/core/layout/layact.cxx   |   20 ---
 sw/source/core/layout/tabfrm.cxx   |   55 
--
 sw/source/filter/ww8/ww8par.cxx|   32 +++--
 sw/source/uibase/docvw/edtwin.cxx  |   13 ++
 23 files changed, 118 insertions(+), 84 deletions(-)

New commits:
commit e41b48d8995918d4296b28a160c762697b551af2
Author: Julien Nabet 
AuthorDate: Sat Jun 19 13:51:28 2021 +0200
Commit: Andras Timar 
CommitDate: Wed Jun 23 21:05:00 2021 +0200

tdf#142932: fix crash when pasting cells with comments+"skip empty cells"

See bt here:
https://bugs.documentfoundation.org/attachment.cgi?id=173011

4  0x7fc4b0cdbb3d in ScColContainer::operator[](unsigned long) 
(this=0x872e1e0, nIndex=64) at sc/inc/colcontainer.hxx:43
5  0x7fc4b120d82b in 
ScTable::DeleteBeforeCopyFromClip(sc::CopyFromClipContext&, ScTable const&, 
sc::ColumnSpanSet&) (this=0x872e1e0, rCxt=..., rClipTab=..., 
rBroadcastSpans=...)
   at sc/source/core/data/table7.cxx:118
6  0x7fc4b0e42939 in 
ScDocument::DeleteBeforeCopyFromClip(sc::CopyFromClipContext&, ScMarkData 
const&, sc::ColumnSpanSet&) (this=0x3bffa60, rCxt=..., rMark=..., 
rBroadcastSpans=...)
   at sc/source/core/data/document10.cxx:75
7  0x7fc4b0e0b67b in ScDocument::CopyFromClip(ScRange const&, 
ScMarkData const&, InsertDeleteFlags, ScDocument*, ScDocument*, bool, bool, 
bool, bool, ScRangeList const*)
   (this=0x3bffa60, rDestRange=..., rMark=..., nInsFlag=7, pRefUndoDoc=0x0, 
pClipDoc=0x7d3bb40, bResetCut=true, bAsLink=false, bIncludeFiltered=false, 
bSkipAttrForEmpty=true, pDestRanges=0x7fff4a3da4b0)
   at sc/source/core/data/document.cxx:2916
8  0x7fc4b2412dc3 in ScViewFunc::PasteFromClip(InsertDeleteFlags, 
ScDocument*, ScPasteFunc, bool, bool, bool, InsCellCmd, InsertDeleteFlags, 
bool) (this=
   0x41a29e0, nFlags=7, pClipDoc=0x7d3bb40, nFunction=ScPasteFunc::NONE, 
bSkipEmpty=true, bTranspose=false, bAsLink=false, eMoveMode=INS_NONE, 
nUndoExtraFlags=InsertDeleteFlags::NONE, bAllowDialogs=true)
   at sc/source/ui/view/viewfun3.cxx:1312

Change-Id: Ic119cb5d414a35a9ba18b0564d7adf83154eb9d7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117497
Tested-by: Jenkins
Reviewed-by: Noel Grandin 
(cherry picked from commit a6d269ed9478b20f611912bf9711c2683e7bc924)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117632
Reviewed-by: Xisco Fauli 
(cherry picked from commit bb59b4165456d13eda800098be8b875d93b093d3)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117637

diff --git a/sc/source/core/data/table7.cxx b/sc/source/core/data/table7.cxx
index fc821133ef65..b75751ff7de4 100644
--- a/sc/source/core/data/table7.cxx
+++ b/sc/source/core/data/table7.cxx
@@ -108,7 +108,8 @@ void ScTable::DeleteBeforeCopyFromClip(
 ScRange aClipRange = rCxt.getClipDoc()->GetClipParam().getWholeRange();
 SCCOL nClipCol = aClipRange.aStart.Col();
 {
-for (SCCOL nCol = aRange.mnCol1; nCol <= aRange.mnCol2; ++nCol, 
++nClipCol)
+const SCCOL nMaxCol2 = std::min( aRange.mnCol2, aCol.size() - 1 
);
+for (SCCOL nCol = aRange.mnCol1; nCol <= nMaxCol2; ++nCol, ++nClipCol)
 {
 if (nClipCol > aClipRange.aEnd.Col())
 nClipCol = aClipRange.aStart.Col(); // loop through columns.
commit ddd472813b12501f907c6936e27f9de66fa58452
Author: Caolán McNamara 
AuthorDate: Thu Jun 10 21:02:33 2021 +0100
Commit: Andras Timar 
CommitDate: Wed Jun 23 

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

2021-06-22 Thread Julien Nabet (via logerrit)
 sc/source/core/data/table7.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit a6d269ed9478b20f611912bf9711c2683e7bc924
Author: Julien Nabet 
AuthorDate: Sat Jun 19 13:51:28 2021 +0200
Commit: Noel Grandin 
CommitDate: Tue Jun 22 11:14:11 2021 +0200

tdf#142932: fix crash when pasting cells with comments+"skip empty cells"

See bt here:
https://bugs.documentfoundation.org/attachment.cgi?id=173011

4  0x7fc4b0cdbb3d in ScColContainer::operator[](unsigned long) 
(this=0x872e1e0, nIndex=64) at sc/inc/colcontainer.hxx:43
5  0x7fc4b120d82b in 
ScTable::DeleteBeforeCopyFromClip(sc::CopyFromClipContext&, ScTable const&, 
sc::ColumnSpanSet&) (this=0x872e1e0, rCxt=..., rClipTab=..., 
rBroadcastSpans=...)
   at sc/source/core/data/table7.cxx:118
6  0x7fc4b0e42939 in 
ScDocument::DeleteBeforeCopyFromClip(sc::CopyFromClipContext&, ScMarkData 
const&, sc::ColumnSpanSet&) (this=0x3bffa60, rCxt=..., rMark=..., 
rBroadcastSpans=...)
   at sc/source/core/data/document10.cxx:75
7  0x7fc4b0e0b67b in ScDocument::CopyFromClip(ScRange const&, 
ScMarkData const&, InsertDeleteFlags, ScDocument*, ScDocument*, bool, bool, 
bool, bool, ScRangeList const*)
   (this=0x3bffa60, rDestRange=..., rMark=..., nInsFlag=7, pRefUndoDoc=0x0, 
pClipDoc=0x7d3bb40, bResetCut=true, bAsLink=false, bIncludeFiltered=false, 
bSkipAttrForEmpty=true, pDestRanges=0x7fff4a3da4b0)
   at sc/source/core/data/document.cxx:2916
8  0x7fc4b2412dc3 in ScViewFunc::PasteFromClip(InsertDeleteFlags, 
ScDocument*, ScPasteFunc, bool, bool, bool, InsCellCmd, InsertDeleteFlags, 
bool) (this=
   0x41a29e0, nFlags=7, pClipDoc=0x7d3bb40, nFunction=ScPasteFunc::NONE, 
bSkipEmpty=true, bTranspose=false, bAsLink=false, eMoveMode=INS_NONE, 
nUndoExtraFlags=InsertDeleteFlags::NONE, bAllowDialogs=true)
   at sc/source/ui/view/viewfun3.cxx:1312

Change-Id: Ic119cb5d414a35a9ba18b0564d7adf83154eb9d7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117497
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/sc/source/core/data/table7.cxx b/sc/source/core/data/table7.cxx
index 6ec79a90fd98..2ab726ed6a98 100644
--- a/sc/source/core/data/table7.cxx
+++ b/sc/source/core/data/table7.cxx
@@ -109,7 +109,8 @@ void ScTable::DeleteBeforeCopyFromClip(
 ScRange aClipRange = rCxt.getClipDoc()->GetClipParam().getWholeRange();
 SCCOL nClipCol = aClipRange.aStart.Col();
 {
-for (SCCOL nCol = aRange.mnCol1; nCol <= aRange.mnCol2; ++nCol, 
++nClipCol)
+const SCCOL nMaxCol2 = std::min( aRange.mnCol2, aCol.size() - 1 
);
+for (SCCOL nCol = aRange.mnCol1; nCol <= nMaxCol2; ++nCol, ++nClipCol)
 {
 if (nClipCol > aClipRange.aEnd.Col())
 nClipCol = aClipRange.aStart.Col(); // loop through columns.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-2' - sc/source

2021-06-22 Thread Julien Nabet (via logerrit)
 sc/source/core/data/table7.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit bb59b4165456d13eda800098be8b875d93b093d3
Author: Julien Nabet 
AuthorDate: Sat Jun 19 13:51:28 2021 +0200
Commit: Xisco Fauli 
CommitDate: Tue Jun 22 14:45:12 2021 +0200

tdf#142932: fix crash when pasting cells with comments+"skip empty cells"

See bt here:
https://bugs.documentfoundation.org/attachment.cgi?id=173011

4  0x7fc4b0cdbb3d in ScColContainer::operator[](unsigned long) 
(this=0x872e1e0, nIndex=64) at sc/inc/colcontainer.hxx:43
5  0x7fc4b120d82b in 
ScTable::DeleteBeforeCopyFromClip(sc::CopyFromClipContext&, ScTable const&, 
sc::ColumnSpanSet&) (this=0x872e1e0, rCxt=..., rClipTab=..., 
rBroadcastSpans=...)
   at sc/source/core/data/table7.cxx:118
6  0x7fc4b0e42939 in 
ScDocument::DeleteBeforeCopyFromClip(sc::CopyFromClipContext&, ScMarkData 
const&, sc::ColumnSpanSet&) (this=0x3bffa60, rCxt=..., rMark=..., 
rBroadcastSpans=...)
   at sc/source/core/data/document10.cxx:75
7  0x7fc4b0e0b67b in ScDocument::CopyFromClip(ScRange const&, 
ScMarkData const&, InsertDeleteFlags, ScDocument*, ScDocument*, bool, bool, 
bool, bool, ScRangeList const*)
   (this=0x3bffa60, rDestRange=..., rMark=..., nInsFlag=7, pRefUndoDoc=0x0, 
pClipDoc=0x7d3bb40, bResetCut=true, bAsLink=false, bIncludeFiltered=false, 
bSkipAttrForEmpty=true, pDestRanges=0x7fff4a3da4b0)
   at sc/source/core/data/document.cxx:2916
8  0x7fc4b2412dc3 in ScViewFunc::PasteFromClip(InsertDeleteFlags, 
ScDocument*, ScPasteFunc, bool, bool, bool, InsCellCmd, InsertDeleteFlags, 
bool) (this=
   0x41a29e0, nFlags=7, pClipDoc=0x7d3bb40, nFunction=ScPasteFunc::NONE, 
bSkipEmpty=true, bTranspose=false, bAsLink=false, eMoveMode=INS_NONE, 
nUndoExtraFlags=InsertDeleteFlags::NONE, bAllowDialogs=true)
   at sc/source/ui/view/viewfun3.cxx:1312

Change-Id: Ic119cb5d414a35a9ba18b0564d7adf83154eb9d7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117497
Tested-by: Jenkins
Reviewed-by: Noel Grandin 
(cherry picked from commit a6d269ed9478b20f611912bf9711c2683e7bc924)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117632
Reviewed-by: Xisco Fauli 

diff --git a/sc/source/core/data/table7.cxx b/sc/source/core/data/table7.cxx
index 6ec79a90fd98..2ab726ed6a98 100644
--- a/sc/source/core/data/table7.cxx
+++ b/sc/source/core/data/table7.cxx
@@ -109,7 +109,8 @@ void ScTable::DeleteBeforeCopyFromClip(
 ScRange aClipRange = rCxt.getClipDoc()->GetClipParam().getWholeRange();
 SCCOL nClipCol = aClipRange.aStart.Col();
 {
-for (SCCOL nCol = aRange.mnCol1; nCol <= aRange.mnCol2; ++nCol, 
++nClipCol)
+const SCCOL nMaxCol2 = std::min( aRange.mnCol2, aCol.size() - 1 
);
+for (SCCOL nCol = aRange.mnCol1; nCol <= nMaxCol2; ++nCol, ++nClipCol)
 {
 if (nClipCol > aClipRange.aEnd.Col())
 nClipCol = aClipRange.aStart.Col(); // loop through columns.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-09 Thread Julien Nabet (via logerrit)
 sfx2/source/bastyp/helper.cxx|   13 ++---
 sfx2/source/doc/doctempl.cxx |8 +---
 sfx2/source/doc/doctemplates.cxx |   32 +---
 sfx2/source/doc/sfxbasemodel.cxx |   25 +++--
 4 files changed, 23 insertions(+), 55 deletions(-)

New commits:
commit 58d218df8c5e36468183ebae666120a6d5d0a4f7
Author: Julien Nabet 
AuthorDate: Wed Jun 9 20:03:04 2021 +0200
Commit: Julien Nabet 
CommitDate: Wed Jun 9 21:28:05 2021 +0200

Simplify Sequences initializations (sfx2)

Change-Id: I1384dd80e910ba1c55ec7481ab481bc48740fc5c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116937
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sfx2/source/bastyp/helper.cxx b/sfx2/source/bastyp/helper.cxx
index 7918cfcceec1..d9d1a4bb4da4 100644
--- a/sfx2/source/bastyp/helper.cxx
+++ b/sfx2/source/bastyp/helper.cxx
@@ -49,15 +49,10 @@ std::vector SfxContentHelper::GetResultSet( const 
OUString& rURL )
 ::ucbhelper::Content aCnt( rURL, uno::Reference< 
ucb::XCommandEnvironment >(), comphelper::getProcessComponentContext() );
 uno::Reference< sdbc::XResultSet > xResultSet;
 uno::Reference< ucb::XDynamicResultSet > xDynResultSet;
-uno::Sequence< OUString > aProps(3);
-OUString* pProps = aProps.getArray();
-pProps[0] = "Title";
-pProps[1] = "ContentType";
-pProps[2] = "IsFolder";
 
 try
 {
-xDynResultSet = aCnt.createDynamicCursor( aProps );
+xDynResultSet = aCnt.createDynamicCursor( { "Title", 
"ContentType", "IsFolder" } );
 if ( xDynResultSet.is() )
 xResultSet = xDynResultSet->getStaticResultSet();
 }
@@ -112,14 +107,10 @@ std::vector< OUString > 
SfxContentHelper::GetHelpTreeViewContents( const OUStrin
 
 ::ucbhelper::Content aCnt( rURL, new ::ucbhelper::CommandEnvironment( 
xInteractionHandler, uno::Reference< ucb::XProgressHandler >() ), 
comphelper::getProcessComponentContext() );
 uno::Reference< sdbc::XResultSet > xResultSet;
-uno::Sequence< OUString > aProps(2);
-OUString* pProps = aProps.getArray();
-pProps[0] = "Title";
-pProps[1] = "IsFolder";
 
 try
 {
-uno::Reference< ucb::XDynamicResultSet > xDynResultSet = 
aCnt.createDynamicCursor( aProps );
+uno::Reference< ucb::XDynamicResultSet > xDynResultSet = 
aCnt.createDynamicCursor( { "Title", "IsFolder" } );
 if ( xDynResultSet.is() )
 xResultSet = xDynResultSet->getStaticResultSet();
 }
diff --git a/sfx2/source/doc/doctempl.cxx b/sfx2/source/doc/doctempl.cxx
index 5e6dd0e6260b..cea3d30f4f1d 100644
--- a/sfx2/source/doc/doctempl.cxx
+++ b/sfx2/source/doc/doctempl.cxx
@@ -1488,16 +1488,10 @@ void SfxDocTemplate_Impl::AddRegion( const OUString& 
rTitle,
 
 // now get the content of the region
 uno::Reference< XResultSet > xResultSet;
-Sequence< OUString > aProps(2);
-aProps[0] = TITLE;
-aProps[1] = TARGET_URL;
 
 try
 {
-Sequence< NumberedSortingInfo > aSortingInfo(1);
-aSortingInfo.getArray()->ColumnIndex = 1;
-aSortingInfo.getArray()->Ascending = true;
-xResultSet = rContent.createSortedCursor( aProps, aSortingInfo, 
m_rCompareFactory, INCLUDE_DOCUMENTS_ONLY );
+xResultSet = rContent.createSortedCursor( { TITLE, TARGET_URL }, { { 
1, true } }, m_rCompareFactory, INCLUDE_DOCUMENTS_ONLY );
 }
 catch ( Exception& ) {}
 
diff --git a/sfx2/source/doc/doctemplates.cxx b/sfx2/source/doc/doctemplates.cxx
index 4e01f35583c7..50d11b8b043b 100644
--- a/sfx2/source/doc/doctemplates.cxx
+++ b/sfx2/source/doc/doctemplates.cxx
@@ -699,11 +699,6 @@ bool SfxDocTplService_Impl::addEntry( Content& 
rParentFolder,
 
 if ( ! Content::create( aLinkURL, maCmdEnv, 
comphelper::getProcessComponentContext(), aLink ) )
 {
-Sequence< OUString > aNames(3);
-aNames[0] = TITLE;
-aNames[1] = IS_FOLDER;
-aNames[2] = TARGET_URL;
-
 Sequence< Any > aValues(3);
 aValues[0] <<= rTitle;
 aValues[1] <<= false;
@@ -711,7 +706,7 @@ bool SfxDocTplService_Impl::addEntry( Content& 
rParentFolder,
 
 try
 {
-rParentFolder.insertNewContent( TYPE_LINK, aNames, aValues, aLink 
);
+rParentFolder.insertNewContent( TYPE_LINK, { TITLE, IS_FOLDER, 
TARGET_URL }, aValues, aLink );
 setProperty( aLink, PROPERTY_TYPE, makeAny( rType ) );
 bAddedEntry = true;
 }
@@ -747,10 +742,6 @@ bool SfxDocTplService_Impl::createFolder( const OUString& 
rNewFolderURL,
 {
 try
 {
-Sequence< OUString > aNames(2);
-aNames[0] = TITLE;
-aNames[1] = IS_FOLDER;
-
 Sequence< Any > aValues(2);
 aValues[0] <<= aFolderName;
 aValues[1] <<= true;
@@ -762,7 +753,7 @@ bool 

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

2021-06-09 Thread Julien Nabet (via logerrit)
 sdext/source/presenter/PresenterGeometryHelper.cxx |   44 -
 sdext/source/presenter/PresenterSlideShowView.cxx  |   27 ++--
 sdext/source/presenter/PresenterWindowManager.cxx  |   27 ++--
 3 files changed, 55 insertions(+), 43 deletions(-)

New commits:
commit da44de883f205736fffeacc148c32dcfd638ad66
Author: Julien Nabet 
AuthorDate: Wed Jun 9 19:02:52 2021 +0200
Commit: Julien Nabet 
CommitDate: Wed Jun 9 21:27:29 2021 +0200

Simplify Sequences initializations (sdext)

Change-Id: Ide9a3ddd4f6915f45b02353293236988bff51eba
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116935
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sdext/source/presenter/PresenterGeometryHelper.cxx 
b/sdext/source/presenter/PresenterGeometryHelper.cxx
index 3d59f259ea7b..67a81d63c766 100644
--- a/sdext/source/presenter/PresenterGeometryHelper.cxx
+++ b/sdext/source/presenter/PresenterGeometryHelper.cxx
@@ -21,6 +21,8 @@
 
 #include 
 #include 
+#include 
+
 
 using namespace ::com::sun::star;
 using namespace ::com::sun::star::uno;
@@ -183,12 +185,15 @@ Reference 
PresenterGeometryHelper::CreatePolygon(
 if ( ! rxDevice.is())
 return nullptr;
 
-Sequence > aPoints(1);
-aPoints[0] = Sequence(4);
-aPoints[0][0] = geometry::RealPoint2D(rBox.X, rBox.Y);
-aPoints[0][1] = geometry::RealPoint2D(rBox.X, rBox.Y+rBox.Height);
-aPoints[0][2] = geometry::RealPoint2D(rBox.X+rBox.Width, 
rBox.Y+rBox.Height);
-aPoints[0][3] = geometry::RealPoint2D(rBox.X+rBox.Width, rBox.Y);
+Sequence > aPoints
+{
+{
+{ o3tl::narrowing(rBox.X), o3tl::narrowing(rBox.Y) 
},
+{ o3tl::narrowing(rBox.X), 
o3tl::narrowing(rBox.Y+rBox.Height) },
+{ o3tl::narrowing(rBox.X+rBox.Width), 
o3tl::narrowing(rBox.Y+rBox.Height) },
+{ o3tl::narrowing(rBox.X+rBox.Width), 
o3tl::narrowing(rBox.Y) }
+}
+};
 Reference xPolygon (
 rxDevice->createCompatibleLinePolyPolygon(aPoints));
 if (xPolygon.is())
@@ -204,12 +209,15 @@ Reference 
PresenterGeometryHelper::CreatePolygon(
 if ( ! rxDevice.is())
 return nullptr;
 
-Sequence > aPoints(1);
-aPoints[0] = Sequence(4);
-aPoints[0][0] = geometry::RealPoint2D(rBox.X1, rBox.Y1);
-aPoints[0][1] = geometry::RealPoint2D(rBox.X1, rBox.Y2);
-aPoints[0][2] = geometry::RealPoint2D(rBox.X2, rBox.Y2);
-aPoints[0][3] = geometry::RealPoint2D(rBox.X2, rBox.Y1);
+Sequence > aPoints
+{
+{
+{ rBox.X1, rBox.Y1 },
+{ rBox.X1, rBox.Y2 },
+{ rBox.X2, rBox.Y2 },
+{ rBox.X2, rBox.Y1 }
+}
+};
 Reference xPolygon (
 rxDevice->createCompatibleLinePolyPolygon(aPoints));
 if (xPolygon.is())
@@ -230,11 +238,13 @@ Reference 
PresenterGeometryHelper::CreatePolygon(
 for (sal_Int32 nIndex=0; nIndex(4);
-aPoints[nIndex][0] = geometry::RealPoint2D(rBox.X, rBox.Y);
-aPoints[nIndex][1] = geometry::RealPoint2D(rBox.X, rBox.Y+rBox.Height);
-aPoints[nIndex][2] = geometry::RealPoint2D(rBox.X+rBox.Width, 
rBox.Y+rBox.Height);
-aPoints[nIndex][3] = geometry::RealPoint2D(rBox.X+rBox.Width, rBox.Y);
+aPoints[nIndex] = Sequence
+{
+{ o3tl::narrowing(rBox.X), o3tl::narrowing(rBox.Y) 
},
+{ o3tl::narrowing(rBox.X), 
o3tl::narrowing(rBox.Y+rBox.Height) },
+{ o3tl::narrowing(rBox.X+rBox.Width), 
o3tl::narrowing(rBox.Y+rBox.Height) },
+{ o3tl::narrowing(rBox.X+rBox.Width), 
o3tl::narrowing(rBox.Y) }
+};
 }
 
 Reference xPolygon (
diff --git a/sdext/source/presenter/PresenterSlideShowView.cxx 
b/sdext/source/presenter/PresenterSlideShowView.cxx
index 7ad4bc207645..26239c0b2642 100644
--- a/sdext/source/presenter/PresenterSlideShowView.cxx
+++ b/sdext/source/presenter/PresenterSlideShowView.cxx
@@ -666,20 +666,21 @@ void PresenterSlideShowView::PaintOuterWindow (const 
awt::Rectangle& rRepaintBox
 Reference xBackgroundBitmap 
(mpBackground->GetNormalBitmap());
 if (xBackgroundBitmap.is())
 {
-Sequence aTextures (1);
 const geometry::IntegerSize2D 
aBitmapSize(xBackgroundBitmap->getSize());
-aTextures[0] = rendering::Texture (
-geometry::AffineMatrix2D(
-aBitmapSize.Width,0,0,
-0,aBitmapSize.Height,0),
-1,
-0,
-xBackgroundBitmap,
-nullptr,
-nullptr,
-rendering::StrokeAttributes(),
-rendering::TexturingMode::REPEAT,
-rendering::TexturingMode::REPEAT);
+Sequence aTextures
+{
+{
+geometry::AffineMatrix2D( aBitmapSize.Width,0,0, 
0,aBitmapSize.Height,0),
+1,
+0,
+xBackgroundBitmap,
+nullptr,
+nullptr,
+rendering::StrokeAttributes(),
+ 

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

2021-06-09 Thread Julien Nabet (via logerrit)
 sd/source/filter/xml/sdxmlwrp.cxx  |   15 ++-
 sd/source/ui/dlg/TemplateScanner.cxx   |   16 +++-
 sd/source/ui/presenter/PresenterCanvas.cxx |   15 +--
 3 files changed, 22 insertions(+), 24 deletions(-)

New commits:
commit fca7d50b17fae217bd34e9e6f5e3a8b0fda93833
Author: Julien Nabet 
AuthorDate: Wed Jun 9 18:27:28 2021 +0200
Commit: Julien Nabet 
CommitDate: Wed Jun 9 19:57:46 2021 +0200

Simplify Sequences initializations (sd)

Change-Id: I968f1209961ba30ad0837846ae1ba4a9249663c8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116934
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sd/source/filter/xml/sdxmlwrp.cxx 
b/sd/source/filter/xml/sdxmlwrp.cxx
index 4bd5b043e089..9a6e8d9a9afe 100644
--- a/sd/source/filter/xml/sdxmlwrp.cxx
+++ b/sd/source/filter/xml/sdxmlwrp.cxx
@@ -1007,11 +1007,16 @@ extern "C" SAL_DLLPUBLIC_EXPORT bool 
TestImportFODP(SvStream )
 uno::Reference xStream(new 
::utl::OSeekableInputStreamWrapper(rStream));
 uno::Reference 
xInterface(xMultiServiceFactory->createInstance("com.sun.star.comp.Writer.XmlFilterAdaptor"),
 uno::UNO_SET_THROW);
 
-css::uno::Sequence aUserData(7);
-aUserData[0] = "com.sun.star.comp.filter.OdfFlatXml";
-aUserData[2] = "com.sun.star.comp.Impress.XMLOasisImporter";
-aUserData[3] = "com.sun.star.comp.Impress.XMLOasisExporter";
-aUserData[6] = "true";
+css::uno::Sequence aUserData
+{
+"com.sun.star.comp.filter.OdfFlatXml",
+"",
+"com.sun.star.comp.Impress.XMLOasisImporter",
+"com.sun.star.comp.Impress.XMLOasisExporter",
+"",
+"",
+"true"
+};
 uno::Sequence 
aAdaptorArgs(comphelper::InitPropertySequence(
 {
 { "UserData", uno::Any(aUserData) },
diff --git a/sd/source/ui/dlg/TemplateScanner.cxx 
b/sd/source/ui/dlg/TemplateScanner.cxx
index 4afc801df5f2..5d302c26156f 100644
--- a/sd/source/ui/dlg/TemplateScanner.cxx
+++ b/sd/source/ui/dlg/TemplateScanner.cxx
@@ -141,15 +141,10 @@ TemplateScanner::State 
TemplateScanner::InitializeEntryScanning()
 {
 mxEntryEnvironment.clear();
 
+//  Create a cursor to iterate over the templates in this folders.
 //  We are interested only in three properties: the entry's name,
 //  its URL, and its content type.
-Sequence aProps (3);
-aProps[0] = TITLE;
-aProps[1] = "TargetURL";
-aProps[2] = "TypeDescription";
-
-//  Create a cursor to iterate over the templates in this folders.
-mxEntryResultSet.set( maFolderContent.createCursor(aProps, 
::ucbhelper::INCLUDE_DOCUMENTS_ONLY));
+mxEntryResultSet.set( maFolderContent.createCursor({ TITLE, 
"TargetURL", "TypeDescription" }, ::ucbhelper::INCLUDE_DOCUMENTS_ONLY));
 }
 else
 eNextState = ERROR;
@@ -218,13 +213,8 @@ TemplateScanner::State 
TemplateScanner::InitializeFolderScanning()
 mxFolderEnvironment.clear();
 ::ucbhelper::Content aTemplateDir (mxTemplateRoot, 
mxFolderEnvironment, comphelper::getProcessComponentContext());
 
-//  Define the list of properties we are interested in.
-Sequence aProps (2);
-aProps[0] = TITLE;
-aProps[1] = "TargetDirURL";
-
 //  Create a cursor to iterate over the template folders.
-mxFolderResultSet.set( aTemplateDir.createCursor(aProps, 
::ucbhelper::INCLUDE_FOLDERS_ONLY));
+mxFolderResultSet.set( aTemplateDir.createCursor({ TITLE, 
"TargetDirURL" }, ::ucbhelper::INCLUDE_FOLDERS_ONLY));
 if (mxFolderResultSet.is())
 eNextState = GATHER_FOLDER_LIST;
 }
diff --git a/sd/source/ui/presenter/PresenterCanvas.cxx 
b/sd/source/ui/presenter/PresenterCanvas.cxx
index f1f2271a1098..d657d6f37596 100644
--- a/sd/source/ui/presenter/PresenterCanvas.cxx
+++ b/sd/source/ui/presenter/PresenterCanvas.cxx
@@ -660,12 +660,15 @@ Reference 
PresenterCanvas::UpdateSpriteClip (
 else
 {
 // Create a new clip polygon from the window clip rectangle.
-Sequence > aPoints (1);
-aPoints[0] = Sequence(4);
-aPoints[0][0] = geometry::RealPoint2D(nMinX,nMinY);
-aPoints[0][1] = geometry::RealPoint2D(nMaxX,nMinY);
-aPoints[0][2] = geometry::RealPoint2D(nMaxX,nMaxY);
-aPoints[0][3] = geometry::RealPoint2D(nMinX,nMaxY);
+Sequence > aPoints
+{
+{
+{ nMinX,nMinY },
+{ nMaxX,nMinY },
+{ nMaxX,nMaxY },
+{ nMinX,nMaxY }
+}
+};
 Reference xLinePolygon(
 xDevice->createCompatibleLinePolyPolygon(aPoints));
 if (xLinePolygon.is())
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-09 Thread Julien Nabet (via logerrit)
 sccomp/qa/unit/SwarmSolverTest.cxx |   21 +++--
 sccomp/qa/unit/solver.cxx  |3 +--
 2 files changed, 8 insertions(+), 16 deletions(-)

New commits:
commit 5897a97bb53bcbf2283161cc22f43d87f575f3d6
Author: Julien Nabet 
AuthorDate: Wed Jun 9 18:14:41 2021 +0200
Commit: Julien Nabet 
CommitDate: Wed Jun 9 19:57:11 2021 +0200

Simplify Sequences initializations (sccomp)

Change-Id: I6316e1318ae1ee68e5d4e4529731bca0d1860b58
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116932
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sccomp/qa/unit/SwarmSolverTest.cxx 
b/sccomp/qa/unit/SwarmSolverTest.cxx
index b7d3becc475c..78cfccaaa376 100644
--- a/sccomp/qa/unit/SwarmSolverTest.cxx
+++ b/sccomp/qa/unit/SwarmSolverTest.cxx
@@ -75,8 +75,7 @@ void SwarmSolverTest::testUnconstrained()
 table::CellAddress aObjective(0, 1, 1);
 
 // "changing cells" - unknown variables
-uno::Sequence aVariables(1);
-aVariables[0] = table::CellAddress(0, 1, 0);
+uno::Sequence aVariables{ { 0, 1, 0 } };
 
 // constraints
 uno::Sequence aConstraints;
@@ -125,8 +124,7 @@ void SwarmSolverTest::testVariableBounded()
 table::CellAddress aObjective(0, 1, 1);
 
 // "changing cells" - unknown variables
-uno::Sequence aVariables(1);
-aVariables[0] = table::CellAddress(0, 1, 0);
+uno::Sequence aVariables{ { 0, 1, 0 } };
 
 // constraints
 uno::Sequence aConstraints(2);
@@ -177,8 +175,7 @@ void SwarmSolverTest::testVariableConstrained()
 table::CellAddress aObjective(0, 1, 1);
 
 // "changing cells" - unknown variables
-uno::Sequence aVariables(1);
-aVariables[0] = table::CellAddress(0, 1, 0);
+uno::Sequence aVariables{ { 0, 1, 0 } };
 
 // constraints
 uno::Sequence aConstraints(3);
@@ -233,9 +230,7 @@ void SwarmSolverTest::testTwoVariables()
 table::CellAddress aObjective(0, 1, 5);
 
 // "changing cells" - unknown variables
-uno::Sequence aVariables(2);
-aVariables[0] = table::CellAddress(0, 1, 2);
-aVariables[1] = table::CellAddress(0, 1, 3);
+uno::Sequence aVariables{ { 0, 1, 2 }, { 0, 1, 3 } };
 
 // constraints
 uno::Sequence aConstraints(4);
@@ -299,11 +294,9 @@ void SwarmSolverTest::testMultipleVariables()
 table::CellAddress aObjective(0, 5, 7);
 
 // "changing cells" - unknown variables
-uno::Sequence aVariables(4);
-aVariables[0] = table::CellAddress(0, 6, 1);
-aVariables[1] = table::CellAddress(0, 6, 2);
-aVariables[2] = table::CellAddress(0, 6, 3);
-aVariables[3] = table::CellAddress(0, 6, 4);
+uno::Sequence aVariables{
+{ 0, 6, 1 }, { 0, 6, 2 }, { 0, 6, 3 }, { 0, 6, 4 }
+};
 
 // constraints
 uno::Sequence aConstraints(12);
diff --git a/sccomp/qa/unit/solver.cxx b/sccomp/qa/unit/solver.cxx
index 4405279e26cb..eedbce69f274 100644
--- a/sccomp/qa/unit/solver.cxx
+++ b/sccomp/qa/unit/solver.cxx
@@ -87,8 +87,7 @@ void LpSolverTest::testSolver(OUString const & rName)
 table::CellAddress aObjective(0, 0, 0);
 
 // "changing cells" - unknown variables
-uno::Sequence aVariables(1);
-aVariables[0] = table::CellAddress(0, 0, 0);
+uno::Sequence aVariables { {0, 0, 0 } };
 
 // constraints
 uno::Sequence aConstraints(1);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-08 Thread Julien Nabet (via logerrit)
 comphelper/source/misc/accessiblekeybindinghelper.cxx|5 +
 connectivity/source/commontools/TPrivilegesResultSet.cxx |5 +
 connectivity/source/drivers/firebird/Catalog.cxx |4 +---
 connectivity/source/drivers/hsqldb/HCatalog.cxx  |4 +---
 connectivity/source/drivers/hsqldb/HStorageAccess.cxx|   12 +++-
 connectivity/source/drivers/hsqldb/HTables.cxx   |5 +
 connectivity/source/drivers/mysql_jdbc/YCatalog.cxx  |7 +++
 connectivity/source/drivers/mysql_jdbc/YTables.cxx   |7 +++
 connectivity/source/drivers/postgresql/pq_statics.cxx|4 +---
 connectivity/source/parse/sqliterator.cxx|5 +
 10 files changed, 20 insertions(+), 38 deletions(-)

New commits:
commit 6ef69234cf9138000a1dcf483114ea7c792fe3ed
Author: Julien Nabet 
AuthorDate: Tue Jun 8 10:16:31 2021 +0200
Commit: Julien Nabet 
CommitDate: Tue Jun 8 13:27:37 2021 +0200

Simplify Sequences initializations (comphelper+connectivity)

Change-Id: I8a91f4bd2a1117acb571f1058af18071bc058c9d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116815
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/comphelper/source/misc/accessiblekeybindinghelper.cxx 
b/comphelper/source/misc/accessiblekeybindinghelper.cxx
index 8028464aff2b..ce1203e42fcd 100644
--- a/comphelper/source/misc/accessiblekeybindinghelper.cxx
+++ b/comphelper/source/misc/accessiblekeybindinghelper.cxx
@@ -64,10 +64,7 @@ namespace comphelper
 void OAccessibleKeyBindingHelper::AddKeyBinding( const awt::KeyStroke& 
rKeyStroke )
 {
 ::osl::MutexGuard aGuard( m_aMutex );
-
-Sequence< awt::KeyStroke > aSeq(1);
-aSeq[0] = rKeyStroke;
-m_aKeyBindings.push_back( aSeq );
+m_aKeyBindings.push_back( { rKeyStroke } );
 }
 
 
diff --git a/connectivity/source/commontools/TPrivilegesResultSet.cxx 
b/connectivity/source/commontools/TPrivilegesResultSet.cxx
index de255d3cb8c1..54bfb37d7034 100644
--- a/connectivity/source/commontools/TPrivilegesResultSet.cxx
+++ b/connectivity/source/commontools/TPrivilegesResultSet.cxx
@@ -38,11 +38,8 @@ OResultSetPrivileges::OResultSetPrivileges( const Reference< 
XDatabaseMetaData>&
 osl_atomic_increment( _refCount );
 {
 OUString sUserWorkingFor;
-Sequence< OUString > sTableTypes(3);
 // we want all catalogues, all schemas, all tables
-sTableTypes[0] = "VIEW";
-sTableTypes[1] = "TABLE";
-sTableTypes[2] = "%"; // just to be sure to include anything else...
+Sequence< OUString > sTableTypes {"VIEW", "TABLE", "%"}; // this last 
one is just to be sure to include anything else...
 try
 {
 m_xTables = 
_rxMeta->getTables(catalog,schemaPattern,tableNamePattern,sTableTypes);
diff --git a/connectivity/source/drivers/firebird/Catalog.cxx 
b/connectivity/source/drivers/firebird/Catalog.cxx
index 47fedab60d59..90cec260 100644
--- a/connectivity/source/drivers/firebird/Catalog.cxx
+++ b/connectivity/source/drivers/firebird/Catalog.cxx
@@ -27,9 +27,7 @@ Catalog::Catalog(const uno::Reference< XConnection >& 
rConnection):
 //- OCatalog -
 void Catalog::refreshTables()
 {
-Sequence< OUString > aTypes(2);
-aTypes[0] = "TABLE";
-aTypes[1] = "VIEW";
+Sequence< OUString > aTypes {"TABLE", "VIEW"};
 
 uno::Reference< XResultSet > xTables = m_xMetaData->getTables(Any(),
 "%",
diff --git a/connectivity/source/drivers/hsqldb/HCatalog.cxx 
b/connectivity/source/drivers/hsqldb/HCatalog.cxx
index 029e60f9450a..1074be53559c 100644
--- a/connectivity/source/drivers/hsqldb/HCatalog.cxx
+++ b/connectivity/source/drivers/hsqldb/HCatalog.cxx
@@ -54,9 +54,7 @@ void OHCatalog::refreshTables()
 {
 ::std::vector< OUString> aVector;
 
-Sequence< OUString > sTableTypes(2);
-sTableTypes[0] = "VIEW";
-sTableTypes[1] = "TABLE";
+Sequence< OUString > sTableTypes {"VIEW", "TABLE"};
 
 refreshObjects(sTableTypes,aVector);
 
diff --git a/connectivity/source/drivers/hsqldb/HStorageAccess.cxx 
b/connectivity/source/drivers/hsqldb/HStorageAccess.cxx
index 91b8324008e3..4e939ad58603 100644
--- a/connectivity/source/drivers/hsqldb/HStorageAccess.cxx
+++ b/connectivity/source/drivers/hsqldb/HStorageAccess.cxx
@@ -463,11 +463,13 @@ void write_to_storage_stream( JNIEnv* env, jstring name, 
jstring key, jint v )
 {
 if ( xOut.is() )
 {
-Sequence< ::sal_Int8 > oneByte(4);
-oneByte[0] = static_cast((v >> 24) & 0xFF);
-oneByte[1] = static_cast((v >> 16) & 0xFF);
-oneByte[2] = static_cast((v >>  8) & 0xFF);
-oneByte[3] = static_cast((v >>  0) & 0xFF);
+Sequence< ::sal_Int8 > oneByte
+{
+static_cast((v >> 24) & 0xFF),
+

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

2021-06-08 Thread Julien Nabet (via logerrit)
 cppcanvas/source/mtfrenderer/polypolyaction.cxx |3 +--
 cppcanvas/source/wrapper/implbitmap.cxx |3 +--
 2 files changed, 2 insertions(+), 4 deletions(-)

New commits:
commit 46ea7c5d8be6b3e9436a44240117f83808d9d4c1
Author: Julien Nabet 
AuthorDate: Tue Jun 8 10:31:10 2021 +0200
Commit: Julien Nabet 
CommitDate: Tue Jun 8 13:20:39 2021 +0200

Simplify Sequences initializations (cppcanvas)

Change-Id: If2d882060422b4e450de9ddda28d8d5c624c8e24
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116816
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/cppcanvas/source/mtfrenderer/polypolyaction.cxx 
b/cppcanvas/source/mtfrenderer/polypolyaction.cxx
index 6d679cbd0a81..cc9fec338ca0 100644
--- a/cppcanvas/source/mtfrenderer/polypolyaction.cxx
+++ b/cppcanvas/source/mtfrenderer/polypolyaction.cxx
@@ -278,8 +278,7 @@ namespace cppcanvas::internal
 rendering::RenderState aLocalState( maState );
 ::canvas::tools::prependToRenderState(aLocalState, 
rTransformation);
 
-uno::Sequence< rendering::Texture > aSeq(1);
-aSeq[0] = maTexture;
+uno::Sequence< rendering::Texture > aSeq { maTexture };
 
 rCachedPrimitive = 
mpCanvas->getUNOCanvas()->fillTexturedPolyPolygon( mxPolyPoly,

   mpCanvas->getViewState(),
diff --git a/cppcanvas/source/wrapper/implbitmap.cxx 
b/cppcanvas/source/wrapper/implbitmap.cxx
index 9b7883f053a3..176fcd1cd849 100644
--- a/cppcanvas/source/wrapper/implbitmap.cxx
+++ b/cppcanvas/source/wrapper/implbitmap.cxx
@@ -84,8 +84,7 @@ namespace cppcanvas::internal
 }
 
 rendering::RenderState aLocalState( getRenderState() );
-uno::Sequence aCol(1);
-aCol[0] = rendering::ARGBColor( nAlphaModulation, 1.0, 1.0, 1.0 );
+uno::Sequence aCol { { nAlphaModulation, 
1.0, 1.0, 1.0 } };
 aLocalState.DeviceColor =
 
pCanvas->getUNOCanvas()->getDevice()->getDeviceColorSpace()->convertFromARGB(aCol);
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-18 Thread Julien Nabet (via logerrit)
 sc/uiconfig/scalc/ui/notebookbar.ui|4 ++--
 sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui |4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit c21398066b6bf630070ed291456f2663e06d94b9
Author: Julien Nabet 
AuthorDate: Tue Jun 15 22:06:48 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 18 19:38:18 2021 +0200

tdf#142873: Fix print preview zoom-out zoom-in buttons

.uno:ZoomOut has been renamed .uno:ZoomMinus
.uno:ZoomIn has been renamed .uno:ZoomPlus

Change-Id: I06e7e66550399e53032a0df39a98846982acba48
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117279
Tested-by: Jenkins
Reviewed-by: Jim Raykowski 

diff --git a/sc/uiconfig/scalc/ui/notebookbar.ui 
b/sc/uiconfig/scalc/ui/notebookbar.ui
index 3626b2da0dc0..ef2886b0d28f 100644
--- a/sc/uiconfig/scalc/ui/notebookbar.ui
+++ b/sc/uiconfig/scalc/ui/notebookbar.ui
@@ -15018,7 +15018,7 @@
   
 True
 False
-.uno:ZoomOut
+.uno:ZoomMinus
   
   
 False
@@ -15042,7 +15042,7 @@
   
 True
 False
-.uno:ZoomIn
+.uno:ZoomPlus
   
   
 False
diff --git a/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui 
b/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui
index 84f390bb5461..4ff33a943a9a 100644
--- a/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui
+++ b/sc/uiconfig/scalc/ui/notebookbar_groupedbar_compact.ui
@@ -11061,7 +11061,7 @@
   
 True
 False
-.uno:ZoomOut
+.uno:ZoomMinus
   
   
 False
@@ -11087,7 +11087,7 @@
   
 True
 False
-.uno:ZoomIn
+.uno:ZoomPlus
   
   
 False
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-11 Thread Julien Nabet (via logerrit)
 sc/qa/extras/scchartobj.cxx   |3 --
 sc/qa/extras/scchartsobj.cxx  |6 +---
 sc/qa/extras/scdatapilotfieldgroupitemobj.cxx |5 ---
 sc/qa/extras/scdatapilotfieldgroupobj.cxx |5 ---
 sc/qa/extras/scdatapilotfieldgroupsobj.cxx|5 ---
 sc/qa/extras/scindexenumeration_scenariosenumeration.cxx  |5 +--
 sc/qa/extras/scindexenumeration_subtotalfieldsenumeration.cxx |5 ---
 sc/qa/extras/scindexenumeration_tablechartsenumeration.cxx|6 +---
 sc/qa/extras/scscenariosobj.cxx   |4 --
 sc/qa/extras/sctablesheetobj.cxx  |9 ++
 sc/qa/perf/scperfobj.cxx  |4 --
 sc/source/core/data/dptabsrc.cxx  |8 ++---
 sc/source/filter/xml/xmlimprt.cxx |   15 ++
 sc/source/ui/Accessibility/AccessiblePreviewTable.cxx |4 +-
 sc/source/ui/docshell/docsh4.cxx  |3 --
 sc/source/ui/unoobj/appluno.cxx   |4 +-
 sc/source/ui/unoobj/cellsuno.cxx  |   14 -
 sc/source/ui/unoobj/chart2uno.cxx |3 --
 sc/source/ui/unoobj/chartuno.cxx  |2 -
 sc/source/ui/unoobj/condformatuno.cxx |8 +++--
 sc/source/ui/unoobj/dapiuno.cxx   |2 -
 sc/source/ui/unoobj/datauno.cxx   |2 -
 sc/source/ui/unoobj/fielduno.cxx  |3 --
 sc/source/ui/unoobj/nameuno.cxx   |2 -
 sc/source/ui/vba/vbachart.cxx |5 ---
 25 files changed, 53 insertions(+), 79 deletions(-)

New commits:
commit b1fe17f280b24e78e7ee55d4762dc64a98d6f302
Author: Julien Nabet 
AuthorDate: Wed Jun 9 17:28:19 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 11 14:54:14 2021 +0200

Simplify Sequences initializations (sc)

Change-Id: I0c581b3a900a6b89c0f4e203310d65600545987f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116929
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sc/qa/extras/scchartobj.cxx b/sc/qa/extras/scchartobj.cxx
index d5cd726f9164..04eaeba8131d 100644
--- a/sc/qa/extras/scchartobj.cxx
+++ b/sc/qa/extras/scchartobj.cxx
@@ -157,8 +157,7 @@ uno::Reference ScChartObj::init()
   uno::UNO_SET_THROW);
 uno::Reference xCRA(xCellRange1, 
uno::UNO_QUERY_THROW);
 
-uno::Sequence aCRA(1);
-aCRA[0] = xCRA->getRangeAddress();
+uno::Sequence aCRA{ xCRA->getRangeAddress() };
 
 uno::Reference xTCS(xSheet0, 
uno::UNO_QUERY_THROW);
 uno::Reference xTC = xTCS->getCharts();
diff --git a/sc/qa/extras/scchartsobj.cxx b/sc/qa/extras/scchartsobj.cxx
index 7424e1d68c76..0b85a2988d25 100644
--- a/sc/qa/extras/scchartsobj.cxx
+++ b/sc/qa/extras/scchartsobj.cxx
@@ -165,12 +165,10 @@ uno::Reference ScChartsObj::init()
   uno::UNO_SET_THROW);
 uno::Reference xCRA(xCellRange1, 
uno::UNO_QUERY_THROW);
 
-uno::Sequence aCRA(1);
-aCRA[0] = xCRA->getRangeAddress();
-
 uno::Reference xTCS(xSheet0, 
uno::UNO_QUERY_THROW);
 uno::Reference xTC = xTCS->getCharts();
-xTC->addNewByName("ScChartsObj", awt::Rectangle(500, 3000, 25000, 11000), 
aCRA, true, true);
+xTC->addNewByName("ScChartsObj", awt::Rectangle(500, 3000, 25000, 11000),
+  { xCRA->getRangeAddress() }, true, true);
 
 return xTC;
 }
diff --git a/sc/qa/extras/scdatapilotfieldgroupitemobj.cxx 
b/sc/qa/extras/scdatapilotfieldgroupitemobj.cxx
index e40170e5198c..6e0716020957 100644
--- a/sc/qa/extras/scdatapilotfieldgroupitemobj.cxx
+++ b/sc/qa/extras/scdatapilotfieldgroupitemobj.cxx
@@ -146,10 +146,7 @@ uno::Reference 
ScDataPilotFieldGroupItemObj::init()
 
 uno::Reference 
xDPFG(xIA_RF0->getByIndex(0),
  uno::UNO_QUERY_THROW);
-uno::Sequence aElements(2);
-aElements[0] = "aName";
-aElements[1] = "otherName";
-xDPFG->createNameGroup(aElements);
+xDPFG->createNameGroup({ "aName", "otherName" });
 
 uno::Reference 
xIA_DPT1(xDPTS->getDataPilotTables(),
  uno::UNO_QUERY_THROW);
diff --git a/sc/qa/extras/scdatapilotfieldgroupobj.cxx 
b/sc/qa/extras/scdatapilotfieldgroupobj.cxx
index 8fc85a85faea..f908dd160c6b 100644
--- a/sc/qa/extras/scdatapilotfieldgroupobj.cxx
+++ b/sc/qa/extras/scdatapilotfieldgroupobj.cxx
@@ -172,10 +172,7 @@ uno::Reference 
ScDataPilotFieldGroupObj::init()
 
 uno::Reference 
xDPFG(xIA_RF0->getByIndex(0),
  uno::UNO_QUERY_THROW);
-uno::Sequence 

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

2021-06-11 Thread Julien Nabet (via logerrit)
 sw/source/core/text/frmform.cxx |9 +++--
 sw/source/core/unocore/unofield.cxx |4 +---
 sw/source/core/unocore/unoframe.cxx |   15 ---
 sw/source/core/unocore/unoobj.cxx   |   30 +++---
 sw/source/core/unocore/unoparagraph.cxx |4 +---
 sw/source/filter/xml/xmlimp.cxx |   15 ++-
 sw/source/ui/dbui/dbinsdlg.cxx  |   27 +++
 sw/source/uibase/dbui/dbmgr.cxx |7 ---
 sw/source/uibase/docvw/srcedtw.cxx  |5 +
 sw/source/uibase/envelp/labelcfg.cxx|8 +---
 sw/source/uibase/uno/unotxvw.cxx|2 +-
 11 files changed, 48 insertions(+), 78 deletions(-)

New commits:
commit 76a69fb0bb1d849a2a7e76e209a30db149d79cdd
Author: Julien Nabet 
AuthorDate: Thu Jun 10 00:02:28 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 11 14:54:36 2021 +0200

Simplify Sequences initializations (sw)

Change-Id: I02647bdb720620afe20284a069a71c19dbfcea05
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116944
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sw/source/core/text/frmform.cxx b/sw/source/core/text/frmform.cxx
index 12a4492bbec7..82f2a8dcd893 100644
--- a/sw/source/core/text/frmform.cxx
+++ b/sw/source/core/text/frmform.cxx
@@ -517,9 +517,6 @@ void SwTextFrame::AdjustFrame( const SwTwips nChgHght, bool 
bHasToFit )
 
 css::uno::Sequence< css::style::TabStop > SwTextFrame::GetTabStopInfo( SwTwips 
CurrentPos )
 {
-css::uno::Sequence< css::style::TabStop > tabs(1);
-css::style::TabStop ts;
-
 SwTextFormatInfo aInf( getRootFrame()->GetCurrShell()->GetOut(), this 
);
 SwTextFormatter  aLine( this,  );
 SwTextCursor TextCursor( this,  );
@@ -533,10 +530,11 @@ css::uno::Sequence< css::style::TabStop > 
SwTextFrame::GetTabStopInfo( SwTwips C
 
 if( !pTS )
 {
-return css::uno::Sequence< css::style::TabStop >();
+return {};
 }
 
 // copy tab stop information into a Sequence, which only contains one 
element.
+css::style::TabStop ts;
 ts.Position = pTS->GetTabPos();
 ts.DecimalChar = pTS->GetDecimal();
 ts.FillChar = pTS->GetFill();
@@ -550,8 +548,7 @@ css::uno::Sequence< css::style::TabStop > 
SwTextFrame::GetTabStopInfo( SwTwips C
 default: break; // prevent warning
 }
 
-tabs[0] = ts;
-return tabs;
+return { ts };
 }
 
 // AdjustFollow expects the following situation:
diff --git a/sw/source/core/unocore/unofield.cxx 
b/sw/source/core/unocore/unofield.cxx
index 07a5b0bed2cc..a4f4cb597415 100644
--- a/sw/source/core/unocore/unofield.cxx
+++ b/sw/source/core/unocore/unofield.cxx
@@ -2336,9 +2336,7 @@ uno::Any SAL_CALL SwXTextField::getPropertyValue(const 
OUString& rPropertyName)
 break;
 case FN_UNO_ANCHOR_TYPES:
 {
-uno::Sequence aTypes(1);
-text::TextContentAnchorType* pArray = aTypes.getArray();
-pArray[0] = text::TextContentAnchorType_AS_CHARACTER;
+uno::Sequence aTypes { 
text::TextContentAnchorType_AS_CHARACTER };
 aRet <<= aTypes;
 }
 break;
diff --git a/sw/source/core/unocore/unoframe.cxx 
b/sw/source/core/unocore/unoframe.cxx
index e5c8fb7e1515..a430d92f5b7f 100644
--- a/sw/source/core/unocore/unoframe.cxx
+++ b/sw/source/core/unocore/unoframe.cxx
@@ -1988,13 +1988,14 @@ uno::Any SwXFrame::getPropertyValue(const OUString& 
rPropertyName)
 
 if(FN_UNO_ANCHOR_TYPES == pEntry->nWID)
 {
-uno::Sequence aTypes(5);
-text::TextContentAnchorType* pArray = aTypes.getArray();
-pArray[0] = text::TextContentAnchorType_AT_PARAGRAPH;
-pArray[1] = text::TextContentAnchorType_AS_CHARACTER;
-pArray[2] = text::TextContentAnchorType_AT_PAGE;
-pArray[3] = text::TextContentAnchorType_AT_FRAME;
-pArray[4] = text::TextContentAnchorType_AT_CHARACTER;
+uno::Sequence aTypes
+{
+text::TextContentAnchorType_AT_PARAGRAPH,
+text::TextContentAnchorType_AS_CHARACTER,
+text::TextContentAnchorType_AT_PAGE,
+text::TextContentAnchorType_AT_FRAME,
+text::TextContentAnchorType_AT_CHARACTER
+};
 aAny <<= aTypes;
 }
 else if(pFormat)
diff --git a/sw/source/core/unocore/unoobj.cxx 
b/sw/source/core/unocore/unoobj.cxx
index 56ad0c297eec..4cb772142e16 100644
--- a/sw/source/core/unocore/unoobj.cxx
+++ b/sw/source/core/unocore/unoobj.cxx
@@ -2527,9 +2527,6 @@ SwUnoCursorHelper::CreateSortDescriptor(const bool 
bFromTable)
 pArray[3] = beans::PropertyValue("MaxSortFieldsCount", -1, aVal,
 beans::PropertyState_DIRECT_VALUE);
 
-uno::Sequence< table::TableSortField > aFields(3);
-table::TableSortField* pFields = aFields.getArray();
-
 lang::Locale aLang( SvtSysLocale().GetLanguageTag().getLocale());
 // get collator algorithm to be used for the locale
 

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

2021-06-11 Thread Julien Nabet (via logerrit)
 svl/source/passwordcontainer/passwordcontainer.cxx |   20 
 1 file changed, 4 insertions(+), 16 deletions(-)

New commits:
commit f676b194faf2805529556c2f1da0578b58bf37de
Author: Julien Nabet 
AuthorDate: Thu Jun 10 12:42:07 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 11 14:57:08 2021 +0200

Simplify even more initializations in svl/passwordcontainer.cxx

Change-Id: I42cb919a8853df050d71b97f86abd20fdfccb5a6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116978
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/svl/source/passwordcontainer/passwordcontainer.cxx 
b/svl/source/passwordcontainer/passwordcontainer.cxx
index 99f94c5eb809..1181144ead22 100644
--- a/svl/source/passwordcontainer/passwordcontainer.cxx
+++ b/svl/source/passwordcontainer/passwordcontainer.cxx
@@ -231,11 +231,8 @@ PassMap StorageItem::getInfo()
 
 void StorageItem::setUseStorage( bool bUse )
 {
-Sequence< uno::Any > sendVals(1);
-sendVals[0] <<= bUse;
-
 ConfigItem::SetModified();
-ConfigItem::PutProperties( { "UseStorage" }, sendVals );
+ConfigItem::PutProperties( { "UseStorage" }, { uno::Any(bUse) } );
 }
 
 
@@ -289,14 +286,10 @@ bool StorageItem::getEncodedMP( OUString& aResult )
 
 void StorageItem::setEncodedMP( const OUString& aEncoded, bool bAcceptEmpty )
 {
-Sequence< uno::Any > sendVals(2);
-
 bool bHasMaster = ( !aEncoded.isEmpty() || bAcceptEmpty );
-sendVals[0] <<= bHasMaster;
-sendVals[1] <<= aEncoded;
 
 ConfigItem::SetModified();
-ConfigItem::PutProperties( { "HasMaster", "Master" }, sendVals );
+ConfigItem::PutProperties( { "HasMaster", "Master" }, { 
uno::Any(bHasMaster), uno::Any(aEncoded) } );
 
 hasEncoded = bHasMaster;
 mEncoded = aEncoded;
@@ -305,8 +298,7 @@ void StorageItem::setEncodedMP( const OUString& aEncoded, 
bool bAcceptEmpty )
 
 void StorageItem::remove( const OUString& aURL, const OUString& aName )
 {
-std::vector < OUString > forIndex { aURL, aName };
-Sequence< OUString > sendSeq { createIndex( forIndex ) };
+Sequence< OUString > sendSeq { createIndex( { aURL, aName } ) };
 
 ConfigItem::ClearNodeElements( "Store", sendSeq );
 }
@@ -326,13 +318,9 @@ void StorageItem::update( const OUString& aURL, const 
NamePassRecord& aRecord )
 return;
 }
 
-std::vector < OUString > forIndex;
-forIndex.push_back( aURL );
-forIndex.push_back( aRecord.GetUserName() );
-
 Sequence< beans::PropertyValue > sendSeq(1);
 
-sendSeq[0].Name  = "Store/Passwordstorage['" + createIndex( forIndex ) + 
"']/Password";
+sendSeq[0].Name  = "Store/Passwordstorage['" + createIndex( { aURL, 
aRecord.GetUserName() } ) + "']/Password";
 
 sendSeq[0].Value <<= aRecord.GetPersPasswords();
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-11 Thread Julien Nabet (via logerrit)
 unotools/source/config/fltrcfg.cxx |   19 +++
 unotools/source/i18n/calendarwrapper.cxx   |   10 +-
 unotools/source/i18n/localedatawrapper.cxx |   10 +-
 unotools/source/misc/ZipPackageHelper.cxx  |5 +
 unotools/source/ucbhelper/ucbhelper.cxx|5 +
 unotools/source/ucbhelper/ucblockbytes.cxx |4 +---
 6 files changed, 16 insertions(+), 37 deletions(-)

New commits:
commit 39b8ce7081888b5d5e73ba0b49396b09ca7f3b61
Author: Julien Nabet 
AuthorDate: Fri Jun 11 12:30:29 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 11 14:58:09 2021 +0200

Simplify Sequences initializations (unotools)

Change-Id: Ibc5deee4b69213310a75c2a74a800d99bc451424
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117047
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/unotools/source/config/fltrcfg.cxx 
b/unotools/source/config/fltrcfg.cxx
index c68ac827ee79..323cfe0c38ed 100644
--- a/unotools/source/config/fltrcfg.cxx
+++ b/unotools/source/config/fltrcfg.cxx
@@ -120,12 +120,7 @@ void SvtAppFilterOptions_Impl::Notify( const Sequence< 
OUString >&  )
 
 voidSvtAppFilterOptions_Impl::Load()
 {
-Sequence aNames(2);
-OUString* pNames = aNames.getArray();
-pNames[0] = "Load";
-pNames[1] = "Save";
-
-Sequence aValues = GetProperties(aNames);
+Sequence aValues = GetProperties({ "Load", "Save" });
 const Any* pValues = aValues.getConstArray();
 
 if(pValues[0].hasValue())
@@ -165,11 +160,7 @@ void SvtWriterFilterOptions_Impl::ImplCommit()
 {
 SvtAppFilterOptions_Impl::ImplCommit();
 
-Sequence aNames { "Executable" };
-Sequence aValues(1);
-aValues[0] <<= bLoadExecutable;
-
-PutProperties(aNames, aValues);
+PutProperties({ "Executable" }, { Any(bLoadExecutable) });
 }
 
 void SvtWriterFilterOptions_Impl::Load()
@@ -215,11 +206,7 @@ void SvtCalcFilterOptions_Impl::ImplCommit()
 {
 SvtAppFilterOptions_Impl::ImplCommit();
 
-Sequence aNames { "Executable" };
-Sequence aValues(1);
-aValues[0] <<= bLoadExecutable;
-
-PutProperties(aNames, aValues);
+PutProperties({ "Executable" }, { Any(bLoadExecutable) });
 }
 
 void SvtCalcFilterOptions_Impl::Load()
diff --git a/unotools/source/i18n/calendarwrapper.cxx 
b/unotools/source/i18n/calendarwrapper.cxx
index 5f4a1669bccf..7f0cc753a2c5 100644
--- a/unotools/source/i18n/calendarwrapper.cxx
+++ b/unotools/source/i18n/calendarwrapper.cxx
@@ -78,7 +78,7 @@ css::uno::Sequence< OUString > 
CalendarWrapper::getAllCalendars( const css::lang
 TOOLS_WARN_EXCEPTION( "unotools.i18n", "getAllCalendars" );
 }
 
-return css::uno::Sequence< OUString > (0);
+return {};
 }
 
 OUString CalendarWrapper::getUniqueID() const
@@ -247,7 +247,7 @@ css::uno::Sequence< css::i18n::CalendarItem2 > 
CalendarWrapper::getMonths() cons
 {
 TOOLS_WARN_EXCEPTION( "unotools.i18n", "getMonths" );
 }
-return css::uno::Sequence< css::i18n::CalendarItem2 > (0);
+return {};
 }
 
 css::uno::Sequence< css::i18n::CalendarItem2 > CalendarWrapper::getDays() const
@@ -261,7 +261,7 @@ css::uno::Sequence< css::i18n::CalendarItem2 > 
CalendarWrapper::getDays() const
 {
 TOOLS_WARN_EXCEPTION( "unotools.i18n", "getDays" );
 }
-return css::uno::Sequence< css::i18n::CalendarItem2 > (0);
+return {};
 }
 
 OUString CalendarWrapper::getDisplayName( sal_Int16 nCalendarDisplayIndex, 
sal_Int16 nIdx, sal_Int16 nNameType ) const
@@ -321,7 +321,7 @@ css::uno::Sequence< css::i18n::CalendarItem2 > 
CalendarWrapper::getGenitiveMonth
 {
 TOOLS_WARN_EXCEPTION( "unotools.i18n", "getGenitiveMonths" );
 }
-return css::uno::Sequence< css::i18n::CalendarItem2 > (0);
+return {};
 }
 
 css::uno::Sequence< css::i18n::CalendarItem2 > 
CalendarWrapper::getPartitiveMonths() const
@@ -335,7 +335,7 @@ css::uno::Sequence< css::i18n::CalendarItem2 > 
CalendarWrapper::getPartitiveMont
 {
 TOOLS_WARN_EXCEPTION( "unotools.i18n", "getPartitiveMonths" );
 }
-return css::uno::Sequence< css::i18n::CalendarItem2 > (0);
+return {};
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/unotools/source/i18n/localedatawrapper.cxx 
b/unotools/source/i18n/localedatawrapper.cxx
index 39e01f563392..2bb6769c51ed 100644
--- a/unotools/source/i18n/localedatawrapper.cxx
+++ b/unotools/source/i18n/localedatawrapper.cxx
@@ -169,7 +169,7 @@ void LocaleDataWrapper::loadData()
 catch (const Exception&)
 {
 TOOLS_WARN_EXCEPTION( "unotools.i18n", "getDateAcceptancePatterns" );
-aDateAcceptancePatterns = css::uno::Sequence< OUString >(0);
+aDateAcceptancePatterns = {};
 }
 
 
@@ -182,7 +182,7 @@ void LocaleDataWrapper::loadData()
 catch ( const Exception& )
 {
 TOOLS_WARN_EXCEPTION( "unotools.i18n", "getReservedWord" );
-aReservedWordSeq = css::uno::Sequence< OUString >(0);
+aReservedWordSeq = {};
 }
 for (int 

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

2021-06-11 Thread Julien Nabet (via logerrit)
 ucb/source/core/FileAccess.cxx  |   17 ++-
 ucb/source/core/provprox.cxx|4 --
 ucb/source/ucp/cmis/cmis_content.cxx|   46 +---
 ucb/source/ucp/file/bc.cxx  |   37 +++--
 ucb/source/ucp/file/filglob.cxx |4 --
 ucb/source/ucp/file/filinsreq.cxx   |4 --
 ucb/source/ucp/file/filrset.cxx |   15 +++---
 ucb/source/ucp/file/filtask.cxx |   32 +++---
 ucb/source/ucp/ftp/ftpcontent.cxx   |   18 +++-
 ucb/source/ucp/ftp/ftpresultsetbase.cxx |   18 
 ucb/source/ucp/gio/gio_content.cxx  |   32 +++---
 11 files changed, 74 insertions(+), 153 deletions(-)

New commits:
commit a75596f3f8d3660bd96a107eb13a2ea210be5b66
Author: Julien Nabet 
AuthorDate: Thu Jun 10 21:59:45 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 11 14:57:41 2021 +0200

Simplify Sequences initializations (ucb)

Change-Id: Idd38076a40b1177253719c01c1928da4c903151c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117017
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/ucb/source/core/FileAccess.cxx b/ucb/source/core/FileAccess.cxx
index c998318924ff..8e93248bd192 100644
--- a/ucb/source/core/FileAccess.cxx
+++ b/ucb/source/core/FileAccess.cxx
@@ -364,15 +364,10 @@ void OFileAccess::createFolder( const OUString& 
NewFolderURL )
 if ( rProps[ 0 ].Name != "Title" )
 continue;
 
-Sequence aNames { "Title" };
-Sequence< Any > aValues(1);
-Any* pValues = aValues.getArray();
-pValues[0] <<= aTitle;
-
 ucbhelper::Content aNew;
 try
 {
-if ( !aCnt.insertNewContent( rCurr.Type, aNames, aValues, aNew 
) )
+if ( !aCnt.insertNewContent( rCurr.Type, { "Title" }, { 
Any(aTitle) }, aNew ) )
 continue;
 
 // Success. We're done.
@@ -429,13 +424,12 @@ Sequence< OUString > OFileAccess::getFolderContents( 
const OUString& FolderURL,
 
 ucbhelper::Content aCnt( aFolderObj.GetMainURL( 
INetURLObject::DecodeMechanism::NONE ), mxEnvironment, 
comphelper::getProcessComponentContext() );
 Reference< XResultSet > xResultSet;
-Sequence< OUString > aProps(0);
 
 ucbhelper::ResultSetInclude eInclude = bIncludeFolders ? 
ucbhelper::INCLUDE_FOLDERS_AND_DOCUMENTS : ucbhelper::INCLUDE_DOCUMENTS_ONLY;
 
 try
 {
-xResultSet = aCnt.createCursor( aProps, eInclude );
+xResultSet = aCnt.createCursor( {}, eInclude );
 }
 catch ( css::ucb::CommandFailedException const & )
 {
@@ -598,16 +592,11 @@ bool OFileAccess::createNewFile( const OUString & 
rParentURL,
 if ( rProps[ 0 ].Name != "Title" )
 continue;
 
-Sequence aNames { "Title" };
-Sequence< Any > aValues(1);
-Any* pValues = aValues.getArray();
-pValues[0] <<= rTitle;
-
 try
 {
 ucbhelper::Content aNew;
 if ( aParentCnt.insertNewContent(
- rCurr.Type, aNames, aValues, data, aNew ) )
+ rCurr.Type, { "Title" }, { Any(rTitle) }, data, aNew 
) )
 return true; // success.
 else
 continue;
diff --git a/ucb/source/core/provprox.cxx b/ucb/source/core/provprox.cxx
index 337a1d8f1c42..379b6e4887ed 100644
--- a/ucb/source/core/provprox.cxx
+++ b/ucb/source/core/provprox.cxx
@@ -306,9 +306,7 @@ UcbContentProviderProxy::getContentProvider()
 {
 Reference xInit(m_xProvider,UNO_QUERY);
 if(xInit.is()) {
-Sequence aArgs(1);
-aArgs[0] <<= m_aArguments;
-xInit->initialize(aArgs);
+xInit->initialize({ Any(m_aArguments) });
 }
 }
 }
diff --git a/ucb/source/ucp/cmis/cmis_content.cxx 
b/ucb/source/ucp/cmis/cmis_content.cxx
index e29afbf72ae5..aa7628199a8c 100644
--- a/ucb/source/ucp/cmis/cmis_content.cxx
+++ b/ucb/source/ucp/cmis/cmis_content.cxx
@@ -1969,28 +1969,32 @@ namespace cmis
 {
 if ( isFolder( xEnv ) )
 {
-uno::Sequence< ucb::ContentInfo > seq(2);
 
 // Minimum set of props we really need
-uno::Sequence< beans::Property > props( 1 );
-props[0] = beans::Property(
-"Title",
--1,
-cppu::UnoType::get(),
-beans::PropertyAttribute::MAYBEVOID | 
beans::PropertyAttribute::BOUND );
-
-// file
-seq[0].Type   =  CMIS_FILE_TYPE;
-seq[0].Attributes = ( 
ucb::ContentInfoAttribute::INSERT_WITH_INPUTSTREAM |
-  

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

2021-06-08 Thread Julien Nabet (via logerrit)
 cui/source/customize/SvxNotebookbarConfigPage.cxx |3 +--
 cui/source/customize/SvxToolbarConfigPage.cxx |9 -
 2 files changed, 5 insertions(+), 7 deletions(-)

New commits:
commit b32520f3e6b4ec4868d6e94d6fc20abb283c8308
Author: Julien Nabet 
AuthorDate: Tue Jun 8 12:44:41 2021 +0200
Commit: Julien Nabet 
CommitDate: Tue Jun 8 17:07:06 2021 +0200

Simplify Sequences initializations (cui)

Change-Id: Iaf6a27f3a8dd156e91751a2fe242e8388f8d6b6c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116829
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/cui/source/customize/SvxNotebookbarConfigPage.cxx 
b/cui/source/customize/SvxNotebookbarConfigPage.cxx
index 978055e1a1bc..16d555a9a2e7 100644
--- a/cui/source/customize/SvxNotebookbarConfigPage.cxx
+++ b/cui/source/customize/SvxNotebookbarConfigPage.cxx
@@ -516,8 +516,7 @@ void SvxNotebookbarEntriesListBox::ChangedVisibility(int 
nRow)
 else
 sVisible = "False";
 OUString sSetEntries = sUIItemId + ",visible," + sVisible;
-Sequence sSeqOfEntries(1);
-sSeqOfEntries[0] = sSetEntries;
+Sequence sSeqOfEntries{ sSetEntries };
 EditRegistryFile(sUIItemId, sSetEntries, sNotebookbarInterface);
 CustomNotebookbarGenerator::modifyCustomizedUIFile(sSeqOfEntries);
 OUString sUIPath = "modules/s" + m_pPage->GetAppName().toAsciiLowerCase() 
+ "/ui/";
diff --git a/cui/source/customize/SvxToolbarConfigPage.cxx 
b/cui/source/customize/SvxToolbarConfigPage.cxx
index 57f78dcd6161..99a85d82f96e 100644
--- a/cui/source/customize/SvxToolbarConfigPage.cxx
+++ b/cui/source/customize/SvxToolbarConfigPage.cxx
@@ -508,8 +508,6 @@ IMPL_LINK(SvxToolbarConfigPage, ModifyItemHdl, const 
OString&, rIdent, void)
 
 if (newgraphic.is())
 {
-
css::uno::Sequence> aGraphicSeq(1);
-
 css::uno::Sequence aURLSeq{ pEntry->GetCommand() };
 
 if (!pEntry->GetBackupGraphic().is())
@@ -524,7 +522,9 @@ IMPL_LINK(SvxToolbarConfigPage, ModifyItemHdl, const 
OString&, rIdent, void)
 }
 }
 
-aGraphicSeq[0] = newgraphic;
+
css::uno::Sequence> aGraphicSeq{
+newgraphic
+};
 try
 {
 GetSaveInData()->GetImageManager()->replaceImages(
@@ -558,8 +558,7 @@ IMPL_LINK(SvxToolbarConfigPage, ModifyItemHdl, const 
OString&, rIdent, void)
 
 css::uno::Reference backup = 
pEntry->GetBackupGraphic();
 
-css::uno::Sequence> 
aGraphicSeq(1);
-aGraphicSeq[0] = backup;
+css::uno::Sequence> 
aGraphicSeq{ backup };
 
 css::uno::Sequence aURLSeq{ pEntry->GetCommand() };
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: desktop/source embeddedobj/source embeddedobj/test eventattacher/source filter/source forms/source formula/source fpicker/source

2021-06-08 Thread Julien Nabet (via logerrit)
 desktop/source/deployment/gui/dp_gui_updatedialog.cxx |   15 ++--
 embeddedobj/source/msole/oleembed.cxx |4 ---
 embeddedobj/test/mtexecutor/bitmapcreator.cxx |9 ---
 embeddedobj/test/mtexecutor/mainthreadexecutor.cxx|9 ---
 eventattacher/source/eventattacher.cxx|3 --
 filter/source/msfilter/mstoolbar.cxx  |3 --
 filter/source/pdf/pdfdecomposer.cxx   |7 +-
 filter/source/xsltdialog/xmlfiltersettingsdialog.cxx  |   21 --
 forms/source/component/ListBox.cxx|   20 -
 formula/source/ui/dlg/formula.cxx |   13 +++
 fpicker/source/office/iodlg.cxx   |4 ---
 11 files changed, 48 insertions(+), 60 deletions(-)

New commits:
commit c7a9a1dbe2b30afb564953ce1e856b95e3ec9436
Author: Julien Nabet 
AuthorDate: Tue Jun 8 13:35:11 2021 +0200
Commit: Julien Nabet 
CommitDate: Tue Jun 8 17:08:06 2021 +0200

Simplify Sequences initializations (desktop/e*/filter/forms/formula/fpicker)

includes removing of unused TOKEN_SEP

Change-Id: Ic72d9d94bd8d07232699ee4d948f3b203d524491
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116833
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/desktop/source/deployment/gui/dp_gui_updatedialog.cxx 
b/desktop/source/deployment/gui/dp_gui_updatedialog.cxx
index 1e48fa7182f8..ae47ec42b22f 100644
--- a/desktop/source/deployment/gui/dp_gui_updatedialog.cxx
+++ b/desktop/source/deployment/gui/dp_gui_updatedialog.cxx
@@ -664,24 +664,25 @@ void UpdateDialog::notifyMenubar( bool bPrepareOnly, bool 
bRecheckOnly )
 sal_Int32 nCount = 0;
 for (sal_uInt16 i = 0, nItemCount = m_xUpdates->n_children(); i < 
nItemCount; ++i)
 {
-uno::Sequence< OUString > aItem(2);
 
 UpdateDialog::Index const * p = reinterpret_cast< 
UpdateDialog::Index const * >(m_xUpdates->get_id(i).toInt64());
 
 if ( p->m_eKind == ENABLED_UPDATE )
 {
 dp_gui::UpdateData aUpdData = m_enabledUpdates[ p->m_nIndex ];
-aItem[0] = dp_misc::getIdentifier( aUpdData.aInstalledPackage 
);
 
 dp_misc::DescriptionInfoset aInfoset( m_context, 
aUpdData.aUpdateInfo );
-aItem[1] = aInfoset.getVersion();
+uno::Sequence< OUString > aItem
+{
+dp_misc::getIdentifier( aUpdData.aInstalledPackage ),
+aInfoset.getVersion()
+};
+aItemList.realloc( nCount + 1 );
+aItemList[ nCount ] = aItem;
+nCount += 1;
 }
 else
 continue;
-
-aItemList.realloc( nCount + 1 );
-aItemList[ nCount ] = aItem;
-nCount += 1;
 }
 }
 
diff --git a/embeddedobj/source/msole/oleembed.cxx 
b/embeddedobj/source/msole/oleembed.cxx
index 926f5b9e9393..8c23a4429895 100644
--- a/embeddedobj/source/msole/oleembed.cxx
+++ b/embeddedobj/source/msole/oleembed.cxx
@@ -91,9 +91,7 @@ void OleEmbeddedObject::SwitchComponentToRunningState_Impl()
 uno::Sequence< sal_Int32 > OleEmbeddedObject::GetReachableStatesList_Impl(
 const uno::Sequence< 
embed::VerbDescriptor >& aVerbList )
 {
-uno::Sequence< sal_Int32 > aStates(2);
-aStates[0] = embed::EmbedStates::LOADED;
-aStates[1] = embed::EmbedStates::RUNNING;
+uno::Sequence< sal_Int32 > aStates { embed::EmbedStates::LOADED, 
embed::EmbedStates::RUNNING };
 for ( embed::VerbDescriptor const & vd : aVerbList )
 if ( vd.VerbID == embed::EmbedVerbs::MS_OLEVERB_OPEN )
 {
diff --git a/embeddedobj/test/mtexecutor/bitmapcreator.cxx 
b/embeddedobj/test/mtexecutor/bitmapcreator.cxx
index 458c085ae111..60a89f8cd078 100644
--- a/embeddedobj/test/mtexecutor/bitmapcreator.cxx
+++ b/embeddedobj/test/mtexecutor/bitmapcreator.cxx
@@ -29,10 +29,11 @@ using namespace ::com::sun::star;
 
 uno::Sequence< OUString > SAL_CALL 
VCLBitmapCreator::impl_staticGetSupportedServiceNames()
 {
-uno::Sequence< OUString > aRet(2);
-aRet[0] = "com.sun.star.embed.BitmapCreator";
-aRet[1] = "com.sun.star.comp.embed.BitmapCreator";
-return aRet;
+return
+{
+"com.sun.star.embed.BitmapCreator",
+"com.sun.star.comp.embed.BitmapCreator"
+};
 }
 
 
diff --git a/embeddedobj/test/mtexecutor/mainthreadexecutor.cxx 
b/embeddedobj/test/mtexecutor/mainthreadexecutor.cxx
index 1fc7d2e3cc31..82a124a2c969 100644
--- a/embeddedobj/test/mtexecutor/mainthreadexecutor.cxx
+++ b/embeddedobj/test/mtexecutor/mainthreadexecutor.cxx
@@ -27,10 +27,11 @@ using namespace ::com::sun::star;
 
 uno::Sequence< OUString > SAL_CALL 
MainThreadExecutor::impl_staticGetSupportedServiceNames()
 {
-uno::Sequence< OUString > aRet(2);
-aRet[0] = 

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

2021-06-08 Thread Julien Nabet (via logerrit)
 dbaccess/source/core/dataaccess/datasource.cxx|5 +--
 dbaccess/source/core/dataaccess/documentcontainer.cxx |   11 ---
 dbaccess/source/ui/browser/unodatbr.cxx   |   26 +-
 dbaccess/source/ui/control/sqledit.cxx|4 --
 dbaccess/source/ui/dlg/CollectionView.cxx |4 --
 5 files changed, 18 insertions(+), 32 deletions(-)

New commits:
commit af8dc07bfdf5d6e7bd2278305cd39ed269e50ed7
Author: Julien Nabet 
AuthorDate: Tue Jun 8 12:57:35 2021 +0200
Commit: Julien Nabet 
CommitDate: Tue Jun 8 17:07:46 2021 +0200

Simplify Sequences initializations (dbaccess)

Change-Id: I38ecf7f13a853909fc746ee9bf1167f9c15cbc5f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116832
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/dbaccess/source/core/dataaccess/datasource.cxx 
b/dbaccess/source/core/dataaccess/datasource.cxx
index e560d75040b0..9ce895bae875 100644
--- a/dbaccess/source/core/dataaccess/datasource.cxx
+++ b/dbaccess/source/core/dataaccess/datasource.cxx
@@ -219,9 +219,8 @@ void SAL_CALL OAuthenticationContinuation::setPassword( 
const OUString& _rPasswo
 
 Sequence< RememberAuthentication > SAL_CALL 
OAuthenticationContinuation::getRememberPasswordModes( RememberAuthentication& 
_reDefault )
 {
-Sequence< RememberAuthentication > aReturn(1);
-_reDefault = aReturn[0] = RememberAuthentication_SESSION;
-return aReturn;
+_reDefault = RememberAuthentication_SESSION;
+return { _reDefault };
 }
 
 void SAL_CALL OAuthenticationContinuation::setRememberPassword( 
RememberAuthentication _eRemember )
diff --git a/dbaccess/source/core/dataaccess/documentcontainer.cxx 
b/dbaccess/source/core/dataaccess/documentcontainer.cxx
index 9d88d27222f5..472f60ad566f 100644
--- a/dbaccess/source/core/dataaccess/documentcontainer.cxx
+++ b/dbaccess/source/core/dataaccess/documentcontainer.cxx
@@ -372,11 +372,12 @@ Reference< XInterface > SAL_CALL 
ODocumentContainer::createInstanceWithArguments
 
 Sequence< OUString > SAL_CALL ODocumentContainer::getAvailableServiceNames(  )
 {
-Sequence< OUString > aSe(3);
-aSe[0] = SERVICE_SDB_DOCUMENTDEFINITION;
-aSe[1] = SERVICE_NAME_FORM_COLLECTION;
-aSe[2] = SERVICE_NAME_REPORT_COLLECTION;
-return aSe;
+return
+{
+SERVICE_SDB_DOCUMENTDEFINITION,
+SERVICE_NAME_FORM_COLLECTION,
+SERVICE_NAME_REPORT_COLLECTION
+};
 }
 
 Any SAL_CALL ODocumentContainer::execute( const Command& aCommand, sal_Int32 
CommandId, const Reference< XCommandEnvironment >& Environment )
diff --git a/dbaccess/source/ui/browser/unodatbr.cxx 
b/dbaccess/source/ui/browser/unodatbr.cxx
index db5bec8c6428..e8c1c1f5920b 100644
--- a/dbaccess/source/ui/browser/unodatbr.cxx
+++ b/dbaccess/source/ui/browser/unodatbr.cxx
@@ -3147,24 +3147,14 @@ void SbaTableQueryBrowser::impl_initialize()
 {
 try
 {
-Sequence< OUString> aProperties(5);
-Sequence< Any> aValues(5);
-
-OUString* pStringIter = aProperties.getArray();
-Any* pValueIter = aValues.getArray();
-*pStringIter++  = "AlwaysShowCursor";
-*pValueIter++   <<= false;
-*pStringIter++  = PROPERTY_BORDER;
-*pValueIter++   <<= sal_Int16(0);
-
-*pStringIter++  = "HasNavigationBar";
-*pValueIter++   <<= false;
-*pStringIter++  = "HasRecordMarker";
-*pValueIter++   <<= false;
-
-*pStringIter++  = "Tabstop";
-*pValueIter++   <<= false;
-
+Sequence< OUString> aProperties
+{
+"AlwaysShowCursor", PROPERTY_BORDER, "HasNavigationBar", 
"HasRecordMarker", "Tabstop"
+};
+Sequence< Any> aValues
+{
+Any(false), Any(sal_Int16(0)), Any(false), Any(false), 
Any(false)
+};
 Reference< XMultiPropertySet >  xFormMultiSet(getFormComponent(), 
UNO_QUERY);
 if ( xFormMultiSet.is() )
 xFormMultiSet->setPropertyValues(aProperties, aValues);
diff --git a/dbaccess/source/ui/control/sqledit.cxx 
b/dbaccess/source/ui/control/sqledit.cxx
index 062f99e96cae..c53f684dab4a 100644
--- a/dbaccess/source/ui/control/sqledit.cxx
+++ b/dbaccess/source/ui/control/sqledit.cxx
@@ -142,9 +142,7 @@ void SQLEditView::SetDrawingArea(weld::DrawingArea* 
pDrawingArea)
 osl::MutexGuard g(m_mutex);
 m_notifier = n;
 }
-css::uno::Sequence< OUString > s(2);
-s[0] = "FontHeight";
-s[1] = "FontName";
+css::uno::Sequence< OUString > s { "FontHeight", "FontName" };
 n->addPropertiesChangeListener(s, m_listener);
 m_ColorConfig.AddListener(this);
 }
diff --git a/dbaccess/source/ui/dlg/CollectionView.cxx 
b/dbaccess/source/ui/dlg/CollectionView.cxx
index 77dd170785b2..75973ad1e780 100644
--- a/dbaccess/source/ui/dlg/CollectionView.cxx
+++ b/dbaccess/source/ui/dlg/CollectionView.cxx

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

2021-06-11 Thread Julien Nabet (via logerrit)
 vcl/qa/cppunit/canvasbitmaptest.cxx |   28 ++--
 vcl/source/gdi/print.cxx|4 +---
 vcl/source/helper/canvastools.cxx   |   25 +
 3 files changed, 32 insertions(+), 25 deletions(-)

New commits:
commit 771c8282aadb45373fc6348cc70f4cd75a43a396
Author: Julien Nabet 
AuthorDate: Fri Jun 11 14:20:45 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri Jun 11 15:32:10 2021 +0200

Simplify Sequences initializations (vcl)

Change-Id: Id93bde17dbc4c71ad93bc094b94408fc9e39ec98
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117055
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/vcl/qa/cppunit/canvasbitmaptest.cxx 
b/vcl/qa/cppunit/canvasbitmaptest.cxx
index d77599e7b8a4..9b50282ee8b0 100644
--- a/vcl/qa/cppunit/canvasbitmaptest.cxx
+++ b/vcl/qa/cppunit/canvasbitmaptest.cxx
@@ -216,19 +216,27 @@ void checkCanvasBitmap( const 
rtl::Reference& xBmp,
 if( nOriginalDepth <= 8 )
 return;
 
-uno::Sequence aARGBColor(1);
-uno::Sequence  aRGBColor(1);
 uno::Sequence aPixel3, aPixel4;
 
 const Color aCol(COL_GREEN);
-aARGBColor[0].Red   = vcl::unotools::toDoubleColor(aCol.GetRed());
-aARGBColor[0].Green = vcl::unotools::toDoubleColor(aCol.GetGreen());
-aARGBColor[0].Blue  = vcl::unotools::toDoubleColor(aCol.GetBlue());
-aARGBColor[0].Alpha = 1.0;
-
-aRGBColor[0].Red   = vcl::unotools::toDoubleColor(aCol.GetRed());
-aRGBColor[0].Green = vcl::unotools::toDoubleColor(aCol.GetGreen());
-aRGBColor[0].Blue  = vcl::unotools::toDoubleColor(aCol.GetBlue());
+uno::Sequence aARGBColor
+{
+{
+1.0,
+vcl::unotools::toDoubleColor(aCol.GetRed()),
+vcl::unotools::toDoubleColor(aCol.GetGreen()),
+vcl::unotools::toDoubleColor(aCol.GetBlue())
+}
+};
+
+uno::Sequence  aRGBColor
+{
+{
+vcl::unotools::toDoubleColor(aCol.GetRed()),
+vcl::unotools::toDoubleColor(aCol.GetGreen()),
+vcl::unotools::toDoubleColor(aCol.GetBlue())
+}
+};
 
 aPixel3 = xBmp->convertIntegerFromARGB( aARGBColor );
 aPixel4 = xBmp->getPixel( aLayout, geometry::IntegerPoint2D(5,0) );
diff --git a/vcl/source/gdi/print.cxx b/vcl/source/gdi/print.cxx
index d7928956e9bd..652bc00c58be 100644
--- a/vcl/source/gdi/print.cxx
+++ b/vcl/source/gdi/print.cxx
@@ -123,17 +123,15 @@ void PrinterOptions::ReadFromConfig( bool i_bFile )
 {
 xConfigProvider = css::configuration::theDefaultProvider::get( 
xContext );
 
-css::uno::Sequence< css::uno::Any > aArgs(1);
 css::beans::PropertyValue aVal;
 aVal.Name = "nodepath";
 if( i_bFile )
 aVal.Value <<= OUString( 
"/org.openoffice.Office.Common/Print/Option/File" );
 else
 aVal.Value <<= OUString( 
"/org.openoffice.Office.Common/Print/Option/Printer" );
-aArgs.getArray()[0] <<= aVal;
 xConfigAccess.set(
 xConfigProvider->createInstanceWithArguments(
-"com.sun.star.configuration.ConfigurationAccess", 
aArgs ),
+"com.sun.star.configuration.ConfigurationAccess", { 
css::uno::Any(aVal) } ),
 css::uno::UNO_QUERY );
 if( xConfigAccess.is() )
 {
diff --git a/vcl/source/helper/canvastools.cxx 
b/vcl/source/helper/canvastools.cxx
index fef5500a8227..c547dace4a14 100644
--- a/vcl/source/helper/canvastools.cxx
+++ b/vcl/source/helper/canvastools.cxx
@@ -565,15 +565,13 @@ namespace vcl::unotools
 
 uno::Sequence< double > colorToStdColorSpaceSequence( const Color& 
rColor )
 {
-uno::Sequence< double > aRet(4);
-double* pRet = aRet.getArray();
-
-pRet[0] = toDoubleColor(rColor.GetRed());
-pRet[1] = toDoubleColor(rColor.GetGreen());
-pRet[2] = toDoubleColor(rColor.GetBlue());
-pRet[3] = toDoubleColor(rColor.GetAlpha());
-
-return aRet;
+return
+{
+toDoubleColor(rColor.GetRed()),
+toDoubleColor(rColor.GetGreen()),
+toDoubleColor(rColor.GetBlue()),
+toDoubleColor(rColor.GetAlpha())
+};
 }
 
 Color stdColorSpaceSequenceToColor( const uno::Sequence< double >& 
rColor)
@@ -595,12 +593,15 @@ namespace vcl::unotools
 const Color&rColor,
 const uno::Reference< rendering::XColorSpace >& xColorSpace )
 {
-uno::Sequence aSeq(1);
-aSeq[0] = rendering::ARGBColor(
+uno::Sequence aSeq
+{
+{
 toDoubleColor(rColor.GetAlpha()),
 toDoubleColor(rColor.GetRed()),
 toDoubleColor(rColor.GetGreen()),
-

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

2021-05-14 Thread Julien Nabet (via logerrit)
 sfx2/source/devtools/ObjectInspectorTreeHandler.cxx |   17 +
 1 file changed, 5 insertions(+), 12 deletions(-)

New commits:
commit c76e184ca1448c15f2f5fb059a51c2b483d0e387
Author: Julien Nabet 
AuthorDate: Fri May 14 09:50:31 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 11:07:17 2021 +0200

Directly initialize vectors in sfx2/ObjectInspectorTreeHandler

since we've got all the information from the beginning.

The static_cast is to fix this error:

/home/julien/lo/libreoffice/sfx2/source/devtools/ObjectInspectorTreeHandler.cxx:976:39:
 error: type 'float' cannot be narrowed to 'int' in initializer list 
[-Wc++11-narrowing]
std::vector aMethodsWidths { nMethodsDigitWidth * 30, 
nMethodsDigitWidth * 15,
  ^~~

/home/julien/lo/libreoffice/sfx2/source/devtools/ObjectInspectorTreeHandler.cxx:976:39:
 note: insert an explicit cast to silence this issue
std::vector aMethodsWidths { nMethodsDigitWidth * 30, 
nMethodsDigitWidth * 15,
  ^~~
  static_cast(  )

Change-Id: I7d59d947bd54bf97dd559b6813cabd3ea4216efe
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115582
Reviewed-by: Gülşah Köse 
Reviewed-by: Julien Nabet 
Tested-by: Jenkins

diff --git a/sfx2/source/devtools/ObjectInspectorTreeHandler.cxx 
b/sfx2/source/devtools/ObjectInspectorTreeHandler.cxx
index 4915917ee087..204cdb3c9319 100644
--- a/sfx2/source/devtools/ObjectInspectorTreeHandler.cxx
+++ b/sfx2/source/devtools/ObjectInspectorTreeHandler.cxx
@@ -968,20 +968,13 @@ ObjectInspectorTreeHandler::ObjectInspectorTreeHandler(
 
 auto nPropertiesDigitWidth
 = 
mpObjectInspectorWidgets->mpPropertiesTreeView->get_approximate_digit_width();
-std::vector aPropertiesWidths;
-aPropertiesWidths.push_back(nPropertiesDigitWidth * 30);
-aPropertiesWidths.push_back(nPropertiesDigitWidth * 30);
-aPropertiesWidths.push_back(nPropertiesDigitWidth * 30);
-aPropertiesWidths.push_back(nPropertiesDigitWidth * 30);
+std::vector aPropertiesWidths(4, nPropertiesDigitWidth * 30);
 
mpObjectInspectorWidgets->mpPropertiesTreeView->set_column_fixed_widths(aPropertiesWidths);
 
-auto nMethodsDigitWidth
-= 
mpObjectInspectorWidgets->mpMethodsTreeView->get_approximate_digit_width();
-std::vector aMethodsWidths;
-aMethodsWidths.push_back(nMethodsDigitWidth * 30);
-aMethodsWidths.push_back(nMethodsDigitWidth * 15);
-aMethodsWidths.push_back(nMethodsDigitWidth * 30);
-aMethodsWidths.push_back(nMethodsDigitWidth * 50);
+auto nMethodsDigitWidth = static_cast(
+
mpObjectInspectorWidgets->mpMethodsTreeView->get_approximate_digit_width());
+std::vector aMethodsWidths{ nMethodsDigitWidth * 30, 
nMethodsDigitWidth * 15,
+ nMethodsDigitWidth * 30, 
nMethodsDigitWidth * 50 };
 
mpObjectInspectorWidgets->mpMethodsTreeView->set_column_fixed_widths(aMethodsWidths);
 
 pObjectInspectorWidgets->mpPaned->set_position(160);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-14 Thread Julien Nabet (via logerrit)
 vcl/source/edit/texteng.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 10bacbcc5ed91a195c74140e05b953f62e46afe7
Author: Julien Nabet 
AuthorDate: Thu May 13 12:18:02 2021 +0200
Commit: Noel Grandin 
CommitDate: Fri May 14 08:47:56 2021 +0200

Fix assertion in vcl/texteng

Insert macro from https://bugs.documentfoundation.org/show_bug.cgi?id=94024 
and start
I got this bt:
0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
1  0x7f39e2b61537 in __GI_abort () at abort.c:79
2  0x7f39e2b6140f in __assert_fail_base
   (fmt=0x7f39e2cca128 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", 
assertion=0x7f39db29740e "index >= 0 && static_cast(index) < 
static_cast(getLength())", file=0x7f39db27f997 
"/home/julien/lo/libreoffice/include/rtl/ustring.hxx", line=794, 
function=) at assert.c:92
3  0x7f39e2b70662 in __GI___assert_fail
   (assertion=0x7f39db29740e "index >= 0 && static_cast(index) 
< static_cast(getLength())", file=0x7f39db27f997 
"/home/julien/lo/libreoffice/include/rtl/ustring.hxx", line=794, 
function=0x7f39db2bada5 "sal_Unicode rtl::OUString::operator[](sal_Int32) 
const") at assert.c:101
4  0x7f39da1fe3c4 in rtl::OUString::operator[](int) const 
(this=0x846da80, index=-1) at include/rtl/ustring.hxx:794
5  0x7f39da59acdc in TextEngine::GetWord(TextPaM const&, TextPaM*, 
TextPaM*) (this=0x8901e80, rCursorPos=..., pStartOfWord=0x7ffd1f0b7360, 
pEndOfWord=0x0) at vcl/source/edit/texteng.cxx:2375
6  0x7f39c4ac5c5c in basctl::EditorWindow::RequestHelp(HelpEvent 
const&) (this=0x8581060, rHEvt=...) at basctl/source/basicide/baside2b.cxx:370
7  0x7f39da3b8f91 in ImplHandleMouseHelpRequest(vcl::Window*, Point 
const&) (pChild=0x8581060, rMousePos=Point = {...}) at 
vcl/source/window/winproc.cxx:181

(gdb) frame 4
4  0x7f39da1fe3c4 in rtl::OUString::operator[] (this=0x846da80, 
index=-1) at include/rtl/ustring.hxx:794
794 assert(index >= 0 && static_cast(index) < 
static_cast(getLength()));
(gdb) p this
$1 = (const rtl::OUString *) 0x846da80
(gdb) p *this
$2 = "\t\t"
(gdb) frame 5
5  0x7f39da59acdc in TextEngine::GetWord (this=0x8901e80, 
rCursorPos=..., pStartOfWord=0x7ffd1f0b7360, pEndOfWord=0x0) at 
vcl/source/edit/texteng.cxx:2375
2375if (aBoundary.endPos < pNode->GetText().getLength() && 
u_charType(pNode->GetText()[aBoundary.endPos - 1]) == U_CONNECTOR_PUNCTUATION)
(gdb) p aBoundary.endPos
$3 = 0
(gdb) p pNode->GetText()
$4 = "\t\t"
(gdb) p pNode->GetText().getLength()
$5 = 2

Change-Id: Ic94362b26cb0ebb0975c42fe5a31724ff485aad0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115546
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/vcl/source/edit/texteng.cxx b/vcl/source/edit/texteng.cxx
index 1959151ffee1..aa4940e33eba 100644
--- a/vcl/source/edit/texteng.cxx
+++ b/vcl/source/edit/texteng.cxx
@@ -2372,7 +2372,7 @@ OUString TextEngine::GetWord( const TextPaM& rCursorPos, 
TextPaM* pStartOfWord,
 GetLocale(), 
css::i18n::WordType::ANYWORD_IGNOREWHITESPACES, true).startPos);
 }
 // tdf#57879 - expand selection to the right to include connector 
punctuations and search for additional word boundaries
-if (aBoundary.endPos < pNode->GetText().getLength() && 
u_charType(pNode->GetText()[aBoundary.endPos - 1]) == U_CONNECTOR_PUNCTUATION)
+if (aBoundary.endPos > 0 && aBoundary.endPos < 
pNode->GetText().getLength() && u_charType(pNode->GetText()[aBoundary.endPos - 
1]) == U_CONNECTOR_PUNCTUATION)
 {
 aBoundary.endPos = xBI->getWordBoundary(pNode->GetText(), 
aBoundary.endPos,
 GetLocale(), css::i18n::WordType::ANYWORD_IGNOREWHITESPACES, 
true).endPos;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-14 Thread Julien Nabet (via logerrit)
 chart2/qa/unit/common_functor_test.cxx |9 +
 1 file changed, 1 insertion(+), 8 deletions(-)

New commits:
commit 6b58816d17957536a2875cbbed0d270451ff25f7
Author: Julien Nabet 
AuthorDate: Fri May 14 10:37:03 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 11:37:05 2021 +0200

Directly initialize vectors in common_functor_test.cxx

since we've got all the information from the beginning.

Change-Id: I37098766967968f0db722c8998158d626792545e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115586
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/chart2/qa/unit/common_functor_test.cxx 
b/chart2/qa/unit/common_functor_test.cxx
index eaa5a29fc08a..b2e404e13508 100644
--- a/chart2/qa/unit/common_functor_test.cxx
+++ b/chart2/qa/unit/common_functor_test.cxx
@@ -61,14 +61,7 @@ void CommonFunctorsTest::testAnyToString()
 
 void CommonFunctorsTest::testDoubleToString()
 {
-std::vector aInput;
-aInput.push_back(2.0);
-aInput.push_back(10.0);
-aInput.push_back(12.0);
-aInput.push_back(15.0);
-aInput.push_back(25.234);
-aInput.push_back(123.456);
-aInput.push_back(0.123450);
+std::vector aInput { 2.0, 10.0, 12.0, 15.0, 25.234, 123.456, 
0.123450 };
 
 std::vector aOutput;
 std::transform(aInput.begin(), aInput.end(),
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-14 Thread Julien Nabet (via logerrit)
 chart2/source/view/main/VDataSeries.cxx |9 +
 1 file changed, 5 insertions(+), 4 deletions(-)

New commits:
commit 5449a798d1e676ce8bef876270226eaea602f258
Author: Julien Nabet 
AuthorDate: Fri May 14 10:55:16 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 12:03:09 2021 +0200

Avoid temporary var + directly initialize vector in VDataSeries.cxx

Change-Id: Ief280ca4cb2cdadfc41f7c98bdec4044475c7daf
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115588
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/chart2/source/view/main/VDataSeries.cxx 
b/chart2/source/view/main/VDataSeries.cxx
index 545254ecfccc..247fe41a2d27 100644
--- a/chart2/source/view/main/VDataSeries.cxx
+++ b/chart2/source/view/main/VDataSeries.cxx
@@ -277,10 +277,11 @@ void VDataSeries::doSortByXValues()
 sal_Int32 nPointIndex = 0;
 for( nPointIndex=0; nPointIndex < m_nPointCount; nPointIndex++ )
 {
-std::vector< double > aSinglePoint;
-aSinglePoint.push_back( (nPointIndex < 
m_aValues_X.Doubles.getLength()) ? m_aValues_X.Doubles[nPointIndex] : fNan );
-aSinglePoint.push_back( (nPointIndex < 
m_aValues_Y.Doubles.getLength()) ? m_aValues_Y.Doubles[nPointIndex] : fNan );
-aTmp.push_back( aSinglePoint );
+aTmp.push_back(
+{ ((nPointIndex < m_aValues_X.Doubles.getLength()) ? 
m_aValues_X.Doubles[nPointIndex] : fNan),
+  ((nPointIndex < m_aValues_Y.Doubles.getLength()) ? 
m_aValues_Y.Doubles[nPointIndex] : fNan)
+}
+  );
 }
 
 //do sort
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: 2 commits - connectivity/qa sc/CppunitTest_sc_ucalc_pivottable.mk sc/CppunitTest_sc_ucalc_sharedformula.mk sc/CppunitTest_sc_ucalc_sort.mk sc/Module_sc.mk sc/ucalc_setu

2021-05-14 Thread Julien Nabet (via logerrit)
 connectivity/qa/connectivity/resource/sharedresources_test.cxx |9 
 sc/CppunitTest_sc_ucalc_pivottable.mk  |  107 
 sc/CppunitTest_sc_ucalc_sharedformula.mk   |  107 
 sc/CppunitTest_sc_ucalc_sort.mk|  107 
 sc/Module_sc.mk|1 
 sc/ucalc_setup.mk  |  124 
++
 6 files changed, 133 insertions(+), 322 deletions(-)

New commits:
commit f40cbba63f13e7081fc5901769651fd4d43ea34d
Author: Julien Nabet 
AuthorDate: Fri May 14 11:34:13 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 12:45:59 2021 +0200

Directly initialize vector in sharedresources_test.cxx

Change-Id: I5341272a33127a7cb19d477593d906ebd0c6bdec
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115592
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/connectivity/qa/connectivity/resource/sharedresources_test.cxx 
b/connectivity/qa/connectivity/resource/sharedresources_test.cxx
index a6bf22fba858..dfc62a763bbd 100644
--- a/connectivity/qa/connectivity/resource/sharedresources_test.cxx
+++ b/connectivity/qa/connectivity/resource/sharedresources_test.cxx
@@ -88,10 +88,11 @@ void 
SharedResourcesTest::testGetSourceStringWithSubstitutionThree()
 
 void SharedResourcesTest::testGetSourceStringWithSubstitutionVector()
 {
-std::vector> aStringToSubstitutes;
-aStringToSubstitutes.push_back(std::pair("$sub0$", 
"vector0"));
-aStringToSubstitutes.push_back(std::pair("$sub1$", 
"vector1"));
-aStringToSubstitutes.push_back(std::pair("$sub2$", 
"vector2"));
+std::vector> aStringToSubstitutes{
+std::pair("$sub0$", "vector0"),
+std::pair("$sub1$", "vector1"),
+std::pair("$sub2$", "vector2")
+};
 
 CPPUNIT_ASSERT_EQUAL(OUString("Three substitution vector0 vector1 
vector2"),
  m_aResource.getResourceStringWithSubstitution(
commit f2736a462ea764e6f5abc95747c52e48d507b345
Author: Xisco Fauli 
AuthorDate: Fri May 14 01:34:19 2021 +0200
Commit: Xisco Fauli 
CommitDate: Fri May 14 12:45:42 2021 +0200

sc_ucalc: Use a template for makefiles

Change-Id: I2146ded4c8c0eb8ba7814f76f3ec5d9030a67857
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115578
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 

diff --git a/sc/CppunitTest_sc_ucalc_pivottable.mk 
b/sc/CppunitTest_sc_ucalc_pivottable.mk
index fbf88762bd78..b93593ca97d8 100644
--- a/sc/CppunitTest_sc_ucalc_pivottable.mk
+++ b/sc/CppunitTest_sc_ucalc_pivottable.mk
@@ -9,111 +9,6 @@
 #
 #*
 
-$(eval $(call gb_CppunitTest_CppunitTest,sc_ucalc_pivottable))
-
-$(eval $(call gb_Library_use_common_precompiled_header,sc_ucalc_pivottable))
-
-$(eval $(call gb_CppunitTest_add_exception_objects,sc_ucalc_pivottable, \
-   sc/qa/unit/ucalc_pivottable \
-))
-
-$(eval $(call gb_CppunitTest_use_library_objects,sc_ucalc_pivottable, \
-   sc \
-   scqahelper \
-))
-
-$(eval $(call gb_CppunitTest_use_externals,sc_ucalc_pivottable,\
-   boost_headers \
-$(call gb_Helper_optional,OPENCL, \
-clew) \
-icu_headers \
-icui18n \
-icuuc \
-   libxml2 \
-   mdds_headers \
-   orcus \
-   orcus-parser \
-))
-
-$(eval $(call gb_CppunitTest_use_libraries,sc_ucalc_pivottable, \
-   $(call gb_Helper_optional,AVMEDIA,avmedia) \
-basegfx \
-comphelper \
-cppu \
-cppuhelper \
-dbtools \
-drawinglayer \
-editeng \
-for \
-forui \
-i18nlangtag \
-i18nutil \
-   $(call gb_Helper_optional,OPENCL, \
-   opencl) \
-sal \
-salhelper \
-sax \
-sb \
-sfx \
-sot \
-svl \
-svt \
-svx \
-svxcore \
-   test \
-tk \
-tl \
-ucbhelper \
-   unotest \
-utl \
-vbahelper \
-vcl \
-xo \
-))
-
-$(eval $(call gb_CppunitTest_set_include,sc_ucalc_pivottable,\
--I$(SRCDIR)/sc/source/ui/inc \
--I$(SRCDIR)/sc/source/core/inc \
--I$(SRCDIR)/sc/inc \
-$$(INCLUDE) \
-))
-
-$(eval $(call gb_CppunitTest_use_api,sc_ucalc_pivottable,\
-   udkapi \
-   offapi \
-   oovbaapi \
-))
-
-$(eval $(call gb_CppunitTest_use_custom_headers,sc_ucalc_pivottable,\
-   officecfg/registry \
-))
-
-$(eval $(call gb_CppunitTest_use_ure,sc_ucalc_pivottable))
-$(eval $(call gb_CppunitTest_use_vcl,sc_ucalc_pivottable))
-
-$(eval $(call gb_CppunitTest_use_components,sc_ucalc_pivottable,\
-configmgr/source/configmgr \
-framework/util/fwk \
-i18npool/source/search/i18nsearch \
-i18npool/util/i18npool \
-sax/source/expatwrap/expwrap \
-scaddins/source/analysis/analysis \
-scaddins/source/datefunc/date \
-scaddins/source/pricing/pricing \
-sfx2/util/sfx \
-ucb/source/core/ucb1 \
-ucb/source/ucp/file/ucpfile1 \
-

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

2021-05-14 Thread Julien Nabet (via logerrit)
 configmgr/source/access.cxx |   26 +-
 1 file changed, 13 insertions(+), 13 deletions(-)

New commits:
commit 141f3e101508e7d0a83bd34a5cf48673fe91e44c
Author: Julien Nabet 
AuthorDate: Fri May 14 11:08:45 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 23:13:59 2021 +0200

Directly partly initialize vector in access.cxx

Change-Id: Iac19920caf0a9bdfa07b025c19c7659b96374c7e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115590
Tested-by: Julien Nabet 
Reviewed-by: Julien Nabet 

diff --git a/configmgr/source/access.cxx b/configmgr/source/access.cxx
index fa2aa1fe6eb0..02e3f557c684 100644
--- a/configmgr/source/access.cxx
+++ b/configmgr/source/access.cxx
@@ -173,19 +173,19 @@ css::uno::Sequence< css::uno::Type > Access::getTypes()
 assert(thisIs(IS_ANY));
 osl::MutexGuard g(*lock_);
 checkLocalizedPropertyAccess();
-std::vector< css::uno::Type > types;
-types.push_back(cppu::UnoType< css::uno::XInterface >::get());
-types.push_back(cppu::UnoType< css::uno::XWeak >::get());
-types.push_back(cppu::UnoType< css::lang::XTypeProvider >::get());
-types.push_back(cppu::UnoType< css::lang::XServiceInfo >::get());
-types.push_back(cppu::UnoType< css::lang::XComponent >::get());
-types.push_back(cppu::UnoType< css::container::XContainer >::get());
-types.push_back(cppu::UnoType< css::beans::XExactName >::get());
-types.push_back(cppu::UnoType< css::container::XHierarchicalName >::get());
-types.push_back(cppu::UnoType< css::container::XNamed >::get());
-types.push_back(cppu::UnoType< css::beans::XProperty >::get());
-types.push_back(cppu::UnoType< css::container::XElementAccess >::get());
-types.push_back(cppu::UnoType< css::container::XNameAccess >::get());
+std::vector< css::uno::Type > types { cppu::UnoType< css::uno::XInterface 
>::get(),
+  cppu::UnoType< css::uno::XWeak 
>::get(),
+  cppu::UnoType< 
css::lang::XTypeProvider >::get(),
+  cppu::UnoType< 
css::lang::XServiceInfo >::get(),
+  cppu::UnoType< css::lang::XComponent 
>::get(),
+  cppu::UnoType< 
css::container::XContainer >::get(),
+  cppu::UnoType< 
css::beans::XExactName >::get(),
+  cppu::UnoType< 
css::container::XHierarchicalName >::get(),
+  cppu::UnoType< 
css::container::XNamed >::get(),
+  cppu::UnoType< css::beans::XProperty 
>::get(),
+  cppu::UnoType< 
css::container::XElementAccess >::get(),
+  cppu::UnoType< 
css::container::XNameAccess >::get()
+};
 if (getNode()->kind() == Node::KIND_GROUP) {
 types.push_back(cppu::UnoType< css::beans::XPropertySetInfo >::get());
 types.push_back(cppu::UnoType< css::beans::XPropertySet >::get());
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-14 Thread Julien Nabet (via logerrit)
 connectivity/source/drivers/flat/EDatabaseMetaData.cxx |   45 ++--
 connectivity/source/drivers/flat/EDriver.cxx   |   25 +++
 connectivity/source/drivers/jdbc/JDriver.cxx   |   59 -
 3 files changed, 66 insertions(+), 63 deletions(-)

New commits:
commit e01786898406130aa81eadc32f7bc2fad65c5344
Author: Julien Nabet 
AuthorDate: Fri May 14 18:46:57 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 23:09:11 2021 +0200

Directly initialize vector in connectivity (part 3)

Change-Id: Ie7f74a3f0fa865994057575b3dfac2bc209c6793
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115631
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/connectivity/source/drivers/flat/EDatabaseMetaData.cxx 
b/connectivity/source/drivers/flat/EDatabaseMetaData.cxx
index 5cb1a79a6c2c..ff02c5827395 100644
--- a/connectivity/source/drivers/flat/EDatabaseMetaData.cxx
+++ b/connectivity/source/drivers/flat/EDatabaseMetaData.cxx
@@ -53,28 +53,29 @@ Reference< XResultSet > 
OFlatDatabaseMetaData::impl_getTypeInfo_throw(  )
 
 static ODatabaseMetaDataResultSet::ORows aRows = [&]()
 {
-ODatabaseMetaDataResultSet::ORows tmp;
-ODatabaseMetaDataResultSet::ORow aRow;
-
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(new ORowSetValueDecorator(OUString("CHAR")));
-aRow.push_back(new ORowSetValueDecorator(DataType::CHAR));
-aRow.push_back(new ORowSetValueDecorator(sal_Int32(254)));
-aRow.push_back(ODatabaseMetaDataResultSet::getQuoteValue());
-aRow.push_back(ODatabaseMetaDataResultSet::getQuoteValue());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(new 
ORowSetValueDecorator(sal_Int32(ColumnValue::NULLABLE)));
-aRow.push_back(ODatabaseMetaDataResultSet::get1Value());
-aRow.push_back(new 
ORowSetValueDecorator(sal_Int32(ColumnSearch::CHAR)));
-aRow.push_back(ODatabaseMetaDataResultSet::get1Value());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(new ORowSetValueDecorator(sal_Int32(10)));
+ODatabaseMetaDataResultSet::ORows tmp(10);
+ODatabaseMetaDataResultSet::ORow aRow
+{
+{ ODatabaseMetaDataResultSet::getEmptyValue() },
+{ new ORowSetValueDecorator(OUString("CHAR")) },
+{ new ORowSetValueDecorator(DataType::CHAR) },
+{ new ORowSetValueDecorator(sal_Int32(254)) },
+{ ODatabaseMetaDataResultSet::getQuoteValue() },
+{ ODatabaseMetaDataResultSet::getQuoteValue() },
+{ ODatabaseMetaDataResultSet::getEmptyValue() },
+{ new ORowSetValueDecorator(sal_Int32(ColumnValue::NULLABLE)) },
+{ ODatabaseMetaDataResultSet::get1Value() },
+{ new ORowSetValueDecorator(sal_Int32(ColumnSearch::CHAR)) },
+{ ODatabaseMetaDataResultSet::get1Value() },
+{ ODatabaseMetaDataResultSet::get0Value() },
+{ ODatabaseMetaDataResultSet::get0Value() },
+{ ODatabaseMetaDataResultSet::getEmptyValue() },
+{ ODatabaseMetaDataResultSet::get0Value() },
+{ ODatabaseMetaDataResultSet::get0Value() },
+{ ODatabaseMetaDataResultSet::getEmptyValue() },
+{ ODatabaseMetaDataResultSet::getEmptyValue() },
+{ new ORowSetValueDecorator(sal_Int32(10)) }
+};
 
 tmp.push_back(aRow);
 
diff --git a/connectivity/source/drivers/flat/EDriver.cxx 
b/connectivity/source/drivers/flat/EDriver.cxx
index 3e6bb90a7ed6..6a1c4a37adef 100644
--- a/connectivity/source/drivers/flat/EDriver.cxx
+++ b/connectivity/source/drivers/flat/EDriver.cxx
@@ -82,47 +82,48 @@ Sequence< DriverPropertyInfo > SAL_CALL 
ODriver::getPropertyInfo( const OUString
 {
 if ( acceptsURL(url) )
 {
-std::vector< DriverPropertyInfo > aDriverInfo;
-
 Sequence< OUString > aBoolean(2);
 aBoolean[0] = "0";
 aBoolean[1] = "1";
 
-aDriverInfo.push_back(DriverPropertyInfo(
+std::vector< DriverPropertyInfo > aDriverInfo
+{
+{ DriverPropertyInfo(
 "FieldDelimiter"
 ,"Field separator."
 ,false
 ,OUString()
 ,Sequence< OUString >())
-);
-aDriverInfo.push_back(DriverPropertyInfo(
+},
+{ DriverPropertyInfo(
 "HeaderLine"
 ,"Text contains headers."
  

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

2021-05-14 Thread Julien Nabet (via logerrit)
 connectivity/qa/connectivity/resource/sharedresources_test.cxx |8 +++-
 1 file changed, 3 insertions(+), 5 deletions(-)

New commits:
commit be96aa21aed3069775609780566541b3631cbbe1
Author: Julien Nabet 
AuthorDate: Fri May 14 12:58:25 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 23:08:54 2021 +0200

Simplify a bit initialization in sharedresources_test.cxx

Change-Id: I5c3fb9fffc9ac541536a8e9cf824789d9c107b3e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115597
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/connectivity/qa/connectivity/resource/sharedresources_test.cxx 
b/connectivity/qa/connectivity/resource/sharedresources_test.cxx
index dfc62a763bbd..9c8f4e4396b7 100644
--- a/connectivity/qa/connectivity/resource/sharedresources_test.cxx
+++ b/connectivity/qa/connectivity/resource/sharedresources_test.cxx
@@ -88,11 +88,9 @@ void 
SharedResourcesTest::testGetSourceStringWithSubstitutionThree()
 
 void SharedResourcesTest::testGetSourceStringWithSubstitutionVector()
 {
-std::vector> aStringToSubstitutes{
-std::pair("$sub0$", "vector0"),
-std::pair("$sub1$", "vector1"),
-std::pair("$sub2$", "vector2")
-};
+std::vector> aStringToSubstitutes{ { 
"$sub0$", "vector0" },
+{ 
"$sub1$", "vector1" },
+{ 
"$sub2$", "vector2" } };
 
 CPPUNIT_ASSERT_EQUAL(OUString("Three substitution vector0 vector1 
vector2"),
  m_aResource.getResourceStringWithSubstitution(
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-18 Thread Julien Nabet (via logerrit)
 xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx |   10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

New commits:
commit 816c2bb27bde42700fd0154cc250e9dcfd5d744e
Author: Julien Nabet 
AuthorDate: Mon May 17 21:02:47 2021 +0200
Commit: Julien Nabet 
CommitDate: Tue May 18 09:41:52 2021 +0200

Typo: solt=>slot

Change-Id: I742060932f3408bd40921d91e062a7acee0832e3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115719
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx 
b/xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx
index dd57a28be6da..21524c37163b 100644
--- a/xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx
+++ b/xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx
@@ -216,13 +216,13 @@ void SecurityEnvironment_NssImpl::updateSlots()
 m_Slots.clear();
 m_tSymKeyList.clear();
 
-PK11SlotList * soltList = PK11_GetAllTokens( CKM_INVALID_MECHANISM, 
PR_FALSE, PR_FALSE, nullptr ) ;
-if( soltList == nullptr )
+PK11SlotList * slotList = PK11_GetAllTokens( CKM_INVALID_MECHANISM, 
PR_FALSE, PR_FALSE, nullptr ) ;
+if( slotList == nullptr )
 return;
 
-for (PK11SlotListElement* soltEle = soltList->head ; soltEle != nullptr; 
soltEle = soltEle->next)
+for (PK11SlotListElement* slotEle = slotList->head ; slotEle != nullptr; 
slotEle = slotEle->next)
 {
-PK11SlotInfo * pSlot = soltEle->slot ;
+PK11SlotInfo * pSlot = slotEle->slot ;
 
 if(pSlot != nullptr)
 {
@@ -260,7 +260,7 @@ void SecurityEnvironment_NssImpl::updateSlots()
 }// end of if(pSlot != NULL)
 }// end of for
 
-PK11_FreeSlotList(soltList);
+PK11_FreeSlotList(slotList);
 }
 
 Sequence< Reference < XCertificate > >
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - avmedia/source

2021-05-05 Thread Julien Nabet (via logerrit)
 avmedia/source/framework/MediaControlBase.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 59692b289fb3a0d98d9462a590fa8f393572211c
Author: Julien Nabet 
AuthorDate: Mon Dec 14 19:45:22 2020 +0100
Commit: Caolán McNamara 
CommitDate: Wed May 5 20:42:50 2021 +0200

rhbz#1957034 crash in embedded videos

Related tdf#13: fix assertion on avmedia/MediaControlBase

Assertion when trying to insert a video in Impress, see bt:
https://bugs.documentfoundation.org/attachment.cgi?id=168161

According to https://en.cppreference.com/w/cpp/algorithm/clamp
"behavior is undefined if the value of lo is greater than hi"

Regression from:
commit 36b3b357fe2a882db6a5f5a006239e16200fb847
Author: Noel 
Date:   Thu Nov 12 16:10:56 2020 +0200

replace std::min(std::max()) with std::clamp

Change-Id: Idf33eb6c662b60174678f990f98aefc72edec2a6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107722
Tested-by: Jenkins
Reviewed-by: Noel Grandin 
(cherry picked from commit f4e496af66bc6a779f600158cc42b986d654f143)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115078
Reviewed-by: Michael Stahl 
Tested-by: Caolán McNamara 

diff --git a/avmedia/source/framework/MediaControlBase.cxx 
b/avmedia/source/framework/MediaControlBase.cxx
index 005c409fccb4..0ab60b6ac9f3 100644
--- a/avmedia/source/framework/MediaControlBase.cxx
+++ b/avmedia/source/framework/MediaControlBase.cxx
@@ -64,7 +64,7 @@ void MediaControlBase::UpdateVolumeSlider( MediaItem const & 
aMediaItem )
 {
 mxVolumeSlider->set_sensitive(true);
 const sal_Int32 nVolumeDB = aMediaItem.getVolumeDB();
-mxVolumeSlider->set_value( std::clamp( nVolumeDB, sal_Int32(0), 
AVMEDIA_DB_RANGE ) );
+mxVolumeSlider->set_value( std::clamp( nVolumeDB, AVMEDIA_DB_RANGE, 
sal_Int32(0)) );
 }
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-17 Thread Julien Nabet (via logerrit)
 connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx |   38 +-
 connectivity/source/drivers/file/FDriver.cxx |   24 +++---
 connectivity/source/drivers/flat/EDatabaseMetaData.cxx   |   38 +-
 connectivity/source/drivers/flat/EDriver.cxx |   20 ++---
 connectivity/source/drivers/jdbc/JDriver.cxx |   52 +++
 5 files changed, 86 insertions(+), 86 deletions(-)

New commits:
commit 08ffd34d5274e745a1400c70f94fc297f5ad8569
Author: Julien Nabet 
AuthorDate: Sun May 16 20:36:59 2021 +0200
Commit: Julien Nabet 
CommitDate: Mon May 17 18:48:35 2021 +0200

Simplify some initializations in connectivity

Change-Id: I980b59f06fb6004ba23279c8364cb0587e7ac8fc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115679
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx 
b/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx
index 455bf09e6733..6c798e5a166c 100644
--- a/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx
+++ b/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx
@@ -1013,25 +1013,25 @@ Reference< XResultSet > 
OEvoabDatabaseMetaData::impl_getTypeInfo_throw(  )
 ODatabaseMetaDataResultSet::ORows tmp(2);
 ODatabaseMetaDataResultSet::ORow aRow
 {
-{ ODatabaseMetaDataResultSet::getEmptyValue() },
-{ new ORowSetValueDecorator(OUString("VARCHAR")) },
-{ new ORowSetValueDecorator(DataType::VARCHAR) },
-{ new ORowSetValueDecorator(sal_Int32(s_nCHAR_OCTET_LENGTH)) },
-{ ODatabaseMetaDataResultSet::getQuoteValue() },
-{ ODatabaseMetaDataResultSet::getQuoteValue() },
-{ ODatabaseMetaDataResultSet::getEmptyValue() },
-{ ODatabaseMetaDataResultSet::get1Value() },
-{ ODatabaseMetaDataResultSet::get1Value() },
-{ new ORowSetValueDecorator(sal_Int32(ColumnSearch::FULL)) },
-{ ODatabaseMetaDataResultSet::get1Value() },
-{ ODatabaseMetaDataResultSet::get0Value() },
-{ ODatabaseMetaDataResultSet::get0Value() },
-{ ODatabaseMetaDataResultSet::getEmptyValue() },
-{ ODatabaseMetaDataResultSet::get0Value() },
-{ ODatabaseMetaDataResultSet::get0Value() },
-{ ODatabaseMetaDataResultSet::getEmptyValue() },
-{ ODatabaseMetaDataResultSet::getEmptyValue() },
-{ new ORowSetValueDecorator(sal_Int32(10)) }
+ ODatabaseMetaDataResultSet::getEmptyValue() ,
+ new ORowSetValueDecorator(OUString("VARCHAR")) ,
+ new ORowSetValueDecorator(DataType::VARCHAR) ,
+ new ORowSetValueDecorator(sal_Int32(s_nCHAR_OCTET_LENGTH)) ,
+ ODatabaseMetaDataResultSet::getQuoteValue() ,
+ ODatabaseMetaDataResultSet::getQuoteValue() ,
+ ODatabaseMetaDataResultSet::getEmptyValue() ,
+ ODatabaseMetaDataResultSet::get1Value() ,
+ ODatabaseMetaDataResultSet::get1Value() ,
+ new ORowSetValueDecorator(sal_Int32(ColumnSearch::FULL)) ,
+ ODatabaseMetaDataResultSet::get1Value() ,
+ ODatabaseMetaDataResultSet::get0Value() ,
+ ODatabaseMetaDataResultSet::get0Value() ,
+ ODatabaseMetaDataResultSet::getEmptyValue() ,
+ ODatabaseMetaDataResultSet::get0Value() ,
+ ODatabaseMetaDataResultSet::get0Value() ,
+ ODatabaseMetaDataResultSet::getEmptyValue() ,
+ ODatabaseMetaDataResultSet::getEmptyValue() ,
+ new ORowSetValueDecorator(sal_Int32(10))
 };
 
 tmp.push_back(aRow);
diff --git a/connectivity/source/drivers/file/FDriver.cxx 
b/connectivity/source/drivers/file/FDriver.cxx
index f536df64039d..5c251a402b5b 100644
--- a/connectivity/source/drivers/file/FDriver.cxx
+++ b/connectivity/source/drivers/file/FDriver.cxx
@@ -104,47 +104,47 @@ Sequence< DriverPropertyInfo > SAL_CALL 
OFileDriver::getPropertyInfo( const OUSt
 
 std::vector< DriverPropertyInfo > aDriverInfo
 {
- { DriverPropertyInfo(
+ {
 "CharSet"
 ,"CharSet of the database."
 ,false
 ,OUString()
-,Sequence< OUString >())
+,Sequence< OUString >()
  },
- { DriverPropertyInfo(
+ {
 "Extension"
 ,"Extension of the file format."
 ,false
 ,".*"
-,Sequence< OUString >())
+,Sequence< OUString >()
  },
- { DriverPropertyInfo(
+ {
 "ShowDeleted"
 ,"Display inactive records."
 ,false
 ,"0"
-,aBoolean)
+,aBoolean
  },
- { DriverPropertyInfo(
+ 

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

2021-05-17 Thread Julien Nabet (via logerrit)
 connectivity/source/drivers/ado/ADatabaseMetaDataResultSet.cxx |  349 
+-
 1 file changed, 184 insertions(+), 165 deletions(-)

New commits:
commit c8cf2e0e088b74afa52564945a9c005b3b86bf7e
Author: Julien Nabet 
AuthorDate: Fri May 14 13:25:48 2021 +0200
Commit: Julien Nabet 
CommitDate: Mon May 17 12:56:05 2021 +0200

Directly initialize maps in ADatabaseMetaDataResultSet.cxx

Change-Id: I40d88f6b538c1c38589b8cadc8c174ffa6754940
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115599
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/connectivity/source/drivers/ado/ADatabaseMetaDataResultSet.cxx 
b/connectivity/source/drivers/ado/ADatabaseMetaDataResultSet.cxx
index caa4dd800324..95358ed6df5c 100644
--- a/connectivity/source/drivers/ado/ADatabaseMetaDataResultSet.cxx
+++ b/connectivity/source/drivers/ado/ADatabaseMetaDataResultSet.cxx
@@ -780,7 +780,6 @@ void ODatabaseMetaDataResultSet::getFastPropertyValue(
 
 void ODatabaseMetaDataResultSet::setProceduresMap()
 {
-
 for(sal_Int32 i=1;i<4;i++)
 m_aColMapping.push_back(i);
 m_aColMapping.push_back(5);
@@ -789,10 +788,12 @@ void ODatabaseMetaDataResultSet::setProceduresMap()
 m_aColMapping.push_back(6);
 m_aColMapping.push_back(4);
 
-::std::map aMap;
-aMap[DB_PT_UNKNOWN] = ProcedureResult::UNKNOWN;
-aMap[DB_PT_PROCEDURE]   = ProcedureResult::NONE;
-aMap[DB_PT_FUNCTION]= ProcedureResult::RETURN;
+::std::map aMap
+{
+{DB_PT_UNKNOWN, ProcedureResult::UNKNOWN},
+{DB_PT_PROCEDURE, ProcedureResult::NONE},
+{DB_PT_FUNCTION, ProcedureResult::RETURN}
+};
 m_aValueRange[4] = aMap;
 
 rtl::Reference pMetaData = new 
ODatabaseMetaDataResultSetMetaData(m_pRecordSet,this);
@@ -854,52 +855,53 @@ void ODatabaseMetaDataResultSet::setColumnsMap()
 m_aColMapping.push_back(7);
 m_aColMapping.push_back(11);
 
-::std::map aMap;
-aMap[adEmpty]   = ADOS::MapADOType2Jdbc(adEmpty);
-aMap[adTinyInt] = ADOS::MapADOType2Jdbc(adTinyInt);
-aMap[adSmallInt]= ADOS::MapADOType2Jdbc(adSmallInt);
-aMap[adInteger] = ADOS::MapADOType2Jdbc(adInteger);
-aMap[adBigInt]  = ADOS::MapADOType2Jdbc(adBigInt);
-aMap[adUnsignedTinyInt] = ADOS::MapADOType2Jdbc(adUnsignedTinyInt);
-aMap[adUnsignedSmallInt]= ADOS::MapADOType2Jdbc(adUnsignedSmallInt);
-aMap[adUnsignedInt] = ADOS::MapADOType2Jdbc(adUnsignedInt);
-aMap[adUnsignedBigInt]  = ADOS::MapADOType2Jdbc(adUnsignedBigInt);
-aMap[adSingle]  = ADOS::MapADOType2Jdbc(adSingle);
-aMap[adDouble]  = ADOS::MapADOType2Jdbc(adDouble);
-aMap[adCurrency]= ADOS::MapADOType2Jdbc(adCurrency);
-aMap[adDecimal] = ADOS::MapADOType2Jdbc(adDecimal);
-aMap[adNumeric] = ADOS::MapADOType2Jdbc(adNumeric);
-aMap[adBoolean] = ADOS::MapADOType2Jdbc(adBoolean);
-aMap[adError]   = ADOS::MapADOType2Jdbc(adError);
-aMap[adUserDefined] = ADOS::MapADOType2Jdbc(adUserDefined);
-aMap[adVariant] = ADOS::MapADOType2Jdbc(adVariant);
-aMap[adIDispatch]   = ADOS::MapADOType2Jdbc(adIDispatch);
-aMap[adIUnknown]= ADOS::MapADOType2Jdbc(adIUnknown);
-aMap[adGUID]= ADOS::MapADOType2Jdbc(adGUID);
-aMap[adDate]= ADOS::MapADOType2Jdbc(adDate);
-aMap[adDBDate]  = ADOS::MapADOType2Jdbc(adDBDate);
-aMap[adDBTime]  = ADOS::MapADOType2Jdbc(adDBTime);
-aMap[adDBTimeStamp] = ADOS::MapADOType2Jdbc(adDBTimeStamp);
-aMap[adBSTR]= ADOS::MapADOType2Jdbc(adBSTR);
-aMap[adChar]= ADOS::MapADOType2Jdbc(adChar);
-aMap[adVarChar] = ADOS::MapADOType2Jdbc(adVarChar);
-aMap[adLongVarChar] = ADOS::MapADOType2Jdbc(adLongVarChar);
-aMap[adWChar]   = ADOS::MapADOType2Jdbc(adWChar);
-aMap[adVarWChar]= ADOS::MapADOType2Jdbc(adVarWChar);
-aMap[adLongVarWChar]= ADOS::MapADOType2Jdbc(adLongVarWChar);
-aMap[adBinary]  = ADOS::MapADOType2Jdbc(adBinary);
-aMap[adVarBinary]   = ADOS::MapADOType2Jdbc(adVarBinary);
-aMap[adLongVarBinary]   = ADOS::MapADOType2Jdbc(adLongVarBinary);
-aMap[adChapter] = ADOS::MapADOType2Jdbc(adChapter);
-aMap[adFileTime]= ADOS::MapADOType2Jdbc(adFileTime);
-aMap[adPropVariant] = ADOS::MapADOType2Jdbc(adPropVariant);
-aMap[adVarNumeric]  = ADOS::MapADOType2Jdbc(adVarNumeric);
-
+::std::map aMap {
+{adEmpty,ADOS::MapADOType2Jdbc(adEmpty)},
+{adTinyInt,  ADOS::MapADOType2Jdbc(adTinyInt)},
+{adSmallInt, ADOS::MapADOType2Jdbc(adSmallInt)},
+{adInteger,  ADOS::MapADOType2Jdbc(adInteger)},
+{adBigInt,   ADOS::MapADOType2Jdbc(adBigInt)},
+{adUnsignedTinyInt,  ADOS::MapADOType2Jdbc(adUnsignedTinyInt)},
+{adUnsignedSmallInt, 

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

2021-05-18 Thread Julien Nabet (via logerrit)
 configure.ac |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 2c4dd73c4c9f471fa2083f9f99dd27a7148f3175
Author: Julien Nabet 
AuthorDate: Mon May 17 18:43:48 2021 +0200
Commit: Heiko Tietze 
CommitDate: Tue May 18 08:59:29 2021 +0200

tdf#142335: fix bashism in configure.ac

Thanks to Matt Whitlock!

(also reported in https://bugs.gentoo.org/show_bug.cgi?id=780432)

Change-Id: I38fec6faf9a929adf1f300b8c369ec6c16a91ed8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115716
Tested-by: Jenkins
Reviewed-by: Heiko Tietze 

diff --git a/configure.ac b/configure.ac
index d7b831435713..3d14c5e4258c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2682,7 +2682,7 @@ AC_SUBST(ENABLE_RELEASE_BUILD)
 AC_SUBST(GET_TASK_ALLOW_ENTITLEMENT)
 
 AC_MSG_CHECKING([whether to build a Community flavor])
-if test -z "$enable_community_flavor" -o "$enable_community_flavor" == "yes"; 
then
+if test -z "$enable_community_flavor" -o "$enable_community_flavor" = "yes"; 
then
 AC_DEFINE(HAVE_FEATURE_COMMUNITY_FLAVOR)
 AC_MSG_RESULT([yes])
 else
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-14 Thread Julien Nabet (via logerrit)
 chart2/source/view/axes/VCartesianAxis.cxx |   12 +++-
 1 file changed, 3 insertions(+), 9 deletions(-)

New commits:
commit b6d6a3f34163eba45691387dfe2748f7a1788f6a
Author: Julien Nabet 
AuthorDate: Fri May 14 10:42:47 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 16:05:51 2021 +0200

Directly initialize vectors in VCartesianAxis.cxx

since we've got all the information from the beginning.

Change-Id: I4045c8fd5ab5653cd390ceb29cfef76bd6c520a2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115587
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/chart2/source/view/axes/VCartesianAxis.cxx 
b/chart2/source/view/axes/VCartesianAxis.cxx
index ebd045a24845..fcb3391c693c 100644
--- a/chart2/source/view/axes/VCartesianAxis.cxx
+++ b/chart2/source/view/axes/VCartesianAxis.cxx
@@ -1275,9 +1275,7 @@ void VCartesianAxis::get2DAxisMainLine(
 double fDeltaY = rEnd.getY() - rStart.getY();
 
 //only those points are candidates which are lying on exactly 
one wall as these are outer edges
-tScreenPosAndLogicPosList aPosList;
-aPosList.push_back( getScreenPosAndLogicPos( fMinX, 
fYOnYPlane, fZOther ) );
-aPosList.push_back( getScreenPosAndLogicPos( fMinX, fYOther, 
fZOnZPlane ) );
+tScreenPosAndLogicPosList aPosList { getScreenPosAndLogicPos( 
fMinX, fYOnYPlane, fZOther ), getScreenPosAndLogicPos( fMinX, fYOther, 
fZOnZPlane ) };
 
 if( fabs(fDeltaY) > fabs(fDeltaX)  )
 {
@@ -1329,9 +1327,7 @@ void VCartesianAxis::get2DAxisMainLine(
 double fDeltaY = rEnd.getY() - rStart.getY();
 
 //only those points are candidates which are lying on exactly 
one wall as these are outer edges
-tScreenPosAndLogicPosList aPosList;
-aPosList.push_back( getScreenPosAndLogicPos( fXOnXPlane, 
fMinY, fZOther ) );
-aPosList.push_back( getScreenPosAndLogicPos( fXOther, fMinY, 
fZOnZPlane ) );
+tScreenPosAndLogicPosList aPosList { getScreenPosAndLogicPos( 
fXOnXPlane, fMinY, fZOther ), getScreenPosAndLogicPos( fXOther, fMinY, 
fZOnZPlane ) };
 
 if( fabs(fDeltaY) > fabs(fDeltaX)  )
 {
@@ -1408,9 +1404,7 @@ void VCartesianAxis::get2DAxisMainLine(
 double fDeltaX = rEnd.getX() - rStart.getX();
 
 //only those points are candidates which are lying on exactly 
one wall as these are outer edges
-tScreenPosAndLogicPosList aPosList;
-aPosList.push_back( getScreenPosAndLogicPos( fXOther, 
fYOnYPlane, fMinZ ) );
-aPosList.push_back( getScreenPosAndLogicPos( fXOnXPlane, 
fYOther, fMinZ ) );
+tScreenPosAndLogicPosList aPosList { getScreenPosAndLogicPos( 
fXOther, fYOnYPlane, fMinZ ), getScreenPosAndLogicPos( fXOnXPlane, fYOther, 
fMinZ ) };
 
 std::sort( aPosList.begin(), aPosList.end(), lcl_GreaterYPos() 
);
 ScreenPosAndLogicPos aBestPos( aPosList[0] );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-14 Thread Julien Nabet (via logerrit)
 canvas/source/opengl/ogl_spritedevicehelper.cxx |9 -
 1 file changed, 4 insertions(+), 5 deletions(-)

New commits:
commit ee2199a4356c9a74b4a3e817f7aef268efba5123
Author: Julien Nabet 
AuthorDate: Fri May 14 10:25:09 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 15:56:58 2021 +0200

Directly initialize vectors in ogl_spritedevicehelper.cxx

since we've got all the information from the beginning.

static_cast were needed to avoid this kind of error:

/home/julien/lo/libreoffice/canvas/source/opengl/ogl_spritedevicehelper.cxx:305:36:
 error: non-constant-expression cannot be narrowed from type 'sal_uInt32' (aka 
'unsigned int') to 'double' in initializer list [-Wc++11-narrowing]
   mpTextureCache->getCacheMissCount(), 
mpTextureCache->getCacheHitCount() }
   ^~~

/home/julien/lo/libreoffice/canvas/source/opengl/ogl_spritedevicehelper.cxx:305:36:
 note: insert an explicit cast to silence this issue
   mpTextureCache->getCacheMissCount(), 
mpTextureCache->getCacheHitCount() }
   ^~~
   static_cast(   )
Change-Id: If2705251cc4a246c2b8cb0bf873d413b3c572880

Change-Id: Ie1ce45cb6518fe97442ec5f3f05d34bae586b417
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115585
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/canvas/source/opengl/ogl_spritedevicehelper.cxx 
b/canvas/source/opengl/ogl_spritedevicehelper.cxx
index bcca03d0bd45..7e838162e6c3 100644
--- a/canvas/source/opengl/ogl_spritedevicehelper.cxx
+++ b/canvas/source/opengl/ogl_spritedevicehelper.cxx
@@ -301,11 +301,10 @@ namespace oglcanvas
 maLastUpdate.reset();
 
 const double fps(denominator == 0.0 ? 100.0 : 1.0/denominator);
-std::vector aVec; aVec.push_back(fps);
-aVec.push_back(maActiveSprites.size());
-aVec.push_back(mpTextureCache->getCacheSize());
-aVec.push_back(mpTextureCache->getCacheMissCount());
-aVec.push_back(mpTextureCache->getCacheHitCount());
+std::vector aVec { fps, 
static_cast(maActiveSprites.size()),
+
static_cast(mpTextureCache->getCacheSize()),
+
static_cast(mpTextureCache->getCacheMissCount()),
+
static_cast(mpTextureCache->getCacheHitCount()) };
 renderOSD( aVec, 20 );
 
 /*
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-14 Thread Julien Nabet (via logerrit)
 connectivity/source/drivers/calc/CDatabaseMetaData.cxx |   22 +++--
 1 file changed, 10 insertions(+), 12 deletions(-)

New commits:
commit 23b39541ddab1bcbeeea9cb6ecb7b5f18d4220a3
Author: Julien Nabet 
AuthorDate: Fri May 14 14:06:04 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 16:16:38 2021 +0200

Directly initialize ODatabaseMetaDataResultSet in CDatabaseMetaData.cxx

Change-Id: I32af6d9c699689b688d996c56fd5f64c5ed2f71d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115608
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/connectivity/source/drivers/calc/CDatabaseMetaData.cxx 
b/connectivity/source/drivers/calc/CDatabaseMetaData.cxx
index bbed24e0c5e2..04945e71de6c 100644
--- a/connectivity/source/drivers/calc/CDatabaseMetaData.cxx
+++ b/connectivity/source/drivers/calc/CDatabaseMetaData.cxx
@@ -175,12 +175,11 @@ Reference< XResultSet > SAL_CALL 
OCalcDatabaseMetaData::getTables(
 OUString aName = aSheetNames[nSheet];
 if ( !lcl_IsEmptyOrHidden( xSheets, aName ) && 
match(tableNamePattern,aName,'\0') )
 {
-ODatabaseMetaDataResultSet::ORow aRow { nullptr, nullptr, nullptr 
};
-aRow.reserve(6);
-aRow.push_back(new ORowSetValueDecorator(aName));
-aRow.push_back(new ORowSetValueDecorator(aTable));
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRows.push_back(aRow);
+aRows.push_back( { nullptr, nullptr, nullptr,
+   new ORowSetValueDecorator(aName),
+   new ORowSetValueDecorator(aTable),
+   ODatabaseMetaDataResultSet::getEmptyValue()
+ } );
 }
 }
 
@@ -200,12 +199,11 @@ Reference< XResultSet > SAL_CALL 
OCalcDatabaseMetaData::getTables(
 OUString aName = aDBNames[nRange];
 if ( !lcl_IsUnnamed( xRanges, aName ) && 
match(tableNamePattern,aName,'\0') )
 {
-ODatabaseMetaDataResultSet::ORow aRow { nullptr, nullptr, 
nullptr };
-aRow.reserve(6);
-aRow.push_back(new ORowSetValueDecorator(aName));
-aRow.push_back(new ORowSetValueDecorator(aTable));
-
aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRows.push_back(aRow);
+aRows.push_back( { nullptr, nullptr, nullptr,
+   new ORowSetValueDecorator(aName),
+   new ORowSetValueDecorator(aTable),
+   
ODatabaseMetaDataResultSet::getEmptyValue()
+ } );
 }
 }
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-14 Thread Julien Nabet (via logerrit)
 basctl/source/basicide/baside2b.cxx |   11 +++
 1 file changed, 3 insertions(+), 8 deletions(-)

New commits:
commit 6aca0107c25b2cf0b26ed09c6ea3917e85542d54
Author: Julien Nabet 
AuthorDate: Fri May 14 09:58:13 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 20:41:33 2021 +0200

Directly initialize vectors in baside2b.cxx

since we've got all the information from the beginning.

Change-Id: I58dff3fea715af09f3027d92c0504c3e27015f1c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115584
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/basctl/source/basicide/baside2b.cxx 
b/basctl/source/basicide/baside2b.cxx
index ecba2d5fa873..5a1bae42fd93 100644
--- a/basctl/source/basicide/baside2b.cxx
+++ b/basctl/source/basicide/baside2b.cxx
@@ -1640,14 +1640,9 @@ WatchWindow::WatchWindow(Layout* pParent)
 m_xTreeListBox->connect_changed( LINK( this, WatchWindow, TreeListHdl ) );
 m_xTreeListBox->connect_expanding(LINK(this, WatchWindow, 
RequestingChildrenHdl));
 
-std::vector aWidths;
-std::vector aEditables;
-aWidths.push_back(220);  // VarTabWidth
-aEditables.push_back(false);
-aWidths.push_back(100);  // ValueTabWidth
-aEditables.push_back(true);
-aWidths.push_back(1250); // TypeTabWidth
-aEditables.push_back(false);
+// VarTabWidth, ValueTabWidth, TypeTabWidth
+std::vector aWidths { 220, 100, 1250 };
+std::vector aEditables { false, true, false };
 m_xTreeListBox->set_column_fixed_widths(aWidths);
 m_xTreeListBox->set_column_editables(aEditables);
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-14 Thread Julien Nabet (via logerrit)
 connectivity/source/drivers/component/CDatabaseMetaData.cxx |   46 +---
 connectivity/source/drivers/dbase/DDatabaseMetaData.cxx |   45 ++-
 connectivity/source/drivers/dbase/DTable.cxx|   12 +--
 3 files changed, 52 insertions(+), 51 deletions(-)

New commits:
commit 2d41535a89f2540800494cee339da2c71cdb9666
Author: Julien Nabet 
AuthorDate: Fri May 14 15:04:10 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 20:41:48 2021 +0200

Directly initialize vector in connectivity (part 1)

Change-Id: I3b0bf1ca710aba58d7d649687b5d791374be8d6e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115610
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/connectivity/source/drivers/component/CDatabaseMetaData.cxx 
b/connectivity/source/drivers/component/CDatabaseMetaData.cxx
index ea5ca9f31879..cb5d1dcab4eb 100644
--- a/connectivity/source/drivers/component/CDatabaseMetaData.cxx
+++ b/connectivity/source/drivers/component/CDatabaseMetaData.cxx
@@ -53,31 +53,29 @@ Reference< XResultSet > 
OComponentDatabaseMetaData::impl_getTypeInfo_throw(  )
 static ODatabaseMetaDataResultSet::ORows aRows;
 if(aRows.empty())
 {
-ODatabaseMetaDataResultSet::ORow aRow;
-
 aRows.reserve(6);
-aRow.reserve(18);
-
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(new ORowSetValueDecorator(OUString("VARCHAR")));
-aRow.push_back(new ORowSetValueDecorator(DataType::VARCHAR));
-aRow.push_back(new ORowSetValueDecorator(sal_Int32(65535)));
-aRow.push_back(ODatabaseMetaDataResultSet::getQuoteValue());
-aRow.push_back(ODatabaseMetaDataResultSet::getQuoteValue());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(ODatabaseMetaDataResultSet::get1Value()); // 
ORowSetValue((sal_Int32)ColumnValue::NULLABLE)
-aRow.push_back(ODatabaseMetaDataResultSet::get1Value());
-aRow.push_back(new 
ORowSetValueDecorator(sal_Int32(ColumnSearch::CHAR)));
-aRow.push_back(ODatabaseMetaDataResultSet::get1Value());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(new ORowSetValueDecorator(sal_Int32(10)));
-
+ODatabaseMetaDataResultSet::ORow aRow
+{
+ODatabaseMetaDataResultSet::getEmptyValue(),
+new ORowSetValueDecorator(OUString("VARCHAR")),
+new ORowSetValueDecorator(DataType::VARCHAR),
+new ORowSetValueDecorator(sal_Int32(65535)),
+ODatabaseMetaDataResultSet::getQuoteValue(),
+ODatabaseMetaDataResultSet::getQuoteValue(),
+ODatabaseMetaDataResultSet::getEmptyValue(),
+ODatabaseMetaDataResultSet::get1Value(), // 
ORowSetValue((sal_Int32)ColumnValue::NULLABLE
+ODatabaseMetaDataResultSet::get1Value(),
+new ORowSetValueDecorator(sal_Int32(ColumnSearch::CHAR)),
+ODatabaseMetaDataResultSet::get1Value(),
+ODatabaseMetaDataResultSet::get0Value(),
+ODatabaseMetaDataResultSet::get0Value(),
+ODatabaseMetaDataResultSet::getEmptyValue(),
+ODatabaseMetaDataResultSet::get0Value(),
+ODatabaseMetaDataResultSet::get0Value(),
+ODatabaseMetaDataResultSet::getEmptyValue(),
+ODatabaseMetaDataResultSet::getEmptyValue(),
+new ORowSetValueDecorator(sal_Int32(10))
+};
 
 aRows.push_back(aRow);
 
diff --git a/connectivity/source/drivers/dbase/DDatabaseMetaData.cxx 
b/connectivity/source/drivers/dbase/DDatabaseMetaData.cxx
index cb8113a52652..4bb3a0c7179a 100644
--- a/connectivity/source/drivers/dbase/DDatabaseMetaData.cxx
+++ b/connectivity/source/drivers/dbase/DDatabaseMetaData.cxx
@@ -61,28 +61,29 @@ Reference< XResultSet > 
ODbaseDatabaseMetaData::impl_getTypeInfo_throw(  )
 static ODatabaseMetaDataResultSet::ORows aRows;
 if(aRows.empty())
 {
-ODatabaseMetaDataResultSet::ORow aRow;
-aRow.reserve(19);
-
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(new ORowSetValueDecorator(OUString("VARCHAR")));
-aRow.push_back(new ORowSetValueDecorator(DataType::VARCHAR));
-aRow.push_back(new ORowSetValueDecorator(sal_Int32(254)));
-aRow.push_back(ODatabaseMetaDataResultSet::getQuoteValue());
-aRow.push_back(ODatabaseMetaDataResultSet::getQuoteValue());
-aRow.push_back(new ORowSetValueDecorator(OUString("length")));
-

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

2021-05-14 Thread Julien Nabet (via logerrit)
 connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx |   75 +++
 connectivity/source/drivers/file/FDatabaseMetaData.cxx   |5 -
 connectivity/source/drivers/file/FDriver.cxx |   28 +++--
 3 files changed, 53 insertions(+), 55 deletions(-)

New commits:
commit 46d3e84d7a131f7c72cb536ab2f314cb55ffc155
Author: Julien Nabet 
AuthorDate: Fri May 14 15:25:25 2021 +0200
Commit: Julien Nabet 
CommitDate: Fri May 14 20:42:15 2021 +0200

Directly initialize vector in connectivity (part 2)

Change-Id: I4dc9862a30fc584e600d2952d1110a1ebbcd160d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115611
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx 
b/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx
index ead76b086ce5..455bf09e6733 100644
--- a/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx
+++ b/connectivity/source/drivers/evoab2/NDatabaseMetaData.cxx
@@ -988,15 +988,12 @@ Reference< XResultSet > SAL_CALL 
OEvoabDatabaseMetaData::getTableTypes(  )
 rtl::Reference<::connectivity::ODatabaseMetaDataResultSet> pResult = new 
::connectivity::ODatabaseMetaDataResultSet(::connectivity::ODatabaseMetaDataResultSet::eTableTypes);
 
 // here we fill the rows which should be visible when ask for data from 
the resultset returned here
-ODatabaseMetaDataResultSet::ORows aRows;
-for(std::size_t i=0;i < SAL_N_ELEMENTS(sTableTypes);++i)
+auto nNbTypes = SAL_N_ELEMENTS(sTableTypes);
+ODatabaseMetaDataResultSet::ORows aRows(nNbTypes);
+for(std::size_t i=0;i < nNbTypes;++i)
 {
-ODatabaseMetaDataResultSet::ORow aRow;
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(new ORowSetValueDecorator(OUString(sTableTypes[i])));
-
 // bound row
-aRows.push_back(aRow);
+aRows.push_back( { ODatabaseMetaDataResultSet::getEmptyValue(), new 
ORowSetValueDecorator(OUString(sTableTypes[i])) });
 }
 // here we set the rows at the resultset
 pResult->setRows(aRows);
@@ -1013,29 +1010,29 @@ Reference< XResultSet > 
OEvoabDatabaseMetaData::impl_getTypeInfo_throw(  )
 
 static ODatabaseMetaDataResultSet::ORows aRows = []()
 {
-ODatabaseMetaDataResultSet::ORows tmp;
-ODatabaseMetaDataResultSet::ORow aRow;
-aRow.reserve(19);
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(new ORowSetValueDecorator(OUString("VARCHAR")));
-aRow.push_back(new ORowSetValueDecorator(DataType::VARCHAR));
-aRow.push_back(new 
ORowSetValueDecorator(sal_Int32(s_nCHAR_OCTET_LENGTH)));
-aRow.push_back(ODatabaseMetaDataResultSet::getQuoteValue());
-aRow.push_back(ODatabaseMetaDataResultSet::getQuoteValue());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-// aRow.push_back(new 
ORowSetValueDecorator((sal_Int32)ColumnValue::NULLABLE));
-aRow.push_back(ODatabaseMetaDataResultSet::get1Value());
-aRow.push_back(ODatabaseMetaDataResultSet::get1Value());
-aRow.push_back(new 
ORowSetValueDecorator(sal_Int32(ColumnSearch::FULL)));
-aRow.push_back(ODatabaseMetaDataResultSet::get1Value());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::get0Value());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
-aRow.push_back(new ORowSetValueDecorator(sal_Int32(10)));
+ODatabaseMetaDataResultSet::ORows tmp(2);
+ODatabaseMetaDataResultSet::ORow aRow
+{
+{ ODatabaseMetaDataResultSet::getEmptyValue() },
+{ new ORowSetValueDecorator(OUString("VARCHAR")) },
+{ new ORowSetValueDecorator(DataType::VARCHAR) },
+{ new ORowSetValueDecorator(sal_Int32(s_nCHAR_OCTET_LENGTH)) },
+{ ODatabaseMetaDataResultSet::getQuoteValue() },
+{ ODatabaseMetaDataResultSet::getQuoteValue() },
+{ ODatabaseMetaDataResultSet::getEmptyValue() },
+{ ODatabaseMetaDataResultSet::get1Value() },
+{ ODatabaseMetaDataResultSet::get1Value() },
+{ new ORowSetValueDecorator(sal_Int32(ColumnSearch::FULL)) },
+{ ODatabaseMetaDataResultSet::get1Value() },
+{ ODatabaseMetaDataResultSet::get0Value() },
+{ ODatabaseMetaDataResultSet::get0Value() },
+{ ODatabaseMetaDataResultSet::getEmptyValue() },
+{ ODatabaseMetaDataResultSet::get0Value() },
+{ ODatabaseMetaDataResultSet::get0Value() },
+{ ODatabaseMetaDataResultSet::getEmptyValue() 

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

2021-05-15 Thread Julien Nabet (via logerrit)
 sfx2/source/devtools/ObjectInspectorTreeHandler.cxx |   10 ++
 1 file changed, 6 insertions(+), 4 deletions(-)

New commits:
commit 2668f93205e5c006d1f8228aaef8dda0403bc08a
Author: Julien Nabet 
AuthorDate: Fri May 14 11:28:17 2021 +0200
Commit: Julien Nabet 
CommitDate: Sat May 15 10:00:48 2021 +0200

Fix regression in "Directly initialize vectors in sfx2/ObjectInsp..."

Change-Id: Ibd975c4da8ccfd44f5c2b779774a3834918603b0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115591
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sfx2/source/devtools/ObjectInspectorTreeHandler.cxx 
b/sfx2/source/devtools/ObjectInspectorTreeHandler.cxx
index 204cdb3c9319..60a81be9ab60 100644
--- a/sfx2/source/devtools/ObjectInspectorTreeHandler.cxx
+++ b/sfx2/source/devtools/ObjectInspectorTreeHandler.cxx
@@ -971,10 +971,12 @@ ObjectInspectorTreeHandler::ObjectInspectorTreeHandler(
 std::vector aPropertiesWidths(4, nPropertiesDigitWidth * 30);
 
mpObjectInspectorWidgets->mpPropertiesTreeView->set_column_fixed_widths(aPropertiesWidths);
 
-auto nMethodsDigitWidth = static_cast(
-
mpObjectInspectorWidgets->mpMethodsTreeView->get_approximate_digit_width());
-std::vector aMethodsWidths{ nMethodsDigitWidth * 30, 
nMethodsDigitWidth * 15,
- nMethodsDigitWidth * 30, 
nMethodsDigitWidth * 50 };
+auto nMethodsDigitWidth
+= 
mpObjectInspectorWidgets->mpMethodsTreeView->get_approximate_digit_width();
+std::vector aMethodsWidths{ static_cast(nMethodsDigitWidth * 30),
+ static_cast(nMethodsDigitWidth * 15),
+ static_cast(nMethodsDigitWidth * 30),
+ static_cast(nMethodsDigitWidth * 50) 
};
 
mpObjectInspectorWidgets->mpMethodsTreeView->set_column_fixed_widths(aMethodsWidths);
 
 pObjectInspectorWidgets->mpPaned->set_position(160);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-05-24 Thread Julien Nabet (via logerrit)
 sc/inc/olinetab.hxx  |2 +-
 sc/source/core/data/olinetab.cxx |   24 +---
 2 files changed, 6 insertions(+), 20 deletions(-)

New commits:
commit 706d423bb12c79f0e6c71b7e38d092d1bdf1c259
Author: Julien Nabet 
AuthorDate: Mon May 24 17:15:32 2021 +0200
Commit: Julien Nabet 
CommitDate: Mon May 24 20:59:25 2021 +0200

Teach ScOutlineCollection to return an iterator when calling erase, then 
use it

Hoping C++11 erase method std::map which returns an iterator is now known
for compiler of every env.

Change-Id: Ie4f87ce234228209257f7025e197fdf53ea7e69d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116066
Reviewed-by: Noel Grandin 
Reviewed-by: Julien Nabet 
Tested-by: Jenkins

diff --git a/sc/inc/olinetab.hxx b/sc/inc/olinetab.hxx
index d7ee741f56c5..45c4a65a6b9b 100644
--- a/sc/inc/olinetab.hxx
+++ b/sc/inc/olinetab.hxx
@@ -80,7 +80,7 @@ public:
 iterator end();
 const_iterator begin() const;
 const_iterator end() const;
-void erase(const iterator& pos);
+iterator erase(const iterator& pos);
 bool empty() const;
 
 iterator FindStart(SCCOLROW nMinStart);
diff --git a/sc/source/core/data/olinetab.cxx b/sc/source/core/data/olinetab.cxx
index ddcc4c4ed6ad..13fc17a7b35f 100644
--- a/sc/source/core/data/olinetab.cxx
+++ b/sc/source/core/data/olinetab.cxx
@@ -126,9 +126,9 @@ ScOutlineCollection::const_iterator 
ScOutlineCollection::end() const
 return m_Entries.end();
 }
 
-void ScOutlineCollection::erase(const iterator& pos)
+ScOutlineCollection::iterator ScOutlineCollection::erase(const iterator& pos)
 {
-m_Entries.erase(pos);
+return m_Entries.erase(pos);
 }
 
 bool ScOutlineCollection::empty() const
@@ -262,11 +262,7 @@ bool ScOutlineArray::Insert(
 return false;
 }
 aCollections[nMoveLevel+1].insert(*pEntry);
-size_t nPos = std::distance(rColl.begin(), it);
-rColl.erase(it);
-it = rColl.begin();
-std::advance(it, nPos);
-itEnd = rColl.end();
+it = rColl.erase(it);
 if (nMoveLevel == nDepth - 1)
 bNeedSize = true;
 }
@@ -345,12 +341,7 @@ void ScOutlineArray::PromoteSub(SCCOLROW nStartPos, 
SCCOLROW nEndPos, size_t nSt
 {
 aCollections[nLevel-1].insert(*pEntry);
 
-// Re-calc iterator positions after the tree gets invalidated
-size_t nPos = std::distance(rColl.begin(), it);
-rColl.erase(it);
-it = rColl.begin();
-std::advance(it, nPos);
-itEnd = rColl.end();
+it = rColl.erase(it);
 }
 else
 ++it;
@@ -368,12 +359,7 @@ void ScOutlineArray::PromoteSub(SCCOLROW nStartPos, 
SCCOLROW nEndPos, size_t nSt
 {
 aCollections[nLevel-1].insert(*pEntry);
 
-// Re-calc iterator positions after the tree gets invalidated
-size_t nPos = std::distance(rColl.begin(), it);
-rColl.erase(it);
-it = rColl.begin();
-std::advance(it, nPos);
-itEnd = rColl.end();
+it = rColl.erase(it);
 }
 else
 ++it;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-02 Thread Julien Nabet (via logerrit)
 slideshow/source/engine/shapes/viewmediashape.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 7e9c3569f9258877b5303f041283d4882d1290fe
Author: Julien Nabet 
AuthorDate: Tue Jun 1 19:08:13 2021 +0200
Commit: Julien Nabet 
CommitDate: Wed Jun 2 08:38:43 2021 +0200

tdf#92917: fix crash in Impress in viewmediashape (slideshow)

See bt here:
https://bugs.documentfoundation.org/attachment.cgi?id=172527

I thought about this patch comparing with 
OGLTransitionerImpl::initWindowFromSlideShowView in:
slideshow/source/engine/opengl/TransitionerImpl.cxx

304 /// take the XSlideShowView and extract the parent window from it. 
see viewmediashape.cxx
305 uno::Reference< rendering::XCanvas > xCanvas(mxView->getCanvas(), 
uno::UNO_QUERY_THROW);
306 uno::Sequence< uno::Any > aDeviceParams;
307 ::canvas::tools::getDeviceInfo( xCanvas, aDeviceParams );
...
317 OutputDevice* pDevice = reinterpret_cast(aVal);
318 vcl::Window* pWindow = pDevice ? pDevice->GetOwnerWindow() : 
nullptr;

Change-Id: I183cc8271f75fb145c27688c5594805792c1fdaf
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116551
Tested-by: Jenkins
Reviewed-by: Noel Grandin 
Reviewed-by: Julien Nabet 

diff --git a/slideshow/source/engine/shapes/viewmediashape.cxx 
b/slideshow/source/engine/shapes/viewmediashape.cxx
index cddaea4c1b0b..2179f71ba78c 100644
--- a/slideshow/source/engine/shapes/viewmediashape.cxx
+++ b/slideshow/source/engine/shapes/viewmediashape.cxx
@@ -393,7 +393,8 @@ namespace slideshow::internal
 
 rVCLDeviceParams[ 1 ] >>= aVal;
 
-vcl::Window* pWindow = reinterpret_cast< vcl::Window* >( aVal 
);
+OutputDevice* pDevice = reinterpret_cast(aVal);
+vcl::Window* pWindow = pDevice ? pDevice->GetOwnerWindow() : 
nullptr;
 
 if( pWindow )
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-05 Thread Julien Nabet (via logerrit)
 oox/source/crypto/CryptTools.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 399a6472f666ae6c3e20b6f8367f9fd089c15605
Author: Julien Nabet 
AuthorDate: Sat Jun 5 08:09:40 2021 +0200
Commit: Julien Nabet 
CommitDate: Sat Jun 5 19:08:08 2021 +0200

Potentially uninitialized local variable 'aEvpMd' used

Seen on Win10:
cd C:/cygwin/home/serva/lode/dev/core/oox && 
C:/cygwin/home/serva/lode/opt/bin/make -j 1 -rs build
[build DEP] LNK:Library/ooxlo.dll
[build CXX] oox/source/crypto/CryptTools.cxx
C:\cygwin\home\serva\lode\dev\core\oox\source\crypto\CryptTools.cxx(122) : 
error C2220: the following warning is treated as an error
C:\cygwin\home\serva\lode\dev\core\oox\source\crypto\CryptTools.cxx(122) : 
warning C4701: potentially uninitialized local variable 'aEvpMd' used
C:\cygwin\home\serva\lode\dev\core\oox\source\crypto\CryptTools.cxx(122) : 
warning C4703: potentially uninitialized local pointer variable 'aEvpMd' used
make[1]: *** 
[C:/cygwin/home/serva/lode/dev/core/solenv/gbuild/LinkTarget.mk:301: 
C:/cygwin/home/serva/lode/dev/core/workdir/CxxObject/oox/source/crypto/CryptTools.o]
 Error 2
make: *** [Makefile:122: oox.build] Error 2

Change-Id: Id9409c95aa3edf866671ef8418e7ade3cbc1e718
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116740
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/oox/source/crypto/CryptTools.cxx b/oox/source/crypto/CryptTools.cxx
index 77b6f8c11988..6baf1f98ae98 100644
--- a/oox/source/crypto/CryptTools.cxx
+++ b/oox/source/crypto/CryptTools.cxx
@@ -109,7 +109,7 @@ struct CryptoImpl
 void setupCryptoHashContext(std::vector& rKey, CryptoHashType 
eType)
 {
 mpHmacContext.reset(HMAC_CTX_new());
-const EVP_MD* aEvpMd;
+const EVP_MD* aEvpMd = nullptr;
 switch (eType)
 {
 case CryptoHashType::SHA1:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: accessibility/source binaryurp/source

2021-06-05 Thread Julien Nabet (via logerrit)
 accessibility/source/extended/AccessibleGridControlHeader.cxx |6 ++
 accessibility/source/extended/AccessibleGridControlTable.cxx  |3 +--
 binaryurp/source/bridge.cxx   |3 +--
 3 files changed, 4 insertions(+), 8 deletions(-)

New commits:
commit 3e8e5f079e032a2b7b709bc01113f14da893263c
Author: Julien Nabet 
AuthorDate: Sat Jun 5 00:21:06 2021 +0200
Commit: Julien Nabet 
CommitDate: Sat Jun 5 16:21:03 2021 +0200

Simplify Sequences initializations (accessibility/binaryurp)

Change-Id: I4b388b7faa1dc47f27d29aaaff9041fe81a29f71
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116739
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/accessibility/source/extended/AccessibleGridControlHeader.cxx 
b/accessibility/source/extended/AccessibleGridControlHeader.cxx
index d5f80820a4e3..7c6c2df5925d 100644
--- a/accessibility/source/extended/AccessibleGridControlHeader.cxx
+++ b/accessibility/source/extended/AccessibleGridControlHeader.cxx
@@ -140,14 +140,12 @@ Reference< XAccessibleTable > SAL_CALL 
AccessibleGridControlHeader::getAccessibl
 //not selectable
 Sequence< sal_Int32 > SAL_CALL 
AccessibleGridControlHeader::getSelectedAccessibleRows()
 {
-Sequence< sal_Int32 > aSelSeq(0);
-return aSelSeq;
+return {};
 }
 //columns aren't selectable
 Sequence< sal_Int32 > SAL_CALL 
AccessibleGridControlHeader::getSelectedAccessibleColumns()
 {
-Sequence< sal_Int32 > aSelSeq(0);
-return aSelSeq;
+return {};
 }
 //row headers not selectable
 sal_Bool SAL_CALL AccessibleGridControlHeader::isAccessibleRowSelected( 
sal_Int32 /*nRow*/ )
diff --git a/accessibility/source/extended/AccessibleGridControlTable.cxx 
b/accessibility/source/extended/AccessibleGridControlTable.cxx
index eb222d6ed6ac..ffb8108d0f24 100644
--- a/accessibility/source/extended/AccessibleGridControlTable.cxx
+++ b/accessibility/source/extended/AccessibleGridControlTable.cxx
@@ -155,8 +155,7 @@ Sequence< sal_Int32 > SAL_CALL 
AccessibleGridControlTable::getSelectedAccessible
 //columns aren't selectable
 Sequence< sal_Int32 > SAL_CALL 
AccessibleGridControlTable::getSelectedAccessibleColumns()
 {
-Sequence< sal_Int32 > aSelSeq(0);
-return aSelSeq;
+return {};
 }
 
 sal_Bool SAL_CALL AccessibleGridControlTable::isAccessibleRowSelected( 
sal_Int32 nRow )
diff --git a/binaryurp/source/bridge.cxx b/binaryurp/source/bridge.cxx
index acefb175e8ec..007e7e9440df 100644
--- a/binaryurp/source/bridge.cxx
+++ b/binaryurp/source/bridge.cxx
@@ -951,8 +951,7 @@ void Bridge::sendCommitChangeRequest() {
 assert(mode_ == MODE_REQUESTED || mode_ == MODE_REPLY_1);
 css::uno::Sequence< css::bridge::ProtocolProperty > s(1);
 s[0].Name = "CurrentContext";
-std::vector< BinaryAny > a;
-a.push_back(mapCppToBinaryAny(css::uno::Any(s)));
+std::vector< BinaryAny > a { mapCppToBinaryAny(css::uno::Any(s)) };
 sendProtPropRequest(OutgoingRequest::KIND_COMMIT_CHANGE, a);
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-07 Thread Julien Nabet (via logerrit)
 canvas/qa/cppunit/canvastest.cxx   |7 +-
 canvas/source/cairo/cairo_canvashelper.cxx |   26 +---
 canvas/source/directx/dx_impltools.cxx |   15 ++
 canvas/workben/canvasdemo.cxx  |   31 +
 4 files changed, 37 insertions(+), 42 deletions(-)

New commits:
commit 87e8d5ec6bb2fa332d2c374040d39ca18462cb6f
Author: Julien Nabet 
AuthorDate: Fri Jun 4 22:19:30 2021 +0200
Commit: Julien Nabet 
CommitDate: Mon Jun 7 12:58:48 2021 +0200

Simplify Sequences initializations (canvas)

Change-Id: I651858d71e378341205d6a785bd97f294664a439
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116737
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/canvas/qa/cppunit/canvastest.cxx b/canvas/qa/cppunit/canvastest.cxx
index 993983377d08..5414a757d3c3 100644
--- a/canvas/qa/cppunit/canvastest.cxx
+++ b/canvas/qa/cppunit/canvastest.cxx
@@ -114,11 +114,8 @@ public:
 mRenderState.AffineTransform = geometry::AffineMatrix2D(2, 0, 0, 0, 2, 
0);
 mViewState.AffineTransform = geometry::AffineMatrix2D(5, 0, 0, 0, 5, 
0);
 
-uno::Sequence points(2);
-points[0] = geometry::RealPoint2D(10, 5);
-points[1] = geometry::RealPoint2D(88, 5);
-uno::Sequence> polygonPoints(1);
-polygonPoints[0] = points;
+uno::Sequence> polygonPoints{ { { 
10, 5 },
+ { 
88, 5 } } };
 uno::Reference polygon
 = mDevice->createCompatibleLinePolyPolygon(polygonPoints);
 polygon->setClosed(0, false);
diff --git a/canvas/source/cairo/cairo_canvashelper.cxx 
b/canvas/source/cairo/cairo_canvashelper.cxx
index 2711634e9948..f9e197d3447a 100644
--- a/canvas/source/cairo/cairo_canvashelper.cxx
+++ b/canvas/source/cairo/cairo_canvashelper.cxx
@@ -404,23 +404,25 @@ namespace cairocanvas
 {
 if( rLeft.getLength() == 3 )
 {
-uno::Sequence aRes(3);
-aRes[0] = basegfx::utils::lerp(rLeft[0],rRight[0],fAlpha);
-aRes[1] = basegfx::utils::lerp(rLeft[1],rRight[1],fAlpha);
-aRes[2] = basegfx::utils::lerp(rLeft[2],rRight[2],fAlpha);
-return aRes;
+return
+{
+basegfx::utils::lerp(rLeft[0],rRight[0],fAlpha),
+basegfx::utils::lerp(rLeft[1],rRight[1],fAlpha),
+basegfx::utils::lerp(rLeft[2],rRight[2],fAlpha)
+};
 }
 else if( rLeft.getLength() == 4 )
 {
-uno::Sequence aRes(4);
-aRes[0] = basegfx::utils::lerp(rLeft[0],rRight[0],fAlpha);
-aRes[1] = basegfx::utils::lerp(rLeft[1],rRight[1],fAlpha);
-aRes[2] = basegfx::utils::lerp(rLeft[2],rRight[2],fAlpha);
-aRes[3] = basegfx::utils::lerp(rLeft[3],rRight[3],fAlpha);
-return aRes;
+return
+{
+basegfx::utils::lerp(rLeft[0],rRight[0],fAlpha),
+basegfx::utils::lerp(rLeft[1],rRight[1],fAlpha),
+basegfx::utils::lerp(rLeft[2],rRight[2],fAlpha),
+basegfx::utils::lerp(rLeft[3],rRight[3],fAlpha)
+};
 }
 
-return uno::Sequence();
+return {};
 }
 
 static cairo_pattern_t* patternFromParametricPolyPolygon( 
::canvas::ParametricPolyPolygon const & rPolygon )
diff --git a/canvas/source/directx/dx_impltools.cxx 
b/canvas/source/directx/dx_impltools.cxx
index 27b98364bad1..7f464a8515b9 100644
--- a/canvas/source/directx/dx_impltools.cxx
+++ b/canvas/source/directx/dx_impltools.cxx
@@ -349,14 +349,13 @@ namespace dxcanvas::tools
 uno::Sequence< sal_Int8 > argbToIntSequence( Gdiplus::ARGB rColor )
 {
 // TODO(F1): handle color space conversions, when defined on 
canvas/graphicDevice
-uno::Sequence< sal_Int8 > aRet(4);
-
-aRet[0] = static_cast((rColor >> 16) & 0xFF); // red
-aRet[1] = static_cast((rColor >> 8) & 0xFF);  // green
-aRet[2] = static_cast(rColor & 0xFF); // blue
-aRet[3] = static_cast((rColor >> 24) & 0xFF); // alpha
-
-return aRet;
+return
+{
+static_cast((rColor >> 16) & 0xFF), // red
+static_cast((rColor >> 8) & 0xFF),  // green
+static_cast(rColor & 0xFF), // blue
+static_cast((rColor >> 24) & 0xFF)  // alpha
+};
 }
 
 Gdiplus::ARGB sequenceToArgb( const uno::Sequence< sal_Int8 >& rColor )
diff --git a/canvas/workben/canvasdemo.cxx b/canvas/workben/canvasdemo.cxx
index 9d48b84132d6..85791072d860 100644
--- a/canvas/workben/canvasdemo.cxx
+++ b/canvas/workben/canvasdemo.cxx
@@ -38,6 +38,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -155,17 +156,16 @@ class DemoRenderer
 
 void drawRect( 

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

2021-06-03 Thread Julien Nabet (via logerrit)
 dbaccess/source/core/api/HelperCollections.cxx |2 +-
 extensions/source/propctrlr/formlinkdialog.cxx |4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 23390e3096c2db2526cbc0867e3b2063e06f6150
Author: Julien Nabet 
AuthorDate: Thu Jun 3 07:06:53 2021 +0200
Commit: Stephan Bergmann 
CommitDate: Thu Jun 3 09:38:58 2021 +0200

Revert "Initialize vector directly with the already known count number"

This reverts commit da9fe0da11687bfc4c0eff2197286da67d6206c2.

Reason for revert: wrong result since there'll be first 4 by default 
initializations then an extra reserve allocation.

Change-Id: If480243e81db405d6a984b8450a219e486f1a1ff
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116465
Reviewed-by: Julien Nabet 
Tested-by: Jenkins

diff --git a/dbaccess/source/core/api/HelperCollections.cxx 
b/dbaccess/source/core/api/HelperCollections.cxx
index 12ab6414dfed..dfc18badc688 100644
--- a/dbaccess/source/core/api/HelperCollections.cxx
+++ b/dbaccess/source/core/api/HelperCollections.cxx
@@ -53,7 +53,7 @@ namespace dbaccess
 std::unique_ptr 
OPrivateColumns::createWithIntrinsicNames( const ::rtl::Reference< 
::connectivity::OSQLColumns >& _rColumns,
 bool _bCase, ::cppu::OWeakObject& _rParent, ::osl::Mutex& _rMutex )
 {
-std::vector< OUString > aNames(_rColumns->size());
+std::vector< OUString > aNames; aNames.reserve( _rColumns->size() );
 
 OUString sColumName;
 for (auto const& column : *_rColumns)
diff --git a/extensions/source/propctrlr/formlinkdialog.cxx 
b/extensions/source/propctrlr/formlinkdialog.cxx
index f367179b7a1c..7f2d794b4010 100644
--- a/extensions/source/propctrlr/formlinkdialog.cxx
+++ b/extensions/source/propctrlr/formlinkdialog.cxx
@@ -185,8 +185,8 @@ namespace pcr
 void FormLinkDialog::commitLinkPairs()
 {
 // collect the field lists from the rows
-std::vector< OUString > aDetailFields(4);
-std::vector< OUString > aMasterFields(4);
+std::vector< OUString > aDetailFields; aDetailFields.reserve( 4 );
+std::vector< OUString > aMasterFields; aMasterFields.reserve( 4 );
 
 const FieldLinkRow* aRows[] = {
 m_xRow1.get(), m_xRow2.get(), m_xRow3.get(), m_xRow4.get()
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-03 Thread Julien Nabet (via logerrit)
 connectivity/source/drivers/ado/ADriver.cxx  |   54 +++
 connectivity/source/drivers/dbase/DDriver.cxx|9 -
 connectivity/source/drivers/file/FDriver.cxx |   17 --
 connectivity/source/drivers/flat/EDriver.cxx |8 -
 connectivity/source/drivers/hsqldb/HDriver.cxx   |   47 +++---
 connectivity/source/drivers/jdbc/JDriver.cxx |7 
 connectivity/source/drivers/mysql_jdbc/YDriver.cxx   |   15 --
 connectivity/source/drivers/mysqlc/mysqlc_driver.cxx |9 -
 connectivity/source/drivers/odbc/ODriver.cxx |  139 +--
 9 files changed, 141 insertions(+), 164 deletions(-)

New commits:
commit f790fb5172bddba854448799081116aff96f2a42
Author: Julien Nabet 
AuthorDate: Thu Jun 3 09:15:01 2021 +0200
Commit: Julien Nabet 
CommitDate: Thu Jun 3 14:12:06 2021 +0200

Simplify some initializations in connectivity (2)

Change-Id: Iacbd1ccc58ebe6ef0a434e7334bc393d3457f889
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116638
Reviewed-by: Mike Kaganski 
Reviewed-by: Julien Nabet 
Tested-by: Jenkins

diff --git a/connectivity/source/drivers/ado/ADriver.cxx 
b/connectivity/source/drivers/ado/ADriver.cxx
index fcda87a9c0ab..e2d8cc2aa730 100644
--- a/connectivity/source/drivers/ado/ADriver.cxx
+++ b/connectivity/source/drivers/ado/ADriver.cxx
@@ -121,34 +121,32 @@ Sequence< DriverPropertyInfo > SAL_CALL 
ODriver::getPropertyInfo( const OUString
 impl_checkURL_throw(url);
 if ( acceptsURL(url) )
 {
-std::vector< DriverPropertyInfo > aDriverInfo;
-
-Sequence< OUString > aBooleanValues(2);
-aBooleanValues[0] = "false";
-aBooleanValues[1] = "true";
-
-aDriverInfo.push_back(DriverPropertyInfo(
-"IgnoreDriverPrivileges"
-,"Ignore the privileges from the database driver."
-,false
-,"false"
-,aBooleanValues)
-);
-aDriverInfo.push_back(DriverPropertyInfo(
-"EscapeDateTime"
-,"Escape date time format."
-,false
-,"true"
-,aBooleanValues)
-);
-aDriverInfo.push_back(DriverPropertyInfo(
-"TypeInfoSettings"
-,"Defines how the type info of the database metadata should be 
manipulated."
-,false
-,OUString( )
-,Sequence< OUString > ())
-);
-return Sequence< DriverPropertyInfo 
>(aDriverInfo.data(),aDriverInfo.size());
+Sequence< OUString > aBooleanValues{ "false", "true" };
+
+return
+{
+{
+ "IgnoreDriverPrivileges",
+ "Ignore the privileges from the database driver.",
+ false,
+ "false",
+ aBooleanValues
+},
+{
+"EscapeDateTime",
+"Escape date time format.",
+false,
+"true",
+aBooleanValues
+},
+{
+"TypeInfoSettings",
+"Defines how the type info of the database metadata should be 
manipulated.",
+false,
+{},
+{}
+}
+};
 }
 return Sequence< DriverPropertyInfo >();
 }
diff --git a/connectivity/source/drivers/dbase/DDriver.cxx 
b/connectivity/source/drivers/dbase/DDriver.cxx
index 8e571a04e98e..8eae0013c940 100644
--- a/connectivity/source/drivers/dbase/DDriver.cxx
+++ b/connectivity/source/drivers/dbase/DDriver.cxx
@@ -80,11 +80,10 @@ Sequence< DriverPropertyInfo > SAL_CALL 
ODriver::getPropertyInfo( const OUString
 {
 if ( acceptsURL(url) )
 {
-Sequence< OUString > aBoolean(2);
-aBoolean[0] = "0";
-aBoolean[1] = "1";
+Sequence< OUString > aBoolean { "0", "1" };
 
-DriverPropertyInfo aDriverInfo[] = {
+return
+{
 {
 "CharSet"
 ,"CharSet of the database."
@@ -107,8 +106,6 @@ Sequence< DriverPropertyInfo > SAL_CALL 
ODriver::getPropertyInfo( const OUString
 ,aBoolean
 }
 };
-
-return Sequence< DriverPropertyInfo >(aDriverInfo, 
std::size(aDriverInfo));
 }
 
 SharedResources aResources;
diff --git a/connectivity/source/drivers/file/FDriver.cxx 
b/connectivity/source/drivers/file/FDriver.cxx
index 5c251a402b5b..c5afbd75f7e3 100644
--- a/connectivity/source/drivers/file/FDriver.cxx
+++ b/connectivity/source/drivers/file/FDriver.cxx
@@ -98,25 +98,23 @@ Sequence< DriverPropertyInfo > SAL_CALL 
OFileDriver::getPropertyInfo( const OUSt
 if ( acceptsURL(url) )
 {
 
-Sequence< OUString > aBoolean(2);
-aBoolean[0] = "0";
-aBoolean[1] = "1";
+Sequence< OUString > aBoolean { "0", "1" };
 
-std::vector< DriverPropertyInfo > aDriverInfo
+return
 

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

2021-05-24 Thread Julien Nabet (via logerrit)
 svl/source/items/itempool.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit a0f6319ca5bb0fb19e7de59cafe7e7a7d47a1006
Author: Julien Nabet 
AuthorDate: Mon May 24 14:46:42 2021 +0200
Commit: Julien Nabet 
CommitDate: Mon May 24 16:54:24 2021 +0200

Fix documentation of SfxItemPool ctr

Change-Id: Ieead093b16c073e8b4b10d785c880287fa1994d4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116056
Reviewed-by: Noel Grandin 
Reviewed-by: Julien Nabet 
Tested-by: Jenkins

diff --git a/svl/source/items/itempool.cxx b/svl/source/items/itempool.cxx
index 20d0dcaca68e..32d7744b1837 100644
--- a/svl/source/items/itempool.cxx
+++ b/svl/source/items/itempool.cxx
@@ -143,8 +143,8 @@ SfxBroadcaster& SfxItemPool::BC()
  *  @see SfxItemPool::SetDefaults(std::vector*).
  *
  *  @see SfxItemPool::SetDefaults(std::vector*)
- *  @see 
SfxItemPool::ReleaseDefaults(std::vector*,sal_uInt16,sal_Bool)
- *  @see SfxItemPool::ReldaseDefaults(sal_Bool)
+ *  @see SfxItemPool::ReleaseDefaults(std::vector*,bool)
+ *  @see SfxItemPool::ReleaseDefaults(bool)
  */
 SfxItemPool::SfxItemPool
 (
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-01 Thread Julien Nabet (via logerrit)
 slideshow/source/engine/shapes/viewmediashape.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit e45575443ca5e4b6683e81e1c2e8e4a543b506fb
Author: Julien Nabet 
AuthorDate: Tue Jun 1 12:59:08 2021 +0200
Commit: Julien Nabet 
CommitDate: Tue Jun 1 15:41:22 2021 +0200

Reduce scope (slideshow/viewmediashape)

Change-Id: I3190aa77c5a13c6a6d1cf484b63916784954ea87
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116533
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/slideshow/source/engine/shapes/viewmediashape.cxx 
b/slideshow/source/engine/shapes/viewmediashape.cxx
index 29c6405b8725..cddaea4c1b0b 100644
--- a/slideshow/source/engine/shapes/viewmediashape.cxx
+++ b/slideshow/source/engine/shapes/viewmediashape.cxx
@@ -406,7 +406,6 @@ namespace slideshow::internal
 
 if( !rRangePix.isEmpty() )
 {
-uno::Sequence< uno::Any >   aArgs( 3 );
 awt::Rectangle  aAWTRect( 
rRangePix.getMinX(),
   
rRangePix.getMinY(),
 
rRangePix.getMaxX() - rRangePix.getMinX(),
@@ -433,6 +432,7 @@ namespace slideshow::internal
 
 if( mxPlayer.is() )
 {
+uno::Sequence< uno::Any >   aArgs( 3 );
 sal_IntPtr nParentWindowHandle(0);
 const SystemEnvData* pEnvData = 
mpMediaWindow->GetSystemData();
 // tdf#139609 gtk doesn't need the handle, and 
fetching it is undesirable
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-06-02 Thread Julien Nabet (via logerrit)
 dbaccess/source/core/api/HelperCollections.cxx |2 +-
 extensions/source/propctrlr/formlinkdialog.cxx |4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit da9fe0da11687bfc4c0eff2197286da67d6206c2
Author: Julien Nabet 
AuthorDate: Wed Jun 2 21:23:42 2021 +0200
Commit: Julien Nabet 
CommitDate: Wed Jun 2 23:22:03 2021 +0200

Initialize vector directly with the already known count number

instead of initializing an empty vector then reserve a fixed value

Change-Id: Iccddda05b3dd98aa9c25a61637ece7af4d42d72f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116624
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/dbaccess/source/core/api/HelperCollections.cxx 
b/dbaccess/source/core/api/HelperCollections.cxx
index dfc18badc688..12ab6414dfed 100644
--- a/dbaccess/source/core/api/HelperCollections.cxx
+++ b/dbaccess/source/core/api/HelperCollections.cxx
@@ -53,7 +53,7 @@ namespace dbaccess
 std::unique_ptr 
OPrivateColumns::createWithIntrinsicNames( const ::rtl::Reference< 
::connectivity::OSQLColumns >& _rColumns,
 bool _bCase, ::cppu::OWeakObject& _rParent, ::osl::Mutex& _rMutex )
 {
-std::vector< OUString > aNames; aNames.reserve( _rColumns->size() );
+std::vector< OUString > aNames(_rColumns->size());
 
 OUString sColumName;
 for (auto const& column : *_rColumns)
diff --git a/extensions/source/propctrlr/formlinkdialog.cxx 
b/extensions/source/propctrlr/formlinkdialog.cxx
index 7f2d794b4010..f367179b7a1c 100644
--- a/extensions/source/propctrlr/formlinkdialog.cxx
+++ b/extensions/source/propctrlr/formlinkdialog.cxx
@@ -185,8 +185,8 @@ namespace pcr
 void FormLinkDialog::commitLinkPairs()
 {
 // collect the field lists from the rows
-std::vector< OUString > aDetailFields; aDetailFields.reserve( 4 );
-std::vector< OUString > aMasterFields; aMasterFields.reserve( 4 );
+std::vector< OUString > aDetailFields(4);
+std::vector< OUString > aMasterFields(4);
 
 const FieldLinkRow* aRows[] = {
 m_xRow1.get(), m_xRow2.get(), m_xRow3.get(), m_xRow4.get()
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-2' - i18npool/source

2021-07-04 Thread Julien Nabet (via logerrit)
 i18npool/source/localedata/data/fr_FR.xml |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 7c7f113723ec5e908957cd4ae43ef0f3ec643504
Author: Julien Nabet 
AuthorDate: Sat Jul 3 23:51:11 2021 +0200
Commit: Eike Rathke 
CommitDate: Mon Jul 5 01:21:28 2021 +0200

tdf#143173: fix wrong French abbr for Alphabetical Index-Grouped entries

Change-Id: If478fc1127f957e05cdf7bc247881f0c59146896
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118366
Tested-by: Jenkins
Reviewed-by: Julien Nabet 
(cherry picked from commit 0151a178d4e26b4546f7b27d569f0d94420caa9d)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118307
Reviewed-by: Eike Rathke 

diff --git a/i18npool/source/localedata/data/fr_FR.xml 
b/i18npool/source/localedata/data/fr_FR.xml
index ac7e17710cf9..b2b3abb329bb 100644
--- a/i18npool/source/localedata/data/fr_FR.xml
+++ b/i18npool/source/localedata/data/fr_FR.xml
@@ -212,8 +212,8 @@
 A-Z
 0
 1
- sv
- sv
+ sq.
+ sqq.
   
   
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2021-07-01 Thread Julien Nabet (via logerrit)
 basic/source/runtime/methods.cxx |   10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

New commits:
commit 4a0b40f1be9f6773c8ebc5331c257911a76a5cee
Author: Julien Nabet 
AuthorDate: Wed Jun 30 22:55:46 2021 +0200
Commit: Noel Grandin 
CommitDate: Thu Jul 1 08:37:49 2021 +0200

tdf#143081: fix Basic Replace() function crashes LO

0x7f19c0aa6e57 in rtl::OUStringBuffer::append(char16_t const*, int) 
(this=0x7fff100d0748, str=0x6f6f46a u"晦饖香©", len=-1) at 
include/rtl/ustrbuf.hxx:659
0x7f19c0c3c8a8 in SbRtl_Replace(StarBASIC*, SbxArray&, bool) (rPar=...) 
at basic/source/runtime/methods.cxx:1321

see bt here:
https://bugs.documentfoundation.org/attachment.cgi?id=173298

Calling xCharClass->toUpper may change words, eg: "Straße" becomes "Strasse"
so the length of the word increases.
In brief, we want to use the length of aSrcStr not aExpStr

Change-Id: Ia291d47a2021efc7dd9162ca5cc72b7940fdd71e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118202
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index fb0e3e81aaa7..41f0d38ec1b0 100644
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -1285,8 +1285,6 @@ void SbRtl_Replace(StarBASIC *, SbxArray & rPar, bool)
 const OUString aExpStr = rPar.Get(1)->GetOUString();
 OUString aFindStr = rPar.Get(2)->GetOUString();
 const OUString aReplaceStr = rPar.Get(3)->GetOUString();
-const sal_Int32 nExpStrLen = aExpStr.getLength();
-const sal_Int32 nFindStrLen = aFindStr.getLength();
 
 OUString aSrcStr(aExpStr);
 if (bCaseInsensitive)
@@ -1298,10 +1296,12 @@ void SbRtl_Replace(StarBASIC *, SbxArray & rPar, bool)
 aSrcStr = xCharClass->toUpper(aSrcStr, 0, aSrcStr.getLength(), 
rLocale);
 aFindStr = xCharClass->toUpper(aFindStr, 0, aFindStr.getLength(), 
rLocale);
 }
+const sal_Int32 nSrcStrLen = aSrcStr.getLength();
+const sal_Int32 nFindStrLen = aFindStr.getLength();
 
 // Note: the result starts from lStartPos, removing everything to the 
left. See i#94895.
-sal_Int32 nPrevPos = std::min(lStartPos - 1, nExpStrLen);
-OUStringBuffer sResult(nExpStrLen - nPrevPos);
+sal_Int32 nPrevPos = std::min(lStartPos - 1, nSrcStrLen);
+OUStringBuffer sResult(nSrcStrLen - nPrevPos);
 sal_Int32 nCounts = 0;
 while (lCount == -1 || lCount > nCounts)
 {
@@ -1318,7 +1318,7 @@ void SbRtl_Replace(StarBASIC *, SbxArray & rPar, bool)
 break;
 }
 }
-sResult.append(aExpStr.getStr() + nPrevPos, nExpStrLen - nPrevPos);
+sResult.append(aExpStr.getStr() + nPrevPos, nSrcStrLen - nPrevPos);
 rPar.Get(0)->PutString(sResult.makeStringAndClear());
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


<    2   3   4   5   6   7   8   9   10   11   >