summaryrefslogtreecommitdiff
path: root/desktop
AgeCommit message (Collapse)Author
2024-07-14cid#1608572 silence Overflowed integer argumentCaolán McNamara
try to convince coverity of the errors of its ways Change-Id: I4e847f3773931dccaff1724166072bfde0b97941 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170438 Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-13cid#1610240 Unchecked dynamic_castCaolán McNamara
Change-Id: Iee9088344bb3319b751bc3c611ad0ab5e42374b3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170434 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-12SW: exctract document structureAttila Szűcs
It extract form controls, and write its data to JSON. It is a basic 1. version, for now it only recognize: -PlainText (and write its text) -CheckBox (and write its state) but it writes some common data for any type of controls: ID, alias, Tag, TabIndex, and its index. Change-Id: I9ff74cd013c6f1118942207059181678713504af Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170381 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2024-07-11fix locking in UpdateRequiredDialogNoel Grandin
Ever since commit 838036c304d474fc4c19e2fc59cadc6ba457c9ee Author: Noel Grandin <noel.grandin@collabora.co.uk> Date: Tue Mar 7 13:46:29 2023 +0200 osl::Mutex->std::mutex in UpdateRequiredDialog Calling from disableAllEntries, which takes a mutex, to hasActiveEntries, would deadlock. Noticing that this class is trying to use a mix of the SolarMutex and its own mutex, rather just use the SolarMutex everywhere, which is much safer, and not a problem in a place where performance is not an issue Change-Id: Id241c3b811f314d75de03c4c647c0594b8d498bb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170283 Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-07-10Properly implement cppu::throwException for EmscriptenStephan Bergmann
...by implementing (for now) just enough of the cpp2uno half of the Wasm UNO bridge to make it work. In general, that half suffers from the same issue as the already-implemented uno2cpp half, namely that Wasm doesn't allow to generate code on the fly (which, in this case, would be needed to implement the vtable slot trampoline functions). So, for now just hard-code the few vtableSlotFunction_* that are needed by the UNO interfaces for cppuhelper/source/exc_thrower.cxx. (A proper fix would probably use the same approach as for the uno2cpp half, and use something like wasmcallgen to generate at least all the vtableSlotFunction_* needed for udkapi/offapi upfront.) The RTTI for the exceptions needs to be unique across the executable for exception catching to actually work (as it compares exception types by RTTI address rather than by name). We thus need to export all the relevant RTTI symbols (which I hacked into the existing wasmcallgen for now, even if that makes that executable's name a slight misnomer now), and access them with a new jsGetExportedSymbol. (This exporting would also be needed by the "classical" approach of using dlsym on the main module, cf. <https://gerrit.libreoffice.org/c/core/+/167187> "WIP: Emscripten: Set up support for dlsym from main module". And while that dlsym approach would work, it is much simpler to just use that jsGetExportedSymbol than to use a dlsym detour, and thereby avoid all the hassle of -sMAIN_MODULE detailed in the commit message of that Gerrit change.) It also turned out that including Emscripten's <cxxabi.h> needs __USING_WASM_EXCEPTIONS__ to be defined, because it uses that in its declaration of __cxa_throw. (The source for setting that define internally in Emscripten is get_cflags in the emsdk's upstream/emscripten/tools/system_libs.py, which defines __USING_EMSCRIPTEN_EXCEPTIONS__ for the non-Wasm, Emscripten JS exception mode, and defines __USING_WASM_EXCEPTIONS__ for --enable-wasm-exceptions, which we use. The commit message of f4ec967599f5dafa1ce477631d7c2e8de005e28f "Fix redefinion of Emscripten __cxxabiv1::__cxa_exception" documents my prior confusion of when one or the other would be defined.) Change-Id: Id08765ab5b4ce1553dc3a61648324526185cb64c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170246 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-07-10lok: expose presentation info and slide render functionsMarco Cecchetti
This exposes the (impress only) function to get the current presentation info in JSON format and the slide rendering functions that enable rendering of slide layers to a bitmap. Change-Id: Id0591d5894f730eae48b3edc986ae5d804ce7c81 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170263 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2024-07-09cid#1554685 COPY_INSTEAD_OF_MOVECaolán McNamara
Change-Id: I9014693a2baa5dfe727e925f2aae170c11f4b8fc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170188 Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-09valgrind: dhat is no longer experimentalDr. David Alan Gilbert
The valgrind dhat plugin is no longer experimental as of valgrind commit 441bfc5f5 in 2018, update the switch. Signed-off-by: Dr. David Alan Gilbert <dave@treblig.org> Change-Id: Iba74eeed1cc5e2350d715454bf32192e0bc3692b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170072 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> Tested-by: Jenkins
2024-07-08cid#1555801 Unchecked return valueCaolán McNamara
Change-Id: I2fbc0b65b081da5776c49962ff3b6a36b76808da Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170128 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-03cid#1607891 Dereference after null checkCaolán McNamara
Change-Id: Ie446d2623ca41254e3f72ac05f3f090265af48ed Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169920 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-06-29Fix "lets" -> "let's"Andrea Gelmini
Change-Id: I3f55e97561323cff8a4148d8388ecd3a5550c704 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169753 Tested-by: Jenkins Reviewed-by: Andrea Gelmini <andrea.gelmini@gelma.net>
2024-06-24Resave with newer Glade versionBogdan Buzea
Change-Id: I66bcfe5859bfc9f89cfcd8fc11e0ce6532e3eeb7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169387 Tested-by: Jenkins Reviewed-by: Taichi Haradaguchi <20001722@ymail.ne.jp>
2024-06-18loplugin:ostr in variousNoel Grandin
Change-Id: I7aa8ed716998a185996482dc561219b398a1c919 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169080 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-06-17Add new LOK CALLBACK for vertical rulerDarshan-upadhyay1110
- We're adding a new LOK callback LOK_CALLBACK_VERTICAL_RULER_UPDATE. - The reason is that we currently override the existing callback. - Using the same callback for both vertical and horizontal rulers causes an issue. - override will create problem like it will only send any one of the ruler orientation update. - It results in online updates being limited to just one ruler orientation. - By introducing a new callback, we ensure updates for both vertical and horizontal rulers both are captured correctly in online. Change-Id: I02d0e3e7e4ac8a07a83644460aa0ba36e0f3c013 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167481 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> (cherry picked from commit 11b936629dd4ef9308d63b312900b8b7c8ff19b4) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167464 Tested-by: Jenkins
2024-06-15tdf#35568 Repeat "first run" procedure on upgradeMike Kaganski
1. In isProductVersionUpgraded, if it was upgraded, set FirstRun. This will run in runGraphicsRenderTests, early enough in Desktop::Main(). 2. This will make sure that Desktop::CheckFirstRun() will do its tasks, including creation of the quickstart shortcut. It is simplified a bit, to use a better WinAPI. 3. Setting FirstRun to false is moved to m_firstRunTimer's handler, to make sure that it gets run eventually, even if the first launch was terminated before the timer fired. This will not make installer itself create the quickstart shortcut: it will happen on the program's first run after an upgrade. But users now won't have to enable the option manually each time. Change-Id: Ica6cc41f1e56b8970db27d14e2be3c47910293e3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168902 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins
2024-06-12Embind: Centrally initialize via Module.initUno() in a new uno.jsStephan Bergmann
...so that the unoObject function can be moved there too (so that other code outside embindtest.js can reuse it) Change-Id: Id3edb7cede56321db29ba435f221cb7702a3513c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168700 Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de> Tested-by: Jenkins
2024-06-11LOK: do not use deprecated .uno:BackColorAndras Timar
.uno:BackColor was deprecated in be3d34b5d6b97c3eb12ab3f84ce2da2ef965a928 which changed the label to "Character Highlighting Color (deprecated - use CharBackColor)" We do not want this label to appear in LOK based product. The corresponding online patch set: https://github.com/CollaboraOnline/online/pull/9225 Change-Id: Ieb780d278cd45bf82a2b4acee0abd17af2dc71eb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168519 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Miklos Vajna <vmiklos@collabora.com> (cherry picked from commit db27cd2246cfc54abd94885ce5edbdca69688af0) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168616 Tested-by: Jenkins Reviewed-by: Andras Timar <andras.timar@collabora.com>
2024-06-07Make Embind-related code also available under --disable-dbgutilStephan Bergmann
...and just keep embindtest.js --enable-dbgutil--only. For convenience when using EMSCRIPTEN_EXTRA_SOFFICE_POST_JS recently introduced in 82640810efd1636e358c047a1a5b3e4e3fc9d28a "New EMSCRIPTEN_EXTRA_SOFFICE_POST_JS configure variable". Change-Id: I03311d89ff14a70f84e03e99ab8e609641ea589b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168552 Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de> Tested-by: Jenkins
2024-06-07New EMSCRIPTEN_EXTRA_SOFFICE_POST_JS configure variableStephan Bergmann
...which can be useful during development, to add e.g. additional test code to the generated qt_soffice.html Change-Id: Ic498dcd4c812b7b4c8e48b07c2bff411a9f19438 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168522 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-06-06mar: use OS version in User-AgentChristian Lohmaier
this will allow the server to handle cases when we have to drop support for older versions of Windows for example Change-Id: I13f85a97179df6aa91e00853dbf6576d78854061 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168152 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Jenkins
2024-05-31Make sure updates dir exists when writing updating.logStephan Bergmann
Change-Id: Ib652fedde970d01b701ad4b61e75028cd43974f6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168258 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-05-31Consolidate on a single Updater::log overloadStephan Bergmann
Change-Id: Id812788f30ac4a327d450255cfe19181c69ae81e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168257 Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de> Tested-by: Jenkins
2024-05-30cool#9174 - Enable .uno:ChangeBezierHubert Figuière
This allow Convert to Curve in COOL Signed-off-by: Hubert Figuière <hub@collabora.com> Change-Id: Id1aa0bc68238ac29221edb1c1ec7dda6e16ce103 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168170 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> (cherry picked from commit c5a7ff366fd9094c3ee1aba4c016b59c5635ea9b) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168194 Tested-by: Jenkins
2024-05-28tdf#161048 Revert "move opencl check at startup inside its own thread"Noel Grandin
This reverts commit 7d1242b01d3ad9be1cfcf2bd3fbee9ce63dddddf. Intel's OpenCL driver gets stuck during shutdown and blocks the process from exiting Change-Id: I0e1360fd183dacd7331e1dd4122154d705f567fa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168067 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins
2024-05-28Emscripten: Add hack to prepare for --enable-wasm-exceptionsStephan Bergmann
(...which will be beneficial, in turn, to implement exception handling in the work-in-progress bridges/source/cpp_uno/gcc3_wasm UNO bridge). Once setting --enable-wasm-exceptions, plus the corresponding -sSUPPORT_LONGJMP=wasm in qt5, I indeed started to see the "RuntimeError: null function or function signature mismatch" that was already mentioned in static/README.wasm.md. I could track it down to the early destruction of the aDesktop local variable in soffice_main, as I now explain there. However, it beats me why that variable gets destroyed early. The desktop::Desktop::~Desktop dtor claims to be called from within main -> soffice_main -> desktop::Desktop::~Desktop, but at a time when the call to main -> soffice_main -> SVMain has not yet returned. There also does not appear to be any C++ exception handling stack unwinding going on. (It could be related somehow to -sSUPPORT_LONGJMP=wasm, I don't know.) And everything appears to just work fine after turning that aDesktop local variable into a (leaked) heap instance instead, so go with that hack for now... Change-Id: I8e00c988ee9a44fd3befbe41c844eec050f0e509 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167694 Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de> Tested-by: Jenkins
2024-05-23lok: stop amazing waste of repeated font sizes in each font element.Michael Meeks
These days all sensible fonts are scalable, so anything else is madness. With the compact_fonts option we go from: INCOMING: commandvalues: {"commandName":".uno:CharFontName","commandValues": {"Albany AMT":["6","7","8","9","10","10.5","11","12","13","14","15","16", "18","20","21","22","24","26","28","32","36","40","42","44","48","54", "60","66","72","80","88","96"],"Amiri":["6","7" <truncated 58,418 chars> INCOMING: commandvalues: { "commandName": ".uno:CharFontName", "FontNames": [ "Albany AMT", "Amiri", "Amiri Quran", "Amiri Quran Colored", "Andale Mono", "Andale Sans", "Andy MT", "AR PL UMing CN", "AR PL UMing HK", "AR PL UMing TW", "AR PL UMing TW MBE", "Arial", <truncated 6,948 chars> An 8x size win. Change-Id: I3dc9f5de876def6e4afc09a43105b1740f7c621f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167799 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> (cherry picked from commit 628f56a1802ad76cbe84a9a5590b04ed81a57a9e) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167962 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2024-05-23lok: stop amazing waste of pretty-printed JSON sent over the API.Michael Meeks
before: INCOMING: commandvalues: { "commandName": ".uno:CharFontName", "commandValues": { "Albany AMT": [ "6", "7", "8", "9", "10", "10.5", "11", "12", <truncated 199,811 chars> after: INCOMING: commandvalues: {"commandName":".uno:CharFontName","commandValues": {"Albany AMT":["6","7","8","9","10","10.5","11","12","13","14","15","16", "18","20","21","22","24","26","28","32","36","40","42","44","48","54", "60","66","72","80","88","96"],"Amiri":["6","7" <truncated 58,418 chars> A 3x size saving. Change-Id: I574b8bdf790078c61b7605137a47a531dee16f1e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167685 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins
2024-05-20Drop remnants of a long-obsolete hackMike Kaganski
In commits 6dd5a96e1e3a6bb307f8f2d43cce2b5f2cde659d (INTEGRATION: CWS unopkg1 (1.1.2); FILE ADDED, 2004-04-14), 19a10039a59002b68291e7f200f85fd962592d75 (INTEGRATION: CWS unopkg2 (1.2.4); FILE MERGED, 2004-06-11), and 886715b6b6f30fed36d50a4ddf84ed5984f4f993 (INTEGRATION: CWS scriptingf7 (1.3.4); FILE MERGED, 2004-07-23), a hack was introduced to allow empty substorages. Later, in commits 0d6b24a721f05fedef9cd32b596a0fec71a5089f (INTEGRATION: CWS tdoc3 (1.7.24); FILE MERGED, 2004-11-09) and 5f4d17724f7323077191114486edff8cdce05b2f (INTEGRATION: CWS scriptingf9 (1.6.2); FILE MERGED, 2004-12-23), that hack was removed, but one place was kept, which is removed now. Change-Id: Iaaf46421ddbe942878ebe17ca1e585be9db5999d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167823 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-05-20tdf#69192 fix cmdlinehelp: --show[=slide_number], etc.Justin Luth
I had skimmed the help file earlier, and concluded that { } are used elsewhere to indicate optional paramaters. However, there is --quickstart[=no], and -env:<VAR>[=<VALUE>] which exactly match my optional addition. Thanks Stéphane for pointing this out. Also included are some other changes we made to clarify the help wording in general, so the documentation and the cmdline help are in sync. We dropped Files other than Impress documents are opened in default mode, regardless of previous mode. because: -from an initial reading it doesn't convey any useful meaning. -searching for other uses of "mode" in the file suggests it means that prior --print/--convert-to/--view modes no longer apply. This override of prior modes is true for all modes, but only this argument tries to spell this out. -it seems rather inconceivable that any user would attempt to mix --show with any other arguments or more than one file. Change-Id: I191e572506cf2b39ed6c9ff4ebaf66f258a176a1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167633 Tested-by: Jenkins Reviewed-by: Justin Luth <jluth@mail.com>
2024-05-18lok: dump more SfxViewShell state, and LOK notifier state on Windows.Michael Meeks
This should help to associate the right view-ids, with the right windows, and help to catch any stray / lingering windows from closed sessions - hopefully. Change-Id: I197a3280d5d2aeddd356ee037c51e4887f43278b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167765 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> (cherry picked from commit 8d979fae0c435b820302c76fcfdc2642b4820360) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167684 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2024-05-17WaE: C6011 Dereferencing NULL pointer warningsCaolán McNamara
Change-Id: Ic67e884555517620acb6d43bafc28e8291720913 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167770 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-05-17Revert "tdf#109347: don't verify SSL certificate for crashreport upload"Thorsten Behrens
With recent improvements in libcurl CA usage on Linux, this workaround is no longer needed. See also 11f439b861922b9286b2e47ed326f3508a48d44e This reverts commit ec4229bc49a315f3f17664bb43e61d3b2e13fb87. Change-Id: I09124691687297f3b6ae0b9ca64652809caf3a11 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167752 Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de> Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2024-05-15lok: get faster ModifiedStatus from the core.Michael Meeks
Gives a more responsive UI, closes a number of races, and helps us to make better decisions, more quickly on whether to save. Change-Id: I6e2548f06f715ba56ba75fd746273bdd57dc20dd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167635 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> (cherry picked from commit 44e79f02241fbc213462df03a37b621cb72f9d05) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167469 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2024-05-15tdf#70526 Provide start up time measurementsVenetia
Added support for measuring the start up time between each Splashscreen update. Change-Id: Id38058c89c8524d782bf15cd956c8fba5de056de Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163965 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-05-12jsdialog: enable Object Name and Description dialogSzymon Kłos
and send uno command enable/disable status Signed-off-by: Szymon Kłos <szymon.klos@collabora.com> Change-Id: Id643a27308809b6960be72fb368b9f078ff9cf6c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167296 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167521 Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-05-08drop requirement for rtl_random_getBytes to have "Pool" argCaolán McNamara
Seeing as since: commit e9531b792ddf0cfc2db11713b574c5fc7ae09e2c Date: Tue Feb 6 14:39:47 2024 +0100 sal: rtlRandomPool: require OS random device, abort if not present Both rtl_random_createPool() and rtl_random_getBytes() first try to get random data from the OS, via /dev/urandom or rand_s() (documented to call RtlGenRandom(), see [1]). we don't use the initial arg to rtl_random_getBytes anymore, drop the requirement to have one. Then simplify our usages of that, and addtionally deprecate rtl_random_createPool and rtl_random_destroyPool. Change-Id: I13dcc067714a8a741a4e8f2bfcf2006373f832c4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167067 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-05-08flush CallbackFlushHandler queue via PostUserEvent instead of Idle+TimerCaolán McNamara
Looking at when Invoke was called from Idle (or from auxiliary Timeout if there was no chance to run the Idle within 100ms) and when duplicate merging and modification of the queue is done before getting dispatched and cleared; Then the pattern is that duplicates are collected and merged during the current block of events to be processed, and dispatching the flush via PostUserEvent instead gives the same results. During startup, scheduling via PostUserEvent drops the need to have the aux timeout, and while the number of messages seen in the first queue flush (now via PostUserEvent instead of 100ms Timer) remain the same as before, subsequent queue flushes can get processed earlier while smaller, though typically at the same time as before once the document is fully loaded. Change-Id: I64c6bbc3dea9fb3a512c2a9521303a8f143d4a89 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167064 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167307 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-05-08tdf#69192: add StartingSlide to SID_PRESENTATION and cmdline show=Justin Luth
Allow the user to start the presentation at a specific slide using command-line parameters. This patch depends on the previous variable renaming patch. Change-Id: I87797cbccb463904e5d2fe9b078e3921be27c91a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167066 Tested-by: Jenkins Reviewed-by: Justin Luth <jluth@mail.com> Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2024-05-08NFC dispatchwatcher.hxx: rename aPrinterName to aParamJustin Luth
It is rather confusing to have a generic parameter variable named aPrinterName. I'm going to use that in my patch, so first clean it up separately. Change-Id: I3e73eeddbc506d369ba5d6e2b569d30eef78bfb6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167059 Tested-by: Jenkins Reviewed-by: Justin Luth <jluth@mail.com> Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2024-05-07workaround compiler crash on macos-intelNoel Grandin
Change-Id: I779785c068fd04e314b4d6c22d9fe66d9aa88736 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167294 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-05-07loplugin:ostr in desktopNoel Grandin
Change-Id: Ib43d1c3a182badddd870bcb8e052ac7fd0a16fc5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167270 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-05-07WaE: C6011 Dereferencing NULL pointer warningsCaolán McNamara
Change-Id: Iaef14644b8d9fa0c26de39871e9352d5d79ebb08 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167248 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-05-07lok: reseed comphelper's random number generator on fork.Michael Meeks
Also avoid std::random_device it doesn't work in a COOL kit process. Change-Id: Ie2d063611a73e734afd92d6fd779f34a2f316230 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167070 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2024-05-07move opencl check at startup inside its own threadNoel Grandin
shaves 30% off the startup time for me. Change-Id: Ibabb2a6b283243aaaaafb8257e99e82e2ef112c4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167100 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-05-03makefile simplification: replace $(call gb_CustomTarget_get_workdir,foo)Christian Lohmaier
…by a simple/static $(gb_CustomTarget_workdir)/foo The build system has a lot of overly complicated leftovers from when it was introduced and had not only deal with split repositories but also had to coexist with another buildsystem. Along with lots of copy'n'paste along the years the makefiles became hard to grasp for newcomers with all our calls and evals. As a first step to streamline that, the macros from TargetLocations that simply prefix a static path to the argument (and similar of the same kind) are a natural pick before simplifying the rules themselves/getting rid of a bunch of eval statements. Change-Id: Ia06dbbcd5d1994755a2ff05b84f72ccbc4e3cab5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167005 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2024-05-03Simplify conditionStephan Bergmann
...after this got wrapped in an outer > ifeq ($(OS),EMSCRIPTEN) in cf0b0f0dd04fae98b686cd5768673c217a58fab6 "Emscripten: Only add the --pre-js code to the soffice executable" Change-Id: Ic2b9ae7709a06146a206ebaa2ee8881387dae6b1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166998 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-05-02WaE: C6011 Dereferencing NULL pointer warningsCaolán McNamara
Change-Id: I8edb1fefe1b2b8a3db3ee8f3a0eed59c7f08a36e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166863 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-05-01next is never passed a null pointer, use a referenceCaolán McNamara
Change-Id: I6d57e6a7f746a05017c6f93ef434a234716259c2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166965 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-05-01Use a for loop for setting view properties.Gökay Şatır
Since there may be no view with the given id, checking the list first is safer. Signed-off-by: Gökay Şatır <gokaysatir@collabora.com> Change-Id: I4c305e0a0f6ce7cccdfea9889c414a6054ed3a88 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166531 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> (cherry picked from commit 4d8c4a60105488be84ea80775dc04a24582752fb) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166720 Tested-by: Jenkins
2024-05-01WaE: C6011 Dereferencing NULL pointer warningsCaolán McNamara
Change-Id: Ic2231df89b900c17beac4627e3573b45aef0bc26 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166954 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>