diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2024-02-16 12:00:24 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2024-02-16 14:58:41 +0100 |
commit | ce350b840ce806c4060f9fdbd67fa4c95c82edf5 (patch) | |
tree | be9e37a04a3cdc980609db98cd20df1dbbb33cbc /sw/inc | |
parent | 3b04e74503ec6d07dc4befdb756e6abdc3de4e58 (diff) |
cool#8270 sw lok: fix bad statusbar pagenum string on async binding update
This is similar to commit 51d8a2ef54751403fa707816e27ddb4e7faa8231
(cool#7492 sfx2 lok: fix bad view id / statusbar string on async binding
update, 2024-01-08), but here the problem was that the async job tried
to get the current view from the model, which is not correct.
Fix the buggy page number string in the status bar by requesting callers
of SwViewShell::GetFirstLastVisPageNumbers() to provide the view, given
that SwViewShell itself doesn't have access to SwView, only the
SwWrtShell subclass would have that.
Change-Id: I7e10c05d2429ea2771d6c3e46ac9ce77c0eb2bbe
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163474
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'sw/inc')
-rw-r--r-- | sw/inc/viewsh.hxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sw/inc/viewsh.hxx b/sw/inc/viewsh.hxx index aa3999efbf7f..9318c51196fe 100644 --- a/sw/inc/viewsh.hxx +++ b/sw/inc/viewsh.hxx @@ -105,6 +105,8 @@ struct SwVisiblePageNumbers OUString sFirstCustomVirt, sLastCustomVirt; }; +class SwView; + class SW_DLLPUBLIC SwViewShell : public sw::Ring<SwViewShell> { friend void SetOutDev( SwViewShell *pSh, OutputDevice *pOut ); @@ -596,7 +598,7 @@ public: bool isOutputToWindow() const; void OnGraphicArrived(const SwRect&); - void GetFirstLastVisPageNumbers(SwVisiblePageNumbers& rVisiblePageNumbers); + void GetFirstLastVisPageNumbers(SwVisiblePageNumbers& rVisiblePageNumbers, SwView& rView); virtual void dumpAsXml(xmlTextWriterPtr pWriter) const; }; |