From 0dec0cdd711d87ec1741b4b66e8060d2f13a4496 Mon Sep 17 00:00:00 2001
From: Pranav Kant <pranavk@gnome.org>
Date: Sat, 6 Jun 2015 00:36:54 +0530
Subject: [PATCH 021/398] lokdocview: fix render calls after LOK callbacks
Change-Id: Ib33f0e1dcf257350be1e2cf6c49cd92494472a55
(cherry picked from commit 085f31a435eed43e3b7927e10309ddd00fb5b9a5)
---
libreofficekit/source/gtk/lokdocview.cxx | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/libreofficekit/source/gtk/lokdocview.cxx b/libreofficekit/source/gtk/lokdocview.cxx
index 42dd14cb34ed..6c3176783953 100644
--- a/libreofficekit/source/gtk/lokdocview.cxx
+++ b/libreofficekit/source/gtk/lokdocview.cxx
@@ -949,21 +949,18 @@ gboolean LOKDocView_Impl::callbackImpl(CallbackData* pCallback)
{
GdkRectangle aRectangle = LOKDocView_Impl::payloadToRectangle(pCallback->m_aPayload.c_str());
setTilesInvalid(aRectangle);
- renderDocument(0);
}
else
- {
m_pTileBuffer->resetAllTiles();
- renderDocument(0);
- }
+
+ gtk_widget_queue_draw(m_pDrawingArea);
}
break;
case LOK_CALLBACK_INVALIDATE_VISIBLE_CURSOR:
{
m_aVisibleCursor = LOKDocView_Impl::payloadToRectangle(pCallback->m_aPayload.c_str());
m_bCursorOverlayVisible = true;
- setTilesInvalid(m_aVisibleCursor);
- renderDocument(0);
+ gtk_widget_queue_draw(m_pDrawingArea);
}
break;
case LOK_CALLBACK_TEXT_SELECTION:
@@ -1030,7 +1027,6 @@ gboolean LOKDocView_Impl::callbackImpl(CallbackData* pCallback)
gtk_widget_set_size_request(m_pDrawingArea,
twipToPixel(m_nDocumentWidthTwips, m_fZoom),
twipToPixel(m_nDocumentHeightTwips, m_fZoom));
- m_pTileBuffer->resetAllTiles();
}
break;
case LOK_CALLBACK_SET_PART:
--
2.12.0