1
0
Fork 0
mirror of https://github.com/Ellpeck/MLEM.git synced 2024-12-25 17:59:24 +01:00

allow multiple gestures to be queried simultaneously in GetGesture

This commit is contained in:
Ellpeck 2020-05-31 20:07:10 +02:00
parent 6c03ef2bd9
commit d3e8a9f811

View file

@ -416,7 +416,7 @@ namespace MLEM.Input {
/// <returns>True if a gesture of the type was found, otherwise false</returns>
public bool GetGesture(GestureType type, out GestureSample sample) {
foreach (var gesture in this.Gestures) {
if (gesture.GestureType == type) {
if ((gesture.GestureType & type) != 0) {
sample = gesture;
return true;
}