Skip to content

Instantly share code, notes, and snippets.

@saikat
Created January 26, 2010 05:55
Show Gist options
  • Select an option

  • Save saikat/286590 to your computer and use it in GitHub Desktop.

Select an option

Save saikat/286590 to your computer and use it in GitHub Desktop.
- (void)selectPreviousWidget
{
if ([_items count] == 0)
return;
if ([_selectionIndexes firstIndex] > 0)
[self setSelectionIndexes:[CPIndexSet indexSetWithIndex:[_selectionIndexes firstIndex]-1]];
else
[self setSelectionIndexes:[CPIndexSet indexSetWithIndex:[_items count]-1]];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment