diff options
author | Jürgen Schmidt <jsc@apache.org> | 2012-06-22 12:30:43 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-05-31 16:13:17 +0100 |
commit | 61dfc6fa942e9d9c241231fb5467c860fe95ea06 (patch) | |
tree | cd188a10033b222fab837032b0e976151f9a6144 /sw | |
parent | f0545c44400a78acea9ca7cb97de212f245efc6a (diff) |
Resolves: #i120030# optimize thumbnail creation/painting
(cherry picked from commit 255beb8f56a074ce85eaf1db3cdf168f9c09466e)
Conflicts:
sfx2/inc/sfx2/objsh.hxx
sw/source/core/layout/paintfrm.cxx
Change-Id: I23157f7a6983ba81b1c8ddcc409a4989915be2ed
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/layout/paintfrm.cxx | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx index 615d7d87430b..cb75b9e46bc1 100644 --- a/sw/source/core/layout/paintfrm.cxx +++ b/sw/source/core/layout/paintfrm.cxx @@ -3880,6 +3880,19 @@ private: void SwFlyFrm::Paint(SwRect const& rRect, SwPrintData const*const) const { + //optimize thumbnail generation and store procedure to improve odt saving performance, #i120030# + ViewShell *pShell = getRootFrm()->GetCurrShell(); + if (pShell && pShell->GetDoc() && pShell->GetDoc()->GetDocShell()) + { + sal_Bool bInGenerateThumbnail = pShell->GetDoc()->GetDocShell()->IsInGenerateAndStoreThumbnail(); + if (bInGenerateThumbnail) + { + SwRect aVisRect = pShell->VisArea(); + if (!aVisRect.IsOver(Frm())) + return; + } + } + //because of the overlapping of frames and drawing objects the flys have to //paint their borders (and those of the internal ones) directly. //e.g. #33066# |