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

Unified Diff: chrome/browser/resources/settings/on_startup_page/startup_url_entry.js

Issue 1882483002: MD Settings: OnStartup, implementing "Edit" functionality. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@edit_on_startup_move_delete
Patch Set: Nit. Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/settings/on_startup_page/startup_url_entry.js
diff --git a/chrome/browser/resources/settings/on_startup_page/startup_url_entry.js b/chrome/browser/resources/settings/on_startup_page/startup_url_entry.js
index c3fbeb98da634ce994cc3de387286fecf20aff3d..89750cb691f8c46c0019f5f47d1d9a0854f0cea8 100644
--- a/chrome/browser/resources/settings/on_startup_page/startup_url_entry.js
+++ b/chrome/browser/resources/settings/on_startup_page/startup_url_entry.js
@@ -7,6 +7,16 @@
* displayes a URL that is loaded during startup. It includes a menu that allows
* the user to edit/remove the entry.
*/
+
+cr.exportPath('settings');
+
+/**
+ * The name of the event fired from this element when the "Edit" option is
+ * tapped.
+ * @const {string}
+ */
+settings.EDIT_STARTUP_URL_EVENT = 'edit-startup-url';
+
Polymer({
is: 'settings-startup-url-entry',
@@ -26,7 +36,14 @@ Polymer({
/** @private */
onRemoveTap_: function() {
+ this.$$('iron-dropdown').close();
settings.StartupUrlsPageBrowserProxyImpl.getInstance().removeStartupPage(
this.model.modelIndex);
},
+
+ /** @private */
+ onEditTap_: function() {
+ this.$$('iron-dropdown').close();
+ this.fire(settings.EDIT_STARTUP_URL_EVENT, this.model);
+ },
});

Powered by Google App Engine
This is Rietveld 408576698