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_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 368 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
379 | 379 |
380 private: | 380 private: |
381 void DispatchEvent( | 381 void DispatchEvent( |
382 events::HistogramValue histogram_value, | 382 events::HistogramValue histogram_value, |
383 const std::string& event_name, | 383 const std::string& event_name, |
384 bool include_incognito, | 384 bool include_incognito, |
385 const extensions::Event::WillDispatchCallback& will_dispatch_callback, | 385 const extensions::Event::WillDispatchCallback& will_dispatch_callback, |
386 std::unique_ptr<base::Value> json_arg); | 386 std::unique_ptr<base::Value> json_arg); |
387 | 387 |
388 // extensions::ExtensionRegistryObserver. | 388 // extensions::ExtensionRegistryObserver. |
389 void OnExtensionUnloaded( | 389 void OnExtensionUnloaded(content::BrowserContext* browser_context, |
390 content::BrowserContext* browser_context, | 390 const extensions::Extension* extension, |
391 const extensions::Extension* extension, | 391 extensions::UnloadedExtensionReason reason) override; |
392 extensions::UnloadedExtensionInfo::Reason reason) override; | |
393 | 392 |
394 Profile* profile_; | 393 Profile* profile_; |
395 AllDownloadItemNotifier notifier_; | 394 AllDownloadItemNotifier notifier_; |
396 std::set<const extensions::Extension*> shelf_disabling_extensions_; | 395 std::set<const extensions::Extension*> shelf_disabling_extensions_; |
397 | 396 |
398 base::Time last_checked_removal_; | 397 base::Time last_checked_removal_; |
399 | 398 |
400 // Listen to extension unloaded notifications. | 399 // Listen to extension unloaded notifications. |
401 ScopedObserver<extensions::ExtensionRegistry, | 400 ScopedObserver<extensions::ExtensionRegistry, |
402 extensions::ExtensionRegistryObserver> | 401 extensions::ExtensionRegistryObserver> |
403 extension_registry_observer_; | 402 extension_registry_observer_; |
404 | 403 |
405 DISALLOW_COPY_AND_ASSIGN(ExtensionDownloadsEventRouter); | 404 DISALLOW_COPY_AND_ASSIGN(ExtensionDownloadsEventRouter); |
406 }; | 405 }; |
407 | 406 |
408 } // namespace extensions | 407 } // namespace extensions |
409 | 408 |
410 #endif // CHROME_BROWSER_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ | 409 #endif // CHROME_BROWSER_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ |
OLD | NEW |