2406 Commits

Author SHA1 Message Date
Daniel Robertson
6900bf41e2 o3tl/cow_wrapper: remove boost dependency
Remove boost dependencies from ::o3tl::cow_wrapper, and add
the necessary includes to files including checked_delete and
noncopyable that do not already include the necessary files.

Change-Id: Iedae4232002792724226829a5d5cf9d16ffd0686
Reviewed-on: https://gerrit.libreoffice.org/18125
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2015-08-29 22:51:36 +00:00
Stephan Bergmann
fe6c124da7 Remove demonstrated-useless comphelper::compare
Change-Id: Ifd1b38afb963255b76f0d821eb46e4c6a972128a
2015-08-21 10:34:04 +02:00
Stephan Bergmann
5ff8f80a27 Demonstrate comphelper::compare is useless
Change-Id: I03de2d02f4814bf3425f7278ec91ed1e3b4ce1a0
2015-08-21 10:34:04 +02:00
Stephan Bergmann
63de6ba249 There is no css::uno::Sequence<sal_uInt8> in UNO
Change-Id: Ibf5095fea20314180a4e002295c89f570d66d45f
2015-08-19 14:48:28 +02:00
Stephan Bergmann
39ce314c12 comphelper::isA(Type... -> Type == cppu::UnoType...
Change-Id: I1bfb99b1715a907a03af5a30df6c7a41f91fd2fb
2015-08-19 14:48:27 +02:00
Stephan Bergmann
d21260cdb6 Remove two silly typedefs
Change-Id: Ia7de1cebf6009e770ca1b96bab6d5e121573ccc1
2015-08-19 13:34:43 +02:00
Stephan Bergmann
5da0dce19c Consolidate isFileUrl checks
Change-Id: I1b74fdfaa09c4d0d6c296253958e83e78b546a9a
2015-08-19 12:24:37 +02:00
Noel Grandin
4f87e9da41 loplugin: defaultparams
Change-Id: I29ef505ee77965df33677f8051ec39398ef0c74e
2015-08-11 09:48:17 +02:00
Caolán McNamara
eab0ae6a51 cppcheck: nullPointerRedundantCheck
Change-Id: I5cac2cdb383de5448383434a910eb97061c29071
2015-08-10 12:13:30 +01:00
Noel Grandin
3ff2e30ff6 cui,connectivity: inline some use-once typedefs
Change-Id: I1b043031014a3e823cd614966984a2ac2be1ac71
2015-08-04 08:55:56 +02:00
Michael Stahl
819fd24487 comphelper: replace boost::function with std::function
Change-Id: I042c97d8472c3afceffba36808687f382571e6c2
2015-07-31 21:24:24 +02:00
Michael Stahl
18110ca3bd comphelper, desktop: fix MSVC mergedlib link failure
Duplicate symbols are easily avoided by removing duplicate code.

Change-Id: I9b598a44156d6ff71b0691e69ab8163b15e2e26f
2015-07-27 21:22:07 +02:00
Noel Grandin
d74436fb86 com::sun::star->css in comphelper
Change-Id: I4aa0b2d15f2a06cbbbf63a363f403ca6435ffbcd
Reviewed-on: https://gerrit.libreoffice.org/17365
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-07-27 11:01:04 +00:00
Marek Doležel
11f24bc2f0 tdf#92130 fix DoEvents to be recognized as keyword
Change-Id: I24868acec66a72abbb52b8026ed3a092dbd97632
Reviewed-on: https://gerrit.libreoffice.org/17347
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2015-07-25 23:44:03 +00:00
Caolán McNamara
b12c835d4d coverity#1312139 random byte is deliberate
Change-Id: Iff546476256c87813b01a7db2c8331f926b7e3bd
2015-07-23 12:14:39 +01:00
Giuseppe Castagno
bc9a8ddbb7 tdf#82744: fix WebDAV lock/unlock behaviour - part 2
Changes done to the code in framework, comphelper and unotools,
in no particular order

- add an interaction handler dedicated to WebDAV
The stock interaction handler can be missing depending on the need of
the framework performing its tasks, so a dedicated handler is
provided, this one is always present.

- force opening of a WebDAV file.
A WebDAV file sould be open r/o even if explicitly requested to open
as r/w.
This is a limitation of current WebDAV implementation, not of the
standard.
This change is needed in order to reopen correctly a file as
requested by a 'Edit Mode' GUI command.

Change-Id: I5368fa2c0511f1630e6d6139c6a986d33aa19082
Reviewed-on: https://gerrit.libreoffice.org/17182
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2015-07-22 16:17:04 +00:00
Takeshi Abe
a890a7696f tdf#88206 replace cppu::WeakImplHelper* etc.
with the variadic variants, for comphelper.
This also includes extra changes in other modules
required accordingly.

Change-Id: Id1537f46f1c90f760a0d8987a6dafa0e1da03b8f
Reviewed-on: https://gerrit.libreoffice.org/16929
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-07-20 07:06:22 +00:00
Andrea Gelmini
9f27e5b0e0 Fix typos
Change-Id: I52cbaad71560d73f5e24f3de3cd62b00d678dd6c
Reviewed-on: https://gerrit.libreoffice.org/17187
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2015-07-19 19:45:07 +00:00
Stephan Bergmann
e363123a24 loplugin:simplifybool
Change-Id: I928325376b97ddd312af0f0a71187f29be607c6a
2015-07-16 14:00:16 +02:00
Caolán McNamara
5b2f823194 add a SAL_RAND_REPEATABLE for repeatable random nums
merge the formula and comphelper ones together

Change-Id: I2e7e2cdb176afc6982e384fa1e007da5b914e6f0
2015-07-10 08:58:20 +01:00
Andrea Gelmini
ffa8892c5a Fix typos
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-07-04 10:23:17 +00:00
Caolán McNamara
10a7c828be coverity#1308587 Uncaught exception
Change-Id: I45e699ebf255e7d933a3b5d77717dcd7583d8383
2015-06-29 12:58:03 +01:00
Noel Grandin
b55166d266 Revert "return and use std::vector from OInterfaceContainerHelper"
This reverts commit e57314f61f67b093510c5a8a8f34a62126ba8734.
2015-06-29 10:11:53 +02:00
Noel Grandin
e57314f61f return and use std::vector from OInterfaceContainerHelper
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-29 07:25:22 +00:00
Stephan Bergmann
6390d2c52b Get rid of comphelper::string::is*Ascii functions
Change-Id: I99912112e5b009d7a143f9816d757cdf6ebb1783
2015-06-24 15:27:28 +02:00
Stephan Bergmann
3fb56b38c4 Simplify comphelper::string::isdigitAsciiString definitions
Change-Id: I26c889e51287a239ef92a798a6899266837064d9
2015-06-24 15:27:27 +02:00
Takeshi Abe
0655f98565 Drop duplicate #includes
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-23 10:40:00 +00:00
Andrea Gelmini
aade27554d Fix typos
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-22 12:36:21 +00:00
Andrea Gelmini
9ed033917b Fix typos
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-21 19:56:13 +00:00
Miklos Vajna
bcace9acaf Add SwTiledRenderingTest::testGetTextSelection() testcase.
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-18 16:34:16 +00:00
Takeshi Abe
0980095619 Replace boost::scoped_array<T> with std::unique_ptr<T[]>
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-17 15:50:45 +00:00
Andrea Gelmini
3fa7b0b70f Fix typos
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-16 11:25:13 +00:00
Matthew J. Francis
46e12364dc Fix insertion and deletion in IndexedPropertyValuesContainer
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-14 15:03:58 +00:00
Caolán McNamara
a941df0f89 cppcheck: noExplicitConstructor
Change-Id: Ie2ae923ad4c1a66e779711de6ff05328ef144dac
2015-06-08 17:35:00 +01:00
Stephan Bergmann
66a0a3726a loplugin:cstylecast: deal with remaining pointer casts
Change-Id: I1ceb4359188b61e15a31750a496021c4394e1a3f
2015-06-08 16:23:52 +02:00
Noel Grandin
81610561ed uno::Sequence provides now begin and end
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-04 06:35:44 +00:00
Stephan Bergmann
cd93d5f36a loplugin:cstylecast: deal with those that are (technically) const_cast
Change-Id: Idbd718042e13e9c107c1a349c113656bf9468614
2015-06-02 11:25:47 +02:00
Caolán McNamara
bfd33a826c callcatcher: update unused code
Change-Id: I735264eb32ebdd165d23a4717f0329f666b8b140
2015-05-25 12:32:53 +01:00
Caolán McNamara
6240967cfc callcatcher: update unused code
Change-Id: I1f2a94cdcd4329af68d946ff0a74ddec4ac1c590
2015-05-24 15:40:22 +01:00
Michael Stahl
708f0d2afd comphelper::PropertySetInfo: convert legacy assertion
Change-Id: I23dbe1b3cf6cc611efe8a39c49f4e5b47bf25a49
2015-05-18 22:20:47 +02:00
Michael Stahl
24dbd76b8d comphelper::PropertySetInfo remove unused parameter
Change-Id: I960b31befe749860e926e5bb567c0b8d0f87867a
2015-05-18 22:20:47 +02:00
Andrea Gelmini
5b1337f7b2 tdf#62475: partial handmade fixes
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-15 17:55:15 +00:00
Tor Lillqvist
44724236a0 Add support for progress bar callbacks to LibreOfficeKit clients
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-06 17:55:58 +03:00
Stephan Bergmann
c47f7dfb30 sal/log.hxx is what was missing
Change-Id: I11aa264391aa4fcd90d171b9a6d93ed8e430b6cc
2015-05-06 13:46:41 +02:00
Tor Lillqvist
776d74bb55 If using std::random_device fails, fall back to just time(nullptr)
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-06 12:39:36 +03:00
Norbert Thiebaud
011563a083 seed mt19937 with random data
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-05-05 10:41:56 +00:00
Miklos Vajna
eaf4104582 comphelper::dispatchCommand: allow passing command arguments
Change-Id: I6464c5d1a46fadac2510700101f3c8cc29dd7995
2015-04-22 14:11:47 +02:00
Stephan Bergmann
6ff2d84ade Various #include <sal/log.hxx> fixups
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-22 09:57:47 +02:00
Stephan Bergmann
da36fc8c95 No more need for PartialWeakComponentImplHelper here
...since 70626249cd247d9acdad417b8eaf252bae22c059 "API CHANGE a11y unpublishing
and add/removeListener rename."

Change-Id: I89d81326d97712abcac94c3436a13905954c55cf
2015-04-21 22:48:02 +02:00
Stephan Bergmann
4592d27dca Get rid of trivial comphelper::in-/decrement wrappers
Change-Id: Id3a12ef9d56c30719f483e610c8a8b08caf05def
2015-04-21 08:56:51 +02:00