Constellation

Struct Constellation 

Source
pub struct Constellation<STF, SWF> {
Show 59 fields namespace_receiver: RoutedReceiver<PipelineNamespaceRequest>, namespace_ipc_sender: GenericSender<PipelineNamespaceRequest>, script_sender: GenericSender<(WebViewId, PipelineId, ScriptToConstellationMessage)>, script_receiver: Receiver<Result<(WebViewId, PipelineId, ScriptToConstellationMessage), Error>>, background_monitor_register: Option<Box<dyn BackgroundHangMonitorRegister>>, background_monitor_register_join_handle: Option<JoinHandle<()>>, background_monitor_control_senders: Vec<GenericSender<BackgroundHangMonitorControlMsg>>, background_hang_monitor_sender: GenericSender<HangMonitorAlert>, background_hang_monitor_receiver: RoutedReceiver<HangMonitorAlert>, layout_factory: Arc<dyn LayoutFactory>, embedder_to_constellation_receiver: Receiver<EmbedderToConstellationMessage>, embedder_proxy: EmbedderProxy, compositor_proxy: CompositorProxy, webviews: WebViewManager<ConstellationWebView>, public_resource_threads: ResourceThreads, private_resource_threads: ResourceThreads, public_storage_threads: StorageThreads, private_storage_threads: StorageThreads, system_font_service: Arc<SystemFontServiceProxy>, devtools_sender: Option<Sender<DevtoolsControlMsg>>, bluetooth_ipc_sender: IpcSender<BluetoothRequest>, sw_managers: HashMap<ImmutableOrigin, GenericSender<ServiceWorkerMsg>>, swmanager_ipc_sender: GenericSender<SWManagerMsg>, swmanager_receiver: RoutedReceiver<SWManagerMsg>, time_profiler_chan: ProfilerChan, mem_profiler_chan: ProfilerChan, webrender_wgpu: WebRenderWGPU, message_ports: FxHashMap<MessagePortId, MessagePortInfo>, message_port_routers: FxHashMap<MessagePortRouterId, IpcSender<MessagePortMsg>>, broadcast_channels: BroadcastChannels, pipelines: FxHashMap<PipelineId, Pipeline>, browsing_contexts: FxHashMap<BrowsingContextId, BrowsingContext>, browsing_context_group_set: FxHashMap<BrowsingContextGroupId, BrowsingContextGroup>, browsing_context_group_next_id: u32, pending_changes: Vec<SessionHistoryChange>, next_pipeline_namespace_id: PipelineNamespaceId, webdriver_load_status_sender: Option<(GenericSender<WebDriverLoadStatus>, PipelineId)>, document_states: FxHashMap<PipelineId, DocumentState>, shutting_down: bool, handled_warnings: VecDeque<(Option<String>, String)>, random_pipeline_closure: Option<(SmallRng, f32)>, phantom: PhantomData<(STF, SWF)>, webgl_threads: Option<WebGLThreads>, webxr_registry: Option<Registry>, canvas: OnceCell<(Sender<ConstellationCanvasMsg>, GenericSender<CanvasMsg>)>, pending_approval_navigations: FxHashMap<PipelineId, (LoadData, NavigationHistoryBehavior)>, pressed_mouse_buttons: u16, active_keyboard_modifiers: Modifiers, hard_fail: bool, active_media_session: Option<PipelineId>, broken_image_icon_data: Vec<u8>, user_content_manager: UserContentManager, process_manager: ProcessManager, async_runtime: Box<dyn AsyncRuntime>, script_join_handles: FxHashMap<WebViewId, JoinHandle<()>>, privileged_urls: Vec<ServoUrl>, image_cache_factory: Arc<ImageCacheFactoryImpl>, pending_viewport_changes: HashMap<BrowsingContextId, ViewportDetails>, screenshot_readiness_requests: Vec<ScreenshotReadinessRequest>,
}
Expand description

The Constellation itself. In the servo browser, there is one constellation, which maintains all of the browser global data. In embedded applications, there may be more than one constellation, which are independent of each other.

The constellation may be in a different process from the pipelines, and communicates using IPC.

It is parameterized over a LayoutThreadFactory and a ScriptThreadFactory (which in practice are implemented by LayoutThread in the layout crate, and ScriptThread in the script crate). Script and layout communicate using a Message type.

