| Index: chrome/browser/resources/options/search_engine_manager_engine_list.js
|
| diff --git a/chrome/browser/resources/options/search_engine_manager_engine_list.js b/chrome/browser/resources/options/search_engine_manager_engine_list.js
|
| index 89695874b853624e4749140063058f065e42d069..bbea9b0d19910cad510b3e86e400a1f4d84a9974 100644
|
| --- a/chrome/browser/resources/options/search_engine_manager_engine_list.js
|
| +++ b/chrome/browser/resources/options/search_engine_manager_engine_list.js
|
| @@ -116,26 +116,31 @@ cr.define('options.search_engines', function() {
|
|
|
| // And the URL column.
|
| var urlEl = this.createEditableTextCell(engine.url);
|
| - var urlWithButtonEl = this.ownerDocument.createElement('div');
|
| - urlWithButtonEl.appendChild(urlEl);
|
| - urlWithButtonEl.className = 'url-column';
|
| - urlWithButtonEl.classList.add('weakrtl');
|
| - this.contentElement.appendChild(urlWithButtonEl);
|
| - // Add the Make Default button. Temporary until drag-and-drop re-ordering
|
| - // is implemented. When this is removed, remove the extra div above.
|
| - if (engine.canBeDefault) {
|
| - var makeDefaultButtonEl = this.ownerDocument.createElement('button');
|
| - makeDefaultButtonEl.className = 'custom-appearance list-inline-button';
|
| - makeDefaultButtonEl.textContent =
|
| - loadTimeData.getString('makeDefaultSearchEngineButton');
|
| - makeDefaultButtonEl.onclick = function(e) {
|
| - chrome.send('managerSetDefaultSearchEngine', [engine.modelIndex]);
|
| - };
|
| - // Don't select the row when clicking the button.
|
| - makeDefaultButtonEl.onmousedown = function(e) {
|
| - e.stopPropagation();
|
| - };
|
| - urlWithButtonEl.appendChild(makeDefaultButtonEl);
|
| + // Extensions should not display a URL column.
|
| + if (!engine.isExtension) {
|
| + var urlWithButtonEl = this.ownerDocument.createElement('div');
|
| + urlWithButtonEl.appendChild(urlEl);
|
| + urlWithButtonEl.className = 'url-column';
|
| + urlWithButtonEl.classList.add('weakrtl');
|
| + this.contentElement.appendChild(urlWithButtonEl);
|
| + // Add the Make Default button. Temporary until drag-and-drop
|
| + // re-ordering is implemented. When this is removed, remove the extra
|
| + // div above.
|
| + if (engine.canBeDefault) {
|
| + var makeDefaultButtonEl = this.ownerDocument.createElement('button');
|
| + makeDefaultButtonEl.className =
|
| + 'custom-appearance list-inline-button';
|
| + makeDefaultButtonEl.textContent =
|
| + loadTimeData.getString('makeDefaultSearchEngineButton');
|
| + makeDefaultButtonEl.onclick = function(e) {
|
| + chrome.send('managerSetDefaultSearchEngine', [engine.modelIndex]);
|
| + };
|
| + // Don't select the row when clicking the button.
|
| + makeDefaultButtonEl.onmousedown = function(e) {
|
| + e.stopPropagation();
|
| + };
|
| + urlWithButtonEl.appendChild(makeDefaultButtonEl);
|
| + }
|
| }
|
|
|
| // Do final adjustment to the input fields.
|
| @@ -148,6 +153,9 @@ cr.define('options.search_engines', function() {
|
| if (engine.urlLocked)
|
| this.urlField_.disabled = true;
|
|
|
| + if (engine.isExtension)
|
| + this.nameField_.disabled = true;
|
| +
|
| if (this.isPlaceholder) {
|
| this.nameField_.placeholder =
|
| loadTimeData.getString('searchEngineTableNamePlaceholder');
|
|
|