| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 567 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 578 this.input.setAttribute('placeholder', placeholder); | 578 this.input.setAttribute('placeholder', placeholder); |
| 579 | 579 |
| 580 if (isSearchField) | 580 if (isSearchField) |
| 581 this._setupSearchControls(); | 581 this._setupSearchControls(); |
| 582 | 582 |
| 583 this._updateEmptyStyles(); | 583 this._updateEmptyStyles(); |
| 584 } | 584 } |
| 585 | 585 |
| 586 _setupSearchControls() { | 586 _setupSearchControls() { |
| 587 var clearButton = this.element.createChild('div', 'toolbar-input-clear-butto
n'); | 587 var clearButton = this.element.createChild('div', 'toolbar-input-clear-butto
n'); |
| 588 clearButton.appendChild(UI.Icon.create('smallicon-gray-cross-hover', 'search
-cancel-button')); | 588 clearButton.appendChild(UI.Icon.create('mediumicon-gray-cross-hover', 'searc
h-cancel-button')); |
| 589 clearButton.addEventListener('click', () => this._internalSetValue('', true)
); | 589 clearButton.addEventListener('click', () => this._internalSetValue('', true)
); |
| 590 this.input.addEventListener('keydown', event => this._onKeydownCallback(even
t)); | 590 this.input.addEventListener('keydown', event => this._onKeydownCallback(even
t)); |
| 591 } | 591 } |
| 592 | 592 |
| 593 /** | 593 /** |
| 594 * @param {string} value | 594 * @param {string} value |
| 595 */ | 595 */ |
| 596 setValue(value) { | 596 setValue(value) { |
| 597 this._internalSetValue(value, false); | 597 this._internalSetValue(value, false); |
| 598 } | 598 } |
| (...skipping 455 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1054 /** | 1054 /** |
| 1055 * @param {!Common.Setting} setting | 1055 * @param {!Common.Setting} setting |
| 1056 * @param {string=} tooltip | 1056 * @param {string=} tooltip |
| 1057 * @param {string=} alternateTitle | 1057 * @param {string=} alternateTitle |
| 1058 */ | 1058 */ |
| 1059 constructor(setting, tooltip, alternateTitle) { | 1059 constructor(setting, tooltip, alternateTitle) { |
| 1060 super(alternateTitle || setting.title() || '', tooltip); | 1060 super(alternateTitle || setting.title() || '', tooltip); |
| 1061 UI.SettingsUI.bindCheckbox(this.inputElement, setting); | 1061 UI.SettingsUI.bindCheckbox(this.inputElement, setting); |
| 1062 } | 1062 } |
| 1063 }; | 1063 }; |
| OLD | NEW |