diff options
Diffstat (limited to 'components/script/dom/webgl_extensions')
17 files changed, 44 insertions, 36 deletions
diff --git a/components/script/dom/webgl_extensions/ext/angleinstancedarrays.rs b/components/script/dom/webgl_extensions/ext/angleinstancedarrays.rs index 74d779a94a3..21712a6a90c 100644 --- a/components/script/dom/webgl_extensions/ext/angleinstancedarrays.rs +++ b/components/script/dom/webgl_extensions/ext/angleinstancedarrays.rs @@ -2,15 +2,15 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; use canvas_traits::webgl::WebGLVersion; use crate::dom::bindings::codegen::Bindings::ANGLEInstancedArraysBinding; use crate::dom::bindings::codegen::Bindings::ANGLEInstancedArraysBinding::ANGLEInstancedArraysConstants; use crate::dom::bindings::codegen::Bindings::ANGLEInstancedArraysBinding::ANGLEInstancedArraysMethods; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::{Dom, DomRoot}; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct ANGLEInstancedArrays { diff --git a/components/script/dom/webgl_extensions/ext/extblendminmax.rs b/components/script/dom/webgl_extensions/ext/extblendminmax.rs index 060595f5c51..19aa0e06a97 100644 --- a/components/script/dom/webgl_extensions/ext/extblendminmax.rs +++ b/components/script/dom/webgl_extensions/ext/extblendminmax.rs @@ -2,13 +2,13 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; use canvas_traits::webgl::WebGLVersion; use crate::dom::bindings::codegen::Bindings::EXTBlendMinmaxBinding; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct EXTBlendMinmax { diff --git a/components/script/dom/webgl_extensions/ext/extcolorbufferhalffloat.rs b/components/script/dom/webgl_extensions/ext/extcolorbufferhalffloat.rs index d1500aa2c9e..aa1d25f024b 100644 --- a/components/script/dom/webgl_extensions/ext/extcolorbufferhalffloat.rs +++ b/components/script/dom/webgl_extensions/ext/extcolorbufferhalffloat.rs @@ -2,14 +2,14 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; use canvas_traits::webgl::WebGLVersion; use crate::dom::bindings::codegen::Bindings::EXTColorBufferHalfFloatBinding; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webgl_extensions::ext::oestexturehalffloat::OESTextureHalfFloat; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct EXTColorBufferHalfFloat { diff --git a/components/script/dom/webgl_extensions/ext/extshadertexturelod.rs b/components/script/dom/webgl_extensions/ext/extshadertexturelod.rs index 4faf199bfde..219904b13b7 100644 --- a/components/script/dom/webgl_extensions/ext/extshadertexturelod.rs +++ b/components/script/dom/webgl_extensions/ext/extshadertexturelod.rs @@ -2,13 +2,13 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -use canvas_traits::webgl::{WebGLVersion, is_gles}; +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; +use canvas_traits::webgl::{is_gles, WebGLVersion}; use crate::dom::bindings::codegen::Bindings::EXTShaderTextureLodBinding; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct EXTShaderTextureLod { diff --git a/components/script/dom/webgl_extensions/ext/exttexturefilteranisotropic.rs b/components/script/dom/webgl_extensions/ext/exttexturefilteranisotropic.rs index 9b491c685bf..f487ab4775e 100644 --- a/components/script/dom/webgl_extensions/ext/exttexturefilteranisotropic.rs +++ b/components/script/dom/webgl_extensions/ext/exttexturefilteranisotropic.rs @@ -2,14 +2,14 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; use canvas_traits::webgl::WebGLVersion; use crate::dom::bindings::codegen::Bindings::EXTTextureFilterAnisotropicBinding; use crate::dom::bindings::codegen::Bindings::EXTTextureFilterAnisotropicBinding::EXTTextureFilterAnisotropicConstants; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct EXTTextureFilterAnisotropic { diff --git a/components/script/dom/webgl_extensions/ext/mod.rs b/components/script/dom/webgl_extensions/ext/mod.rs index 54290ceb9eb..174653e3332 100644 --- a/components/script/dom/webgl_extensions/ext/mod.rs +++ b/components/script/dom/webgl_extensions/ext/mod.rs @@ -2,8 +2,8 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{ext_constants, WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; use crate::dom::bindings::codegen::Bindings::WebGLRenderingContextBinding::WebGLRenderingContextConstants as constants; -use super::{ext_constants, WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; pub mod angleinstancedarrays; pub mod extblendminmax; diff --git a/components/script/dom/webgl_extensions/ext/oeselementindexuint.rs b/components/script/dom/webgl_extensions/ext/oeselementindexuint.rs index 65e6829831f..2a06fbe35f2 100644 --- a/components/script/dom/webgl_extensions/ext/oeselementindexuint.rs +++ b/components/script/dom/webgl_extensions/ext/oeselementindexuint.rs @@ -2,13 +2,13 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -use canvas_traits::webgl::{WebGLVersion, is_gles}; +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; +use canvas_traits::webgl::{is_gles, WebGLVersion}; use crate::dom::bindings::codegen::Bindings::OESElementIndexUintBinding; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct OESElementIndexUint { diff --git a/components/script/dom/webgl_extensions/ext/oesstandardderivatives.rs b/components/script/dom/webgl_extensions/ext/oesstandardderivatives.rs index 6afef692953..6a2c76aedb1 100644 --- a/components/script/dom/webgl_extensions/ext/oesstandardderivatives.rs +++ b/components/script/dom/webgl_extensions/ext/oesstandardderivatives.rs @@ -2,14 +2,14 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -use canvas_traits::webgl::{WebGLVersion, is_gles}; +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; +use canvas_traits::webgl::{is_gles, WebGLVersion}; use crate::dom::bindings::codegen::Bindings::OESStandardDerivativesBinding; use crate::dom::bindings::codegen::Bindings::OESStandardDerivativesBinding::OESStandardDerivativesConstants; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct OESStandardDerivatives { diff --git a/components/script/dom/webgl_extensions/ext/oestexturefloat.rs b/components/script/dom/webgl_extensions/ext/oestexturefloat.rs index 0c468cf1fa2..6db9c6473d1 100644 --- a/components/script/dom/webgl_extensions/ext/oestexturefloat.rs +++ b/components/script/dom/webgl_extensions/ext/oestexturefloat.rs @@ -2,13 +2,15 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{ + constants as webgl, ext_constants as gl, WebGLExtension, WebGLExtensionSpec, WebGLExtensions, +}; use canvas_traits::webgl::WebGLVersion; use crate::dom::bindings::codegen::Bindings::OESTextureFloatBinding; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{constants as webgl, ext_constants as gl, WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct OESTextureFloat { diff --git a/components/script/dom/webgl_extensions/ext/oestexturefloatlinear.rs b/components/script/dom/webgl_extensions/ext/oestexturefloatlinear.rs index 57d7a594c22..31fb196efa2 100644 --- a/components/script/dom/webgl_extensions/ext/oestexturefloatlinear.rs +++ b/components/script/dom/webgl_extensions/ext/oestexturefloatlinear.rs @@ -2,12 +2,12 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{constants as webgl, WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; use crate::dom::bindings::codegen::Bindings::OESTextureFloatLinearBinding; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{constants as webgl, WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct OESTextureFloatLinear { diff --git a/components/script/dom/webgl_extensions/ext/oestexturehalffloat.rs b/components/script/dom/webgl_extensions/ext/oestexturehalffloat.rs index 695d77ee67b..1ab369b8304 100644 --- a/components/script/dom/webgl_extensions/ext/oestexturehalffloat.rs +++ b/components/script/dom/webgl_extensions/ext/oestexturehalffloat.rs @@ -2,13 +2,17 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{ + constants as webgl, ext_constants as gl, WebGLExtension, WebGLExtensionSpec, WebGLExtensions, +}; use canvas_traits::webgl::WebGLVersion; -use crate::dom::bindings::codegen::Bindings::OESTextureHalfFloatBinding::{self, OESTextureHalfFloatConstants}; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::codegen::Bindings::OESTextureHalfFloatBinding::{ + self, OESTextureHalfFloatConstants, +}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{constants as webgl, ext_constants as gl, WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct OESTextureHalfFloat { diff --git a/components/script/dom/webgl_extensions/ext/oestexturehalffloatlinear.rs b/components/script/dom/webgl_extensions/ext/oestexturehalffloatlinear.rs index dd44caca9ca..07109f6576e 100644 --- a/components/script/dom/webgl_extensions/ext/oestexturehalffloatlinear.rs +++ b/components/script/dom/webgl_extensions/ext/oestexturehalffloatlinear.rs @@ -2,13 +2,13 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; use crate::dom::bindings::codegen::Bindings::OESTextureHalfFloatBinding::OESTextureHalfFloatConstants; use crate::dom::bindings::codegen::Bindings::OESTextureHalfFloatLinearBinding; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct OESTextureHalfFloatLinear { diff --git a/components/script/dom/webgl_extensions/ext/oesvertexarrayobject.rs b/components/script/dom/webgl_extensions/ext/oesvertexarrayobject.rs index ba1256538d4..5238a4c287c 100644 --- a/components/script/dom/webgl_extensions/ext/oesvertexarrayobject.rs +++ b/components/script/dom/webgl_extensions/ext/oesvertexarrayobject.rs @@ -2,15 +2,17 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; use canvas_traits::webgl::WebGLVersion; -use crate::dom::bindings::codegen::Bindings::OESVertexArrayObjectBinding::{self, OESVertexArrayObjectMethods}; use crate::dom::bindings::codegen::Bindings::OESVertexArrayObjectBinding::OESVertexArrayObjectConstants; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::codegen::Bindings::OESVertexArrayObjectBinding::{ + self, OESVertexArrayObjectMethods, +}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::{Dom, DomRoot}; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use crate::dom::webglvertexarrayobjectoes::WebGLVertexArrayObjectOES; use dom_struct::dom_struct; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct OESVertexArrayObject { diff --git a/components/script/dom/webgl_extensions/ext/webglcolorbufferfloat.rs b/components/script/dom/webgl_extensions/ext/webglcolorbufferfloat.rs index aceaf026728..263d21fe882 100644 --- a/components/script/dom/webgl_extensions/ext/webglcolorbufferfloat.rs +++ b/components/script/dom/webgl_extensions/ext/webglcolorbufferfloat.rs @@ -2,14 +2,14 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; use canvas_traits::webgl::WebGLVersion; use crate::dom::bindings::codegen::Bindings::WEBGLColorBufferFloatBinding; -use crate::dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object}; +use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::DomRoot; use crate::dom::webgl_extensions::ext::oestexturefloat::OESTextureFloat; use crate::dom::webglrenderingcontext::WebGLRenderingContext; use dom_struct::dom_struct; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; #[dom_struct] pub struct WEBGLColorBufferFloat { diff --git a/components/script/dom/webgl_extensions/extension.rs b/components/script/dom/webgl_extensions/extension.rs index 6256eb4b608..53e3e8b21a7 100644 --- a/components/script/dom/webgl_extensions/extension.rs +++ b/components/script/dom/webgl_extensions/extension.rs @@ -2,12 +2,12 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::WebGLExtensions; use canvas_traits::webgl::WebGLVersion; use crate::dom::bindings::reflector::DomObject; use crate::dom::bindings::root::DomRoot; use crate::dom::bindings::trace::JSTraceable; use crate::dom::webglrenderingcontext::WebGLRenderingContext; -use super::WebGLExtensions; /// Trait implemented by WebGL extensions. pub trait WebGLExtension: Sized diff --git a/components/script/dom/webgl_extensions/extensions.rs b/components/script/dom/webgl_extensions/extensions.rs index 52f4bf4d47f..76c995068dc 100644 --- a/components/script/dom/webgl_extensions/extensions.rs +++ b/components/script/dom/webgl_extensions/extensions.rs @@ -2,6 +2,8 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::wrapper::{TypedWebGLExtensionWrapper, WebGLExtensionWrapper}; +use super::{ext, WebGLExtension, WebGLExtensionSpec}; use canvas_traits::webgl::WebGLVersion; use crate::dom::bindings::cell::DomRefCell; use crate::dom::bindings::codegen::Bindings::ANGLEInstancedArraysBinding::ANGLEInstancedArraysConstants; @@ -23,8 +25,6 @@ use malloc_size_of::MallocSizeOf; use std::collections::HashMap; use std::iter::FromIterator; use std::ptr::NonNull; -use super::{ext, WebGLExtension, WebGLExtensionSpec}; -use super::wrapper::{WebGLExtensionWrapper, TypedWebGLExtensionWrapper}; // Data types that are implemented for texImage2D and texSubImage2D in a WebGL 1.0 context // but must trigger a InvalidValue error until the related WebGL Extensions are enabled. diff --git a/components/script/dom/webgl_extensions/wrapper.rs b/components/script/dom/webgl_extensions/wrapper.rs index 6b39fc0e2bc..9918952dc73 100644 --- a/components/script/dom/webgl_extensions/wrapper.rs +++ b/components/script/dom/webgl_extensions/wrapper.rs @@ -2,6 +2,7 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use super::{WebGLExtension, WebGLExtensionSpec, WebGLExtensions}; use crate::dom::bindings::reflector::DomObject; use crate::dom::bindings::root::MutNullableDom; use crate::dom::bindings::trace::JSTraceable; @@ -10,7 +11,6 @@ use js::jsapi::JSObject; use malloc_size_of::MallocSizeOf; use std::any::Any; use std::ptr::NonNull; -use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec}; /// Trait used internally by WebGLExtensions to store and /// handle the different WebGL extensions in a common list. |