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

Side by Side Diff: chrome/browser/ui/omnibox/chrome_omnibox_edit_controller.cc

Issue 2479593006: Move enable extensions define to a build flag. (Closed)
Patch Set: Merge Created 4 years, 1 month 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
« no previous file with comments | « chrome/browser/ui/media_utils.cc ('k') | chrome/browser/ui/prefs/prefs_tab_helper.cc » ('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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/omnibox/chrome_omnibox_edit_controller.h" 5 #include "chrome/browser/ui/omnibox/chrome_omnibox_edit_controller.h"
6 6
7 #include "chrome/app/chrome_command_ids.h" 7 #include "chrome/app/chrome_command_ids.h"
8 #include "chrome/browser/command_updater.h" 8 #include "chrome/browser/command_updater.h"
9 #include "components/toolbar/toolbar_model.h" 9 #include "components/toolbar/toolbar_model.h"
10 #include "extensions/features/features.h"
10 11
11 #if defined(ENABLE_EXTENSIONS) 12 #if BUILDFLAG(ENABLE_EXTENSIONS)
12 #include "chrome/browser/ui/extensions/settings_api_bubble_helpers.h" 13 #include "chrome/browser/ui/extensions/settings_api_bubble_helpers.h"
13 #endif 14 #endif
14 15
15 ChromeOmniboxEditController::ChromeOmniboxEditController( 16 ChromeOmniboxEditController::ChromeOmniboxEditController(
16 CommandUpdater* command_updater) 17 CommandUpdater* command_updater)
17 : command_updater_(command_updater) {} 18 : command_updater_(command_updater) {}
18 19
19 ChromeOmniboxEditController::~ChromeOmniboxEditController() {} 20 ChromeOmniboxEditController::~ChromeOmniboxEditController() {}
20 21
21 void ChromeOmniboxEditController::OnAutocompleteAccept( 22 void ChromeOmniboxEditController::OnAutocompleteAccept(
22 const GURL& destination_url, 23 const GURL& destination_url,
23 WindowOpenDisposition disposition, 24 WindowOpenDisposition disposition,
24 ui::PageTransition transition, 25 ui::PageTransition transition,
25 AutocompleteMatchType::Type match_type) { 26 AutocompleteMatchType::Type match_type) {
26 OmniboxEditController::OnAutocompleteAccept(destination_url, disposition, 27 OmniboxEditController::OnAutocompleteAccept(destination_url, disposition,
27 transition, match_type); 28 transition, match_type);
28 if (command_updater_) 29 if (command_updater_)
29 command_updater_->ExecuteCommand(IDC_OPEN_CURRENT_URL); 30 command_updater_->ExecuteCommand(IDC_OPEN_CURRENT_URL);
30 31
31 #if defined(ENABLE_EXTENSIONS) 32 #if BUILDFLAG(ENABLE_EXTENSIONS)
32 extensions::MaybeShowExtensionControlledSearchNotification( 33 extensions::MaybeShowExtensionControlledSearchNotification(
33 GetWebContents(), match_type); 34 GetWebContents(), match_type);
34 #endif 35 #endif
35 } 36 }
36 37
37 void ChromeOmniboxEditController::OnInputInProgress(bool in_progress) { 38 void ChromeOmniboxEditController::OnInputInProgress(bool in_progress) {
38 GetToolbarModel()->set_input_in_progress(in_progress); 39 GetToolbarModel()->set_input_in_progress(in_progress);
39 UpdateWithoutTabRestore(); 40 UpdateWithoutTabRestore();
40 } 41 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/media_utils.cc ('k') | chrome/browser/ui/prefs/prefs_tab_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698