Fields§

§namespace_receiver: RoutedReceiver<PipelineNamespaceRequest>

An ipc-sender/threaded-receiver pair to facilitate installing pipeline namespaces in threads via a per-process installer.

§namespace_ipc_sender: GenericSender<PipelineNamespaceRequest>§script_sender: GenericSender<(WebViewId, PipelineId, ScriptToConstellationMessage)>

An IPC channel for script threads to send messages to the constellation. This is the script threads’ view of script_receiver.

§script_receiver: Receiver<Result<(WebViewId, PipelineId, ScriptToConstellationMessage), Error>>

A channel for the constellation to receive messages from script threads. This is the constellation’s view of script_sender.

§background_monitor_register: Option<Box<dyn BackgroundHangMonitorRegister>>

A handle to register components for hang monitoring. None when in multiprocess mode.

§background_monitor_register_join_handle: Option<JoinHandle<()>>

In single process mode, a join handle on the BHM worker thread.

§background_monitor_control_senders: Vec<GenericSender<BackgroundHangMonitorControlMsg>>

Channels to control all background-hang monitors. TODO: store them on the relevant BrowsingContextGroup, so that they could be controlled on a “per-tab/event-loop” basis.

§background_hang_monitor_sender: GenericSender<HangMonitorAlert>

A channel for the background hang monitor to send messages to the constellation.

§background_hang_monitor_receiver: RoutedReceiver<HangMonitorAlert>

A channel for the constellation to receiver messages from the background hang monitor.

§layout_factory: Arc<dyn LayoutFactory>

A factory for creating layouts. This allows customizing the kind of layout created for a Constellation and prevents a circular crate dependency between script and layout.

§embedder_to_constellation_receiver: Receiver<EmbedderToConstellationMessage>

A channel for the embedder (renderer and libservo) to send messages to the Constellation.

§embedder_proxy: EmbedderProxy

A channel through which messages can be sent to the embedder.

§compositor_proxy: CompositorProxy

A channel (the implementation of which is port-specific) for the constellation to send messages to the compositor thread.

§webviews: WebViewManager<ConstellationWebView>

Bookkeeping data for all webviews in the constellation.

§public_resource_threads: ResourceThreads

Channels for the constellation to send messages to the public resource-related threads. There are two groups of resource threads: one for public browsing, and one for private browsing.

§private_resource_threads: ResourceThreads

Channels for the constellation to send messages to the private resource-related threads. There are two groups of resource threads: one for public browsing, and one for private browsing.

§public_storage_threads: StorageThreads

Channels for the constellation to send messages to the public storage-related threads. There are two groups of storage threads: one for public browsing, and one for private browsing.

§private_storage_threads: StorageThreads

Channels for the constellation to send messages to the private storage-related threads. There are two groups of storage threads: one for public browsing, and one for private browsing.

§system_font_service: Arc<SystemFontServiceProxy>

A channel for the constellation to send messages to the font cache thread.

§devtools_sender: Option<Sender<DevtoolsControlMsg>>

A channel for the constellation to send messages to the devtools thread.

§bluetooth_ipc_sender: IpcSender<BluetoothRequest>

An IPC channel for the constellation to send messages to the bluetooth thread.

§sw_managers: HashMap<ImmutableOrigin, GenericSender<ServiceWorkerMsg>>

A map of origin to sender to a Service worker manager.

§swmanager_ipc_sender: GenericSender<SWManagerMsg>

An IPC channel for Service Worker Manager threads to send messages to the constellation. This is the SW Manager thread’s view of swmanager_receiver.

§swmanager_receiver: RoutedReceiver<SWManagerMsg>

A channel for the constellation to receive messages from the Service Worker Manager thread. This is the constellation’s view of swmanager_sender.

§time_profiler_chan: ProfilerChan

A channel for the constellation to send messages to the time profiler thread.

§mem_profiler_chan: ProfilerChan

A channel for the constellation to send messages to the memory profiler thread.

§webrender_wgpu: WebRenderWGPU

WebRender related objects required by WebGPU threads

§message_ports: FxHashMap<MessagePortId, MessagePortInfo>

A map of message-port Id to info.

§message_port_routers: FxHashMap<MessagePortRouterId, IpcSender<MessagePortMsg>>

A map of router-id to ipc-sender, to route messages to ports.

