mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
Make GlobalScope.get_cx a static method.
This commit is contained in:
parent
4998c65c42
commit
f79e1e327d
39 changed files with 132 additions and 127 deletions
|
@ -117,7 +117,7 @@ impl XRRigidTransformMethods for XRRigidTransform {
|
|||
// https://immersive-web.github.io/webxr/#dom-xrrigidtransform-matrix
|
||||
fn Matrix(&self, _cx: JSContext) -> NonNull<JSObject> {
|
||||
if self.matrix.get().is_null() {
|
||||
let cx = self.global().get_cx();
|
||||
let cx = GlobalScope::get_cx();
|
||||
// According to the spec all matrices are column-major,
|
||||
// however euclid uses row vectors so we use .to_array()
|
||||
let arr = self.transform.to_transform().to_array();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue