[sql] Remove _HAS_EXCEPTIONS=0 from build info.
[chromium-blink-merge.git] / chrome / browser / resources / settings / internet_page / network_proxy_input.js
blobebd926df5f9a7962ea26ce21a669abe9696b8da2
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
3 // found in the LICENSE file.
5 /**
6 * @fileoverview Polymer element for displaying and editing a single
7 * network proxy value. When the URL or port changes, a 'proxy-change' event is
8 * fired with the combined url and port values passed as a single string,
9 * url:port.
11 Polymer({
12 is: 'network-proxy-input',
14 properties: {
15 /**
16 * Whether or not the proxy value can be edited.
18 editable: {
19 type: Boolean,
20 value: false
23 /**
24 * A label for the proxy value.
26 label: {
27 type: String,
28 value: 'Proxy'
31 /**
32 * The proxy object.
33 * @type {?CrOnc.ProxyLocation}
35 value: {
36 type: Object,
37 value: function() { return {Host: '', Port: 80}; },
38 notify: true
42 /**
43 * Event triggered when an input value changes.
44 * @private
46 onValueChange_: function() {
47 var port = parseInt(this.value.Port);
48 if (isNaN(port))
49 port = 80;
50 this.value.Port = port;
51 this.fire('proxy-change', {value: this.value});
53 });