| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // | 5 // |
| 6 // This file contains the Extension App autocomplete provider. The provider | 6 // This file contains the Extension App autocomplete provider. The provider |
| 7 // is responsible for keeping track of which Extension Apps are installed and | 7 // is responsible for keeping track of which Extension Apps are installed and |
| 8 // their URLs. An instance of it gets created and managed by the autocomplete | 8 // their URLs. An instance of it gets created and managed by the autocomplete |
| 9 // controller. | 9 // controller. |
| 10 // | 10 // |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 51 // Register for install/uninstall notification so we can update our cache. | 51 // Register for install/uninstall notification so we can update our cache. |
| 52 void RegisterForNotifications(); | 52 void RegisterForNotifications(); |
| 53 | 53 |
| 54 // Calculate the relevance of the match. | 54 // Calculate the relevance of the match. |
| 55 int CalculateRelevance(AutocompleteInput::Type type, | 55 int CalculateRelevance(AutocompleteInput::Type type, |
| 56 int input_length, | 56 int input_length, |
| 57 int target_length, | 57 int target_length, |
| 58 const GURL& url); | 58 const GURL& url); |
| 59 | 59 |
| 60 // NotificationObserver implementation: | 60 // NotificationObserver implementation: |
| 61 virtual void Observe(NotificationType type, | 61 virtual void Observe(int type, |
| 62 const NotificationSource& source, | 62 const NotificationSource& source, |
| 63 const NotificationDetails& details) OVERRIDE; | 63 const NotificationDetails& details) OVERRIDE; |
| 64 | 64 |
| 65 NotificationRegistrar registrar_; | 65 NotificationRegistrar registrar_; |
| 66 | 66 |
| 67 // Our cache of ExtensionApp objects (name + url) representing the extension | 67 // Our cache of ExtensionApp objects (name + url) representing the extension |
| 68 // apps we know about. | 68 // apps we know about. |
| 69 ExtensionApps extension_apps_; | 69 ExtensionApps extension_apps_; |
| 70 | 70 |
| 71 DISALLOW_COPY_AND_ASSIGN(ExtensionAppProvider); | 71 DISALLOW_COPY_AND_ASSIGN(ExtensionAppProvider); |
| 72 }; | 72 }; |
| 73 | 73 |
| 74 #endif // CHROME_BROWSER_AUTOCOMPLETE_EXTENSION_APP_PROVIDER_H_ | 74 #endif // CHROME_BROWSER_AUTOCOMPLETE_EXTENSION_APP_PROVIDER_H_ |
| OLD | NEW |