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

Side by Side Diff: third_party/scons/scons-local/SCons/Variables/BoolVariable.py

Issue 17024: Update to SCons 1.2.0. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 11 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
OLDNEW
1 """engine.SCons.Variables.BoolVariable 1 """engine.SCons.Variables.BoolVariable
2 2
3 This file defines the option type for SCons implementing true/false values. 3 This file defines the option type for SCons implementing true/false values.
4 4
5 Usage example: 5 Usage example:
6 6
7 opts = Variables() 7 opts = Variables()
8 opts.Add(BoolVariable('embedded', 'build for an embedded system', 0)) 8 opts.Add(BoolVariable('embedded', 'build for an embedded system', 0))
9 ... 9 ...
10 if env['embedded'] == 1: 10 if env['embedded'] == 1:
(...skipping 16 matching lines...) Expand all
27 # 27 #
28 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY 28 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
29 # KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE 29 # KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
30 # WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 30 # WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
31 # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 31 # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
32 # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 32 # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
33 # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 33 # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
34 # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 34 # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
35 # 35 #
36 36
37 __revision__ = "src/engine/SCons/Variables/BoolVariable.py 3603 2008/10/10 05:46 :45 scons" 37 __revision__ = "src/engine/SCons/Variables/BoolVariable.py 3842 2008/12/20 22:59 :52 scons"
38 38
39 __all__ = ['BoolVariable',] 39 __all__ = ['BoolVariable',]
40 40
41 import string 41 import string
42 42
43 import SCons.Errors 43 import SCons.Errors
44 44
45 __true_strings = ('y', 'yes', 'true', 't', '1', 'on' , 'all' ) 45 __true_strings = ('y', 'yes', 'true', 't', '1', 'on' , 'all' )
46 __false_strings = ('n', 'no', 'false', 'f', '0', 'off', 'none') 46 __false_strings = ('n', 'no', 'false', 'f', '0', 'off', 'none')
47 47
(...skipping 28 matching lines...) Expand all
76 76
77 def BoolVariable(key, help, default): 77 def BoolVariable(key, help, default):
78 """ 78 """
79 The input parameters describe a boolen option, thus they are 79 The input parameters describe a boolen option, thus they are
80 returned with the correct converter and validator appended. The 80 returned with the correct converter and validator appended. The
81 'help' text will by appended by '(yes|no) to show the valid 81 'help' text will by appended by '(yes|no) to show the valid
82 valued. The result is usable for input to opts.Add(). 82 valued. The result is usable for input to opts.Add().
83 """ 83 """
84 return (key, '%s (yes|no)' % help, default, 84 return (key, '%s (yes|no)' % help, default,
85 _validator, _text2bool) 85 _validator, _text2bool)
OLDNEW
« no previous file with comments | « third_party/scons/scons-local/SCons/Util.py ('k') | third_party/scons/scons-local/SCons/Variables/EnumVariable.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698