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

Side by Side Diff: chrome/browser/resources/options/chromeos/internet_detail_ip_address_field.js

Issue 543493002: Compile chrome://settings, part 2: reduce from 950 to 400 errors (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@F_settings
Patch Set: rebase? rebase! Created 6 years, 3 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 (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 cr.define('options.internet', function() { 5 cr.define('options.internet', function() {
6 /** @const */ var EditableTextField = options.EditableTextField; 6 /** @const */ var EditableTextField = options.EditableTextField;
7 7
8 /** 8 /**
9 * The regular expression that matches an IP address. String to match against 9 * The regular expression that matches an IP address. String to match against
10 * should have all whitespace stripped already. 10 * should have all whitespace stripped already.
11 * @const 11 * @const
12 * @type {RegExp} 12 * @type {RegExp}
13 */ 13 */
14 var singleIp_ = /^([0-9]+)\.([0-9]+)\.([0-9]+)\.([0-9]+)$/; 14 var singleIp_ = /^([0-9]+)\.([0-9]+)\.([0-9]+)\.([0-9]+)$/;
15 15
16 /** 16 /**
17 * Creates a new field specifically for entering IP addresses. 17 * Creates a new field specifically for entering IP addresses.
18 * @constructor 18 * @constructor
19 * @extends {options.EditableTextField}
19 */ 20 */
20 function IPAddressField() { 21 function IPAddressField() {
21 var el = cr.doc.createElement('div'); 22 var el = cr.doc.createElement('div');
22 IPAddressField.decorate(el); 23 IPAddressField.decorate(el);
23 return el; 24 return el;
24 } 25 }
25 26
26 /** 27 /**
27 * Decorates an element as a inline-editable list item. Note that this is 28 * Decorates an element as a inline-editable list item. Note that this is
28 * a subclass of IPAddressField. 29 * a subclass of IPAddressField.
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 result.push(parseInt(matches[i], 10)); 103 result.push(parseInt(matches[i], 10));
103 } 104 }
104 return result.join('.'); 105 return result.join('.');
105 }, 106 },
106 }; 107 };
107 108
108 return { 109 return {
109 IPAddressField: IPAddressField, 110 IPAddressField: IPAddressField,
110 }; 111 };
111 }); 112 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698