summaryrefslogtreecommitdiff
path: root/include/svtools/grfmgr.hxx
AgeCommit message (Collapse)Author
2016-10-27loplugin:expandablemethods in svtoolsNoel Grandin
Change-Id: I126cc87c890867c3e762f86969a20d64aef63108 Reviewed-on: https://gerrit.libreoffice.org/30314 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-10-05Remove _TYPED suffix from tools/link.hxx macrosStephan Bergmann
...which was introduced with 3ead3ad52f9bb2f9d1d6cf8dfc73a0a25e6778ed "Gradually typed Link" to distinguish the new, typed versions from the old, untyped ones, but is no longer necessary since 382eb1a23c390154619c385414bdbe6f6e461173 "remove untyped Link<>" removed the old versions. Change-Id: I494025df486a16a45861fcd8192dfe0275b1103c
2016-09-30loplugin:constantparamNoel Grandin
Change-Id: Idbe8c8e6b3d44cacce296ec8c79b2b244281057c Reviewed-on: https://gerrit.libreoffice.org/29321 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-09-13loplugin:override: No more need for the "MSVC dtor override" workaroundStephan Bergmann
The issue of 362d4f0cd4e50111edfae9d30c90602c37ed65a2 "Explicitly mark overriding destructors as 'virtual'" appears to no longer be a problem with MSVC 2013. (The little change in the rewriting code of compilerplugins/clang/override.cxx was necessary to prevent an endless loop when adding "override" to OOO_DLLPUBLIC_CHARTTOOLS virtual ~CloseableLifeTimeManager(); in chart2/source/inc/LifeTime.hxx, getting stuck in the leading OOO_DLLPUBLIC_CHARTTOOLS macro. Can't remember what that isAtEndOfImmediateMacroExpansion thing was originally necessary for, anyway.) Change-Id: I534c634504d7216b9bb632c2775c04eaf27e927e
2016-09-09loplugin:constantparam in svtoolsNoel Grandin
Change-Id: I04caae0c9ae621c55e16d3bdc014a4729617feb3 Reviewed-on: https://gerrit.libreoffice.org/28757 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-09-05tdf#100442 use unordered_set for GraphicManager's maObjListAron Budea
Speeds up ImplCheckSizeOfSwappedInGraphics. maObjList didn't seem to depend on it being a vector. Change-Id: I0028186b5c4f53ae198b9b33a31c51f0b2e5eb45 Reviewed-on: https://gerrit.libreoffice.org/28439 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2016-09-05loplugin:countusersofdefaultparamsNoel Grandin
Change-Id: I38bfc88e85a9e5a024e982e555a0e0485a3010ad Reviewed-on: https://gerrit.libreoffice.org/28662 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-13loplugin:passstuffbyref in svtoolsNoel Grandin
Change-Id: Ie166eaef65e56fafe4e57a5559b587d7558d7aa4
2016-03-17loplugin:constantparam in svtoolsNoel Grandin
Change-Id: I1a3c4a36e29a6712c589ffd3aaada593880d978d Reviewed-on: https://gerrit.libreoffice.org/23304 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-01-13loplugin:unusedmethods unused return value in include/svtoolsNoel Grandin
Change-Id: Ibc83f032bb703559cc643933e53e8670bd6560b3
2016-01-10Fix typosAndrea Gelmini
Change-Id: I9a5940027423ff0791fa7da0b79b617412ce6b86 Reviewed-on: https://gerrit.libreoffice.org/21209 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2015-11-10loplugin:nullptr (automatic rewrite)Stephan Bergmann
Change-Id: I7fc4b4d5c895f241cfb052b009e943e073f3befe
2015-10-27loplugin:unusedmethodsNoel Grandin
Change-Id: I161cd52606c11b6008f5d8b1d8ee391692f91861 Reviewed-on: https://gerrit.libreoffice.org/19231 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-10-23com::sun::star->css in include/sot to include/typelibNoel Grandin
Change-Id: I9cd92b53370a6b6018d2f7c648890f9c014a27de
2015-10-06loplugin:unusedmethodsNoel Grandin
Change-Id: I150baadc442e57ee604563bc52965daa9d2e41af
2015-09-29loplugin:removeunusedmethods, remove unused stuffNoel Grandin
Change-Id: I35456b2a3ad2a84a1d045f09cdfb29e4c19b8350
2015-09-10convert Link<> to typedNoel Grandin
Change-Id: I7aa46c5cbaf70bea5756a4066bc620b3c40dedee
2015-08-26convert Link to TypedNoel Grandin
and make it statically allocated, no point in dynamically allocating such a small object Change-Id: If476bf5dc1e0d535383d16bc49c8d567776f16cd
2015-07-14loplugin:unusedmethods svtoolsNoel Grandin
Change-Id: I04ad31055c04a247faddf4311943ca769051473c Reviewed-on: https://gerrit.libreoffice.org/17032 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-07-02loplugin:unusedmethods toolsNoel Grandin
Change-Id: I45f5489233879126d4f9ee3d01db504d950bb597 Reviewed-on: https://gerrit.libreoffice.org/16656 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-06-29remove custom RTTI from SvDataCopyStreamNoel Grandin
nothing is using it, except perhaps for XFillExchangeData, which was using it incorrectly :-( Change-Id: Ib9246a20bc97ad91d3e3e97fa642217686fc8c46
2015-05-06convert BMP_MIRROR constants to scoped enumNoel Grandin
and fix bug in svx/source/xoutdev/_xoutbmp.cxx,XOutBitmap::MirrorGraphic where it was not correctly translating between different flags types. Change-Id: I78b4965544da2aa54b67ec18307fa54c8ffc3aee
2015-05-05Use typed Timer::SetTimeoutHdl LinkStephan Bergmann
Change-Id: Iaaf0c93e5b28c0f7dbe4f02eda8beeae30708100
2015-04-30Gradually typed LinkStephan Bergmann
Turn the Link class into a template abstracting over the link's argument and return types, but provide default template arguments that keep the generic, unsafe "void* in, sal_IntPtr out" behvior. That way, individual uses of the Link class can be updated over time. All the related macros are duplicated with ..._TYPED counterparts, that additionally take the RetType (except for LINK_TYPED, which manages to infer the relevant types from the supplied Member). (It would have been attractive to change the "untyped" LinkStubs from taking a void* to a properly typed ArgType parameter, too, but that would cause -fsanitize=function to flag uses of "untyped" Link::Call.) Change-Id: I3b0140378bad99abbf240140ebb4a46a05d2d2f8
2015-04-22convert ADJUSTMENT_ flags to scoped enumNoel Grandin
Change-Id: I2b3d50eb7cbc3abc4cdc7e94219852f678b45e13
2015-04-22convert GRFMGR_DRAW_ constants to scoped enumNoel Grandin
Change-Id: Ie0b4cc1d2cfa740d0e260db52db635c3fe6b90b6
2015-04-09loplugin:staticmethodsNoel Grandin
Change-Id: I715374b531da2850434b2436633b6042ecb9ebe0
2015-03-19loplugin:constantfunction: svtoolsNoel Grandin
Change-Id: I42479fb10878a0a1c2071f7b35ae375061781d40
2015-02-22More improvements of graphic cache size handlingZolnai Tamás
* ImplFillSwappedGraphicObject method is part of the old caching mechanism which interferes with the newer one, so remove this method. * Use Graphic size directly becuase in some case it does not match with the GraphicObject's size. * Assertions to avoid underflow of mnUsedSize Change-Id: I3381f49ca05e3e5d565848c8af24c78e7b9ac3af
2015-01-26followup code removal after changing virtual methods to non-virtualNoel Grandin
This cleanups up indentation and removes dead classes. This is a followup patch to commit 272b1dd55797aacf511fb4342b0054e3697243f6 "new loplugin: change virtual methods to non-virtual" Change-Id: I1c2139589cf8cb23bb9808defe22c51039d38de1
2015-01-26new loplugin: change virtual methods to non-virtualNoel Grandin
Where we can prove that the virtual method is never overriden. In the case of pure-virtual methods, we remove the method entirely. Sometimes this leads to entire methods and fields being eliminated. Change-Id: I138ef81c95f115dbd8c023a83cfc7e9d5d6d14ae
2015-01-08An odd way to say "nullptr"Stephan Bergmann
Change-Id: I6d83714b78c4d149dff5ea56483d7afa6d0eb677
2015-01-08Sane SvStream* fake pointer values for 64-bit platformsStephan Bergmann
cf. <https://gerrit.libreoffice.org/#/c/13659/3> "Signed/Unsigned mismatch on x86_64 platform on windows" Change-Id: Ie526ee431f59be374d61fe8c38bdf2a579a7234b
2015-01-08brute-force find-and-remove of unused #define constants.Noel Grandin
Change-Id: I7223530ae37297a76654cd00cc1fedb56dbe3adb
2014-12-03Linked graphic is not displayedZolnai Tamás
Regression from: 17475638138c92162be1c0f34cf1f9cc95c63579 Change-Id: Ie2d484fbe065c24d19938c8c9c68818bd1076f2d
2014-11-07Optimize ImplCheckSizeOfSwappedInGraphics() a bitZolnai Tamás
Store used size as a member so we don't need to recalculate it all the time and no need to use a size map. Change-Id: I1f929c5d3a56f545cef123bda087ecaf8ca0be4a
2014-11-07Swapping Graphic is a privilage of GraphicObject.Zolnai Tamás
This means more things: * Graphic won't swap out itself, so those classes which uses Graphic without GraphicObject won't need to deal with swapping. * When a Graphic is queried from GraphicObject the caller won't need to deal with swapping, because GraphicObject swaps it in before return. * GraphicObject will swap in the Graphic always when a swapping dependent data is queried (e.g. whole graphic, transformed graphic or AnimationNotifyHdl) Change-Id: I2bf6e37291ec94146f10aac4a35084682437ed16
2014-11-07Remove unused IsInSwap() methodZolnai Tamás
Change-Id: Ib295bd71b5cf16fd75d04818dfd415ff24cb2655
2014-11-07Paint background images always via drawinglayerZolnai Tamás
Painting via GraphicObject is obsolete. See fdo#68927 where the problem was the quality of svg graphics, it seems a good idea to extend this improvement to all graphic type. Change-Id: I57a26d4fcfea8e4f666504a90281365e8a9a7e1d
2014-11-07Avoid an image loss situation of auto swappingZolnai Tamás
Before an image data is used GraphicObject should be swapped in. When a GraphicObject is swapped in auto swapping mechanism is triggered which can swap out some of the images. We should avoid to swap out the same image on which the swap in method was called before because the caller code assumes that the image data is there. Change-Id: Ia4addc370742aea5fbf185cf87e3c062a5ebf5be
2014-11-07Make SetSwapState() an internal methodZolnai Tamás
So we can be sure it is always called when user data changed. Change-Id: If107907afffb85a7a57817f5807847a5c028416c
2014-09-30fdo#82577: Handle PolyPolygonNoel Grandin
Put the TOOLS PolyPolygon class in the tools namespace. Avoids clash with the Windows PolyPolygon typedef. Change-Id: I811ecbb3d55ba4ce66e4555a8586f60fcd57fb66
2014-09-29loplugin: cstylecastNoel Grandin
Change-Id: Iea517d2287bded4a702c73dfdd1f182023425d67
2014-07-15Resolves: #i125111# limit mem footprint for GraphicObjects...Armin Le Grand
in 32Bit environments Conflicts: svtools/inc/svtools/grfmgr.hxx svtools/source/graphic/grfmgr.cxx svtools/source/graphic/grfmgr2.cxx sw/source/core/doc/notxtfrm.cxx sw/source/core/graphic/ndgrf.cxx "commit 62b0eaf37c08dd27244e77b8bc90c691b000ebd6 Related: fdo#50697 reset the cache timeout on GetGraphic so the graphic gets swapped out Xms after the last use and not Xms after initial creation regardless of if it got used a moment earlier." corrected place for stl sort function for linux (cherry picked from commit a48414a396f7de4e00510e82e3744c097ce3d5d6) Conflicts: svtools/source/graphic/grfmgr2.cxx Change-Id: I79158b7d42629f8dec2bc5565540701bcd3ef6f4 6f21c7fd4d2681446fc1a6d9607366a1e69165a1
2014-04-29Related: fdo#50697 reset the cache timeout on GetGraphicCaolán McNamara
so the graphic gets swapped out Xms after the last use and not Xms after initial creation regardless of if it got used a moment earlier. Change-Id: I1458f307d090ecd8d8d031b545f23e78bf1bcb67
2014-04-01Explicitly mark overriding destructors as "virtual"Stephan Bergmann
It appears that the C++ standard allows overriding destructors to be marked "override," but at least some MSVC versions complain about it, so at least make sure such destructors are explicitly marked "virtual." Change-Id: I0e1cafa7584fd16ebdce61f569eae2373a71b0a1
2014-03-26First batch of adding SAL_OVERRRIDE to overriding function declarationsStephan Bergmann
...mostly done with a rewriting Clang plugin, with just some manual tweaking necessary to fix poor macro usage. Change-Id: I71fa20213e86be10de332ece0aa273239df7b61a
2014-03-26Split TYPEINFO into plain and TYPEINFO_OVERRIDEStephan Bergmann
...where the latter contains SAL_OVERRIDE annotations Change-Id: Id64794b388d83dfe7026440e8b20a5b5efd412d1
2014-03-24svtools: sal_Bool->boolNoel Grandin
Change-Id: Ic9b4838c4d1b4d2d2ea4665811dd396bdbec31b7
2014-03-16SwapIn/SwapOut can return bool + sal_Bool to boolMatteo Casalin
Change-Id: Ia5477d6bb83af38435b9ac44359fe2f46b00807c