QBasic::start+QBasicTimer+can+only+be+used+with+thread+start+with+QThread
时间: 2024-03-01 21:48:09 浏览: 143
QBasic::start() is a function in the QBasicTimer class in Qt framework. It is used to start the timer and begin the timer events. However, it can only be used with threads started with QThread.
QBasicTimer is a class in Qt that provides timer functionality for objects. It allows you to set timers and receive timer events at regular intervals.
When using QBasicTimer, you need to create a subclass of QObject and override the timerEvent() function to handle the timer events. You can then start the timer using the start() function.
However, it's important to note that QBasicTimer can only be used with threads started with QThread. This means that if you want to use QBasicTimer, you need to create a QThread object and start it using the start() function provided by QThread.
阅读全文