davdroman / Bohr

Settings screen composing framework
MIT License
1.26k stars 83 forks source link

Adding an image to the cell #38

Closed mythodeia closed 8 years ago

mythodeia commented 8 years ago

to use an image before the text do we need to subclass the cell or just mess with BOTableViewCell.m and add it there? i used the default imageview of the cell so i added it in the BOTableViewCell.m by adjusting the class method like so:

+ (instancetype)cellWithTitle:(NSString *)title key:(NSString *)key image:(UIImage*)image handler:(void (^)(id cell))handler;
davdroman commented 8 years ago

The original initializer doesn't contain an image option to keep it short, since it's not something you'll always want. To assign an image, you can specify it through the handler block.

mythodeia commented 8 years ago

:+1: