diff options
author | Matteo Casalin <matteo.casalin@yahoo.com> | 2014-03-30 10:38:29 +0200 |
---|---|---|
committer | Matteo Casalin <matteo.casalin@yahoo.com> | 2014-03-30 16:38:00 +0200 |
commit | 057c882c82fd5ed473b86950b5afc1f41f69c242 (patch) | |
tree | 30808c3692e663c7daf9d22f4df329908cf57861 | |
parent | c060aa34303212de017879c6b27d7f54129586c7 (diff) |
OUString: use isEmpty instead of getLength()==0
Change-Id: Iaabfc2fb1f3fdf40681959232dbd7b02b333b877
-rw-r--r-- | sw/source/ui/fldui/fldref.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/ui/fldui/fldref.cxx b/sw/source/ui/fldui/fldref.cxx index 4c227e0153fb..1642eac57d36 100644 --- a/sw/source/ui/fldui/fldref.cxx +++ b/sw/source/ui/fldui/fldref.cxx @@ -746,13 +746,13 @@ sal_Int32 SwFldRefPage::FillFormatLB(sal_uInt16 nTypeId) IMPL_LINK_NOARG(SwFldRefPage, ModifyHdl) { OUString aName(m_pNameED->GetText()); - const sal_uInt16 nLen = aName.getLength(); + const bool bEmptyName = aName.isEmpty(); sal_Bool bEnable = sal_True; sal_uInt16 nTypeId = (sal_uInt16)(sal_uLong)m_pTypeLB->GetEntryData(GetTypeSel()); if ((nTypeId == TYP_SETREFFLD && !GetFldMgr().CanInsertRefMark(aName)) || - (nLen == 0 && (nTypeId == TYP_GETREFFLD || nTypeId == TYP_SETREFFLD || + (bEmptyName && (nTypeId == TYP_GETREFFLD || nTypeId == TYP_SETREFFLD || nTypeId == REFFLDFLAG_BOOKMARK))) bEnable = sal_False; |