§broadcast_channels: BroadcastChannels

Bookkeeping for BroadcastChannel functionnality.

§pipelines: FxHashMap<PipelineId, Pipeline>

The set of all the pipelines in the browser. (See the pipeline module for more details.)

§browsing_contexts: FxHashMap<BrowsingContextId, BrowsingContext>

The set of all the browsing contexts in the browser.

§browsing_context_group_set: FxHashMap<BrowsingContextGroupId, BrowsingContextGroup>

A user agent holds a a set of browsing context groups.

https://html.spec.whatwg.org/multipage/#browsing-context-group-set

§browsing_context_group_next_id: u32

The Id counter for BrowsingContextGroup.

§pending_changes: Vec<SessionHistoryChange>

When a navigation is performed, we do not immediately update the session history, instead we ask the event loop to begin loading the new document, and do not update the browsing context until the document is active. Between starting the load and it activating, we store a SessionHistoryChange object for the navigation in progress.

§next_pipeline_namespace_id: PipelineNamespaceId

Pipeline IDs are namespaced in order to avoid name collisions, and the namespaces are allocated by the constellation.

§webdriver_load_status_sender: Option<(GenericSender<WebDriverLoadStatus>, PipelineId)>

An IpcSender to notify navigation events to webdriver.

§document_states: FxHashMap<PipelineId, DocumentState>

Document states for loaded pipelines (used only when writing screenshots).

§shutting_down: bool

Are we shutting down?

§handled_warnings: VecDeque<(Option<String>, String)>

Have we seen any warnings? Hopefully always empty! The buffer contains (thread_name, reason) entries.

§random_pipeline_closure: Option<(SmallRng, f32)>

The random number generator and probability for closing pipelines. This is for testing the hardening of the constellation.

§phantom: PhantomData<(STF, SWF)>

Phantom data that keeps the Rust type system happy.

§webgl_threads: Option<WebGLThreads>

Entry point to create and get channels to a WebGLThread.

§webxr_registry: Option<Registry>

The XR device registry

§canvas: OnceCell<(Sender<ConstellationCanvasMsg>, GenericSender<CanvasMsg>)>

Lazily initialized channels for canvas paint thread.

§pending_approval_navigations: FxHashMap<PipelineId, (LoadData, NavigationHistoryBehavior)>

Navigation requests from script awaiting approval from the embedder.

§pressed_mouse_buttons: u16

Bitmask which indicates which combination of mouse buttons are currently being pressed.

§active_keyboard_modifiers: Modifiers

The currently activated keyboard modifiers.

§hard_fail: bool

If True, exits on thread failure instead of displaying about:failure

§active_media_session: Option<PipelineId>

Pipeline ID of the active media session.

§broken_image_icon_data: Vec<u8>

The image bytes associated with the BrokenImageIcon embedder resource. Read during startup and provided to image caches that are created on an as-needed basis, rather than retrieving it every time.

§user_content_manager: UserContentManager

User content manager

§process_manager: ProcessManager

The process manager.

§async_runtime: Box<dyn AsyncRuntime>

The async runtime.

§script_join_handles: FxHashMap<WebViewId, JoinHandle<()>>

When in single-process mode, join handles for script-threads.

§privileged_urls: Vec<ServoUrl>

A list of URLs that can access privileged internal APIs.

§image_cache_factory: Arc<ImageCacheFactoryImpl>

The [ImageCacheFactory] to use for all ScriptThreads when we are running in single-process mode. In multi-process mode, each process will create its own ImageCacheFactoryImpl.

§pending_viewport_changes: HashMap<BrowsingContextId, ViewportDetails>

Pending viewport changes for browsing contexts that are not yet known to the constellation.

§screenshot_readiness_requests: Vec<ScreenshotReadinessRequest>

Pending screenshot readiness requests. These are collected until the screenshot is ready to take place, at which point the Constellation informs the renderer that it can start the process of taking the screenshot.

Implementations§

Source§

impl<STF, SWF> Constellation<STF, SWF>

Source

pub fn start( embedder_to_constellation_receiver: Receiver<EmbedderToConstellationMessage>, state: InitialConstellationState, layout_factory: Arc<dyn LayoutFactory>, random_pipeline_closure_probability: Option<f32>, random_pipeline_closure_seed: Option<usize>, hard_fail: bool, )

