summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2020-06-27 16:08:39 +0100
committerCaolán McNamara <caolanm@redhat.com>2020-06-27 20:22:45 +0200
commitbd02918f77636f54b13b796e205ead77ca853ed9 (patch)
tree64a15a41d36c1ba01309f83eeef40205b97b62c8
parent2a87fbc2f645e8d607c235147d7a00293cdabafc (diff)
cid#1464970 Unchecked dynamic_cast
Change-Id: I9190065a88defe9165ac79a0339a6a510b0903d8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/97314 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--sc/source/ui/app/inputwin.cxx6
1 files changed, 4 insertions, 2 deletions
diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx
index 5bdf3a4480a9..ebca73d2f9f8 100644
--- a/sc/source/ui/app/inputwin.cxx
+++ b/sc/source/ui/app/inputwin.cxx
@@ -196,8 +196,10 @@ ScInputWindow::ScInputWindow( vcl::Window* pParent, const SfxBindings* pBind ) :
InsertItem (SID_INPUT_FUNCTION, Image(StockImage::Yes, RID_BMP_INPUT_FUNCTION), ToolBoxItemBits::NONE, 2);
}
+ const bool bIsLOKMobilePhone = mpViewShell && mpViewShell->isLOKMobilePhone();
+
// sigma and equal buttons
- if (!mpViewShell->isLOKMobilePhone())
+ if (!bIsLOKMobilePhone)
{
InsertItem (SID_INPUT_SUM, Image(StockImage::Yes, RID_BMP_INPUT_SUM), ToolBoxItemBits::DROPDOWNONLY, 3);
InsertItem (SID_INPUT_EQUAL, Image(StockImage::Yes, RID_BMP_INPUT_EQUAL), ToolBoxItemBits::NONE, 4);
@@ -224,7 +226,7 @@ ScInputWindow::ScInputWindow( vcl::Window* pParent, const SfxBindings* pBind ) :
}
// sigma and equal buttons
- if (!mpViewShell->isLOKMobilePhone())
+ if (!bIsLOKMobilePhone)
{
SetItemText (SID_INPUT_SUM, ScResId( SCSTR_QHELP_BTNSUM ) );
SetHelpId (SID_INPUT_SUM, HID_INSWIN_SUMME);