["When applicable, unstable sorting is preferred because it is generally
faster than stable sorting and it doesn’t allocate auxiliary
memory."](https://doc.rust-lang.org/std/vec/struct.Vec.html#method.sort)
Binary also reduced by 1KB in Release.
Testing: No behaviour change as semantically all current usage does not
have any pair with `std::cmp::Ordering::Equal`.
Signed-off-by: Euclid Ye <euclid.ye@huawei.com>
`webview.focus` return `Result<(),()>`, hence it gives warning if the
result is not handled.
Signed-off-by: PotatoCP <Kenzie.Raditya.Tirtarahardja@huawei.com>
https://github.com/servo/servo/pull/38160 added a webdriver-specific API
to support waiting on focus operations to complete. These changes
replace that with a generalized pattern, where a unique ID is created
for each focus operation and the embedder can receive notifications
about each focus operation when it is complete, regardless of whether
the focus was actually changed.
Testing: Existing test coverage from
https://github.com/servo/servo/pull/38160/ is unchanged.
---------
Signed-off-by: Josh Matthews <josh@joshmatthews.net>
Rather than creating unique types for each pipeline-namespaced index
type (eg. MessagePortId, DomExceptionId, etc.), we can create a generic
common type that uses a marker to prevent type confusion. This change
allows us to reduce the boilerplate code required when implementing
serializable/transferable interfaces, since the structured clone
implementation can rely on the common type.
Testing: Existing WPT tests for serialization and transferring provide
coverage.
---------
Signed-off-by: Josh Matthews <josh@joshmatthews.net>
Create a separate file for `WebviewManager` to improve clarity.
Testing: This change is just a refactor, so no new tests are needed.
Signed-off-by: Shubham Gupta <shubham13297@gmail.com>
2025-04-04 07:34:19 +00:00
Renamed from components/constellation/webview.rs (Browse further)