Expand description
Types used by the embedding layer and/or exposed to the API. This crate is responsible for
defining types that cross the process boundary from the embedding/rendering layer all the way
to script, thus it should have very minimal dependencies on other parts of Servo. If a type
is not exposed in the API or doesn’t involve messages sent to the embedding/libservo layer, it
is probably a better fit for the constellation_traits crate.
Re-exports§
pub use crate::input_events::*;pub use crate::webdriver::*;
Modules§
Structs§
- Authentication
Response - Compositor
HitTest Result - The result of a hit test in the compositor.
- Dual
Rumble Effect Params - https://w3.org/TR/gamepad/#dom-gamepadhapticeffecttype-dual-rumble
- Embedder
Control Id - Embedder
Proxy - Sends messages to the embedder.
- File
Picker Request - Filter
Pattern - Filter for file selection;
the
Stringcontent is expected to be extension (e.g, “doc”, without the prefixing “.”) - Focus
Sequence Number - A sequence number generated by a script thread for its pipelines. The
constellation attaches the target pipeline’s last seen
FocusSequenceNumberto every focus-related message it sends. - Image
- A raster image buffer.
- Input
Method Request - Request to present an IME to the user when an editable element is focused. If
typeisInputMethodType::Text, then thetextparameter specifies the pre-existing text content andinsertion_pointthe zero-based index into the string of the insertion point. - Java
Script Error Info - Java
Script Evaluation Id - An identifier for a particular JavaScript evaluation that is used to track the evaluation from the embedding layer to the script layer and then back.
- Media
Metadata - https://w3c.github.io/mediasession/#mediametadata
- Media
Position State - https://w3c.github.io/mediasession/#dictdef-mediapositionstate
- Notification
- Data that could be used to display a desktop notification to the end user when the Notification API is called.
- Notification
Action - Actions available for users to choose from for interacting with the notification.
- RgbColor
- Screen
Geometry - Information about a
WebView’s screen geometry and offset. This is used for the Screen CSSOM APIs andwindow.screenLeft/window.screenX/window.screenTop/window.screenY/window.moveBy/window.resizeBy/window.outerWidth/window.outerHeight/window.screen.availHeight/window.screen.availWidth. - Screen
Metrics - Unlike
ScreenGeometry, the data is in device-independent pixels to be used by DOM APIs - Script
ToEmbedder Chan - A Script to Embedder Channel
- Select
Element Option - Selected
File - Response to file selection request
- Traversal
Id - An opaque identifier for a single history traversal operation.
- Untrusted
Node Address - The address of a node. Layout sends these back. They must be validated via
from_untrusted_node_addressbefore they can be used, because we do not trust layout. - Viewport
Details - Data about a
WebViewor<iframe>viewport: its size and also the HiDPI scale factor to use when rendering the contents. - WebResource
Request - WebResource
Response
Enums§
- Alert
Response - Allow
OrDeny - A response to a request to allow or deny an action.
- Animation
State - For a given pipeline, whether any animations are currently running and any animation callbacks are queued
- Confirm
Response - Context
Menu Result - Cursor
- A cursor for the window. This is different from a CSS cursor (see
CursorKind) in that it has noAutovalue. - Embedder
Control Request - Embedder
Control Response - Embedder
Msg - Gamepad
Haptic Effect Type - https://w3.org/TR/gamepad/#dom-gamepadhapticeffecttype
- Input
Method Type - Used to specify the kind of input method editor appropriate to edit a field. This is a subset of htmlinputelement::InputType because some variants of InputType don’t make sense in this context.
- JSValue
- Java
Script Evaluation Error - An error that happens when trying to evaluate JavaScript on a
WebView. - Java
Script Evaluation Result Serialization Error - Indicates the reason that JavaScript evaluation failed due serializing issues the result of the evaluation.
- Load
Status - The status of the load in this
WebView. - Media
Session Action Type - https://w3c.github.io/mediasession/#enumdef-mediasessionaction
- Media
Session Event - Type of events sent from script to the embedder about the media session.
- Media
Session Playback State - https://w3c.github.io/mediasession/#enumdef-mediasessionplaybackstate
- Permission
Feature - Enum with variants that match the DOM PermissionName enum
- Pixel
Format - Prompt
Response - Screenshot
Capture Error - Scroll
- Select
Element Option OrOptgroup - Represents the contents of either an
<option>or an<optgroup>element - Shutdown
State - Tracks whether Servo isn’t shutting down, is in the process of shutting down, or has finished shutting down.
- Simple
Dialog - Simple dialogs are synchronous dialogs that can be opened by web content. Since their messages are controlled by web content, they should be presented to the user in a way that makes them impossible to mistake for browser UI.
- Theme
- The type of platform theme.
- WebResource
Response Msg - WebView
Point - A point in a
WebView, either expressed in device pixels or page pixels. Page pixels are CSS pixels, which take into account device pixel scale, page zoom, and pinch zoom. - WebView
Rect - A rectangle in a
WebView, either expressed in device pixels or page pixels. Page pixels are CSS pixels, which take into account device pixel scale, page zoom, and pinch zoom. - WebView
Vector
Traits§
- Event
Loop Waker - Refresh
Driver - A
RefreshDriveris a trait that can be implemented by Servo embedders in order to drive let Servo know when to start preparing the next frame. For example, on systems that support Vsync notifications, an embedder may want to implement this trait to drive Servo animations via those notifications.