summaryrefslogtreecommitdiff
path: root/sw/source/uibase/uiview
diff options
context:
space:
mode:
authorMatteo Casalin <matteo.casalin@yahoo.com>2014-11-12 09:05:53 +0100
committerMatteo Casalin <matteo.casalin@yahoo.com>2014-11-16 16:54:42 +0100
commitf65dea36d2778b7f626ac8b07cd057110a5c3a4b (patch)
tree3b88477a134b90ec1b7717069fc8c127bb63f71d /sw/source/uibase/uiview
parent195fd6b5e3cfbf5359ea58663ae7c97f78ac4592 (diff)
sw: convert 'a ? b : sal_True' to '!a || b'
Change-Id: I7177521a9bf9c845216e2b6c91d20df93b137987
Diffstat (limited to 'sw/source/uibase/uiview')
-rw-r--r--sw/source/uibase/uiview/view2.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx
index e9591742b575..3bd1eeb94321 100644
--- a/sw/source/uibase/uiview/view2.cxx
+++ b/sw/source/uibase/uiview/view2.cxx
@@ -391,7 +391,7 @@ bool SwView::InsertGraphicDlg( SfxRequest& rReq )
{
Any aVal = xCtrlAcc->getValue( ExtendedFilePickerElementIds::CHECKBOX_LINK, 0);
OSL_ENSURE(aVal.hasValue(), "Value CBX_INSERT_AS_LINK not found");
- bAsLink = aVal.hasValue() ? *(sal_Bool*) aVal.getValue() : sal_True;
+ bAsLink = !aVal.hasValue() || *(sal_Bool*) aVal.getValue();
Any aTemplateValue = xCtrlAcc->getValue(
ExtendedFilePickerElementIds::LISTBOX_IMAGE_TEMPLATE,
ListboxControlActions::GET_SELECTED_ITEM );
@@ -426,7 +426,7 @@ bool SwView::InsertGraphicDlg( SfxRequest& rReq )
{
Any aVal = xCtrlAcc->getValue( ExtendedFilePickerElementIds::CHECKBOX_LINK, 0);
OSL_ENSURE(aVal.hasValue(), "Value CBX_INSERT_AS_LINK not found");
- bAsLink = aVal.hasValue() ? *(sal_Bool*) aVal.getValue() : sal_True;
+ bAsLink = !aVal.hasValue() || *(sal_Bool*) aVal.getValue();
Any aTemplateValue = xCtrlAcc->getValue(
ExtendedFilePickerElementIds::LISTBOX_IMAGE_TEMPLATE,
ListboxControlActions::GET_SELECTED_ITEM );