heavyrain.lee 4 jaren geleden
bovenliggende
commit
c833e76ad6

+ 2 - 1
wfchat/WildFireChat/Me/WFCSettingTableViewController.m

@@ -230,7 +230,8 @@
         UIButton *btn = [[UIButton alloc] initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, 48)];
         [btn setTitle:LocalizedString(@"Logout") forState:UIControlStateNormal];
         btn.titleLabel.font = [UIFont pingFangSCWithWeight:FontWeightStyleRegular size:16];
-        [btn setTitleColor:[UIColor colorWithHexString:@"0x1d1d1d"] forState:UIControlStateNormal];
+        [btn setTitleColor:[UIColor colorWithHexString:@"0xf95569"]
+                  forState:UIControlStateNormal];
         [btn addTarget:self action:@selector(onLogoutBtn:) forControlEvents:UIControlEventTouchUpInside];
         [cell addSubview:btn];
     }

+ 12 - 13
wfuikit/WFChatUIKit/CommonVC/WFCUProfileTableViewController.m

@@ -140,13 +140,13 @@
     
     NSString *alias = [[WFCCIMService sharedWFCIMService] getFriendAlias:self.userId];
     if (alias.length) {
-        self.aliasLabel = [[UILabel alloc] initWithFrame:CGRectMake(64, 8, width - 64 - 8, 21)];
+        self.aliasLabel = [[UILabel alloc] initWithFrame:CGRectMake(94, 8, width - 64 - 8, 21)];
         self.aliasLabel.text = alias;
         
-        self.displayNameLabel = [[UILabel alloc] initWithFrame:CGRectMake(64, 26, width - 64 - 8, 21)];
+        self.displayNameLabel = [[UILabel alloc] initWithFrame:CGRectMake(94, 32, width - 94 - 8, 21)];
         self.displayNameLabel.text = self.userInfo.displayName;
         
-        self.userNameLabel = [[UILabel alloc] initWithFrame:CGRectMake(64, 50, width - 64 - 8, 11)];
+        self.userNameLabel = [[UILabel alloc] initWithFrame:CGRectMake(94, 60, width - 94 - 8, 11)];
         self.userNameLabel.text = [NSString stringWithFormat:@"野火ID:%@", self.userInfo.name];
         self.userNameLabel.font = [UIFont systemFontOfSize:12];
         self.userNameLabel.textColor = [UIColor grayColor];
@@ -158,12 +158,11 @@
         self.displayNameLabel.font = [UIFont pingFangSCWithWeight:FontWeightStyleMedium size:20];
         self.displayNameLabel.textColor = [UIColor colorWithHexString:@"0x1d1d1d"];
         
-        self.userNameLabel = [[UILabel alloc] initWithFrame:CGRectMake(64, 42, width - 64 - 8, 21)];
+        self.userNameLabel = [[UILabel alloc] initWithFrame:CGRectMake(94, 50, width - 94 - 8, 21)];
         self.userNameLabel.text = [NSString stringWithFormat:@"野火ID:%@", self.userInfo.name];
         self.userNameLabel.font = [UIFont systemFontOfSize:12];
         self.userNameLabel.textColor = [UIColor grayColor];
     }
-    self.userNameLabel.hidden = YES;
     
     [self.headerCell addSubview:self.portraitView];
     [self.headerCell addSubview:self.displayNameLabel];
@@ -185,14 +184,14 @@
         [self showSeparatorLine:alisaCell];
         [self.headerCells addObject:alisaCell];
 
-        if (self.userInfo.mobile.length > 0) {
-            self.mobileLabel = [[UILabel alloc] initWithFrame:CGRectMake(92, 50, width - 94 - 8, 21)];
-            self.mobileLabel.font = [UIFont pingFangSCWithWeight:FontWeightStyleRegular size:14];
-            self.mobileLabel.textColor = [UIColor colorWithHexString:@"0x828282"];
-            self.mobileLabel.text = [NSString stringWithFormat:@"%@: %@",WFCString(@"Mobile"),self.userInfo.mobile];
-            [self.headerCell addSubview:self.mobileLabel];
-
-        }
+//        if (self.userInfo.mobile.length > 0) {
+//            self.mobileLabel = [[UILabel alloc] initWithFrame:CGRectMake(92, 50, width - 94 - 8, 21)];
+//            self.mobileLabel.font = [UIFont pingFangSCWithWeight:FontWeightStyleRegular size:14];
+//            self.mobileLabel.textColor = [UIColor colorWithHexString:@"0x828282"];
+//            self.mobileLabel.text = [NSString stringWithFormat:@"%@: %@",WFCString(@"Mobile"),self.userInfo.mobile];
+//            [self.headerCell addSubview:self.mobileLabel];
+//
+//        }
         
         if (self.userInfo.email.length > 0) {
             UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:@"cell"];

