Blamite Game Engine - blam!  00296.01.12.21.0102.blamite
The core library for the Blamite Game Engine.
error_dialog.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #include "../debug_ui.h"
4 
6 {
15  {
16  public:
17  bool show_error_dialog = false;
18  const char* title = "";
19  const char* message = "";
20 
25 
30 
34  void Draw()
35  {
37  {
38  ImGui::OpenPopup(title);
39  if (ImGui::BeginPopupModal(title, &show_error_dialog, ImGuiWindowFlags_AlwaysAutoResize))
40  {
42 
43  ImGui::Separator();
44 
45  if (ImGui::Button("ok"))
46  {
47  show_error_dialog = false;
48  }
49 
50  ImGui::EndPopup();
51  }
52  }
53  }
54  };
55 }
Blam::DebugUI::Windows::ErrorDialog::ErrorDialog
ErrorDialog()
Empty constructor.
Definition: error_dialog.hpp:24
Blam::DebugUI::Windows::ErrorDialog::message
const char * message
The contents of the error dialog.
Definition: error_dialog.hpp:19
Blam::DebugUI::Windows::ErrorDialog
A seemingly incomplete class for an ImGUI-based error dialog?
Definition: error_dialog.hpp:14
Blam::DebugUI::Windows::ErrorDialog::show_error_dialog
bool show_error_dialog
Whether or not to show the error dialog.
Definition: error_dialog.hpp:17
Blam::DebugUI::ImGUIDrawingGroup
Class representing an ImGUI drawing group/draw list item.
Definition: debug_ui.h:359
Blam::DebugUI::Windows::ErrorDialog::~ErrorDialog
~ErrorDialog()
Empty destructor.
Definition: error_dialog.hpp:29
Blam::DebugUI::Windows
Legacy namespace to contain data for the legacy ImGUI console.
Definition: debug_ui.h:434
Blam::DebugUI::Windows::ErrorDialog::Draw
void Draw()
Shows the error dialog, if enabled.
Definition: error_dialog.hpp:34
Text
@ Text
Master text object that wraps around both BitmapText and DWText.
Definition: render_stack.h:73
Blam::DebugUI::Windows::ErrorDialog::title
const char * title
The title of the error dialog.
Definition: error_dialog.hpp:18