[Libreoffice-commits] core.git: 2 commits - slideshow/source smoketest/smoketest.cxx
slideshow/source/engine/shapes/gdimtftools.cxx| 40 +- slideshow/source/engine/shapes/viewmediashape.cxx | 10 ++- slideshow/source/engine/slide/targetpropertiescreator.cxx |3 - smoketest/smoketest.cxx | 19 +++--- 4 files changed, 35 insertions(+), 37 deletions(-) New commits: commit d07c4fe7681d90f20c4c0dafefc3439e8265e734 Author: Mike Kaganski AuthorDate: Fri Oct 29 10:06:09 2021 +0300 Commit: Mike Kaganski CommitDate: Sun Oct 31 06:57:21 2021 +0100 Prepare for removal of non-const operator[] from Sequence in smoketest Change-Id: Ica192dfb16716b4fb38d59eee0a39c6dd411b6a0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124390 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/smoketest/smoketest.cxx b/smoketest/smoketest.cxx index a60f58167f66..80a29036f19b 100644 --- a/smoketest/smoketest.cxx +++ b/smoketest/smoketest.cxx @@ -140,15 +140,16 @@ void Test::test() { CPPUNIT_ASSERT( test::getTestArgument( u"smoketest.doc", &doc)); -css::uno::Sequence< css::beans::PropertyValue > args(2); -args[0].Name = "MacroExecutionMode"; -args[0].Handle = -1; -args[0].Value <<= css::document::MacroExecMode::ALWAYS_EXECUTE_NO_WARN; -args[0].State = css::beans::PropertyState_DIRECT_VALUE; -args[1].Name = "ReadOnly"; -args[1].Handle = -1; -args[1].Value <<= true; -args[1].State = css::beans::PropertyState_DIRECT_VALUE; +css::uno::Sequence< css::beans::PropertyValue > args{ +{ /* Name */ "MacroExecutionMode", + /* Handle */ -1, + /* Value */ css::uno::Any(css::document::MacroExecMode::ALWAYS_EXECUTE_NO_WARN), + /* State */ css::beans::PropertyState_DIRECT_VALUE }, +{ /* Name */ "ReadOnly", + /* Handle */ -1, + /* Value */ css::uno::Any(true), + /* State */ css::beans::PropertyState_DIRECT_VALUE } +}; css::util::URL url; url.Complete = "vnd.sun.star.script:Standard.Global.StartTestWithDefaultOptions?" "language=Basic&location=document"; commit df16e70378cdc80b3e4c1327704a2781a4c57992 Author: Mike Kaganski AuthorDate: Fri Oct 29 10:05:16 2021 +0300 Commit: Mike Kaganski CommitDate: Sun Oct 31 06:57:10 2021 +0100 Prepare for removal of non-const operator[] from Sequence in slideshow Change-Id: Ic3d4835a6153ce3451e5ddf7a74310ea2b70da2c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124389 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/slideshow/source/engine/shapes/gdimtftools.cxx b/slideshow/source/engine/shapes/gdimtftools.cxx index 0f8644cd3da8..6a803f757711 100644 --- a/slideshow/source/engine/shapes/gdimtftools.cxx +++ b/slideshow/source/engine/shapes/gdimtftools.cxx @@ -29,6 +29,7 @@ #include #include +#include #include #include @@ -174,29 +175,22 @@ GDIMetaFileSharedPtr getMetaFile( const uno::Reference< lang::XComponent >& uno::Reference< drawing::XGraphicExportFilter > xExporter = drawing::GraphicExportFilter::create(rxContext); -uno::Sequence< beans::PropertyValue > aProps(3); -aProps[0].Name = "FilterName"; -aProps[0].Value <<= OUString("SVM"); - -aProps[1].Name = "GraphicRenderer"; -aProps[1].Value <<= uno::Reference< graphic::XGraphicRenderer >(xRenderer); - -uno::Sequence< beans::PropertyValue > aFilterData(4); -aFilterData[0].Name = "ScrollText"; -aFilterData[0].Value <<= ((mtfLoadFlags & MTF_LOAD_SCROLL_TEXT_MTF) != 0); - -aFilterData[1].Name = "ExportOnlyBackground"; -aFilterData[1].Value <<= ((mtfLoadFlags & MTF_LOAD_BACKGROUND_ONLY) != 0); - -aFilterData[2].Name = "Version"; -aFilterData[2].Value <<= static_cast( SOFFICE_FILEFORMAT_50 ); - -aFilterData[3].Name = "CurrentPage"; -aFilterData[3].Value <<= uno::Reference< uno::XInterface >( xContainingPage, - uno::UNO_QUERY_THROW ); - -aProps[2].Name = "FilterData"; -aProps[2].Value <<= aFilterData; +uno::Sequence< beans::PropertyValue > aFilterData{ +comphelper::makePropertyValue("ScrollText", + ((mtfLoadFlags & MTF_LOAD_SCROLL_TEXT_MTF) != 0)), +comphelper::makePropertyValue("ExportOnlyBackground", + ((mtfLoadFlags & MTF_LOAD_BACKGROUND_ONLY) != 0)), +comphelper::makePropertyValue("Version", static_cast( SOFFICE_FILEFORMAT_50 )), +comphelper::makePropertyValue( +"CurrentPage", uno::Reference< uno::XInterface >( xContainingPage, + uno::UNO_QUERY_THROW )) +}; + +uno::Sequence< beans::PropertyValue > aProps{ +comphelper::makePropertyValue("FilterName", OUString("SVM")), +comphelper::makePropertyValue("GraphicRenderer", uno::Reference< graphic::X
[Libreoffice-commits] core.git: 2 commits - sdext/source sfx2/source
sdext/source/minimizer/configurationaccess.cxx | 49 +++-- sdext/source/minimizer/impoptimizer.cxx| 62 --- sdext/source/minimizer/optimizationstats.cxx | 13 +- sdext/source/minimizer/optimizerdialog.cxx | 15 +- sdext/source/minimizer/optimizerdialogcontrols.cxx | 20 ++- sdext/source/pdfimport/filterdet.cxx | 27 +++-- sdext/source/pdfimport/misc/pwdinteract.cxx|4 sdext/source/pdfimport/odf/odfemitter.cxx |3 sdext/source/pdfimport/pdfiadaptor.cxx |8 - sdext/source/pdfimport/wrapper/wrapper.cxx | 15 +- sdext/source/presenter/PresenterAccessibility.cxx |3 sdext/source/presenter/PresenterCanvasHelper.cxx |9 - sdext/source/presenter/PresenterGeometryHelper.cxx |3 sdext/source/presenter/PresenterPaneFactory.cxx| 15 +- sdext/source/presenter/PresenterSlideShowView.cxx |4 sdext/source/presenter/PresenterWindowManager.cxx |9 - sfx2/source/appl/appopen.cxx |5 sfx2/source/appl/appserv.cxx |6 - sfx2/source/appl/newhelp.cxx |7 - sfx2/source/appl/shutdownicon.cxx | 33 +++--- sfx2/source/appl/shutdowniconaqua.mm | 18 +-- sfx2/source/control/charwin.cxx| 10 - sfx2/source/control/dispatch.cxx |9 - sfx2/source/control/recentdocsview.cxx |4 sfx2/source/control/recentdocsviewitem.cxx | 12 -- sfx2/source/control/request.cxx|2 sfx2/source/control/thumbnailview.cxx |4 sfx2/source/control/unoctitm.cxx | 28 ++--- sfx2/source/dialog/backingwindow.cxx | 28 ++--- sfx2/source/dialog/dinfdlg.cxx | 50 + sfx2/source/dialog/filedlghelper.cxx | 23 ++-- sfx2/source/dialog/filtergrouping.cxx | 10 + sfx2/source/dialog/mailmodel.cxx | 53 + sfx2/source/dialog/templdlg.cxx|6 - sfx2/source/doc/SfxDocumentMetaData.cxx| 44 +++- sfx2/source/doc/docfac.cxx | 18 +-- sfx2/source/doc/docfile.cxx| 81 --- sfx2/source/doc/doctempl.cxx |5 sfx2/source/doc/doctemplates.cxx | 30 + sfx2/source/doc/exoticfileloadexception.cxx|5 sfx2/source/doc/exoticfileloadexception.hxx|2 sfx2/source/doc/graphhelp.cxx | 15 +- sfx2/source/doc/guisaveas.cxx |7 - sfx2/source/doc/iframe.cxx | 10 - sfx2/source/doc/objmisc.cxx|9 - sfx2/source/doc/objstor.cxx| 68 +++- sfx2/source/doc/printhelper.cxx| 51 + sfx2/source/doc/sfxbasemodel.cxx | 112 +++-- sfx2/source/doc/templatedlg.cxx| 36 ++ sfx2/source/doc/zoomitem.cxx | 17 +-- sfx2/source/inet/inettbc.cxx | 11 +- sfx2/source/notify/globalevents.cxx|3 sfx2/source/sidebar/ResourceManager.cxx|3 sfx2/source/sidebar/UnoDecks.cxx | 12 -- sfx2/source/sidebar/UnoPanels.cxx | 12 -- sfx2/source/view/ipclient.cxx |7 - sfx2/source/view/lokcharthelper.cxx| 10 + sfx2/source/view/viewprn.cxx | 27 ++--- sfx2/source/view/viewsh.cxx|7 - 59 files changed, 574 insertions(+), 595 deletions(-) New commits: commit 8b9e502480812f61a1c8d37c465aaf93763fe156 Author: Mike Kaganski AuthorDate: Fri Oct 29 10:02:46 2021 +0300 Commit: Mike Kaganski CommitDate: Sun Oct 31 06:56:57 2021 +0100 Prepare for removal of non-const operator[] from Sequence in sdext Change-Id: I1992d1ffbbc80efe9749ebd254971a0a92a10019 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124386 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/sdext/source/minimizer/configurationaccess.cxx b/sdext/source/minimizer/configurationaccess.cxx index 0ed089e341a2..3479918c2dc9 100644 --- a/sdext/source/minimizer/configurationaccess.cxx +++ b/sdext/source/minimizer/configurationaccess.cxx @@ -25,6 +25,7 @@ #include #include #include +#include #include #include #include @@ -427,38 +428,24 @@ sal_Int32 ConfigurationAccess::GetConfigProperty( const PPPOptimizerTokenEnum eP Sequence< PropertyValue > ConfigurationAccess::GetConfigurationSequence() { -Sequence< PropertyValue > aRet( 15 ); OptimizerSettings& rSettings( maSettings.front() ); -aRet[ 0 ].Name = "JPEGCompression"; -aRet[ 0 ].Value <<= rSettings.mbJPEGCompression; -aRet[ 1 ].Name = "JPEG
Re: new installer
I think your friends should use the LibreOffice as packaged by their distro then. --tml
new installer
Hello, i have many friends who are nebies at Libre Office. There are many time confuse when they want install the new Libre Office. They have to use the terminal what is improper for a earlier windows user. So i wrote a piece of code to build an grafic user installer for Linux Mint and Ubuntu. Please check this nice installer. is for free and can be built in a Libre Office pack. Victor Beg installer.sh Description: application/shellscript Mittels "install.sh" haben sie unter Linux zugang zu eine Grafische Instalation oberfläche (Zenity). Unter Mint Cinnamon beim doppelclick auf datei werden Sie gefragt obsie es in terminal öffnen wollen oder als Anwendung. Wählen Sie terminal, "run in terminal". Untere andere Ubuntu derivate kann es vorkommen dass, das Datei nicht lauffähig ist bevor es nicht ausführbar gemacht wird. Dazu klicken sie mit rechte Maus taste auf Datei "install.sh" und wählen Sie aus den kontext- "Eigenschaften". Oben in der mitte sehen sie der reiter "Berechtigungen". Drauf klicken und ganz unten setzen sie das hacken für "ausführbar machen". Jetzt sollte das Program ganz normal starten mittels doppelklick (falls eingestellt). Sollte das unerwartete passieren und noch immer nicht funkionieren,bleibt nur mehr übrig-recthe Maus taste klick auf Datei, kopieren, terminal öffnen ,einfügen, Enter. With "install.sh" you have access to a graphical installation interface (Zenity) under Linux. Under Mint Cinnamon double-click on file and you will be asked whether you want to open it in terminal or as application. Choose terminal, "run in terminal". With other Ubuntu derivatives, it can happen that the file will not run before it is made executable. To do this, right-click on the "install.sh" file and select "Properties" from the context. At the top in the middle you can see the "Permisions" tab. Click on it and at the very bottom set the checkmark for "make executable". Now the program should start normally with a double click (if set). Should something unexpected happen and still not work, the only thing left to do is right-click on file, copy, open terminal, paste, enter.
[Libreoffice-commits] core.git: shell/source
shell/source/cmdmail/cmdmailmsg.cxx | 15 --- shell/source/cmdmail/cmdmailsuppl.cxx |3 +-- 2 files changed, 9 insertions(+), 9 deletions(-) New commits: commit c6af59b234e8eb8182dc7f686290524feafd6ed6 Author: Mike Kaganski AuthorDate: Fri Oct 29 10:04:32 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 23:18:51 2021 +0200 Prepare for removal of non-const operator[] from Sequence in shell Change-Id: Ie7792d0aa3f404d9177a1eb6f75569577fc3d6a9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124388 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/shell/source/cmdmail/cmdmailmsg.cxx b/shell/source/cmdmail/cmdmailmsg.cxx index 2a6a5f843af2..bb8c8bc05559 100644 --- a/shell/source/cmdmail/cmdmailmsg.cxx +++ b/shell/source/cmdmail/cmdmailmsg.cxx @@ -145,27 +145,28 @@ Sequence< OUString > SAL_CALL CmdMailMsg::getElementNames( ) sal_Int32 nItems = 0; Sequence< OUString > aRet( 7 ); +auto pRet = aRet.getArray(); if( !m_aBody.isEmpty() ) -aRet[nItems++] = "body"; +pRet[nItems++] = "body"; if( !m_aOriginator.isEmpty() ) -aRet[nItems++] = "from"; +pRet[nItems++] = "from"; if( !m_aRecipient.isEmpty() ) -aRet[nItems++] = "to"; +pRet[nItems++] = "to"; if( m_CcRecipients.hasElements() ) -aRet[nItems++] = "cc"; +pRet[nItems++] = "cc"; if( m_BccRecipients.hasElements() ) -aRet[nItems++] = "bcc"; +pRet[nItems++] = "bcc"; if( !m_aSubject.isEmpty() ) -aRet[nItems++] = "subject"; +pRet[nItems++] = "subject"; if( m_Attachments.hasElements() ) -aRet[nItems++] = "attachment"; +pRet[nItems++] = "attachment"; aRet.realloc( nItems ); return aRet; diff --git a/shell/source/cmdmail/cmdmailsuppl.cxx b/shell/source/cmdmail/cmdmailsuppl.cxx index c65372f5430e..00b6517c4648 100644 --- a/shell/source/cmdmail/cmdmailsuppl.cxx +++ b/shell/source/cmdmail/cmdmailsuppl.cxx @@ -147,8 +147,7 @@ void SAL_CALL CmdMailSuppl::sendSimpleMailMessage( const Reference< XSimpleMailM aProperty.Name = "nodepath"; aProperty.Value <<= OUString("org.openoffice.Office.Common/ExternalMailer"); -Sequence< Any > aArgumentList( 1 ); -aArgumentList[0] <<= aProperty; +Sequence< Any > aArgumentList{ Any(aProperty) }; Reference< XNameAccess > xNameAccess( m_xConfigurationProvider->createInstanceWithArguments(
[Libreoffice-commits] core.git: sd/qa sd/source
sd/qa/unit/import-tests.cxx | 64 ++--- sd/qa/unit/tiledrendering/tiledrendering.cxx |5 sd/source/core/CustomAnimationEffect.cxx | 15 - sd/source/core/EffectMigration.cxx|9 sd/source/filter/grf/sdgrffilter.cxx |5 sd/source/filter/html/HtmlOptionsDialog.cxx |2 sd/source/filter/html/buttonset.cxx |6 sd/source/filter/html/htmlex.cxx | 37 +-- sd/source/filter/ppt/pptinanimations.cxx | 52 ++-- sd/source/filter/xml/sdxmlwrp.cxx |3 sd/source/ui/animations/CustomAnimationDialog.cxx |5 sd/source/ui/animations/CustomAnimationPane.cxx |9 sd/source/ui/controller/slidelayoutcontroller.cxx |5 sd/source/ui/dlg/diactrl.cxx |9 sd/source/ui/dlg/gluectrl.cxx |7 sd/source/ui/framework/configuration/ConfigurationUpdater.cxx |3 sd/source/ui/framework/configuration/ResourceId.cxx |5 sd/source/ui/framework/factories/FullScreenPane.cxx | 16 - sd/source/ui/framework/factories/ViewShellWrapper.cxx |3 sd/source/ui/framework/module/ModuleController.cxx|6 sd/source/ui/presenter/PresenterHelper.cxx| 13 - sd/source/ui/remotecontrol/ImagePreparer.cxx | 33 +- sd/source/ui/slideshow/SlideShowRestarter.cxx |7 sd/source/ui/slideshow/slideshow.cxx | 24 -- sd/source/ui/slideshow/slideshowimpl.cxx | 18 - sd/source/ui/unoidl/SdUnoSlideView.cxx|3 sd/source/ui/unoidl/UnoDocumentSettings.cxx |8 sd/source/ui/unoidl/unomodel.cxx | 119 -- sd/source/ui/unoidl/unoobj.cxx|2 sd/source/ui/view/DocumentRenderer.cxx| 73 ++ sd/source/ui/view/ViewTabBar.cxx | 10 sd/source/ui/view/drviews5.cxx|5 sd/source/ui/view/drviewse.cxx| 11 sd/source/ui/view/sdview4.cxx |7 sd/source/ui/view/viewshe2.cxx|5 35 files changed, 276 insertions(+), 328 deletions(-) New commits: commit 94f34c57be79187c7108eea845e1303ddc6319e5 Author: Mike Kaganski AuthorDate: Fri Oct 29 10:02:01 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 23:13:41 2021 +0200 Prepare for removal of non-const operator[] from Sequence in sd Change-Id: I82dc012188f846161beeb54901c2f5d298e5c3b7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124385 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx index 561f5b71abc5..e1b71fd788cf 100644 --- a/sd/qa/unit/import-tests.cxx +++ b/sd/qa/unit/import-tests.cxx @@ -91,6 +91,7 @@ #include #include +#include #include #include #include @@ -1741,22 +1742,19 @@ void SdImportTest::testTdf113163() uno::Reference < uno::XComponentContext > xContext = ::comphelper::getProcessComponentContext(); uno::Reference< drawing::XGraphicExportFilter > xGraphicExporter = drawing::GraphicExportFilter::create(xContext); -uno::Sequence< beans::PropertyValue > aFilterData(2); -aFilterData[0].Name = "PixelWidth"; -aFilterData[0].Value <<= sal_Int32(100); -aFilterData[1].Name = "PixelHeight"; -aFilterData[1].Value <<= sal_Int32(100); +uno::Sequence< beans::PropertyValue > aFilterData{ +comphelper::makePropertyValue("PixelWidth", sal_Int32(100)), +comphelper::makePropertyValue("PixelHeight", sal_Int32(100)) +}; utl::TempFile aTempFile; aTempFile.EnableKillingFile(); -uno::Sequence< beans::PropertyValue > aDescriptor(3); -aDescriptor[0].Name = "URL"; -aDescriptor[0].Value <<= aTempFile.GetURL(); -aDescriptor[1].Name = "FilterName"; -aDescriptor[1].Value <<= OUString("PNG"); -aDescriptor[2].Name = "FilterData"; -aDescriptor[2].Value <<= aFilterData; +uno::Sequence< beans::PropertyValue > aDescriptor{ +comphelper::makePropertyValue("URL", aTempFile.GetURL()), +comphelper::makePropertyValue("FilterName", OUString("PNG")), +comphelper::makePropertyValue("FilterData", aFilterData) +}; uno::Reference< lang::XComponent > xPage(getPage(0, xDocShRef), uno::UNO_QUERY); xGraphicExporter->setSourceDocument(xPage); @@ -1794,22 +1792,19 @@ void SdImportTest::testTdf93124() uno::Reference < uno::XComponentContext > xContext = ::comphelper::getProcessComponentContext(); uno::Reference< drawing::
[Libreoffice-commits] core.git: cui/source
cui/source/dialogs/scriptdlg.cxx |3 +++ 1 file changed, 3 insertions(+) New commits: commit 2afbef0037f022a59ed1198f1f84e454d070df92 Author: Caolán McNamara AuthorDate: Fri Oct 29 12:39:22 2021 +0100 Commit: Caolán McNamara CommitDate: Sat Oct 30 22:40:43 2021 +0200 Related: tdf#145377 call select handler if restoring previously selected script Change-Id: Ibab3e920e6830c86bb6bfba070f14ca8a153c25f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124429 Tested-by: Jenkins Reviewed-by: Caolán McNamara diff --git a/cui/source/dialogs/scriptdlg.cxx b/cui/source/dialogs/scriptdlg.cxx index 4ae05a0c48e6..3bc7a52b40ab 100644 --- a/cui/source/dialogs/scriptdlg.cxx +++ b/cui/source/dialogs/scriptdlg.cxx @@ -1080,7 +1080,10 @@ void SvxScriptOrgDialog::RestorePreviousSelection() } if (xEntry) +{ m_xScriptsBox->set_cursor(*xEntry); +ScriptSelectHdl(*m_xScriptsBox); +} } namespace {
[Libreoffice-commits] core.git: canvas/source
canvas/source/directx/dx_textlayout_drawhelper.cxx |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) New commits: commit b9f098c5a2223417af89d69fd8c0548570fd3a9d Author: Mike Kaganski AuthorDate: Sat Oct 30 22:03:44 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 22:26:06 2021 +0200 Another tools::Long->sal_Int32 in the DX array A leftover from commit bc413e15fae3672f580894a3cd7b077d533d8e6c Change-Id: Ibacdf71f608657a4488c84b88ef54fb52d3e8439 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124496 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/canvas/source/directx/dx_textlayout_drawhelper.cxx b/canvas/source/directx/dx_textlayout_drawhelper.cxx index 6b5a389f77ae..e7623219c798 100644 --- a/canvas/source/directx/dx_textlayout_drawhelper.cxx +++ b/canvas/source/directx/dx_textlayout_drawhelper.cxx @@ -206,14 +206,14 @@ namespace dxcanvas { // create the DXArray const sal_Int32 nLen( rLogicalAdvancements.getLength() ); -std::unique_ptr<::tools::Long[]> pDXArray( new ::tools::Long[nLen] ); +std::unique_ptr pDXArray( std::make_unique(nLen) ); for( sal_Int32 i=0; iDrawTextArray( aEmptyPoint, aText, - o3tl::span( pDXArray.get(), nLen ), + o3tl::span( pDXArray.get(), nLen ), rText.StartPosition, rText.Length, bIsRTL ? SalLayoutFlags::BiDiRtl : SalLayoutFlags::NONE);
[Libreoffice-commits] core.git: scripting/source
scripting/source/basprov/basmethnode.cxx| 20 ++ scripting/source/dlgprov/dlgevtatt.cxx |2 - scripting/source/dlgprov/dlgprov.cxx| 16 +-- scripting/source/protocolhandler/scripthandler.cxx |6 ++-- scripting/source/provider/ActiveMSPList.cxx |7 ++--- scripting/source/provider/BrowseNodeFactoryImpl.cxx | 12 +--- scripting/source/provider/MasterScriptProvider.cxx | 12 +--- scripting/source/provider/ProviderCache.cxx |5 ++- scripting/source/vbaevents/eventhelper.cxx | 28 +--- 9 files changed, 49 insertions(+), 59 deletions(-) New commits: commit 22ba855d1a2317361c6ad8b631ae1bd707887435 Author: Mike Kaganski AuthorDate: Fri Oct 29 10:00:35 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 22:04:01 2021 +0200 Prepare for removal of non-const operator[] from Sequence in scripting Change-Id: Ia85fe6de38674c7982b0f983a798a4d99ec1fb70 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124384 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/scripting/source/basprov/basmethnode.cxx b/scripting/source/basprov/basmethnode.cxx index 688b4ef2140f..fca2cafe8d72 100644 --- a/scripting/source/basprov/basmethnode.cxx +++ b/scripting/source/basprov/basmethnode.cxx @@ -23,6 +23,8 @@ #include #include #include + +#include #include #include #include @@ -237,17 +239,13 @@ namespace basprov { Reference< frame::XDispatchHelper > xHelper( frame::DispatchHelper::create( m_xContext ) ); -Sequence < PropertyValue > aArgs(7); -aArgs[0].Name = "Document"; -aArgs[0].Value <<= sDocURL; -aArgs[1].Name = "LibName"; -aArgs[1].Value <<= sLibName; -aArgs[2].Name = "Name"; -aArgs[2].Value <<= sModName; -aArgs[3].Name = "Type"; -aArgs[3].Value <<= OUString("Module"); -aArgs[4].Name = "Line"; -aArgs[4].Value <<= static_cast< sal_uInt32 >( nLine1 ); +Sequence < PropertyValue > aArgs{ +comphelper::makePropertyValue("Document", sDocURL), +comphelper::makePropertyValue("LibName", sLibName), +comphelper::makePropertyValue("Name", sModName), +comphelper::makePropertyValue("Type", OUString("Module")), +comphelper::makePropertyValue("Line", static_cast< sal_uInt32 >( nLine1 )) +}; xHelper->executeDispatch( xProv, ".uno:BasicIDEAppear", OUString(), 0, aArgs ); } } diff --git a/scripting/source/dlgprov/dlgevtatt.cxx b/scripting/source/dlgprov/dlgevtatt.cxx index 43b5851c225a..704518e07aef 100644 --- a/scripting/source/dlgprov/dlgevtatt.cxx +++ b/scripting/source/dlgprov/dlgevtatt.cxx @@ -113,7 +113,7 @@ namespace dlgprov Sequence< Any > args(1); if ( xSMgr.is() ) { -args[0] <<= xModel; +args.getArray()[0] <<= xModel; mxListener.set( xSMgr->createInstanceWithArgumentsAndContext( "ooo.vba.EventListener", args, m_xContext ), UNO_QUERY ); } if ( !rxControl.is() ) diff --git a/scripting/source/dlgprov/dlgprov.cxx b/scripting/source/dlgprov/dlgprov.cxx index d52660904471..5a4e5c7eb124 100644 --- a/scripting/source/dlgprov/dlgprov.cxx +++ b/scripting/source/dlgprov/dlgprov.cxx @@ -71,15 +71,15 @@ namespace dlgprov OUString aDlgLocation = aInetObj.GetMainURL( INetURLObject::DecodeMechanism::NONE ); css::lang::Locale aLocale = Application::GetSettings().GetUILanguageTag().getLocale(); -Sequence aArgs( 6 ); -aArgs[0] <<= aDlgLocation; -aArgs[1] <<= true; // bReadOnly -aArgs[2] <<= aLocale; -aArgs[3] <<= aDlgName; -aArgs[4] <<= OUString(); - Reference< task::XInteractionHandler > xDummyHandler; -aArgs[5] <<= xDummyHandler; + +Sequence aArgs{ Any(aDlgLocation), + Any(true), // bReadOnly + Any(aLocale), + Any(aDlgName), + Any(OUString()), + Any(xDummyHandler) }; + Reference< XMultiComponentFactory > xSMgr_( i_xContext->getServiceManager(), UNO_SET_THROW ); // TODO: Ctor Reference< resource::XStringResourceManager > xStringResourceManager( xSMgr_->createInstanceWithContext diff --git a/scripting/source/protocolhandler/scripthandler.cxx b/scripting/source/protocolhandler/scripthandler.cxx index db9d746c81be..0ef2fdad21db 100644 --- a/scripting/source/protocolhandler/scripthandler.cxx +++ b/scripting/source/protocolhandler/scripthandler.cxx @@ -176,8 +176,8 @@ void SAL_CALL ScriptProtocolHandler::dispatchWithNotification( "S
[Libreoffice-commits] core.git: sc/qa sc/source
sc/qa/extras/macros-test.cxx |9 sc/qa/extras/sccellrangeobj.cxx |5 sc/qa/extras/scindexenumeration_tableconditionalentryenumeration.cxx | 20 - sc/qa/extras/scmodelobj.cxx |6 sc/qa/extras/scpdfexport.cxx | 29 +- sc/qa/extras/scsubtotaldescriptorbase.cxx|6 sc/qa/extras/scsubtotalfieldobj.cxx |6 sc/qa/extras/sctableconditionalentryobj.cxx | 20 - sc/qa/extras/sctableconditionalformat.cxx| 19 - sc/qa/unit/bugfix-test.cxx | 13 - sc/qa/unit/chart2dataprovider.cxx| 21 - sc/qa/unit/copy_paste_test.cxx |5 sc/qa/unit/jumbosheets-test.cxx |5 sc/qa/unit/scshapetest.cxx |5 sc/qa/unit/subsequent_export_test2.cxx |9 sc/qa/unit/tiledrendering/tiledrendering.cxx | 36 +-- sc/qa/unit/uicalc/uicalc.cxx |5 sc/source/core/data/documen3.cxx |3 sc/source/core/data/documen5.cxx | 30 +- sc/source/core/data/dpfilteredcache.cxx |9 sc/source/core/data/dpobject.cxx |9 sc/source/core/data/dpoutput.cxx |8 sc/source/core/data/dptabsrc.cxx |7 sc/source/core/data/table5.cxx | 14 - sc/source/core/data/validat.cxx | 22 -- sc/source/core/tool/charthelper.cxx |7 sc/source/core/tool/formulaparserpool.cxx|3 sc/source/core/tool/interpr4.cxx |5 sc/source/filter/excel/xichart.cxx |7 sc/source/filter/excel/xiescher.cxx | 10 sc/source/filter/excel/xltoolbar.cxx |6 sc/source/filter/excel/xltracer.cxx |5 sc/source/filter/ftools/fapihelper.cxx |5 sc/source/filter/inc/xltracer.hxx|2 sc/source/filter/oox/autofilterbuffer.cxx| 20 + sc/source/filter/oox/drawingfragment.cxx |9 sc/source/filter/oox/viewsettings.cxx|7 sc/source/filter/oox/workbooksettings.cxx| 18 - sc/source/filter/xml/XMLCodeNameProvider.cxx | 10 sc/source/filter/xml/xmldrani.cxx|2 sc/source/filter/xml/xmldrani.hxx|2 sc/source/filter/xml/xmlexprt.cxx| 13 - sc/source/filter/xml/xmlimprt.cxx|6 sc/source/filter/xml/xmlsorti.cxx| 39 +-- sc/source/ui/Accessibility/AccessibleCsvControl.cxx | 24 +- sc/source/ui/Accessibility/AccessibleDocument.cxx|6 sc/source/ui/Accessibility/AccessiblePreviewTable.cxx|2 sc/source/ui/cctrl/tbzoomsliderctrl.cxx | 10 sc/source/ui/docshell/docsh.cxx | 26 +- sc/source/ui/docshell/docsh4.cxx | 15 - sc/source/ui/drawfunc/fuins2.cxx | 27 +- sc/source/ui/miscdlgs/optsolver.cxx |5 sc/source/ui/miscdlgs/solveroptions.cxx |3 sc/source/ui/miscdlgs/solverutil.cxx |7 sc/source/ui/unoobj/PivotTableDataSequence.cxx | 11 - sc/source/ui/unoobj/cellvaluebinding.cxx | 17 - sc/source/ui/unoobj/chartuno.cxx | 27 +- sc/source/ui/unoobj/condformatuno.cxx| 19 - sc/source/ui/unoobj/dapiuno.cxx |3 sc/source/ui/unoobj/datauno.cxx | 14 - sc/source/ui/unoobj/docuno.cxx | 55 ++--- sc/source/ui/unoobj/eventuno.cxx |3 sc/source/ui/unoobj/linkuno.cxx |9 sc/source/ui/unoobj/servuno.cxx
[Libreoffice-commits] core.git: 2 commits - opencl/source sccomp/qa sccomp/source
opencl/source/openclconfig.cxx |4 sccomp/qa/unit/SwarmSolverTest.cxx | 157 ++--- sccomp/qa/unit/solver.cxx |9 + sccomp/source/solver/LpsolveSolver.cxx |4 4 files changed, 80 insertions(+), 94 deletions(-) New commits: commit 9a668129259eeba1a05745b7cd820fccf3043f45 Author: Mike Kaganski AuthorDate: Fri Oct 29 09:53:10 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 21:55:44 2021 +0200 Prepare for removal of non-const operator[] from Sequence in opencl Change-Id: Id58484eb9b955948a8edb48000b86cec3b721060 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124377 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/opencl/source/openclconfig.cxx b/opencl/source/openclconfig.cxx index 5467fc5e83c9..9c4452c153d3 100644 --- a/opencl/source/openclconfig.cxx +++ b/opencl/source/openclconfig.cxx @@ -55,11 +55,11 @@ namespace { css::uno::Sequence SetOfImplMatcherToStringSequence(const OpenCLConfig::ImplMatcherSet& rSet) { css::uno::Sequence result(rSet.size()); - +auto resultRange = asNonConstRange(result); size_t n(0); for (const auto& rItem : rSet) { -result[n++] = +resultRange[n++] = rItem.maOS.replaceAll("%", "%25").replaceAll("/", "%2F").replaceAll(";", "%3B") + "/" + rItem.maOSVersion.replaceAll("%", "%25").replaceAll("/", "%2F").replaceAll(";", "%3B") + "/" + rItem.maPlatformVendor.replaceAll("%", "%25").replaceAll("/", "%2F").replaceAll(";", "%3B") + "/" + commit 881ea76399a76599e17688f335f4f164d4d29413 Author: Mike Kaganski AuthorDate: Fri Oct 29 09:59:24 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 21:55:34 2021 +0200 Prepare for removal of non-const operator[] from Sequence in sccomp Change-Id: Ic55d553c85dd0abb92b6b7f223a437c8c2ca0700 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124383 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/sccomp/qa/unit/SwarmSolverTest.cxx b/sccomp/qa/unit/SwarmSolverTest.cxx index 78cfccaaa376..030822b9cdb4 100644 --- a/sccomp/qa/unit/SwarmSolverTest.cxx +++ b/sccomp/qa/unit/SwarmSolverTest.cxx @@ -127,14 +127,14 @@ void SwarmSolverTest::testVariableBounded() uno::Sequence aVariables{ { 0, 1, 0 } }; // constraints -uno::Sequence aConstraints(2); -aConstraints[0].Left = table::CellAddress(0, 1, 0); -aConstraints[0].Operator = sheet::SolverConstraintOperator_LESS_EQUAL; -aConstraints[0].Right <<= 100.0; - -aConstraints[1].Left = table::CellAddress(0, 1, 0); -aConstraints[1].Operator = sheet::SolverConstraintOperator_GREATER_EQUAL; -aConstraints[1].Right <<= -100.0; +uno::Sequence aConstraints{ +{ /* [0] Left */ table::CellAddress(0, 1, 0), + /* Operator */ sheet::SolverConstraintOperator_LESS_EQUAL, + /* Right*/ uno::Any(100.0) }, +{ /* [1] Left */ table::CellAddress(0, 1, 0), + /* Operator */ sheet::SolverConstraintOperator_GREATER_EQUAL, + /* Right*/ uno::Any(-100.0) } +}; // initialize solver xSolver->setDocument(xDocument); @@ -178,18 +178,17 @@ void SwarmSolverTest::testVariableConstrained() uno::Sequence aVariables{ { 0, 1, 0 } }; // constraints -uno::Sequence aConstraints(3); -aConstraints[0].Left = table::CellAddress(0, 1, 0); -aConstraints[0].Operator = sheet::SolverConstraintOperator_GREATER_EQUAL; -aConstraints[0].Right <<= -5.0; - -aConstraints[1].Left = table::CellAddress(0, 1, 0); -aConstraints[1].Operator = sheet::SolverConstraintOperator_LESS_EQUAL; -aConstraints[1].Right <<= 0.0; - -aConstraints[2].Left = table::CellAddress(0, 1, 1); -aConstraints[2].Operator = sheet::SolverConstraintOperator_GREATER_EQUAL; -aConstraints[2].Right <<= 10.0; +uno::Sequence aConstraints{ +{ /* [0] Left */ table::CellAddress(0, 1, 0), + /* Operator */ sheet::SolverConstraintOperator_GREATER_EQUAL, + /* Right*/ uno::Any(-5.0) }, +{ /* [1] Left */ table::CellAddress(0, 1, 0), + /* Operator */ sheet::SolverConstraintOperator_LESS_EQUAL, + /* Right*/ uno::Any(0.0) }, +{ /* [2] Left */ table::CellAddress(0, 1, 1), + /* Operator */ sheet::SolverConstraintOperator_GREATER_EQUAL, + /* Right*/ uno::Any(10.0) } +}; // initialize solver xSolver->setDocument(xDocument); @@ -233,23 +232,20 @@ void SwarmSolverTest::testTwoVariables() uno::Sequence aVariables{ { 0, 1, 2 }, { 0, 1, 3 } }; // constraints -uno::Sequence aConstraints(4); - -aConstraints[0].Left = table::CellAddress(0, 1, 2); -aConstraints[0].Operator = sheet::SolverConstraintOperator_GREATER_EQUAL; -aConstraints[0].Right <<= -100.0; - -aConstraints[1].Left = table::CellAddress(0, 1,
[Libreoffice-commits] core.git: sax/qa
sax/qa/cppunit/xmlimport.cxx | 13 + 1 file changed, 5 insertions(+), 8 deletions(-) New commits: commit 83f50dee5b4add87cf30903aeb0e44e0d4f04682 Author: Mike Kaganski AuthorDate: Fri Oct 29 09:56:46 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 21:12:29 2021 +0200 Prepare for removal of non-const operator[] from Sequence in sax Change-Id: I9df7229f55347bd4477626595cab459065cc4bb8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124381 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/sax/qa/cppunit/xmlimport.cxx b/sax/qa/cppunit/xmlimport.cxx index cb34ff1f5eb2..fcf839609cac 100644 --- a/sax/qa/cppunit/xmlimport.cxx +++ b/sax/qa/cppunit/xmlimport.cxx @@ -358,17 +358,16 @@ void XMLImportTest::setUp() xTokenHandler.set( new DummyTokenHandler ); uno::Reference const xInit(m_xLegacyFastParser, uno::UNO_QUERY_THROW); -uno::Sequence args(1); -args[0] <<= xTokenHandler; -xInit->initialize( args ); +xInit->initialize({ uno::Any(xTokenHandler) }); sal_Int32 nNamespaceCount = SAL_N_ELEMENTS(DummyTokenHandler::namespaceURIs); uno::Sequence namespaceArgs( nNamespaceCount + 1 ); -namespaceArgs[0] <<= OUString( "registerNamespaces" ); +auto p_namespaceArgs = namespaceArgs.getArray(); +p_namespaceArgs[0] <<= OUString( "registerNamespaces" ); for (sal_Int32 i = 1; i <= nNamespaceCount; i++ ) { css::beans::Pair rPair( OUString(DummyTokenHandler::namespaceURIs[i - 1]), i << 16 ); -namespaceArgs[i] <<= rPair; +p_namespaceArgs[i] <<= rPair; } xInit->initialize( namespaceArgs ); @@ -406,9 +405,7 @@ void XMLImportTest::testMissingNamespaceDeclaration() uno::Reference const xInit(m_xLegacyFastParser, uno::UNO_QUERY_THROW); -uno::Sequence args(1); -args[0] <<= OUString("IgnoreMissingNSDecl"); -xInit->initialize( args ); +xInit->initialize({ uno::Any(OUString("IgnoreMissingNSDecl")) }); for (sal_uInt16 i = 0; i < SAL_N_ELEMENTS( fileNames ); i++) {
[Libreoffice-commits] core.git: reportdesign/source
reportdesign/source/core/api/ReportDefinition.cxx | 20 ++--- reportdesign/source/core/api/ReportEngineJFree.cxx | 43 --- reportdesign/source/filter/xml/xmlControlProperty.cxx |2 reportdesign/source/filter/xml/xmlExportDocumentHandler.cxx |2 reportdesign/source/filter/xml/xmlfilter.cxx| 12 +-- reportdesign/source/ui/dlg/CondFormat.cxx | 16 +--- reportdesign/source/ui/dlg/DateTime.cxx | 25 +++--- reportdesign/source/ui/dlg/GroupsSorting.cxx| 45 +--- reportdesign/source/ui/dlg/Navigator.cxx|7 - reportdesign/source/ui/inspection/GeometryHandler.cxx |3 reportdesign/source/ui/misc/RptUndo.cxx | 23 ++ reportdesign/source/ui/misc/UITools.cxx |5 - reportdesign/source/ui/report/DesignView.cxx| 12 +-- reportdesign/source/ui/report/ReportController.cxx | 14 +-- reportdesign/source/ui/report/ReportSection.cxx | 15 ++-- 15 files changed, 111 insertions(+), 133 deletions(-) New commits: commit c5196e281f51b2894aa903469ba8c15a6723eb4c Author: Mike Kaganski AuthorDate: Fri Oct 29 09:55:58 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 20:55:43 2021 +0200 Prepare for removal of non-const operator[] from Sequence in reportdesign Change-Id: I7631aeb90bf224ba7a00025df6e3fa444b216a42 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124380 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/reportdesign/source/core/api/ReportDefinition.cxx b/reportdesign/source/core/api/ReportDefinition.cxx index 6e8c0950b72e..36babe9b72a0 100644 --- a/reportdesign/source/core/api/ReportDefinition.cxx +++ b/reportdesign/source/core/api/ReportDefinition.cxx @@ -208,7 +208,7 @@ static void lcl_extractAndStartStatusIndicator( const utl::MediaDescriptor& _rDe sal_Int32 nLength = _rCallArgs.getLength(); _rCallArgs.realloc( nLength + 1 ); -_rCallArgs[ nLength ] <<= _rxStatusIndicator; +_rCallArgs.getArray()[ nLength ] <<= _rxStatusIndicator; } } catch (const uno::Exception&) @@ -706,7 +706,7 @@ uno::Sequence< OUString > SAL_CALL OReportDefinition::getSupportedServiceNames( { sal_Int32 nLen = aSupported.getLength(); aSupported.realloc( nLen + 1 ); -aSupported[ nLen ] = SERVICE_REPORTDEFINITION; +aSupported.getArray()[ nLen ] = SERVICE_REPORTDEFINITION; } // outta here @@ -1246,7 +1246,7 @@ void OReportDefinition::impl_loadFromStorage_nolck_throw( const uno::Reference< beans::PropertyValue aPropVal; aPropVal.Name = "Storage"; aPropVal.Value <<= _xStorageToLoadFrom; -aDelegatorArguments[nPos] <<= aPropVal; +aDelegatorArguments.getArray()[nPos] <<= aPropVal; rptui::OXUndoEnvironment& rEnv = m_pImpl->m_pReportModel->GetUndoEnv(); rptui::OXUndoEnvironment::OUndoEnvLock aLock(rEnv); @@ -1328,8 +1328,9 @@ void SAL_CALL OReportDefinition::storeToStorage( const uno::Reference< embed::XS sal_Int32 nArgsLen = aDelegatorArguments.getLength(); -aDelegatorArguments.realloc(nArgsLen+1); -aDelegatorArguments[nArgsLen++] <<= xInfoSet; +aDelegatorArguments.realloc(nArgsLen+3); +auto pDelegatorArguments = aDelegatorArguments.getArray(); +pDelegatorArguments[nArgsLen++] <<= xInfoSet; uno::Reference< document::XEmbeddedObjectResolver > xObjectResolver; uno::Reference xGraphicStorageHandler; @@ -1338,9 +1339,8 @@ void SAL_CALL OReportDefinition::storeToStorage( const uno::Reference< embed::XS xGraphicHelper.clear(); xObjectResolver = SvXMLEmbeddedObjectHelper::Create( _xStorageToSaveTo,*this, SvXMLEmbeddedObjectHelperMode::Write ).get(); -aDelegatorArguments.realloc(nArgsLen+2); -aDelegatorArguments[nArgsLen++] <<= xGraphicStorageHandler; -aDelegatorArguments[nArgsLen++] <<= xObjectResolver; +pDelegatorArguments[nArgsLen++] <<= xGraphicStorageHandler; +pDelegatorArguments[nArgsLen++] <<= xObjectResolver; uno::Reference xCom(static_cast(this),uno::UNO_QUERY); // Try to write to settings.xml, meta.xml, and styles.xml; only really care about success of @@ -1607,9 +1607,7 @@ void SAL_CALL OReportDefinition::load( const uno::Sequence< beans::PropertyValue const size_t nLastOpenMode = SAL_N_ELEMENTS( nOpenModes ) - 1; for ( size_t i=nFirstOpenMode; i <= nLastOpenMode; ++i ) { -uno::Sequence< uno::Any > aStorageCreationArgs(2); -aStorageCreationArgs[0] = aStorageSource; -aStorageCreationArgs[1] <<= nOpenModes[i]; +uno::Sequence< uno::Any > aStorageCreationArgs{ aStorageSource, uno::Any(nOpenModes[i]) }; try { diff --git a/reportdesign/source/core/api/ReportEngineJFree.cxx b/reportdesign/source/core/api/ReportEngineJFree.cxx index 210bf3
[Libreoffice-commits] core.git: helpcontent2
helpcontent2 |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 7ddf23d19439b9aa569ae35bbac41079203b9f84 Author: Adolfo Jayme Barrientos AuthorDate: Sat Oct 30 13:50:10 2021 -0500 Commit: Gerrit Code Review CommitDate: Sat Oct 30 20:50:10 2021 +0200 Update git submodules * Update helpcontent2 from branch 'master' to 081aa4f6de2c2f6388267883e68966b9da02981f - BASIC syntax error Change-Id: I6ed5bb2541ce6ad6e2bc4f877a093ea5f9cb7aa5 - Since Windows 8, “Run” isn’t a clickable Start option Change-Id: I1e02547fbe6042e47c028062ea43375cb3ebd0a4 diff --git a/helpcontent2 b/helpcontent2 index 3445df8b3761..081aa4f6de2c 16 --- a/helpcontent2 +++ b/helpcontent2 @@ -1 +1 @@ -Subproject commit 3445df8b3761cc8dafd0f5a275696ad54dc9bbec +Subproject commit 081aa4f6de2c2f6388267883e68966b9da02981f
[Libreoffice-commits] help.git: 2 commits - source/text
source/text/sbasic/shared/0304.xhp|2 +- source/text/shared/guide/start_parameters.xhp |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) New commits: commit 081aa4f6de2c2f6388267883e68966b9da02981f Author: Adolfo Jayme Barrientos AuthorDate: Sat Oct 30 13:50:01 2021 -0500 Commit: Adolfo Jayme Barrientos CommitDate: Sat Oct 30 13:50:01 2021 -0500 BASIC syntax error Change-Id: I6ed5bb2541ce6ad6e2bc4f877a093ea5f9cb7aa5 diff --git a/source/text/sbasic/shared/0304.xhp b/source/text/sbasic/shared/0304.xhp index 7971edc18..33dbd5af5 100644 --- a/source/text/sbasic/shared/0304.xhp +++ b/source/text/sbasic/shared/0304.xhp @@ -203,7 +203,7 @@ Set oDoc = ThisComponent Print oDoc.Title oDoc = Nothing -Print oDoc ‘ Error +Print oDoc ' Error End Sub commit 52b37a0450f918a2e4c7ecf8461ee33d4e355e7c Author: Adolfo Jayme Barrientos AuthorDate: Sun Oct 24 15:44:44 2021 -0500 Commit: Adolfo Jayme Barrientos CommitDate: Sat Oct 30 13:22:38 2021 -0500 Since Windows 8, “Run” isn’t a clickable Start option Change-Id: I1e02547fbe6042e47c028062ea43375cb3ebd0a4 diff --git a/source/text/shared/guide/start_parameters.xhp b/source/text/shared/guide/start_parameters.xhp index cae93e1d1..4cc41b8c1 100644 --- a/source/text/shared/guide/start_parameters.xhp +++ b/source/text/shared/guide/start_parameters.xhp @@ -39,7 +39,7 @@ -Select Run from the Windows Start menu. +Search for Run in the Windows Start menu. Type the following text in the Open text field and click OK.
[Libreoffice-commits] core.git: 2 commits - package/qa package/source pyuno/source
package/qa/cppunit/test_package.cxx |8 -- package/source/xstor/owriteablestream.cxx | 34 +- package/source/xstor/xfactory.cxx | 15 ++-- package/source/xstor/xstorage.cxx | 68 ++-- package/source/zipapi/XBufferedThreadedStream.cxx |3 package/source/zipapi/ZipFile.cxx |3 package/source/zippackage/ZipPackage.cxx | 22 +++--- package/source/zippackage/ZipPackageFolder.cxx| 13 ++- package/source/zippackage/ZipPackageStream.cxx| 74 +++--- package/source/zippackage/zipfileaccess.cxx | 14 ++-- pyuno/source/module/pyuno.cxx | 13 --- pyuno/source/module/pyuno_callable.cxx|3 pyuno/source/module/pyuno_runtime.cxx | 11 ++- 13 files changed, 142 insertions(+), 139 deletions(-) New commits: commit d0a8d4a973b5ae395b6fa925e27c7a120a324f4a Author: Mike Kaganski AuthorDate: Fri Oct 29 09:54:10 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 20:17:13 2021 +0200 Prepare for removal of non-const operator[] from Sequence in package Change-Id: Ib5d7fa143c4c5e3b4862ed4b91acf1e2dfc4d8bb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124378 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/package/qa/cppunit/test_package.cxx b/package/qa/cppunit/test_package.cxx index 6f767295618c..022d8a9eea53 100644 --- a/package/qa/cppunit/test_package.cxx +++ b/package/qa/cppunit/test_package.cxx @@ -53,12 +53,8 @@ namespace BootstrapFixtureBase::setUp(); OUString aURL = m_directories.getURLFromSrc(u"/package/qa/cppunit/data/a2z.zip"); -uno::Sequence aNVs(1); -aNVs[0].Name = "URL"; -aNVs[0].Value <<= aURL; - -uno::Sequence aArgs(1); -aArgs[0] <<= aNVs; +uno::Sequence aNVs{ { "URL", uno::Any(aURL) } }; +uno::Sequence aArgs{ uno::Any(aNVs) }; uno::Reference xCxt = comphelper::getProcessComponentContext(); uno::Reference xSvcMgr = xCxt->getServiceManager(); diff --git a/package/source/xstor/owriteablestream.cxx b/package/source/xstor/owriteablestream.cxx index c91996d0756c..b141a469ece2 100644 --- a/package/source/xstor/owriteablestream.cxx +++ b/package/source/xstor/owriteablestream.cxx @@ -775,8 +775,7 @@ void OWriteStream_Impl::Commit() return; uno::Reference< packages::XDataSinkEncrSupport > xNewPackageStream; -uno::Sequence< uno::Any > aSeq( 1 ); -aSeq[0] <<= false; +uno::Sequence< uno::Any > aSeq{ uno::Any(false) }; if ( m_xCacheStream.is() ) { @@ -959,7 +958,7 @@ uno::Sequence< beans::PropertyValue > OWriteStream_Impl::InsertOwnProps( break; if (i == aResult.getLength()) aResult.realloc(i + 1); -aResult[i] = aPropVal; +aResult.getArray()[i] = aPropVal; } return aResult; @@ -1030,30 +1029,32 @@ uno::Sequence< beans::PropertyValue > OWriteStream_Impl::ReadPackageStreamProper nPropNum = 3; else if ( m_nStorageType == embed::StorageFormats::PACKAGE ) nPropNum = 4; +assert(nPropNum >= 2); uno::Sequence< beans::PropertyValue > aResult( nPropNum ); +auto aResultRange = asNonConstRange(aResult); // The "Compressed" property must be set after "MediaType" property, // since the setting of the last one can change the value of the first one if ( m_nStorageType == embed::StorageFormats::OFOPXML || m_nStorageType == embed::StorageFormats::PACKAGE ) { -aResult[0].Name = "MediaType"; -aResult[1].Name = "Compressed"; -aResult[2].Name = "Size"; +aResultRange[0].Name = "MediaType"; +aResultRange[1].Name = "Compressed"; +aResultRange[2].Name = "Size"; if ( m_nStorageType == embed::StorageFormats::PACKAGE ) -aResult[3].Name = "Encrypted"; +aResultRange[3].Name = "Encrypted"; } else { -aResult[0].Name = "Compressed"; -aResult[1].Name = "Size"; +aResultRange[0].Name = "Compressed"; +aResultRange[1].Name = "Size"; } // TODO: may be also raw stream should be marked uno::Reference< beans::XPropertySet > xPropSet( m_xPackageStream, uno::UNO_QUERY_THROW ); -for ( auto& rProp : asNonConstRange(aResult) ) +for ( auto& rProp : aResultRange ) { try { rProp.Value = xPropSet->getPropertyValue( rProp.Name ); @@ -2612,7 +2613,7 @@ void SAL_CALL OWriteStream::insertRelationshipByID( const OUString& sID, const const beans::StringPair aIDRel("Id", sID); -sal_Int32 nIDInd = -1; +uno::Sequence* pPair = nullptr; // TODO/LATER: in future the unification of the ID could be checked uno::Sequence< uno::Sequence< beans::StringPair > > aSeq = getAllRelationships(); @@ -2620,16 +2621,17 @@ void SAL_CALL OWriteStream::insertRel
[Libreoffice-commits] core.git: oox/source
oox/source/core/xmlfilterbase.cxx | 13 +- oox/source/docprop/docprophandler.cxx |6 - oox/source/drawingml/chart/axisconverter.cxx |2 oox/source/drawingml/chart/seriesconverter.cxx|8 - oox/source/drawingml/chart/typegroupconverter.cxx |5 oox/source/drawingml/color.cxx|5 oox/source/drawingml/customshapeproperties.cxx| 45 oox/source/drawingml/effectproperties.cxx | 13 +- oox/source/drawingml/fillproperties.cxx | 21 ++-- oox/source/drawingml/lineproperties.cxx |6 - oox/source/drawingml/shape.cxx| 97 +- oox/source/drawingml/shape3dproperties.cxx| 114 ++ oox/source/export/chartexport.cxx | 31 ++--- oox/source/export/drawingml.cxx | 58 --- oox/source/helper/graphichelper.cxx | 25 ++-- oox/source/helper/textinputstream.cxx |3 oox/source/ole/axcontrol.cxx | 18 +-- oox/source/ole/oleobjecthelper.cxx|6 - oox/source/ole/olestorage.cxx | 10 - oox/source/ole/vbaproject.cxx |4 oox/source/ppt/animationspersist.cxx |6 - oox/source/ppt/presentationfragmenthandler.cxx| 43 +++- oox/source/ppt/timenodelistcontext.cxx| 14 +- oox/source/shape/WpsContext.cxx |5 oox/source/vml/vmlformatting.cxx |2 oox/source/vml/vmlinputstream.cxx |6 - oox/source/vml/vmlshape.cxx | 41 --- 27 files changed, 283 insertions(+), 324 deletions(-) New commits: commit 3c1085fcdd8814180507d8ea1aa6e75d4f94f14f Author: Mike Kaganski AuthorDate: Fri Oct 29 09:52:20 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 19:22:33 2021 +0200 Prepare for removal of non-const operator[] from Sequence in oox Change-Id: Iee1e16c516547e8f23631b33c928ac6637050f68 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124376 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/oox/source/core/xmlfilterbase.cxx b/oox/source/core/xmlfilterbase.cxx index 7f4ff6bd0f0c..9390cabd04de 100644 --- a/oox/source/core/xmlfilterbase.cxx +++ b/oox/source/core/xmlfilterbase.cxx @@ -515,14 +515,15 @@ OUString lclAddRelation( const Reference< XRelationshipAccess >& rRelations, sal OUString sId = "rId" + OUString::number( nId ); Sequence< StringPair > aEntry( bExternal ? 3 : 2 ); -aEntry[0].First = "Type"; -aEntry[0].Second = rType; -aEntry[1].First = "Target"; -aEntry[1].Second = INetURLObject::decode(rTarget, INetURLObject::DecodeMechanism::ToIUri, RTL_TEXTENCODING_UTF8); +auto pEntry = aEntry.getArray(); +pEntry[0].First = "Type"; +pEntry[0].Second = rType; +pEntry[1].First = "Target"; +pEntry[1].Second = INetURLObject::decode(rTarget, INetURLObject::DecodeMechanism::ToIUri, RTL_TEXTENCODING_UTF8); if( bExternal ) { -aEntry[2].First = "TargetMode"; -aEntry[2].Second = "External"; +pEntry[2].First = "TargetMode"; +pEntry[2].Second = "External"; } rRelations->insertRelationshipByID( sId, aEntry, true ); diff --git a/oox/source/docprop/docprophandler.cxx b/oox/source/docprop/docprophandler.cxx index ebcb87c3cdde..95043e497aea 100644 --- a/oox/source/docprop/docprophandler.cxx +++ b/oox/source/docprop/docprophandler.cxx @@ -256,11 +256,7 @@ void OOXMLDocPropHandler::UpdateDocStatistic( const OUString& aChars ) if (nInd == aSet.getLength()) aSet.realloc( nInd + 1 ); -beans::NamedValue aProp; -aProp.Name = aName; -aProp.Value <<= aChars.toInt32(); - -aSet[nInd] = aProp; +aSet.getArray()[nInd] = { aName, uno::Any(aChars.toInt32()) }; m_xDocProp->setDocumentStatistics( aSet ); } diff --git a/oox/source/drawingml/chart/axisconverter.cxx b/oox/source/drawingml/chart/axisconverter.cxx index 4620f5b5a15c..a8ccc6cdf164 100644 --- a/oox/source/drawingml/chart/axisconverter.cxx +++ b/oox/source/drawingml/chart/axisconverter.cxx @@ -315,7 +315,7 @@ void AxisConverter::convertFromModel(const Reference& rxCoord // minor increment Sequence< SubIncrement >& rSubIncrementSeq = rIncrementData.SubIncrements; rSubIncrementSeq.realloc( 1 ); -Any& rIntervalCount = rSubIncrementSeq[ 0 ].IntervalCount; +Any& rIntervalCount = rSubIncrementSeq.getArray()[ 0 ].IntervalCount; rIntervalCount.clear(); if( bLogScale ) { diff --git a/oox/source/drawingml/chart/seriesconverter.cxx b/oox/source/drawingml/chart/seriesconverter.cxx index 324f3817d6f1..d4fa267da536 100644 --- a/oox/source/drawingml/chart/seriesconverter.cxx +++ b/oox/source/drawingml/chart/seriesconverter.c
[Libreoffice-commits] core.git: cui/source download.lst external/zxing
cui/source/dialogs/QrCodeGenDialog.cxx |4 ++-- download.lst |4 ++-- external/zxing/StaticLibrary_zxing.mk | 23 +++ 3 files changed, 11 insertions(+), 20 deletions(-) New commits: commit d53340b2253537104abe6f95c8c63cc74487c3ec Author: homeboy445 AuthorDate: Tue Sep 28 13:14:35 2021 +0530 Commit: Adolfo Jayme Barrientos CommitDate: Sat Oct 30 18:56:48 2021 +0200 Switch to a newer version of ZXing library Change-Id: Ib2b919bb7545f05631aed2e6176a97aeb866ee84 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122772 Tested-by: Jenkins Reviewed-by: Adolfo Jayme Barrientos diff --git a/cui/source/dialogs/QrCodeGenDialog.cxx b/cui/source/dialogs/QrCodeGenDialog.cxx index 271d14999cbf..fad04c944ee0 100644 --- a/cui/source/dialogs/QrCodeGenDialog.cxx +++ b/cui/source/dialogs/QrCodeGenDialog.cxx @@ -105,9 +105,9 @@ std::string GetBarCodeType(const int& type) switch (type) { case 1: -return "CODE_128"; +return "Code128"; default: -return "QR_CODE"; +return "QRCode"; } } diff --git a/download.lst b/download.lst index 46184db628ee..561d4e5f5908 100644 --- a/download.lst +++ b/download.lst @@ -265,8 +265,8 @@ export ZLIB_SHA256SUM := 4ff941449631ace0d4d203e3483be9dbc9da454084111f97ea0a211 export ZLIB_TARBALL := zlib-1.2.11.tar.xz export ZMF_SHA256SUM := 27051a30cb057fdb5d5de65a1f165c7153dc76e27fe62251cbb86639eb2caf22 export ZMF_TARBALL := libzmf-0.0.2.tar.xz -export ZXING_SHA256SUM := e595b3fa2ec320beb0b28f6af56b1141853257c2611686685639cebb3b248c86 -export ZXING_TARBALL := zxing-cpp-1.1.1.tar.gz +export ZXING_SHA256SUM := 653d9e44195d86cf64a36af9ff3a1978ec5599df3882439fefa56e7064f55e8a +export ZXING_TARBALL := zxing-cpp-1.2.0.tar.gz NUMBERTEXT_EXTENSION_SHA256SUM := 1568ed1d2feb8210bb5de61d69574a165cded536cfa17c6953c9064076469de2 OPENSYMBOL_SHA256SUM := f543e6e2d7275557a839a164941c0a86e5f2c3f2a0042bfc434c88c6dde9e140 export CUCKOO_SHA256SUM := 471dd83a813ed2816c2246c373004470ad0f6612c7ce72038929dc5161cdd58e diff --git a/external/zxing/StaticLibrary_zxing.mk b/external/zxing/StaticLibrary_zxing.mk index 9a5ca26cc398..c80f37dc21b5 100644 --- a/external/zxing/StaticLibrary_zxing.mk +++ b/external/zxing/StaticLibrary_zxing.mk @@ -33,26 +33,28 @@ $(eval $(call gb_StaticLibrary_add_generated_exception_objects,zxing,\ UnpackedTarball/zxing/core/src/BarcodeFormat \ UnpackedTarball/zxing/core/src/BitArray \ UnpackedTarball/zxing/core/src/BitMatrixIO \ + UnpackedTarball/zxing/core/src/BinaryBitmap \ UnpackedTarball/zxing/core/src/BitMatrix \ UnpackedTarball/zxing/core/src/BitSource \ UnpackedTarball/zxing/core/src/textcodec/Big5TextDecoder \ UnpackedTarball/zxing/core/src/textcodec/Big5TextEncoder \ UnpackedTarball/zxing/core/src/textcodec/Big5MapTable \ UnpackedTarball/zxing/core/src/CharacterSetECI \ + UnpackedTarball/zxing/core/src/ConcentricFinder \ UnpackedTarball/zxing/core/src/DecodeHints \ UnpackedTarball/zxing/core/src/DecodeStatus \ UnpackedTarball/zxing/core/src/datamatrix/DMWriter \ - UnpackedTarball/zxing/core/src/datamatrix/DMDefaultPlacement \ UnpackedTarball/zxing/core/src/datamatrix/DMDetector \ UnpackedTarball/zxing/core/src/datamatrix/DMVersion \ UnpackedTarball/zxing/core/src/datamatrix/DMSymbolInfo \ UnpackedTarball/zxing/core/src/datamatrix/DMDecoder \ - UnpackedTarball/zxing/core/src/datamatrix/DMBitMatrixParser \ UnpackedTarball/zxing/core/src/datamatrix/DMReader \ + UnpackedTarball/zxing/core/src/datamatrix/DMBitLayout \ UnpackedTarball/zxing/core/src/datamatrix/DMDataBlock \ UnpackedTarball/zxing/core/src/datamatrix/DMECEncoder \ UnpackedTarball/zxing/core/src/datamatrix/DMHighLevelEncoder \ UnpackedTarball/zxing/core/src/GlobalHistogramBinarizer \ + UnpackedTarball/zxing/core/src/GTIN \ UnpackedTarball/zxing/core/src/GenericGF \ UnpackedTarball/zxing/core/src/GridSampler \ UnpackedTarball/zxing/core/src/GenericLuminanceSource \ @@ -71,35 +73,29 @@ $(eval $(call gb_StaticLibrary_add_generated_exception_objects,zxing,\ UnpackedTarball/zxing/core/src/maxicode/MCDecoder \ UnpackedTarball/zxing/core/src/maxicode/MCBitMatrixParser \ UnpackedTarball/zxing/core/src/maxicode/MCReader \ - UnpackedTarball/zxing/core/src/oned/ODUPCEANExtensionSupport \ UnpackedTarball/zxing/core/src/oned/ODUPCEWriter \ UnpackedTarball/zxing/core/src/oned/ODEAN8Writer \ UnpackedTarball/zxing/core/src/oned/ODWriterHelper \ UnpackedTarball/zxing/core/src/oned/ODITFWriter \ UnpackedTarball/zxing/core/src/oned/ODITFReader \ UnpackedTarball/zxing/core/src/oned/ODCode39Reader \ - UnpackedTarball/zxing/core/src/oned/ODRSSExpandedReade
[Libreoffice-commits] core.git: basic/CppunitTest_basic_macros.mk basic/qa basic/source
basic/CppunitTest_basic_macros.mk |1 basic/qa/cppunit/test_global_array.cxx | 89 + basic/source/comp/dim.cxx | 11 ++-- 3 files changed, 97 insertions(+), 4 deletions(-) New commits: commit 27d96bfaea5f7967a11dc3a7e2bc9d88dd6f5666 Author: Andreas Heinisch AuthorDate: Fri Oct 29 08:40:14 2021 +0200 Commit: Andreas Heinisch CommitDate: Sat Oct 30 18:28:17 2021 +0200 tdf#145371 - Delete array variable only before ReDim Otherwise, global array variables don't maintain their state. Change-Id: I10dafd9e2946630c5476c9858f765d67ef2f6d6c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124368 Tested-by: Jenkins Reviewed-by: Andreas Heinisch diff --git a/basic/CppunitTest_basic_macros.mk b/basic/CppunitTest_basic_macros.mk index c70bfff42c68..83a9221369f0 100644 --- a/basic/CppunitTest_basic_macros.mk +++ b/basic/CppunitTest_basic_macros.mk @@ -20,6 +20,7 @@ $(eval $(call gb_CppunitTest_add_exception_objects,basic_macros, \ basic/qa/cppunit/test_nested_struct \ basic/qa/cppunit/test_vba \ basic/qa/cppunit/test_global_as_new \ + basic/qa/cppunit/test_global_array \ )) $(eval $(call gb_CppunitTest_use_libraries,basic_macros, \ diff --git a/basic/qa/cppunit/test_global_array.cxx b/basic/qa/cppunit/test_global_array.cxx new file mode 100644 index ..0b83d5efddee --- /dev/null +++ b/basic/qa/cppunit/test_global_array.cxx @@ -0,0 +1,89 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */ +/* + * 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/. + */ + +#include +#include +#include +#include +#include +#include +#include + +namespace +{ +class GlobalArrayTest : public CppUnit::TestFixture +{ +void testMaintainsValueAcrossCalls(); + +CPPUNIT_TEST_SUITE(GlobalArrayTest); +CPPUNIT_TEST(testMaintainsValueAcrossCalls); +CPPUNIT_TEST_SUITE_END(); + +BasicDLL lib; +StarBASICRef interpreter; + +SbModuleRef Module() +{ +interpreter = new StarBASIC(); +auto mod = interpreter->MakeModule("GlobalArray", R"BAS( + +Type testType +iNrAs Integer +sType As String +End Type + +Global aTestTypes(2) As New testType + +Function Macro1 As String +aTestTypes(0).iNr = 1 +aTestTypes(0).sType = "A" +Macro1 = aTestTypes(0).iNr & aTestTypes(0).sType +End Function + +Function Macro2 As String +aTestTypes(1).iNr = 2 +aTestTypes(1).sType = "B" +Macro2 = aTestTypes(0).iNr & aTestTypes(0).sType & aTestTypes(1).iNr & aTestTypes(1).sType +End Function + +)BAS"); +CPPUNIT_ASSERT(mod->Compile()); +CPPUNIT_ASSERT_EQUAL(StarBASIC::GetErrBasic(), ERRCODE_NONE); +CPPUNIT_ASSERT_EQUAL(SbxBase::GetError(), ERRCODE_NONE); +CPPUNIT_ASSERT(mod->IsCompiled()); +return mod; +} +}; + +void GlobalArrayTest::testMaintainsValueAcrossCalls() +{ +auto m = Module(); +auto Macro1 = m->FindMethod("Macro1", SbxClassType::Method); +CPPUNIT_ASSERT_MESSAGE("Could not Find Macro1 in module", Macro1 != nullptr); + +// There is no SbxMethod::call(), the basic code is exercised here in the copy ctor +SbxVariableRef returned = new SbxMethod{ *Macro1 }; +CPPUNIT_ASSERT(returned->IsString()); +CPPUNIT_ASSERT_EQUAL(OUString{ "1A" }, returned->GetOUString()); + +auto Macro2 = m->FindMethod("Macro2", SbxClassType::Method); +CPPUNIT_ASSERT_MESSAGE("Could not Find Macro2 in module", Macro2 != nullptr); +returned = new SbxMethod{ *Macro2 }; +CPPUNIT_ASSERT(returned->IsString()); +// tdf#145371 - check if the global array has maintained its state +// Without the fix in place, this test would have failed with: +// - Expected: 1A2B +// - Actual : 02B +CPPUNIT_ASSERT_EQUAL(OUString("1A2B"), returned->GetOUString()); +} + +// Put the test suite in the registry +CPPUNIT_TEST_SUITE_REGISTRATION(GlobalArrayTest); + +} // namespace diff --git a/basic/source/comp/dim.cxx b/basic/source/comp/dim.cxx index 56bbab29587a..cbc25b0152b4 100644 --- a/basic/source/comp/dim.cxx +++ b/basic/source/comp/dim.cxx @@ -431,10 +431,13 @@ void SbiParser::DefVar( SbiOpcode eOp, bool bStatic ) } else { -// tdf#136755 - delete the variable beforehand REDIM -SbiExpression aExpr(this, *pDef, nullptr); -aExpr.Gen(); -aGen.Gen(bVBASupportOn ? SbiOpcode::ERASE_CLEAR_ : SbiOpcode::ERASE_); +// tdf#145371, tdf#136755 - only delete the variable beforehand REDIM +if (eOp == SbiOpcode::REDIM_) +{ +SbiExp
[Libreoffice-commits] core.git: 2 commits - lingucomponent/source linguistic/source
lingucomponent/source/lingutil/lingutil.cxx |6 ++ lingucomponent/source/spellcheck/spell/sspellimp.cxx |9 +++-- linguistic/source/defs.hxx |3 +-- linguistic/source/gciterator.cxx |3 +-- 4 files changed, 7 insertions(+), 14 deletions(-) New commits: commit 8d1ebf5336c8194977d807e43c46b41b0cbcf88d Author: Mike Kaganski AuthorDate: Fri Oct 29 09:48:15 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 18:27:43 2021 +0200 Prepare for removal of non-const operator[] from Sequence in linguistic Change-Id: I6eda1416ca0421a48bf9811343850aa504019d57 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124374 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/linguistic/source/defs.hxx b/linguistic/source/defs.hxx index 38909e82362c..7e3d658956e5 100644 --- a/linguistic/source/defs.hxx +++ b/linguistic/source/defs.hxx @@ -45,8 +45,7 @@ struct LangSvcEntries explicit LangSvcEntries( const OUString &rSvcImplName ) : nLastTriedSvcIndex(-1) { -aSvcImplNames.realloc(1); -aSvcImplNames[0] = rSvcImplName; +aSvcImplNames = { rSvcImplName }; } void Clear() diff --git a/linguistic/source/gciterator.cxx b/linguistic/source/gciterator.cxx index 09e814d97050..b915dee3033a 100644 --- a/linguistic/source/gciterator.cxx +++ b/linguistic/source/gciterator.cxx @@ -1044,8 +1044,7 @@ uno::Reference< util::XChangesBatch > const & GrammarCheckingIterator::GetUpdate beans::PropertyValue aValue; aValue.Name = "nodepath"; aValue.Value <<= OUString("org.openoffice.Office.Linguistic/ServiceManager"); -uno::Sequence< uno::Any > aProps(1); -aProps[0] <<= aValue; +uno::Sequence< uno::Any > aProps{ uno::Any(aValue) }; m_xUpdateAccess.set( xConfigurationProvider->createInstanceWithArguments( "com.sun.star.configuration.ConfigurationUpdateAccess", aProps ), commit 6d4a6abab3bc610c8bceb9e7d322565f5614c3c5 Author: Mike Kaganski AuthorDate: Fri Oct 29 09:46:58 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 18:27:34 2021 +0200 Prepare for removal of non-const operator[] from Sequence in lingucomponent Change-Id: Ibce58dc277a703881de91bebdfd8b328c820a28e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124373 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/lingucomponent/source/lingutil/lingutil.cxx b/lingucomponent/source/lingutil/lingutil.cxx index aa1fa92edd62..3038d5a3edad 100644 --- a/lingucomponent/source/lingutil/lingutil.cxx +++ b/lingucomponent/source/lingutil/lingutil.cxx @@ -120,11 +120,9 @@ static void GetOldStyleDicsInDir( { // add the dictionary to the resulting vector SvtLinguConfigDictionaryEntry aDicEntry; -aDicEntry.aLocations.realloc(1); -aDicEntry.aLocaleNames.realloc(1); -aDicEntry.aLocations[0] = sPath; +aDicEntry.aLocations = { sPath }; +aDicEntry.aLocaleNames = { aLocaleName }; aDicEntry.aFormatName = aFormatName; -aDicEntry.aLocaleNames[0] = aLocaleName; aRes.push_back( aDicEntry ); } } diff --git a/lingucomponent/source/spellcheck/spell/sspellimp.cxx b/lingucomponent/source/spellcheck/spell/sspellimp.cxx index 2bacf9386319..843dcfb28585 100644 --- a/lingucomponent/source/spellcheck/spell/sspellimp.cxx +++ b/lingucomponent/source/spellcheck/spell/sspellimp.cxx @@ -179,12 +179,9 @@ Sequence< Locale > SAL_CALL SpellChecker::getLocales() } // ... and add them to the resulting sequence m_aSuppLocales.realloc( aLocaleNamesSet.size() ); -sal_Int32 k = 0; -for (auto const& localeName : aLocaleNamesSet) -{ -Locale aTmp( LanguageTag::convertToLocale(localeName)); -m_aSuppLocales[k++] = aTmp; -} +std::transform( +aLocaleNamesSet.begin(), aLocaleNamesSet.end(), m_aSuppLocales.getArray(), +[](auto const& localeName) { return LanguageTag::convertToLocale(localeName); }); //! For each dictionary and each locale we need a separate entry. //! If this results in more than one dictionary per locale than (for now)
[Libreoffice-commits] core.git: drawinglayer/source editeng/source include/vcl vcl/inc vcl/source
drawinglayer/source/primitive2d/textlayoutdevice.cxx |2 - editeng/source/accessibility/AccessibleStringWrap.cxx |2 - include/vcl/outdev.hxx|2 - include/vcl/vcllayout.hxx |2 - vcl/inc/sallayout.hxx |4 +- vcl/inc/textlayout.hxx|4 +- vcl/source/control/edit.cxx | 26 +- vcl/source/gdi/sallayout.cxx | 10 +++--- vcl/source/gdi/textlayout.cxx |6 ++-- vcl/source/outdev/text.cxx| 20 ++--- 10 files changed, 39 insertions(+), 39 deletions(-) New commits: commit 91399f5d9d9990d2e249155f4810cdaa5051e72b Author: Noel Grandin AuthorDate: Sat Oct 30 15:43:48 2021 +0200 Commit: Noel Grandin CommitDate: Sat Oct 30 18:25:25 2021 +0200 tools::Long->sal_Int32 in GetCaretPositions Change-Id: Id3f037e132a4d07cb2b68dbb93dd24f7f6b33ab6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124461 Tested-by: Jenkins Reviewed-by: Noel Grandin diff --git a/drawinglayer/source/primitive2d/textlayoutdevice.cxx b/drawinglayer/source/primitive2d/textlayoutdevice.cxx index 3dfd0258f099..102effd7fde1 100644 --- a/drawinglayer/source/primitive2d/textlayoutdevice.cxx +++ b/drawinglayer/source/primitive2d/textlayoutdevice.cxx @@ -331,7 +331,7 @@ std::vector TextLayouterDevice::getCaretPositions(const OUString& rText, if (nTextLength) { aRetval.reserve(2 * nTextLength); -std::vector aArray(2 * nTextLength); +std::vector aArray(2 * nTextLength); mrDevice.GetCaretPositions(rText, aArray.data(), nIndex, nLength); aRetval.assign(aArray.begin(), aArray.end()); } diff --git a/editeng/source/accessibility/AccessibleStringWrap.cxx b/editeng/source/accessibility/AccessibleStringWrap.cxx index 29ed20295760..9dff63c3ce75 100644 --- a/editeng/source/accessibility/AccessibleStringWrap.cxx +++ b/editeng/source/accessibility/AccessibleStringWrap.cxx @@ -56,7 +56,7 @@ void AccessibleStringWrap::GetCharacterBounds( sal_Int32 nIndex, tools::Rectangl } else { -tools::Long aXArray[2]; +sal_Int32 aXArray[2]; mrDev.GetCaretPositions( maText, aXArray, nIndex, 1 ); rRect.SetLeft( 0 ); rRect.SetTop( 0 ); diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx index 900a4e88db80..151ab8236c6c 100644 --- a/include/vcl/outdev.hxx +++ b/include/vcl/outdev.hxx @@ -1061,7 +1061,7 @@ public: vcl::text::TextLayoutCache const* = nullptr, SalLayoutGlyphs const*const pLayoutCache = nullptr) const; -voidGetCaretPositions( const OUString&, tools::Long* pCaretXArray, +voidGetCaretPositions( const OUString&, sal_Int32* pCaretXArray, sal_Int32 nIndex, sal_Int32 nLen, const SalLayoutGlyphs* pGlyphs = nullptr ) const; voidDrawStretchText( const Point& rStartPt, sal_uLong nWidth, diff --git a/include/vcl/vcllayout.hxx b/include/vcl/vcllayout.hxx index 34acb2fe733e..6ea9bc61bfbb 100644 --- a/include/vcl/vcllayout.hxx +++ b/include/vcl/vcllayout.hxx @@ -88,7 +88,7 @@ public: virtual sal_Int32 GetTextBreak(DeviceCoordinate nMaxWidth, DeviceCoordinate nCharExtra, int nFactor) const = 0; virtual DeviceCoordinate FillDXArray( std::vector* pDXArray ) const = 0; virtual DeviceCoordinate GetTextWidth() const { return FillDXArray( nullptr ); } -virtual voidGetCaretPositions( int nArraySize, tools::Long* pCaretXArray ) const = 0; +virtual voidGetCaretPositions( int nArraySize, sal_Int32* pCaretXArray ) const = 0; virtual boolIsKashidaPosValid ( int /*nCharPos*/ ) const { return true; } // i60594 // methods using glyph indexing diff --git a/vcl/inc/sallayout.hxx b/vcl/inc/sallayout.hxx index 8dc16d9021c1..ab29a2022985 100644 --- a/vcl/inc/sallayout.hxx +++ b/vcl/inc/sallayout.hxx @@ -63,7 +63,7 @@ public: voidDrawText(SalGraphics&) const override; sal_Int32 GetTextBreak(DeviceCoordinate nMaxWidth, DeviceCoordinate nCharExtra, int nFactor) const override; DeviceCoordinate FillDXArray(std::vector* pDXArray) const override; -voidGetCaretPositions(int nArraySize, tools::Long* pCaretXArray) const override; +voidGetCaretPositions(int nArraySize, sal_Int32* pCaretXArray) const override; boolGetNextGlyph(const GlyphItem** pGlyph, Point& rPos, int& nStart, const LogicalFontInstance** ppGlyphFont = nullptr, const vcl::font::PhysicalFontFace** pFallbackFont = nullptr) const ove
[Libreoffice-commits] core.git: desktop/qa desktop/source
desktop/qa/unit/desktop-lok-init.cxx | 44 +++ desktop/source/app/app.cxx|4 desktop/source/app/appinit.cxx| 10 - desktop/source/app/check_ext_deps.cxx |6 desktop/source/app/dispatchwatcher.cxx| 62 -- desktop/source/app/opencl.cxx |6 desktop/source/deployment/gui/dp_gui_updatedialog.cxx | 27 +--- desktop/source/deployment/manager/dp_extensionmanager.cxx |3 desktop/source/deployment/manager/dp_informationprovider.cxx |8 - desktop/source/deployment/misc/dp_dependencies.cxx|3 desktop/source/deployment/misc/dp_descriptioninfoset.cxx |3 desktop/source/deployment/registry/component/dp_component.cxx | 10 - desktop/source/deployment/registry/configuration/dp_configuration.cxx |5 desktop/source/deployment/registry/dp_registry.cxx|7 - desktop/source/deployment/registry/help/dp_help.cxx |3 desktop/source/deployment/registry/package/dp_package.cxx | 19 +-- desktop/source/deployment/registry/script/dp_script.cxx |5 desktop/source/lib/init.cxx | 23 +-- desktop/source/lib/lokclipboard.cxx |7 - desktop/source/migration/migration.cxx| 22 ++- 20 files changed, 120 insertions(+), 157 deletions(-) New commits: commit 471f5ab323c5676ca22358ca67f4e6820b7e071c Author: Mike Kaganski AuthorDate: Fri Oct 29 09:27:05 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 17:39:47 2021 +0200 Prepare for removal of non-const operator[] from Sequence in desktop Change-Id: I76959f62d46e12d984fe4c7be74e5857399e9126 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124358 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/desktop/qa/unit/desktop-lok-init.cxx b/desktop/qa/unit/desktop-lok-init.cxx index 7e6e266cf899..49971afc2e5c 100644 --- a/desktop/qa/unit/desktop-lok-init.cxx +++ b/desktop/qa/unit/desktop-lok-init.cxx @@ -11,6 +11,7 @@ #include #include #include +#include #include #include @@ -61,9 +62,7 @@ void LOKInitTest::testJsonToPropertyValues() "\"value\":\"something.odt\"" "}}"; -uno::Sequence aArgs(1); -aArgs[0].Name = "FileName"; -aArgs[0].Value <<= OUString("something.odt"); +uno::Sequence aArgs{ comphelper::makePropertyValue("FileName", OUString("something.odt")) }; assertSequencesEqual( aArgs, comphelper::containerToSequence(desktop::jsonToPropertyValuesVector(arguments))); @@ -129,31 +128,26 @@ void LOKInitTest::testJsonToPropertyValuesBorder() "}}"; // see SvxBoxItem::QueryValue for details -uno::Sequence aOuterSeq(9); table::BorderLine2 aLine(sal_Int32(COL_BLACK), 0, 1, 0, table::BorderLineStyle::SOLID, 1); -aOuterSeq[0] <<= aLine; // left -aOuterSeq[1] <<= aLine; // right -aOuterSeq[2] <<= aLine; // bottom -aOuterSeq[3] <<= aLine; // top -aOuterSeq[4] <<= static_cast(0); -aOuterSeq[5] <<= static_cast(0); -aOuterSeq[6] <<= static_cast(0); -aOuterSeq[7] <<= static_cast(0); -aOuterSeq[8] <<= static_cast(0); +uno::Sequence aOuterSeq{ uno::Any(aLine), // left + uno::Any(aLine), // right + uno::Any(aLine), // bottom + uno::Any(aLine), // top + uno::Any(static_cast(0)), + uno::Any(static_cast(0)), + uno::Any(static_cast(0)), + uno::Any(static_cast(0)), + uno::Any(static_cast(0)) }; // see SvxBoxInfoItem::QueryValue() for details -uno::Sequence aInnerSeq(5); -aInnerSeq[0] <<= aLine; // horizontal -aInnerSeq[1] <<= aLine; // vertical -aInnerSeq[2] <<= static_cast(0); -aInnerSeq[3] <<= static_cast(0x7F); -aInnerSeq[4] <<= static_cast(0); - -uno::Sequence aArgs(2); -aArgs[0].Name = "OuterBorder"; -aArgs[0].Value <<= aOuterSeq; -aArgs[1].Name = "InnerBorder"; -aArgs[1].Value <<= aInnerSeq; +uno::Sequence aInnerSeq{ uno::Any(aLine), // horizontal + uno::Any(aLine), // vertical + uno::Any(static_cast(0)), + uno::Any(static_cast(0x7F)), + uno::Any(static_cast(0)) }; + +uno::Sequence aArgs{ comphelper::makePropertyValue("OuterBorder",
[Libreoffice-commits] core.git: lotuswordpro/qa
lotuswordpro/qa/cppunit/test_lotuswordpro.cxx |8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) New commits: commit 7ba7c1128f469ee5631f3221f6c468ed24c04b98 Author: Mike Kaganski AuthorDate: Fri Oct 29 09:49:13 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 17:39:15 2021 +0200 Prepare for removal of non-const operator[] from Sequence in lotuswordpro Change-Id: Id71f7a16d5ba0b47676d11136ef327205c370aab Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124375 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/lotuswordpro/qa/cppunit/test_lotuswordpro.cxx b/lotuswordpro/qa/cppunit/test_lotuswordpro.cxx index 78a5426a5a79..f4c16903059f 100644 --- a/lotuswordpro/qa/cppunit/test_lotuswordpro.cxx +++ b/lotuswordpro/qa/cppunit/test_lotuswordpro.cxx @@ -7,6 +7,10 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +#include + +#include + #include #include #include @@ -50,9 +54,7 @@ namespace const OUString &rURL, const OUString &, SfxFilterFlags, SotClipboardFormatId, unsigned int) { -uno::Sequence< beans::PropertyValue > aDescriptor(1); -aDescriptor[0].Name = "URL"; -aDescriptor[0].Value <<= rURL; +uno::Sequence aDescriptor{ comphelper::makePropertyValue("URL", rURL) }; return m_xFilter->filter(aDescriptor); }
[Libreoffice-commits] core.git: canvas/source cppcanvas/source drawinglayer/source editeng/inc editeng/source emfio/inc emfio/source filter/source include/editeng include/vcl sc/source starmath/source
canvas/source/cairo/cairo_textlayout.cxx|4 +- canvas/source/cairo/cairo_textlayout.hxx|2 - canvas/source/opengl/ogl_canvashelper.cxx |2 - canvas/source/vcl/textlayout.cxx|8 ++-- canvas/source/vcl/textlayout.hxx|2 - cppcanvas/source/inc/implrenderer.hxx |2 - cppcanvas/source/mtfrenderer/implrenderer.cxx | 10 ++--- cppcanvas/source/mtfrenderer/textaction.cxx | 10 ++--- cppcanvas/source/mtfrenderer/textaction.hxx |2 - drawinglayer/source/primitive2d/textlayoutdevice.cxx|4 +- drawinglayer/source/processor2d/vclprocessor2d.cxx |2 - drawinglayer/source/tools/wmfemfhelper.cxx |2 - editeng/inc/editdoc.hxx | 18 +- editeng/source/editeng/editdoc.cxx |8 ++-- editeng/source/editeng/editeng.cxx |2 - editeng/source/editeng/impedit.hxx |2 - editeng/source/editeng/impedit2.cxx |2 - editeng/source/editeng/impedit3.cxx | 18 +- editeng/source/items/svxfont.cxx|4 +- editeng/source/outliner/outleeng.cxx|2 - editeng/source/outliner/outleeng.hxx|2 - editeng/source/outliner/outliner.cxx|4 +- emfio/inc/mtftools.hxx |2 - emfio/source/reader/emfreader.cxx |2 - emfio/source/reader/mtftools.cxx|8 ++-- emfio/source/reader/wmfreader.cxx |4 +- filter/source/svg/svgwriter.cxx | 10 ++--- filter/source/svg/svgwriter.hxx |4 +- include/editeng/editeng.hxx |2 - include/editeng/outliner.hxx|6 +-- include/editeng/svxfont.hxx |4 +- include/vcl/devicecoordinate.hxx|2 - include/vcl/metaact.hxx | 10 ++--- include/vcl/outdev.hxx | 12 +++--- include/vcl/pdfwriter.hxx |2 - sc/source/ui/view/output2.cxx |2 - starmath/source/accessibility.cxx |4 +- svx/source/customshapes/EnhancedCustomShapeFontWork.cxx |2 - sw/source/core/inc/scriptinfo.hxx | 12 +++--- sw/source/core/text/porlay.cxx | 14 sw/source/core/txtnode/fntcache.cxx | 28 toolkit/source/awt/vclxfont.cxx |2 - toolkit/source/awt/vclxgraphics.cxx |2 - vcl/inc/calendar.hxx|2 - vcl/inc/pdf/pdfwriter_impl.hxx |2 - vcl/qa/cppunit/complextext.cxx | 10 ++--- vcl/qa/cppunit/svm/svmtest.cxx |2 - vcl/source/control/calendar.cxx |2 - vcl/source/filter/eps/eps.cxx |8 ++-- vcl/source/filter/svm/SvmConverter.cxx |4 +- vcl/source/filter/svm/SvmReader.cxx |2 - vcl/source/filter/svm/SvmWriter.cxx |2 - vcl/source/filter/wmf/emfwr.cxx |6 +-- vcl/source/filter/wmf/emfwr.hxx |2 - vcl/source/filter/wmf/wmfwr.cxx |8 ++-- vcl/source/filter/wmf/wmfwr.hxx |6 +-- vcl/source/gdi/metaact.cxx |6 +-- vcl/source/gdi/pdfwriter.cxx|2 - vcl/source/gdi/pdfwriter_impl.cxx |2 - vcl/source/gdi/textlayout.cxx |6 +-- vcl/source/outdev/text.cxx | 12 +++--- vcl/workben/vcldemo.cxx |2 - 62 files changed, 166 insertions(+), 166 deletions(-) New commits: commit bc413e15fae3672f580894a3cd7b077d533d8e6c Author: Noel Grandin AuthorDate: Sat Oct 30 11:03:48 2021 +0200 Commit: Noel Grandin CommitDate: Sat Oct 30 15:43:23 2021 +0200 tools::Long->sal_Int32 in the DX arrays Change-Id: I36ddc11b39763dc77086591fe9bb756195b4294f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124459 Tested-by: Jenkins Reviewed-by: Noel Grandin diff --git a/canvas/source/cairo/cairo_textlayout.cxx b/canvas/source/cairo/cairo_textlayout.cxx index acf2672be51d..7dc992a8c360 100644 --- a/canvas/source/cairo/cairo_textlayout.cxx +++ b/canvas/source/cairo/cairo_textlayout.cxx @@ -263,7 +263,7 @@ namespace cairocanvas ::osl::MutexGuard aGuard( m_aMutex
[Libreoffice-commits] core.git: Branch 'libreoffice-7-2' - dbaccess/source
dbaccess/source/core/dataaccess/databasedocument.cxx |9 + dbaccess/source/core/dataaccess/databasedocument.hxx |7 +-- 2 files changed, 14 insertions(+), 2 deletions(-) New commits: commit 6a94729cba8d452f5390672b69843607f7287dba Author: Noel Grandin AuthorDate: Fri Oct 29 11:35:14 2021 +0200 Commit: Noel Grandin CommitDate: Sat Oct 30 14:26:46 2021 +0200 tdf#143392 fix title on Base window regression from commit 857caa5fc69b92e781457a1b67a89aa051c2d70f tdf#79049 speed up OOXML workbook load Change-Id: Ia2d55386a7508dc2bbb2fa8501b45c3f30ad6a75 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124423 Tested-by: Jenkins Reviewed-by: Noel Grandin (cherry picked from commit 31315fea28ad327f36c0e593156bf808c7af3467) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124201 diff --git a/dbaccess/source/core/dataaccess/databasedocument.cxx b/dbaccess/source/core/dataaccess/databasedocument.cxx index 603a0622b2ba..0fad46db2ff0 100644 --- a/dbaccess/source/core/dataaccess/databasedocument.cxx +++ b/dbaccess/source/core/dataaccess/databasedocument.cxx @@ -793,6 +793,15 @@ Sequence< PropertyValue > SAL_CALL ODatabaseDocument::getArgs( ) return m_pImpl->getMediaDescriptor().getPropertyValues(); } +Sequence< PropertyValue > SAL_CALL ODatabaseDocument::getArgs2( const ::css::uno::Sequence< ::rtl::OUString >& requestedArgs ) +{ +DocumentGuard aGuard( *this, DocumentGuard::MethodWithoutInit ); +std::vector aRet; +for (const auto & rArgName : requestedArgs) +aRet.push_back(PropertyValue(rArgName, 0, m_pImpl->getMediaDescriptor().get(rArgName), PropertyState_DIRECT_VALUE)); +return comphelper::containerToSequence(aRet); +} + void SAL_CALL ODatabaseDocument::setArgs(const Sequence& /* aArgs */) { throw NoSupportException(); diff --git a/dbaccess/source/core/dataaccess/databasedocument.hxx b/dbaccess/source/core/dataaccess/databasedocument.hxx index b1bfbedc61b2..b20a2f3ed1d8 100644 --- a/dbaccess/source/core/dataaccess/databasedocument.hxx +++ b/dbaccess/source/core/dataaccess/databasedocument.hxx @@ -28,7 +28,7 @@ #include #include -#include +#include #include #include #include @@ -130,7 +130,7 @@ private: }; // ODatabaseDocument -typedef cppu::PartialWeakComponentImplHelper< css::frame::XModel2 +typedef cppu::PartialWeakComponentImplHelper< css::frame::XModel3 , css::util::XModifiable , css::frame::XStorable , css::document::XEventBroadcaster @@ -330,6 +330,9 @@ public: virtual css::uno::Reference< css::frame::XController2 > SAL_CALL createViewController( const OUString& ViewName, const css::uno::Sequence< css::beans::PropertyValue >& Arguments, const css::uno::Reference< css::frame::XFrame >& Frame ) override ; virtual void SAL_CALL setArgs(const css::uno::Sequence& aArgs) override; +// XModel3 +virtual ::css::uno::Sequence< ::css::beans::PropertyValue > SAL_CALL getArgs2( const ::css::uno::Sequence< ::rtl::OUString >& requestedArgs ) override; + // XStorable virtual sal_Bool SAL_CALL hasLocation( ) override ; virtual OUString SAL_CALL getLocation( ) override ;
New Defects reported by Coverity Scan for LibreOffice
Hi, Please find the latest report on new defect(s) introduced to LibreOffice found with Coverity Scan. 1 new defect(s) introduced to LibreOffice found with Coverity Scan. 2 defect(s), reported by Coverity Scan earlier, were marked fixed in the recent build analyzed by Coverity Scan. New defect(s) Reported-by: Coverity Scan Showing 1 of 1 defect(s) ** CID 1416802: Uninitialized variables (UNINIT) /usr/lib/gcc/x86_64-redhat-linux/9/include/avx512fintrin.h: 207 in _mm512_undefined_epi32()() *** CID 1416802: Uninitialized variables (UNINIT) /usr/lib/gcc/x86_64-redhat-linux/9/include/avx512fintrin.h: 207 in _mm512_undefined_epi32()() 201 202 extern __inline __m512i 203 __attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) 204 _mm512_undefined_epi32 (void) 205 { 206 __m512i __Y = __Y; >>> CID 1416802: Uninitialized variables (UNINIT) >>> Using uninitialized value "__Y". 207 return __Y; 208 } 209 210 #define _mm512_undefined_si512 _mm512_undefined_epi32 211 212 extern __inline __m512i To view the defects in Coverity Scan visit, https://u15810271.ct.sendgrid.net/ls/click?upn=HRESupC-2F2Czv4BOaCWWCy7my0P0qcxCbhZ31OYv50ypSs1kiFPuCn2xFdlMIFBirii0zZ9j2-2F9F2XPBcBm2BNgi9duPy3v-2FzgFDd2LJ-2BDKI-3DBH1h_OTq2XUZbbipYjyLSo6GRo-2FpVxQ9OzkDINu9UTS-2FQhSdO0F0jQniitrGlNxDIzPJihMvTdIy7P-2BrOZSNVsZQbGlUwfNH0QH-2Bzfe2ZIlMYSTCIQqYtE1Y31kag-2FiOL1n15CHEbOSKwZGmdpvD7X9hJ79lBJfBWoAYjrrL7o4leC18V0UcYyf1w-2BVMc6S2A-2FkBKlJQvCSsmMUfV9QaNda7jFMgMhc0ZFwezjEuL4sY6XMs-3D
[Libreoffice-commits] core.git: sc/source
sc/source/ui/dbgui/asciiopt.cxx |1 + sc/source/ui/dbgui/imoptdlg.cxx |3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) New commits: commit 70db0942c3f63bed8c2ff517e80c06cef9b52267 Author: Eike Rathke AuthorDate: Fri Oct 29 22:41:04 2021 +0200 Commit: Eike Rathke CommitDate: Sat Oct 30 11:46:29 2021 +0200 Add comments for defaults of bEvaluateFormulas The default is "true" if not present at all for compatibility of older filter options strings. The default is "false" if present. Change-Id: I79383e6fcf211fc8b8f933ae93f6d53ec084d551 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124454 Reviewed-by: Eike Rathke Tested-by: Jenkins diff --git a/sc/source/ui/dbgui/asciiopt.cxx b/sc/source/ui/dbgui/asciiopt.cxx index 3bb97c5b3236..c7f920f5fb25 100644 --- a/sc/source/ui/dbgui/asciiopt.cxx +++ b/sc/source/ui/dbgui/asciiopt.cxx @@ -186,6 +186,7 @@ void ScAsciiOptions::ReadFromString( const OUString& rString ) // Token 12: evaluate formulas. if (nPos >= 0) { +// If present, defaults to "false". bEvaluateFormulas = rString.getToken(0, ',', nPos) == "true"; } else diff --git a/sc/source/ui/dbgui/imoptdlg.cxx b/sc/source/ui/dbgui/imoptdlg.cxx index 2b279f1be10a..7c161da22754 100644 --- a/sc/source/ui/dbgui/imoptdlg.cxx +++ b/sc/source/ui/dbgui/imoptdlg.cxx @@ -45,7 +45,7 @@ ScImportOptions::ScImportOptions( const OUString& rStr ) bSaveFormulas = false; bRemoveSpace = false; nSheetToExport = 0; -bEvaluateFormulas = true; +bEvaluateFormulas = true; // true if not present at all, for compatibility sal_Int32 nTokenCount = comphelper::string::getTokenCount(rStr, ','); if ( nTokenCount < 3 ) return; @@ -91,6 +91,7 @@ ScImportOptions::ScImportOptions( const OUString& rStr ) nSheetToExport = -23; // invalid, force error } if ( nTokenCount >= 13 ) +// If present, defaults to "false". bEvaluateFormulas = rStr.getToken(0, ',', nIdx) == "true"; } }
[Libreoffice-commits] core.git: hwpfilter/qa
hwpfilter/qa/cppunit/test_hwpfilter.cxx |6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) New commits: commit fbb4c0955d8c346c385e2ad72b061572475cb1fc Author: Mike Kaganski AuthorDate: Fri Oct 29 09:45:16 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 11:15:49 2021 +0200 Prepare for removal of non-const operator[] from Sequence in hwpfilter Change-Id: I43690203f91cc9bc575470de58c7d1198d2ee7c9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124371 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/hwpfilter/qa/cppunit/test_hwpfilter.cxx b/hwpfilter/qa/cppunit/test_hwpfilter.cxx index 125b115cc3d2..2bb942aba5a0 100644 --- a/hwpfilter/qa/cppunit/test_hwpfilter.cxx +++ b/hwpfilter/qa/cppunit/test_hwpfilter.cxx @@ -11,6 +11,7 @@ #include #include +#include #include #include #include @@ -43,10 +44,7 @@ namespace uno::Reference xFilter(m_xSFactory->createInstance("com.sun.comp.hwpimport.HwpImportFilter"), uno::UNO_QUERY_THROW); -uno::Sequence< beans::PropertyValue > aDescriptor(1); -aDescriptor[0].Name = "URL"; -aDescriptor[0].Value <<= rURL; -return xFilter->filter(aDescriptor); +return xFilter->filter({ comphelper::makePropertyValue("URL", rURL) }); } void HwpFilterTest::test()
[Libreoffice-commits] core.git: sd/source
sd/source/ui/slideshow/slideshowimpl.cxx |3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) New commits: commit 1635f94ad500bc323c04738d62a7af0e64034221 Author: Caolán McNamara AuthorDate: Fri Oct 29 14:40:34 2021 +0100 Commit: Caolán McNamara CommitDate: Sat Oct 30 11:07:51 2021 +0200 add SfxUnoFrameItem arg to indicate what frame sent this SfxRequest Change-Id: I35b581e1ab66a5fbd9bd9c1034a5c8f22c0294e5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124442 Tested-by: Jenkins Reviewed-by: Caolán McNamara diff --git a/sd/source/ui/slideshow/slideshowimpl.cxx b/sd/source/ui/slideshow/slideshowimpl.cxx index ddb72ded108d..b199bd03ddf0 100644 --- a/sd/source/ui/slideshow/slideshowimpl.cxx +++ b/sd/source/ui/slideshow/slideshowimpl.cxx @@ -1501,9 +1501,10 @@ void SlideshowImpl::click( const Reference< XShape >& xShape ) SfxViewFrame* pViewFrm = SfxViewFrame::Current(); if (pViewFrm) { +SfxUnoFrameItem aDocFrame(SID_FILLFRAME, pViewFrm->GetFrame().GetFrameInterface()); pViewFrm->GetDispatcher()->ExecuteList( SID_OPENDOC, SfxCallMode::ASYNCHRON | SfxCallMode::RECORD, -{ &aUrl, &aBrowsing }); +{ &aUrl, &aBrowsing }, { &aDocFrame } ); } } }
[Libreoffice-commits] core.git: cui/source
cui/source/dialogs/scriptdlg.cxx |9 + cui/source/inc/scriptdlg.hxx |1 + 2 files changed, 6 insertions(+), 4 deletions(-) New commits: commit d33703e26a926507637733612ef169b3f3e05002 Author: Caolán McNamara AuthorDate: Fri Oct 29 12:54:26 2021 +0100 Commit: Caolán McNamara CommitDate: Sat Oct 30 11:07:29 2021 +0200 Resolves: tdf#145377 don't use dismissed dialog as parent for error dialogs the script dialog is dismissed before the error dialogs get executed Change-Id: I9e143a7e65077d09f436c4744759c78a9970f1d0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124430 Tested-by: Jenkins Reviewed-by: Caolán McNamara diff --git a/cui/source/dialogs/scriptdlg.cxx b/cui/source/dialogs/scriptdlg.cxx index 3ba92fc337cf..4ae05a0c48e6 100644 --- a/cui/source/dialogs/scriptdlg.cxx +++ b/cui/source/dialogs/scriptdlg.cxx @@ -372,6 +372,7 @@ CuiInputDialog::CuiInputDialog(weld::Window * pParent, InputDialogMode nMode) SvxScriptOrgDialog::SvxScriptOrgDialog(weld::Window* pParent, const OUString& language) : SfxDialogController(pParent, "cui/ui/scriptorganizer.ui", "ScriptOrganizerDialog") +, m_pParent(pParent) , m_sLanguage(language) , m_delErrStr(CuiResId(RID_SVXSTR_DELFAILED)) , m_delErrTitleStr(CuiResId(RID_SVXSTR_DELFAILED_TITLE)) @@ -622,19 +623,19 @@ IMPL_LINK(SvxScriptOrgDialog, ButtonHdl, weld::Button&, rButton, void) } catch ( reflection::InvocationTargetException& ite ) { -SvxScriptErrorDialog::ShowAsyncErrorDialog(getDialog(), css::uno::Any(ite)); +SvxScriptErrorDialog::ShowAsyncErrorDialog(m_pParent, css::uno::Any(ite)); } catch ( provider::ScriptFrameworkErrorException& ite ) { -SvxScriptErrorDialog::ShowAsyncErrorDialog(getDialog(), css::uno::Any(ite)); +SvxScriptErrorDialog::ShowAsyncErrorDialog(m_pParent, css::uno::Any(ite)); } catch ( RuntimeException& re ) { -SvxScriptErrorDialog::ShowAsyncErrorDialog(getDialog(), css::uno::Any(re)); +SvxScriptErrorDialog::ShowAsyncErrorDialog(m_pParent, css::uno::Any(re)); } catch ( Exception& e ) { -SvxScriptErrorDialog::ShowAsyncErrorDialog(getDialog(), css::uno::Any(e)); +SvxScriptErrorDialog::ShowAsyncErrorDialog(m_pParent, css::uno::Any(e)); } } StoreCurrentSelection(); diff --git a/cui/source/inc/scriptdlg.hxx b/cui/source/inc/scriptdlg.hxx index 3f16d8a66bab..d2e5cae7f27d 100644 --- a/cui/source/inc/scriptdlg.hxx +++ b/cui/source/inc/scriptdlg.hxx @@ -77,6 +77,7 @@ public: class SvxScriptOrgDialog : public SfxDialogController { protected: +weld::Window* m_pParent; OUString m_sLanguage; static Selection_hash m_lastSelection; const OUString m_delErrStr;
[Libreoffice-commits] core.git: bin/lo-all-static-libs bin/oss-fuzz-setup.sh config_host.mk.in configure.ac download.lst external/libjpeg-turbo RepositoryExternal.mk solenv/bin solenv/gbuild
RepositoryExternal.mk | 10 bin/lo-all-static-libs |1 bin/oss-fuzz-setup.sh |2 config_host.mk.in |2 configure.ac| 34 +- download.lst|4 external/libjpeg-turbo/ExternalProject_libjpeg-turbo.mk | 43 --- external/libjpeg-turbo/Module_libjpeg-turbo.mk |2 external/libjpeg-turbo/StaticLibrary_libjpeg-turbo.mk | 214 external/libjpeg-turbo/UnpackedTarball_libjpeg-turbo.mk | 13 external/libjpeg-turbo/jconfig.h| 86 ++ external/libjpeg-turbo/jconfigint.h | 51 +++ external/libjpeg-turbo/jpeg-turbo.build.patch.1 | 58 external/libjpeg-turbo/jpeg-turbo.win_build.patch.1 | 54 external/libjpeg-turbo/ubsan.patch | 39 -- solenv/bin/concat-deps.c|5 solenv/gbuild/LinkTarget.mk | 77 + solenv/gbuild/StaticLibrary.mk |2 solenv/gbuild/TargetLocations.mk|3 solenv/gbuild/platform/android.mk |1 solenv/gbuild/platform/com_MSC_class.mk |1 solenv/gbuild/platform/iOS.mk |2 solenv/gbuild/platform/macosx.mk|2 solenv/gbuild/platform/solaris.mk |2 solenv/gbuild/platform/unxgcc.mk|2 25 files changed, 482 insertions(+), 228 deletions(-) New commits: commit 1295f497e0cc7fc7cfcb66182496a4d29aa701b3 Author: Caolán McNamara AuthorDate: Wed Oct 20 16:07:29 2021 +0100 Commit: Caolán McNamara CommitDate: Sat Oct 30 11:06:48 2021 +0200 upgrade libjpeg-turbo to 2.1.1 simd enabled for x86_64 and x86, arm/aarch64 might be worth exploring too Change-Id: Ic2726ee8c6b6e59ca983b977ee2731f5b78b97d1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123898 Tested-by: Jenkins Reviewed-by: Caolán McNamara diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk index 951267d0e624..23d4b2e63637 100644 --- a/RepositoryExternal.mk +++ b/RepositoryExternal.mk @@ -402,6 +402,10 @@ endif # SYSTEM_ZLIB ifneq ($(SYSTEM_LIBJPEG),) define gb_LinkTarget__use_libjpeg +$(call gb_LinkTarget_set_include,$(1),\ + $$(INCLUDE) \ + $(LIBJPEG_CFLAGS) \ +) $(call gb_LinkTarget_add_libs,$(1),$(LIBJPEG_LIBS)) $(call gb_LinkTarget_set_ldflags,$(1),\ $$(filter-out -L/usr/lib/jvm%,$$(T_LDFLAGS)) \ @@ -414,12 +418,12 @@ gb_ExternalProject__use_libjpeg := else define gb_LinkTarget__use_libjpeg +$(call gb_LinkTarget_use_external_project,$(1),libjpeg-turbo,full) $(call gb_LinkTarget_set_include,$(1),\ - $(LIBJPEG_CFLAGS) \ + -I$(call gb_UnpackedTarball_get_dir,libjpeg-turbo) \ $$(INCLUDE) \ ) -$(call gb_LinkTarget_add_libs,$(1),$(LIBJPEG_LIBS)) -$(call gb_LinkTarget_use_external_project,$(1),libjpeg-turbo,full) +$(call gb_LinkTarget_use_static_libraries,$(1),libjpeg-turbo) endef diff --git a/bin/lo-all-static-libs b/bin/lo-all-static-libs index d89dd8eca296..11230c695248 100755 --- a/bin/lo-all-static-libs +++ b/bin/lo-all-static-libs @@ -111,7 +111,6 @@ echo $INSTDIR/$LIBO_LIB_FOLDER/lib*.a \ $WORKDIR/LinkTarget/StaticLibrary/lib*.a \ $oslibs \ $WORKDIR/UnpackedTarball/icu/source/lib/*.a \ - $WORKDIR/UnpackedTarball/libjpeg-turbo/.libs/*.a \ $WORKDIR/UnpackedTarball/liblangtag/liblangtag/.libs/*.a \ $WORKDIR/UnpackedTarball/lcms2/src/.libs/*.a \ $WORKDIR/UnpackedTarball/libabw/src/lib/.libs/*.a \ diff --git a/bin/oss-fuzz-setup.sh b/bin/oss-fuzz-setup.sh index 39ff8a8d8d5b..22c9ef2b7e49 100755 --- a/bin/oss-fuzz-setup.sh +++ b/bin/oss-fuzz-setup.sh @@ -21,7 +21,7 @@ curl --no-progress-meter -S \ -C - -O https://dev-www.libreoffice.org/src/dtoa-20180411.tgz \ -C - -O https://dev-www.libreoffice.org/src/expat-2.4.1.tar.bz2 \ -C - -O https://dev-www.libreoffice.org/src/libcuckoo-93217f8d391718380c508a722ab9acd5e9081233.tar.gz \ --C - -O https://dev-www.libreoffice.org/src/libjpeg-turbo-1.5.3.tar.gz \ +-C - -O https://dev-www.libreoffice.org/src/libjpeg-turbo-2.1.1.tar.gz \ -C - -O https://dev-www.libreoffice.org/src/lcms2-2.12.tar.gz \ -C - -O https://dev-www.libreoffice.org/src/libexttextcat-3.4.5.tar.xz \ -C - -O https://dev-www.libreoffice.org/src/cppunit-1.15.1.tar.gz \ diff --git a/config_host.mk.in b/config_host.mk.in index 3970cb6a61c9..4b4f58f80fc2 100644 --- a/config_host.mk.in +++ b/config_host.mk.in @@ -452,6 +452,7 @@ export MWAW_LIBS=$(gb_SPACE)@MWAW_LIBS@ export MYTHES_CFLAGS=$(gb_SPACE)@MYTHES_CFLAGS@ export MYTHES_LIBS=$(gb_SPACE)@MYTHES_LIBS@ export NASM=@NASM@ +export NAFLAGS=@NAFLAGS@
[Libreoffice-commits] core.git: i18npool/source
i18npool/source/defaultnumberingprovider/defaultnumberingprovider.cxx |9 - i18npool/source/localedata/LocaleNode.cxx |6 i18npool/source/localedata/localedata.cxx | 52 -- i18npool/source/nativenumber/nativenumbersupplier.cxx | 69 i18npool/source/search/textsearch.cxx | 84 +- i18npool/source/textconversion/textconversion_ko.cxx |6 i18npool/source/textconversion/textconversion_zh.cxx | 11 - i18npool/source/transliteration/textToPronounce_zh.cxx|9 - i18npool/source/transliteration/transliterationImpl.cxx | 18 +- i18npool/source/transliteration/transliteration_Numeric.cxx | 17 +- 10 files changed, 154 insertions(+), 127 deletions(-) New commits: commit 45de43ce9f1441735817fa82924ddc4508d221cd Author: Mike Kaganski AuthorDate: Fri Oct 29 09:46:05 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 10:55:23 2021 +0200 Prepare for removal of non-const operator[] from Sequence in i18npool Change-Id: Ib4c59c45098376f2e0a610a8ffefb4af5306bd6d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124372 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/i18npool/source/defaultnumberingprovider/defaultnumberingprovider.cxx b/i18npool/source/defaultnumberingprovider/defaultnumberingprovider.cxx index e5d631e3e1e5..831b502a2771 100644 --- a/i18npool/source/defaultnumberingprovider/defaultnumberingprovider.cxx +++ b/i18npool/source/defaultnumberingprovider/defaultnumberingprovider.cxx @@ -1121,11 +1121,12 @@ OUString DefaultNumberingProvider::makeNumberingIdentifier(sal_Int16 index) OUStringBuffer result; Locale aLocale("en", OUString(), OUString()); Sequence aProperties(2); -aProperties[0].Name = "NumberingType"; -aProperties[0].Value <<= aSupportedTypes[index].nType; -aProperties[1].Name = "Value"; +auto aPropertiesRange = asNonConstRange(aProperties); +aPropertiesRange[0].Name = "NumberingType"; +aPropertiesRange[0].Value <<= aSupportedTypes[index].nType; +aPropertiesRange[1].Name = "Value"; for (sal_Int32 j = 1; j <= 3; j++) { -aProperties[1].Value <<= j; +aPropertiesRange[1].Value <<= j; result.append( makeNumberingString( aProperties, aLocale ) ); result.append(", "); } diff --git a/i18npool/source/localedata/LocaleNode.cxx b/i18npool/source/localedata/LocaleNode.cxx index 86fc96495bd4..f4c0aaefdc94 100644 --- a/i18npool/source/localedata/LocaleNode.cxx +++ b/i18npool/source/localedata/LocaleNode.cxx @@ -2364,10 +2364,12 @@ void LCOutlineNumberingLevelNode::generateCode (const OFileWriter &of) const Attr::Attr (const Reference< XAttributeList > & attr) { sal_Int16 len = attr->getLength(); name.realloc (len); +auto pName = name.getArray(); value.realloc (len); +auto pValue = value.getArray(); for (sal_Int16 i =0; i< len;i++) { -name[i] = attr->getNameByIndex(i); -value[i] = attr -> getValueByIndex(i); +pName[i] = attr->getNameByIndex(i); +pValue[i] = attr -> getValueByIndex(i); } } diff --git a/i18npool/source/localedata/localedata.cxx b/i18npool/source/localedata/localedata.cxx index 5aecfa32a7fd..5e8f1dee2f79 100644 --- a/i18npool/source/localedata/localedata.cxx +++ b/i18npool/source/localedata/localedata.cxx @@ -758,6 +758,7 @@ LocaleDataImpl::getAllCalendars2( const Locale& rLocale ) allCalendars = func(calendarsCount); Sequence< Calendar2 > calendarsSeq(calendarsCount); +auto calendarsSeqRange = asNonConstRange(calendarsSeq); sal_Int16 offset = REF_OFFSET_COUNT; for(sal_Int16 i = 0; i < calendarsCount; i++) { OUString calendarID(allCalendars[offset]); @@ -780,7 +781,7 @@ LocaleDataImpl::getAllCalendars2( const Locale& rLocale ) offset++; Calendar2 aCalendar(days, months, gmonths, pmonths, eras, startOfWeekDay, minimalDaysInFirstWeek, defaultCalendar, calendarID); -calendarsSeq[i] = aCalendar; +calendarsSeqRange[i] = aCalendar; } return calendarsSeq; } @@ -812,6 +813,7 @@ LocaleDataImpl::getAllCurrencies2( const Locale& rLocale ) sal_Unicode **allCurrencies = func(currencyCount); Sequence< Currency2 > seq(currencyCount); +auto seqRange = asNonConstRange(seq); for(int i = 0, nOff = 0; i < currencyCount; i++, nOff += 8 ) { Currency2 cur( OUString(allCurrencies[nOff]), // string ID @@ -823,7 +825,7 @@ LocaleDataImpl::getAllCurrencies2( const Locale& rLocale ) allCurrencies[nOff+6][0], // short DecimalPlaces allCurrencies[nOff+7][0] != 0 // bo
[Libreoffice-commits] core.git: fpicker/source
fpicker/source/aqua/ControlHelper.mm | 13 +++-- fpicker/source/aqua/SalAquaFilePicker.mm |3 ++- fpicker/source/office/OfficeFilePicker.cxx | 13 - fpicker/source/office/RemoteFilesDialog.cxx |6 -- fpicker/source/office/contentenumeration.cxx | 26 -- fpicker/source/office/iodlg.cxx | 14 -- 6 files changed, 37 insertions(+), 38 deletions(-) New commits: commit b3bf75786f6cfd3feae735ae705e87f48d8059ed Author: Mike Kaganski AuthorDate: Fri Oct 29 09:43:43 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 10:32:07 2021 +0200 Prepare for removal of non-const operator[] from Sequence in fpicker Change-Id: I918b785082b89833839fc0a7eeb7cb36a91f897a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124369 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/fpicker/source/aqua/ControlHelper.mm b/fpicker/source/aqua/ControlHelper.mm index 1feb6d9458a2..88f0b655cb58 100644 --- a/fpicker/source/aqua/ControlHelper.mm +++ b/fpicker/source/aqua/ControlHelper.mm @@ -66,12 +66,13 @@ uno::Any HandleGetListValue(const NSControl* pControl, const sal_Int16 nControlA int nItems = [rMenu numberOfItems]; if (nItems > 0) { aItemList.realloc(nItems); -} -for (int i = 0; i < nItems; i++) { -NSString* sCFItem = [pButton itemTitleAtIndex:i]; -if (nil != sCFItem) { -aItemList[i] = [sCFItem OUString]; -SAL_INFO("fpicker.aqua","Return value[" << (i - 1) << "]: " << aItemList[i - 1]); +OUString* pItemList = aItemList.getArray(); +for (int i = 0; i < nItems; i++) { +NSString* sCFItem = [pButton itemTitleAtIndex:i]; +if (nil != sCFItem) { +pItemList[i] = [sCFItem OUString]; +SAL_INFO("fpicker.aqua","Return value[" << (i - 1) << "]: " << aItemList[i - 1]); +} } } diff --git a/fpicker/source/aqua/SalAquaFilePicker.mm b/fpicker/source/aqua/SalAquaFilePicker.mm index fa2ec600c2ec..01e6f80e92b5 100644 --- a/fpicker/source/aqua/SalAquaFilePicker.mm +++ b/fpicker/source/aqua/SalAquaFilePicker.mm @@ -250,6 +250,7 @@ uno::Sequence SAL_CALL SalAquaFilePicker::getSelectedFiles() SAL_INFO("fpicker.aqua", "# of items: " << nFiles); uno::Sequence< OUString > aSelectedFiles(nFiles); +OUString* pSelectedFiles = aSelectedFiles.getArray(); for(NSUInteger nIndex = 0; nIndex < nFiles; nIndex += 1) { @@ -279,7 +280,7 @@ uno::Sequence SAL_CALL SalAquaFilePicker::getSelectedFiles() OUString sFileOrDirURL = [url OUString]; -aSelectedFiles[nIndex] = sFileOrDirURL; +pSelectedFiles[nIndex] = sFileOrDirURL; } return aSelectedFiles; diff --git a/fpicker/source/office/OfficeFilePicker.cxx b/fpicker/source/office/OfficeFilePicker.cxx index 3386979e4714..49a00f429fb2 100644 --- a/fpicker/source/office/OfficeFilePicker.cxx +++ b/fpicker/source/office/OfficeFilePicker.cxx @@ -773,12 +773,7 @@ Sequence< sal_Int16 > SAL_CALL SvtFilePicker::getSupportedImageFormats() { checkAlive(); -SolarMutexGuard aGuard; -Sequence< sal_Int16 > aFormats( 1 ); - -aFormats[0] = FilePreviewImageFormats::BITMAP; - -return aFormats; +return { FilePreviewImageFormats::BITMAP }; } sal_Int32 SAL_CALL SvtFilePicker::getTargetColorDepth() @@ -953,19 +948,19 @@ void SAL_CALL SvtFilePicker::initialize( const Sequence< Any >& _rArguments ) { // compatibility: one argument, type sal_Int16 , specifies the service type int index = 0; - +auto pArguments = aArguments.getArray(); if (_rArguments[0] >>= m_nServiceType) { // skip the first entry if it was the ServiceType, because it's not needed in OCommonPicker::initialize and it's not a NamedValue NamedValue emptyNamedValue; -aArguments[0] <<= emptyNamedValue; +pArguments[0] <<= emptyNamedValue; index = 1; } for ( int i = index; i < _rArguments.getLength(); i++) { NamedValue namedValue; -aArguments[i] = _rArguments[i]; +pArguments[i] = _rArguments[i]; if (aArguments[i] >>= namedValue ) { diff --git a/fpicker/source/office/RemoteFilesDialog.cxx b/fpicker/source/office/RemoteFilesDialog.cxx index 2e7ac67ead37..b7efa8071116 100644 --- a/fpicker/source/office/RemoteFilesDialog.cxx +++ b/fpicker/source/office/RemoteFilesDialog.cxx @@ -146,13 +146,15 @@ RemoteFilesDialog::~RemoteFilesDialog() if( m_bIsUpdated ) { Sequence< OUString > placesUrlsList( m_aServices.size() ); +auto placesUrlsListRange = asNonConstRange(placesUrlsList); Sequence< OUString >
[Libreoffice-commits] core.git: framework/qa framework/source
framework/qa/cppunit/dispatchtest.cxx |5 framework/source/accelerators/acceleratorconfiguration.cxx|6 framework/source/accelerators/presethandler.cxx | 12 framework/source/classes/taskcreator.cxx | 13 framework/source/dispatch/closedispatcher.cxx | 12 framework/source/dispatch/dispatchdisabler.cxx|6 framework/source/dispatch/dispatchinformationprovider.cxx |7 framework/source/dispatch/dispatchprovider.cxx|7 framework/source/dispatch/interceptionhelper.cxx |5 framework/source/dispatch/mailtodispatcher.cxx|3 framework/source/dispatch/oxt_handler.cxx |3 framework/source/dispatch/popupmenudispatcher.cxx |3 framework/source/dispatch/servicehandler.cxx |3 framework/source/dispatch/systemexec.cxx |3 framework/source/fwe/classes/actiontriggercontainer.cxx |8 framework/source/fwe/classes/addonsoptions.cxx| 394 +- framework/source/fwe/classes/rootactiontriggercontainer.cxx |9 framework/source/fwe/helper/undomanagerhelper.cxx |3 framework/source/fwe/xml/menudocumenthandler.cxx | 38 framework/source/fwe/xml/statusbardocumenthandler.cxx | 23 framework/source/fwe/xml/toolboxdocumenthandler.cxx | 31 framework/source/fwi/classes/converter.cxx|5 framework/source/fwi/classes/protocolhandlercache.cxx |4 framework/source/fwi/jobs/configaccess.cxx|3 framework/source/fwi/uielement/constitemcontainer.cxx |4 framework/source/fwi/uielement/itemcontainer.cxx |4 framework/source/fwi/uielement/rootitemcontainer.cxx |2 framework/source/helper/oframes.cxx |8 framework/source/jobs/job.cxx | 56 - framework/source/jobs/jobdata.cxx | 23 framework/source/jobs/jobdispatch.cxx |4 framework/source/layoutmanager/helpers.cxx|6 framework/source/layoutmanager/layoutmanager.cxx | 50 - framework/source/layoutmanager/toolbarlayoutmanager.cxx | 63 - framework/source/loadenv/loadenv.cxx |6 framework/source/services/dispatchhelper.cxx |5 framework/source/services/frame.cxx |4 framework/source/services/mediatypedetectionhelper.cxx|3 framework/source/services/pathsettings.cxx| 53 - framework/source/services/sessionlistener.cxx |8 framework/source/services/taskcreatorsrv.cxx |9 framework/source/uiconfiguration/imagemanagerimpl.cxx |3 framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx | 11 framework/source/uiconfiguration/uiconfigurationmanager.cxx | 11 framework/source/uielement/FixedTextToolbarController.cxx |8 framework/source/uielement/buttontoolbarcontroller.cxx|6 framework/source/uielement/comboboxtoolbarcontroller.cxx |8 framework/source/uielement/complextoolbarcontroller.cxx | 11 framework/source/uielement/dropdownboxtoolbarcontroller.cxx |8 framework/source/uielement/edittoolbarcontroller.cxx |9 framework/source/uielement/generictoolbarcontroller.cxx |5 framework/source/uielement/menubarmanager.cxx |8 framework/source/uielement/newmenucontroller.cxx | 11 framework/source/uielement/popuptoolbarcontroller.cxx |7 framework/source/uielement/recentfilesmenucontroller.cxx | 18 framework/source/uielement/spinfieldtoolbarcontroller.cxx | 14 framework/source/uielement/togglebuttontoolbarcontroller.cxx | 11 framework/source/uielement/toolbarmanager.cxx | 12 framework/source/uielement/toolbarsmenucontroller.cxx | 16 framework/source/uielement/uicommanddescription.cxx | 31 framework/source/uifactory/addonstoolbarfactory.cxx | 16 framework/source/uifactory/menubarfactory.cxx |3 framework/source/uifactory/uicontrollerfactory.cxx|5 framework/source/uifactory/uielementfactorymanager.cxx| 18 64 files changed, 568 insertions(+), 596 deletions(-) New commits: commit f662ba95361ba6b8eb49e0acd98bf28bc5f21100 Author: Mike Kaganski AuthorDate: Fri Oct 29 09:44:28 2021 +03
[Libreoffice-commits] core.git: forms/source
forms/source/component/ComboBox.cxx|2 +- forms/source/component/Grid.cxx|9 + forms/source/component/ListBox.cxx |9 +++-- forms/source/component/clickableimage.cxx | 16 +++- forms/source/component/entrylisthelper.cxx |5 +++-- forms/source/helper/formnavigation.cxx |6 +++--- forms/source/runtime/formoperations.cxx| 13 - forms/source/solar/control/navtoolbar.cxx |3 ++- forms/source/xforms/submission/replace.cxx | 11 ++- 9 files changed, 34 insertions(+), 40 deletions(-) New commits: commit bddfc920220b712c08eda96ac320a274e4bfcee6 Author: Mike Kaganski AuthorDate: Fri Oct 29 09:39:59 2021 +0300 Commit: Mike Kaganski CommitDate: Sat Oct 30 09:28:10 2021 +0200 Prepare for removal of non-const operator[] from Sequence in forms Change-Id: I2b7bd7935d7e620b9f283ec7c0548beeb97c140d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124366 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/forms/source/component/ComboBox.cxx b/forms/source/component/ComboBox.cxx index fe3260070d68..fa28816c0890 100644 --- a/forms/source/component/ComboBox.cxx +++ b/forms/source/component/ComboBox.cxx @@ -763,7 +763,7 @@ bool OComboBoxModel::commitControlValueToDbColumn( bool _bPostReset ) { sal_Int32 nOldLen = aStringItemList.getLength(); aStringItemList.realloc( nOldLen + 1 ); -aStringItemList[ nOldLen ] = sNewValue; +aStringItemList.getArray()[ nOldLen ] = sNewValue; setFastPropertyValue( PROPERTY_ID_STRINGITEMLIST, makeAny( aStringItemList ) ); setFastPropertyValue( PROPERTY_ID_TYPEDITEMLIST, makeAny( css::uno::Sequence() ) ); diff --git a/forms/source/component/Grid.cxx b/forms/source/component/Grid.cxx index b92f763d578e..67fb4cba1bbf 100644 --- a/forms/source/component/Grid.cxx +++ b/forms/source/component/Grid.cxx @@ -163,10 +163,11 @@ css::uno::Sequence OGridControlModel::getSupportedServiceNames() { css::uno::Sequence aSupported = OControlModel::getSupportedServiceNames(); aSupported.realloc(aSupported.getLength() + 4); -aSupported[aSupported.getLength()-4] = "com.sun.star.awt.UnoControlModel"; -aSupported[aSupported.getLength()-3] = FRM_SUN_COMPONENT_GRIDCONTROL; -aSupported[aSupported.getLength()-2] = FRM_COMPONENT_GRID; -aSupported[aSupported.getLength()-1] = FRM_COMPONENT_GRIDCONTROL; +auto pSupported = aSupported.getArray(); +pSupported[aSupported.getLength()-4] = "com.sun.star.awt.UnoControlModel"; +pSupported[aSupported.getLength()-3] = FRM_SUN_COMPONENT_GRIDCONTROL; +pSupported[aSupported.getLength()-2] = FRM_COMPONENT_GRID; +pSupported[aSupported.getLength()-1] = FRM_COMPONENT_GRIDCONTROL; return aSupported; } Any SAL_CALL OGridControlModel::queryAggregation( const Type& _rType ) diff --git a/forms/source/component/ListBox.cxx b/forms/source/component/ListBox.cxx index 2f95f6331f01..4e632d60a07e 100644 --- a/forms/source/component/ListBox.cxx +++ b/forms/source/component/ListBox.cxx @@ -1178,8 +1178,7 @@ namespace frm { if ( m_nNULLPos != -1 ) { -aSelectionIndicies.realloc(1); -aSelectionIndicies[0] = m_nNULLPos; +aSelectionIndicies = { m_nNULLPos }; } } else @@ -1191,8 +1190,7 @@ namespace frm ValueList::const_iterator curValuePos = ::std::find( aValues.begin(), aValues.end(), v ); if ( curValuePos != aValues.end() ) { -aSelectionIndicies.realloc( 1 ); -aSelectionIndicies[0] = curValuePos - aValues.begin(); +aSelectionIndicies = { o3tl::narrowing(curValuePos - aValues.begin()) }; } } @@ -1391,8 +1389,7 @@ namespace frm OSL_VERIFY( _rExternalValue >>= nSelectIndex ); if ( ( nSelectIndex >= 0 ) && ( nSelectIndex < static_cast(getStringItemList().size()) ) ) { -aSelectIndexes.realloc( 1 ); -aSelectIndexes[ 0 ] = static_cast< sal_Int16 >( nSelectIndex ); +aSelectIndexes = { o3tl::narrowing(nSelectIndex) }; } } break; diff --git a/forms/source/component/clickableimage.cxx b/forms/source/component/clickableimage.cxx index 8dd3489967f5..77dd6c5943b6 100644 --- a/forms/source/component/clickableimage.cxx +++ b/forms/source/component/clickableimage.cxx @@ -44,6 +44,7 @@ #include #include #include +#include #include #include #include @@ -317,15 +318,12 @@ namespace frm if ( xDisp.is() ) { -Sequence aProps(3); -aProps[0].Name = "URL"; -aProps[0].Value <<= aURL.Complete; - -aProps[1].Name = "Fr