From 03e73ef171cc36b88a3930fabd17f1938d05fd49 Mon Sep 17 00:00:00 2001 From: Marcian Lytwyn Date: Sun, 14 Apr 2013 23:46:50 +0000 Subject: [PATCH] Use NSPopupButton addItemsWithTitles method git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/branches/gnustep_testplant_branch@36534 72102866-910b-0410-8b05-ffd578937521 --- Source/NSPopUpButton.m | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Source/NSPopUpButton.m b/Source/NSPopUpButton.m index edfeebbcd..35c998cc1 100644 --- a/Source/NSPopUpButton.m +++ b/Source/NSPopUpButton.m @@ -578,8 +578,7 @@ this to return nil to indicate that we have no context menu. NSArray *array = (NSArray*)anObject; NSInteger index = 0; [self removeAllItems]; - for (index = 0; index < [array count]; ++index) - [self insertItemWithTitle:AUTORELEASE([[array objectAtIndex: index] copy]) atIndex:index]; + [self addItemsWithTitles:array]; } else {