diff options
author | Szymon Kłos <szymon.klos@collabora.com> | 2020-06-16 11:42:13 +0200 |
---|---|---|
committer | Szymon Kłos <szymon.klos@collabora.com> | 2020-07-02 13:15:55 +0200 |
commit | 4bc6799cbf00715b2a0a8f5553d8600ca04c3882 (patch) | |
tree | 4d66fdfe8fc9c8cc1a4173eb41740fc15d3fadbe /sw | |
parent | 2581a31ee06b03d3524f7c668e3cc42c99129482 (diff) |
Getting styles info shouldnt set document modification state
Getter function modified document's 'is modified' state
and broadcasted it due to internal styles creation/delete
That caused spam of SwCursorShell::UpdateCursor calls
when styles preview widget was used in the notebookbar.
Change-Id: I22ee4e820adf79f6e816cb35161cb21f26abb2b0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96921
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/97733
Tested-by: Jenkins
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/uibase/app/docstyle.cxx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sw/source/uibase/app/docstyle.cxx b/sw/source/uibase/app/docstyle.cxx index 458c01d8d725..3a933b50bdd3 100644 --- a/sw/source/uibase/app/docstyle.cxx +++ b/sw/source/uibase/app/docstyle.cxx @@ -1289,7 +1289,14 @@ std::unique_ptr<SfxItemSet> SwDocStyleSheet::GetItemSetForPreview() // time, return one "flattened" item set that contains all items from // all parents. std::unique_ptr<SfxItemSet> pRet; + + bool bModifiedEnabled = rDoc.getIDocumentState().IsEnableSetModified(); + rDoc.getIDocumentState().SetEnableSetModified(false); + FillStyleSheet(FillPreview, &pRet); + + rDoc.getIDocumentState().SetEnableSetModified(bModifiedEnabled); + assert(pRet); return pRet; } |