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

Unified Diff: chrome/browser/resources/extensions/extension_command_list.js

Issue 350943003: Support global keyboard commands on Chrome OS. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Test updates Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/extensions/global_shortcut_listener_chromeos.cc ('k') | chrome/common/extensions/command.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/extensions/extension_command_list.js
diff --git a/chrome/browser/resources/extensions/extension_command_list.js b/chrome/browser/resources/extensions/extension_command_list.js
index 6c912aff0576a866d21ce730dbf80eec06f6fcd2..2c411d3a5fcdc0188ab6a89f6624f8888183211f 100644
--- a/chrome/browser/resources/extensions/extension_command_list.js
+++ b/chrome/browser/resources/extensions/extension_command_list.js
@@ -264,30 +264,27 @@ cr.define('options', function() {
commandClear.title = loadTimeData.getString('extensionCommandsDelete');
commandClear.addEventListener('click', this.handleClear_.bind(this));
- if (command.scope_ui_visible) {
- var select = node.querySelector('.command-scope');
- select.id = this.createElementId_(
- 'setCommandScope', command.extension_id, command.command_name);
- select.hidden = false;
- // Add the 'In Chrome' option.
- var option = document.createElement('option');
- option.textContent = loadTimeData.getString('extensionCommandsRegular');
+ var select = node.querySelector('.command-scope');
+ select.id = this.createElementId_(
+ 'setCommandScope', command.extension_id, command.command_name);
+ select.hidden = false;
+ // Add the 'In Chrome' option.
+ var option = document.createElement('option');
+ option.textContent = loadTimeData.getString('extensionCommandsRegular');
+ select.appendChild(option);
+ if (command.extension_action) {
+ // Extension actions cannot be global, so we might as well disable the
+ // combo box, to signify that.
+ select.disabled = true;
+ } else {
+ // Add the 'Global' option.
+ option = document.createElement('option');
+ option.textContent = loadTimeData.getString('extensionCommandsGlobal');
select.appendChild(option);
- if (command.extension_action) {
- // Extension actions cannot be global, so we might as well disable the
- // combo box, to signify that.
- select.disabled = true;
- } else {
- // Add the 'Global' option.
- option = document.createElement('option');
- option.textContent =
- loadTimeData.getString('extensionCommandsGlobal');
- select.appendChild(option);
- select.selectedIndex = command.global ? 1 : 0;
-
- select.addEventListener(
- 'change', this.handleSetCommandScope_.bind(this));
- }
+ select.selectedIndex = command.global ? 1 : 0;
+
+ select.addEventListener(
+ 'change', this.handleSetCommandScope_.bind(this));
}
this.appendChild(node);
« no previous file with comments | « chrome/browser/extensions/global_shortcut_listener_chromeos.cc ('k') | chrome/common/extensions/command.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698