summaryrefslogtreecommitdiff
path: root/sc
AgeCommit message (Collapse)Author
2018-05-31move mbThreadedGroupCalcInProgress from ScDocument to ScGlobalLuboš Luňák
Some code, such as statics in ScGlobal, cannot(?) easily access ScDocument. Moreover whether Calc is currently performing threaded calculations is not really a state of a document but of Calc itself. Still keep the state accessible via ScDocument for the pipe-dream future where it possibly really will be a state of the document. Change-Id: I2b112221e7fa1b2b4469cfd289fc201025585a5f Reviewed-on: https://gerrit.libreoffice.org/54796 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2018-05-31tdf#96698 - calc: add support for custom validation (through a formula)Marco Cecchetti
Now it is possible to select a `custom` validation in the validation dialog: this type of validation let's the user to define a formula, the cell content is valid when the formula is evaluted to true, and not valid when evaluated to false. The `cutom` validation is correctly saved and restored for ods documents, and is correctly imported and exported to xlsx documents This patch contains an adaptation of a preliminary work of Justin Luth for importing custom validation from xlsx documents. Thanks Justin! Change-Id: Idc26654ba69a6f73d1b208d63acdad4b880c776d Reviewed-on: https://gerrit.libreoffice.org/49084 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com>
2018-05-31SOSAW080: Cleanup of SdrModelArmin Le Grand
First step: Find all constructors/derivations, mark all of them. Removed two-value-constructors, adapted code as needed Reduced constructors for SdrModel/FmFormModel to a single one. Removed PathName for List creation, this is not needed and anyways all calls used the default SvtPathOptions().GetPalettePath(). This is also true for usage of IsFuzzing() that is also part of the default creation process (without path). All usages that need an extra-List were setting it after construction explicitely. Removed UseExtColorTable. This prevents a single List to be not created by default, the ColorTable which is replaced later by all callers that used this. This is not needed since the default ColorTable gets constructed just by default, no expensive stuff is triggered (e.g. loading the ColorTable). Thus now a default ColorTable is created and kept for a short moment, destructed again when a ColorTable is explicitely set. Doing so is also more safe - it avoids not creating a default-ColorTable and then not setting one (what would be urgently required). f23c24a8548d5246b77b1cc359ba89564538e81a f124468c3898c5842d37123bdeb87d79a2b19c62 Change-Id: I865de4bb23f673c6684d83c2c6390439506dc5b6 Reviewed-on: https://gerrit.libreoffice.org/55028 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Armin Le Grand <Armin.Le.Grand@cib.de>
2018-05-31Implement NewWorkbook and WorkbookOpen Automation callbacks in CalcTor Lillqvist
Change-Id: I1ff31d692100695a706bf128c18c4e3ae8b55ce3
2018-05-31Add Author property to ooo::vba::excel::XWorkbook and implement itTor Lillqvist
Corresponds to the Author attribute of css::document::XDocumentProperties. I.e. the initial creator of the document. Change-Id: I07d3ce9dfb87900948d2bb7af14109b17546fb4c
2018-05-31Initial steps to make also Calc usable from Automation clientsTor Lillqvist
Largely parallel to what we do for Writer. Yes, there is a fair amount of duplicated code now for the outgoing ("sink") stuff in sw and sc, that should be factored out (to vbahelper, probably). Change-Id: I8df4a81c3b9043e8d6b0b206e3c04660205987c7
2018-05-31drop Graphic::GetBitmapNoel Grandin
so that we flush out various code using Bitmap, in favour of using BitmapEx. This is part of the process of making Bitmap largely an internal detail of vcl Change-Id: Iaf2ead5e3d9960838723fb55b812b97108093d74 Reviewed-on: https://gerrit.libreoffice.org/55062 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-31drop last use of TransferableHelper::GetSystemClipboardCaolán McNamara
Change-Id: I405b0cac0db5f08aa2f9fb73927c4c21f0250988 Reviewed-on: https://gerrit.libreoffice.org/55076 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-05-31SwModule is a convenient (?) place for passing events to Automation clientsTor Lillqvist
Generate Application.DocumentChange and Application.Quit events. SfxHintId::DocChanged seems to correspond nicely enough to Application.DocumentChange. It is generated a bit eagerly, but as its documentation is fairly vague and no specific detailed information is passed in parameters anyway, it probably doesn't hurt if a client gets it a bit more often with LO than with some other product. Can now remove the FIXME-marked Quit event things in SwVbaApplication. Now need oovbaapi in many makefiles for them to compile. Change-Id: I4d0c5b93b584f198bcc854002eec7aaba7909ecc Reviewed-on: https://gerrit.libreoffice.org/55106 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2018-05-30sc: Insert a space for consistencyTakeshi Abe
Change-Id: Ifb1429eb3ad6d1093a7b5126ea3d15c4509cf8cc Reviewed-on: https://gerrit.libreoffice.org/54981 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com>
2018-05-30protect one-time creation in ScGlobal::Get(Case)Collator() by a mutexLuboš Luňák
Otherwise there is a race condition when calc uses threading, and lp#390983-2 sometimes crashes. Change-Id: I390928c02b8e7d74bebef2dcc98a5c21cb3a8197 Reviewed-on: https://gerrit.libreoffice.org/54795 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Luboš Luňák <l.lunak@collabora.com>
2018-05-30use BitmapEx in the screenshot stuffNoel Grandin
part of the process of moving Bitmap usage to BitmapEx Change-Id: I4f02f8aa60d19a3639d623a998491447adf79e15 Reviewed-on: https://gerrit.libreoffice.org/55031 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-30Revert "UITest_calc_tests: disable randomly failing assert for now"Luboš Luňák
Fixed by my previous commit. This reverts commit 27cc0064a8a52c9000d0249581e80fe7a0c8a7b6. Change-Id: Ib64e7341251d848b4db0dbb1f58c4fcef51437ed
2018-05-29weld SvxTransformTabDialogCaolán McNamara
Change-Id: Ib6dabd04e3f834b61363d5a620de7f0219a1e644 Reviewed-on: https://gerrit.libreoffice.org/55012 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-05-29uitest for bug tdf#104117 and tdf#80693Zdeněk Crhonek
Change-Id: I29bdf088c83ce69152d5c3edee2c855bfece4585 Reviewed-on: https://gerrit.libreoffice.org/55019 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Zdenek Crhonek <zcrhonek@gmail.com>
2018-05-29loplugin:unusedfields-in-constructor in scNoel Grandin
Change-Id: I074bb272b692dea553e1ec1e625c8afd766627d6 Reviewed-on: https://gerrit.libreoffice.org/54997 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-29avoid using EditEngine in ScEditUtils::GetString() if possibleLuboš Luňák
According to 1ecdc7aaf66 it is really needed only for resolving fields, so if there's no field, simply concatenate the contents, as used to be the case before that commit. This should be faster and also safer in the case of Calc's threading enabled. Change-Id: I23a2e1873deb8538e2a1ae0dd80af7e5356c18a5 Reviewed-on: https://gerrit.libreoffice.org/54986 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins <ci@libreoffice.org>
2018-05-29forcepoint#40 null derefCaolán McNamara
presumably since commit 0098bee792c3e208ea4f6ef1c676958d3f4cd207 Date: Thu Sep 21 06:48:09 2017 +0200 tdf#112501: Pivot table: popupbuttons are placed on wrong cells Change-Id: I5413c0ba06fca25cb22256a20ef9640767dd9e50 Reviewed-on: https://gerrit.libreoffice.org/54968 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-05-29tdf#42949 Fix IWYU warnings in sc/inc/m*Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I43882919048c23e9b8d305f8cbba8f120207bb93 Reviewed-on: https://gerrit.libreoffice.org/54824 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-05-28sc: simplify ScModule::GetClipDocHenry Castro
Change-Id: I36a79a41b989d37efc35a9f9b4bebca9bdaf9ee9 Reviewed-on: https://gerrit.libreoffice.org/54935 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Henry Castro <hcastro@collabora.com>
2018-05-28blacklist ocDBSum for calc's threadingLuboš Luňák
Triggers a number of asserts on hard-recalc (Shift+Ctrl+F9) with ooo#58183-1 that would require passing ScContextInterpreter* to a number of functions, so just blacklist it. Change-Id: I0c3666a3423cea7c77f530480b8b63506c4bbad2 Reviewed-on: https://gerrit.libreoffice.org/54933 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins <ci@libreoffice.org>
2018-05-28uitest Calc Fill random numberZdeněk Crhonek
Change-Id: I6922a537f06c7cced0f8b5390c8261c57d07b29b Reviewed-on: https://gerrit.libreoffice.org/54928 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Zdenek Crhonek <zcrhonek@gmail.com>
2018-05-28DBase: synchronize DB types known on Calc with those known on BaseJulien Nabet
by adding 0x31, VisualFoxProAuto on array of valid marks in lcl_MayBeDBase See https://opengrok.libreoffice.org/xref/core/connectivity/source/inc/dbase/DTable.hxx#40 and https://opengrok.libreoffice.org/xref/core/include/connectivity/dbtools.hxx#823 Yes, it should be great to have only 1 enum Change-Id: Ic3fb74c838aab5e744cbe1d70ad8ca4ce2c00b8d Reviewed-on: https://gerrit.libreoffice.org/54894 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-05-28lok: sc: tunneling the ascii import dialog on paste actionMarco Cecchetti
Modified CreateScImportAsciiDlg signature so that we are able to pass a pointer to a dialog parent window to ScImportAsciiDlg. Now the execution of the ScImportAsciiDlg dialog in ScViewFunc::PasteDataFormat is asynchronous, both for lok and desktop case. In order to achieve this result it has been needed to modify the lifespan of some objects previously local to PasteDataFormat. Since PasteDataFormat returns a boolean, I took care to check how this return value is used. I found out 2 cases: 1) in ScViewFunc::PasteFromSystem where it is used for popping up an error dialog box, informing the user in the case that the paste operation is failed; 2) in ScGridWindow::ExecuteDrop where it is used for informing the sysyem window manager of the success or fail of the drag and drop action. The first case is now handled by a lamba invoked on dialog execution end. The second case is always handled as the paste operation was successfull (hoping it doesn't do any real difference). The asynchronous call and the behaviors described above occur only when the paste operation involves some kind of text. Change-Id: Id4f96180a9336f665a22a2441ea490af993431b0 Reviewed-on: https://gerrit.libreoffice.org/53576 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Marco Cecchetti <mrcekets@gmail.com>
2018-05-28Fix typosAndrea Gelmini
Change-Id: I4faf601f9b690bdf284d8ee472091f38ca96d5f1 Reviewed-on: https://gerrit.libreoffice.org/54908 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-05-28weld ScTabBgColorDlgCaolán McNamara
Change-Id: I864382bc55dead850c13faae9958fb660fd4f156 Reviewed-on: https://gerrit.libreoffice.org/54809 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-05-28tdf#100756 slowdown in manipulating spreadsheet via UNONoel Grandin
regression from commit 5bce32904091ffe28884fd5c0f4801ee82bad101 SfxHint: convert home-grown RTTI to normal C++ RTTI the cost does seem in this case to be mostly the dynamic_cast, but since we don't need it anymore, just remove it Change-Id: Icbf51b89c036b86cfb3e4c2a827228ccf25bb3a6 Reviewed-on: https://gerrit.libreoffice.org/54899 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-28loplugin:unusedmethodsNoel Grandin
Change-Id: I64df1f467986b3d70c058adff289a6dd8f00fb20 Reviewed-on: https://gerrit.libreoffice.org/54821 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-28sc: release XTransferable2 when used with VBA compatibility helpersHenry Castro
Copy, Cut, PasteSpecial and Insert is used by Range excel object, so after finishing executing the VBA script ensure to release XTransferable2 interface Change-Id: I967a7ba1a1d101282f7a1b9d4b2e2ac3004f1c07 Reviewed-on: https://gerrit.libreoffice.org/54497 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Henry Castro <hcastro@collabora.com>
2018-05-27misleading comment: not every sheet is examinedJustin Luth
In fact, if there are no sheet-local names defined, then the loop will not even be entered. Only the sheets that actually contain the desired item will be iterated through. Change-Id: I1fa94d8b9190f43b2896a002acdec18397225395 Reviewed-on: https://gerrit.libreoffice.org/54742 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Andras Timar <andras.timar@collabora.com>
2018-05-27uitest for bug tdf#54018Zdeněk Crhonek
Change-Id: I4a5356e275f1132898aec758a79f3a38c71d35ea Reviewed-on: https://gerrit.libreoffice.org/54820 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Zdenek Crhonek <zcrhonek@gmail.com>
2018-05-26fix build failure on some systemCaolán McNamara
Change-Id: I63e1164d5ee431450f1c780758d9fd6f69cf6916
2018-05-26Rename bNeedEdit → bUseEditEngineKhaled Hosny
Make it a bit clear that edit here means edit engine not merely text editing as one would naïvely assume. Took me a while to realize that! Change-Id: I570a0556d3272c480dc1ae95640de32f56ab9607 Reviewed-on: https://gerrit.libreoffice.org/54783 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
2018-05-26UITest_calc_tests: disable randomly failing assert for nowMiklos Vajna
make -sr UITest_calc_tests UITEST_TEST_NAME="tdf53482.tdf53482.test_tdf53482_Range_contains_column_headings_file" passed for me 10 times in a row without problems after this, while 'make check' randomly fails here & there since the introduction of this test. Change-Id: I5c3eae027297e0b488cf72161815239a8b03aa60 Reviewed-on: https://gerrit.libreoffice.org/54825 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-05-25Fix typoAndrea Gelmini
Change-Id: Ib7e080864f809294a4a6ae78694730fb07120753
2018-05-25Improve re-throwing of UNO exceptionsNoel Grandin
(*) if we are already throwing a Wrapped*Exception, get the exception using cppu::getCaughtexception. (*) when catching and then immediately throwing UNO exceptions, use cppu::getCaughtException to prevent exception slicing (*) if we are going to catch an exception and then immediately throw a RuntimeException, rather throw a WrappedTargetRuntimeException and preserve the original exception information. Change-Id: Ia7a501a50ae0e6f4d05186333c8517fdcb17d558 Reviewed-on: https://gerrit.libreoffice.org/54692 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-25loplugin:passstuffbyrefNoel Grandin
Change-Id: I785e96599bbda029adf4698d11d7f981750dec07 Reviewed-on: https://gerrit.libreoffice.org/54802 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-25improve some loggingNoel Grandin
if we're going to write "unhandled" messages, at least what is being unhandled Change-Id: I570183c92876d553f4344b979def653cbd5bb55d Reviewed-on: https://gerrit.libreoffice.org/54793 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-25SOSAW080: Derive SdrObjGroup from SdrObjListArmin Le Grand
Also simplify parent/child relationships, get rid of double data (SdrPage/Parent infos in SdrObjects, also in SdrObjList). This is all not needed - when a SdrObject is inserted to a SdrPage, get SdrPage by traveling over parents (no double info, member as soon as inserted, ...). More cleanups/reworks included, will need some more cleanups, too. Stabilizing: SetRectsDirty/DefaultStyleSheet Had to correct the SetRectsDirty stuff for 3D due to going down the hierarchy while the 2D implementation goes the other direction -> endless loops. Added special handling for 3D stuff for now (will be chnaged again when SnapRect is no longer needed at SdrObject level). Also had to adapt how the DefaultStyleSheet is set at incarnated SdrObjects - better: their properties. Since we now always have a SdrModel, it is possible to correctly initialize with the correct default StyleSheet from that SdrModel. This needs to be done after ForceDefaultAttributes and in a way that again deletes Items that are set in the StyleSheet. This leads to an error in CppunitTest_sd_import_tests where I checked tdf100491 - it is okay and thus I change the control instance of the imported, XML-dumped file. The less hard attributes, the better for Styles in general. Cleanup of comments for last two commits Corrected SvxShape::getParent() Needed to get the direct parent, so test for SdrObject first (to get SdrObjGroup/E3DScene), for SdrPage second Fixed CppunitTest_sc_subsequent_export_test Several problems arose. The used SdrCaptionObj was Cloned, but the clone not inserted to a SdrPage. This leads to not being able to access a UNO API imlementation of the SdrPage (SvxPage) on lower levels. It worked before due to SdrObject having a SdrPage* additionally to being added to a SdrPage - this is exactly the main cleanup this change does. Looked for why it is cloned, could see no reasons. The SdrCaptionObj exists during all im/export, not difference to other SdrObjects (that do not get cloned). It is not changed in any way. It *might* be to suppress a crash that happened due to UNO API Service emfio/emfio not being available in the UnitTest scenario. Interestingly it did not crash with the cloned SdrCaptionObj, but the Graphic exported was probably wrong. Fixed by no longer Cloning the SdrCaptionObj and adding emfio/emfio UNO API Service. d139f821a5b39535a3e7b9c6261df7e18f8ae8ac 910e7f4bc628a715fda7545dffaf3369d5e76ea0 ca1de01b723051e09ac37d7ec7bba978beea41c5 3a76da1471dfe75e69847f64a6a3519ad21c8c9c Change-Id: I986586e326b563acebf00d931a7084c6eb09e5f8 Reviewed-on: https://gerrit.libreoffice.org/54689 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Armin Le Grand <Armin.Le.Grand@cib.de>
2018-05-25tdf#42949 Fix IWYU warnings in sc/inc/[gh]*Gabor Kelemen
Found with bin/find-unneeded-includes Simple removal proposals are dealt with here and a bit of fallout management Change-Id: Ia6f8d4ca46d7b218f5827052ced5641367bd4478 Reviewed-on: https://gerrit.libreoffice.org/54683 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-05-24optimize ScColumn::HandleRefArrayForParallelism()libreoffice-6-1-branch-pointLuboš Luňák
Change-Id: I53b7f514be2e015445eb9cb0471c22d41c464e4e Reviewed-on: https://gerrit.libreoffice.org/54767 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2018-05-24avoid CELLTYPE_EDIT for calc's threaded calculationsLuboš Luňák
Since ScEditUtils::GetString() requires EditEngine, which is probably not completely thread-safe. Change-Id: Ie3d64f56b76a5861fa4b0a1f9cb683cd26806b35 Reviewed-on: https://gerrit.libreoffice.org/54766 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2018-05-24this should be a refNoel Grandin
mistake in commit commit f6063153db8951ca21ac3a2e36973f1d73eda4d1 tdf#117706 Multi-select copying rows between sheets broken noticed by erack Change-Id: Ia5ed3726c8f02750eec3551f7dd908120edb2553 Reviewed-on: https://gerrit.libreoffice.org/54765 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-24tdf#117706 Multi-select copying rows between sheets brokenNoel Grandin
regression from commit 6529cd54c29c5800340530a1b8182c341fbeeafb don't use heap for elements in ScRangeList where I converted some loop variables from pointers to refs, forgetting to assigning to a ref is quite different from assigning to a pointer Change-Id: I4a365006317d16a24cbb1b43994906a0d4b4d424 Reviewed-on: https://gerrit.libreoffice.org/54756 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-24member can be a ref instead of a pointerCaolán McNamara
Change-Id: Idb0c27933b42f3aef65f0bce098f9bd7a81dc034
2018-05-24ScTabViewShell is never optionalCaolán McNamara
Change-Id: I9f42fd6179c0a64cc14a051ca7c9e2ed9300f5c8
2018-05-24coverity#704702 Dereference after null checkCaolán McNamara
Change-Id: I876ffc1511b2115562039b97961c28d7b30e2c06 Reviewed-on: https://gerrit.libreoffice.org/54730 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-05-24reduce some unnecessary ScRangeList copyingNoel Grandin
and reduce unnecessary work in ScRangeList Change-Id: I0ee767fe28571f75f8a2ff980cea27c97c9797dc Reviewed-on: https://gerrit.libreoffice.org/54705 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-24Calc threading : Check for "self" references...Dennis Francis
...on indirect dependencies too. Here a self reference to any formula-group means if there are any references in a formula (of the formula-group itself or any of its dependencies) that points to any element inside the formula-group. If there are any self-references, then that formula-group can't be computed in parallel. For example, with this patch we can detect the following case:- Suppose the formula-group that we want to check is: "=(F2+G2-10)*10.0" spanning A2:A100. Let the formula-group starting at F2 be "=A1*0.1-10". The indirect dependency formula-group starting at F2, references back the elements of our original formula-group at A2. This makes the F.G at A2 unsafe for parallel computation. Concretly, this patch fixes a recalc crash on tdf#63638/1 Change-Id: I7b999a34571b191d2f70da6a3831f78b24a6b0a7 Reviewed-on: https://gerrit.libreoffice.org/54433 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins <ci@libreoffice.org>
2018-05-23Fix typoAndrea Gelmini
Change-Id: Ie9501a1cb9f8c2a747b92eb74c120816b49148d8 Reviewed-on: https://gerrit.libreoffice.org/54709 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>