Skip to content

Commit

Permalink
f
Browse files Browse the repository at this point in the history
  • Loading branch information
etorth committed Jan 12, 2025
1 parent 599de84 commit ec2ec45
Showing 1 changed file with 13 additions and 7 deletions.
20 changes: 13 additions & 7 deletions server/src/mainwindow.fl
Original file line number Diff line number Diff line change
Expand Up @@ -45,17 +45,23 @@ class MainWindow {} {
MenuItem m_launchMenu {
label {Launch }
callback {{
extern MonoServer *g_monoServer;
delete g_monoServer;

extern ServerPasswordWindow *g_serverPasswordWindow;
g_serverPasswordWindow->setTitle("Please set server password:");
g_serverPasswordWindow->showAll();

g_monoServer = new MonoServer();
g_monoServer->Launch();
auto fnLaunchCallback = [this](ServerPasswordWindow *)
{
extern MonoServer *g_monoServer;
delete g_monoServer;

g_monoServer = new MonoServer();
g_monoServer->Launch();

m_launchMenu->deactivate();
m_launchMenu->deactivate();
g_serverPasswordWindow->hideAll();
};

g_serverPasswordWindow->setCallback(fnLaunchCallback);
g_serverPasswordWindow->showAll();
}}
xywh {0 0 30 20} shortcut 0x4006c divider
code0 {\#include "monoserver.hpp"}
Expand Down

0 comments on commit ec2ec45

Please sign in to comment.