mirror of
https://github.com/moonlight-stream/moonlight-qt.git
synced 2026-02-16 10:40:59 +00:00
Reduce the priority of background polling threads
This commit is contained in:
@@ -74,6 +74,13 @@ private:
|
||||
|
||||
void run() override
|
||||
{
|
||||
// Reduce the power and performance impact of our
|
||||
// computer status polling while it's running.
|
||||
setPriority(QThread::LowPriority);
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 9, 0)
|
||||
setServiceLevel(QThread::QualityOfService::Eco);
|
||||
#endif
|
||||
|
||||
// Always fetch the applist the first time
|
||||
int pollsSinceLastAppListFetch = POLLS_PER_APPLIST_FETCH;
|
||||
while (!isInterruptionRequested()) {
|
||||
|
||||
Reference in New Issue
Block a user