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

Unified Diff: chrome/browser/resources/settings/bluetooth_page/bluetooth_add_device_dialog.js

Issue 1954383002: MD Settings: combine bluetooth adding and pairing dialogs into one (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: whoops, html deps Created 4 years, 7 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
Index: chrome/browser/resources/settings/bluetooth_page/bluetooth_add_device_dialog.js
diff --git a/chrome/browser/resources/settings/bluetooth_page/bluetooth_add_device_dialog.js b/chrome/browser/resources/settings/bluetooth_page/bluetooth_add_device_dialog.js
deleted file mode 100644
index eaff3ae4b33017ae428601fb2eb7e6ef5b2bd3bf..0000000000000000000000000000000000000000
--- a/chrome/browser/resources/settings/bluetooth_page/bluetooth_add_device_dialog.js
+++ /dev/null
@@ -1,68 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-/**
- * @fileoverview
- * 'settings-bluetooth-add-device-dialog' is the settings subpage for adding
- * bluetooth devices.
- */
-Polymer({
- is: 'settings-bluetooth-add-device-dialog',
-
- properties: {
- /**
- * The cached bluetooth adapter state.
- * @type {!chrome.bluetooth.AdapterState|undefined}
- */
- adapterState: {
- type: Object,
- observer: 'adapterStateChanged_',
- },
-
- /**
- * The ordered list of bluetooth devices.
- * @type {!Array<!chrome.bluetooth.Device>}
- */
- deviceList: {
- type: Array,
- value: function() { return []; },
- },
- },
-
- /** @private */
- adapterStateChanged_: function() {
- if (!this.adapterState.powered)
- this.fire('close-dialog');
- },
-
- /**
- * @param {!chrome.bluetooth.Device} device
- * @return {boolean}
- * @private
- */
- deviceNotPaired_: function(device) {
- return !device.paired;
- },
-
- /**
- * @param {!Array<!chrome.bluetooth.Device>} deviceList
- * @return {boolean} True if deviceList contains any unpaired devices.
- * @private
- */
- haveDevices_: function(deviceList) {
- return this.deviceList.findIndex(function(d) { return !d.paired; }) != -1;
- },
-
- /**
- * @param {!{detail: {action: string, device: !chrome.bluetooth.Device}}} e
- * @private
- */
- onDeviceEvent_: function(e) {
- this.fire('device-event', e.detail);
- /** @type {Event} */(e).stopPropagation();
- },
-
- /** @private */
- onCancelTap_: function() { this.fire('close-dialog'); },
-});

Powered by Google App Engine
This is Rietveld 408576698