summaryrefslogtreecommitdiffstats
path: root/comphelper
Commit message (Collapse)AuthorAgeFilesLines
* add ThreadPool::isIdle() to avoid incorrect detection of "no tasks"Luboš Luňák2020-12-013-9/+76
| | | | | | | | | | | | | | | | | Tasks that are being worked on but are not yet finished are removed from maTasks, so maTasks.empty() does not mean "idle". I fixed one case already in 2ad4e77a0f266ae6e6fccaebb1d080d2880bdac3, this one fixes joinAll() which has a similar problem and triggers https://gerrit.libreoffice.org/c/core/+/69473/3/sc/source/core/data/documen2.cxx#312 Also rename joinAll() to joinThreadsIfIdle(), as that's what it really is. Change-Id: I8129cfadb81be968575ea8718de9ae997b877a4e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106701 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com> (cherry picked from commit 583b0612696f42571ac97b66c159570ea452fe17) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106824
* handle a possible (unlikely?) deadlock in threadpool cleanupLuboš Luňák2020-12-011-0/+7
| | | | | | | | | Change-Id: I4886989816662bad50db145fd1ff1466e8a3a140 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106700 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com> (cherry picked from commit af361b464b46dcc39a1bb4ab098a6ddf6ff40a53) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106823
* replace std::min(std::max()) with std::clampNoel2020-11-161-1/+1
| | | | | | | Change-Id: I76e34e8020d98292e8ffde387542b7029f85a42d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105754 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* tdf#123936 Formatting files in module comphelper with clang-formatPhilipp Hofer2020-11-136-68/+52
| | | | | | | Change-Id: I01cf258f8fedb4d98f64d2a18735764463f1b2af Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105653 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
* New loplugin:stringviewparamStephan Bergmann2020-11-121-3/+3
| | | | | | | | | | | | | | ...to "Find functions that take rtl::O[U]String parameters that can be generalized to take std::[u16]string_view instead." (Which in turn can avoid costly O[U]String constructions, see e.g. loplugin:stringview and subView.) Some of those functions' call sites, passing plain char string literals, needed to be adapted when converting them. Change-Id: I644ab546d7a0ce9e470ab9b3196e3e60d1e812bc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105622 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* tdf#138113: Base SQL syntax colouring issue with operators "/", "-"Julien Nabet2020-11-111-0/+4
| | | | | | | Change-Id: If268d7731642a6503418ca187b4fe85a889d1d2b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105581 Reviewed-by: Lionel Mamane <lionel@mamane.lu> Tested-by: Jenkins
* loplugin:stringviewNoel2020-11-111-1/+1
| | | | | | | | | | | | | Add new methods "subView" to O(U)String to return substring views of the underlying data. Add a clang plugin to warn when replacing existing calls to copy() would be better to use subView(). Change-Id: I03a5732431ce60808946f2ce2c923b22845689ca Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105420 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* tdf#42949 Fix new IWYU warnings in directories c*Gabor Kelemen2020-11-0613-14/+15
| | | | | | | | | | Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Iac1e7802dbe1efa01c2befdd10406231788d4fc1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105315 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
* remove pimpl from PropertySetHelperNoel Grandin2020-11-041-48/+30
| | | | | | | Change-Id: I20e72b5927d64a69aacd3d4de117a7736d53eea4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105275 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* remove pimpl from NamedValueCollectionNoel Grandin2020-11-041-81/+27
| | | | | | | Change-Id: I134e5fd78a3861e0067b749d93643960205daf69 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105277 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* remove pimpl in PropertyBagNoel Grandin2020-11-041-18/+10
| | | | | | | Change-Id: Ibf34c0d9a3090c190a63f63ba9bd661263aebae6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105276 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* TNumberedItemHash NumberedCollection::m_lComponents is indexed on pointers...Stephan Bergmann2020-10-301-2/+1
| | | | | | | | | | ...reinterpret_cast'ed to sal_IntPtr, so consistently use sal_IntPtr throughout here Change-Id: If0085c2ac7e0e2c755ec034766095baa11a1b08c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105071 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* Extend loplugin:elidestringvar to OStringStephan Bergmann2020-10-281-8/+4
| | | | | | | | | | | | | | | | | | (In VisitVarDecl, filtering out AbstractConditionalOperator avoids an unhelpful > ~/lo/core/vcl/source/pdf/XmpMetadata.cxx:63:32: error: replace single use of literal 'rtl::OString' variable with a literal [loplugin:elidestringvar] > aXmlWriter.content(sPdfConformance); > ^~~~~~~~~~~~~~~ > ~/lo/core/vcl/source/pdf/XmpMetadata.cxx:52:21: note: literal 'rtl::OString' variable defined here [loplugin:elidestringvar] > OString sPdfConformance = (mnPDF_A == 1) ? "A" : "B"; > ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ) Change-Id: I7d0410f04827d79b4b526752917c37d33cad2671 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104911 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* std::set->o3tl::sorted_vector in OPropertyArrayAggregationHelperNoel Grandin2020-10-281-3/+2
| | | | | | | Change-Id: Iec4935af8946e453b39221dcb982059c806f62a4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104902 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* use tools::Long in comphelper..cuiNoel2020-10-212-3/+4
| | | | | | | Change-Id: I65167999c6049038f8f5d530a0c5cb0552ab0e06 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104609 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* tdf#134987 convert DOCX to ODT: fix lost chartsBalazs Varga2020-10-131-0/+8
| | | | | | | | | | | | | | | | | | | | Embedded charts of DOCX documents were lost or replaced by images during conversion to native ODT format, resulted by bad handling of XEmbedPersist objects in EmbeddedObjectContainer. Note: Add missing loext:external-data to ODF 1.3 schema definition to fix ODF validation error in gerrit. See commit 2054af83fefb955e20de2b40178a11726525057e (fdo#72520 : Added property to store external data path in chart) and commit a49a9dab3168c03a539adc131f2ade03236edb69 (fix one more ODF validation error). Change-Id: I9edff9af3a79370ea447ffc6078da3520d0c6f63 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104104 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
* loplugin:const* make some params and methods constNoel2020-10-061-2/+2
| | | | | | | Change-Id: If7fbb25037343e18081a8ee7064840d75e9a45a7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104010 Tested-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* fix possible >= 0 warningLuboš Luňák2020-10-061-1/+1
| | | | | | | Change-Id: I7b5595265d00a33e933a1768d8c80a7ffd25c8a6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103997 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
* fix allocating thread pool workersLuboš Luňák2020-10-053-2/+73
| | | | | | | | | | | | | Tasks are removed from the queue before a worker starts working on it, which means that maTasks.size() is not the number of tasks to do, because the worked on tasks are not included there. This means the code could spawn only a smaller number of workers than were needed (and than CPU cores that are available). Change-Id: Ic6e6a79316cf48d82f2b80be7ad477b723b2c4e5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103955 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
* loplugin:reducevarscope in comphelper,connectivityNoel2020-10-012-3/+2
| | | | | | | Change-Id: Ia70d4963fb892120cc8f79597b46a8fe67b540a9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103762 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* improve some exception messagesNoel Grandin2020-09-274-5/+5
| | | | | | | Change-Id: Ifc5d940fbf77ae13071c299fb6168bdc55dc5c95 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103493 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* Simplify some OUString constructions with universal character namesStephan Bergmann2020-09-231-2/+1
| | | | | | | Change-Id: I16dcaec29de725b4308f2ef3262673e9b9cab1f4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103270 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* OUStringLiteral/OStringLiteral coverity PARSE_ERROR workaroundCaolán McNamara2020-09-224-22/+22
| | | | | | | | | | | | | | | | do more like commit 121771e37f7e2de41cd5643475861062bf25627b Date: Mon Sep 21 09:17:54 2020 +0200 Make some OUStringLiteral vars constexpr cause coverity can live with that Change-Id: I9efd7f848289c4865997a44c6780373068422227 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103147 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
* Turn OUStringLiteral into a consteval'ed, static-refcound rtl_uStringStephan Bergmann2020-09-161-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ...from which an OUString can cheaply be instantiated. This is the OUString equivalent of 4b9e440c51be3e40326bc90c33ae69885bfb51e4 "Turn OStringLiteral into a consteval'ed, static-refcound rtl_String". Most remarks about that commit apply here too (this commit is just substantially bigger and a bit more complicated because there were so much more uses of OUStringLiteral than of OStringLiteral): The one downside is that OUStringLiteral now needs to be a template abstracting over the string length. But any uses for which that is a problem (e.g., as the element type of a container that would no longer be homogeneous, or in the signature of a function that shall not be turned into a template for one reason or another) can be replaced with std::u16string_view, without loss of efficiency compared to the original OUStringLiteral, and without loss of expressivity. The new OUStringLiteral ctor code would probably not be very efficient if it were ever executed at runtime, but it is intended to be only executed at compile time. Where available, C++20 "consteval" is used to statically ensure that. The intended use of the new OUStringLiteral is in all cases where an object that shall itself not be an OUString (e.g., because it shall be a global static variable for which the OUString ctor/dtor would be detrimental at library load/unload) must be converted to an OUString instance in at least one place. Other string literal abstractions could use std::u16string_view (or just plain char16_t const[N]), but interestingly OUStringLiteral might be more efficient than constexpr std::u16string_view even for such cases, as it should not need any relocations at library load time. For now, no existing uses of OUStringLiteral have been changed to some other abstraction (unless technically necessary as discussed above), and no additional places that would benefit from OUStringLiteral have been changed to use it. Global constexpr OUStringLiteral variables defined in an included file would be somewhat suboptimal, as each translation unit that uses them would create its own, unshared instance. The envisioned solution is to turn them into static data members of some class (and there may be a loplugin coming to find and fix affected places). Another approach that has been taken here in a few cases where such variables were only used in one .cxx anyway is to move their definitions from the .hxx into that one .cxx (in turn causing some files to become empty and get removed completely)---which also silenced some GCC -Werror=unused-variable if a variable from a .hxx was not used in some .cxx including it. To keep individual commits reasonably manageable, some consumers of OUStringLiteral in rtl/ustrbuf.hxx and rtl/ustring.hxx are left in a somewhat odd state for now, where they don't take advantage of OUStringLiteral's equivalence to rtl_uString, but just keep extracting its contents and copy it elsewhere. In follow-up commits, those consumers should be changed appropriately, making them treat OUStringLiteral like an rtl_uString or dropping the OUStringLiteral overload in favor of an existing (and cheap to use now) OUString overload, etc. In a similar vein, comparison operators between OUString and std::u16string_view have been added to the existing plethora of comparison operator overloads. It would be nice to eventually consolidate them, esp. with the overloads taking OUStringLiteral and/or char16_t const[N] string literals, but that appears tricky to get right without introducing new ambiguities. Also, a handful of places across the code base use comparisons between OUString and OUStringNumber, which are now ambiguous (converting the OUStringNumber to either OUString or std::u16string_view). For simplicity, those few places have manually been fixed for now by adding explicit conversion to std::u16string_view. Also some compilerplugins code needed to be adapted, and some of the compilerplugins/test cases have become irrelevant (and have been removed), as the tested code would no longer compile in the first place. sal/qa/rtl/strings/test_oustring_concat.cxx documents a workaround for GCC bug <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96878> "Failed class template argument deduction in unevaluated, parenthesized context". That place, as well as uses of OUStringLiteral in extensions/source/abpilot/fieldmappingimpl.cxx and i18npool/source/localedata/localedata.cxx, which have been replaced with OUString::Concat (and which is arguably a better choice, anyway), also caused failures with at least Clang 5.0.2 (but would not have caused failures with at least recent Clang 12 trunk, so appear to be bugs in Clang that have meanwhile been fixed). Change-Id: I34174462a28f2000cfeb2d219ffd533a767920b8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102222 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* small optimisationNoel Grandin2020-09-111-4/+60
| | | | | | | | | | avoid allocating predicate on heap, which is expensive when walking over large numbers of styles nodes Change-Id: Ida4369b77fb74f3af1258a97b0b99e3a78413833 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102437 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* tdf#124176 Use #pragma once in comphelperGeorge Bateman2020-09-044-16/+4
| | | | | | | | | | This commit was carried out by a Python script, source of which is at https://bugs.documentfoundation.org/show_bug.cgi?id=124176#c97. Change-Id: I72229dc1ef743f0394f778aec7c49c11fe7e5176 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100183 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
* Fix typo in codeAndrea Gelmini2020-08-311-2/+2
| | | | | | It passed "make check on Linux" Change-Id: I53b40e36c6b1c0aa115044208b5a372fb101347b
* Simply use OUString aPassword as-isStephan Bergmann2020-08-281-1/+1
| | | | | | | | | | | ...instead of creating a copy via the OUString(sal_Unicode const *) ctor. (This was introduced with dd198398b6e5c84ab1255a90ef96e6445b66a64f, but for no obvious reason.) Change-Id: I9b46b3b1bb402c11810a4d3e68592cfe6fd8034c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101568 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* Change OUStringLiteral from char[] to char16_t[]Stephan Bergmann2020-08-286-25/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a prerequisite for making conversion from OUStringLiteral to OUString more efficient at least for C++20 (by replacing its internals with a constexpr- generated sal_uString-compatible layout with a SAL_STRING_STATIC_FLAG refCount, conditionally for C++20 for now). For a configure-wise bare-bones build on Linux, size reported by `du -bs instdir` grew by 118792 bytes from 1155636636 to 1155755428. In most places just a u"..." string literal prefix had to be added. In some places char const a[] = "..."; variables have been changed to char16_t, and a few places required even further changes to code (which prompted the addition of include/o3tl/string_view.hxx helper function o3tl::equalsIgnoreAsciiCase and the additional OUString::createFromAscii overload). For all uses of macros expanding to string literals, the relevant uses have been rewritten as u"" MACRO instead of changing the macro definitions. It should be possible to change at least some of those macro definitions (and drop the u"" from their call sites) in follow-up commits. Change-Id: Iec4ef1a057d412d22443312d40c6a8a290dc6144 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101483 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* [API CHANGE] Drop OSL_THIS_FUNC, directly use C++11 __func__Stephan Bergmann2020-08-262-2/+2
| | | | | | | | | | | It had been documented as "the macro OSL_THIS_FUNC is intended to be an office internal macro for now", so take the liberty of removing it, even if technically that can be considered an incompatible API change. Change-Id: I7580a932e1da54845934378a650e894f3f3a9062 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101406 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* NullToPointer ValueDependentIsNotNull GNUNull -> nullptr [loplugin:nullptr]Caolán McNamara2020-08-241-1/+1
| | | | | | | Change-Id: I93efe23af18c622123ddc3feb41a43a485ee2722 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101285 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
* loplugin:simplifybool moreNoel Grandin2020-08-141-2/+2
| | | | | | | | | | | look for expressions like !(a && !b) which can be expanded out Change-Id: I72515a9638762b050f9a258c08da39ebfa2ef8e7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100579 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* loplugin:stringstatic also look for local staticsNoel Grandin2020-08-132-20/+20
| | | | | | | | | | Add some API to O*StringLiteral, to make it easier to use in some places that were using O*String Change-Id: I1fb93bd47ac2065c9220d509aad3f4320326d99e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100270 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* SvTreeListBox can move into toolkit headers nowCaolán McNamara2020-08-121-3/+1
| | | | | | | Change-Id: I6b3b6ef1530a192f4b6bf87aa9688687063683ea Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100591 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
* loplugin:unusedmethodsNoel Grandin2020-07-312-60/+0
| | | | | | | Change-Id: I0d888b565b0b53b318b790926667d7ba49504411 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99854 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* loplugin:unusedmethodsNoel Grandin2020-07-301-13/+0
| | | | | | | | | and tweak the plugin a little to speed it up Change-Id: Ia59456232602184c4f1b5d1d75ad94a9a2e2d0be Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99799 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* svx: GalleryObjectCollection shared class and related refactoring workAditya2020-07-301-0/+48
| | | | | | | | | | | | | | Add GalleryObjectCollection, a shared class primarily owned by GalleryTheme which contains object list to be used by GalleryTheme and GalleryBinaryEngine. Refactor ImplCreateUniqueURL, InsertGraphic() Implement comphelper::GraphicMimeTypeHelper::GetExtensionForConvertDataFormat() Refactor Actualize(), implement updateSvDrawObject(), updateTheme() Move ImplCreateSvDrawStorage into constructor instead of calling in directly. Change-Id: I6a8c552268628b4e192f45112ac9e8789c6e1609 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99035 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
* loplugin:unusedmethodsNoel Grandin2020-07-251-32/+0
| | | | | | | Change-Id: I3a35c988b1c55b16958172ed5ef4e2d5cb410e55 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99413 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* tdf#81522 comphelper: just ignore disposed obj on saveJustin Luth2020-07-221-66/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | Even if xObj.is(), it might be disposed, and then getCurrentState() will raise an exception, resulting in an ERRCODE_IO_GENERAL, and failing to save the entire document. Although it might not seem good to just ignore an error on save, the general attitude in that function already leans that way. In fact, the other ::StoreChildren() wraps the entire for-loop in a try-catch. Also, in this function a bad xPersist also breaks out of the loop and returns a false. So wrapping the entire xObj in an "ignore if errors" try-catch seems reasonable to me in this instance. The alternative is not to allow the user to save at all, which is much worse, especially since there is nothing he can do to fix the problem. Change-Id: I0372245563735ae7ac7976bf7ce6060e57a5eb87 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99129 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Justin Luth <justin_luth@sil.org>
* loplugin:unusedmethodsNoel Grandin2020-07-214-105/+1
| | | | | | | Change-Id: I3520c2e97bb5b1611dcce77ca9f8393b29e75a1f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99110 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* loplugin:unusedmethodsNoel Grandin2020-07-162-20/+0
| | | | | | | Change-Id: Ibc1ec64cba8eb083aaff28848a42337cc597ea19 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98857 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* comphelper: don't hardcode hash sizes in Hash::getLength()Miklos Vajna2020-07-151-4/+4
| | | | | | | | | Instead move the constants from filter to comphelper and reuse them. Change-Id: Ib7061e9028ccf6067b4e86f50145c1472c2b01d4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98785 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
* update pchesCaolán McNamara2020-07-121-1/+2
| | | | | | | Change-Id: I75602277a5a26b012a12f2c4f4b7ff5bb663b0b9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98474 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
* replace usage of blacklist with excludelist for IWYUThorsten Behrens2020-07-101-1/+1
| | | | | | | | | | Background and motivation: https://tools.ietf.org/html/draft-knodel-terminology-02 Change-Id: I2f22d455d2a936a85750eaab1fda215ebb6d9d48 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98182 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
* replace usage of whitelist with allowlistThorsten Behrens2020-07-101-11/+11
| | | | | | | | | | | | Background and motivation: https://tools.ietf.org/html/draft-knodel-terminology-02 [API CHANGE] officecfg::Office::Common::Misc::OpenCLWhiteList -> OpenCLAllowList Change-Id: I65636b19b13e4af1e4851f70e78053f3443d6bb1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98181 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
* comphelper: create instances with uno constructorsNoel Grandin2020-07-055-126/+11
| | | | | | | | | See tdf#74608 for motivation Change-Id: Ib7aa69cdf62992cea38a60aac9169c2f1779c1cc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98094 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* Upcoming improved loplugin:staticanonymous -> redundantstatic: comphelperStephan Bergmann2020-06-308-25/+25
| | | | | | | Change-Id: I222ea673a44528cb04847a912cd8da971bb1be3d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/97542 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* use more std::container::insert instead of std::copyNoel Grandin2020-06-241-10/+2
| | | | | | | | | | which is both more compact code, and more efficient, since the insert method can do smarter resizing Change-Id: I17f226660f87cdf002edccc29b4af8fd59a25f91 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96948 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* loplugin:simplifypointertobool improveNoel Grandin2020-06-031-4/+4
| | | | | | | | | | | | | | | | to look for the x.get() != null pattern, which can be simplified to x I'll do the x.get() == nullptr pattern in a separate patch, to reduce the chances of a mistake Change-Id: I45e0d178e75359857cdf50d712039cb526016555 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95354 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* Upcoming loplugin:elidestringvar: comphelperStephan Bergmann2020-06-036-31/+15
| | | | | | | Change-Id: Id388af90ca2c3dff435a1a6261e3de0c3c0dbdbd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95376 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>