| 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 // Defines the Chrome Extensions BrowsingData API functions, which entail | 5 // Defines the Chrome Extensions BrowsingData API functions, which entail |
| 6 // clearing browsing data, and clearing the browser's cache (which, let's be | 6 // clearing browsing data, and clearing the browser's cache (which, let's be |
| 7 // honest, are the same thing), as specified in the extension API JSON. | 7 // honest, are the same thing), as specified in the extension API JSON. |
| 8 | 8 |
| 9 #ifndef CHROME_BROWSER_EXTENSIONS_API_BROWSING_DATA_BROWSING_DATA_API_H_ | 9 #ifndef CHROME_BROWSER_EXTENSIONS_API_BROWSING_DATA_BROWSING_DATA_API_H_ |
| 10 #define CHROME_BROWSER_EXTENSIONS_API_BROWSING_DATA_BROWSING_DATA_API_H_ | 10 #define CHROME_BROWSER_EXTENSIONS_API_BROWSING_DATA_BROWSING_DATA_API_H_ |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 extern const char kDeleteProhibitedError[]; | 49 extern const char kDeleteProhibitedError[]; |
| 50 extern const char kOneAtATimeError[]; | 50 extern const char kOneAtATimeError[]; |
| 51 | 51 |
| 52 } // namespace extension_browsing_data_api_constants | 52 } // namespace extension_browsing_data_api_constants |
| 53 | 53 |
| 54 class BrowsingDataSettingsFunction : public ChromeSyncExtensionFunction { | 54 class BrowsingDataSettingsFunction : public ChromeSyncExtensionFunction { |
| 55 public: | 55 public: |
| 56 DECLARE_EXTENSION_FUNCTION("browsingData.settings", BROWSINGDATA_SETTINGS) | 56 DECLARE_EXTENSION_FUNCTION("browsingData.settings", BROWSINGDATA_SETTINGS) |
| 57 | 57 |
| 58 // ExtensionFunction: | 58 // ExtensionFunction: |
| 59 virtual bool RunImpl() OVERRIDE; | 59 virtual bool RunSync() OVERRIDE; |
| 60 | 60 |
| 61 protected: | 61 protected: |
| 62 virtual ~BrowsingDataSettingsFunction() {} | 62 virtual ~BrowsingDataSettingsFunction() {} |
| 63 | 63 |
| 64 private: | 64 private: |
| 65 // Sets a boolean value in the |selected_dict| with the |data_type| as a key, | 65 // Sets a boolean value in the |selected_dict| with the |data_type| as a key, |
| 66 // indicating whether the data type is both selected and permitted to be | 66 // indicating whether the data type is both selected and permitted to be |
| 67 // removed; and a value in the |permitted_dict| with the |data_type| as a | 67 // removed; and a value in the |permitted_dict| with the |data_type| as a |
| 68 // key, indicating only whether the data type is permitted to be removed. | 68 // key, indicating only whether the data type is permitted to be removed. |
| 69 void SetDetails(base::DictionaryValue* selected_dict, | 69 void SetDetails(base::DictionaryValue* selected_dict, |
| (...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 265 BROWSINGDATA_REMOVEWEBSQL) | 265 BROWSINGDATA_REMOVEWEBSQL) |
| 266 | 266 |
| 267 protected: | 267 protected: |
| 268 virtual ~BrowsingDataRemoveWebSQLFunction() {} | 268 virtual ~BrowsingDataRemoveWebSQLFunction() {} |
| 269 | 269 |
| 270 // BrowsingDataRemoverFunction: | 270 // BrowsingDataRemoverFunction: |
| 271 virtual int GetRemovalMask() OVERRIDE; | 271 virtual int GetRemovalMask() OVERRIDE; |
| 272 }; | 272 }; |
| 273 | 273 |
| 274 #endif // CHROME_BROWSER_EXTENSIONS_API_BROWSING_DATA_BROWSING_DATA_API_H_ | 274 #endif // CHROME_BROWSER_EXTENSIONS_API_BROWSING_DATA_BROWSING_DATA_API_H_ |
| OLD | NEW |