aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/domrectreadonly.rs
diff options
context:
space:
mode:
Diffstat (limited to 'components/script/dom/domrectreadonly.rs')
-rw-r--r--components/script/dom/domrectreadonly.rs14
1 files changed, 14 insertions, 0 deletions
diff --git a/components/script/dom/domrectreadonly.rs b/components/script/dom/domrectreadonly.rs
index d50045b8bfd..1034c049df7 100644
--- a/components/script/dom/domrectreadonly.rs
+++ b/components/script/dom/domrectreadonly.rs
@@ -55,6 +55,20 @@ impl DOMRectReadOnly {
)
}
+ pub(crate) fn new_from_dictionary(
+ global: &GlobalScope,
+ proto: Option<HandleObject>,
+ dictionary: &DOMRectInit,
+ can_gc: CanGc,
+ ) -> DomRoot<DOMRectReadOnly> {
+ reflect_dom_object_with_proto(
+ Box::new(create_a_domrectreadonly_from_the_dictionary(dictionary)),
+ global,
+ proto,
+ can_gc,
+ )
+ }
+
pub(crate) fn set_x(&self, value: f64) {
self.x.set(value);
}