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

Side by Side Diff: chrome/browser/ui/extensions/extension_message_bubble_factory.cc

Issue 2654413002: Stretching NativeViewHost, and misc tab capture fixes.
Patch Set: Gettin' it all working on ui/cocoa and MacViews too. Created 3 years, 10 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 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/extensions/extension_message_bubble_factory.h" 5 #include "chrome/browser/ui/extensions/extension_message_bubble_factory.h"
6 6
7 #include "base/base_switches.h" 7 #include "base/base_switches.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/lazy_instance.h" 9 #include "base/lazy_instance.h"
10 #include "base/metrics/field_trial.h" 10 #include "base/metrics/field_trial.h"
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 #if defined(OS_WIN) || defined(OS_MACOSX) 74 #if defined(OS_WIN) || defined(OS_MACOSX)
75 return true; 75 return true;
76 #else 76 #else
77 return g_override_for_testing == 77 return g_override_for_testing ==
78 ExtensionMessageBubbleFactory::OVERRIDE_ENABLED || 78 ExtensionMessageBubbleFactory::OVERRIDE_ENABLED ||
79 IsExperimentEnabled(kEnableProxyWarningExperimentName); 79 IsExperimentEnabled(kEnableProxyWarningExperimentName);
80 #endif 80 #endif
81 } 81 }
82 82
83 bool EnableDevModeBubble() { 83 bool EnableDevModeBubble() {
84 if (extensions::FeatureSwitch::force_dev_mode_highlighting()->IsEnabled()) 84 return false;
85 return true; 85
86 if (false) {
87 if (extensions::FeatureSwitch::force_dev_mode_highlighting()->IsEnabled())
88 return true;
86 89
87 #if defined(OS_WIN) 90 #if defined(OS_WIN)
88 if (chrome::GetChannel() >= version_info::Channel::BETA) 91 if (chrome::GetChannel() >= version_info::Channel::BETA)
89 return true; 92 return true;
90 #endif 93 #endif
91 94
92 return g_override_for_testing == 95 return g_override_for_testing ==
93 ExtensionMessageBubbleFactory::OVERRIDE_ENABLED || 96 ExtensionMessageBubbleFactory::OVERRIDE_ENABLED ||
94 IsExperimentEnabled(kEnableDevModeWarningExperimentName); 97 IsExperimentEnabled(kEnableDevModeWarningExperimentName);
98 }
95 } 99 }
96 100
97 } // namespace 101 } // namespace
98 102
99 ExtensionMessageBubbleFactory::ExtensionMessageBubbleFactory(Browser* browser) 103 ExtensionMessageBubbleFactory::ExtensionMessageBubbleFactory(Browser* browser)
100 : browser_(browser) { 104 : browser_(browser) {
101 } 105 }
102 106
103 ExtensionMessageBubbleFactory::~ExtensionMessageBubbleFactory() { 107 ExtensionMessageBubbleFactory::~ExtensionMessageBubbleFactory() {
104 } 108 }
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 173
170 controller.reset(); 174 controller.reset();
171 return controller; 175 return controller;
172 } 176 }
173 177
174 // static 178 // static
175 void ExtensionMessageBubbleFactory::set_override_for_tests( 179 void ExtensionMessageBubbleFactory::set_override_for_tests(
176 OverrideForTesting override) { 180 OverrideForTesting override) {
177 g_override_for_testing = override; 181 g_override_for_testing = override;
178 } 182 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698