summaryrefslogtreecommitdiff
path: root/embeddedobj
AgeCommit message (Collapse)Author
2015-12-23loplugin:unusedfields in desktopNoel Grandin
Change-Id: Ic816a7faf4d357d16c13f67533b3b409a531d14c
2015-12-20embeddedobj: do not automatically convert alien objects to ownMichael Stahl
OleEmbeddedObject::changeState() calls TryToConvertToOOo() on non-WNT platforms, which appears highly questionable to me, added in commit 0c3d5fb0ad35ff7fc18917fc86fa58d9312fe3ae. What this does effectively is load the embedded object, store it as ODF, and then load it again as ODF. For one, it doesn't work in all cases currently. If changeState() is not called from the UI but from some filter code, then no m_xClient may be set on the OleEmbeddedObject, hence no m_xClient will be set on the new m_xWrappedObject. Then loading the embedded object will raise errors due to missing BaseURL, and storing it will fail in SfxObjectShell::SaveTo_Impl(). (It would be possible to solve that by copying the "DefaultParentBaseURL" handling code from OCommonEmbeddedObject.) The only reason why the previous code in ShapeExport::WriteOLE2Shape() was able to export the object despite the error is that it does not call SfxBaseModel functions but directly invokes the export filter, so the sfx2 code does not get an opportunity to check its error status. For another, doing this only on non-WNT platforms is also hazardous. It's probably better to leave conversion to own formats to an explicit UI action, as the OleEmbeddedObject::doVerb(-9) magic currently does, where it can hopefully be assumed that the caller at least established the client connection first. Change-Id: Ice3d8f8ceabe81b6e9025957c3eb87de9dbfe61a
2015-12-08consolidate MSO format ClassID magic numbers in msfilter/classids.hxxMichael Stahl
Change-Id: I673eeaa4168f769cb002995c43d986ee5f2030b2
2015-11-28-Werror,-Wunused-functionStephan Bergmann
Change-Id: I6103a8539c4d788fff1a7e3c3530a6ec7cd1f0c6
2015-11-26mark UNO structs as SAL_WARN_UNUSED, where possibleNoel Grandin
Change-Id: Ie3de518f60c9f1313c68df54dbdc1fb2804f1f0d
2015-11-15use initialiser syntax for Sequence<OUString>Noel Grandin
replaced using the script: git grep -lP 'Sequence.*OUString.*\(1\)' | xargs perl -0777 -pi -e "s/Sequence< OUString > (\w+)\(1\); .*\[0\] = (\S+);/Sequence< OUString > \1 { \2 };/g" Change-Id: I23688a91562051a8eed11fc2a85599545c285c34 Reviewed-on: https://gerrit.libreoffice.org/19967 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-11-10loplugin:nullptr (automatic rewrite)Stephan Bergmann
Change-Id: I225d5fe2e3476121e2ca307d815d5615e32311d7
2015-11-06loplugin:stringconstant: elide explicit ctor usage (automatic rewrite)Stephan Bergmann
Change-Id: I5528b17c106aefde4c58dfef00e30fdcf62f7db7
2015-11-04yyyyyNoel Grandin
Change-Id: I9a947beefd2dfe21da8239e841ea3fb416bd1548
2015-10-31use uno::Reference::set method instead of assignmentNoel Grandin
Change-Id: I150f213ab033f5fc1b50abe4e1529292206c9feb Reviewed-on: https://gerrit.libreoffice.org/19689 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-10-30UNO: no need to use OUString constructor when calling createInstanceNoel Grandin
Change-Id: I37da28539b94706574116d0fff5f008aabfb5526 Reviewed-on: https://gerrit.libreoffice.org/19682 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-10-21remove untyped Link<>Noel Grandin
Change-Id: I809f9e10309ceadda0a82c3818277323b34ec61b Reviewed-on: https://gerrit.libreoffice.org/19491 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-10-12Replace "SAL_OVERRIDE" with "override" in LIBO_INTERNAL_ONLY codeStephan Bergmann
Change-Id: I2ea407acd763ef2d7dae2d3b8f32525523ac8274
2015-10-01com::sun::star->css in embeddedobj/Noel Grandin
Change-Id: Ia04fc28ce8e1d70f86520edf2df8c98f7b455465 Reviewed-on: https://gerrit.libreoffice.org/19024 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-09-30Fix typosAndrea Gelmini
Change-Id: Iaa9dd3f02f21947742643349d3b878126017477d Reviewed-on: https://gerrit.libreoffice.org/18947 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2015-09-13cppcheck: noExplicitConstructorCaolán McNamara
Change-Id: I39194062ba68c4cb1ccc9b93c629f005ccd02497
2015-08-14loplugin: defaultparamsNoel Grandin
Change-Id: I455b200febc9939f3fb81597938b26c0e9eb5f74
2015-08-03tdf#88206 replace cppu::WeakImplHelper* etc.Takeshi Abe
with the variadic variants in embeddedobj. Change-Id: I60aad1267b664825f781c085fb33612bce3f7221 Reviewed-on: https://gerrit.libreoffice.org/17474 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-07-24loplugin:unusedmethodsNoel Grandin
Change-Id: If5090c330e12d6e537766bf4a9be0a2360381a7a Reviewed-on: https://gerrit.libreoffice.org/17312 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-07-21Miscellaneous typosAdolfo Jayme Barrientos
Change-Id: I5187364d420ab78c36a91632efab9c32951d867a
2015-07-16for now show chart sidebarMarkus Mohrhard
This is a hack that needs to be cleaned up later. Change-Id: I2772fe6ff8a4792d746a29653635d3eca4088e68
2015-07-16fix indentationMarkus Mohrhard
Change-Id: I4bceb79ed4adda085727dfcee1ba3573811e53b3
2015-07-16fix indentationMarkus Mohrhard
Change-Id: Ifda010d2a8f51c6981cac889bfaa1edaacd22df2
2015-06-29coverity#1308586 Uncaught exceptionCaolán McNamara
Change-Id: I86097e94dd47153a919bb7721376c5b98b50354e
2015-06-28Fix typosAndrea Gelmini
Change-Id: Ifd126a535f18db79a18aaec61b76cdf26ab33dff Reviewed-on: https://gerrit.libreoffice.org/16522 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2015-06-23Resolves: tdf#91683 Revert avoid activating chart objects...Caolán McNamara
just to get their mapunit or set visual size. Will have to try something different here apparently This reverts commit 757f461ef12548af0be470f7c05ff67df3dc1314. (cherry picked from commit f2b3519c6b2aceacbe2fd9d53eb52dd36a356ecc)
2015-06-17Replace boost::scoped_array<T> with std::unique_ptr<T[]>Takeshi Abe
This may reduce some degree of dependency on boost. Done by running a script like: git grep -l '#include *.boost/scoped_array.hpp.' \ | xargs sed -i -e 's@#include *.boost/scoped_array.hpp.@#include <memory>@' git grep -l '\(boost::\)\?scoped_array<\([^<>]*\)>' \ | xargs sed -i -e 's/\(boost::\)\?scoped_array<\([^<>]*\)>/std::unique_ptr<\2[]>/' ... and then killing duplicate or unnecessary includes, while changing manually m_xOutlineStylesCandidates in xmloff/source/text/txtimp.cxx, extensions/source/ole/unoconversionutilities.hxx, and extensions/source/ole/oleobjw.cxx. Change-Id: I3955ed3ad99b94499a7bd0e6e3a09078771f9bfd Reviewed-on: https://gerrit.libreoffice.org/16289 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-06-17More helpful exception messageLionel Elie Mamane
Change-Id: I63dcc98667ebfc94cc16407d283e65e1514d89fb
2015-06-16Fix typosAndrea Gelmini
Change-Id: Id8c7cf460cba5af89891c470e1aaa61b227d356e Reviewed-on: https://gerrit.libreoffice.org/16310 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2015-06-15remove unnecessary check for null when calling deleteNoel Grandin
Idea originally from caolan. Found using the following command: find . -name *.cxx | xargs /opt/local/bin/grep -zlP '(?m)if\s*\(\s*\w+\s*\)\s*delete\s+\w+\;' Change-Id: I3338f4e22193a6dfd6219c8c75835224a3392763
2015-06-08loplugin:cstylecast: deal with remaining pointer castsStephan Bergmann
Change-Id: Ie55f464ef2eca344d3c1292713ded2710c47cc53
2015-05-19tdf#67421: Prevent unloading objects due to cache fullMike Kaganski
When an object is added to OLE objects cache, when cache is full, old objects are tried to be unloaded. This triggers notifications that cause all loaded objects to become active, and to be added to cache (moved to front). As the new object already was added to front of the cache, later activity pushes it to back, until it is the last object in cache. The cache in this process is overfilled, so each next refresh tries to unload current last OLE object. So, in the end, this effectively unloads all cached OLE objects. This patch prevents this by first unloading last object, and then adding new object to front of cache. Also, removed needless creation of reference (makes at least 200 function calls for no reason). Change-Id: Ia903f4df101971df1b0b0148320fc8e45ac1e79c Reviewed-on: https://gerrit.libreoffice.org/15772 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2015-05-10Use IMPL_LINK_NOARG[_TYPED] where applicableStephan Bergmann
Change-Id: I70598072c1d492e360ef46dd7b5ef5a2fa4be495
2015-05-10NOINSTANCE is implied now in IMPL_STATIC_LINK...Stephan Bergmann
Change-Id: Ifb032457d6c1b279c4183282ef2b271c706dd71a
2015-05-10Replace IMPL_STATIC_LINK[_TYPED] with more useful variantsStephan Bergmann
Change-Id: Ic91c8126b8e9a5a7eeed4c356b783c8bebccecf3
2015-05-04embeddedobj: allow creating objects lacking a FileFormatVersion=6800 filterMiklos Vajna
dbaccess::ODatabaseDocument::loadFromStorage() is still not implemented, though. Change-Id: I1be11f2a2274f67dd0a11f96a718394d5f72605f
2015-04-30embeddedobj: allow embedding objects lacking a FileFormatVersion=6800 filterMiklos Vajna
The "own" filter of Base has FileFormatVersion=6200. Change-Id: I3bbd28ebcf4d517ea9cefe692b01b688358c51e8
2015-04-29Remove unnecessary STATIC_LINK macroStephan Bergmann
Change-Id: I4788824667c8e0d1d4e0717b7ae7737bb0fd2c90
2015-04-15remove unnecessary use of void in function declarationsNoel Grandin
ie. void f(void); becomes void f(); I used the following command to make the changes: git grep -lP '\(\s*void\s*\)' -- *.cxx \ | xargs perl -pi -w -e 's/(\w+)\s*\(\s*void\s*\)/$1\(\)/g;' and ran it for both .cxx and .hxx files. Change-Id: I314a1b56e9c14d10726e32841736b0ad5eef8ddd
2015-04-13loplugin:staticmethodsNoel Grandin
Change-Id: I33a8ca28b0c3bf1c31758d93238e74927bebde9c
2015-04-01Replace remaining getCppuType et al with cppu::UnoTypeStephan Bergmann
Change-Id: I1ee944679d509929e47218f88b6fe4be4905a202
2015-03-31Reduce to static_cast any reinterpret_cast from void pointersStephan Bergmann
Change-Id: Iad5d2858976ed789823aaac3aa7f2937233f1dfc
2015-03-27avoid activating chart objects just to get their mapunit or set visual sizeCaolán McNamara
the motivation is SwWrtShell::CalcAndSetScale and the assert/crash triggered by ooo58458-1.odt ooo84729-2.odt ooo75058-1.odt ooo123605-1.odt ooo102990-1.odt fdo57249-1.odt fdo50880-1.odt fdo70223-5.odt ooo30052-2.odt ooo119280-1.odt ooo79009-1.odt ooo58182-2.odt ooo59992-1.odt ooo123607-1.odt ooo89304-1.odt ooo91578-5.odt ooo89303-1.odt ooo30052-1.odt fdo65664-3.odt ooo119941-1.odt ooo55761-1.odt fdo57249-2.odt ooo83229-3.odt ooo84729-1.odt ooo102990-2.odt ooo37749-1.sxw ooo38798-1.sxw ooo27909-1.sxw getMapUnit activates the object which can cause chart object to load data from the current document and appears to attempt to stop and resume pending layout actions which can't be done if layout is underway, hence the assert from the inner SwLayAction::SwLayAction triggered by the runstate while an SwLayAction::SwLayAction is already active for counting the number of pdf output pages. getMapUnit always returns the same result regardless of anything else and the assumption is that we don't need to be in run state to setVisualSize on it Change-Id: Ie75b159b140de223a56324b39699d703c3b40bb9
2015-03-09V801: Decreased performanceCaolán McNamara
Change-Id: I9e9a00acf9503980f0c6c7cd0a20378e5ca7390d
2015-03-05gbuild: set _WIN32_WINNT globally instead of WINVERMichael Stahl
... and remove the definitions in makefiles, except in fpicker, which defines a different value for the Vista file picker. The WINVER value is derived automatically from _WIN32_WINNT by SDK header sdkddkver.h. Change-Id: I73358a9bf5d070f71821654cae2a29335a754a21
2015-02-23remove unnecessary parenthesis in return statementsNoel Grandin
found with $ git grep -lP 'return\s*\(\s*\w+\s*\)\s*;' Change-Id: Ic51606877a9edcadeb647c5bf17bc928b69ab60e
2015-02-14tdf#88624 set DocumentBaseURL when saving reportLionel Elie Mamane
regression from 1d38cb365543924f9c50014e6b2227e77de1d0c9 Change-Id: Ia8cfe47b9d92889b3724f394db5090a59e69dd48
2015-02-02add an explicit virtual keyword here, like the other onesCaolán McNamara
Change-Id: I4c5acf42d5ec33df1dd18dc3a70be7de838c9ff3
2015-02-02OOoEmbeddedObjectFactory does implement optional XLinkFactoryStephan Bergmann
regression from 251f1b0b38be7d1267339898e44e320f05849e22 "fdo#46808, Adapt embed::*EmbeddedObjectCreator UNO services to new style" Change-Id: Id8b49c04183d3bc98f22398a8e43c80909c1ea11
2015-02-02callcatcher: remove some unused methodsCaolán McNamara
Change-Id: Id3ca991e9ede13512a39865496429aabb7e71088