Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(31)

Side by Side Diff: chrome/browser/ui/search/instant_page.cc

Issue 12498002: InstantExtended: Adding InstantRestrictedIDCache. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixing android compile error. Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/ui/search/instant_page.h ('k') | chrome/chrome_common.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "chrome/browser/ui/search/instant_page.h" 5 #include "chrome/browser/ui/search/instant_page.h"
6 6
7 #include "base/utf_string_conversions.h" 7 #include "base/utf_string_conversions.h"
8 #include "chrome/common/render_messages.h" 8 #include "chrome/common/render_messages.h"
9 #include "content/public/browser/web_contents.h" 9 #include "content/public/browser/web_contents.h"
10 #include "ui/base/resource/resource_bundle.h" 10 #include "ui/base/resource/resource_bundle.h"
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 Send(new ChromeViewMsg_SearchBoxSetDisplayInstantResults( 88 Send(new ChromeViewMsg_SearchBoxSetDisplayInstantResults(
89 routing_id(), display_instant_results)); 89 routing_id(), display_instant_results));
90 } 90 }
91 91
92 void InstantPage::KeyCaptureChanged(bool is_key_capture_enabled) { 92 void InstantPage::KeyCaptureChanged(bool is_key_capture_enabled) {
93 Send(new ChromeViewMsg_SearchBoxKeyCaptureChanged( 93 Send(new ChromeViewMsg_SearchBoxKeyCaptureChanged(
94 routing_id(), is_key_capture_enabled)); 94 routing_id(), is_key_capture_enabled));
95 } 95 }
96 96
97 void InstantPage::SendMostVisitedItems( 97 void InstantPage::SendMostVisitedItems(
98 const std::vector<InstantMostVisitedItem>& items) { 98 const std::vector<InstantMostVisitedItemIDPair>& items) {
99 Send(new ChromeViewMsg_SearchBoxMostVisitedItemsChanged(routing_id(), items)); 99 Send(new ChromeViewMsg_SearchBoxMostVisitedItemsChanged(routing_id(), items));
100 } 100 }
101 101
102 InstantPage::InstantPage(Delegate* delegate) 102 InstantPage::InstantPage(Delegate* delegate)
103 : delegate_(delegate), 103 : delegate_(delegate),
104 supports_instant_(false) { 104 supports_instant_(false) {
105 } 105 }
106 106
107 void InstantPage::SetContents(content::WebContents* contents) { 107 void InstantPage::SetContents(content::WebContents* contents) {
108 Observe(contents); 108 Observe(contents);
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 const GURL& url, 262 const GURL& url,
263 content::PageTransition transition, 263 content::PageTransition transition,
264 WindowOpenDisposition disposition) { 264 WindowOpenDisposition disposition) {
265 if (contents()->IsActiveEntry(page_id)) { 265 if (contents()->IsActiveEntry(page_id)) {
266 OnInstantSupportDetermined(page_id, true); 266 OnInstantSupportDetermined(page_id, true);
267 if (ShouldProcessNavigateToURL()) 267 if (ShouldProcessNavigateToURL())
268 delegate_->NavigateToURL(contents(), url, transition, disposition); 268 delegate_->NavigateToURL(contents(), url, transition, disposition);
269 } 269 }
270 } 270 }
271 271
272 void InstantPage::OnDeleteMostVisitedItem(uint64 most_visited_item_id) { 272 void InstantPage::OnDeleteMostVisitedItem(InstantRestrictedID restricted_id) {
273 delegate_->DeleteMostVisitedItem(most_visited_item_id); 273 delegate_->DeleteMostVisitedItem(restricted_id);
274 } 274 }
275 275
276 void InstantPage::OnUndoMostVisitedDeletion(uint64 most_visited_item_id) { 276 void InstantPage::OnUndoMostVisitedDeletion(InstantRestrictedID restricted_id) {
277 delegate_->UndoMostVisitedDeletion(most_visited_item_id); 277 delegate_->UndoMostVisitedDeletion(restricted_id);
278 } 278 }
279 279
280 void InstantPage::OnUndoAllMostVisitedDeletions() { 280 void InstantPage::OnUndoAllMostVisitedDeletions() {
281 delegate_->UndoAllMostVisitedDeletions(); 281 delegate_->UndoAllMostVisitedDeletions();
282 } 282 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/search/instant_page.h ('k') | chrome/chrome_common.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698