Create a new constellation thread.

Source

fn run(&mut self)

The main event loop for the constellation.

Source

fn send_message_to_pipeline( &mut self, pipeline_id: PipelineId, message: ScriptThreadMessage, failure_message: &str, ) -> bool

Helper that sends a message to the event loop of a given pipeline, logging the given failure message and returning false on failure.

Source

fn next_pipeline_namespace_id(&mut self) -> PipelineNamespaceId

Generate a new pipeline id namespace.

Source

fn next_browsing_context_group_id(&mut self) -> BrowsingContextGroupId

Source

fn get_event_loop( &mut self, host: &Host, webview_id: &WebViewId, opener: &Option<BrowsingContextId>, ) -> Result<Weak<EventLoop>, &'static str>

Source

fn set_event_loop( &mut self, event_loop: Weak<EventLoop>, host: Host, webview_id: WebViewId, opener: Option<BrowsingContextId>, )

Source

fn new_pipeline( &mut self, pipeline_id: PipelineId, browsing_context_id: BrowsingContextId, webview_id: WebViewId, parent_pipeline_id: Option<PipelineId>, opener: Option<BrowsingContextId>, initial_viewport_details: ViewportDetails, load_data: LoadData, is_private: bool, throttled: bool, )

Helper function for creating a pipeline

Source

fn fully_active_descendant_browsing_contexts_iter( &self, browsing_context_id: BrowsingContextId, ) -> FullyActiveBrowsingContextsIterator<'_>

Get an iterator for the fully active browsing contexts in a subtree.

Source

fn fully_active_browsing_contexts_iter( &self, webview_id: WebViewId, ) -> FullyActiveBrowsingContextsIterator<'_>

Get an iterator for the fully active browsing contexts in a tree.

Source

fn all_descendant_browsing_contexts_iter( &self, browsing_context_id: BrowsingContextId, ) -> AllBrowsingContextsIterator<'_>

Get an iterator for the browsing contexts in a subtree.

Source

fn ancestor_pipelines_of_browsing_context_iter( &self, browsing_context_id: BrowsingContextId, ) -> impl Iterator<Item = &Pipeline> + '_

Enumerate the specified browsing context’s ancestor pipelines up to the top-level pipeline.

Source

fn ancestor_or_self_pipelines_of_browsing_context_iter( &self, browsing_context_id: BrowsingContextId, ) -> impl Iterator<Item = &Pipeline> + '_

Enumerate the specified browsing context’s ancestor-or-self pipelines up to the top-level pipeline.

Source

fn new_browsing_context( &mut self, browsing_context_id: BrowsingContextId, webview_id: WebViewId, pipeline_id: PipelineId, parent_pipeline_id: Option<PipelineId>, viewport_details: ViewportDetails, is_private: bool, inherited_secure_context: Option<bool>, throttled: bool, )

Create a new browsing context and update the internal bookkeeping.

Source

fn add_pending_change(&mut self, change: SessionHistoryChange)

Source

fn handle_request(&mut self)

Handles loading pages, navigation, and granting access to the compositor

Source

fn handle_request_for_pipeline_namespace( &mut self, request: PipelineNamespaceRequest, )

Source

fn handle_request_from_background_hang_monitor(&self, message: HangMonitorAlert)

Source

fn handle_request_from_swmanager(&mut self, message: SWManagerMsg)

Source

fn handle_request_from_compositor( &mut self, message: EmbedderToConstellationMessage, )

Source

fn handle_evaluate_javascript( &mut self, webview_id: WebViewId, evaluation_id: JavaScriptEvaluationId, script: String, )

Source

fn handle_request_from_script( &mut self, message: (WebViewId, PipelineId, ScriptToConstellationMessage), )

Source

fn check_origin_against_pipeline( &self, pipeline_id: &PipelineId, origin: &ImmutableOrigin, ) -> Result<(), ()>

Check the origin of a message against that of the pipeline it came from. Note: this is still limited as a security check, see https://github.com/servo/servo/issues/11722

Source

fn handle_wgpu_request( &mut self, source_pipeline_id: PipelineId, browsing_context_id: BrowsingContextId, request: ScriptToConstellationMessage, )

Source

fn handle_message_port_transfer_completed( &mut self, router_id: Option<MessagePortRouterId>, ports: Vec<MessagePortId>, )

Source

