Chromium Code Reviews| Index: chrome/browser/resources/chromeos/emulator/bluetooth_settings.html |
| diff --git a/chrome/browser/resources/chromeos/emulator/bluetooth_settings.html b/chrome/browser/resources/chromeos/emulator/bluetooth_settings.html |
| index d21f2d9d786a506b19eb24e09deaf9fc2d15360f..1660e3538bb12cfd44344c21f263ccadde7b5171 100644 |
| --- a/chrome/browser/resources/chromeos/emulator/bluetooth_settings.html |
| +++ b/chrome/browser/resources/chromeos/emulator/bluetooth_settings.html |
| @@ -11,82 +11,77 @@ |
| <div class="element-label">{{title}}</div> |
| <form id="bluetooth-settings-form"> |
| <div class="layout vertical"> |
| - <p> |
| - <label> |
| - <span class="form-label">Toggle bluetooth</span> |
| - <paper-toggle-button |
| - checked="{{powerToMainAdapter}}"></paper-toggle-button> |
| - </label> |
| - </p> |
| - </div> |
| - <div class="layout vertical"> |
| - <p> |
| - <label> |
| - <span class="form-label">Devices</span> |
| - <template is="dom-repeat" items="{{devices}}"> |
| - <div class="device-container"> |
| - <div class="bluetooth-device"> |
| - <div class="element-label">[[item.name]]</div> |
| - <paper-input value="{{item.name}}" |
| - label="Name"></paper-input> |
| - <paper-input value="{{item.path}}" |
| - label="Path"></paper-input> |
| - <paper-input value="{{item.address}}" |
| - label="Address"></paper-input> |
| - <paper-input value="{{item.alias}}" |
| - label="Alias"></paper-input> |
| - <span class="toggle-button-label">Trusted</span> |
| - <paper-toggle-button |
| - checked="{{item.isTrusted}}"></paper-toggle-button> |
| - <span class="toggle-button-label">Pairable</span> |
| - <paper-toggle-button |
| - checked="{{item.isPairable}}"></paper-toggle-button> |
| - <div class="device-field"> |
| - <p> |
| - <label> |
| - <span class="form-label">Class/Type</span> |
| - <paper-radio-group selected="{{item.class}}"> |
| - <template is="dom-repeat" |
| - items="{{deviceClassOptions}}" as="option" |
| - index-as="option_index"> |
| - <paper-radio-button name="{{option.text}}" |
| - >{{option.text}}</paper-radio-button> |
| - </template> |
| - </paper-radio-group> |
| - </label> |
| - </p> |
| - </div> |
| + <label> |
|
xiyuan
2015/07/30 17:21:21
Why have this big <label>?
rfrappier
2015/07/30 22:21:38
It was mainly because all this markup is under the
|
| + <span class="form-label">Devices</span> |
| + <template is="dom-repeat" items="{{devices}}"> |
| + <div class="device-container"> |
| + <div class="bluetooth-device"> |
| + <div class="element-label">[[item.alias]]</div> |
| + <paper-input value="{{item.alias}}" |
| + label="Alias"></paper-input> |
| + <paper-input value="{{item.path}}" |
| + label="Path"></paper-input> |
| + <paper-input value="{{item.address}}" |
| + label="Address"></paper-input> |
| + <paper-input value="{{item.name}}" |
| + label="name"></paper-input> |
| + <span class="toggle-button-label">Trusted</span> |
| + <paper-toggle-button |
| + checked="{{item.isTrusted}}"></paper-toggle-button> |
| + <div class="device-field"> |
|
xiyuan
2015/07/30 17:21:21
Where is "device-field" defined?
|
| + <p> |
|
xiyuan
2015/07/30 17:21:21
<p> seems redundant and could be removed. Why do w
rfrappier
2015/07/30 22:21:38
The <p> tags were just there to add a bit of verti
|
| + <label> |
| + <span class="form-label">Class/Type</span> |
| + <paper-radio-group selected="{{item.class}}"> |
| + <template is="dom-repeat" |
| + items="{{deviceClassOptions}}" as="option" |
| + index-as="option_index"> |
| + <paper-radio-button name="{{option.text}}" |
| + >{{option.text}}</paper-radio-button> |
| + </template> |
| + </paper-radio-group> |
| + </label> |
| + </p> |
| + </div> |
| + <div class="device-field"> |
| + <p> |
|
xiyuan
2015/07/30 17:21:21
same here.
rfrappier
2015/07/30 22:21:38
Acknowledged.
|
| + <label> |
| + <span class="form-label">Pair Authentication Type</span> |
| + <paper-radio-group selected="{{item.pairingMethod}}"> |
| + <template is="dom-repeat" |
| + items="{{deviceAuthenticationMethods}}" as="method" |
|
xiyuan
2015/07/30 17:21:21
nit: more than 80 chars, wrap it.
rfrappier
2015/07/30 22:21:38
Acknowledged.
|
| + index-as="method_index"> |
| + <paper-radio-button name="{{method}}" |
| + >{{method}}</paper-radio-button> |
| + </template> |
| + </paper-radio-group> |
| + </label> |
| + </p> |
| + </div> |
| + <template is="dom-if" |
| + if="{{ showAuthToken(item.pairingMethod) }}"> |
| <div class="device-field"> |
| <p> |
| - <label> |
| - <span class="form-label">Pair Authentication Type</span> |
| - <paper-radio-group selected="{{item.pairMethod}}"> |
| - <template is="dom-repeat" |
| - items="{{deviceAuthenticationMethods}}" as="method" |
| - index-as="method_index"> |
| - <paper-radio-button name="{{method}}" |
| - >{{method}}</paper-radio-button> |
| - </template> |
| - </paper-radio-group> |
| - </label> |
| + <paper-input value="{{item.pairingAuthToken}}" |
| + label="Code"></paper-input> |
| </p> |
| </div> |
| - <paper-button raised class="colored" on-click="pairDevice" |
| - data-index="[[index]]"> |
| - Pair |
| - </paper-button> |
| - <paper-button raised class="colored" |
| - on-click="discoverDevice" data-index="[[index]]"> |
| - Make Discoverable |
| - </paper-button> |
| - </div> |
| + </template> |
| + <paper-button raised class="colored" on-click="pairDevice" |
| + data-index="[[index]]"> |
| + Pair |
| + </paper-button> |
| + <paper-button raised class="colored" |
| + on-click="discoverDevice" data-index="[[index]]"> |
| + Make Discoverable |
| + </paper-button> |
| </div> |
| - </template> |
| - <paper-button on-click="appendNewDevice"> |
| - [+] New Device |
| - </paper-button> |
| - </label> |
| - </p> |
| + </div> |
| + </template> |
| + <paper-button on-click="appendNewDevice"> |
| + [+] New Device |
| + </paper-button> |
| + </label> |
| </div> |
| </form> |
| </div> |