Simplify struct name

This commit is contained in:
Hanno Braun 2022-10-12 13:37:53 +02:00
parent f0bddb564f
commit 0154fe729d
2 changed files with 6 additions and 6 deletions

View File

@ -9,7 +9,7 @@ use wgpu_glyph::ab_glyph::InvalidFont;
use crate::{ use crate::{
camera::Camera, camera::Camera,
gui::EguiState, gui::Gui,
screen::{Screen, Size}, screen::{Screen, Size},
}; };
@ -37,7 +37,7 @@ pub struct Renderer {
pipelines: Pipelines, pipelines: Pipelines,
/// State required for integration with `egui`. /// State required for integration with `egui`.
pub egui: EguiState, pub egui: Gui,
} }
impl Renderer { impl Renderer {
@ -151,7 +151,7 @@ impl Renderer {
let pipelines = let pipelines =
Pipelines::new(&device, &bind_group_layout, color_format); Pipelines::new(&device, &bind_group_layout, color_format);
let egui = EguiState::new(&device, surface_config.format); let egui = Gui::new(&device, surface_config.format);
Ok(Self { Ok(Self {
surface, surface,

View File

@ -23,13 +23,13 @@ pub struct EguiOptionsState {
pub show_inspection_ui: bool, pub show_inspection_ui: bool,
} }
pub struct EguiState { pub struct Gui {
pub context: egui::Context, pub context: egui::Context,
pub render_pass: egui_wgpu::renderer::RenderPass, pub render_pass: egui_wgpu::renderer::RenderPass,
pub options: EguiOptionsState, pub options: EguiOptionsState,
} }
impl EguiState { impl Gui {
pub fn new( pub fn new(
device: &wgpu::Device, device: &wgpu::Device,
texture_format: wgpu::TextureFormat, texture_format: wgpu::TextureFormat,
@ -76,7 +76,7 @@ impl EguiState {
} }
} }
impl std::fmt::Debug for EguiState { impl std::fmt::Debug for Gui {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
f.write_str("EguiState {}") f.write_str("EguiState {}")
} }