mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Update servo-media. Remove implicit shutdown requests. It all happens automagicly now
This commit is contained in:
parent
3658a8cc59
commit
507a1e4370
4 changed files with 53 additions and 38 deletions
63
Cargo.lock
generated
63
Cargo.lock
generated
|
@ -3598,6 +3598,14 @@ dependencies = [
|
|||
"unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "proc-macro2"
|
||||
version = "1.0.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"unicode-xid 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "procedural-masquerade"
|
||||
version = "0.1.6"
|
||||
|
@ -3662,6 +3670,14 @@ dependencies = [
|
|||
"proc-macro2 0.4.26 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "quote"
|
||||
version = "1.0.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"proc-macro2 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "rand"
|
||||
version = "0.6.5"
|
||||
|
@ -4298,7 +4314,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "servo-media"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
dependencies = [
|
||||
"servo-media-audio 0.1.0 (git+https://github.com/servo/media)",
|
||||
"servo-media-player 0.1.0 (git+https://github.com/servo/media)",
|
||||
|
@ -4310,7 +4326,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "servo-media-audio"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
dependencies = [
|
||||
"boxfnonce 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"byte-slice-cast 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
|
@ -4327,7 +4343,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "servo-media-dummy"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
dependencies = [
|
||||
"boxfnonce 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"ipc-channel 0.11.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
|
@ -4342,7 +4358,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "servo-media-gstreamer"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
dependencies = [
|
||||
"boxfnonce 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"byte-slice-cast 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
|
@ -4377,7 +4393,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "servo-media-gstreamer-render"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
dependencies = [
|
||||
"gstreamer 0.14.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"gstreamer-video 0.14.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
|
@ -4387,7 +4403,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "servo-media-gstreamer-render-unix"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
dependencies = [
|
||||
"glib 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"gstreamer 0.14.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
|
@ -4400,7 +4416,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "servo-media-player"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
dependencies = [
|
||||
"ipc-channel 0.11.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"serde 1.0.88 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
|
@ -4412,7 +4428,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "servo-media-streams"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
dependencies = [
|
||||
"lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"uuid 0.7.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
|
@ -4421,12 +4437,12 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "servo-media-traits"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
|
||||
[[package]]
|
||||
name = "servo-media-webrtc"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
dependencies = [
|
||||
"boxfnonce 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
|
@ -4525,11 +4541,11 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "servo_media_derive"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/servo/media#3e3dc52e9b2e49a8ac14f8bbd873028c8482d463"
|
||||
source = "git+https://github.com/servo/media#ac8336c93270b30e556a92df3002626711ef23ff"
|
||||
dependencies = [
|
||||
"proc-macro2 0.4.26 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"proc-macro2 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"quote 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"syn 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
@ -4913,6 +4929,16 @@ dependencies = [
|
|||
"unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "syn"
|
||||
version = "1.0.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"proc-macro2 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"quote 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"unicode-xid 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "synstructure"
|
||||
version = "0.10.1"
|
||||
|
@ -5369,6 +5395,11 @@ name = "unicode-xid"
|
|||
version = "0.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
|
||||
[[package]]
|
||||
name = "unicode-xid"
|
||||
version = "0.2.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
|
||||
[[package]]
|
||||
name = "unreachable"
|
||||
version = "1.0.0"
|
||||
|
@ -6246,9 +6277,11 @@ dependencies = [
|
|||
"checksum precomputed-hash 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c"
|
||||
"checksum proc-macro-hack 0.5.7 (registry+https://github.com/rust-lang/crates.io-index)" = "0c1dd4172a1e1f96f709341418f49b11ea6c2d95d53dca08c0f74cbd332d9cf3"
|
||||
"checksum proc-macro2 0.4.26 (registry+https://github.com/rust-lang/crates.io-index)" = "38fddd23d98b2144d197c0eca5705632d4fe2667d14a6be5df8934f8d74f1978"
|
||||
"checksum proc-macro2 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "4c5c2380ae88876faae57698be9e9775e3544decad214599c3a6266cca6ac802"
|
||||
"checksum procedural-masquerade 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "9a1574a51c3fd37b26d2c0032b649d08a7d51d4cca9c41bbc5bf7118fa4509d0"
|
||||
"checksum quick-error 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "eda5fe9b71976e62bc81b781206aaa076401769b2143379d3eb2118388babac4"
|
||||
"checksum quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)" = "faf4799c5d274f3868a4aae320a0a182cbd2baee377b378f080e16a23e9d80db"
|
||||
"checksum quote 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)" = "053a8c8bcc71fcce321828dc897a98ab9760bef03a4fc36693c231e5b3216cfe"
|
||||
"checksum rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)" = "6d71dacdc3c88c1fde3885a3be3fbab9f35724e6ce99467f7d9c5026132184ca"
|
||||
"checksum rand_chacha 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "556d3a1ca6600bfcbab7c7c91ccb085ac7fbbcd70e008a98742e7847f4f7bcef"
|
||||
"checksum rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "7a6fdeb83b075e8266dcc8762c22776f6877a63111121f5f8c7411e5be7eed4b"
|
||||
|
@ -6328,6 +6361,7 @@ dependencies = [
|
|||
"checksum sw-composite 0.5.10 (registry+https://github.com/rust-lang/crates.io-index)" = "5eba1755094da86216f071f7a28b0453345c3e6e558ea2fd7821c55eef8fb9b2"
|
||||
"checksum swapper 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e454d048db5527d000bfddb77bd072bbf3a1e2ae785f16d9bd116e07c2ab45eb"
|
||||
"checksum syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)" = "b4d960b829a55e56db167e861ddb43602c003c7be0bee1d345021703fac2fb7c"
|
||||
"checksum syn 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "158521e6f544e7e3dcfc370ac180794aa38cb34a1b1e07609376d4adcf429b93"
|
||||
"checksum synstructure 0.10.1 (registry+https://github.com/rust-lang/crates.io-index)" = "73687139bf99285483c96ac0add482c3776528beac1d97d444f6e91f203a2015"
|
||||
"checksum tempfile 3.0.8 (registry+https://github.com/rust-lang/crates.io-index)" = "7dc4738f2e68ed2855de5ac9cdbe05c9216773ecde4739b2f095002ab03a13ef"
|
||||
"checksum tendril 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "707feda9f2582d5d680d733e38755547a3e8fb471e7ba11452ecfd9ce93a5d3b"
|
||||
|
@ -6374,6 +6408,7 @@ dependencies = [
|
|||
"checksum unicode-segmentation 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a8083c594e02b8ae1654ae26f0ade5158b119bd88ad0e8227a5d8fcd72407946"
|
||||
"checksum unicode-width 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "bf3a113775714a22dcb774d8ea3655c53a32debae63a063acc00a91cc586245f"
|
||||
"checksum unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fc72304796d0818e357ead4e000d19c9c174ab23dc11093ac919054d20a6a7fc"
|
||||
"checksum unicode-xid 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "826e7639553986605ec5979c7dd957c7895e93eabed50ab2ffa7f6128a75097c"
|
||||
"checksum unreachable 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "382810877fe448991dfc7f0dd6e3ae5d58088fd0ea5e35189655f84e6814fa56"
|
||||
"checksum unwind-sys 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "bd1c4a6d1cfe0072924d1b1d4ca6faa211c95056666979d7ef1bab4cd206057f"
|
||||
"checksum url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)" = "dd4e7c0d531266369519a4aa4f399d748bd37043b00bde1e4ff1f60a120b355a"
|
||||
|
|
|
@ -83,7 +83,6 @@ pub struct BaseAudioContext {
|
|||
eventtarget: EventTarget,
|
||||
#[ignore_malloc_size_of = "servo_media"]
|
||||
audio_context_impl: Arc<Mutex<AudioContext>>,
|
||||
browsing_context_id: BrowsingContextId,
|
||||
/// https://webaudio.github.io/web-audio-api/#dom-baseaudiocontext-destination
|
||||
destination: MutNullableDom<AudioDestinationNode>,
|
||||
listener: MutNullableDom<AudioListener>,
|
||||
|
@ -128,7 +127,6 @@ impl BaseAudioContext {
|
|||
audio_context_impl: ServoMedia::get()
|
||||
.unwrap()
|
||||
.create_audio_context(&client_context_id, options.into()),
|
||||
browsing_context_id,
|
||||
destination: Default::default(),
|
||||
listener: Default::default(),
|
||||
in_flight_resume_promises_queue: Default::default(),
|
||||
|
@ -555,18 +553,6 @@ impl BaseAudioContextMethods for BaseAudioContext {
|
|||
}
|
||||
}
|
||||
|
||||
impl Drop for BaseAudioContext {
|
||||
fn drop(&mut self) {
|
||||
let client_context_id = ClientContextId::build(
|
||||
self.browsing_context_id.namespace_id.0,
|
||||
self.browsing_context_id.index.0.get(),
|
||||
);
|
||||
ServoMedia::get()
|
||||
.unwrap()
|
||||
.shutdown_audio_context(&client_context_id, self.audio_context_impl.clone());
|
||||
}
|
||||
}
|
||||
|
||||
impl From<BaseAudioContextOptions> for AudioContextOptions {
|
||||
fn from(options: BaseAudioContextOptions) -> Self {
|
||||
match options {
|
||||
|
|
|
@ -1855,16 +1855,6 @@ impl Drop for HTMLMediaElement {
|
|||
}
|
||||
});
|
||||
|
||||
if let Some(ref player) = *self.player.borrow() {
|
||||
let browsing_context_id = window.window_proxy().top_level_browsing_context_id().0;
|
||||
let client_context_id = ClientContextId::build(
|
||||
browsing_context_id.namespace_id.0,
|
||||
browsing_context_id.index.0.get(),
|
||||
);
|
||||
ServoMedia::get()
|
||||
.unwrap()
|
||||
.shutdown_player(&client_context_id, player.clone());
|
||||
}
|
||||
self.remove_controls();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -46,9 +46,13 @@ packages = [
|
|||
"parking_lot",
|
||||
"parking_lot_core",
|
||||
"percent-encoding", # https://github.com/servo/servo/pull/23838
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"rand_core",
|
||||
"scopeguard",
|
||||
"syn",
|
||||
"unicase",
|
||||
"unicode-xid",
|
||||
"url", # https://github.com/servo/servo/pull/23838
|
||||
"ws",
|
||||
]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue