diff options
author | Mihai Varga <mihai.varga@collabora.com> | 2015-11-06 14:34:28 +0200 |
---|---|---|
committer | Mihai Varga <mihai.mv13@gmail.com> | 2015-11-13 09:55:19 +0200 |
commit | 96cd2abd748ed24e5aba50cc4c300cf06e512db3 (patch) | |
tree | a1e6636aef83f49a1d9ee81c87d0a9f71c88b5d2 /include/vcl/ITiledRenderable.hxx | |
parent | 249f8b1cc9897ac9666dd5c69dc22fae7586c207 (diff) |
LOK: setClientZoom() - sets the client zoom level
We need to know the client's view level to correctly handle the mouse
events in calc. PaintTile() set a zoom level that corresponds to the
requested tiles and previously postMouseEvent would call SetZoom(1,1).
Now we can make use of knowing the client's view level and call
SetZoom() with the correct parameters
Change-Id: I34b5afcdcc06a671a8ac92c03e87404e42adf4cd
Conflicts:
sc/source/ui/unoobj/docuno.cxx
Diffstat (limited to 'include/vcl/ITiledRenderable.hxx')
-rw-r--r-- | include/vcl/ITiledRenderable.hxx | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/include/vcl/ITiledRenderable.hxx b/include/vcl/ITiledRenderable.hxx index 99c31b8da9a7..e1cdf83ac439 100644 --- a/include/vcl/ITiledRenderable.hxx +++ b/include/vcl/ITiledRenderable.hxx @@ -23,6 +23,9 @@ namespace vcl class VCL_DLLPUBLIC ITiledRenderable { +protected: + int nTilePixelWidth, nTilePixelHeight; + int nTileTwipWidth, nTileTwipHeight; public: virtual ~ITiledRenderable(); @@ -180,6 +183,21 @@ public: /// If the current contents of the clipboard is something we can paste. virtual bool isMimeTypeSupported() = 0; + + /** + * Save the client's view so that we can compute the right zoom level + * for the mouse events. + * @param nTilePixelWidth - tile width in pixels + * @param nTilePixelHeight - tile height in pixels + * @param nTileTwipWidth - tile width in twips + * @param nTileTwipHeight - tile height in twips + */ + virtual void setClientZoom(int /*nTilePixelWidth*/, + int /*nTilePixelHeight*/, + int /*nTileTwipWidth*/, + int /*nTileTwipHeight*/) + { + } }; } // namespace vcl |