mirror of
				https://github.com/Ryujinx/SDL2-CS.git
				synced 2025-11-04 15:44:49 +00:00 
			
		
		
		
	Input is done! I think!
This commit is contained in:
		
							parent
							
								
									5bdf2d4c35
								
							
						
					
					
						commit
						d4d6dff87c
					
				
							
								
								
									
										42
									
								
								src/SDL2.cs
									
									
									
									
									
								
							
							
						
						
									
										42
									
								
								src/SDL2.cs
									
									
									
									
									
								
							| 
						 | 
					@ -2555,6 +2555,11 @@ namespace SDL2
 | 
				
			||||||
			public SDL_DropEvent drop;
 | 
								public SDL_DropEvent drop;
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							public delegate int SDL_EventFilter(
 | 
				
			||||||
 | 
								IntPtr userdata, // void*
 | 
				
			||||||
 | 
								IntPtr sdlevent // SDL_Event* event, lolC#
 | 
				
			||||||
 | 
							);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		/* Pump the event loop, getting events from the input devices*/
 | 
							/* Pump the event loop, getting events from the input devices*/
 | 
				
			||||||
		[DllImport(nativeLibName)]
 | 
							[DllImport(nativeLibName)]
 | 
				
			||||||
		public static extern void SDL_PumpEvents();
 | 
							public static extern void SDL_PumpEvents();
 | 
				
			||||||
| 
						 | 
					@ -2612,9 +2617,40 @@ namespace SDL2
 | 
				
			||||||
		[DllImport(nativeLibName)]
 | 
							[DllImport(nativeLibName)]
 | 
				
			||||||
		public static extern int SDL_PushEvent(ref SDL_Event _event);
 | 
							public static extern int SDL_PushEvent(ref SDL_Event _event);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		/* TODO: Input Events: All of the event filter stuff.
 | 
							/* userdata refers to a void* */
 | 
				
			||||||
		 * http://wiki.libsdl.org/moin.fcg/APIByCategory#Input_Events
 | 
							[DllImport(nativeLibName)]
 | 
				
			||||||
		 */
 | 
							public static extern void SDL_SetEventFilter(
 | 
				
			||||||
 | 
								SDL_EventFilter filter,
 | 
				
			||||||
 | 
								IntPtr userdata
 | 
				
			||||||
 | 
							);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							/* userdata refers to a void* */
 | 
				
			||||||
 | 
							[DllImport(nativeLibName)]
 | 
				
			||||||
 | 
							public static extern SDL_bool SDL_GetEventFilter(
 | 
				
			||||||
 | 
								ref SDL_EventFilter filter,
 | 
				
			||||||
 | 
								ref IntPtr userdata
 | 
				
			||||||
 | 
							);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							/* userdata refers to a void* */
 | 
				
			||||||
 | 
							[DllImport(nativeLibName)]
 | 
				
			||||||
 | 
							public static extern void SDL_AddEventWatch(
 | 
				
			||||||
 | 
								SDL_EventFilter filter,
 | 
				
			||||||
 | 
								IntPtr userdata
 | 
				
			||||||
 | 
							);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							/* userdata refers to a void* */
 | 
				
			||||||
 | 
							[DllImport(nativeLibName)]
 | 
				
			||||||
 | 
							public static extern void SDL_DelEventWatch(
 | 
				
			||||||
 | 
								SDL_EventFilter filter,
 | 
				
			||||||
 | 
								IntPtr userdata
 | 
				
			||||||
 | 
							);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							/* userdata refers to a void* */
 | 
				
			||||||
 | 
							[DllImport(nativeLibName)]
 | 
				
			||||||
 | 
							public static extern void SDL_FilterEvents(
 | 
				
			||||||
 | 
								SDL_EventFilter filter,
 | 
				
			||||||
 | 
								IntPtr userdata
 | 
				
			||||||
 | 
							);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		/* These are for SDL_EventState() */
 | 
							/* These are for SDL_EventState() */
 | 
				
			||||||
		public const int SDL_QUERY = 		-1;
 | 
							public const int SDL_QUERY = 		-1;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue