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

Side by Side Diff: chrome/browser/resources/settings/search_engines_page/search_engines_page.js

Issue 2180823004: Migrate <cr-dialog> from PaperDialogBehavior to native <dialog>. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments. Created 4 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 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 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 /** 5 /**
6 * @fileoverview 'settings-search-engines-page' is the settings page 6 * @fileoverview 'settings-search-engines-page' is the settings page
7 * containing search engines settings. 7 * containing search engines settings.
8 */ 8 */
9 Polymer({ 9 Polymer({
10 is: 'settings-search-engines-page', 10 is: 'settings-search-engines-page',
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 }, 59 },
60 60
61 /** @private */ 61 /** @private */
62 onAddSearchEngineTap_: function() { 62 onAddSearchEngineTap_: function() {
63 this.showAddSearchEngineDialog_ = true; 63 this.showAddSearchEngineDialog_ = true;
64 this.async(function() { 64 this.async(function() {
65 var dialog = this.$$('settings-search-engine-dialog'); 65 var dialog = this.$$('settings-search-engine-dialog');
66 // Register listener to detect when the dialog is closed. Flip the boolean 66 // Register listener to detect when the dialog is closed. Flip the boolean
67 // once closed to force a restamp next time it is shown such that the 67 // once closed to force a restamp next time it is shown such that the
68 // previous dialog's contents are cleared. 68 // previous dialog's contents are cleared.
69 dialog.addEventListener('iron-overlay-closed', function() { 69 dialog.addEventListener('close', function() {
70 this.showAddSearchEngineDialog_ = false; 70 this.showAddSearchEngineDialog_ = false;
71 }.bind(this)); 71 }.bind(this));
72 }.bind(this)); 72 }.bind(this));
73 }, 73 },
74 74
75 /** @private */ 75 /** @private */
76 computeShowExtensionsList_: function() { 76 computeShowExtensionsList_: function() {
77 return this.extensions.length > 0; 77 return this.extensions.length > 0;
78 }, 78 },
79 }); 79 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698