summaryrefslogtreecommitdiff
path: root/framework
AgeCommit message (Collapse)AuthorFilesLines
2018-02-16Revert "loplugin:changetoolsgen in filter..framework" and reapply pluginNoel Grandin2-5/+5
because I (a) forgot to insert parentheses which changes the meaning of some expressions and (b) I now use the AdjustFoo calls when changing unary operations, which reads much better This reverts commit bf8a6cacd06d7c1961b5db8cc79ee4bbdb342e43. Change-Id: I4b5a9bf0c38ee1b57af91e6b7f184f1e8807f6f7 Reviewed-on: https://gerrit.libreoffice.org/49843 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-02-16native dialog initial basisCaolán McNamara1-1/+1
Change-Id: I392be563e38257390f748c70bb71c67a66778ddd Reviewed-on: https://gerrit.libreoffice.org/49677 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-02-14tdf#108005: Problems with progress bar while saving documentStephan Bergmann2-1/+3
...as StatusIndicatorFactory::m_pWakeUp is still non-null after it has already been used while loading the document. Regression introduced with 017f250764ec7b4ecb82ac19f5b3f68cadf1bf56 "Ensure WakeUpThread is joined before exit". (Also, WakeUpThread::stop could take up to 25 msec longer than necessary, as it failed to set condition_, so would always have waited for WakeUpThread::execute to finish its next 25 msec condition_.wait call.) Change-Id: Ic7fe15f1b90f3b8292cd2ceccdc2719a00743d44 Reviewed-on: https://gerrit.libreoffice.org/49718 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-02-14loplugin:changetoolsgen in filter..frameworkNoel Grandin7-23/+23
Change-Id: I622da8a0c096c74efd97326451c4576b230f0483 Reviewed-on: https://gerrit.libreoffice.org/49701 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-02-06tdf#115218 framework: decouple HiddenForConversion from HiddenMiklos Vajna2-3/+3
Commit 4a0f506f0d8c2a017f0cf880481d3c0c32a48909 (framework: disable layout manager in hidden frames, 2018-01-17) added support for bypassing the framework layout manager for doc conversion purposes, but the Hidden flag has the meaning that the doc is only initially hidden, it may be visible later, so reusing Hidden broke mail merge. Introduce a dedicated HiddenForConversion flag, clients interested in improved performance can opt in for that, and this way behavior for Hidden is not changing. Change-Id: If7537197900f8819f714b164c9e056b4ae69286d Reviewed-on: https://gerrit.libreoffice.org/49302 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-02-06Unused include pngread/write (framework)Julien Nabet2-4/+0
Change-Id: I14358ba06a4a7eb7ad01b0e7cc73455daec917a2 Reviewed-on: https://gerrit.libreoffice.org/49293 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-02-05tdf#108523 Removed @author annotations.Manuj Vashist3-6/+0
Change-Id: I6a60128c413beab6cabb857c073607e15ddbc98f Reviewed-on: https://gerrit.libreoffice.org/49215 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-02-02loplugin:datamembershadow in PopupMenuToolbarControllerNoel Grandin1-2/+1
this looks like an oversight, just use the baseclass member Change-Id: Ida36be64266bbc33a6bd1d89dcb665d24a6dd83f Reviewed-on: https://gerrit.libreoffice.org/49075 Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-29Fix typosAndrea Gelmini2-2/+2
Change-Id: I13b1c0f190b9ebab99e88f90026980fcb2c81c41 Reviewed-on: https://gerrit.libreoffice.org/48833 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-27Fix typosAndrea Gelmini1-1/+1
Change-Id: Id1a19f2c8b44131773d4d5270a607c1907b16597 Reviewed-on: https://gerrit.libreoffice.org/48684 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jens Carl <j.carl43@gmx.de>
2018-01-25Initialize more for sharing during pre-init.Michael Meeks1-0/+3
Change-Id: I12b90504ec9161318683ebad8f8e4dd1e614da89 Reviewed-on: https://gerrit.libreoffice.org/46120 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/48510
2018-01-25Fix typosAndrea Gelmini3-3/+3
Change-Id: If75cf86a65c6f03c6c467efb677e2f7e3e5da576 Reviewed-on: https://gerrit.libreoffice.org/48547 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-24loplugin:useuniqueptr in ImageListsDescriptorNoel Grandin3-10/+8
Change-Id: I165af348b6d8863a4b1e5dd164d92c29f49d09c0 Reviewed-on: https://gerrit.libreoffice.org/48423 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-24loplugin:useuniqueptr in LayoutManagerNoel Grandin4-14/+12
Change-Id: I93383fcb5f0093416914722e25cd0faf70c040eb Reviewed-on: https://gerrit.libreoffice.org/48422 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-19loplugin:unusedmethods also check for functions returning boolNoel Grandin2-3/+2
we were previously excluding them Change-Id: I48a68799b0de60b4995fae541eb363e043d4dd11 Reviewed-on: https://gerrit.libreoffice.org/48167 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-18Fix typosAndrea Gelmini1-1/+1
Change-Id: I633e4921042809c628e55825b70c540767eba1d3 Reviewed-on: https://gerrit.libreoffice.org/48140 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-18Typo: rDesciprtor->rDescriptorJulien Nabet1-1/+1
Change-Id: I71987a989e204c9b4039c8a046e55a0857ad8889 Reviewed-on: https://gerrit.libreoffice.org/48092 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-18framework: disable layout manager in hidden framesMiklos Vajna6-13/+40
The point of hidden frames is that they are not visible on the UI, only their doc model / layout is accessible via the API or file format conversion. That means that laying out the UI elements like menus and toolbars is pointless. So change Frame::initialize() and Frame::setLayoutManager() to not enable the layout manager for hidden frames. To do this, we need a new window style flag, as both hidden and visible frames have an underlying hidden window at the time the framework layout manager would be enabled. Times for 200 hello world inputs: 5780 -> 5054 ms is spent in XHTML-load + ODT export + close (87% of original). Change-Id: I841507bbb62f8fc2979d20e2d579d0bb47b98f37 Reviewed-on: https://gerrit.libreoffice.org/48068 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-01-16Fix typosAndrea Gelmini2-2/+2
Change-Id: I078626eaa3155cc429320cc8c1532003b382b22a Reviewed-on: https://gerrit.libreoffice.org/47855 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-15Fix typoAndrea Gelmini2-13/+13
Change-Id: I51c97356c9c2939f2d94d6388c829a179ca00daa Reviewed-on: https://gerrit.libreoffice.org/47853 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2018-01-15More loplugin:cstylecast: frameworkStephan Bergmann6-65/+65
Change-Id: Iffd183cb21b43aaa66dd55cc6c453ebeae36a3e1
2018-01-15convert a<b?a:b to std::min(a,b)Noel Grandin1-1/+1
with something like git grep -nP '(.*)\s*<\s*(.*)\s*\?\s*\g1\s*:\s*\g2' -- *.?xx Change-Id: Id5078b35961847feb78a66204fdb7598ee63fd23 Note: we also convert a>b?b:a Reviewed-on: https://gerrit.libreoffice.org/47736 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-14Fix typosAndrea Gelmini5-14/+14
Change-Id: I2b4988e1d81fe60f7699362480cd739d2620c053 Reviewed-on: https://gerrit.libreoffice.org/47856 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-14Fix typosAndrea Gelmini12-20/+20
Change-Id: I2a578961837076ebce3c1fb2681b0785d1d490ac Reviewed-on: https://gerrit.libreoffice.org/47857 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-12More loplugin:cstylecast: frameworkStephan Bergmann28-52/+52
auto-rewrite with <https://gerrit.libreoffice.org/#/c/47798/> "Enable loplugin:cstylecast for some more cases" plus solenv/clang-format/reformat-formatted-files Change-Id: I8981ef6de675bf10c103e1af0afccd620762268d
2018-01-11loplugin:redundantcast: frameworkStephan Bergmann1-5/+5
(after a to-be-committed improved loplugin:cstylecast would have rewritten the C-style casts into static_casts) Change-Id: I726159d62e748678f8d739db2d3f97c80a5181c3
2018-01-05Fix typosAndrea Gelmini4-6/+5
Change-Id: I766862d255ac285329ae423629c7445837ddd55f Reviewed-on: https://gerrit.libreoffice.org/47280 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2018-01-04drop CmdToXGraphicNameAccess typedefNoel Grandin1-19/+17
Change-Id: I76dc73c5a6c62b0ec0fff274ae57f084ccdb8c70 Reviewed-on: https://gerrit.libreoffice.org/47347 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-03tdf#107039: Avoid deadlock by locking the SolarMutex early on in one placeTor Lillqvist1-0/+1
See bug report for backtraces of the deadlocking threads. Change-Id: I0334118e173c37b6f9596249e1e2f0d196bbab3f Reviewed-on: https://gerrit.libreoffice.org/47249 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tor Lillqvist <tml@collabora.com>
2018-01-03Fix typosAndrea Gelmini2-3/+3
Change-Id: I3f4ad9eff0730d3deea96b37fa7f36dfd038b214 Reviewed-on: https://gerrit.libreoffice.org/47301 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-29Fix typosAndrea Gelmini3-3/+3
Change-Id: I0e56430afa65b6b5826d56212ac501c0244fce9b Reviewed-on: https://gerrit.libreoffice.org/47145 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-29Fix typosAndrea Gelmini4-4/+4
Change-Id: I3d16dc162e5fa2e08134d848a835eb392e64056e Reviewed-on: https://gerrit.libreoffice.org/47126 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-26loplugin:passstuffbyref improved return in basic,frameworkNoel Grandin4-4/+4
Change-Id: Ib19836febb59f4e2bb07dc874cfc6baabc653237 Reviewed-on: https://gerrit.libreoffice.org/47065 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-22lokdialog: Allow switching language of some of the ResMgr's.Jan Holesovsky1-2/+1
This way, it is possible to have all the strings translated in dialogs even when different users use different languages. [It was already possible to have different languages previously, but not everything in the dialog has switched - like the buttons at the bottom of the dialogs etc.] Change-Id: I29a5ae6d31a370eec60397884200b684ec1bf5b9 Reviewed-on: https://gerrit.libreoffice.org/46417 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/46979 Tested-by: Jenkins <ci@libreoffice.org>
2017-12-21Fix typosAndrea Gelmini1-1/+1
Change-Id: I5c6e252072089a06f0be4292d51aed020cbc67fe Reviewed-on: https://gerrit.libreoffice.org/46888 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-20Related: tdf#79657 Different approach to disable the context menuMaxim Monastirsky1-1/+0
... in the overflow toolbar. Using ToolBoxMenuType::NONE is wrong as it might affect the layout. Can be easily triggered here by adding FloatWinPopupFlags::GrabFocus to StartPopupMode (which likely will be needed to fully solve tdf#79657). Another case was fixed in 91053763a7189c8ac03a59dc996e6333404f846e ("Fix sub-toolbar tearoff for .uno:ChooseControls"), but without providing a solution for the context menu. Change-Id: I4a0b4560fe49106613fa2337b5dd83eb7fa29f47 Reviewed-on: https://gerrit.libreoffice.org/46837 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
2017-12-20Fix typosAndrea Gelmini1-1/+1
Change-Id: I28d73221ea83d89f73460f591723c6f80594ff15 Reviewed-on: https://gerrit.libreoffice.org/46822 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-19remove unused typedefsNoel Grandin1-2/+0
Change-Id: I6fd7a9fed3a80c91a3766fceefd43c5db0aa5275 Reviewed-on: https://gerrit.libreoffice.org/46763 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-19Fix typosAndrea Gelmini1-1/+1
Change-Id: Ibffe19c1dfda9d0f4ba8d2a0761ad1222491007f Reviewed-on: https://gerrit.libreoffice.org/46599 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-17Fix typosAndrea Gelmini3-8/+8
Change-Id: I4630ba4a93a32c47753422b29535c36b53ff3d5e Reviewed-on: https://gerrit.libreoffice.org/46635 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-17tdf#98058 Respect menu:style="text" settingMaxim Monastirsky1-12/+5
It was implemented on the xml handling side, but ignored by the menubar code. In addition, make the menu:style attribute survive customization (similar to tdf#114261). Change-Id: I92a3517ee7ba2fe7a0782985d89fb5d0fdbac246 Reviewed-on: https://gerrit.libreoffice.org/46627 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
2017-12-14No need to keep these whitelisted functions decorated with SAL_CALLStephan Bergmann2-4/+4
The only effect SAL_CALL effectively has on LO-internal code is to change non- static member functions from __thiscall to __cdecl in MSVC (where all other functions are __cdecl by default, anyway). (For 3rd-party code, it could be argued that SAL_CALL is useful on function declarations in the URE stable interface other than non-static member functions, too, in case 3rd-party code uses a compiler switch to change the default calling convention to something other than __cdecl. But loplugin:salcall exempts the URE stable interface, anyway.) One could argue that SAL_CALL, even if today it effectively only affects non- static member functions in MSVC, could be extended in the future to affect more functions on more platforms. However, the current code would already not support that. For example, 3af500580b1c82eabd60335c9ebc458a3f68850c "loplugin:salcall fix functions" changed FrameControl_createInstance in UnoControls/source/base/registercontrols.cxx to no longer be SAL_CALL, even though its address (in ctl_component_getFacrory, in the same file) is passed to cppuhelper::createSingleFactory as an argument of type cppu::ComponentInstantiation, which is a pointer to SAL_CALL function. Change-Id: I3acbf7314a3d7868ed70e35bb5c47bc11a0b7ff6 Reviewed-on: https://gerrit.libreoffice.org/46436 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-12-14Fix typoAndrea Gelmini1-1/+1
Change-Id: I34d41941ef0ba20bca604b7caed80a2d0b6ac129 Reviewed-on: https://gerrit.libreoffice.org/45706 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2017-12-13Make loplugin:salcall look into macros tooStephan Bergmann24-25/+25
"Indirect" calls to isSallCallFunction (for canonic and overridden FunctionDecls) already needed to handle many cases of FunctionDecls spanning macros, so it isn't that much more work to make that also work for cases called directly from VisitFunctionDecl. Change-Id: I529f148c8872b86aa1ef082c6cb73db8ab1866e7 Reviewed-on: https://gerrit.libreoffice.org/46367 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-12-13sal_uLong->void* for userdata in MenuNoel Grandin6-18/+18
Change-Id: I58fb10136a23c445edfd63a1f86ace3995524704 Reviewed-on: https://gerrit.libreoffice.org/46350 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-11Fix typos and grammarIlmari Lauhakangas1-1/+1
Change-Id: I4143da3c5a809118d57849664f6ab1d2e775837f Reviewed-on: https://gerrit.libreoffice.org/46253 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-11loplugin:salcall fix functionsNoel Grandin40-55/+55
since cdecl is the default calling convention on Windows for such functions, the annotation is redundant. Change-Id: I1a85fa27e5ac65ce0e04a19bde74c90800ffaa2d Reviewed-on: https://gerrit.libreoffice.org/46164 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-08cppcheck: fix some reportsJulien Nabet1-1/+1
variableScope reports in comphelper/drawinglayer/editeng +filter/framework/l10ntools Change-Id: I4575428773e8b9b3efedabb44fdcd6d8175ac46a Reviewed-on: https://gerrit.libreoffice.org/46116 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-07loplugin:salcall handle static methodsNoel Grandin1-1/+1
Change-Id: Id6820abec4b8ca8bee26d62b333fd30b42a14aec Reviewed-on: https://gerrit.libreoffice.org/46007 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-06Remove unused #include <vcl/metaact.hxx> from vcl/outdev.hxxStephan Bergmann2-2/+2
...and fix the fallout Change-Id: Ie514bd95d5a9f990a887566619031e9844c40b92 Reviewed-on: https://gerrit.libreoffice.org/45195 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>