mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 06:17:34 +00:00
WindowServer: Port threading to LibThread
This commit is contained in:
parent
1ac7fedefe
commit
8d59b10022
5 changed files with 43 additions and 53 deletions
|
@ -1,6 +1,7 @@
|
|||
#pragma once
|
||||
|
||||
#include <AK/CircularQueue.h>
|
||||
#include <LibThread/Thread.h>
|
||||
#include <stdio.h>
|
||||
|
||||
class Painter;
|
||||
|
@ -16,8 +17,11 @@ public:
|
|||
void paint(Painter&, const Rect&);
|
||||
|
||||
private:
|
||||
void monitor();
|
||||
|
||||
void get_cpu_usage(unsigned& busy, unsigned& idle);
|
||||
|
||||
CircularQueue<float, 30> m_cpu_history;
|
||||
bool m_dirty { false };
|
||||
LibThread::Thread m_thread;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue