Imgui integration began switching dialogs over to new system, work in progress!

This commit is contained in:
Justin Marshall
2020-06-07 20:15:01 -07:00
parent 935b56c995
commit 290a7fb1c5
183 changed files with 76340 additions and 2 deletions
+28
View File
@@ -34,6 +34,17 @@
* main -- Initial startup routine (preps library systems). *
* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
// jmarshall - imgui
#include "imgui.h"
#include "examples/imgui_impl_win32.h"
#include "examples/imgui_impl_dx9.h"
#include <d3d9.h>
extern LPDIRECT3DDEVICE9 globald3d9Device;
// jmarshall end
#include "function.h"
#include <conio.h>
#include <io.h>
@@ -551,6 +562,23 @@ int PASCAL WinMain ( HINSTANCE instance , HINSTANCE , char * command_line , int
video_success = TRUE;
}
}
// jmarshall
IMGUI_CHECKVERSION();
ImGui::CreateContext();
ImGuiIO& io = ImGui::GetIO(); (void)io;
//io.ConfigFlags |= ImGuiConfigFlags_NavEnableKeyboard; // Enable Keyboard Controls
//io.ConfigFlags |= ImGuiConfigFlags_NavEnableGamepad; // Enable Gamepad Controls
// Setup Dear ImGui style
ImGui::StyleColorsDark();
//ImGui::StyleColorsClassic();
// Setup Platform/Renderer bindings
ImGui_ImplWin32_Init(MainWindow);
ImGui_ImplDX9_Init(globald3d9Device);
io.Fonts->AddFontFromFileTTF("code/fonts/Roboto-Medium.ttf", 16.0f);
// jmarshall end
if (!video_success) {
MessageBox(MainWindow, TEXT_VIDEO_ERROR, TEXT_SHORT_TITLE, MB_ICONEXCLAMATION|MB_OK);