fn handle_message_port_transfer_failed( &mut self, ports: FxHashMap<MessagePortId, PortTransferInfo>, )

Source

fn handle_complete_message_port_transfer( &mut self, router_id: MessagePortRouterId, ports: Vec<MessagePortId>, )

Source

fn handle_reroute_messageport( &mut self, port_id: MessagePortId, task: PortMessageTask, )

Source

fn handle_messageport_shipped(&mut self, port_id: MessagePortId)

Source

fn handle_new_messageport_router( &mut self, router_id: MessagePortRouterId, message_port_ipc_sender: IpcSender<MessagePortMsg>, )

Source

fn handle_remove_messageport_router(&mut self, router_id: MessagePortRouterId)

Source

fn handle_new_messageport( &mut self, router_id: MessagePortRouterId, port_id: MessagePortId, )

Source

fn handle_entangle_messageports( &mut self, port1: MessagePortId, port2: MessagePortId, )

Source

fn handle_disentangle_messageports( &mut self, port1: MessagePortId, port2: Option<MessagePortId>, )

Source

fn handle_schedule_serviceworker_job( &mut self, pipeline_id: PipelineId, job: Job, )

https://w3c.github.io/ServiceWorker/#schedule-job-algorithm and https://w3c.github.io/ServiceWorker/#dfn-job-queue

The Job Queue is essentially the channel to a SW manager, which are scoped per origin.

Source

fn handle_broadcast_storage_event( &self, pipeline_id: PipelineId, storage: StorageType, url: ServoUrl, key: Option<String>, old_value: Option<String>, new_value: Option<String>, )

Source

fn handle_exit(&mut self)

Source

fn handle_shutdown(&mut self)

Source

fn handle_pipeline_exited(&mut self, pipeline_id: PipelineId)

Source

fn handle_send_error(&mut self, pipeline_id: PipelineId, err: IpcError)

Source

fn handle_panic( &mut self, webview_id: Option<WebViewId>, reason: String, backtrace: Option<String>, )

Source

fn handle_focus_web_view(&mut self, webview_id: WebViewId)

Source

fn handle_log_entry( &mut self, webview_id: Option<WebViewId>, thread_name: Option<String>, entry: LogEntry, )

Source

fn update_pressed_mouse_buttons(&mut self, event: &MouseButtonEvent)

Source

fn update_active_keybord_modifiers(&mut self, event: &KeyboardEvent)

Source

fn forward_input_event( &mut self, webview_id: WebViewId, event: InputEventAndId, hit_test_result: Option<CompositorHitTestResult>, )

Source

fn handle_new_top_level_browsing_context( &mut self, url: ServoUrl, webview_id: WebViewId, viewport_details: ViewportDetails, )

Source

fn handle_close_top_level_browsing_context(&mut self, webview_id: WebViewId)

Source

fn handle_iframe_size_msg(&mut self, iframe_sizes: Vec<IFrameSizeMsg>)

Source

fn handle_finish_javascript_evaluation( &mut self, evaluation_id: JavaScriptEvaluationId, result: Result<JSValue, JavaScriptEvaluationError>, )

Source

fn handle_subframe_loaded(&mut self, pipeline_id: PipelineId)

Source

fn handle_script_loaded_url_in_iframe_msg( &mut self, load_info: IFrameLoadInfoWithData, )

Source

fn handle_script_new_iframe(&mut self, load_info: IFrameLoadInfoWithData)

Source

fn handle_script_new_auxiliary( &mut self, load_info: AuxiliaryWebViewCreationRequest, )

Source

fn handle_refresh_cursor(&self, pipeline_id: PipelineId)

Source

fn handle_change_running_animations_state( &mut self, pipeline_id: PipelineId, animation_state: AnimationState, )

Source

fn handle_tick_animation(&mut self, webview_ids: Vec<WebViewId>)

Source

fn handle_no_longer_waiting_on_asynchronous_image_updates( &mut self, pipeline_ids: Vec<PipelineId>, )

Source

fn schedule_navigation( &mut self, webview_id: WebViewId, source_id: PipelineId, load_data: LoadData, history_handling: NavigationHistoryBehavior, )

Schedule a navigation(via load_url). 1: Ask the embedder for permission. 2: Store the details of the navigation, pending approval from the embedder.

Source

