summaryrefslogtreecommitdiff
path: root/Juick/MessageCell.m
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2013-11-10 18:51:44 +0400
committerGravatar Vitaly Takmazov2013-11-10 18:51:44 +0400
commit4e6a313148890e30774757b382aa3b3ba1622bb6 (patch)
tree999cfdbb23948a63d98ed0297ff337a8062d41fe /Juick/MessageCell.m
parent44ad254eb2533b922e5de47c65f4af8c37813519 (diff)
refactoring and threadview
Diffstat (limited to 'Juick/MessageCell.m')
-rw-r--r--Juick/MessageCell.m7
1 files changed, 5 insertions, 2 deletions
diff --git a/Juick/MessageCell.m b/Juick/MessageCell.m
index ad3a849..0777dfd 100644
--- a/Juick/MessageCell.m
+++ b/Juick/MessageCell.m
@@ -24,7 +24,6 @@
if (self) {
[self setBackgroundColor:[UIColor whiteColor]];
- self.selectionStyle = UITableViewCellSelectionStyleNone;
self.avatar = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, 32, 32)];
[self.avatar setBackgroundColor:[UIColor clearColor]];
@@ -154,7 +153,11 @@
self.titleLabel.text = msg.user;
self.timestampLabel.text = msg.timestamp;
if (msg.repliesCount > 0) {
- self.summaryLabel.text = [NSString stringWithFormat:@"%@ replies by %@", msg.repliesCount, msg.repliesBy];
+ if ([msg.repliesBy length] > 0) {
+ self.summaryLabel.text = [NSString stringWithFormat:@"%@ replies by %@", msg.repliesCount, msg.repliesBy];
+ } else {
+ self.summaryLabel.text = [NSString stringWithFormat:@"%@ replies", msg.repliesCount];
+ }
} else {
self.summaryLabel.text = nil;
}