Disables keyboard on "Attendre_fin_de_clic", so we no longer need to empty the event loop.

git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@593 416bcca6-2ee7-4201-b75f-2eb2f807beb1
This commit is contained in:
Adrien Destugues
2009-02-04 18:21:48 +00:00
parent 00b67c23ef
commit f90af64c83
3 changed files with 20 additions and 0 deletions

View File

@@ -199,6 +199,7 @@ int Handle_Mouse_Release(SDL_MouseButtonEvent event)
INPUT_Nouveau_Mouse_K &= ~2;
break;
}
if(INPUT_Nouveau_Mouse_K==0) Desactiver_clavier=0;
return Move_cursor_with_constraints();
}
@@ -269,6 +270,8 @@ int Handle_Key_Press(SDL_KeyboardEvent event)
}
else Touche = 0;
}
if (Desactiver_clavier) Touche=0; // Utilisé uniquement dans Attendre fin de clic
return 0;
}
@@ -294,11 +297,13 @@ int Relache_controle(int CodeTouche, int Modifieur)
if(CodeTouche == (Config_Touche[SPECIAL_CLICK_LEFT]&0x0FFF) || (Config_Touche[SPECIAL_CLICK_LEFT]&Modifieur))
{
INPUT_Nouveau_Mouse_K &= ~1;
if(INPUT_Nouveau_Mouse_K==0) Desactiver_clavier=0;
return Move_cursor_with_constraints();
}
if(CodeTouche == (Config_Touche[SPECIAL_CLICK_RIGHT]&0x0FFF) || (Config_Touche[SPECIAL_CLICK_RIGHT]&Modifieur))
{
INPUT_Nouveau_Mouse_K &= ~2;
if(INPUT_Nouveau_Mouse_K==0) Desactiver_clavier=0;
return Move_cursor_with_constraints();
}