From 4ea04358ba07af1a3fcd4b3ee15d489d99776dcd Mon Sep 17 00:00:00 2001 From: Nathan Kinsinger Date: Sat, 13 Feb 2010 11:58:03 -0700 Subject: [PATCH] replace depreciated selectRow:byExtendingSelection: method --- PBGitSidebarController.m | 4 ++-- PBQLOutlineView.m | 6 ++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/PBGitSidebarController.m b/PBGitSidebarController.m index b19eaaa..fd31fbc 100644 --- a/PBGitSidebarController.m +++ b/PBGitSidebarController.m @@ -67,9 +67,9 @@ } [sourceView PBExpandItem:item expandParents:YES]; - NSInteger index = [sourceView rowForItem:item]; + NSIndexSet *index = [NSIndexSet indexSetWithIndex:[sourceView rowForItem:item]]; - [sourceView selectRow:index byExtendingSelection:NO]; + [sourceView selectRowIndexes:index byExtendingSelection:NO]; } - (void)addRevSpec:(PBGitRevSpecifier *)rev diff --git a/PBQLOutlineView.m b/PBQLOutlineView.m index 459d908..c3dde23 100644 --- a/PBQLOutlineView.m +++ b/PBQLOutlineView.m @@ -70,8 +70,10 @@ int row = [self rowAtPoint:mousePoint]; // figure out if the row that was just clicked on is currently selected - if ([selectedRowIndexes containsIndex:row] == NO) - [self selectRow:row byExtendingSelection:NO]; + if ([selectedRowIndexes containsIndex:row] == NO) { + NSIndexSet *index = [NSIndexSet indexSetWithIndex:row]; + [self selectRowIndexes:index byExtendingSelection:NO]; + } } return [controller contextMenuForTreeView];