BoredProject
This commit is contained in:
parent
3f2e6fdb4e
commit
b3d06906ff
9 changed files with 195 additions and 3 deletions
39
Chat/applications/ChatGUI.cpp
Normal file
39
Chat/applications/ChatGUI.cpp
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
|
||||
#include "ClientGui.hpp"
|
||||
#include "Window.hpp"
|
||||
|
||||
using namespace tp;
|
||||
|
||||
int main() {
|
||||
|
||||
ModuleManifest* deps[] = { &tp::gModuleChat, nullptr };
|
||||
ModuleManifest testModule("ClientGUI", nullptr, nullptr, deps);
|
||||
|
||||
if (!testModule.initialize()) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
{
|
||||
ChatAPI chat;
|
||||
ClientGUI gui;
|
||||
|
||||
auto window = Window::createWindow(1000, 700, "Window 1");
|
||||
|
||||
if (window) {
|
||||
|
||||
window->getGraphics().getDebugGui().setFontSize(4);
|
||||
|
||||
while (!window->shouldClose()) {
|
||||
window->processEvents();
|
||||
|
||||
gui.draw(chat);
|
||||
|
||||
window->draw();
|
||||
}
|
||||
}
|
||||
|
||||
Window::destroyWindow(window);
|
||||
}
|
||||
|
||||
testModule.deinitialize();
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue