fixing keyboard input

This commit is contained in:
Michele Scandura 2021-09-24 16:54:44 +01:00
parent 099fca8ceb
commit 9cd001919a

View File

@ -137,7 +137,16 @@ namespace Sledgemapper
_outlineShader = Content.Load<Effect>("shaders/OutlineShader");
MyraEnvironment.Game = this;
ResetRenderTarget();
// Inform Myra that external text input is available
// So it stops translating Keys to chars
_desktop.HasExternalTextInput = true;
// Provide that text input
Window.TextInput += (s, a) =>
{
_desktop.OnChar(a.Character);
};
_mainWidget = new MainWidget(_communicationManager, _messenger, Window);
_communicationManager.CheckLogin();