OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CHROME_BROWSER_SYNC_SYNC_JS_CONTROLLER_H_ | 5 #ifndef SYNC_JS_SYNC_JS_CONTROLLER_H_ |
6 #define CHROME_BROWSER_SYNC_SYNC_JS_CONTROLLER_H_ | 6 #define SYNC_JS_SYNC_JS_CONTROLLER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "base/basictypes.h" | 12 #include "base/basictypes.h" |
13 #include "base/compiler_specific.h" | 13 #include "base/compiler_specific.h" |
14 #include "base/memory/weak_ptr.h" | 14 #include "base/memory/weak_ptr.h" |
15 #include "base/observer_list.h" | 15 #include "base/observer_list.h" |
16 #include "chrome/browser/sync/js/js_arg_list.h" | 16 #include "sync/js/js_arg_list.h" |
17 #include "chrome/browser/sync/js/js_controller.h" | 17 #include "sync/js/js_controller.h" |
18 #include "chrome/browser/sync/js/js_event_handler.h" | 18 #include "sync/js/js_event_handler.h" |
19 #include "chrome/browser/sync/util/weak_handle.h" | 19 #include "sync/util/weak_handle.h" |
20 | 20 |
21 namespace browser_sync { | 21 namespace browser_sync { |
22 | 22 |
23 class JsBackend; | 23 class JsBackend; |
24 | 24 |
25 // A class that mediates between the sync JsEventHandlers and the sync | 25 // A class that mediates between the sync JsEventHandlers and the sync |
26 // JsBackend. | 26 // JsBackend. |
27 class SyncJsController | 27 class SyncJsController |
28 : public JsController, public JsEventHandler, | 28 : public JsController, public JsEventHandler, |
29 public base::SupportsWeakPtr<SyncJsController> { | 29 public base::SupportsWeakPtr<SyncJsController> { |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 | 71 |
72 WeakHandle<JsBackend> js_backend_; | 72 WeakHandle<JsBackend> js_backend_; |
73 ObserverList<JsEventHandler> js_event_handlers_; | 73 ObserverList<JsEventHandler> js_event_handlers_; |
74 PendingJsMessageList pending_js_messages_; | 74 PendingJsMessageList pending_js_messages_; |
75 | 75 |
76 DISALLOW_COPY_AND_ASSIGN(SyncJsController); | 76 DISALLOW_COPY_AND_ASSIGN(SyncJsController); |
77 }; | 77 }; |
78 | 78 |
79 } // namespace browser_sync | 79 } // namespace browser_sync |
80 | 80 |
81 #endif // CHROME_BROWSER_SYNC_SYNC_JS_CONTROLLER_H_ | 81 #endif // SYNC_JS_SYNC_JS_CONTROLLER_H_ |
OLD | NEW |