sw/source/core/layout/paintfrm.cxx |    1 +
 1 file changed, 1 insertion(+)

New commits:
commit 3215fcdc58f0835857dedfc91573b9c891f3ae0a
Author:     Skyler Grey <[email protected]>
AuthorDate: Mon Jul 29 08:00:47 2024 +0000
Commit:     Miklos Vajna <[email protected]>
CommitDate: Wed Aug 7 13:10:05 2024 +0200

    cool#9654 fix: Skip invalidation if it won't go through
    
    On Android, we often hit this condition where we should get an
    invalidation. Unfortunately, the invalidation is skipped due to being in
    LOK Tiled Painting, leaving us to deal with whatever tile was rendered
    on this go-around...
    
    ...Also because of this condition, the tile rendered here is broken.
    pFrame->PaintSwFrame is never called, leading to a tile which renders
    without things like its text. Normally, this wouldn't be a problem as
    it's about to get invalidated, and is more of a nice performance
    optimization...
    
    ...However given we don't invalidate it, we really see that tile without
    any text. Similar workarounds were considered (such as skipping the
    condition in another case that appears to be true on Android or
    rendering the tile anyway, even if we're about to invalidate it) but
    this seems to be the safest bet to avoid something like this happening
    on other platforms...
    
    ...The true solution is still elusive. It probably includes figuring out
    why this happens on Android without happening on other platforms, and
    fixing that, as well as perhaps figuring out what to do about this
    condition if we *do* genuinely trigger it on Android - as the previous
    solution of invalidating everything nearby won't work
    
    Change-Id: Id58f5bae8ae357d116c5f2345e88ec3364cb2172
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171578
    Reviewed-by: Miklos Vajna <[email protected]>
    Tested-by: Jenkins

diff --git a/sw/source/core/layout/paintfrm.cxx 
b/sw/source/core/layout/paintfrm.cxx
index a9b8c1db17ff..f8c657d16784 100644
--- a/sw/source/core/layout/paintfrm.cxx
+++ b/sw/source/core/layout/paintfrm.cxx
@@ -3787,6 +3787,7 @@ void SwLayoutFrame::PaintSwFrame(vcl::RenderContext& 
rRenderContext, SwRect cons
         if ( rRect.Overlaps( aPaintRect ) )
         {
             if ( bCnt && pFrame->IsCompletePaint() &&
+                 !(comphelper::LibreOfficeKit::isActive() && 
comphelper::LibreOfficeKit::isTiledPainting()) &&
                  !rRect.Contains( aPaintRect ) && Application::AnyInput( 
VclInputFlags::KEYBOARD ) )
             {
                 //fix(8104): It may happen, that the processing wasn't complete

Reply via email to