summaryrefslogtreecommitdiff
path: root/extensions
AgeCommit message (Collapse)Author
2022-05-31tdf#149096: don't translate "Get" and "Post" submit methodsJulien Nabet
Change-Id: I4427618dad0c168642225eaaf828a96e37936d8f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134718 Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr> (cherry picked from commit 93b4191cefa5062b120c77335776beee34ee4392) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134789 Tested-by: Jenkins Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2022-04-01Resolves: tdf#117159 don't crash with chart selected in database report editCaolán McNamara
Change-Id: I770008bf0a775c108019c2005b6ec73ee9702a19 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132190 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-11-25remove unused defines and convert some to OUStringLiteralNoel Grandin
Also remove the associated links.txt entries Change-Id: I5028fab2feb828875a0b772418fc29cbdfe4ce72 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125773 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-25loplugin:stringliteraldefine in extensionsNoel Grandin
Change-Id: I9599fb3ca2fdcb30d8e1a52ecbfd954329762eae Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125762 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-24loplugin:stringliteraldefine in comphelperNoel Grandin
Change-Id: I60ccd6049db65fef2397798ab916b0d1e24c0fdc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125531 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-23O[U]String::replaceAt overloads that take string_viewNoel Grandin
which results in lots of nice string_view improvements picked up by the plugins Change-Id: Ib0ec3887816b3d4436d003b739d9814f83e244b2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125657 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-20Don't loose scanned image's resolution precisionMike Kaganski
Change-Id: I526dcf8db880615308cfb228eaa06d1a5a0e5cac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125584 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-20Drop unused variables - againMike Kaganski
This re-instates commit a339ebca55f53db5f0b72b26fcfbb3aaa2b2a825 "Drop unused variables", that was accidentally reverted in commit 1b6e3efe964eec9110e656a8242f6f4d8b5e7f7e "Simplify m_aAppId initialization". Change-Id: Ib65500cc0b0b5c27425f76e358f2d786a7faac09 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125583 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-20Use o3tl::convertHossein
Used o3tl::convert on nXRes and nYRes to calculate biXPelsPerMeter and biYPelsPerMeter for the bitmap information header structure pBIH: https://docs.microsoft.com/en-us/windows/win32/api/wingdi/ns-wingdi-bitmapinfoheader The values of biXPelsPerMeter and biYPelsPerMeter are always ignored by the GDI when loading the bitmaps, but in theory they can be recommendations for the pysical size of a bitmap in some applications. https://devblogs.microsoft.com/oldnewthing/20130515-00/?p=4363 Change-Id: Ia40f17b7d1c27c094158af89bf15ed2f11bdfc05 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125109 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-19Fix --enable-online-updateStephan Bergmann
...after 4bc44490f51f7cc4a36cc7131137018da986c293 "loplugin:stringliteraldefine in tools" Change-Id: I0ec1e07b151e853be8a795c7135aecf5c6957eac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125556 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-11-19gtk3: default to an explicit constrain-to for PopoversCaolán McNamara
with the intent to do the same replacement with GtkWindow under X11 for gtk3 that we do in MenuButtons for the popover with direct popovers when the constraint is GTK_POPOVER_CONSTRAINT_NONE Change-Id: I629c30b44a9e362ba0d924bb229930b5f0dc7ed3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125540 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19loplugin:stringliteraldefine in toolsNoel Grandin
Change-Id: I348b9a844c009f9c19301baa76d31b12f67c6130 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125535 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-13Simplify m_aAppId initializationMike Kaganski
Change-Id: Ib760edab95e988b78505de256aba1b09213600fe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125127 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-13Drop unused variablesMike Kaganski
nWidth/nHeight (1) are irrelevant here (we get the correct pixel size right in the hDIB), and (2) should not be -1, because we don't use ICAP_UNDEFINEDIMAGESIZE capability [1]. [1] https://twain.org/wp-content/uploads/2017/03/TWAIN-2.4-Specification.pdf#page=268 Change-Id: I8cb20087944536552326b3e1582e8ef12dcc0d32 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124986 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-03Add back `== 2`Stephan Bergmann
...that got lost in 23c8da878529f85ba5045db6f7ea7956a64dfc72 "put the message into static_assert" (causing a loplugin:consttobool warning) Change-Id: I8f2a97bd61edbfad0c871c0d2d0e25f1ce9f9f98 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124658 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-11-03put the message into static_assertCaolán McNamara
and use more static_assert where its obviously possible Change-Id: I9466130809acab12505f0760f970793991564165 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124633 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-31uniformly allow focus into GtkToolbarCaolán McNamara
Change-Id: I110daf882d9196cf7552e43a157ba4ae73fd670b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124458 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-31gtk[3 vs 4]: remove can-focus from GtkToolButtonCaolán McNamara
so tab-cycling inside sidebar panel toolbars works as wanted It needs to be false for gtk3 and true for gtk4, leaving it unspecified gets a desired working default. Change-Id: I34869d5dcffc814f62ec2b717108f90c395a067b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124446 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-30Prepare for removal of non-const operator[] from Sequence in extensionsMike Kaganski
Change-Id: Id57b187aaa669d4b9a35ab726a6df1a9b4823f1d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124364 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-10-22return weld::Builder by unique_ptrNoel Grandin
Change-Id: Ifa4f5951d200eaad6c8aebd3f29eed053c927ff0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124051 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-10-22Optimize assignment from OUStringLiteral to OUStringStephan Bergmann
...by making the OUString's pData point to the OUStringLiteral, instead of copying the contained characters. This is one of the improvements that had not been done as part of e6dfaf9f44f9939abc338c83b3024108431d0f69 "Turn OUStringLiteral into a consteval'ed, static-refcound rtl_uString": "To keep individual commits reasonably manageable, some consumers of OUStringLiteral in rtl/ustrbuf.hxx and rtl/ustring.hxx are left in a somewhat odd state for now, where they don't take advantage of OUStringLiteral's equivalence to rtl_uString, but just keep extracting its contents and copy it elsewhere. In follow-up commits, those consumers should be changed appropriately, making them treat OUStringLiteral like an rtl_uString or dropping the OUStringLiteral overload in favor of an existing (and cheap to use now) OUString overload, etc." (Simply dropping the OUStringLiteral overload was not possible in this case, though, as that would have lead to ambiguities among the various OUString and std::u16string_view overloads.) The now-deleted OUStringLiteral rvalue reference overload means that some existing assignments from ternary-operator OUStringLiteral<N> to OUString no longer compile and had to be replaced with uses of std::u16string_view. Those had not already been replaced in e6dfaf9f44f9939abc338c83b3024108431d0f69 because they happened to use OUStringLiteral instances of identical length N in both arms of the ternary operator, so did not already start to fail to compile back then. Change-Id: I328e25b8324d045774e811d20a639f40d6a9a960 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124040 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-10-21loplugin:flattenNoel Grandin
Change-Id: I3b4226a9d089ec9aedab95d96e50a068f57a76c7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123991 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-10-16Simplify vector initialization in extensionsJulien Nabet
Change-Id: Ia83209304a7ed889cdd643c8034420c032ccad6e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123685 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-10-15Remove non-const Sequence::begin()/end() in internal codeMike Kaganski
... to avoid hidden cost of multiple COW checks, because they call getArray() internally. This obsoletes [loplugin:sequenceloop]. Also rename toNonConstRange to asNonConstRange, to reflect that the result is a view of the sequence, not an independent object. TODO: also drop non-const operator[], but introduce operator[] in SequenceRange. Change-Id: Idd5fd7a3400fe65274d2a6343025e2ef8911635d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123518 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-10-14use std::vector::insert instead of push_backNoel Grandin
because it will pre-allocate space and often is optimised to memcpy Change-Id: I03ed7915f2762d3d27e378638052a47a28bbf096 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123588 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-10-14Avoid COW overhead using css::uno::SequenceMike Kaganski
The scenarios are: 1. Calling sequence's begin() and end() in pairs to pass to algorithms (both calls use getArray(), which does the COW checks) 2. In addition to #1, calling end() again when checking result of find algorithms, and/or begin() to calculate result's distance 3. Using non-const sequences in range-based for loops, which internally do #1 4. Assigning sequence to another sequence variable, and then modifying one of them In many cases, the sequences could be made const, or treated as const for the purposes of the algorithms (using std::as_const, std::cbegin, and std::cend). Where algorithm modifies the sequence, it was changed to only call getArray() once. For that, css::uno::toNonConstRange was introduced, which returns a struct (sublclass of std::pair) with two iterators [begin, end], that are calculated using one call to begin() and one call to getLength(). To handle #4, css::uno::Sequence::swap was introduced, that swaps the internal pointer to uno_Sequence. So when a local Sequence variable should be assigned to another variable, and the latter will be modified further, it's now possible to use swap instead, so the two sequences are kept independent. The modified places were found by temporarily removing non-const end(). Change-Id: I8fe2787f200eecb70744e8b77fbdf7a49653f628 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123542 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-10-11tdf#145033 remove old focus handler so no double-connect attempt is madeCaolán McNamara
doesn't hurt in this case, but we assert because it has been a fairly common problem in the past Change-Id: Id312c8d2693df803962c265a9a49926d8df04cc0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123413 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-11loplugin:moveparam in extensionsNoel Grandin
Change-Id: Ibbf0fff9a3540d4f723b91e2979e4465648ff203 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123385 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-10-09Typo *ropertie -> *ropertyJulien Nabet
Change-Id: Id5ae03140ac4fd67bf4940569ac5cd2f15716749 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123306 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-10-07drop 'using namespace std' in extensions(ole)Julien Nabet
Change-Id: Id2bb87f792d389dd9e6eeddd17046a46cddfdb6f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123192 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-10-05tdf#119891 Scanner dialog has no Help buttonOlivier Hallot
Added extended tips for the SANE dialog Help page will follow Change-Id: Ibf60eacb561fd65caa682bfa710e52b93b6148d4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123080 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2021-10-04Bump Glade version for sanedialog.uiOlivier Hallot
Change-Id: I9d787d392d5582fdfbe1928c5e3918863f178260 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123058 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-30Extended loplugin:referencecasting/redundantcast (clang-cl): extensionsStephan Bergmann
Change-Id: Ifd431845dc9bb53b87be400a3f5635c8fdc4b2fa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122885 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-09-30loplugin:constparams improve handling of pointer paramsNoel Grandin
Change-Id: I4c0002e72703eded435bfe4985f5b0121bf8524b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122843 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-28gives names to all the Idles and TasksNoel Grandin
enforce it by making the constructor parameter non-default. Change-Id: I321543e4dcf15ea0a43ad8cce91d2f8dc22df6ec Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122766 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-26tdf#50421: use substVariables for remaining %PERCENT% in "Check for Updates"Julien Nabet
Change-Id: I9e1094ef9a957ca1524367f985f37ffc0da5b353 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122621 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-09-23Extend loplugin:stringviewparam to starts/endsWith: extensionsStephan Bergmann
Change-Id: I29c3a09628f213d8b229a981d62421390385c54e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122499 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-09-22lock older -> lock orderCaolán McNamara
Change-Id: I50d2a73e6b95516f421fb71028af67fe116949d6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122425 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-20clean up ambiguous confusing rectangle APIs like IsInside()Luboš Luňák
Reading 'rectA.IsInside( rectB )' kind of suggests that the code checks whether 'rectA is inside rectB', but it's actually the other way around. Rename IsInside() -> Contains(), IsOver() -> Overlaps(), which should make it clear which way the logic goes. Change-Id: I9347450fe7dc34c96df6d636a4e3e660de1801ac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122271 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Luboš Luňák <l.lunak@collabora.com> Tested-by: Jenkins
2021-09-15remove stray track-visited-linksCaolán McNamara
and add truncate-multiline for consistency Change-Id: I5a6fc0f0ac97a0f96739f2383b6d3eb474e776fe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122145 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-15loplugin:constvarsNoel Grandin
Change-Id: I9b35d6333afa6b305bf73fc55a7e60c8365674e9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122134 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-15Use <comphelper/servicehelper.hxx> implementing XUnoTunnel part 5Mike Kaganski
- Revise uses of getSomething to use getFromUnoTunnel Where that is impossible, use getSomething_cast to unify casting, and minimize number of places doing low-level transformations. The change keeps the existing tunnel references that last for the duration of the pointers' life, because sometimes destroying such reference may destroy the pointed object, and result in use after free. Change-Id: I291c33223582c34cd2c763aa8aacf0ae899ca4c0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122101 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-08-31clang-tidy:readability-redundant-member-initNoel Grandin
Change-Id: Icaef0cca9ca7bce76a7eb7ecd54c492f9ffcaad6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121376 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-25Introduce o3tl::saturating_cast for floating-point->integer conversionMike Kaganski
Change-Id: I73191e5ab25fdd9fd8a788db9858b5eb9d3ab955 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120885 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-08-20tdf#141097 Revert "Veto process exit while an OLE client is connected"Michael Warner
This reverts changes that were made to prevent process exit when an OLE client is connected. These commits had the side effect of preventing the use case of creating a document via OLE, and then allowing the user to view/edit and ultimately quit from the GUI. Revert "More hacks for quit requests from an OLE Automation client" This reverts commit 05e03911cd1f8a355b6410d3997cffc2c794a1e9. Revert "Veto process exit while an OLE client is connected" This reverts commit 89f883bd90a50587868a57397b6350ed9559a20f. Change-Id: I29a1e42a830815bc8d1ff0056c22d86b8f98cc1a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118596 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-08-18loplugin:constparamsNoel Grandin
Change-Id: Ic7410f836e584df45101e78e345c8b3c8d355e09 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120680 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-13bibliography, local URL: better starting directory when picking a new fileMiklos Vajna
Improve the case when we have no old file, so we can't take its old parent directory as a starting point in the file picker, opened by the browse button. It turns out both places that open that file picker have access to the base URL of the current document, so can open the directory of that instead. Change-Id: I4db84b6036771f48962d49ae5e4c46a99c306def Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120455 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-08-13pre-select todays's date if the date is emptyCaolán McNamara
Change-Id: If34dbb31d14512b7a7c2a76a3adeb99882a8c60c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120457 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-08-13tdf#143357 use a DateFormatter and a separate Calendar menubuttonCaolán McNamara
similar to what we ended up with in DateControl in svtools/source/brwbox/ebbcontrols.cxx Change-Id: I37c843ff7e1e8e39b318db80fe590ce5f796f46a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119082 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-08-13extensions bibliography: sync the bibliography database window with sw/Miklos Vajna
That one has the browse button and page number widgets removed for URL (keeping them only for local URL), do the same in extensions/ to be consistent. Change-Id: I519b2d82ddbb88d2b63f599094c23783c6d719cf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120424 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins