diff options
author | 2019-10-07 02:17:40 +0200 | |
---|---|---|
committer | 2019-10-07 02:17:40 +0200 | |
commit | 70c17b053b10741f6018b2559bb46c5f289cadb9 (patch) | |
tree | dfb0ded61e9429eaf653e2f77512ab56608e2f3a /wgpu | |
parent | 5286ef36b6a5eb6846b5675a7a4aced72601df3b (diff) | |
download | iced-70c17b053b10741f6018b2559bb46c5f289cadb9.tar.gz iced-70c17b053b10741f6018b2559bb46c5f289cadb9.tar.bz2 iced-70c17b053b10741f6018b2559bb46c5f289cadb9.zip |
Rename `Box` primitive to `Quad`
Diffstat (limited to 'wgpu')
-rw-r--r-- | wgpu/src/primitive.rs | 2 | ||||
-rw-r--r-- | wgpu/src/renderer.rs | 4 | ||||
-rw-r--r-- | wgpu/src/renderer/button.rs | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/wgpu/src/primitive.rs b/wgpu/src/primitive.rs index e9ab100e..91cdfc85 100644 --- a/wgpu/src/primitive.rs +++ b/wgpu/src/primitive.rs @@ -11,7 +11,7 @@ pub enum Primitive { bounds: Rectangle, size: f32, }, - Box { + Quad { bounds: Rectangle, background: Background, }, diff --git a/wgpu/src/renderer.rs b/wgpu/src/renderer.rs index f8f000f0..5db47a8e 100644 --- a/wgpu/src/renderer.rs +++ b/wgpu/src/renderer.rs @@ -144,8 +144,8 @@ impl Renderer { scale: wgpu_glyph::Scale { x: *size, y: *size }, ..Default::default() }), - Primitive::Box { bounds, background } => { - // TODO: Batch boxes and draw them all at once + Primitive::Quad { bounds, background } => { + // TODO: Batch quads and draw them all at once } } } diff --git a/wgpu/src/renderer/button.rs b/wgpu/src/renderer/button.rs index b9dfb9ac..fd874832 100644 --- a/wgpu/src/renderer/button.rs +++ b/wgpu/src/renderer/button.rs @@ -20,7 +20,7 @@ impl button::Renderer for Renderer { ) -> Self::Primitive { Primitive::Group { primitives: vec![ - Primitive::Box { + Primitive::Quad { bounds: layout.bounds(), background: Background::Color(Color { r: 0.0, |