diff options
author | Anthony Ramine <n.oxyde@gmail.com> | 2016-09-27 13:16:41 +0200 |
---|---|---|
committer | Anthony Ramine <n.oxyde@gmail.com> | 2016-10-06 20:59:09 +0200 |
commit | fcb59d305742a18daa083352a9b6e9a45896c9f6 (patch) | |
tree | d1023c24bfb5827c49d4d4653a72541b66532b95 /components/script/dom/bluetoothremotegattcharacteristic.rs | |
parent | 093b189b4800909b17295b88aed762601f4b8482 (diff) | |
download | servo-fcb59d305742a18daa083352a9b6e9a45896c9f6.tar.gz servo-fcb59d305742a18daa083352a9b6e9a45896c9f6.zip |
Make reflect_dom_object take a &GlobalScope
Diffstat (limited to 'components/script/dom/bluetoothremotegattcharacteristic.rs')
-rw-r--r-- | components/script/dom/bluetoothremotegattcharacteristic.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/components/script/dom/bluetoothremotegattcharacteristic.rs b/components/script/dom/bluetoothremotegattcharacteristic.rs index 6b7ba1dcfad..701a6ddd2a2 100644 --- a/components/script/dom/bluetoothremotegattcharacteristic.rs +++ b/components/script/dom/bluetoothremotegattcharacteristic.rs @@ -14,7 +14,6 @@ use dom::bindings::codegen::Bindings::BluetoothRemoteGATTServerBinding::Bluetoot use dom::bindings::codegen::Bindings::BluetoothRemoteGATTServiceBinding::BluetoothRemoteGATTServiceMethods; use dom::bindings::error::{ErrorResult, Fallible}; use dom::bindings::error::Error::{self, InvalidModification, Network, NotSupported, Security}; -use dom::bindings::global::GlobalRef; use dom::bindings::js::{JS, MutHeap, Root}; use dom::bindings::reflector::{Reflectable, Reflector, reflect_dom_object}; use dom::bindings::str::{ByteString, DOMString}; @@ -23,6 +22,7 @@ use dom::bluetoothcharacteristicproperties::BluetoothCharacteristicProperties; use dom::bluetoothremotegattdescriptor::BluetoothRemoteGATTDescriptor; use dom::bluetoothremotegattservice::BluetoothRemoteGATTService; use dom::bluetoothuuid::{BluetoothDescriptorUUID, BluetoothUUID}; +use dom::globalscope::GlobalScope; use dom::promise::Promise; use ipc_channel::ipc::{self, IpcSender}; use net_traits::bluetooth_thread::BluetoothMethodMsg; @@ -59,7 +59,7 @@ impl BluetoothRemoteGATTCharacteristic { } } - pub fn new(global: GlobalRef, + pub fn new(global: &GlobalScope, service: &BluetoothRemoteGATTService, uuid: DOMString, properties: &BluetoothCharacteristicProperties, @@ -95,7 +95,7 @@ impl BluetoothRemoteGATTCharacteristic { let descriptor = receiver.recv().unwrap(); match descriptor { Ok(descriptor) => { - Ok(BluetoothRemoteGATTDescriptor::new(self.global().r(), + Ok(BluetoothRemoteGATTDescriptor::new(self.global().r().as_global_scope(), self, DOMString::from(descriptor.uuid), descriptor.instance_id)) @@ -126,7 +126,7 @@ impl BluetoothRemoteGATTCharacteristic { match descriptors_vec { Ok(descriptor_vec) => { Ok(descriptor_vec.into_iter() - .map(|desc| BluetoothRemoteGATTDescriptor::new(self.global().r(), + .map(|desc| BluetoothRemoteGATTDescriptor::new(self.global().r().as_global_scope(), self, DOMString::from(desc.uuid), desc.instance_id)) |