项目介绍:
swift简化聊天窗口
主要集成代码:
[Objective-C] 查看源文件 复制代码
class ViewController: UIViewController,UITableViewDelegate,UITableViewDataSource,UITextFieldDelegate { @IBOutlet weak var showTableView: UITableView! @IBOutlet weak var bottomCon: NSLayoutConstraint! @IBOutlet weak var inputTextField: UITextField! var massageListArr: NSMutableArray = [] let screenheight = UIScreen.mainScreen().bounds.size.height @IBOutlet weak var buttonBottom: NSLayoutConstraint! override func viewDidLoad() { super.viewDidLoad() self.showTableView.separatorStyle = UITableViewCellSeparatorStyle.None self.showTableView.tableFooterView = UIView.init(frame: CGRectZero) NSNotificationCenter.defaultCenter().addObserver(self, selector: #selector(keyboardWillShow(_:)), name: UIKeyboardWillChangeFrameNotification, object: nil) NSNotificationCenter.defaultCenter().addObserver(self, selector: #selector(keyboardWillHidden(_:)), name: UIKeyboardWillHideNotification, object: nil) }
DEMO 下载:
TalkPaoSwift.zip
(60.38 KB, 下载次数: 28, 售价: 8 金钱)
2016-7-21 15:27 上传
点击文件名下载附件
swift