[PATCH] avoid ambiguous else

Takeshi Abe tabe at fixedpoint.jp
Wed Feb 2 10:13:53 PST 2011


---
 sc/source/ui/miscdlgs/acredlin.cxx |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/sc/source/ui/miscdlgs/acredlin.cxx b/sc/source/ui/miscdlgs/acredlin.cxx
index ceba5b4..27b1150 100644
--- a/sc/source/ui/miscdlgs/acredlin.cxx
+++ b/sc/source/ui/miscdlgs/acredlin.cxx
@@ -343,10 +343,10 @@ BOOL ScAcceptChgDlg::IsValidAction(const ScChangeAction* pScChangeAction)
     aComment.EraseAllChars('\n');
 
     if(eType==SC_CAT_CONTENT)
-        if(!pScChangeAction->IsDialogParent())
-            pScChangeAction->GetDescription( aDesc, pDoc, TRUE);
-    else
-        pScChangeAction->GetDescription( aDesc, pDoc,!pScChangeAction->IsMasterDelete());
+    {
+        BOOL bTest = !pScChangeAction->IsDialogParent() || !pScChangeAction->IsMasterDelete();
+        pScChangeAction->GetDescription( aDesc, pDoc, bTest );
+    }
 
     if(aDesc.Len()>0)
     {
-- 
1.7.2.3


----Next_Part(Thu_Feb__3_03_20_16_2011_268)----


More information about the LibreOffice mailing list