OLD | NEW |
1 // Copyright (c) 2012 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_GLUE_SYNCED_WINDOW_DELEGATE_REGISTRY_H_ | 5 #ifndef CHROME_BROWSER_SYNC_GLUE_SYNCED_WINDOW_DELEGATE_REGISTRY_H_ |
6 #define CHROME_BROWSER_SYNC_GLUE_SYNCED_WINDOW_DELEGATE_REGISTRY_H_ | 6 #define CHROME_BROWSER_SYNC_GLUE_SYNCED_WINDOW_DELEGATE_REGISTRY_H_ |
7 #pragma once | |
8 | 7 |
9 #include <set> | 8 #include <set> |
10 | 9 |
11 namespace browser_sync { | 10 namespace browser_sync { |
12 | 11 |
13 class SyncedWindowDelegate; | 12 class SyncedWindowDelegate; |
14 | 13 |
15 // A location to register SyncedWindowDelegates such that Android can provide | 14 // A location to register SyncedWindowDelegates such that Android can provide |
16 // pseudo-browsers for the purposes of Sync without having a dependency from | 15 // pseudo-browsers for the purposes of Sync without having a dependency from |
17 // sync onto Android's model of a browser. | 16 // sync onto Android's model of a browser. |
18 class SyncedWindowDelegateRegistry { | 17 class SyncedWindowDelegateRegistry { |
19 public: | 18 public: |
20 static const std::set<SyncedWindowDelegate*>& GetSyncedWindowDelegates(); | 19 static const std::set<SyncedWindowDelegate*>& GetSyncedWindowDelegates(); |
21 static void Register(SyncedWindowDelegate* delegate); | 20 static void Register(SyncedWindowDelegate* delegate); |
22 static void Unregister(SyncedWindowDelegate* delegate); | 21 static void Unregister(SyncedWindowDelegate* delegate); |
23 }; | 22 }; |
24 | 23 |
25 } // namespace browser_sync | 24 } // namespace browser_sync |
26 | 25 |
27 #endif // CHROME_BROWSER_SYNC_GLUE_SYNCED_WINDOW_DELEGATE_REGISTRY_H_ | 26 #endif // CHROME_BROWSER_SYNC_GLUE_SYNCED_WINDOW_DELEGATE_REGISTRY_H_ |
OLD | NEW |