summaryrefslogtreecommitdiff
path: root/desktop
AgeCommit message (Collapse)Author
2018-09-10Generate UNO exception classes as SAL_WARN_UNUSEDStephan Bergmann
...to find more places like 09978dd1fc18ce1ae707bc9e4ea1d2745ff07b61 "clang-tidy bugprone-unused-return-value" Change-Id: Ibe8b6790c701dc8270295dd1e2cbc9023b5ce018 Reviewed-on: https://gerrit.libreoffice.org/60234 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-09-10tdf#42949 Fix IWYU warnings in include/cppuhelper/*Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ib420e9216b8313f5ed7634ec375e39ceb741fd45 Reviewed-on: https://gerrit.libreoffice.org/59297 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-09-08clang-tidy bugprone-unused-raii in RequestHandlerNoel Grandin
The message from clang-tidy is: warning: object destroyed immediately after creation; did you mean to name the object? The guard in RequestHandler::ExecuteCmdLineRequests comes from commit cf333a878ceed18d0343520a2c65be69fc433b1f Date: Sun Jan 21 22:10:09 2018 +0300 tdf#38915: set cProcessed condition on any process outcome and I'm sure it's intention was to set the flag on exit from the function, not immediately. Change-Id: Ibf874a5774770df00b9db7f673554e7ffda55072 Reviewed-on: https://gerrit.libreoffice.org/60183 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins
2018-09-06loplugin:simplifyconstruct in dbaccess..drawinglayerNoel Grandin
Change-Id: I83624d8bc787aaaaf6071171c882a6e5bde70a0d Reviewed-on: https://gerrit.libreoffice.org/60075 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-05Re-introduce code to use the ICU data file in the iOS app bundleTor Lillqvist
We used to have this code snippet in the TiledLibreOffice app back in the days. Then in LibreOfficeLight it was lost and forgotten (?). Clearly we need to tell ICU abouyt the data that we include as a separate file in iOS apps, and presumably any iOS app will be a LibreOffficeKit-based one, so let's do the initialistion here. Change-Id: Ib08dc9d7386789d10e8c53114e79d0b5beab7232
2018-09-05Handle passing a null pAppPath to lo_initialize() on iOSTor Lillqvist
Change-Id: I293ede0dbac4b36a1b91b86100bc11593b402d06
2018-09-05gbuild: allow recording of CppunitTests and PythonTests tooMichael Stahl
Since these don't use soffice they need to be tweaked to use RR variable. A rr git master build from some weeks ago can record all tests, except CppunitTest_dbaccess_firebird_test which fails. smoketest is a bit tricky because it spawns soffice which checks RR variable again and starts a nested rr, but fortunately there's a flag to prevent it from aborting in this situation. For UITests currently only the soffice.bin is recorded, not the python test process. The size of all the recording is about 35G per run in a --enable-dbgutil build. Change-Id: I2143618fa2181e36b6aaeded43637cb3481f5e47 Reviewed-on: https://gerrit.libreoffice.org/60032 Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> Tested-by: Michael Stahl <Michael.Stahl@cib.de>
2018-09-05clang-tidy performance-inefficient-vector-operationNoel Grandin
Change-Id: Iebcaea7b08c5284946d83b6b6b9ed26b218025d4 Reviewed-on: https://gerrit.libreoffice.org/59992 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-31tdf#42949 Fix IWYU warnings: boost/optional in include/Gabor Kelemen
Found with bin/find-unneeded-includes a few low hanging boost/optional headers. This gets us about 75M includebloat reduction; still much to go Change-Id: I5c737631767970f9145609aad298a5d11e3fed65 Reviewed-on: https://gerrit.libreoffice.org/59840 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-08-29desktop: improve help blurb for various casesThorsten Behrens
- tdf#109202 fix was missing --convert-images-to example - its not the mimetype, but the filter name that's needed - also add backslash line continuation where example cmd line overflows Change-Id: I80a461eb4a6ae5c9268bc0f888abd43a179c7a68 Reviewed-on: https://gerrit.libreoffice.org/59722 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2018-08-29Replace find_if with proper quantifier algorithmsArkadiy Illarionov
Change-Id: Icc820a47ac891c358883f9c01224f676c58fdd11 Reviewed-on: https://gerrit.libreoffice.org/59744 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-28Fix typo in codeAndrea Gelmini
To complete commit: e9fa088735bfbd34bc81f1925438691f746db070 It passed "make check" on Linux Change-Id: I2772b1ac5d4024bb11f3e09e24afc566b7091fb8 Reviewed-on: https://gerrit.libreoffice.org/59693 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2018-08-27rename ENABLE_HEADLESS option to DISABLE_GUINoel Grandin
since it has nothing to do with the headless command line option, so use the name it has in the configure.ac file Change-Id: Ibf0615ed02695d6e48a797f5632e4f417c010c70 Reviewed-on: https://gerrit.libreoffice.org/59611 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-16Fix typo: s/an other/another/gAndrea Gelmini
Change-Id: I203c546cfca841e7853282267190e20b60919add Reviewed-on: https://gerrit.libreoffice.org/59098 Tested-by: Jenkins Reviewed-by: Jens Carl <j.carl43@gmx.de>
2018-08-15Revert broken part of cd66852f6dd08631a25d15a1527a647e69ab8ce3Stephan Bergmann
"create appendCopy method in OUStringBuffer"; response_body is a std::string Change-Id: I58ab982c87fa568fdac8e3c72fbcb0e071d73228
2018-08-14create appendCopy method in OUStringBufferNoel Grandin
so we can avoid temporary copies when appending a substring of an OUString to the buffer. I would have preferred to call the method just "append" but that results in ambiguous method errors when the callsite is something like sal_Int32 n; OUStringBuffer s; s.append(n, 10); I'm not sure why Change-Id: I6b5b6641fcb5b26ce2269f89ef06e03c0b6aa76f Reviewed-on: https://gerrit.libreoffice.org/58666 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-12Fix fallout from 6a4c464b49dbfa2801818ead1b50bc9580824d00Tor Lillqvist
Change-Id: I72e4008a0aacf7e35006be685462168874954631
2018-08-10tdf#119194: save deprecated argument earlyMike Kaganski
Change-Id: I4b5001e1f71ac536ac0c3bda4b8c1955020ab40d Reviewed-on: https://gerrit.libreoffice.org/58815 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-08-05coverity#1438225 Improper use of negative valueCaolán McNamara
and coverity#1438221 Argument cannot be negative coverity#1438213 Argument cannot be negative coverity#1438227 Argument cannot be negative coverity#1438223 Argument cannot be negative coverity#1438222 Argument cannot be negative coverity#1438215 Improper use of negative value coverity#1438220 Improper use of negative value coverity#1438217 Improper use of negative value Change-Id: I398ae9901b27f6b65f03aad03638939b5880a671 Reviewed-on: https://gerrit.libreoffice.org/58626 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-08-02Revert rtl_alloc_preInit back to boolean argumentStephan Bergmann
This effectively reverts 271a663d2f098f3f665cab6da2e13b265a7eab93 "rtl: support start/stop threads around pre-init" again, now that df6ba650469a6f2fda06ef1c2e107ccdd3570505 "Remove 'officially dead now' rtl_cache slab allocator mechanism" removed the wsupdate thread. (rtl_alloc_preInit is an internal-use-only C function, so changing its arguments doesn't affect URE compatibility.) Change-Id: Ie9bce86377f9520e2600e4111ac525dddace10f8 Reviewed-on: https://gerrit.libreoffice.org/58443 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-08-02loplugin:returnconstant in cui,desktopNoel Grandin
Change-Id: Ieec9e3d9e2e18add9a1bc7e0e15bb8435ea51954 Reviewed-on: https://gerrit.libreoffice.org/58428 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-01Add missing sal/log.hxx headersGabor Kelemen
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. This is a continuation of commit 6ff2d84ade299cb3d14d4110e4cf1a4b8070c030 to be able to remove those unneeded includes. This commit adds missing headers to every file found by: grep -FwL sal/log.hxx $(git grep -Elw 'SAL_INFO|SAL_INFO_IF|SAL_WARN|SAL_WARN_IF|SAL_DETAIL_LOG_STREAM|SAL_WHERE|SAL_STREAM|SAL_DEBUG') to directories from dbaccess to extensions Change-Id: I4d15aa35e11664ef78c836ffc2937c7e0bb6ea59 Reviewed-on: https://gerrit.libreoffice.org/58165 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-08-01Remove "officially dead now" rtl_cache slab allocator mechanismStephan Bergmann
...after <https://gerrit.libreoffice.org/#/c/58263/> "the custom SAL allocator is no longer used" got merged. According to my July 31, 2018 comment there: "However, [...] this change is effectively a final coffin nail for the 'rtl_cache' mechanism. It could be argued that the alleged benefits of that mechanism (if it were still working) might be real (at least on some platforms; which would need measurements), and that it should be made working again (by reverting the effects of both ce906b8096081dee15dc8cc96e570d5b0b587955 'skip tricky allocators on G_SLICE=always-malloc' and bc6a5d8e79e7d0e7d75ac107aa8e6aa275e434e9 'Disable custom allocator' on rtl_cache_alloc/free again). But it could just as well be argued that the 'rtl_cache' mechanism is effectively gone for long enough now (since end of November, 2017, with bc6a5d8e79e7d0e7d75ac107aa8e6aa275e434e9 'Disable custom allocator') without any (apparent) negative consequences, so that it can be removed for good with this change." Change-Id: I8c1e45d494fc22555a9e675ab27be9e6e404abde Reviewed-on: https://gerrit.libreoffice.org/58369 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-07-29loplugin:stringloop in variousNoel Grandin
Change-Id: Ic2436c6d94729211cd5bc72fee18af228381e4a3 Reviewed-on: https://gerrit.libreoffice.org/58250 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-27loplugin:returnconstant in ucbhelper,drawinglayerNoel Grandin
Change-Id: I4e84c570fe0e555a3aeb1f11632715de466d6e0e Reviewed-on: https://gerrit.libreoffice.org/58192 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-23Fix typosAndrea Gelmini
Change-Id: I9671ad7c9e75b9e10abf46bc6b53fcd760acecbf Reviewed-on: https://gerrit.libreoffice.org/57599 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2018-07-23Fix typosAndrea Gelmini
Change-Id: Iebc31a53404da41f35eed7338662365d7efbd7a2 Reviewed-on: https://gerrit.libreoffice.org/57810 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-07-18Allow the comphelper threadpool to be reset after construction.Michael Meeks
Otherwise some pre-init components can start it, and threads get stranded in the forkit process causing grief. Change-Id: Ib1846f8b329b4c6b84645999dafba1252c5129c7 Reviewed-on: https://gerrit.libreoffice.org/57631 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2018-07-18Fix typosAndrea Gelmini
Change-Id: I5195d13b351c0eebad1eae901f7ce8408a9e5c92 Reviewed-on: https://gerrit.libreoffice.org/57028 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2018-07-17desktop lok: associate EPUB filter with the .epub suffixMiklos Vajna
Change-Id: I7bc4da5404f1947415e982f52e15f4fe76b17348 Reviewed-on: https://gerrit.libreoffice.org/57559 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins
2018-07-13merge IUndoManager into SfxUndoManagerNoel Grandin
SfxUndoManager is the only implementation of the IUnderManager "interface", and it lives in the same header. Plus this way we can get rid of some covariant parameters, which will make using std::unique_ptr easier. Change-Id: I6661b9876b18da830bead78794d237886cd3c5c9 Reviewed-on: https://gerrit.libreoffice.org/57317 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-10tdf#42949 Fix IWYU warnings in include/osl/*hxxGabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I7b19938246ca8498fa300f781589bf17b3d486aa Reviewed-on: https://gerrit.libreoffice.org/56723 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-07-10pass SvStream around by std::unique_ptrNoel Grandin
and give utl::OStreamWrapper a new constructor so that it knows it is taking ownership of the SvStream, which appears to fix several leaks Change-Id: Idcbcca9b81a4f0345fd8b8c8a2f4e84213686a6b Reviewed-on: https://gerrit.libreoffice.org/57187 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-07fix vecUnaccepted check in printf_packagesNoel Grandin
regression from commit 1b0beef8794210b2af49d8c4a00ca7d4e3ebedb7 Date: Tue Mar 6 22:36:02 2018 +0100 Use for-range loops in desktop (part2) Change-Id: I684462f4473eb57db589033795dd4f91d8897389 Reviewed-on: https://gerrit.libreoffice.org/57109 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-02tdf#88205 Adapt uses of css::uno::Sequence to use initializer_list ctorJacek Fraczek
Change-Id: Ib06c8ed707bdfd87b294b2597614249fac2c1f18 Reviewed-on: https://gerrit.libreoffice.org/56342 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2018-06-29tdf#96099 Remove trivial std::map typedefs in [cd]*Arkadiy Illarionov
Change-Id: I043d265d3d73a3e16f05d5ca7e29a09341651d82 Reviewed-on: https://gerrit.libreoffice.org/56639 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-06-27tdf#96099 Remove some trivial std::deque typedefsArkadiy Illarionov
Change-Id: I101c8a39344ab007640aec9ddad6f82d4fe64296 Reviewed-on: https://gerrit.libreoffice.org/56504 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-06-25Fix "javaPathHelper: not found" errors during startup.Thomas Klausner
javaPathHelper is a tool from OpenBSD ports, so there is no point looking for it on other operating systems. Change-Id: I763d717fdf7172b412d527fcd88347b2e54a8fe9
2018-06-25loplugin:useuniqueptr in desktopNoel Grandin
Change-Id: Iff29d7d5962b441678c91bcd0319ac07c6488b34 Reviewed-on: https://gerrit.libreoffice.org/56327 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-06-20lok: Unit test for passing table borders via jsonToPropertyValuesVector.Jan Holesovsky
Change-Id: Iadc0d76a1903d76fcd84f316d4796cc1dec13277 Reviewed-on: https://gerrit.libreoffice.org/56150 Tested-by: Jenkins Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2018-06-20lok: Unit test for jsonToPropertyValuesVector.Jan Holesovsky
Change-Id: I3e0623cc68838c650edbd03cc89bf3fcb8098ff8 Reviewed-on: https://gerrit.libreoffice.org/56149 Tested-by: Jenkins Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2018-06-20lokit: add jsonToUnoAnyHenry Castro
Change-Id: I79c2fe22fe7f3a8daa121ecaa529b6bca3216bf3 Reviewed-on: https://gerrit.libreoffice.org/56032 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2018-06-13Add some help content to test-passive.oxtStephan Bergmann
...mainly to test how well/poorly extension help is supported by --with-help=html, but also as a kind of reference implementation. (There are also extensions in odk/examples/ that contain help content, namely odk/examples/DevelopersGuide/Extensions/DialogWithHelp/ containing context- sensitive help for a dialog, a topic that is not covered here.) See <https://wiki.openoffice.org/wiki/Documentation/DevGuide/Extensions/ Help_Content#Integration_into_the_OpenOffice.org_help_system> for the ways an extension's help content can be integrated into the "classic" (plain --with-help) help system (citing sub-section headings used in that document): * Help Viewer Contents page: The contained help.tree provides a "The test-passive Extension" section with a "The test-passive Extension" page (main.xhp). * Help Viewer Index page: The contained main.xhp provides index entries for "test-passive extension" and "extensions"-"test-passive", and---only on the index pages of Calc and Writer ---for "test-passive extension in Calc and Writer". * Help Viewer Find page: The contained main.xhp is indexer="include", so it should be found by e.g. searching for "bla bla". * Context sensitive help and extended tool tips: The contained Addons.xcu has been extended with a small (floating by default) toolbar containing a "native" button (doing the same as the "passive - native" menu entry), and the contained main.xhp provides an extended tooltip of "Show the test-passive extension's native dialog" for that toolbar button (displayed when using "Help - What's This?" and hovering over the button). For context-sensitive help for dialogs, see the mention of odk/examples/DevelopersGuide/Extensions/DialogWithHelp/ above. The contained help is only provided in "en" localization, which should thus be used as fallback regardless for which locale LO is run. The help-related XML files need to provide identifiers in lots of places, many of which appear to be unused for the given example uses. I specified those as empty strings. The workdir/Extension/test-passive.oxt extension can be built with `make Extension_test-passive`. Change-Id: I0e75f35df85683c9fae1d1384fa6afeaeb8a687d Reviewed-on: https://gerrit.libreoffice.org/55736 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-06-12simplify calls to *DialogFactory::Create methodsNoel Grandin
we don't need to check for nullptr here, it's never null. Change-Id: I3cc5337a8f4dec6747821679e39ccba3cec20f56 Reviewed-on: https://gerrit.libreoffice.org/55114 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-06-05tdf#42949 remove unused compheler includes ..Jochen Nitschke
and fix the fallout Change-Id: I15bc5d626f4d157cbc69a87392078b41e621d14e Reviewed-on: https://gerrit.libreoffice.org/54882 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-06-01loplugin: look for CPPUNIT_ASSERT_EQUALS with params swappedNoel Grandin
idea originally from either tml or moggi, can't remember which Change-Id: Id78d75035036d3aa1666e33469c6eeb38f9e624d Reviewed-on: https://gerrit.libreoffice.org/55126 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-28tdf#96099 Remove some trivial typedef std::vectorArkadiy Illarionov
Change-Id: I41fff78c10d46bde50063536d8cf1a3942dbf6af Reviewed-on: https://gerrit.libreoffice.org/54834 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2018-05-25Improve re-throwing of UNO exceptionsNoel Grandin
(*) if we are already throwing a Wrapped*Exception, get the exception using cppu::getCaughtexception. (*) when catching and then immediately throwing UNO exceptions, use cppu::getCaughtException to prevent exception slicing (*) if we are going to catch an exception and then immediately throw a RuntimeException, rather throw a WrappedTargetRuntimeException and preserve the original exception information. Change-Id: Ia7a501a50ae0e6f4d05186333c8517fdcb17d558 Reviewed-on: https://gerrit.libreoffice.org/54692 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-23remove Linux ("UNX") systray "Quickstarter"Rene Engelhard
Change-Id: Ie0e8b8b7ad59ee640d6b195dfae1a7cf745056fd Reviewed-on: https://gerrit.libreoffice.org/54543 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2018-05-23rename config_extension_update.h.in to config_extensions.h.inRene Engelhard
... and move HAVE_FEATURE_EXTENSIONS there, too Change-Id: I37fe52071e1db32cf5cc1e51dbd89bb4f32a39c1 Reviewed-on: https://gerrit.libreoffice.org/54072 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Rene Engelhard <rene@debian.org>