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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/ui/ActionRegistry.js

Issue 2141273002: Reland of DevTools: automatically populate 'More tools' submenu with the drawer views. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 * @constructor 6 * @constructor
7 */ 7 */
8 WebInspector.ActionRegistry = function() 8 WebInspector.ActionRegistry = function()
9 { 9 {
10 /** @type {!Map.<string, !WebInspector.Action>} */ 10 /** @type {!Map.<string, !WebInspector.Action>} */
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 tags: function() 163 tags: function()
164 { 164 {
165 return this._extension.descriptor()["tags"] || ""; 165 return this._extension.descriptor()["tags"] || "";
166 }, 166 },
167 167
168 /** 168 /**
169 * @return {string} 169 * @return {string}
170 */ 170 */
171 title: function() 171 title: function()
172 { 172 {
173 var title = this._extension.title(WebInspector.platform()); 173 var title = this._extension.title();
174 var options = this._extension.descriptor()["options"]; 174 var options = this._extension.descriptor()["options"];
175 if (options) { 175 if (options) {
176 for (var pair of options) { 176 for (var pair of options) {
177 if (pair["value"] !== this._toggled) 177 if (pair["value"] !== this._toggled)
178 title = pair["title"]; 178 title = pair["title"];
179 } 179 }
180 } 180 }
181 return title; 181 return title;
182 }, 182 },
183 183
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 /** 215 /**
216 * @param {!WebInspector.Context} context 216 * @param {!WebInspector.Context} context
217 * @param {string} actionId 217 * @param {string} actionId
218 * @return {boolean} 218 * @return {boolean}
219 */ 219 */
220 handleAction: function(context, actionId) {} 220 handleAction: function(context, actionId) {}
221 } 221 }
222 222
223 /** @type {!WebInspector.ActionRegistry} */ 223 /** @type {!WebInspector.ActionRegistry} */
224 WebInspector.actionRegistry; 224 WebInspector.actionRegistry;
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698