From 766cd852d360b5c9f40dd68267f76a1aa86a3de7 Mon Sep 17 00:00:00 2001 From: Zaggy1024 Date: Tue, 29 Aug 2023 12:13:50 -0500 Subject: [PATCH] LibWeb: Move the unique task source start to be last in `Task::Source` This also adds some big text to draw attention to the fact that this enum value must remain last. --- Userland/Libraries/LibWeb/HTML/EventLoop/Task.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Userland/Libraries/LibWeb/HTML/EventLoop/Task.h b/Userland/Libraries/LibWeb/HTML/EventLoop/Task.h index 1caf816ce2..ef17779800 100644 --- a/Userland/Libraries/LibWeb/HTML/EventLoop/Task.h +++ b/Userland/Libraries/LibWeb/HTML/EventLoop/Task.h @@ -44,12 +44,13 @@ public: // https://w3c.github.io/performance-timeline/#dfn-performance-timeline-task-source PerformanceTimeline, - // Some elements, such as the HTMLMediaElement, must have a unique task source per instance. - // Keep this field last, to serve as the base value of all unique task sources. - UniqueTaskSourceStart, - // https://html.spec.whatwg.org/multipage/canvas.html#canvas-blob-serialisation-task-source CanvasBlobSerializationTask, + + // !!! IMPORTANT: Keep this field last! + // This serves as the base value of all unique task sources. + // Some elements, such as the HTMLMediaElement, must have a unique task source per instance. + UniqueTaskSourceStart }; static NonnullOwnPtr create(Source source, DOM::Document const* document, JS::SafeFunction steps)