equal
deleted
inserted
replaced
188 [[self.basicSettingList objectAtIndex:row] objectForKey:@"image"]]]; |
188 [[self.basicSettingList objectAtIndex:row] objectForKey:@"image"]]]; |
189 cell.imageView.image = img; |
189 cell.imageView.image = img; |
190 [img release]; |
190 [img release]; |
191 |
191 |
192 UILabel *cellLabel = (UILabel *)[cell.contentView viewWithTag:LABEL_TAG]; |
192 UILabel *cellLabel = (UILabel *)[cell.contentView viewWithTag:LABEL_TAG]; |
193 cellLabel.text = [[self.basicSettingList objectAtIndex:row] objectForKey:@"title"]; |
193 NSString *basicSettingTitleKey = [[self.basicSettingList objectAtIndex:row] objectForKey:@"title"]; |
|
194 cellLabel.text = NSLocalizedStringFromTable(basicSettingTitleKey, @"Scheme", nil); |
194 cellLabel.adjustsFontSizeToFitWidth = YES; |
195 cellLabel.adjustsFontSizeToFitWidth = YES; |
195 |
196 |
196 // can't use the viewWithTag method because row is dynamic |
197 // can't use the viewWithTag method because row is dynamic |
197 UISlider *cellSlider = nil; |
198 UISlider *cellSlider = nil; |
198 for (UIView *oneView in cell.contentView.subviews) { |
199 for (UIView *oneView in cell.contentView.subviews) { |
219 } |
220 } |
220 } |
221 } |
221 cellSlider.frame = CGRectMake(hOffset, vOffset, sliderLength, 23); |
222 cellSlider.frame = CGRectMake(hOffset, vOffset, sliderLength, 23); |
222 |
223 |
223 NSString *prestring = nil; |
224 NSString *prestring = nil; |
224 checkValueString(prestring,cellLabel.text,cellSlider); |
225 checkValueString(prestring,basicSettingTitleKey,cellSlider); |
225 |
226 |
226 // forced to use this weird format otherwise the label disappears when size of the text is bigger than the original |
227 // forced to use this weird format otherwise the label disappears when size of the text is bigger than the original |
227 while ([prestring length] <= 4) |
228 while ([prestring length] <= 4) |
228 prestring = [NSString stringWithFormat:@" %@",prestring]; |
229 prestring = [NSString stringWithFormat:@" %@",prestring]; |
229 cell.detailTextLabel.text = prestring; |
230 cell.detailTextLabel.text = prestring; |
249 [[self.gameModifierArray objectAtIndex:row] objectForKey:@"image"]]]; |
250 [[self.gameModifierArray objectAtIndex:row] objectForKey:@"image"]]]; |
250 cell.imageView.image = image; |
251 cell.imageView.image = image; |
251 [image release]; |
252 [image release]; |
252 cell.imageView.layer.cornerRadius = 6.0f; |
253 cell.imageView.layer.cornerRadius = 6.0f; |
253 cell.imageView.layer.masksToBounds = YES; |
254 cell.imageView.layer.masksToBounds = YES; |
254 cell.textLabel.text = [[self.gameModifierArray objectAtIndex:row] objectForKey:@"title"]; |
255 NSString *gameModTitleKey = [[self.gameModifierArray objectAtIndex:row] objectForKey:@"title"]; |
255 cell.detailTextLabel.text = [[self.gameModifierArray objectAtIndex:row] objectForKey:@"description"]; |
256 cell.textLabel.text = NSLocalizedStringFromTable(gameModTitleKey, @"Scheme", nil); |
|
257 NSString *gameModDescKey = [[self.gameModifierArray objectAtIndex:row] objectForKey:@"description"]; |
|
258 cell.detailTextLabel.text = NSLocalizedStringFromTable(gameModDescKey, @"Scheme", nil); |
256 cell.detailTextLabel.adjustsFontSizeToFitWidth = YES; |
259 cell.detailTextLabel.adjustsFontSizeToFitWidth = YES; |
257 cell.detailTextLabel.minimumFontSize = 6; |
260 cell.detailTextLabel.minimumFontSize = 6; |
258 |
261 |
259 cell.selectionStyle = UITableViewCellSelectionStyleNone; |
262 cell.selectionStyle = UITableViewCellSelectionStyleNone; |
260 } |
263 } |