File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -34,19 +34,19 @@ - (id)tableView:(NSTableView *)aTableView
3434 int row;
3535 struct grpfile const *fg = GroupsFound ();
3636
37- for (row = 0 ; row < rowIndex && fg; fg = fg->next ) {
38- if (fg->ref ) row++;
37+ while (fg && !fg->ref ) fg = fg->next ;
38+ for (row = 0 ; fg; fg = fg->next ) {
39+ if (fg->ref ) {
40+ if (row == rowIndex) break ;
41+ row++;
42+ }
3943 }
4044 if (!fg) {
4145 return nil ;
4246 }
4347 switch ([[aTableColumn identifier ] intValue ]) {
4448 case 0 : // name column
45- if (fg->ref ) {
46- return [NSString stringWithUTF8String: fg->ref->name];
47- } else {
48- return @" Unknown game" ;
49- }
49+ return [NSString stringWithUTF8String: fg->ref->name];
5050 case 1 : // grp column
5151 return [NSString stringWithUTF8String: fg->name];
5252 case 2 : // hidden column pointing to the grpfile entry.
You can’t perform that action at this time.
0 commit comments