fn load_url( &mut self, webview_id: WebViewId, source_id: PipelineId, load_data: LoadData, history_handling: NavigationHistoryBehavior, ) -> Option<PipelineId>

Source

fn handle_abort_load_url_msg(&mut self, new_pipeline_id: PipelineId)

Source

fn handle_load_complete_msg( &mut self, webview_id: WebViewId, pipeline_id: PipelineId, )

Source

fn handle_navigated_to_fragment( &mut self, pipeline_id: PipelineId, new_url: ServoUrl, history_handling: NavigationHistoryBehavior, )

Source

fn handle_traverse_history_msg( &mut self, webview_id: WebViewId, direction: TraversalDirection, )

Source

fn update_browsing_context( &mut self, browsing_context_id: BrowsingContextId, new_reloader: NeedsToReload, )

Source

fn update_pipeline( &mut self, pipeline_id: PipelineId, history_state_id: Option<HistoryStateId>, url: ServoUrl, )

Source

fn handle_joint_session_history_length( &self, webview_id: WebViewId, response_sender: IpcSender<u32>, )

Source

fn handle_push_history_state_msg( &mut self, pipeline_id: PipelineId, history_state_id: HistoryStateId, url: ServoUrl, )

Source

fn handle_replace_history_state_msg( &mut self, pipeline_id: PipelineId, history_state_id: HistoryStateId, url: ServoUrl, )

Source

fn handle_reload_msg(&mut self, webview_id: WebViewId)

Source

fn handle_post_message_msg( &mut self, browsing_context_id: BrowsingContextId, source_pipeline: PipelineId, origin: Option<ImmutableOrigin>, source_origin: ImmutableOrigin, data: StructuredSerializedData, )

Source

fn handle_focus_msg( &mut self, pipeline_id: PipelineId, focused_child_browsing_context_id: Option<BrowsingContextId>, sequence: FocusSequenceNumber, )

Source

fn handle_focus_remote_document_msg( &mut self, focused_browsing_context_id: BrowsingContextId, )

Source

fn focus_browsing_context( &mut self, initiator_pipeline_id: Option<PipelineId>, focused_browsing_context_id: BrowsingContextId, )

Perform the focusing steps for the active document of focused_browsing_context_id.

If initiator_pipeline_id is specified, this method avoids sending a message to initiator_pipeline_id, assuming its local focus state has already been updated. This is necessary for performing the focusing steps for an object that is not the document itself but something that belongs to the document.

Source

fn handle_remove_iframe_msg( &mut self, browsing_context_id: BrowsingContextId, ) -> Vec<PipelineId>

Source

fn handle_set_throttled_complete( &mut self, pipeline_id: PipelineId, throttled: bool, )

Source

fn handle_create_canvas_paint_thread_msg( &mut self, size: UntypedSize2D<u64>, response_sender: IpcSender<Option<(GenericSender<CanvasMsg>, CanvasId)>>, )

Source

fn handle_webdriver_msg(&mut self, msg: WebDriverCommandMsg)

Source

fn set_webview_throttled(&mut self, webview_id: WebViewId, throttled: bool)

Source

fn notify_history_changed(&self, webview_id: WebViewId)

Source

fn change_session_history(&mut self, change: SessionHistoryChange)

Source

fn notify_focus_state(&mut self, pipeline_id: PipelineId)

Update the focus state of the specified pipeline that recently became active (thus doesn’t have a focused container element) and may have out-dated information.

Source

fn focused_browsing_context_is_descendant_of( &self, browsing_context_id: BrowsingContextId, ) -> bool

Source

fn trim_history(&mut self, webview_id: WebViewId)

Source

fn handle_activate_document_msg(&mut self, pipeline_id: PipelineId)

Source

fn handle_change_viewport_details_msg( &mut self, webview_id: WebViewId, new_viewport_details: ViewportDetails, size_type: WindowSizeType, )

Called when the window is resized.

Source

fn handle_exit_fullscreen_msg(&mut self, webview_id: WebViewId)

Called when the window exits from fullscreen mode

Source

fn handle_request_screenshot_readiness(&mut self, webview_id: WebViewId)

Source

fn send_screenshot_readiness_requests_to_pipelines(&mut self)

Source

fn handle_screenshot_readiness_response( &mut self, updated_pipeline_id: PipelineId, response: ScreenshotReadinessResponse, )