+ 1 - 1
wfuikit/WFChatUIKit/ConversationSetting/Cell/WFCUConversationSettingMemberCell.m

@@ -29,7 +29,7 @@
 - (void)layoutSubviews {
     [super layoutSubviews];
     self.headerImageView.frame = CGRectMake(2, 2, self.frame.size.width - 4, self.frame.size.width - 4);
-    self.nameLabel.frame = CGRectMake(0, self.frame.size.width + 7, self.frame.size.width, 11);
+    self.nameLabel.frame = CGRectMake(0, self.frame.size.width + 3, self.frame.size.width, 11);
 }
 
 - (UILabel *)nameLabel {

+ 1 - 3
wfuikit/WFChatUIKit/ConversationSetting/ViewController/WFCUConversationSettingMemberCollectionViewLayout.m

@@ -78,9 +78,7 @@
     } else {
         int lines = (itemCount - 1) / 5 + 1;
         CGFloat height = self.itemAreaWidth * lines;
-        if (lines == 1) {
-            height += 15;
-        }
+        height += 12;
         return height;
     }
 }

+ 6 - 6
wfuikit/WFChatUIKit/ConversationSetting/ViewController/WFCUConversationSettingViewController.m

@@ -162,7 +162,7 @@
 
 - (void)setupMemberCollectionView {
     if (self.conversation.type == Single_Type || self.conversation.type == Group_Type) {
-        self.memberCollectionViewLayout = [[WFCUConversationSettingMemberCollectionViewLayout alloc] initWithItemMargin:16];
+        self.memberCollectionViewLayout = [[WFCUConversationSettingMemberCollectionViewLayout alloc] initWithItemMargin:8];
 
         if (self.conversation.type == Single_Type) {
             self.extraBtnNumber = 1;
@@ -182,8 +182,8 @@
                 self.extraBtnNumber = 1;
                 self.memberCollectionCount = (int)self.memberList.count + self.extraBtnNumber;
             }
-            if (self.memberCollectionCount > Group_Member_Visible_Lines * 4) {
-                self.memberCollectionCount = Group_Member_Visible_Lines * 4;
+            if (self.memberCollectionCount > Group_Member_Visible_Lines * 5) {
+                self.memberCollectionCount = Group_Member_Visible_Lines * 5;
                 self.showMoreMember = YES;
             }
         } else if(self.conversation.type == Channel_Type) {
@@ -199,15 +199,15 @@
         if (self.showMoreMember) {
             UIView *head = [[UIView alloc] init];
             CGRect frame = self.memberCollectionView.frame;
-            frame.size.height += 40;
+            frame.size.height += 36;
             head.frame = frame;
             [head addSubview:self.memberCollectionView];
             
-            UIButton *moreBtn = [[UIButton alloc] initWithFrame:CGRectMake(0, frame.size.height - 40, frame.size.width, 40)];
+            UIButton *moreBtn = [[UIButton alloc] initWithFrame:CGRectMake(0, frame.size.height - 40, frame.size.width, 36)];
             [moreBtn setTitle:WFCString(@"ShowAllMembers") forState:UIControlStateNormal];
             moreBtn.titleLabel.font = [UIFont pingFangSCWithWeight:FontWeightStyleRegular size:17];
             [moreBtn setTitleColor:[UIColor grayColor] forState:UIControlStateNormal];
-            moreBtn.contentVerticalAlignment = UIControlContentVerticalAlignmentTop;
+            moreBtn.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;
             [moreBtn addTarget:self action:@selector(onViewAllMember:) forControlEvents:UIControlEventTouchDown];
             [head addSubview:moreBtn];