         backGroundImageView.addConstraint(passwordIconimageV_width)
         
         //用户名输入textfield
-        let usernameTextField = UITextField()
+        usernameTextField = UITextField()
         usernameTextField.placeholder = "请输入用户名"
         //        usernameTextField.backgroundColor = UIColor.green
         usernameTextField.translatesAutoresizingMaskIntoConstraints = false
+        usernameTextField.clearButtonMode = .whileEditing
         userNameBGView.addSubview(usernameTextField)
         let usernameTextField_leading = NSLayoutConstraint(item: usernameTextField, attribute: .leading, relatedBy: .equal, toItem: userNameIconimageV, attribute: .trailing, multiplier: 1.0, constant: 5)
         userNameBGView.addConstraint(usernameTextField_leading)

        let checkImageView_bottom = NSLayoutConstraint(item: checkImageView, attribute: .bottom, relatedBy: .equal, toItem: rememberBoxBtn, attribute: .bottom, multiplier: 1.0, constant: 0)
        backGroundImageView.addConstraint(checkImageView_bottom)
        checkImageView.isHidden = true
    }
    //记住按钮的点击事件
    func rememberBtnClicked() {


import UIKit

class ViewController: UIViewController,UITableViewDelegate,UITableViewDataSource {

    var checkImageView : UIImageView!
    var usernameTextField : UITextField!
    var passwordTextField : UITextField!
    var usernamePasswordDict : NSMutableDictionary!
    var userNamesTableView : UITableView!
    
    
    
    override func viewDidLoad() {
