summaryrefslogtreecommitdiff
path: root/Juick/Views/BubbleMessageCell.m
diff options
context:
space:
mode:
Diffstat (limited to 'Juick/Views/BubbleMessageCell.m')
-rw-r--r--Juick/Views/BubbleMessageCell.m45
1 files changed, 0 insertions, 45 deletions
diff --git a/Juick/Views/BubbleMessageCell.m b/Juick/Views/BubbleMessageCell.m
deleted file mode 100644
index 1c923c7..0000000
--- a/Juick/Views/BubbleMessageCell.m
+++ /dev/null
@@ -1,45 +0,0 @@
-//
-// BubbleMessageCell.m
-// Juick
-//
-// Created by Vitaly Takmazov on 04/03/2018.
-// Copyright © 2018 com.juick. All rights reserved.
-//
-
-#import "BubbleMessageCell.h"
-
-@implementation BubbleMessageCell
-
-- (void)awakeFromNib {
- [super awakeFromNib];
- // Initialization code
-}
-
-- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
- [super setSelected:selected animated:animated];
-
- // Configure the view for the selected state
-}
-
--(void) configureWithMessage:(Message *)message isMe:(BOOL)isMe {
- self.selectionStyle = UITableViewCellSelectionStyleNone;
- self.message.backgroundColor = isMe ? [UIColor colorNamed:@"Title"] : [UIColor colorNamed:@"Chat"];
- self.message.textColor = isMe ? [UIColor whiteColor] : [UIColor colorNamed:@"Text"];
- self.message.dataDetectorTypes = UIDataDetectorTypeAll;
- self.message.tintColor = isMe? [UIColor whiteColor] : [UIColor colorNamed:@"Title"];
- self.name.text = message.user.uname;
- self.message.text = message.text;
- self.unreadMarker.text = @"";
- __weak UIImageView *weakAvatar = self.avatarView;
- [[AppDelegate shared].api fetchImageWithURL:[NSURL URLWithString:message.user.avatar] callback:^(NSData *data) {
- [UIView transitionWithView:weakAvatar
- duration:0.3
- options:UIViewAnimationOptionTransitionCrossDissolve
- animations:^{
- weakAvatar.image = [UIImage imageWithData:data];
- }
- completion:nil];
- }];
-}
-
-@end