MainWindow.h
#ifndef MAINWINDOW_H #define MAINWINDOW_H #include <QMainWindow> #include <QTimer> class MainWindow : public QMainWindow { Q_OBJECT public: MainWindow(QWidget *parent = 0); ~MainWindow(); void timerEvent(QTimerEvent *); void paintEvent(QPaintEvent *event); private: int m_x,m_y; int m_k; float m_t; }; #endif // MAINWINDOW_H
MainWindow.cpp
#include "mainwindow.h"<