summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorArnaud Versini <arnaud.versini@gmail.com>2018-04-22 16:34:49 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-04-22 22:03:15 +0200
commit860de7575aa0c3079aac25634677248ac68c1f02 (patch)
treeb96b70a4c2a847011d2e535b35542c91da90eb67 /svx
parentfca20f3083c78cc76046e824b062b1ea20d4522b (diff)
Reuse getAccessibleRole result if possible
Change-Id: I9566cd6f01a2e21f471d5ce96948ea635729c6f6 Reviewed-on: https://gerrit.libreoffice.org/53288 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/accessibility/AccessibleControlShape.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/svx/source/accessibility/AccessibleControlShape.cxx b/svx/source/accessibility/AccessibleControlShape.cxx
index b97f164292cb..7c12cf570014 100644
--- a/svx/source/accessibility/AccessibleControlShape.cxx
+++ b/svx/source/accessibility/AccessibleControlShape.cxx
@@ -599,8 +599,9 @@ OUString AccessibleControlShape::CreateAccessibleName()
ensureControlModelAccess();
OUString sName;
- if ( getAccessibleRole() != AccessibleRole::SHAPE
- && getAccessibleRole() != AccessibleRole::RADIO_BUTTON )
+ sal_Int16 aAccessibleRole = getAccessibleRole();
+ if ( aAccessibleRole != AccessibleRole::SHAPE
+ && aAccessibleRole != AccessibleRole::RADIO_BUTTON )
{
AccessibleControlShape* pCtlAccShape = GetLabeledByControlShape();
if(pCtlAccShape)