summaryrefslogtreecommitdiff
path: root/comphelper
AgeCommit message (Collapse)Author
2015-07-10add a SAL_RAND_REPEATABLE for repeatable random numsCaolán McNamara
merge the formula and comphelper ones together Change-Id: I2e7e2cdb176afc6982e384fa1e007da5b914e6f0
2015-07-04Fix typosAndrea Gelmini
Change-Id: I75b4ad61785bf0ba1cb07735d938c0977356b8cc Reviewed-on: https://gerrit.libreoffice.org/16705 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <s.mehrbrodt@gmail.com>
2015-06-29coverity#1308587 Uncaught exceptionCaolán McNamara
Change-Id: I45e699ebf255e7d933a3b5d77717dcd7583d8383
2015-06-29Revert "return and use std::vector from OInterfaceContainerHelper"Noel Grandin
This reverts commit e57314f61f67b093510c5a8a8f34a62126ba8734.
2015-06-29return and use std::vector from OInterfaceContainerHelperNoel Grandin
since most of the time we don’t need a heavyweight uno::Sequence. Adds a new method getElementsAsVector(). Change-Id: I9e72bef0c0c723ffd0dd7d4152db5baec6784a7a Reviewed-on: https://gerrit.libreoffice.org/15747 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-06-24Get rid of comphelper::string::is*Ascii functionsStephan Bergmann
Change-Id: I99912112e5b009d7a143f9816d757cdf6ebb1783
2015-06-24Simplify comphelper::string::isdigitAsciiString definitionsStephan Bergmann
Change-Id: I26c889e51287a239ef92a798a6899266837064d9
2015-06-23Drop duplicate #includesTakeshi Abe
Change-Id: I4db77ea1de42676d9d2df70db3f2e1665a3fd983 Reviewed-on: https://gerrit.libreoffice.org/16419 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2015-06-22Fix typosAndrea Gelmini
Change-Id: I60ed5eb658d50cbc7dc572facb5463b7527b4d9b Reviewed-on: https://gerrit.libreoffice.org/16408 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2015-06-21Fix typosAndrea Gelmini
Change-Id: I2297bf392a405f02be2450f4624f1c9fc0b512ce Reviewed-on: https://gerrit.libreoffice.org/16373 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-06-18Add SwTiledRenderingTest::testGetTextSelection() testcase.Miklos Vajna
Fails without commit 193b907b2bc49b9e48cfab2583e81a24aaa2e666 (SwXTextDocument::getTextSelection: fix missing editeng forward, 2015-06-18). Change-Id: I5fdab128471c12901f930b6b4ab4e2304dd3fe64 Reviewed-on: https://gerrit.libreoffice.org/16359 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2015-06-17Replace boost::scoped_array<T> with std::unique_ptr<T[]>Takeshi Abe
This may reduce some degree of dependency on boost. Done by running a script like: git grep -l '#include *.boost/scoped_array.hpp.' \ | xargs sed -i -e 's@#include *.boost/scoped_array.hpp.@#include <memory>@' git grep -l '\(boost::\)\?scoped_array<\([^<>]*\)>' \ | xargs sed -i -e 's/\(boost::\)\?scoped_array<\([^<>]*\)>/std::unique_ptr<\2[]>/' ... and then killing duplicate or unnecessary includes, while changing manually m_xOutlineStylesCandidates in xmloff/source/text/txtimp.cxx, extensions/source/ole/unoconversionutilities.hxx, and extensions/source/ole/oleobjw.cxx. Change-Id: I3955ed3ad99b94499a7bd0e6e3a09078771f9bfd Reviewed-on: https://gerrit.libreoffice.org/16289 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-06-16Fix typosAndrea Gelmini
Change-Id: Id8c7cf460cba5af89891c470e1aaa61b227d356e Reviewed-on: https://gerrit.libreoffice.org/16310 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2015-06-14Fix insertion and deletion in IndexedPropertyValuesContainerMatthew J. Francis
The cases for iterating to an element from the end (used for elements in the second half of the underlying array) had an off by one error causing the wrong elements to be inserted/removed Change-Id: Idcbf158cc31afaf02fce3f1975509edf6239d3ae Reviewed-on: https://gerrit.libreoffice.org/16073 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com>
2015-06-08cppcheck: noExplicitConstructorCaolán McNamara
Change-Id: Ie2ae923ad4c1a66e779711de6ff05328ef144dac
2015-06-08loplugin:cstylecast: deal with remaining pointer castsStephan Bergmann
Change-Id: I1ceb4359188b61e15a31750a496021c4394e1a3f
2015-06-04uno::Sequence provides now begin and endNoel Grandin
use begin() and end() when calling std::copy on an uno::Sequence Inspired by commit b34b648fc3262c5d9aa295f621e8fe9c97d4c6b2 "uno::Sequence provides now begin and end" Change-Id: I08e8c3fd6144e77b95a26f85bc0daf6a9edeeb0b Reviewed-on: https://gerrit.libreoffice.org/16057 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-06-02loplugin:cstylecast: deal with those that are (technically) const_castStephan Bergmann
Change-Id: Idbd718042e13e9c107c1a349c113656bf9468614
2015-05-25callcatcher: update unused codeCaolán McNamara
Change-Id: I735264eb32ebdd165d23a4717f0329f666b8b140
2015-05-24callcatcher: update unused codeCaolán McNamara
Change-Id: I1f2a94cdcd4329af68d946ff0a74ddec4ac1c590
2015-05-18comphelper::PropertySetInfo: convert legacy assertionMichael Stahl
Change-Id: I23dbe1b3cf6cc611efe8a39c49f4e5b47bf25a49
2015-05-18comphelper::PropertySetInfo remove unused parameterMichael Stahl
Change-Id: I960b31befe749860e926e5bb567c0b8d0f87867a
2015-05-15tdf#62475: partial handmade fixesAndrea Gelmini
Change-Id: Ib9af202c43b916b9af4b4e18db35d470a8692fe4 Reviewed-on: https://gerrit.libreoffice.org/15712 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2015-05-06Add support for progress bar callbacks to LibreOfficeKit clientsTor Lillqvist
The comphelper::LibreOfficeKit bits. Also will need additions to the libsofficeapp bits in desktop and then to the StatusIndicator implementation in framework. Change-Id: I15c2505bbf6439c07d1956685d0a6d2a22aefc58
2015-05-06sal/log.hxx is what was missingStephan Bergmann
Change-Id: I11aa264391aa4fcd90d171b9a6d93ed8e430b6cc
2015-05-06If using std::random_device fails, fall back to just time(nullptr)Tor Lillqvist
For instance, if using LibreOfficeKit in a chroot jail, there might not be a /dev/urandom, which causes the std::random_device ctor to throw a std::runtime_error exception, at least in the libstdc++ I have. Change-Id: Icc91a4ddf92ce66c66b6ffb8b4d1a02ab5f29ee9
2015-05-05seed mt19937 with random dataNorbert Thiebaud
time(NULL) is a poor seed. It is quite predictable and multiple instance starting in the same second will get the same seed and therefore the same pseudo random number sequence Use std::random_device, witch is meant to provide 'true' random data.. mix time(NULL) just in case the std implementation is crappy. PS: sadly std::random_device.entropy() cannot be relied on as clang and gcc are known to return 0 despite their random_device being non-deterministic, hence the prophylactic systematic mixing with time(null) Change-Id: I44dab9970f8f0388dc1c99e9816d49d1afbecf18 Reviewed-on: https://gerrit.libreoffice.org/15591 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2015-04-22comphelper::dispatchCommand: allow passing command argumentsMiklos Vajna
Change-Id: I6464c5d1a46fadac2510700101f3c8cc29dd7995
2015-04-22Various #include <sal/log.hxx> fixupsStephan Bergmann
rtl/string.hxx and rtl/ustring.hxx both unnecessarily #include <sal/log.hxx> (and don't make use of it themselves), but many other files happen to depend on it. Cleaned up some, but something like grep -FwL sal/log.hxx $(git grep -Elw \ 'SAL_INFO|SAL_INFO_IF|SAL_WARN|SAL_WARN_IF') -- \*.cxx) shows lots more files that potentially need fixing before the include can be removed from rtl/string.hxx and rtl/ustring.hxx. Change-Id: Ibf033363e83d37851776f392dc0b077381cd8b90
2015-04-21No more need for PartialWeakComponentImplHelper hereStephan Bergmann
...since 70626249cd247d9acdad417b8eaf252bae22c059 "API CHANGE a11y unpublishing and add/removeListener rename." Change-Id: I89d81326d97712abcac94c3436a13905954c55cf
2015-04-21Get rid of trivial comphelper::in-/decrement wrappersStephan Bergmann
Change-Id: Id3a12ef9d56c30719f483e610c8a8b08caf05def
2015-04-15remove unnecessary use of void in function declarationsNoel Grandin
ie. void f(void); becomes void f(); I used the following command to make the changes: git grep -lP '\(\s*void\s*\)' -- *.cxx \ | xargs perl -pi -w -e 's/(\w+)\s*\(\s*void\s*\)/$1\(\)/g;' and ran it for both .cxx and .hxx files. Change-Id: I314a1b56e9c14d10726e32841736b0ad5eef8ddd
2015-04-02Move osl::LibreOfficeKit stuff to comphelper for nowTor Lillqvist
Let's see where it actually will be needed. Sal is a "picky" place for new API, even inside LIBO_INTERNAL_ONLY. Change-Id: Ia0c5ee8cfc6ee526c5ad34d2f8aab0b14b5f805b
2015-04-02loplugin:staticmethodsNoel Grandin
Change-Id: I1f6c6d13697aa397067478d6b07429120106e6bd
2015-04-01Add isReadOnly() support to simplified configuration accessStephan Bergmann
[API CHANGE]: extends the css.configuration.XReadWriteAccess in an incompatible way, but that is unpublished, has been commented as "still unpublished and unstable," and was specifically introduced for internal use by the simplified configuration access, so should not affect 3rd party code. Change-Id: I99ce045f5bd8c598e689d46fb0d3626dfaa6d0a0
2015-04-01Replace remaining getCppuType et al with cppu::UnoTypeStephan Bergmann
Change-Id: I8dd0e5c8837fe1615aa9d5f546c2fd1c0985f044
2015-03-31V597: introduce a rtl_secureZeroMemoryCaolán McNamara
Change-Id: Id28046eb318cd3b2ed0b813fd266617547cf6ee2
2015-03-31Reduce to static_cast any reinterpret_cast from void pointersStephan Bergmann
Change-Id: I062024d4768374e319b6c67ed8c7abcc89f9d552
2015-03-28Clean up C-style casts from pointers to voidStephan Bergmann
Change-Id: Icdb619101a992a740c71545e669e138cb5dc63a6
2015-03-27new clang plugin: staticmethodsNoel Grandin
Genius suggestion from Tor Lillqvist, write a clang plugin that finds methods that can be static. Change-Id: Ie6684cc95d088e8750b300a028b49f763da00345
2015-03-19fix windows build and sal_Bool->boolCaolán McNamara
Change-Id: If88a5b1171ef0b586861dd071820bc993c4cf06e
2015-03-19fix windows buildNoel Grandin
after my commit 48bb2913a7459edb17a5f62c2f6e6fbc4f1051e2 "convert SFX_FILTER_ constants to enum class" Change-Id: Ieaf524e076f5ecfe16b312a310cd6f5cb8bd637d
2015-03-19convert SFX_FILTER_ constants to enum classNoel Grandin
Change-Id: I7e53cfc90cefd9da7d6ecd795b09214bd44b1613
2015-03-16Factor out the .uno: command dispatching to a separate function / file.Jan Holesovsky
Change-Id: I8486933d57d42992e66be7f17443320cfc2ad629
2015-03-10tdf#89592 Using initializer_lists to populate Sequence<PropertyValue>Swachhand Lokhande
Change-Id: Idef9dd55eb1719eaf592bc4a86440cbd5aa4fb32 Reviewed-on: https://gerrit.libreoffice.org/14781 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Miklos Vajna <vmiklos@collabora.co.uk>
2015-03-09V801: Decreased performanceCaolán McNamara
Change-Id: Id8cd45d2844c121f63684734ab3546c24a1aab32
2015-02-27comphelper: compare implemented as subtractionMichael Stahl
Change-Id: Ic7abd7dd588339e06b6764659829f35b4ea87adb
2015-02-23remove unnecessary parenthesis in return statementsNoel Grandin
found with $ git grep -lP 'return\s*\(\s*\w+\s*\)\s*;' Change-Id: Ic51606877a9edcadeb647c5bf17bc928b69ab60e
2015-02-16boost::noncopyable->'= delete'Caolán McNamara
Change-Id: If0f898a1e912fcd2095d8ba88b2b8046596e16ea
2015-02-16boost::foo_ptr->std::foo_ptrCaolán McNamara
Change-Id: I9219619b538b6530a89f5932ac51eb3b62eb396a