mirror of
https://github.com/RGBCube/serenity
synced 2025-07-28 06:27:45 +00:00
Everywhere: Use MonotonicTime instead of Duration
This is easily identifiable by anyone who uses Duration::now_monotonic, and any downstream users of that data.
This commit is contained in:
parent
b2e7b8cdff
commit
fc5cab5c21
29 changed files with 79 additions and 80 deletions
|
@ -40,7 +40,7 @@ void Screensaver::mousedown_event(GUI::MouseEvent&)
|
|||
|
||||
void Screensaver::mousemove_event(GUI::MouseEvent& event)
|
||||
{
|
||||
auto now = AK::Duration::now_monotonic();
|
||||
auto now = MonotonicTime::now();
|
||||
if ((now - m_start_time).to_milliseconds() < mouse_tracking_delay_milliseconds)
|
||||
return;
|
||||
|
||||
|
|
|
@ -30,7 +30,7 @@ public:
|
|||
|
||||
protected:
|
||||
Screensaver()
|
||||
: m_start_time(AK::Duration::now_monotonic())
|
||||
: m_start_time(MonotonicTime::now())
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -38,7 +38,7 @@ private:
|
|||
void trigger_exit();
|
||||
|
||||
Optional<Gfx::IntPoint> m_mouse_origin;
|
||||
AK::Duration m_start_time;
|
||||
MonotonicTime m_start_time;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue