YIem`s Blog -心比天高命比纸薄-链接找不到的请在站内搜索内容!

2015-12-15-iOS UI 实现QQ聊天界面

//

// RootViewController.m
// Phone
//
// Created by YIem on 15/12/12.
// Copyright (c) 2015年 www.yiem.net YIem博客. All rights reserved.
//

import "RootViewController.h"

import "LTView.h"

import "PhoneViewController.h"

@interface RootViewController ()

@end

@implementation RootViewController



// 调用 一
LTView *yi = [[LTView alloc]initWithFrame:CGRectMake(0, 100, self.view.frame.size.width, 100)];
//yi.backgroundColor = [UIColor blueColor];
yi.label.text = @"DLS151129";
yi.label1.text = @"一亿元[红包]";
yi.label1.textColor = [UIColor redColor];
yi.label2.text = @"16:13";
yi.image1.image = [UIImage imageNamed:@"eat"];

// yi.image1.image = [UIIm]

[self.view addSubview:yi];
[yi release];
// 调用er
LTView *er = [[LTView alloc]initWithFrame:CGRectMake(0, 190, self.view.frame.size.width, 100)];
er.label.text = @"我的电脑";
er.label1.text = @"你已在电脑登录,可传文件到电脑";
er.label2.text = @"16:15";
er.image1.image = [UIImage imageNamed:@"eat"];
[self.view addSubview:er];
[er release];
// 调用san
LTView *san = [[LTView alloc]initWithFrame:CGRectMake(0, 280, self.view.frame.size.width, 100)];
san.label.text = @"DLS150825";
san.label1.text = @"逆风的方向更适合:[分享]";
san.label2.text = @"16:22";

// san.label3.text = @"99+";

san.image1.image = [UIImage imageNamed:@"eat"];
[self.view addSubview:san];
[san release];
// 调用si
LTView *si = [[LTView alloc]initWithFrame:CGRectMake(0, 370, self.view.frame.size.width, 100)];
si.label.text = @"DLS50818";
si.label1.text = @"08-王麻子:[图片]";
si.label2.text = @"16:30";
si.image1.image = [UIImage imageNamed:@"eat"];
[self.view addSubview:si];
[si release];
// 调用wu
LTView *wu = [[LTView alloc]initWithFrame:CGRectMake(0, 460, self.view.frame.size.width, 100)];
wu.label.text = @"iOS";
wu.label1.text = @"六万:收到";
wu.label2.text = @"16:35";
wu.image1.image = [UIImage imageNamed:@"eat"];
[self.view addSubview:wu];
[wu release];
// liu
LTView *liu = [[LTView alloc]initWithFrame:CGRectMake(0, 550, self.view.frame.size.width, 100)];
liu.label.text = @"群助手";
liu.label1.text = @"[27个QQ群有新消息]";
liu.label2.text = @"16:45";
liu.label1.textColor = [UIColor redColor];
liu.image1.image = [UIImage imageNamed:@"eat"];
[self.view addSubview:liu];
[liu release];



//
UIButton *button = [UIButton buttonWithType:UIButtonTypeSystem];
button.frame = CGRectMake(0, 600,self.view.frame.size.width, 70);
[self.view addSubview:button];
[button setBackgroundImage:[UIImage imageNamed:@"002.png"] forState:UIControlStateNormal];
button.self.layer.cornerRadius = 25;

}

当前页面是本站的「Google AMP」版。查看和发表评论请点击:完整版 »