PyQT QObject::startTimer: Timers can only be used with threads started with QThread


PyQT QObject::startTimer: Timers can only be used with threads started with QThread

故障描述:

在線程中設置了statusbar.showMessage() 或者設置了其它Ui部件的值或狀態,會出現這個錯誤。

處理方法:

避免線程中直接設置UI部件的狀態,應該使用自定義信號和槽的方式,間隔調用設置Ui的方法。


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM