Noel Grandin
3e76797384
move comphelper::string::toInt32 to o3tl
...
so we can use it in places where we cannot include comphelper
Change-Id: Iba0ba3e4c0dcf0f9d1f09092a77c3b2010ec4f6d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132732
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2022-04-08 20:44:43 +02:00
Noel Grandin
36e0e88b28
use more subView when converting to Int32
...
Change-Id: I54e3ddf79ba793fd4328bf8bda7f949b65349651
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132693
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2022-04-08 13:18:41 +02:00
Noel Grandin
1927b51993
loplugin:stringviewparam convert methods using indexOf
...
.. and lastIndexOf, which convert to find and rfind
Change-Id: I6c4156cf904774c0d867f85a4c2785dba7593f62
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132445
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2022-04-02 13:31:19 +02:00
Stephan Bergmann
47e6bf0109
Fold MenuBarManager::Destroy into its only call site
...
...mainly to demonstrate that its SolarMutexGuard was redundant and that
replacing it with DBG_TESTSOLARMUTEX() would be overkill
Change-Id: I82f00873cd99cb5da1b644c40ba25f8c210503cd
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132112
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com >
2022-03-25 15:38:42 +01:00
Stephan Bergmann
6e135909d3
tdf#147668: Destroy still needs to do its work when called from disposing
...
Regression introduced with d4257daba1 "use
comphelper::WeakComponentImplHelper in MenuBarManager" changing
- if ( rBHelper.bDisposed )
+ if ( m_bDisposed )
in MenuBarManager::Destroy, but where comphelper::WeakComponentImplHelper sets
m_bDisposed to true before calling disposing.
And Destroy is only called from disposing, so the check can just be removed.
Change-Id: I2625dff9fbb333435a0d1478b0f285c21cd3ee15
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132075
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
Reviewed-by: Stephan Bergmann <sbergman@redhat.com >
Tested-by: Jenkins
2022-03-25 08:21:14 +01:00
Juergen Funk
846c3ce7a2
Solve exception in implts_flushConfigItem
...
Regression from 4256c764ae
in framework/source/services/autorecovery.cxx
in line 1997 sloved the exception
Change-Id: I4bee90b94307978c9c5186c1c5fdaca1aa420e21
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131901
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com >
2022-03-22 13:27:56 +01:00
Noel Grandin
69b5f0b657
loplugin:constparams
...
Change-Id: I5f184f93dbdb414514855c85c9dc1624e7ec8636
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131337
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2022-03-11 10:05:39 +01:00
Luboš Luňák
4256c764ae
do not pass XComponentContext to officecfg::...::get() calls
...
It's used only for the ConfigurationWrapper singleton, so it's used
only the first time and then ignored. It also causes calls to
comphelper::getProcessComponentContext() for every single invocation
despite the value not being needed, and the calls may not be cheap
(it's ~5% CPU during ODS save because relatively frequent calls
to officecfg::Office::Common::Save::ODF::DefaultVersion::get()).
Change-Id: I02c17a1a9cb498aeef220ddd5a0bde5523cb0ffb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131056
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com >
2022-03-07 15:37:22 +01:00
Jens Carl
89aec86200
tdf#45904: Remove ScHeaderFieldObj Java test
...
The ScHeaderFieldObj Java tests are implemented in
ScEditFieldObj_Header.
Change-Id: I45d3b17bd244090c491c85475f20bc06eb92908f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130953
Tested-by: Jenkins
Reviewed-by: Jens Carl <j.carl43@gmx.de >
2022-03-04 17:16:06 +01:00
Andrea Gelmini
2c5d4436f0
Fix typos
...
Change-Id: I9a98bac7c570f25ff7d77df98e93aaeed2665038
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130720
Tested-by: Julien Nabet <serval2412@yahoo.fr >
Reviewed-by: Julien Nabet <serval2412@yahoo.fr >
2022-03-01 19:22:40 +01:00
Jens Carl
26cbb045a0
tdf#45904 Move XComponent Java test to C++
...
Move XComponent Jave tests to C++ for ScCellFieldObj_Cell and
ScCellFieldObj_Header (formerly ScCellFieldObj).
Change-Id: Ibf293a72801720fee49acdda5a3a463e9202bb58
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130742
Tested-by: Jenkins
Reviewed-by: Jens Carl <j.carl43@gmx.de >
2022-03-01 17:40:52 +01:00
Jens Carl
a1877ab81b
tdf#45904 Move XElementAccess Java test to C++
...
Move XElementAccess Java test to C++ for ScHeaderFieldsObj.
Change-Id: I1bc29be9f17d117edecfd889b4f9784ffbd74d71
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130660
Tested-by: Jenkins
Reviewed-by: Jens Carl <j.carl43@gmx.de >
2022-02-28 06:27:21 +01:00
Xisco Fauli
280c505373
CppunitTest_framework_dispatch: remove duplicated dispatchCommand
...
it's already defined in unotest::MacrosTest
Change-Id: I2abc4bea61f55242b9cf3c7f030f5c74f8a51efe
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130402
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org >
2022-02-23 09:06:59 +01:00
Noel Grandin
27352b8163
Add XWeak constructor and operator= to uno::WeakReference
...
which is faster since we can skip the UNO_QUERY.
Change-Id: Id95ad9f3568213e974bd13659d92d4ea94dbfbd6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130282
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2022-02-22 12:27:55 +01:00
Armin Le Grand (Allotropia)
4a0ccb5fec
WASM make test file loading work
...
Change-Id: Ic34104534c3e0e73791cf867bfb2e1246dc79cf8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128653
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de >
2022-01-20 14:27:16 +01:00
Armin Le Grand (Allotropia)
02140554ee
WASM --enable-wasm-strip now skips lots of LO code
...
... resulting in a stripped-down, Writer-only build to decrease
the resulting WASM bytecode size.
It removes the following code from the build:
* All other major modules: Base, Calc, Chart, Draw, Impress and
Math and related writerperfect filters
* The premultiply tables
* The (auto-)recovery functionality
* All accessibility (but not the accessibility document checker)
* The LanguageGuess component
* EPUB support
* The start center / BackingWindow
* The TipOfTheDay functionality
* The splash screen communication
Currently crashs with anything different then soffice --writer.
Closing the document also still crashes.
FYI: many of these features are now behind ENABLE_WASM_STRIP_*
defines, but they normally don't work on their own, globally!
That's because we started with stripping the main components.
Change-Id: Ib9c0f9452815910c0a2aceaf142ba1ad4a9cb0d7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126182
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de >
2022-01-20 12:28:54 +01:00
Gabor Kelemen
e3206e6740
Recheck modules [e-f]* with IWYU
...
See tdf#42949 for motivation
Change-Id: I49a3ce10dee4b03f99156f5b641f69448e1d5617
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128479
Tested-by: Jenkins
Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de >
2022-01-17 01:33:35 +01:00
Caolán McNamara
4342717dcd
include memory for std::unique_ptr
...
Change-Id: I15f78ecfc53e75403bb8edbcd6e5400e8ecaaa44
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128465
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com >
2022-01-15 17:35:16 +01:00
Mike Kaganski
6b973753d4
tdf#146754: consider xyz:123 as host:port when parsing URLs smart
...
... rather than scheme: and path.
Change-Id: I9a48310b585b8fa3e31635f877a91f1560b065f0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128457
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com >
2022-01-15 10:52:56 +01:00
Noel Grandin
a2eaf99e46
make comphelper::OInterfaceContainerHelper4 more threadsafe
...
(*) make all the methods that require an external mutex take a
std::unique_lock as a parameter, so that call sites cannot forget
(*) make the forEach method drop the lock when firing listener methods,
to reduce the odds of deadlock
Change-Id: I0a80e3b3d1c1c03b7de4a658d31fcc2847690903
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128415
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2022-01-14 21:04:10 +01:00
Noel Grandin
a67b622ce5
OReadStatusBarDocumentHandler doesnt need SolarMutex
...
it is only ever used from a single thread. This was there
since the beginning.
Change-Id: Ib001db94c7a5b2520d9a6435e21c27dca60d1dd0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128271
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2022-01-11 13:21:01 +01:00
Noel Grandin
72493fe922
OWriteToolBoxDocumentHandler doesnt need SolarMutex
...
it is only ever used from a single thread. This was there
since the beginning.
Change-Id: I580cf86457b2983cd7729bce32cbc0ccca601005
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128270
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2022-01-11 12:55:57 +01:00
Noel Grandin
934d246e77
OWriteImagesDocumentHandler doesnt need SolarMutex
...
it is only ever used from a single thread. This was there
since the beginning.
Change-Id: If6c2929677ea1231cbf3326974451c3c6d51486f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128269
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2022-01-11 12:55:43 +01:00
Noel Grandin
c155710de1
OReadImagesDocumentHandler doesn't need SolarMutex
...
it is only ever used from a single thread. This was there
since the beginning.
Change-Id: I7a2629071a3b2f3d4ddb6c7758a24515cfd5cebc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128268
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2022-01-11 12:55:30 +01:00
Caolán McNamara
326351e2b3
move UserData bodge into VCLXMenu
...
Change-Id: I20c303788e576a29574a696cb20c9e8a235233b1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126804
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com >
2022-01-08 15:32:56 +01:00
Noel Grandin
aaa42c6725
use comphelper::WeakComponentImplHelper in WindowContentFactoryManager
...
Change-Id: I0918d7d1ff84b4d5e41191b554d08474abce1f93
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127518
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-27 09:00:06 +01:00
Noel Grandin
5437632edf
use comphelper::WeakComponentImplHelper in UIElementFactoryManager
...
Change-Id: I048e5671df230c498a2425d60f64208089fd044b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127489
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-27 07:34:16 +01:00
Noel Grandin
cfd257873a
use comphelper::WeakComponentImplHelper in UIControllerFactory
...
Change-Id: I4b583d72a1ece5af86f43be2f2add3da2779502a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127488
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-27 07:34:00 +01:00
Noel Grandin
8566b3f8d2
use comphelper::WeakComponentImplHelper in StatusbarItem
...
Change-Id: I2c278547d16c5ad0530188f1e465cb784d345746
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127460
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-26 08:23:53 +01:00
Noel Grandin
a839a6afad
use comphelper::WeakComponentImplHelper in UICommandDescription
...
Change-Id: I042c9761c60d3b1c39950cfede80958edf2d84c2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127461
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-26 08:23:14 +01:00
Noel Grandin
92c0775f2f
use comphelper::WeakComponentImplHelper in SubstitutePathVariables
...
Change-Id: I1b41ae57b65b42ef63d2d2c026cf78a00b5b937d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127462
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-26 08:22:42 +01:00
Noel Grandin
2d1ed93e46
use comphelper::WeakComponentImplHelper in TaskCreatorService
...
Change-Id: I2414ef01bc0990c68bb6fa02a897bfa19d7982a6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127463
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-26 08:22:20 +01:00
Noel Grandin
058c64ad17
use comphelper::WeakComponentImplHelper in WindowStateConfiguration
...
Change-Id: Iada515ab1926aa1e0b7a3f39690d7c6eebf28aea
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127465
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-26 08:21:59 +01:00
Noel Grandin
d4257daba1
use comphelper::WeakComponentImplHelper in MenuBarManager
...
Change-Id: I687f71c5af810618b3ab27b004bf765b53d7b8e6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127466
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-25 19:34:05 +01:00
Noel Grandin
98dbe250d7
use comphelper::WeakComponentImplHelper in ContextChangeEventMultiplexer
...
Change-Id: I6f8c2be817695e44b25f209a5a56e021cd3e94d5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127487
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-25 19:33:53 +01:00
Noel Grandin
a7a1d8647a
use comphelper::WeakComponentImplHelper in ModuleUIConfigurationManagerSupplier
...
Change-Id: I22164080dd87ab3c3a93b50d06cba8574e00c189
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127464
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-25 18:14:05 +01:00
Noel Grandin
a997f62242
cleanup AcceleratorCache
...
(1) reduce visibility of stuff nothing is using outside the class
(2) remove noise comments
Change-Id: Icea829ef92d6121b957ad47a992ef7ac04656af9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127324
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-22 17:17:48 +01:00
Andrea Gelmini
bddf28af4a
Fix typo
...
Change-Id: I0b441f47062a45395777b609d71ea0fa978bffc9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127279
Tested-by: Julien Nabet <serval2412@yahoo.fr >
Reviewed-by: Julien Nabet <serval2412@yahoo.fr >
2021-12-21 21:35:08 +01:00
Noel Grandin
489bce5986
loplugin:flatten in filter..framework
...
Change-Id: I15a577b3c6da03001bbbf2c2b43b29b41c4007c1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127234
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-21 17:14:14 +01:00
Noel Grandin
a08f3b1055
osl::Mutex->std::mutex in GlobalImageList
...
Change-Id: I12b3074e77e67bfd0914f74d71ad2dace8d1ac21
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127107
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-20 17:52:30 +01:00
Noel Grandin
dab35c152a
osl::Mutex->std::mutex in ModuleUIConfigurationManager
...
Change-Id: I012ba8ab049fd19832e9f1df643957e57c05b69c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127109
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-20 17:52:01 +01:00
Noel Grandin
516fa8464f
osl::Mutex->std::mutex in ImageManagerImpl
...
Change-Id: I2feae13f2d8fe90d1f3b072156f3e384fd71db82
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127108
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-20 14:58:02 +01:00
Noel Grandin
d53b9c69e2
osl::Mutex->std::mutex in UndoManagerHelper_Impl
...
Change-Id: I4d279e2175f22422bec242ef8a15166cf67ef59f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127105
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-20 13:11:28 +01:00
Noel Grandin
599cb40c92
osl::Mutex->std::mutex in Oxt_Handler
...
Change-Id: Iaa7120a5373c09a1515dc76e5a5ba19b16cf1554
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127102
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-20 09:47:16 +01:00
Noel Grandin
95b7ecbbdb
osl::Mutex->std::mutex in WakeUpThread
...
Change-Id: I469fa855eb373829f23232875669f607dcb0c6a6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127104
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-20 09:25:41 +01:00
Noel Grandin
82ceab070d
osl::Mutex->std::mutex in UIConfigurationManager
...
Change-Id: Idbad742b51c1ee8b8ba7104bc7520772ad947ed2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127110
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-20 08:36:05 +01:00
Noel Grandin
7e44d8d78a
osl::Mutex->std::mutex in HelpOnStartup
...
Change-Id: I3133ab5e0f0af40c7570856c216f3921576818af
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127103
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-20 08:34:04 +01:00
Noel Grandin
7fe0a4cddf
osl::Mutex->std::mutex in StorageHolder
...
Change-Id: Ie0ababcea79b445ac73ffd4e69d260a7641af663
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127106
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk >
2021-12-20 08:33:50 +01:00
Andrea Gelmini
9d65987055
Fix typos
...
Change-Id: I7f1636226c4fbe29d9d2ef850318a9d57f1b5450
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127009
Tested-by: Julien Nabet <serval2412@yahoo.fr >
Reviewed-by: Julien Nabet <serval2412@yahoo.fr >
2021-12-17 20:43:28 +01:00
Mike Kaganski
866b569b58
tdf#146219: don't try to detect if a recent file is a directory
...
This avoids accessing (possibly unavailable) remote URLs,
when we already know that MRU items are files.
Change-Id: I97e07f007d4129b93b4939311c67cf95de6ff836
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126943
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com >
2021-12-16 21:28:09 +01:00