Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(322)

Unified Diff: sky/specs/runloop.md

Issue 835973003: Specs: Move the LayoutManager and RenderNode logic from Element to (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sky/specs/dom.md ('k') | sky/specs/style.md » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/specs/runloop.md
diff --git a/sky/specs/runloop.md b/sky/specs/runloop.md
index 8d7f245ca7fd553f9d6a3896b2a371323c0880ff..20231fc07ef1570e6bb124f337be953777a0afe5 100644
--- a/sky/specs/runloop.md
+++ b/sky/specs/runloop.md
@@ -7,17 +7,35 @@ takes 8.333ms):
1. Send scroll and resize events if necessary, limiting each handler
to 1ms, and limiting the total time spent on these handlers to 1ms.
-2. Update as much of layout as possible; after 1ms, stop, leaving the
- remaining nodes unprepared.
+2. Fire animation frame callbacks for up to 1ms. Each callback can run
+ for up to 1ms. Once 1ms has expired, throw a (catchable)
+ EDeadlineExceeded exception. If it's not caught, drop subsequent
+ callbacks.
-3. Update as much of paint as possible; after 1ms, stop, leaving the
- remaining nodes unprepared.
+3. Spend up to 1ms to update the render tree, including calling
+ childAdded(), childRemoved(), and getLayoutManager() as needed.
+ Once 1ms has expired, throw a (catchable) EDeadlineExceeded
+ exception, leaving the render tree in whatever state it has
+ reached.
-4. Send frame to GPU.
+4. Update as much of layout as possible; after 1ms, throw a
+ (catchable) EDeadlineExceeded exception, leaving the remaining
+ nodes unprepared.
-5. Run pending tasks until the 8.333ms expires. Each task may only run
+5. Update as much of paint as possible; after 1ms, throw a (catchable)
+ EDeadlineExceeded exception, leaving any remaining nodes
+ unprepared.
+
+6. Send frame to GPU.
+
+7. Run pending tasks until the 8.333ms expires. Each task may only run
for at most 1ms, after 1ms they get a (catchable) EDeadlineExceeded
exception. While there are no pending tasks, sleep.
+ Tasks are thingsl like:
+ - timers
+ - updating the DOM in response to parsing
+ - input events
+ - mojo callbacks
TODO(ianh): Update the timings above to have some relationship to
reality.
« no previous file with comments | « sky/specs/dom.md ('k') | sky/specs/style.md » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698