OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_EXTENSIONS_EXTENSION_HISTORY_API_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_HISTORY_API_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_HISTORY_API_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_HISTORY_API_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <map> | 9 #include <map> |
10 #include <string> | 10 #include <string> |
(...skipping 10 matching lines...) Expand all Loading... |
21 public: | 21 public: |
22 // Single instance of the event router. | 22 // Single instance of the event router. |
23 static ExtensionHistoryEventRouter* GetInstance(); | 23 static ExtensionHistoryEventRouter* GetInstance(); |
24 | 24 |
25 // Safe to call multiple times. | 25 // Safe to call multiple times. |
26 void ObserveProfile(Profile* profile); | 26 void ObserveProfile(Profile* profile); |
27 | 27 |
28 private: | 28 private: |
29 friend struct DefaultSingletonTraits<ExtensionHistoryEventRouter>; | 29 friend struct DefaultSingletonTraits<ExtensionHistoryEventRouter>; |
30 | 30 |
31 ExtensionHistoryEventRouter() {} | 31 ExtensionHistoryEventRouter(); |
32 virtual ~ExtensionHistoryEventRouter() {} | 32 virtual ~ExtensionHistoryEventRouter(); |
33 | 33 |
34 // NotificationObserver::Observe. | 34 // NotificationObserver::Observe. |
35 virtual void Observe(NotificationType type, | 35 virtual void Observe(NotificationType type, |
36 const NotificationSource& source, | 36 const NotificationSource& source, |
37 const NotificationDetails& details); | 37 const NotificationDetails& details); |
38 | 38 |
39 void HistoryUrlVisited(Profile* profile, | 39 void HistoryUrlVisited(Profile* profile, |
40 const history::URLVisitedDetails* details); | 40 const history::URLVisitedDetails* details); |
41 | 41 |
42 void HistoryUrlsRemoved(Profile* profile, | 42 void HistoryUrlsRemoved(Profile* profile, |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
142 class DeleteRangeHistoryFunction : public HistoryFunctionWithCallback { | 142 class DeleteRangeHistoryFunction : public HistoryFunctionWithCallback { |
143 public: | 143 public: |
144 virtual bool RunAsyncImpl(); | 144 virtual bool RunAsyncImpl(); |
145 DECLARE_EXTENSION_FUNCTION_NAME("history.deleteRange"); | 145 DECLARE_EXTENSION_FUNCTION_NAME("history.deleteRange"); |
146 | 146 |
147 // Callback for the history service to acknowledge deletion. | 147 // Callback for the history service to acknowledge deletion. |
148 void DeleteComplete(); | 148 void DeleteComplete(); |
149 }; | 149 }; |
150 | 150 |
151 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_HISTORY_API_H_ | 151 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_HISTORY_API_H_ |
OLD | NEW |