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

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

Issue 14646034: Add onfocuschange to the Extended Search API, with associated isFocused attribute. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added unit tests Created 7 years, 7 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
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 "chrome/common/url_constants.h" 9 #include "chrome/common/url_constants.h"
10 #include "content/public/browser/navigation_controller.h" 10 #include "content/public/browser/navigation_controller.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 void InstantPage::SendThemeBackgroundInfo( 101 void InstantPage::SendThemeBackgroundInfo(
102 const ThemeBackgroundInfo& theme_info) { 102 const ThemeBackgroundInfo& theme_info) {
103 Send(new ChromeViewMsg_SearchBoxThemeChanged(routing_id(), theme_info)); 103 Send(new ChromeViewMsg_SearchBoxThemeChanged(routing_id(), theme_info));
104 } 104 }
105 105
106 void InstantPage::SetDisplayInstantResults(bool display_instant_results) { 106 void InstantPage::SetDisplayInstantResults(bool display_instant_results) {
107 Send(new ChromeViewMsg_SearchBoxSetDisplayInstantResults( 107 Send(new ChromeViewMsg_SearchBoxSetDisplayInstantResults(
108 routing_id(), display_instant_results)); 108 routing_id(), display_instant_results));
109 } 109 }
110 110
111 void InstantPage::KeyCaptureChanged(bool is_key_capture_enabled) { 111 void InstantPage::FocusChanged(OmniboxFocusState state,
112 Send(new ChromeViewMsg_SearchBoxKeyCaptureChanged( 112 OmniboxFocusChangeReason reason) {
113 routing_id(), is_key_capture_enabled)); 113 Send(new ChromeViewMsg_SearchBoxFocusChanged(routing_id(), state, reason));
114 } 114 }
115 115
116 void InstantPage::SendMostVisitedItems( 116 void InstantPage::SendMostVisitedItems(
117 const std::vector<InstantMostVisitedItemIDPair>& items) { 117 const std::vector<InstantMostVisitedItemIDPair>& items) {
118 Send(new ChromeViewMsg_SearchBoxMostVisitedItemsChanged(routing_id(), items)); 118 Send(new ChromeViewMsg_SearchBoxMostVisitedItemsChanged(routing_id(), items));
119 } 119 }
120 120
121 InstantPage::InstantPage(Delegate* delegate, const std::string& instant_url) 121 InstantPage::InstantPage(Delegate* delegate, const std::string& instant_url)
122 : delegate_(delegate), 122 : delegate_(delegate),
123 instant_url_(instant_url), 123 instant_url_(instant_url),
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
288 delegate_->DeleteMostVisitedItem(restricted_id); 288 delegate_->DeleteMostVisitedItem(restricted_id);
289 } 289 }
290 290
291 void InstantPage::OnUndoMostVisitedDeletion(InstantRestrictedID restricted_id) { 291 void InstantPage::OnUndoMostVisitedDeletion(InstantRestrictedID restricted_id) {
292 delegate_->UndoMostVisitedDeletion(restricted_id); 292 delegate_->UndoMostVisitedDeletion(restricted_id);
293 } 293 }
294 294
295 void InstantPage::OnUndoAllMostVisitedDeletions() { 295 void InstantPage::OnUndoAllMostVisitedDeletions() {
296 delegate_->UndoAllMostVisitedDeletions(); 296 delegate_->UndoAllMostVisitedDeletions();
297 } 297 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698