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

Unified Diff: ui/app_list/search_controller.cc

Issue 2846733004: Optimization: not sending answer server requests for voice queries. (Closed)
Patch Set: Last nits Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/app_list/search_controller.h ('k') | ui/app_list/views/app_list_main_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/app_list/search_controller.cc
diff --git a/ui/app_list/search_controller.cc b/ui/app_list/search_controller.cc
index 83cca8d94661d2c13fbe7f725dad73d82454f0d1..cae058357c4ea02bff3b211b9500e84fc20b9722 100644
--- a/ui/app_list/search_controller.cc
+++ b/ui/app_list/search_controller.cc
@@ -36,21 +36,21 @@ SearchController::SearchController(SearchBoxModel* search_box,
SearchController::~SearchController() {
}
-void SearchController::Start(bool is_voice_query) {
+void SearchController::Start() {
Stop();
base::string16 query;
base::TrimWhitespace(search_box_->text(), base::TRIM_ALL, &query);
+ is_voice_query_ = search_box_->is_voice_query();
+
dispatching_query_ = true;
for (const auto& provider : providers_)
- provider->Start(is_voice_query, query);
+ provider->Start(is_voice_query_, query);
dispatching_query_ = false;
query_for_recommendation_ = query.empty() ? true : false;
- is_voice_query_ = is_voice_query;
-
OnResultsChanged();
stop_timer_.Start(FROM_HERE,
« no previous file with comments | « ui/app_list/search_controller.h ('k') | ui/app_list/views/app_list_main_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698