//******************************************************
//******************************************************
//********** RETURN RIGHT HAND OPTIONAL INDEX **********
//******************************************************
//******************************************************
- (NSArray *)sectionIndexTitlesForTableView:(UITableView *)tableView
{
//----- RETURN NIL IF NO INDEX TO BE SHOWN -----
if([AppMain sharedAppMain].CurrentView != CURRENT_VIEW_ALL_MUSIC)
return nil;
NSMutableArray *tempArray = [[NSMutableArray alloc] init];
[tempArray addObject:@"A"];
[tempArray addObject:@"B"];
[tempArray addObject:@"C"];
[tempArray addObject:@"D"];
[tempArray addObject:@"E"];
[tempArray addObject:@"F"];
[tempArray addObject:@"G"];
[tempArray addObject:@"H"];
[tempArray addObject:@"I"];
[tempArray addObject:@"J"];
[tempArray addObject:@"K"];
[tempArray addObject:@"L"];
[tempArray addObject:@"M"];
[tempArray addObject:@"N"];
[tempArray addObject:@"O"];
[tempArray addObject:@"P"];
[tempArray addObject:@"Q"];
[tempArray addObject:@"R"];
[tempArray addObject:@"S"];
[tempArray addObject:@"T"];
[tempArray addObject:@"U"];
[tempArray addObject:@"V"];
[tempArray addObject:@"W"];
[tempArray addObject:@"X"];
[tempArray addObject:@"Y"];
[tempArray addObject:@"Z"];
[tempArray addObject:@"#"];
return tempArray;
}
//**********************************************************
//**********************************************************
//********** USER SELECTING RIGHT HAND INDEX ITEM **********
//**********************************************************
//**********************************************************
//This is called for every index position as the user drags their finger along the index
- (NSInteger)tableView:(UITableView *)tableView sectionForSectionIndexTitle:(NSString *)title atIndex:(NSInteger)index
{
//----- IGNORE? -----
if([AppMain sharedAppMain].CurrentView != CURRENT_VIEW_ALL_MUSIC)
return -1;
NSLog(@"Selecting letter at index: %d", index);
//[self.tableView scrollToRowAtIndexPath:[NSIndexPath indexPathForRow:RowIndex inSection:0]
// atScrollPosition:UITableViewScrollPositionNone
// animated:NO];
//Return the section the table should scroll to
return -1;
}