svx/source/dialog/rubydialog.cxx | 8 ++++++-- svx/source/stbctrls/pszctrl.cxx | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-)
New commits: commit e5d68c4a4ad953d4d7d99103ee2181be38cd025b Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Wed Dec 14 14:28:50 2022 +0000 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Wed Dec 14 19:38:59 2022 +0000 Resolves: tdf#152495 crash on dismissing ruby dialog with ESC Change-Id: I26af008a7ee7b105255a1aaacff7ff30813172a4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144166 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caol...@redhat.com> diff --git a/svx/source/dialog/rubydialog.cxx b/svx/source/dialog/rubydialog.cxx index 4059e8d35c8c..3fefb5e74641 100644 --- a/svx/source/dialog/rubydialog.cxx +++ b/svx/source/dialog/rubydialog.cxx @@ -83,6 +83,7 @@ class SvxRubyData_Impl : public cppu::WeakImplHelper<css::view::XSelectionChange Sequence<PropertyValues> aRubyValues; Reference<XController> xController; bool bHasSelectionChanged; + bool bDisposing; public: SvxRubyData_Impl(); @@ -98,6 +99,7 @@ public: return xModel; } bool HasSelectionChanged() const { return bHasSelectionChanged; } + bool IsDisposing() const { return bDisposing; } Reference<XRubySelection> const& GetRubySelection() { xSelection.set(xController, UNO_QUERY); @@ -120,6 +122,7 @@ public: SvxRubyData_Impl::SvxRubyData_Impl() : bHasSelectionChanged(false) + , bDisposing(false) { } @@ -161,6 +164,7 @@ void SvxRubyData_Impl::disposing(const EventObject&) { } xController = nullptr; + bDisposing = true; } void SvxRubyData_Impl::AssertOneEntry() @@ -269,9 +273,9 @@ void SvxRubyDialog::Close() void SvxRubyDialog::Activate() { SfxModelessDialogController::Activate(); - if (!m_xContentArea) + if (m_pImpl->IsDisposing()) { - // tdf#141967 if Activate is called during tear down bail early + // tdf#141967/tdf#152495 if Activate is called during tear down bail early return; } //get selection from current view frame commit 040867fce9a992b34813dab3a4d7ab93ebccbe11 Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Wed Dec 14 12:42:01 2022 +0000 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Wed Dec 14 19:38:51 2022 +0000 table cel->table cell Change-Id: Id817e6da3c445d827584d1ece9aba195f641d506 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144165 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caol...@redhat.com> diff --git a/svx/source/stbctrls/pszctrl.cxx b/svx/source/stbctrls/pszctrl.cxx index 129ac67eb085..5eddc1981727 100644 --- a/svx/source/stbctrls/pszctrl.cxx +++ b/svx/source/stbctrls/pszctrl.cxx @@ -323,7 +323,7 @@ void SvxPosSizeStatusBarControl::StateChangedAtStatusBarControl( sal_uInt16 nSID } else if ( auto pStringItem = dynamic_cast<const SfxStringItem*>( pState) ) { - // show string (table cel or different) + // show string (table cell or different) pImpl->aStr = pStringItem->GetValue(); pImpl->bTable = true; pImpl->bPos = false;