sc/source/ui/cctrl/dpcontrol.cxx | 5 ----- sc/source/ui/view/gridwin4.cxx | 14 +++++++++++++- 2 files changed, 13 insertions(+), 6 deletions(-)
New commits: commit 63f47a9a08974cd9b3f18d96019794b97aec1e91 Author: Henry Castro <hcas...@collabora.com> Date: Thu May 14 14:53:23 2015 -0400 sc tiled editing: Corrected dropdown button offset Also includes: sc tiled editing: Mapping has to be turned off after drawing the buttons. Otherwise the redlines are on wrong positions in the tiled rendering case. Also - we are actually never call with something else than MAP_PIXEL, so let's kill the resetting of the mapmode; let's see if some obscure corner case bites us here. Change-Id: I8da07dd5448b8863df3148882ec50e6746760cca diff --git a/sc/source/ui/cctrl/dpcontrol.cxx b/sc/source/ui/cctrl/dpcontrol.cxx index e2c3457..f020024 100644 --- a/sc/source/ui/cctrl/dpcontrol.cxx +++ b/sc/source/ui/cctrl/dpcontrol.cxx @@ -95,9 +95,6 @@ void ScDPFieldButton::setPopupLeft(bool b) void ScDPFieldButton::draw() { - bool bOldMapEnablaed = mpOutDev->IsMapModeEnabled(); - mpOutDev->EnableMapMode(false); - if (mbBaseButton) { // Background @@ -144,8 +141,6 @@ void ScDPFieldButton::draw() if (mbPopupButton) drawPopupButton(); - - mpOutDev->EnableMapMode(bOldMapEnablaed); } void ScDPFieldButton::getPopupBoundingBox(Point& rPos, Size& rSize) const diff --git a/sc/source/ui/view/gridwin4.cxx b/sc/source/ui/view/gridwin4.cxx index bfda05a..3919ca5 100644 --- a/sc/source/ui/view/gridwin4.cxx +++ b/sc/source/ui/view/gridwin4.cxx @@ -756,12 +756,24 @@ void ScGridWindow::DrawContent(OutputDevice &rDevice, const ScTableInfo& rTableI if ( bLogicText ) aOutputData.DrawStrings(true); // in logic MapMode if bLogicText is set aOutputData.DrawEdit(true); - pContentDev->SetMapMode(MAP_PIXEL); + + // the buttons are painted in absolute coordinates + if (bIsTiledRendering) + { + // Tiled offset nScrX, nScrY + MapMode aMap( MAP_PIXEL ); + aMap.SetOrigin(Point(nScrX, nScrY)); + pContentDev->SetMapMode(aMap); + } + else + pContentDev->SetMapMode(MAP_PIXEL); // Autofilter- und Pivot-Buttons DrawButtons(nX1, nX2, rTableInfo, pContentDev); // Pixel + pContentDev->SetMapMode(MAP_PIXEL); + aOutputData.DrawClipMarks(); // Szenario / ChangeTracking muss auf jeden Fall nach DrawGrid sein, auch bei !bGridFirst _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits