mirror of
https://github.com/glest/glest-source.git
synced 2025-02-24 19:52:25 +01:00
- bugfix for disabling hotkeys when in menu's and editing text in a field
This commit is contained in:
parent
92039ac053
commit
b180581bf8
@ -2387,6 +2387,11 @@ void MenuStateConnectedGame::cleanupMapPreviewTexture() {
|
||||
if(SystemFlags::getSystemSettingType(SystemFlags::debugSystem).enabled) SystemFlags::OutputDebug(SystemFlags::debugSystem,"In [%s::%s Line: %d]\n",__FILE__,__FUNCTION__,__LINE__);
|
||||
}
|
||||
|
||||
bool MenuStateConnectedGame::isInSpecialKeyCaptureEvent() {
|
||||
bool result = (chatManager.getEditEnabled() || activeInputLabel != NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void MenuStateConnectedGame::FTPClient_CallbackEvent(string itemName,
|
||||
FTP_Client_CallbackType type, pair<FTP_Client_ResultType,string> result, void *userdata) {
|
||||
if(SystemFlags::getSystemSettingType(SystemFlags::debugSystem).enabled) SystemFlags::OutputDebug(SystemFlags::debugSystem,"In [%s::%s Line %d]\n",__FILE__,__FUNCTION__,__LINE__);
|
||||
|
@ -183,7 +183,7 @@ public:
|
||||
virtual void keyPress(char c);
|
||||
virtual void keyUp(char key);
|
||||
|
||||
virtual bool isInSpecialKeyCaptureEvent() { return chatManager.getEditEnabled(); }
|
||||
virtual bool isInSpecialKeyCaptureEvent();
|
||||
|
||||
private:
|
||||
|
||||
|
@ -3108,4 +3108,9 @@ int32 MenuStateCustomGame::getNetworkPlayerStatus() {
|
||||
return result;
|
||||
}
|
||||
|
||||
bool MenuStateCustomGame::isInSpecialKeyCaptureEvent() {
|
||||
bool result = (chatManager.getEditEnabled() || activeInputLabel != NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
}}//end namespace
|
||||
|
@ -173,7 +173,7 @@ public:
|
||||
|
||||
|
||||
virtual void simpleTask(BaseThread *callingThread);
|
||||
virtual bool isInSpecialKeyCaptureEvent() { return chatManager.getEditEnabled(); }
|
||||
virtual bool isInSpecialKeyCaptureEvent();
|
||||
|
||||
private:
|
||||
|
||||
|
@ -663,12 +663,15 @@ void MenuStateOptions::mouseMove(int x, int y, const MouseState *ms){
|
||||
checkBoxDisableScreenshotConsoleText.mouseMove(x, y);
|
||||
}
|
||||
|
||||
bool MenuStateOptions::isInSpecialKeyCaptureEvent() {
|
||||
return (activeInputLabel != NULL);
|
||||
}
|
||||
|
||||
void MenuStateOptions::keyDown(char key){
|
||||
if(activeInputLabel!=NULL)
|
||||
{
|
||||
if(key==vkBack){
|
||||
if(activeInputLabel != NULL) {
|
||||
if(key == vkBack) {
|
||||
string text= activeInputLabel->getText();
|
||||
if(text.size()>1){
|
||||
if(text.size() > 1) {
|
||||
text.erase(text.end()-2);
|
||||
}
|
||||
activeInputLabel->setText(text);
|
||||
|
@ -123,7 +123,7 @@ public:
|
||||
void render();
|
||||
virtual void keyDown(char key);
|
||||
virtual void keyPress(char c);
|
||||
|
||||
virtual bool isInSpecialKeyCaptureEvent();
|
||||
|
||||
private:
|
||||
void saveConfig();
|
||||
|
Loading…
x
Reference in New Issue
Block a user