Source

fn get_activity(&self, pipeline_id: PipelineId) -> DocumentActivity

Get the current activity of a pipeline.

Source

fn set_activity(&self, pipeline_id: PipelineId, activity: DocumentActivity)

Set the current activity of a pipeline.

Source

fn update_activity(&self, pipeline_id: PipelineId)

Update the current activity of a pipeline.

Source

fn resize_browsing_context( &mut self, new_viewport_details: ViewportDetails, size_type: WindowSizeType, browsing_context_id: BrowsingContextId, )

Handle updating the size of a browsing context. This notifies every pipeline in the context of the new size.

Source

fn handle_theme_change(&mut self, webview_id: WebViewId, theme: Theme)

Handle theme change events from the embedder and forward them to all appropriate ScriptThreads.

Source

fn switch_fullscreen_mode(&mut self, browsing_context_id: BrowsingContextId)

Source

fn close_browsing_context( &mut self, browsing_context_id: BrowsingContextId, exit_mode: ExitPipelineMode, ) -> Option<BrowsingContext>

Source

fn close_browsing_context_children( &mut self, browsing_context_id: BrowsingContextId, dbc: DiscardBrowsingContext, exit_mode: ExitPipelineMode, )

Source

fn refresh_load_data(&self, pipeline_id: PipelineId) -> Option<LoadData>

Returns the LoadData associated with the given pipeline if it exists, containing the most recent URL associated with the given pipeline.

Source

fn handle_discard_document( &mut self, webview_id: WebViewId, pipeline_id: PipelineId, )

Source

fn unload_document(&self, pipeline_id: PipelineId)

Send a message to script requesting the document associated with this pipeline runs the ‘unload’ algorithm.

Source

fn close_pipeline( &mut self, pipeline_id: PipelineId, dbc: DiscardBrowsingContext, exit_mode: ExitPipelineMode, )

Source

fn maybe_close_random_pipeline(&mut self)

Source

fn get_joint_session_history( &mut self, webview_id: WebViewId, ) -> &mut JointSessionHistory

Source

fn browsing_context_to_sendable( &self, browsing_context_id: BrowsingContextId, ) -> Option<SendableFrameTree>

Source

fn update_webview_in_compositor(&mut self, webview_id: WebViewId)

Send the frame tree for the given webview to the compositor.

Source

fn handle_media_session_action_msg(&mut self, action: MediaSessionActionType)

Source

fn handle_set_scroll_states( &self, pipeline_id: PipelineId, scroll_states: FxHashMap<ExternalScrollId, LayoutVector2D>, )

Source

fn handle_paint_metric( &mut self, pipeline_id: PipelineId, event: PaintMetricEvent, )

Source

fn create_canvas_paint_thread( &self, ) -> (Sender<ConstellationCanvasMsg>, GenericSender<CanvasMsg>)

Source

fn handle_embedder_control_response( &self, id: EmbedderControlId, response: EmbedderControlResponse, )

Auto Trait Implementations§

§

impl<STF, SWF> !Freeze for Constellation<STF, SWF>

§

impl<STF, SWF> !RefUnwindSafe for Constellation<STF, SWF>

§

impl<STF, SWF> !Send for Constellation<STF, SWF>

§

impl<STF, SWF> !Sync for Constellation<STF, SWF>

§

impl<STF, SWF> Unpin for Constellation<STF, SWF>
where STF: Unpin, SWF: Unpin,

§

impl<STF, SWF> !UnwindSafe for Constellation<STF, SWF>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> Downcast<T> for T

Source§

fn downcast(&self) -> &T

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> MaybeBoxed<Box<T>> for T

Source§

fn maybe_boxed(self) -> Box<T>

Convert
Source§

impl<T> MaybeBoxed<T> for T

Source§

fn maybe_boxed(self) -> T

Convert
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, S> SimdFrom<T, S> for T
where S: Simd,

Source§

fn simd_from(value: T, _simd: S) -> T

Source§

impl<F, T, S> SimdInto<T, S> for F
where T: SimdFrom<F, S>, S: Simd,

Source§

fn simd_into(self, simd: S) -> T

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> Upcast<T> for T

Source§

fn upcast(&self) -> Option<&T>

Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> ErasedDestructor for T
where T: 'static,

Source§

impl<T> MaybeSendSync for T