aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/webgl_validations
diff options
context:
space:
mode:
Diffstat (limited to 'components/script/dom/webgl_validations')
-rw-r--r--components/script/dom/webgl_validations/tex_image_2d.rs10
-rw-r--r--components/script/dom/webgl_validations/types.rs3
2 files changed, 8 insertions, 5 deletions
diff --git a/components/script/dom/webgl_validations/tex_image_2d.rs b/components/script/dom/webgl_validations/tex_image_2d.rs
index dece682d377..31ad93adbbf 100644
--- a/components/script/dom/webgl_validations/tex_image_2d.rs
+++ b/components/script/dom/webgl_validations/tex_image_2d.rs
@@ -2,14 +2,16 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
+use std::{self, cmp, fmt};
+
+use canvas_traits::webgl::WebGLError::*;
+use canvas_traits::webgl::{TexDataType, TexFormat};
+
use super::types::TexImageTarget;
use super::WebGLValidator;
use crate::dom::bindings::root::DomRoot;
use crate::dom::webglrenderingcontext::WebGLRenderingContext;
-use crate::dom::webgltexture::{ImageInfo, WebGLTexture};
-use crate::dom::webgltexture::{TexCompression, TexCompressionValidation};
-use canvas_traits::webgl::{TexDataType, TexFormat, WebGLError::*};
-use std::{self, cmp, fmt};
+use crate::dom::webgltexture::{ImageInfo, TexCompression, TexCompressionValidation, WebGLTexture};
/// The errors that the texImage* family of functions can generate.
#[derive(Debug)]
diff --git a/components/script/dom/webgl_validations/types.rs b/components/script/dom/webgl_validations/types.rs
index b28664843e9..7e0164c9738 100644
--- a/components/script/dom/webgl_validations/types.rs
+++ b/components/script/dom/webgl_validations/types.rs
@@ -2,10 +2,11 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
-use crate::dom::bindings::codegen::Bindings::WebGL2RenderingContextBinding::WebGL2RenderingContextConstants as constants;
use canvas_traits::gl_enums;
use serde::{Deserialize, Serialize};
+use crate::dom::bindings::codegen::Bindings::WebGL2RenderingContextBinding::WebGL2RenderingContextConstants as constants;
+
gl_enums! {
pub enum TexImageTarget {
Texture2D = constants::TEXTURE_2D,