project_files/HedgewarsMobile/Classes/MissionTrainingViewController.m
changeset 6100 e6426c6b2882
parent 6094 16b12a6417d1
child 6210 923c8414e3af
equal deleted inserted replaced
6099:e6dd54f8d334 6100:e6426c6b2882
   155 #pragma mark Table view delegate
   155 #pragma mark Table view delegate
   156 -(void) tableView:(UITableView *)aTableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
   156 -(void) tableView:(UITableView *)aTableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
   157     NSInteger row = [indexPath row];
   157     NSInteger row = [indexPath row];
   158 
   158 
   159     self.missionName = [[self.listOfMissions objectAtIndex:row] stringByDeletingPathExtension];
   159     self.missionName = [[self.listOfMissions objectAtIndex:row] stringByDeletingPathExtension];
   160     NSString *filePath = [[NSString alloc] initWithFormat:@"%@/Missions/Training/%@@2x.png",GRAPHICS_DIRECTORY(),self.missionName];
   160     NSString *size = IS_IPAD() ? @"@2x" : @"";
       
   161     NSString *filePath = [[NSString alloc] initWithFormat:@"%@/Missions/Training/%@%@.png",GRAPHICS_DIRECTORY(),self.missionName,size];
   161     UIImage *img = [[UIImage alloc] initWithContentsOfFile:filePath];
   162     UIImage *img = [[UIImage alloc] initWithContentsOfFile:filePath];
   162     [filePath release];
   163     [filePath release];
   163     [self.previewImage setImage:img];
   164     [self.previewImage setImage:img];
   164     [img release];
   165     [img release];
   165 
   166