summaryrefslogtreecommitdiff
path: root/framework
AgeCommit message (Collapse)Author
2018-10-16drop LazyDeletorCaolán McNamara
Change-Id: I7d2e00466f321994a46b0529d645e342f229c929 Reviewed-on: https://gerrit.libreoffice.org/61718 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
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-09tdf#120264 - Access to "Get Involved"heiko tietze
UNO command SID_GETINVOLVED added with access to the website from all main menus under Help Dispensable ellipsis removed from other UNO commands around Help Change-Id: I79536be3de31f55a7b208bcdd5a243e05b3d3668 Reviewed-on: https://gerrit.libreoffice.org/61238 Tested-by: Jenkins Reviewed-by: Heiko Tietze <tietze.heiko@gmail.com>
2018-10-09use unique_ptr in SfxUndoManager::AddUndoActionNoel Grandin
Change-Id: I11483e3cece12a7373f4276972b4c899edf1ce15 Reviewed-on: https://gerrit.libreoffice.org/61566 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-08tdf#42949 Fix IWYU warnings in include/comphelper/[m-z]*Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I04c5ba277d5b3398c07de6ae66713d977636088d Reviewed-on: https://gerrit.libreoffice.org/61347 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-09-28Fix E_SUCCEDED -> E_SUCCEEDEDAndrea Gelmini
It passed "make check" on Linux. Change-Id: I96b34c818f6d4170c110ecd1fb93af79c3279e57 Reviewed-on: https://gerrit.libreoffice.org/61028 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-09-24tdf#42949 Fix IWYU warnings in include/comphelper/[a-l]*Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I22ba2c8aec235e34cd7835b8a0a716bf3057db7a Reviewed-on: https://gerrit.libreoffice.org/60837 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-09-19menu:style="radio" is used since 2010, update dtd to realityChristian Lohmaier
menubar definitions using menu:style="radio" attribute were introduced with df4017a8fffb448cd2f202ed297754f275ca6be3 / the other commits of that cws, but the dtd wasn't adjusted accordingly Change-Id: I7c7e1b8116800ee20cfede431ed90ef8f213cce0 Reviewed-on: https://gerrit.libreoffice.org/60276 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2018-09-18tdf#114441 Replacing sal_uLong with most appropriate integer typesCaio B. Silva
Change-Id: I4ba636e9b882c0c0958420037768fd596fdecef9 Reviewed-on: https://gerrit.libreoffice.org/57845 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2018-09-17New loplugin:externalStephan Bergmann
...warning about (for now only) functions and variables with external linkage that likely don't need it. The problems with moving entities into unnamed namespacs and breaking ADL (as alluded to in comments in compilerplugins/clang/external.cxx) are illustrated by the fact that while struct S1 { int f() { return 0; } }; int f(S1 s) { return s.f(); } namespace N { struct S2: S1 { int f() { return 1; } }; int f(S2 s) { return s.f(); } } int main() { return f(N::S2()); } returns 1, both moving just the struct S2 into an nunnamed namespace, struct S1 { int f() { return 0; } }; int f(S1 s) { return s.f(); } namespace N { namespace { struct S2: S1 { int f() { return 1; } }; } int f(S2 s) { return s.f(); } } int main() { return f(N::S2()); } as well as moving just the function f overload into an unnamed namespace, struct S1 { int f() { return 0; } }; int f(S1 s) { return s.f(); } namespace N { struct S2: S1 { int f() { return 1; } }; namespace { int f(S2 s) { return s.f(); } } } int main() { return f(N::S2()); } would each change the program to return 0 instead. Change-Id: I4d09f7ac5e8f9bcd6e6bde4712608444b642265c Reviewed-on: https://gerrit.libreoffice.org/60539 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-08loplugin:simplifyconstruct in filter..frameworkNoel Grandin
Change-Id: Ida4307a92dfb1dbd14da5a30b6ee1f0fd6a9455e Reviewed-on: https://gerrit.libreoffice.org/60194 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-07Cppcheck: make 1-argument ctors explicitMike Kaganski
Change-Id: I437988b238af961c6a3ac61ed4e93ea8206f6001 Reviewed-on: https://gerrit.libreoffice.org/60123 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-09-06loplugin:useuniqueptr in framework::FrameNoel Grandin
Change-Id: Ic1350d5bff80d4a88d3949a412ee9bf02ad969ba Reviewed-on: https://gerrit.libreoffice.org/60050 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
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-09-04loplugin:useuniqueptr in AcceleratorConfigurationNoel Grandin
Change-Id: I255005e80ee57638846e353a88477dd54bbbb284 Reviewed-on: https://gerrit.libreoffice.org/59943 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-04loplugin:useuniqueptr in HandlerCacheNoel Grandin
Change-Id: Ic3ba52568cbf1281162b3b4146d8c5d2ce9574b4 Reviewed-on: https://gerrit.libreoffice.org/59942 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-31tdf#119390 Don't focus the toolbar when closing a floating windowMaxim Monastirsky
Toolbar popup windows have the toolbar as their direct parent. This causes problems when such window is teared-off and later closed, as Window::dispose will attempt to move the focus to its parent which is the toolbar, instead of what users expect to have the focus back in the document area, or in whatever was the last focused control. As a solution reparent the window before dispose, similar to what happens with floating toolbars. Also return the focus to the main window when popup mode ends, so we can keep track of the last focused control. This is also a good thing by itself, as WB_OWNERDRAWDECORATION windows don't get the focus by default, which results in neither the floating window nor the document have focus after tear-off. Change-Id: I060b8c45a64db9c612da58b7c35478bab41a4558 Reviewed-on: https://gerrit.libreoffice.org/59811 Tested-by: Jenkins Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
2018-08-15loplugin:useuniqueptr in MenuBarManagerNoel Grandin
Change-Id: Iffdd62e8af5fa31caecc6ea01bd5e21de950862c Reviewed-on: https://gerrit.libreoffice.org/59021 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
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-09Toolbar and menu containers are similar enoughMaxim Monastirsky
... to be handled by the same code. Change-Id: I96fae066ccf2bef474fe4faf8068b7290eea8d8b Reviewed-on: https://gerrit.libreoffice.org/58766 Tested-by: Jenkins Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
2018-08-06fix for crash in CppunitTest_services on windowsNoel Grandin
after commit 9cceba9a928cf3b3447f293020be2fe76c035ed5 make DBG_TESTSOLARMUTEX available in assert builds bt looks like: #0 0x00007faf569074fd in ImplDbgTestSolarMutex() #1 0x00007faf56904df9 in vcl::EventPoster::~EventPoster() #2 0x00007faf4392b452 in AutoRecovery::~AutoRecovery() #3 0x00007faf4392b589 in AutoRecovery::~AutoRecovery() #4 0x00007faf5d03dfc8 in __run_exit_handlers() Change-Id: If72eece22db89b492d8e69d1abb496168e32cb9d Reviewed-on: https://gerrit.libreoffice.org/58636 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-31Fix typosAndrea Gelmini
Change-Id: If8897807f065a342ef0e7f923199660079a70d22 Reviewed-on: https://gerrit.libreoffice.org/58123 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2018-07-30Add 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 filter to jvmfwk Change-Id: I2a73d63f2aaef5f26d7d08957daaa8a30b412ac5 Reviewed-on: https://gerrit.libreoffice.org/58204 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-07-29Fix typosAndrea Gelmini
Change-Id: I246d2f1681a7d833fc5f201bfdbacbe4fc3ae084 Reviewed-on: https://gerrit.libreoffice.org/58286 Tested-by: Jenkins Reviewed-by: Jens Carl <j.carl43@gmx.de>
2018-07-29Fix typoAndrea Gelmini
Change-Id: I5daaf19dab60a07033fd28499ba8ad25607777d9 Reviewed-on: https://gerrit.libreoffice.org/58127 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2018-07-27loplugin:returnconstant in frameworkNoel Grandin
Change-Id: Id3009a4b038175625cf8be419deb5ef8a9998850 Reviewed-on: https://gerrit.libreoffice.org/58110 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-27loplugin:stringloop in basic, framework, sax, svtoolsNoel Grandin
Change-Id: I2bad74a8f103e9dc68c8e0d0e6315697068d2f6d Reviewed-on: https://gerrit.libreoffice.org/58135 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-27Related: rhbz#1602589 add comments to coverity annotationsCaolán McNamara
Change-Id: I88c941832a0d682ea4b6028c28edd48cf5df38f7 Reviewed-on: https://gerrit.libreoffice.org/58093 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-07-26framework: avoid -Werror=deprecated-copy (GCC trunk towards GCC 9)Stephan Bergmann
...by removing explicitly user-provided functions that do the same as their implicitly-defined counterparts, but may prevent implicitly declared copy functions from being defined as non-deleted in the future. (Even if such a user-provided function was declared non-inline in an include file, the apparently-used implicitly-defined copy functions are already inline, so why bother with non-inline functions.) Change-Id: Ia4c3442642a2db3ca365a35e56a203a955a415c4 Reviewed-on: https://gerrit.libreoffice.org/58080 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-07-23Fix typosAndrea Gelmini
Change-Id: I4bb060a6a65ca27bba8d16c268660bedef8b0ed5 Reviewed-on: https://gerrit.libreoffice.org/57821 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2018-07-19Fix typosAndrea Gelmini
Change-Id: I7d12fe95d1c65a431325273c6e95943166e2ec58 Reviewed-on: https://gerrit.libreoffice.org/56941 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.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-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-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-08Fix typoAndrea Gelmini
Change-Id: I1cc4544e807d7c04aa171358ccd1c204040dff55 Reviewed-on: https://gerrit.libreoffice.org/57078 Tested-by: Jenkins Reviewed-by: Jens Carl <j.carl43@gmx.de>
2018-07-02loplugin:constantparamNoel Grandin
Change-Id: I9fbfa6163c1d4650c52b00dc911972f07fe7c0e5 Reviewed-on: https://gerrit.libreoffice.org/56778 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-06-29Improved loplugin:redundantcast (const-qualified typedefs): frameworkStephan Bergmann
Change-Id: Ibcceaa03a73926b559a297f62b3d1d2676c9f4f0 Reviewed-on: https://gerrit.libreoffice.org/56698 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-06-28tdf#86612: statusbar: hide some elements if width is not sufficientVasily Melenchuk
new statusbar element property mandatory=true/false to determine if this element can be hidden if total statusbar width is not enough to fit all elements. marked some calc and draw statusbar elements as not mandatory. Change-Id: I20e26d3c4bd865e94ea48632a1e97d55f3fa712f Reviewed-on: https://gerrit.libreoffice.org/56443 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2018-06-26Clean up XMLNamespacesStephan Bergmann
...so that it no longer has a m_aXMLAttributeNamespace member that the user- provided copy ctor did not copy. (Which was presumably by accident, but appears to not have had bad consequences due to how XMLNamespaces::adNamespace is only called before the copy ctor is called in SaxNamespaceFilter::startElement, framework/source/fwe/xml/saxnamespacefilter.cxx). Found by new -Wdeprecated-copy of GCC trunk towards GCC 9. Change-Id: I0701ecdfbef9c078a09ed411f4d9ccd166271aae Reviewed-on: https://gerrit.libreoffice.org/56469 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-06-19Rename nFlags to nSearchFlagsSamuel Mehrbrodt
Change-Id: Ib03046acf3d34fc307a3765d7d0b1b7d9448b507 Reviewed-on: https://gerrit.libreoffice.org/56088 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-06-19tdf#118238 Only disable UI interaction when loading document as hiddenSamuel Mehrbrodt
The "quiet" interaction handler was used unconditionally when loading a document via the loadComponentFromURL API method. So no dialog was shown asking the user whether he wants to enable macros. With this patch, the "quiet" interaction handler is only used, when the document was loaded with the "Hidden" property set. Change-Id: Idd522d0bf605499b071390fb58312181b755dfca Reviewed-on: https://gerrit.libreoffice.org/56086 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-06-18tdf#108523 Remove @author annotationsAbhyudaya Sharma
Change-Id: I85e364da59ce70ddd97fdae9bc03a4ea76b007fc Reviewed-on: https://gerrit.libreoffice.org/55263 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-06-18Fix typosAndrea Gelmini
Change-Id: I77c4c8feb12d7ed6ee4b4eaa6132a91f4e655fbc Reviewed-on: https://gerrit.libreoffice.org/55967 Tested-by: Jenkins Reviewed-by: Jens Carl <j.carl43@gmx.de>
2018-06-13WaE: Wmaybe-uninitializedCaolán McNamara
Change-Id: I48e0d84ec0307f9895b5148f9522df8f0c02ac6c Reviewed-on: https://gerrit.libreoffice.org/55758 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-06-12loplugin:constantparamNoel Grandin
Change-Id: Ia769b3176aea287cd57414d7ce8e88c6da43883e Reviewed-on: https://gerrit.libreoffice.org/55622 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-06-11new loplugin:shouldreturnboolNoel Grandin
look for methods returning only 1 and/or 0, which (most of the time) should be returning bool. Off by default, because some of this is a matter of taste Change-Id: Ib17782e629888255196e89d4a178618a9612a0de Reviewed-on: https://gerrit.libreoffice.org/54379 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-06-11menubar: framework/startpage sync help menubar entryandreas kainz
Change-Id: I8895c79a65750330600ebf0be19d184736fe2c1c Reviewed-on: https://gerrit.libreoffice.org/55543 Reviewed-by: Heiko Tietze <tietze.heiko@gmail.com> Tested-by: Jenkins <ci@libreoffice.org>
2018-06-08look for unnecessary calls to Reference::is() after an UNO_QUERY_THROWNoel Grandin
Since the previous call would throw if there was nothing to be assigned to the value. Idea from tml. Used the following script to find places: git grep -A3 -n UNO_QUERY_THROW | grep -B3 -F 'is()' Change-Id: I36ba7b00bcd014bdf16c0455ab91056f82194969 Reviewed-on: https://gerrit.libreoffice.org/55417 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-06-06enable incremental linking on windowsNoel Grandin
requires a handful of workarounds Change-Id: I77c25580135eeec437716eceea1412607f8d14ca Reviewed-on: https://gerrit.libreoffice.org/55244 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>