Commit e51b1284 authored by salix5's avatar salix5

OnEvent()

parent 3f1414f0
...@@ -621,12 +621,13 @@ bool DeckBuilder::OnEvent(const irr::SEvent& event) { ...@@ -621,12 +621,13 @@ bool DeckBuilder::OnEvent(const irr::SEvent& event) {
case irr::EET_KEY_INPUT_EVENT: { case irr::EET_KEY_INPUT_EVENT: {
switch(event.KeyInput.Key) { switch(event.KeyInput.Key) {
case irr::KEY_KEY_R: { case irr::KEY_KEY_R: {
if(!event.KeyInput.PressedDown) if(!event.KeyInput.PressedDown && !mainGame->HasFocus(EGUIET_EDIT_BOX))
mainGame->textFont->setTransparency(true); mainGame->textFont->setTransparency(true);
break; break;
} }
case irr::KEY_ESCAPE: { case irr::KEY_ESCAPE: {
mainGame->device->minimizeWindow(); if(!mainGame->HasFocus(EGUIET_EDIT_BOX))
mainGame->device->minimizeWindow();
break; break;
} }
default: break; default: break;
......
...@@ -364,12 +364,13 @@ bool MenuHandler::OnEvent(const irr::SEvent& event) { ...@@ -364,12 +364,13 @@ bool MenuHandler::OnEvent(const irr::SEvent& event) {
case irr::EET_KEY_INPUT_EVENT: { case irr::EET_KEY_INPUT_EVENT: {
switch(event.KeyInput.Key) { switch(event.KeyInput.Key) {
case irr::KEY_KEY_R: { case irr::KEY_KEY_R: {
if(!event.KeyInput.PressedDown) if(!event.KeyInput.PressedDown && !mainGame->HasFocus(EGUIET_EDIT_BOX))
mainGame->textFont->setTransparency(true); mainGame->textFont->setTransparency(true);
break; break;
} }
case irr::KEY_ESCAPE: { case irr::KEY_ESCAPE: {
mainGame->device->minimizeWindow(); if(!mainGame->HasFocus(EGUIET_EDIT_BOX))
mainGame->device->minimizeWindow();
break; break;
} }
default: break; default: break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment