| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_PAGE_H_ | 5 #ifndef CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_ |
| 6 #define CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_ | 6 #define CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 // Called when the page wants to navigate to |url|. Usually used by the | 85 // Called when the page wants to navigate to |url|. Usually used by the |
| 86 // page to navigate to privileged destinations (e.g. chrome:// URLs) or to | 86 // page to navigate to privileged destinations (e.g. chrome:// URLs) or to |
| 87 // navigate to URLs that are hidden from the page using Restricted IDs (rid | 87 // navigate to URLs that are hidden from the page using Restricted IDs (rid |
| 88 // in the API). | 88 // in the API). |
| 89 virtual void NavigateToURL(const content::WebContents* contents, | 89 virtual void NavigateToURL(const content::WebContents* contents, |
| 90 const GURL& url, | 90 const GURL& url, |
| 91 content::PageTransition transition, | 91 content::PageTransition transition, |
| 92 WindowOpenDisposition disposition, | 92 WindowOpenDisposition disposition, |
| 93 bool is_search_type) = 0; | 93 bool is_search_type) = 0; |
| 94 | 94 |
| 95 // Used to log in UMA the total number of mouseovers over NTP tiles/titles. |
| 96 virtual void LogIframeHover() = 0; |
| 97 |
| 95 // Called when the SearchBox wants to delete a Most Visited item. | 98 // Called when the SearchBox wants to delete a Most Visited item. |
| 96 virtual void DeleteMostVisitedItem(const GURL& url) = 0; | 99 virtual void DeleteMostVisitedItem(const GURL& url) = 0; |
| 97 | 100 |
| 98 // Called when the SearchBox wants to undo a Most Visited deletion. | 101 // Called when the SearchBox wants to undo a Most Visited deletion. |
| 99 virtual void UndoMostVisitedDeletion(const GURL& url) = 0; | 102 virtual void UndoMostVisitedDeletion(const GURL& url) = 0; |
| 100 | 103 |
| 101 // Called when the SearchBox wants to undo all Most Visited deletions. | 104 // Called when the SearchBox wants to undo all Most Visited deletions. |
| 102 virtual void UndoAllMostVisitedDeletions() = 0; | 105 virtual void UndoAllMostVisitedDeletions() = 0; |
| 103 | 106 |
| 104 // Called when the page fails to load for whatever reason. | 107 // Called when the page fails to load for whatever reason. |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 204 const std::vector<InstantSuggestion>& suggestions); | 207 const std::vector<InstantSuggestion>& suggestions); |
| 205 void OnShowInstantOverlay(int page_id, | 208 void OnShowInstantOverlay(int page_id, |
| 206 int height, | 209 int height, |
| 207 InstantSizeUnits units); | 210 InstantSizeUnits units); |
| 208 void OnFocusOmnibox(int page_id, OmniboxFocusState state); | 211 void OnFocusOmnibox(int page_id, OmniboxFocusState state); |
| 209 void OnSearchBoxNavigate(int page_id, | 212 void OnSearchBoxNavigate(int page_id, |
| 210 const GURL& url, | 213 const GURL& url, |
| 211 content::PageTransition transition, | 214 content::PageTransition transition, |
| 212 WindowOpenDisposition disposition, | 215 WindowOpenDisposition disposition, |
| 213 bool is_search_type); | 216 bool is_search_type); |
| 217 void OnLogIframeHover(int page_id); |
| 214 void OnDeleteMostVisitedItem(int page_id, const GURL& url); | 218 void OnDeleteMostVisitedItem(int page_id, const GURL& url); |
| 215 void OnUndoMostVisitedDeletion(int page_id, const GURL& url); | 219 void OnUndoMostVisitedDeletion(int page_id, const GURL& url); |
| 216 void OnUndoAllMostVisitedDeletions(int page_id); | 220 void OnUndoAllMostVisitedDeletions(int page_id); |
| 217 | 221 |
| 218 void ClearContents(); | 222 void ClearContents(); |
| 219 | 223 |
| 220 Delegate* const delegate_; | 224 Delegate* const delegate_; |
| 221 scoped_ptr<InstantIPCSender> ipc_sender_; | 225 scoped_ptr<InstantIPCSender> ipc_sender_; |
| 222 const std::string instant_url_; | 226 const std::string instant_url_; |
| 223 const bool is_incognito_; | 227 const bool is_incognito_; |
| 224 | 228 |
| 225 DISALLOW_COPY_AND_ASSIGN(InstantPage); | 229 DISALLOW_COPY_AND_ASSIGN(InstantPage); |
| 226 }; | 230 }; |
| 227 | 231 |
| 228 #endif // CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_ | 232 #endif // CHROME_BROWSER_UI_SEARCH_INSTANT_PAGE_H_ |
| OLD | NEW |