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 #include "chrome/browser/ui/search/search_tab_helper.h" | 5 #include "chrome/browser/ui/search/search_tab_helper.h" |
6 | 6 |
7 #include "chrome/browser/ui/search/search.h" | 7 #include "chrome/browser/instant/search.h" |
8 #include "chrome/common/url_constants.h" | 8 #include "chrome/common/url_constants.h" |
9 #include "content/public/browser/navigation_entry.h" | 9 #include "content/public/browser/navigation_entry.h" |
10 #include "content/public/browser/notification_service.h" | 10 #include "content/public/browser/notification_service.h" |
11 #include "content/public/browser/notification_types.h" | 11 #include "content/public/browser/notification_types.h" |
12 | 12 |
13 DEFINE_WEB_CONTENTS_USER_DATA_KEY(chrome::search::SearchTabHelper); | 13 DEFINE_WEB_CONTENTS_USER_DATA_KEY(chrome::search::SearchTabHelper); |
14 | 14 |
15 namespace { | 15 namespace { |
16 | 16 |
17 bool IsNTP(const content::WebContents* contents) { | 17 bool IsNTP(const content::WebContents* contents) { |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 type = Mode::MODE_SEARCH_RESULTS; | 88 type = Mode::MODE_SEARCH_RESULTS; |
89 origin = Mode::ORIGIN_SEARCH; | 89 origin = Mode::ORIGIN_SEARCH; |
90 } | 90 } |
91 if (user_input_in_progress_) | 91 if (user_input_in_progress_) |
92 type = Mode::MODE_SEARCH_SUGGESTIONS; | 92 type = Mode::MODE_SEARCH_SUGGESTIONS; |
93 model_.SetMode(Mode(type, origin)); | 93 model_.SetMode(Mode(type, origin)); |
94 } | 94 } |
95 | 95 |
96 } // namespace search | 96 } // namespace search |
97 } // namespace chrome | 97 } // namespace chrome |
OLD | NEW |