mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Rename Promise::new to Promise::new_in_current_compartment
This commit is contained in:
parent
6fa1853bb1
commit
782b58587a
25 changed files with 93 additions and 51 deletions
|
@ -277,8 +277,9 @@ impl BluetoothDeviceMethods for BluetoothDevice {
|
|||
}
|
||||
|
||||
// https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothdevice-watchadvertisements
|
||||
#[allow(unsafe_code)]
|
||||
fn WatchAdvertisements(&self) -> Rc<Promise> {
|
||||
let p = Promise::new(&self.global());
|
||||
let p = unsafe { Promise::new_in_current_compartment(&self.global()) };
|
||||
let sender = response_async(&p, self);
|
||||
// TODO: Step 1.
|
||||
// Note: Steps 2 - 3 are implemented in components/bluetooth/lib.rs in watch_advertisements function
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue