diff options
author | Alan Jeffrey <ajeffrey@mozilla.com> | 2016-05-25 22:10:44 -0500 |
---|---|---|
committer | Alan Jeffrey <ajeffrey@mozilla.com> | 2016-05-26 12:55:55 -0500 |
commit | d92dfe1b8c2c3b89e19ed3e2482219f0921c72b0 (patch) | |
tree | a7c58004b343bbf5ba74c73d4e237e8106bd123c /components/script/dom | |
parent | cd1396fa9ae72bebf13115ed0d752fb21ce0df19 (diff) | |
download | servo-d92dfe1b8c2c3b89e19ed3e2482219f0921c72b0.tar.gz servo-d92dfe1b8c2c3b89e19ed3e2482219f0921c72b0.zip |
Record the frame type (IFrame or MozBrowserIFrame) in the pipeline.
Diffstat (limited to 'components/script/dom')
-rw-r--r-- | components/script/dom/bindings/trace.rs | 4 | ||||
-rw-r--r-- | components/script/dom/htmliframeelement.rs | 4 |
2 files changed, 5 insertions, 3 deletions
diff --git a/components/script/dom/bindings/trace.rs b/components/script/dom/bindings/trace.rs index e97e5cb923d..4a1c781a293 100644 --- a/components/script/dom/bindings/trace.rs +++ b/components/script/dom/bindings/trace.rs @@ -56,7 +56,7 @@ use js::jsval::JSVal; use js::rust::Runtime; use layout_interface::{LayoutChan, LayoutRPC}; use libc; -use msg::constellation_msg::{PipelineId, SubpageId, WindowSizeData, WindowSizeType, ReferrerPolicy}; +use msg::constellation_msg::{FrameType, PipelineId, SubpageId, WindowSizeData, WindowSizeType, ReferrerPolicy}; use net_traits::image::base::{Image, ImageMetadata}; use net_traits::image_cache_thread::{ImageCacheChan, ImageCacheThread}; use net_traits::response::HttpsState; @@ -290,7 +290,7 @@ no_jsmanaged_fields!(PropertyDeclarationBlock); no_jsmanaged_fields!(HashSet<T>); // These three are interdependent, if you plan to put jsmanaged data // in one of these make sure it is propagated properly to containing structs -no_jsmanaged_fields!(SubpageId, WindowSizeData, WindowSizeType, PipelineId); +no_jsmanaged_fields!(FrameType, SubpageId, WindowSizeData, WindowSizeType, PipelineId); no_jsmanaged_fields!(TimerEventId, TimerSource); no_jsmanaged_fields!(WorkerId); no_jsmanaged_fields!(QuirksMode); diff --git a/components/script/dom/htmliframeelement.rs b/components/script/dom/htmliframeelement.rs index 8cec0aa6659..3913d46b884 100644 --- a/components/script/dom/htmliframeelement.rs +++ b/components/script/dom/htmliframeelement.rs @@ -34,7 +34,7 @@ use ipc_channel::ipc; use js::jsapi::{JSAutoCompartment, RootedValue, JSContext, MutableHandleValue}; use js::jsval::{UndefinedValue, NullValue}; use layout_interface::ReflowQueryType; -use msg::constellation_msg::{LoadData, NavigationDirection, PipelineId, SubpageId}; +use msg::constellation_msg::{FrameType, LoadData, NavigationDirection, PipelineId, SubpageId}; use net_traits::response::HttpsState; use script_traits::IFrameSandboxState::{IFrameSandboxed, IFrameUnsandboxed}; use script_traits::{IFrameLoadInfo, MozBrowserEvent, ScriptMsg as ConstellationMsg}; @@ -123,6 +123,7 @@ impl HTMLIFrameElement { let (new_subpage_id, old_subpage_id) = self.generate_new_subpage_id(); let new_pipeline_id = self.pipeline_id.get().unwrap(); let private_iframe = self.privatebrowsing(); + let frame_type = if self.Mozbrowser() { FrameType::MozBrowserIFrame } else { FrameType::IFrame }; let load_info = IFrameLoadInfo { load_data: load_data, @@ -132,6 +133,7 @@ impl HTMLIFrameElement { new_pipeline_id: new_pipeline_id, sandbox: sandboxed, is_private: private_iframe, + frame_type: frame_type, }; window.constellation_chan() .send(ConstellationMsg::ScriptLoadedURLInIFrame(load_info)) |