mirror of
				https://github.com/luanti-org/luanti.git
				synced 2025-10-30 23:15:32 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			18 lines
		
	
	
		
			1.0 KiB
		
	
	
	
		
			Diff
		
	
	
	
	
	
			
		
		
	
	
			18 lines
		
	
	
		
			1.0 KiB
		
	
	
	
		
			Diff
		
	
	
	
	
	
| diff --git a/android/app/src/main/java/org/libsdl/app/SDLActivity.java b/android/app/src/main/java/org/libsdl/app/SDLActivity.java
 | |
| --- a/android/app/src/main/java/org/libsdl/app/SDLActivity.java
 | |
| +++ b/android/app/src/main/java/org/libsdl/app/SDLActivity.java
 | |
| @@ -1345,7 +1345,12 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
 | |
|              }
 | |
|          }
 | |
|  
 | |
| -        if ((source & InputDevice.SOURCE_MOUSE) == InputDevice.SOURCE_MOUSE) {
 | |
| +        if ((source & InputDevice.SOURCE_MOUSE) == InputDevice.SOURCE_MOUSE ||
 | |
| +                /*
 | |
| +                 * CUSTOM ADDITION FOR LUANTI
 | |
| +                 * should be upstreamed
 | |
| +                 */
 | |
| +                (source & InputDevice.SOURCE_MOUSE_RELATIVE) == InputDevice.SOURCE_MOUSE_RELATIVE) {
 | |
|              // on some devices key events are sent for mouse BUTTON_BACK/FORWARD presses
 | |
|              // they are ignored here because sending them as mouse input to SDL is messy
 | |
|              if ((keyCode == KeyEvent.KEYCODE_BACK) || (keyCode == KeyEvent.KEYCODE_FORWARD)) {
 |