OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef MOJO_SERVICES_HTML_VIEWER_WEBTHREAD_IMPL_H_ | 5 #ifndef MOJO_SERVICES_HTML_VIEWER_WEBTHREAD_IMPL_H_ |
6 #define MOJO_SERVICES_HTML_VIEWER_WEBTHREAD_IMPL_H_ | 6 #define MOJO_SERVICES_HTML_VIEWER_WEBTHREAD_IMPL_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 | 9 |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
11 #include "base/threading/thread.h" | 11 #include "base/threading/thread.h" |
12 #include "third_party/WebKit/public/platform/WebThread.h" | 12 #include "third_party/WebKit/public/platform/WebThread.h" |
13 | 13 |
14 namespace mojo { | 14 namespace html_viewer { |
15 | 15 |
16 class WebThreadBase : public blink::WebThread { | 16 class WebThreadBase : public blink::WebThread { |
17 public: | 17 public: |
18 virtual ~WebThreadBase(); | 18 virtual ~WebThreadBase(); |
19 | 19 |
20 virtual void addTaskObserver(TaskObserver* observer); | 20 virtual void addTaskObserver(TaskObserver* observer); |
21 virtual void removeTaskObserver(TaskObserver* observer); | 21 virtual void removeTaskObserver(TaskObserver* observer); |
22 | 22 |
23 virtual bool isCurrentThread() const = 0; | 23 virtual bool isCurrentThread() const = 0; |
24 virtual blink::PlatformThreadId threadId() const = 0; | 24 virtual blink::PlatformThreadId threadId() const = 0; |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 virtual void exitRunLoop(); | 66 virtual void exitRunLoop(); |
67 | 67 |
68 private: | 68 private: |
69 virtual bool isCurrentThread() const; | 69 virtual bool isCurrentThread() const; |
70 virtual blink::PlatformThreadId threadId() const; | 70 virtual blink::PlatformThreadId threadId() const; |
71 | 71 |
72 scoped_refptr<base::MessageLoopProxy> message_loop_; | 72 scoped_refptr<base::MessageLoopProxy> message_loop_; |
73 blink::PlatformThreadId thread_id_; | 73 blink::PlatformThreadId thread_id_; |
74 }; | 74 }; |
75 | 75 |
76 } // namespace mojo | 76 } // namespace html_viewer |
77 | 77 |
78 #endif // MOJO_SERVICES_HTML_VIEWER_WEBTHREAD_IMPL_H_ | 78 #endif // MOJO_SERVICES_HTML_VIEWER_WEBTHREAD_IMPL_H_ |
OLD | NEW |