summaryrefslogtreecommitdiff
path: root/desktop
AgeCommit message (Collapse)Author
2018-11-07lok: send signature status on document loadTomaž Vajngerl
Change-Id: If164d0edc9343b1db5ee96a2da46c9436ddbc73f Reviewed-on: https://gerrit.libreoffice.org/62776 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-11-06lok: trigger sign. verification in getSignatureState + update testTomaž Vajngerl
As the certificate chain can be added after the document was opened, we need to trigger signature verification every time the LOK API method getSignatureState is called. In addition update the tests so that they check the status of a document that's not signed, a document that was signed but the certificate chain is not available so the verification fails and later adding the certificate chain and the verification returns an OK status. Change-Id: I44578d0cece5bfc4a2e43fbbcd68b5ea1ccbc38b Reviewed-on: https://gerrit.libreoffice.org/62276 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-11-05tdf#121143: don't send OnCloseApp twice; properly cleanup AppBasicManagerMike Kaganski
The OnCloseApp event is being sent twice: first time in SfxTerminateListener_Impl::notifyTermination (in Desktop::terminate), and the second time in Desktop::doShutdown. The second event happens after application's Basic manager already was destroyed in SfxApplication::Deinitialize. The Basic provider, which holds a pointer to the manager, doesn't properly cleanup upon the manager's destruction, thus trying to use it after free. This removes the second (duplicate) generated OnCloseApp event, and makes BasicProviderImpl inherit from SfxListener to allow receiving the manager's SfxHintId::Dying notification. Change-Id: Iabf1432c41b1925b11b5a89e5fd8a6ae8249831e Reviewed-on: https://gerrit.libreoffice.org/62810 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-11-05lok: update the test for singing the document from LOKTomaž Vajngerl
Change-Id: Ie34d8c26bfbf4192cd2067c8315030903edb3fb3 Reviewed-on: https://gerrit.libreoffice.org/62274 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-11-03Create a CG bitmap context in doc_paintWindow(), too, for iOSTor Lillqvist
Just like in doc_paintTile(). Now at least some of the dialogs work in the iOS app, yay. Change-Id: I10c7eeb1f121ba68a1af723d45575890b1d598da Reviewed-on: https://gerrit.libreoffice.org/62800 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2018-11-03On iOS, lok_init_2() links directly to libreofficekit_hook_2()Tor Lillqvist
Thus no need for any special __attribute__ ((visibility("default"))) dance. Change-Id: I398d588a0165fd616ea0d259bbf2cab1e1a07ccb Reviewed-on: https://gerrit.libreoffice.org/62796 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2018-11-02fix signatures of deleted copy/assign operatorsNoel Grandin
Change-Id: Id1a0749b78a7021be3564487fb974d7084705129 Reviewed-on: https://gerrit.libreoffice.org/62718 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-11-02We now use a fixed name ICU data file in the iOS appTor Lillqvist
That makes it much easier to use the same Xcode project file when building against different versions of LibreOffice, with different ICU data files. The configure script in the "online" directory creates a ICU.dat symlink to the ICU data file (with a name like icudt60l.dat in a 6.0 branch, or icudt63l.dat in a current master) in the LibreOffice build directory, and that is what gets copied into the app bundle. Change-Id: Ibe2ca85f66e2d4973d6ba3c52fc4d60e113d8f9a
2018-11-01gbuild: rename value OS=IOS to OS=iOSMichael Stahl
This gets rid of the horrible hack in gbuild.mk to accomodate the case-incorrect iOS platform makefiles that cannot be renamed without upsetting git on file systems that sadly lack the case sensitivity feature. Keep the macro defined to IOS though. Change-Id: I1022bfef4900da00e75fc1ccce786b20f8673234 Reviewed-on: https://gerrit.libreoffice.org/62705 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2018-11-01clang-tidy: (WIP) bugprone-too-small-loop-variable findingsTamás Zolnai
Change-Id: Iaa255b39928ac45dec1ed37e368c149d6027f561 Reviewed-on: https://gerrit.libreoffice.org/62701 Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2018-10-31lok: new function to add certificate to certificate DBTomaž Vajngerl
Also needed to extend XCertificateCreator with a new method "addDERCertificateToTheDatabase". Change-Id: I7b4df65365893bd5a0628aeec30b3156584849fe Reviewed-on: https://gerrit.libreoffice.org/62273 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-10-31lok: Get the object shell from the documentTomaž Vajngerl
Change-Id: Id62c0db3c9f404aaab70de0a73a20b2bb57b0393 Reviewed-on: https://gerrit.libreoffice.org/62272 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-10-29lok: create certificate and private key with insertCertificateTomaž Vajngerl
Change-Id: Ie114068d9aec5259f9f7ed395c5dfeecf8bb787d Reviewed-on: https://gerrit.libreoffice.org/61915 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-10-29Remove unused parameterSamuel Mehrbrodt
Change-Id: I5b53e8d270f5b87cb3068943d35c17e1f041d1a5 Reviewed-on: https://gerrit.libreoffice.org/62497 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-10-29lokit: test for the new signing API functionsTomaž Vajngerl
Change-Id: I3ab2f3986955eb82451704fc2386b64f208da554 Reviewed-on: https://gerrit.libreoffice.org/61782 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-10-28lokit: add funct. to insert, sign and verify signatureTomaž Vajngerl
A lot of signing code paths trigger a GUI dialog (to select the certificate for example) which aren't acceptable when triggering through the LOKit. This code paths needed to be duplicated and reworked to not trigger any GUI action. Change-Id: I2f0d6038fb1bcd00adcdf86e432f9df8858cc21c Reviewed-on: https://gerrit.libreoffice.org/61780 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-10-28update old 'interface-requires' comments to <requires> tagCaolán McNamara
Change-Id: If7533650ae543f9d43a3a50fdfc137141fa64586 Reviewed-on: https://gerrit.libreoffice.org/62444 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-27possible fix for issue 120928 - quickstart --killtray throws exceptionbrinzing
Change-Id: Id4081439075f4beecc2b0e4aed035d5ee28a2cfd Reviewed-on: https://gerrit.libreoffice.org/62429 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins
2018-10-27tdf#120703 PVS: V530 The return value of function is required to be utilizedMike Kaganski
Change-Id: Ifc170a45e25b3fd5b7f561cc50afb6452bb359bd Reviewed-on: https://gerrit.libreoffice.org/62420 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-10-26unopkg: Make logging to default location work againSamuel Mehrbrodt
Change-Id: Ie0b476164b370f58e0b220cee56ed52896753ade Reviewed-on: https://gerrit.libreoffice.org/62394 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-10-26unopkg: Log deployment output with the same logger as unopkgSamuel Mehrbrodt
This prevents overwriting the existing logfile by using the same logger as unopkg does. Change-Id: Iaad4c5b99a4f428d3a4ad8a046c88404aecb5652 Reviewed-on: https://gerrit.libreoffice.org/62393 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-10-26unopkg: Write to console when no UNO availableSamuel Mehrbrodt
Change-Id: I159b7e85f53e33c5359cca83aa958387d888f6a2 Reviewed-on: https://gerrit.libreoffice.org/62391 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-10-26Introduce SimpleTextFormatter and format unopkg output using itSamuel Mehrbrodt
This will write log messages as plain text (no timestamp and other stuff like PlainTextFormatter). Warnings and errors will be prefixed accordingly. Change-Id: Id82512d7dd3907a4c7cd69a963a375966189dc20 Reviewed-on: https://gerrit.libreoffice.org/62370 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-10-26Log unopkg errors to log file if requestedSamuel Mehrbrodt
Before only the output generated by extension add/remove/... functions were logged to file, but not the error messages of unopkg itself. Change-Id: I4451aa51e2877ae48c453ee4791e36d970832567 Reviewed-on: https://gerrit.libreoffice.org/62369 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-10-25The 2nd parameter to lo_initialize() is a URL so use such naming consistentlyTor Lillqvist
Change-Id: Id4e7f8556d6910ab43b0f7b8ba09e7be8b1ec1d1
2018-10-24remove more rtl::OUString and OString prefixesNoel Grandin
which seem to have snuck back in since the great rounds of removals. Change-Id: I85f7f5f4801c0b48dae8b50f51f83595b286d6a1 Reviewed-on: https://gerrit.libreoffice.org/62229 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-23remove all use_action_appearance linesCaolán McNamara
Change-Id: I031676e939f53a28b1a62654ffe0a91b95dea029 Reviewed-on: https://gerrit.libreoffice.org/62234 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-23clang-tidy performance-unnecessary-copy-init in dbaccess..drawinglayerNoel Grandin
Change-Id: I49a152b2aea93d30b16192260f4f659c7e5fcaee Reviewed-on: https://gerrit.libreoffice.org/62215 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-22Put quotes around a URL in a message to make it more obvious if it is emptyTor Lillqvist
Change-Id: I03fe3f70ee97066d9c2083d4ef091c501f241392
2018-10-22If we have encountered a "FATAL ERROR" we can afford writing a line to stderrTor Lillqvist
There is no guarantee that if something is wrong, the Application::ShowNativeErrorBox() will manage to show anything, is there? And this code might be invoked in a program that doesn't even have any GUI. So at least try to show the message on stderr, too. Change-Id: Ieb11a6f490c26c773af646ed7e9c3cf6ccb4a669
2018-10-22tdf#120249: fix escaping to handle quotes and multiple trailing backslshesMike Kaganski
Follow-up of commit f4103a42d58535e21c48ff94ab000ab0305c62e3 Change-Id: I4562386d3151875dff8e9eddf31c4af3333cefb7 Reviewed-on: https://gerrit.libreoffice.org/61245 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-10-22Sync extension registration on startupSamuel Mehrbrodt
There are cases where the extension registration becomes invalid (empty rdb files) which leads to extensions not starting up, although installed and active. Syncing extension repos on startup fixes that. The performance impact is negligible (1ms in my measurements). Change-Id: I10475ce6a054b43c4591b17a8486648ca6a30068 Reviewed-on: https://gerrit.libreoffice.org/61943 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-10-21tdf#120703 (PVS): handle failed (re)allocationsMike Kaganski
V769 The 'readBuf' pointer in the 'readBuf + readAll' expression could be nullptr. In such case, resulting value will be senseless and it should not be used. Check lines: 171, 166. V701 realloc() possible leak: when realloc() fails in allocating memory, original pointer 'readBuf' is lost. Consider assigning realloc() to a temporary pointer. Change-Id: I2e15a1abb79516dd42d64256463333bb54eab5b8 Reviewed-on: https://gerrit.libreoffice.org/62117 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-10-19clang-tidy readability-container-size-emptyNoel Grandin
Change-Id: I1df70b7dff5ebb6048f7fc618789faa15ca5d422 Reviewed-on: https://gerrit.libreoffice.org/61967 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-19clang-tidy readability-misleading-indentationNoel Grandin
Change-Id: I4673fc7c694924b41d048a1918ddb8b0e0af1f79 Reviewed-on: https://gerrit.libreoffice.org/61935 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-18clang-tidy readability-simplify-boolean-exprNoel Grandin
Change-Id: I78fa01a6c803dec782488490b730af3a11814d64 Reviewed-on: https://gerrit.libreoffice.org/61902 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-18Need <rtl/strbuf.hxx> for the !HAVE_FEATURE_EXTENSIONS case, apparentlyTor Lillqvist
Change-Id: I3d3c31f785ae2969660c95425419ef9fe5b893c3
2018-10-17loplugin:staticvar in cppuhelper..desktopNoel Grandin
Change-Id: I21cf6bafab6e865b90b29caa73183a8e00b538d1 Reviewed-on: https://gerrit.libreoffice.org/61865 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-17clang-tidy readability-redundant-smartptr-getNoel Grandin
redundant get() call on smart pointer Change-Id: Icb5a03bbc15e79a30d3d135a507d22914d15c2bd Reviewed-on: https://gerrit.libreoffice.org/61837 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-12tdf#119739 split ConfigManager::getLocale(), getUILocale(), getWorkLocale()Eike Rathke
To prevent further confusion which is which, dbaccess UserInformation already got that wrong since ever. /org.openoffice.Setup/L10N/ooLocale is the UI locale. /org.openoffice.Setup/L10N/ooSetupSystemLocale is the work locale. Confusingly due to legacy when the setup program was a separate binary that picked the UI ooLocale and later set up the default (system) work locale as well. Change-Id: I9a05ad39f5fb65c54076ff5789ba7a2cc06ad23a Reviewed-on: https://gerrit.libreoffice.org/61725 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins
2018-10-12Conditional formatting: Allow to set the icon set CF via .uno: command.Jan Holesovsky
When .uno:IconSetFormatDialog gets a parameter, it directly creates the icon set conditional formatting with pre-selected values. Change-Id: I75dda90e5ea9c191254acc24c564cda7b27243a5 Reviewed-on: https://gerrit.libreoffice.org/56429 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Miklos Vajna <vmiklos@collabora.co.uk> Reviewed-on: https://gerrit.libreoffice.org/61669 Tested-by: Jenkins Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2018-10-12Make sure the UserInstallation/user directory exists on iOS (and Android)Tor Lillqvist
If it doesn't exist lots of things go very badly. Took a while for me to understand the mechanism, sigh. Change-Id: I40300587a5f422876cbda68c5aa98a23ed707135
2018-10-10Move the iOS CGBitmapContextCreate() call do doc_paintTile()Tor Lillqvist
Thus it now actually takes a buffer pointer also on iOS, like on Linux and Android. Less confusing, more uniform. Add a separate iOS-specific paintTileToCGContext() method to LibreOfficeKitDocumentClass that takes a CGContextRef. Adapt callers correspondingly. (The LibreOfficeLight code in particular needs the paintTileToCGContext().) Change-Id: I81084806d37b9aac9f2b2bc03d0c262e991eec81
2018-10-09Extend loplugin:redundantinline to catch inline functions w/o external linkageStephan Bergmann
...where "inline" (in its meaning of "this function can be defined in multiple translation units") thus doesn't make much sense. (As discussed in compilerplugins/clang/redundantinline.cxx, exempt such "static inline" functions in include files for now.) All the rewriting has been done automatically by the plugin, except for one instance in sw/source/ui/frmdlg/column.cxx that used to involve an #if), plus some subsequent solenv/clang-format/reformat-formatted-files. Change-Id: Ib8b996b651aeafc03bbdc8890faa05ed50517224 Reviewed-on: https://gerrit.libreoffice.org/61573 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-10-09Fix typosAndrea Gelmini
Change-Id: Ia2aca4e87054d2f5cc0462e07ac0717278d3c98c Reviewed-on: https://gerrit.libreoffice.org/61577 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2018-10-08desktop: move font initialization into preloadDataAshod Nakashian
Reviewed-on: https://gerrit.libreoffice.org/57160 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com> (cherry picked from commit bbba0902fc1f1c6bb2a7f1e6ff2b682e2fbd3cc9) Change-Id: I66840512b45e987cc7b08b07b65bdb24f2023a41
2018-10-08desktop: move dictionary preload before font initAron Budea
spell-checker is initialized during font init since e7f65920b12517b31f0c5cbfd0dcb8df96d20ba4 Change-Id: Ia5b5223aa8cc00d0e80451142ae18a7046ad00d4 Reviewed-on: https://gerrit.libreoffice.org/57064 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2018-10-08desktop: initialize fonts in pre-initAshod Nakashian
Reviewed-on: https://gerrit.libreoffice.org/56573 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com> (cherry picked from commit e7f65920b12517b31f0c5cbfd0dcb8df96d20ba4) Change-Id: I5a3acc41196c7e0672514fa2dae00e5fc0f76a1f Reviewed-on: https://gerrit.libreoffice.org/61492 Tested-by: Jenkins Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2018-10-05We should call pDevice->SetBackground(Wallpaper(COL_TRANSPARENT)) also on iOSTor Lillqvist
Change-Id: Id42d3b84ab97ec1efd9551e4d9cc5fd16ab77c80
2018-10-05Call SetOutputSizePixel() in the iOS case, tooTor Lillqvist
Change-Id: I844901f38ec1d93f4183e0678741fecdc7636139