getElapsedTimeSinceBoot: Honor times in suspend, too (#8983)

This commit is contained in:
zwim authored and GitHub committed 2022-04-11 00:20:48 +02:00
1 parent 61cafab0e5
commit 0808560532
2 files changed
+6 -4

No files matched your search

+2 -2
View File
@@ -1242,10 +1242,10 @@ function UIManager:getTime()
end
--[[--
Returns a TimeVal object corresponding to the last UI tick plus the time in standby.
Returns a TimeVal object corresponding to the last UI tick plus the time in standby and suspend.
]]
function UIManager:getElapsedTimeSinceBoot()
return self:getTime() + Device.total_standby_tv
return self:getTime() + Device.total_standby_tv + Device.total_suspend_tv
end
-- precedence of refresh modes: