summaryrefslogtreecommitdiff
path: root/comphelper
AgeCommit message (Collapse)AuthorFilesLines
2016-06-17tdf#98955 hardware_concurrency not ideal for thread poolsAshod Nakashian4-1/+109
A new static member getPreferredConcurrency added to comphelper::ThreadPool to return a configurable max number of threads. By default the new function returns the hardware_concurrency value provided by std::thread. When MAX_CONCURRENCY envar is defined, the return value is limited to whatever is set there. Three call-sites that used std::thread::hardware_concurrency have been replaced with getPreferredConcurrency. Unittests added to cover the functionality of the new member. Unittests are capped to 4 threads. Reviewed-on: https://gerrit.libreoffice.org/26254 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> (cherry picked from commit 60e75fb276778459f6055360646d879b8c615d83) Change-Id: I3332e393a88a5ed436316fa712ed920a4b37f4af Reviewed-on: https://gerrit.libreoffice.org/26395 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-05-24Revert "remove some manual ref-counting"Noel Grandin1-8/+14
until I have a better understanding of the UNO reference counting. This reverts commit 111de438ea3e512a541281dc0716cc728ea8d152.
2016-05-24remove some manual ref-countingNoel Grandin1-14/+8
triggered when I noticed a class doing acquire() in the constructor and then release() in the destructor. found mostly by git grep -n -B5 -e '->release()' Change-Id: Ie1abeaed75c1f861df185e3bde680272dbadc97f Reviewed-on: https://gerrit.libreoffice.org/25363 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-19clang-tidy misc-unused-alias-declsNoel Grandin1-2/+0
Change-Id: Iabde7a84b9c2758e0d2b2ffe0fb99fcfa51ff124 Reviewed-on: https://gerrit.libreoffice.org/25075 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-18update unusedmethods plugin to deal with constructorsNoel Grandin2-18/+0
and fix the operator< implementations in some of the other plugins too. Change-Id: Ie5631e0cdc8d2a994ad2af2533cdb558a6cfc035 Reviewed-on: https://gerrit.libreoffice.org/25057 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-18clang-tidy modernize-make-sharedNoel Grandin1-1/+1
Change-Id: I3fa866bfb3093fc876474a9d9db29fe05dc2af3a Reviewed-on: https://gerrit.libreoffice.org/25056 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-16conver CHAR to scoped enumNoel Grandin1-73/+79
Change-Id: Ie7f22c6986a0973e6d50bbd1fe9c10f6b478a2db Reviewed-on: https://gerrit.libreoffice.org/24984 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-04use Any constructor instead of temporariesNoel Grandin2-6/+2
Change-Id: Iffb82a2cee1a28d89eeea2b905aaa14086ee475a
2016-04-29Iteration must not start at the endSeraphime Kirkovski1-1/+1
Change-Id: I2aebcc909aa9222fc1881e57bbc844025a154e84 Reviewed-on: https://gerrit.libreoffice.org/24497 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
2016-04-27-Werror,-WvarargsStephan Bergmann1-9/+5
"passing an object that undergoes default argument promotion to 'va_start' has undefined behavior [-Werror,-Wvarargs]" just replace the variadic function with one taking an initializer list Change-Id: Ied3dfe835dcebef48cf35374ec4d8835f98e6779
2016-04-26loplugin:simplifyboolStephan Bergmann1-1/+1
Change-Id: Ie3662271f57df724329cb5fa52881479890277f9
2016-04-26update loplugin stylepolice to check local pointers varsNoel Grandin1-4/+4
are actually pointer vars. Also convert from regex to normal code, so we can enable this plugin all the time. Change-Id: Ie36a25ecba61c18f99c77c77646d6459a443cbd1 Reviewed-on: https://gerrit.libreoffice.org/24391 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-26tdf#60418: improve perf of opening/closing odts with form tagsAron Budea2-76/+48
Opening/closing times using "Without Frame tags" attached file from bug report changed as follows on my system (debug build): open: 2:06 -> 1:32 close (doc unchanged): 1:52 -> 0:18 The performance fixes in the different CXX files are independent, eventattachermgr.cxx is related to doc close, the others to doc open. Change-Id: I24fc4558f79b9123494a3939c0a313fcd47a067f Reviewed-on: https://gerrit.libreoffice.org/24359 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-04-25Some more sal_Bool -> boolStephan Bergmann1-1/+1
Change-Id: Ie29e3610ae7fc7a489b367fd6797db7547d47c49
2016-04-22Add an interaction handler wrapper for simple file access.Giuseppe Castagno2-0/+141
This wrapper is to be used when you want to avoid the error messages displayed when accessing a file (the messages activated by ucphelper::cancelCommandExecution), especially when accessing a Web/DAV connection to enable https certificate validation and optionally enabling the authentication dialog that may be needed in these operations. Change-Id: I19f3072b91b6c4f453a54b56a3d9883b3383dfa5 Reviewed-on: https://gerrit.libreoffice.org/24274 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-04-21clang-tidy modernize-loop-convert in c*Noel Grandin1-4/+4
Change-Id: I77d2548f8be97792660761e6156cd24734a95aaf
2016-04-20loplugin:salbool: Automatic rewrite of sal_False/TrueStephan Bergmann10-26/+26
Change-Id: Idb7e5ff0c73bbc2c462b92cd96444eb5d2d4194b
2016-04-18clean-up: unused using declarations and includesJochen Nitschke8-20/+0
Searched source for using declarations. Checked if those symbols reappear in the source file, even in comments or dead code but not in #include statements. If they don't reappear, remove the declaration. Remove includes whose symbol got removed. Change-Id: Ibb77163f63c1120070e9518e3dc0a78c6c59fab0 Reviewed-on: https://gerrit.libreoffice.org/24148 Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-13tdf#94306 remove unused boost dependenciesJochen Nitschke1-1/+0
remove <boost/noncopyable.hpp> in pch and remove boost from makefile if it was the only boost entry. Change-Id: Icb945ae59c137571f4f63807601738eea5c3e831 Reviewed-on: https://gerrit.libreoffice.org/24061 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2016-04-13loplugin:passstuffbyref in comphelperNoel Grandin2-4/+4
Change-Id: I502a0ec6627f37e17c4a9adebda58299167a8126
2016-04-12cleanup: remove unused com/sun/star/uno includesJochen Nitschke5-7/+0
Sequence.h(xx), Any.h(xx) and Type.h(xx) and remove unused using-declarations from these files. Add a few missing includes provided by them. Change-Id: I6b91b6d1fdf9d0496dd546c0aab9bdcc6831a5d4 Reviewed-on: https://gerrit.libreoffice.org/23805 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-11clang-tidy performance-unnecessary-value-param in comphelperNoel Grandin5-7/+7
Change-Id: Iff26c89ea6079e0f12691dbc04bb36f02b85c305 Reviewed-on: https://gerrit.libreoffice.org/23920 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-08tdf#94306 replace boost::noncopyable in c...Jochen Nitschke5-14/+23
comphelper, connectivity and cppcanvas. Replace with C++11 delete copy-constructur and copy-assignment. Removed unused boost/noncopyable.hpp includes from some source files in cppcanvas. Change-Id: I90780820e21fbfd291ac10c266e7d16616e3a81b Reviewed-on: https://gerrit.libreoffice.org/23905 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2016-04-05tdf#74608 Constructor function for SequenceOutputStreamServiceYeliz Taneroğlu4-26/+7
Change-Id: I0f162bd0ec61262a182ebab8cea1cfe27419a54e Reviewed-on: https://gerrit.libreoffice.org/23610 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-04-05loplugin:constantparam in comphelperNoel Grandin4-117/+52
Change-Id: I81e6af1ee869caa3b40d2d00604e8e22517d92d7 Reviewed-on: https://gerrit.libreoffice.org/23808 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-02cleanup: remove unused Reference.h(xx) includesJochen Nitschke8-11/+0
and unused using-declarations from Reference.h Change-Id: I297a7ae6044fa329d245ecf08fd5c4cb930f5b19 Reviewed-on: https://gerrit.libreoffice.org/23735 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2016-04-01tdf#97966 Drop 'static' keywordsWastack1-3/+3
Including no keywords from extern "C" blocks Change-Id: Id0304994a692f1004993dda2ffd7fb819ab8e8d0 Reviewed-on: https://gerrit.libreoffice.org/23670 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2016-03-29tdf#74608 Constructor function for SequenceInputStreamServiceSteven Guo4-27/+8
Added ctor funtion for SequenceInputStream(Service) in comphelper. Change-Id: I043e46aa283709f316e7ad794e15438f6b2d955f Reviewed-on: https://gerrit.libreoffice.org/23564 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-03-11Resolves: tdf#98418 AttributeList must support XCloneableCaolán McNamara1-3/+15
regression from commit 8998768a34751d35403678a81464a26835b2230e Date: Sat Feb 6 18:38:32 2016 +0100 Change-Id: I217fb66621505b77b6102954c07ef513e2d4b25e
2016-03-11tdf#97966: Remove 'static' keywordsWastack1-1/+1
Change-Id: Iced527f48afa828cc9acf5b6461674a2706cbcd7 Reviewed-on: https://gerrit.libreoffice.org/23135 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2016-03-10Avoid reserved identifierStephan Bergmann1-2/+2
Change-Id: Ib02af22430421a2f49de742853ca0f5c42e21cd0
2016-03-10Avoid reserved identifiersStephan Bergmann1-9/+9
Change-Id: Iaf015fdcf9818655243e138c6c655c5f86511ac3
2016-03-08tdf#74608 comphelper: Constructor feature for InstanceLockerYeliz Taneroğlu5-37/+9
Change-Id: If2c597d56d4dde74ec8361b74bdd1933f42afa4b Reviewed-on: https://gerrit.libreoffice.org/22940 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-03-03loplugin:unuseddefaultparams comphelperNoel Grandin5-17/+9
Change-Id: I78280a13fc0d82fc87041b5dad0c3f2f7d462652 Reviewed-on: https://gerrit.libreoffice.org/22853 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-01OSingletonRegistration is dead nowMatúš Kukan1-14/+0
Change-Id: I64a5ffa8790496bd39ba26e0c789db9eedc51071 Reviewed-on: https://gerrit.libreoffice.org/22788 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Matúš Kukan <matus@libreoffice.org>
2016-02-24convert HighlighterLanguage to scoped enumNoel Grandin2-9/+9
Change-Id: Ibf0871601e52ea4fa49e9622176431943c55abdd
2016-02-24convert TokenTypes to scoped enumNoel Grandin2-32/+37
Change-Id: I17c0a616dd6cf48a22896b6cd6b0df157d1f9a9f
2016-02-24remove unused exc_handling enumNoel Grandin1-21/+12
Change-Id: I5e2e084114c8b0eedd0f2cd8327d6c6d68742462
2016-02-24convert PropertyDescription::LocationType to scoped enumNoel Grandin1-13/+13
Change-Id: Ifcd6bf1728c632ed10301c4a426dae57dbf0912a
2016-02-24convert DocPasswordRequestType to scoped enumNoel Grandin1-2/+2
Change-Id: I25d217ca2cf3e8cc4dfaccc6dc7d5453ffdc6cb6
2016-02-24convert PropertyOrigin to scoped enumNoel Grandin1-5/+5
Change-Id: I26c9929be8aad02030722508334e66f5028ffb37
2016-02-24convert DocPasswordVerifierResult to scoped enumNoel Grandin1-10/+10
Change-Id: Ib5a595819dec8511d284ed1022d8f7c624f8d8f9
2016-02-24convert EConfigurationModes to scoped enumNoel Grandin1-8/+8
Change-Id: I1e81c8d637e738f536f7efad8b67d0c9183e6483
2016-02-24convert ComponentMethodGuard::MethodType to scoped enumNoel Grandin1-1/+1
Change-Id: I1f1b4981c70c2b8ff8087a85f0af28b816b4654a
2016-02-24tdf#74608: Constructor function for SimpleLogRing singletonyeliztaneroglu5-46/+27
Change-Id: Ia8c2f214b635114ecac4a2ceb06628a2f18b6411 Reviewed-on: https://gerrit.libreoffice.org/22020 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-02-23new loplugin: commaoperatorNoel Grandin1-1/+1
Change-Id: I03f24e61f696b7619855e3c7010aa0d874e5a4ff
2016-02-17Typo: namesapce(s)->namespace(s)Julien Nabet1-1/+1
Change-Id: Ic7c14c2e39a5ade1f5622a8350f9197d84cf9cc8
2016-02-17use consistent #define checks for the Windows platformNoel Grandin1-1/+1
stage 2 of replacing usage of various checks for the windows platform with the compiler-defined '_WIN32' macro In this stage we focus on replacing usage of the WIN macro Change-Id: Ie8a4a63198a6de96bd158ecd707dadafb9c8ea84 Reviewed-on: https://gerrit.libreoffice.org/22393 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-02-11[API CHANGE] add operator==/!= to UNO structsNoel Grandin1-21/+0
this is useful now that we are storing UNO structs in std::vector Change-Id: Ic558bcd669bd2b3cdf9eb8393269eb906ac52369 Reviewed-on: https://gerrit.libreoffice.org/22257 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-02-09sequence->vector in OFOPXMLHelper_ImplNoel Grandin1-19/+15
Change-Id: I6c5806fefc57d82124652ecbb5bfa8e109f9a255 Reviewed-on: https://gerrit.libreoffice.org/22181 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>