OLD | NEW |
---|---|
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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_UI_SEARCH_INSTANT_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_UI_SEARCH_INSTANT_CONTROLLER_H_ |
6 #define CHROME_BROWSER_UI_SEARCH_INSTANT_CONTROLLER_H_ | 6 #define CHROME_BROWSER_UI_SEARCH_INSTANT_CONTROLLER_H_ |
7 | 7 |
8 #include <list> | 8 #include <list> |
9 #include <string> | 9 #include <string> |
10 #include <utility> | 10 #include <utility> |
(...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
435 | 435 |
436 // Populates InstantAutocompleteResult with AutocompleteMatch details. | 436 // Populates InstantAutocompleteResult with AutocompleteMatch details. |
437 // |autocomplete_match_index| specifies the index of |match| in the | 437 // |autocomplete_match_index| specifies the index of |match| in the |
438 // AutocompleteResult. If the |match| is obtained from auto complete | 438 // AutocompleteResult. If the |match| is obtained from auto complete |
439 // providers, then the |autocomplete_match_index| is set to kNoMatchIndex. | 439 // providers, then the |autocomplete_match_index| is set to kNoMatchIndex. |
440 void PopulateInstantAutocompleteResultFromMatch( | 440 void PopulateInstantAutocompleteResultFromMatch( |
441 const AutocompleteMatch& match, | 441 const AutocompleteMatch& match, |
442 size_t autocomplete_match_index, | 442 size_t autocomplete_match_index, |
443 InstantAutocompleteResult* result); | 443 InstantAutocompleteResult* result); |
444 | 444 |
445 // Experiment that removes recommended URLs if a matching URL is already open | |
446 // in the Browser. | |
beaudoin
2013/06/20 21:55:44
Rephrase: Removes recommended URLs ... if the rele
annark1
2013/07/04 18:29:15
Done.
| |
447 void MaybeRemoveMostVisitedItems(std::vector<InstantMostVisitedItem>* items); | |
448 | |
445 BrowserInstantController* const browser_; | 449 BrowserInstantController* const browser_; |
446 | 450 |
447 // Whether the extended API and regular API are enabled. If both are false, | 451 // Whether the extended API and regular API are enabled. If both are false, |
448 // Instant is effectively disabled. | 452 // Instant is effectively disabled. |
449 const bool extended_enabled_; | 453 const bool extended_enabled_; |
450 bool instant_enabled_; | 454 bool instant_enabled_; |
451 | 455 |
452 // If true, the Instant URL is set to kChromeSearchLocalNtpUrl. | 456 // If true, the Instant URL is set to kChromeSearchLocalNtpUrl. |
453 bool use_local_page_only_; | 457 bool use_local_page_only_; |
454 | 458 |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
543 // MODE_SEARCH_SUGGESTIONS, except in those cases where this is false. | 547 // MODE_SEARCH_SUGGESTIONS, except in those cases where this is false. |
544 bool allow_overlay_to_show_search_suggestions_; | 548 bool allow_overlay_to_show_search_suggestions_; |
545 | 549 |
546 // List of events and their timestamps, useful in debugging Instant behaviour. | 550 // List of events and their timestamps, useful in debugging Instant behaviour. |
547 mutable std::list<std::pair<int64, std::string> > debug_events_; | 551 mutable std::list<std::pair<int64, std::string> > debug_events_; |
548 | 552 |
549 DISALLOW_COPY_AND_ASSIGN(InstantController); | 553 DISALLOW_COPY_AND_ASSIGN(InstantController); |
550 }; | 554 }; |
551 | 555 |
552 #endif // CHROME_BROWSER_UI_SEARCH_INSTANT_CONTROLLER_H_ | 556 #endif // CHROME_BROWSER_UI_SEARCH_INSTANT_CONTROLLER_H_ |
OLD | NEW |