diff --git a/game/iphone/chatcell.mm b/game/iphone/chatcell.mm index d4b5fe7..f650cc2 100644 --- a/game/iphone/chatcell.mm +++ b/game/iphone/chatcell.mm @@ -1,14 +1,12 @@ #import "game/iphone/chatcell.h" @implementation ChatCell -- (id)initWithFrame:(CGRect)frame reuseIdentifier:(NSString *)reuseIdentifier { - self = [super initWithFrame:frame reuseIdentifier:reuseIdentifier]; +- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier { + self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]; if (self == nil) { return nil; } - self.selectionStyle = UITableViewCellSelectionStyleNone; - chatLabel_ = [[UILabel alloc] initWithFrame:CGRectZero]; chatLabel_.backgroundColor = [UIColor whiteColor]; chatLabel_.opaque = YES; diff --git a/game/iphone/chatviewcontroller.mm b/game/iphone/chatviewcontroller.mm index ac39f42..63b156f 100644 --- a/game/iphone/chatviewcontroller.mm +++ b/game/iphone/chatviewcontroller.mm @@ -419,7 +419,7 @@ ChatCell *cell = (ChatCell *)[tableView_ dequeueReusableCellWithIdentifier:@"chatcell"]; if (cell == nil) { - cell = [[[ChatCell alloc] initWithFrame:CGRectZero + cell = [[[ChatCell alloc] initWithStyle:UITableViewCellSelectionStyleNone reuseIdentifier:@"chatcell"] autorelease]; } [self initializeChatCell:(int)indexPath.row cell:cell];