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

Side by Side Diff: PRESUBMIT.py

Issue 448483003: [Mac] Check for colour constants that do not specify a colourspace. Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 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 """Top-level presubmit script for Chromium. 5 """Top-level presubmit script for Chromium.
6 6
7 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts 7 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts
8 for more details about the presubmit API built into gcl. 8 for more details about the presubmit API built into gcl.
9 """ 9 """
10 10
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 ), 136 ),
137 ( 137 (
138 'convertSizeToBase:', 138 'convertSizeToBase:',
139 ( 139 (
140 'The use of -[NSView convertSizeToBase:] is almost certainly wrong.', 140 'The use of -[NSView convertSizeToBase:] is almost certainly wrong.',
141 'Please use |convertSize:(point) toView:nil| instead.', 141 'Please use |convertSize:(point) toView:nil| instead.',
142 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', 142 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts',
143 ), 143 ),
144 True, 144 True,
145 ), 145 ),
146 (
147 # This is a C++ function, but it returns an NSObject so is only likely
148 # to appear in .mm files.
149 'SkColorToCalibratedNSColor',
150 (
151 '"Calibrated" colors are probably not what you want. Consider using',
152 'SkColorToSRGBNSColor instead of SkColorToCalibratedNSColor.',
153 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts',
154 ),
155 False,
156 ),
157 (
158 # Catch all of [NSColor colorWithCalibrated(Hue|Red|White).*.
159 'colorWithCalibrated',
160 (
161 '"Calibrated" colors are probably not what you want. Consider using',
162 'the +[NSColor colorWithSRGBRed:green:blue:alpha: or the ',
163 '+[NSColor colorWithGenericGamma22White:alpha: method.',
164 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts',
165 ),
166 False,
167 ),
146 ) 168 )
147 169
148 170
149 _BANNED_CPP_FUNCTIONS = ( 171 _BANNED_CPP_FUNCTIONS = (
150 # Make sure that gtest's FRIEND_TEST() macro is not used; the 172 # Make sure that gtest's FRIEND_TEST() macro is not used; the
151 # FRIEND_TEST_ALL_PREFIXES() macro from base/gtest_prod_util.h should be 173 # FRIEND_TEST_ALL_PREFIXES() macro from base/gtest_prod_util.h should be
152 # used instead since that allows for FLAKY_ and DISABLED_ prefixes. 174 # used instead since that allows for FLAKY_ and DISABLED_ prefixes.
153 ( 175 (
154 'FRIEND_TEST(', 176 'FRIEND_TEST(',
155 ( 177 (
(...skipping 1465 matching lines...) Expand 10 before | Expand all | Expand 10 after
1621 builders.extend(['cros_x86']) 1643 builders.extend(['cros_x86'])
1622 1644
1623 # The AOSP bot doesn't build the chrome/ layer, so ignore any changes to it 1645 # The AOSP bot doesn't build the chrome/ layer, so ignore any changes to it
1624 # unless they're .gyp(i) files as changes to those files can break the gyp 1646 # unless they're .gyp(i) files as changes to those files can break the gyp
1625 # step on that bot. 1647 # step on that bot.
1626 if (not all(re.search('^chrome', f) for f in files) or 1648 if (not all(re.search('^chrome', f) for f in files) or
1627 any(re.search('\.gypi?$', f) for f in files)): 1649 any(re.search('\.gypi?$', f) for f in files)):
1628 builders.extend(['android_aosp']) 1650 builders.extend(['android_aosp'])
1629 1651
1630 return GetDefaultTryConfigs(builders) 1652 return GetDefaultTryConfigs(builders)
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698