QTimer* mTimer = new QTimer(this); connect(mTimer,SIGNAL(timeout()),this,SLOT(move())); mTimer->start(1000);//From then on, the move() slot is called every second.
一年前用它跑了个贪吃蛇,一年后用它做了下自动重连主机

QTimer* mTimer = new QTimer(this); connect(mTimer,SIGNAL(timeout()),this,SLOT(move())); mTimer->start(1000);//From then on, the move() slot is called every second.