[Libreoffice-commits] core.git: sd/source
Jim Raykowski (via logerrit)
logerrit at kemper.freedesktop.org
Thu Apr 8 04:14:43 UTC 2021
sd/source/ui/dlg/navigatr.cxx | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
New commits:
commit f458b30b15526e95a6d25820450241fd6234171c
Author: Jim Raykowski <raykowj at gmail.com>
AuthorDate: Wed Apr 7 18:49:56 2021 -0800
Commit: Jim Raykowski <raykowj at gmail.com>
CommitDate: Thu Apr 8 06:14:03 2021 +0200
tdf#141511 fix null pointer use crash
Change-Id: I196216d10829df99629e4e97aad7db622c3378e9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113779
Tested-by: Jenkins
Reviewed-by: Jim Raykowski <raykowj at gmail.com>
diff --git a/sd/source/ui/dlg/navigatr.cxx b/sd/source/ui/dlg/navigatr.cxx
index c0e2ec79992e..c8d23c068491 100644
--- a/sd/source/ui/dlg/navigatr.cxx
+++ b/sd/source/ui/dlg/navigatr.cxx
@@ -639,10 +639,13 @@ void SdNavigatorControllerItem::StateChanged( sal_uInt16 nSId,
{
const auto pDrawViewShell =
static_cast<::sd::DrawViewShell *>(pDrawDocShell->GetViewShell());
- bool bEditModePage(pDrawViewShell->GetEditMode() == EditMode::Page);
- pNavigatorWin->mxToolbox->set_sensitive(bEditModePage);
- pNavigatorWin->mxLbDocs->set_sensitive(bEditModePage);
- pNavigatorWin->mxTlbObjects->set_sensitive(bEditModePage);
+ if (pDrawViewShell)
+ {
+ bool bEditModePage(pDrawViewShell->GetEditMode() == EditMode::Page);
+ pNavigatorWin->mxToolbox->set_sensitive(bEditModePage);
+ pNavigatorWin->mxLbDocs->set_sensitive(bEditModePage);
+ pNavigatorWin->mxTlbObjects->set_sensitive(bEditModePage);
+ }
}
const SfxUInt32Item& rStateItem = dynamic_cast<const SfxUInt32Item&>(*pItem);
More information about the Libreoffice-commits
mailing list