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

Unified Diff: content/renderer/renderer_high_priority_task_queue.h

Issue 242103007: NOT FOR REVIEW - prioritize fonts Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 8 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 | « content/content_renderer.gypi ('k') | content/renderer/renderer_high_priority_task_queue.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/renderer_high_priority_task_queue.h
diff --git a/content/renderer/renderer_high_priority_task_queue.h b/content/renderer/renderer_high_priority_task_queue.h
new file mode 100644
index 0000000000000000000000000000000000000000..c52c3fa10f5f45c963436c74793ae6dc980282d9
--- /dev/null
+++ b/content/renderer/renderer_high_priority_task_queue.h
@@ -0,0 +1,62 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_RENDERER_RENDERER_HIGH_PRIORITY_TASK_QUEUE_H_
+#define CHROME_RENDERER_RENDERER_HIGH_PRIORITY_TASK_QUEUE_H_
+
+#include "base/base_export.h"
+#include "base/basictypes.h"
+#include "base/callback_forward.h"
+#include "base/memory/ref_counted.h"
+#include "base/memory/scoped_ptr.h"
+#include "base/message_loop/incoming_task_queue.h"
+#include "base/message_loop/message_loop.h"
+#include "base/message_loop/message_pump_default.h"
+#include "base/time/time.h"
+
+namespace tracked_objects {
+class Location;
+} // namespace tracked_objects
+
+namespace content {
+
+class MessagePumpHighPriority : public base::MessagePumpDefault {
+ public:
+ MessagePumpHighPriority();
+ virtual ~MessagePumpHighPriority();
+
+ private:
+
+};
+
+class MessageLoopRendererMainThread : public base::MessageLoop {
+ public:
+ MessageLoopRendererMainThread();
+
+ virtual void ReloadAllWorkQueues() OVERRIDE;
+ virtual base::TaskQueue& GetNextWorkQueue() OVERRIDE;
+ virtual bool HasWorkAvailable() const OVERRIDE;
+
+ private:
+ void ReloadHighPriorityWorkQueue();
+
+ scoped_refptr<base::internal::IncomingTaskQueue>
+ high_priority_incoming_task_queue_;
+ scoped_refptr<base::internal::MessageLoopProxyImpl>
+ high_priority_message_loop_proxy_;
+ base::TaskQueue high_priority_work_queue_;
+};
+
+class RendererHighPriorityTaskQueue {
+ public:
+ static bool PostTask(const tracked_objects::Location& from_here,
+ const base::Closure& task);
+ private:
+ RendererHighPriorityTaskQueue() {}
+ DISALLOW_COPY_AND_ASSIGN(RendererHighPriorityTaskQueue);
+};
+
+} // namespace content
+
+#endif // CHROME_RENDERER_RENDERER_MAIN_PLATFORM_DELEGATE_H_
« no previous file with comments | « content/content_renderer.gypi ('k') | content/renderer/renderer_high_priority_task_queue.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698