From 1900ac0b853eb3ae55c495da078410709004f433 Mon Sep 17 00:00:00 2001 From: Julien Nabet Date: Fri, 25 Apr 2014 09:12:04 +0200 Subject: Related fdo#77874: [None] as only possible choice in lists There was a slight error in commit 3a2a68a90f96d844c2e2636ecf3236c6f365520a Indeed rToFill.InsertEntry was never called Change-Id: I8189d478feecb9442036d13b68685db38e392ec2 --- sw/source/core/uibase/utlui/uitool.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sw') diff --git a/sw/source/core/uibase/utlui/uitool.cxx b/sw/source/core/uibase/utlui/uitool.cxx index fb7f749c6582..0080d3f32bfe 100644 --- a/sw/source/core/uibase/utlui/uitool.cxx +++ b/sw/source/core/uibase/utlui/uitool.cxx @@ -668,13 +668,13 @@ sal_Int32 InsertStringSorted(const OUString& rEntry, ListBox& rToFill, sal_Int32 { CollatorWrapper& rCaseColl = ::GetAppCaseCollator(); const sal_Int32 nCount = rToFill.GetEntryCount(); - while ( nOffset < nCount ) + while (nOffset < nCount) { if( 0 < rCaseColl.compareString( rToFill.GetEntry(nOffset), rEntry )) - return rToFill.InsertEntry(rEntry, nOffset); + break; ++nOffset; } - return nCount; + return rToFill.InsertEntry(rEntry, nOffset); } void FillCharStyleListBox(ListBox& rToFill, SwDocShell* pDocSh, bool bSorted, bool bWithDefault) -- cgit