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

Side by Side Diff: chrome/browser/resources/settings/controls/settings_dropdown_menu.html

Issue 2446003002: settings-dropdown-menu must set <select>#value after its options change (Closed)
Patch Set: Hide custom option via CSS Created 4 years, 1 month 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
« no previous file with comments | « no previous file | chrome/browser/resources/settings/controls/settings_dropdown_menu.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <link rel="import" href="chrome://resources/html/polymer.html"> 1 <link rel="import" href="chrome://resources/html/polymer.html">
2 <link rel="import" href="/controls/pref_control_behavior.html"> 2 <link rel="import" href="/controls/pref_control_behavior.html">
3 <link rel="import" href="/i18n_setup.html"> 3 <link rel="import" href="/i18n_setup.html">
4 <link rel="import" href="/md_select_css.html"> 4 <link rel="import" href="/md_select_css.html">
5 <link rel="import" href="/prefs/pref_util.html"> 5 <link rel="import" href="/prefs/pref_util.html">
6 <link rel="import" href="/settings_shared_css.html"> 6 <link rel="import" href="/settings_shared_css.html">
7 7
8 <dom-module id="settings-dropdown-menu"> 8 <dom-module id="settings-dropdown-menu">
9 <template> 9 <template>
10 <style include="settings-shared md-select"></style> 10 <style include="settings-shared md-select">
11 /* Hide "Custom" value when unselectable. */
12 option:disabled {
13 display: none;
14 }
15 </style>
11 <div class="md-select-wrapper"> 16 <div class="md-select-wrapper">
12 <select class="md-select" id="dropdownMenu" on-change="onChange_" 17 <select class="md-select" id="dropdownMenu" on-change="onChange_"
13 value="[[selected_]]"
14 disabled="[[shouldDisableMenu_(disabled, menuOptions)]]"> 18 disabled="[[shouldDisableMenu_(disabled, menuOptions)]]">
15 <template is="dom-repeat" items="[[menuOptions]]"> 19 <template is="dom-repeat" items="[[menuOptions]]">
16 <option value="[[item.value]]">[[item.name]]</option> 20 <option value="[[item.value]]">[[item.name]]</option>
17 </template> 21 </template>
18 <option value="[[notFoundValue_]]" 22 <option value="[[notFoundValue_]]"
19 hidden$="[[!isSelectedNotFound_(selected_)]]"> 23 disabled="[[!showNotFoundValue_(menuOptions, pref.value)]]">
20 $i18n{custom} 24 $i18n{custom}
21 </option> 25 </option>
22 </select> 26 </select>
23 <span class="md-select-underline"></span> 27 <span class="md-select-underline"></span>
24 </div> 28 </div>
25 </template> 29 </template>
26 <script src="settings_dropdown_menu.js"></script> 30 <script src="settings_dropdown_menu.js"></script>
27 </dom-module> 31 </dom-module>
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/resources/settings/controls/settings_dropdown_menu.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698