Path: blob/main/system/include/SDL/SDL_input.h
6169 views
/*1Simple DirectMedia Layer2Copyright (C) 1997-2011 Sam Lantinga <[email protected]>34This software is provided 'as-is', without any express or implied5warranty. In no event will the authors be held liable for any damages6arising from the use of this software.78Permission is granted to anyone to use this software for any purpose,9including commercial applications, and to alter it and redistribute it10freely, subject to the following restrictions:11121. The origin of this software must not be misrepresented; you must not13claim that you wrote the original software. If you use this software14in a product, an acknowledgment in the product documentation would be15appreciated but is not required.162. Altered source versions must be plainly marked as such, and must not be17misrepresented as being the original software.183. This notice may not be removed or altered from any source distribution.19*/2021/**22* \file SDL_input.h23*24* Include file for lowlevel SDL input device handling.25*26* This talks about individual devices, and not the system cursor. If you27* just want to know when the user moves the pointer somewhere in your28* window, this is NOT the API you want. This one handles things like29* multi-touch, drawing tablets, and multiple, separate mice.30*31* The other API is in SDL_mouse.h32*/3334#ifndef _SDL_input_h35#define _SDL_input_h3637#include "SDL_stdinc.h"38#include "SDL_error.h"39#include "SDL_video.h"4041#include "begin_code.h"42/* Set up for C function definitions, even when using C++ */43#ifdef __cplusplus44/* *INDENT-OFF* */45extern "C" {46/* *INDENT-ON* */47#endif484950/* Function prototypes */5152/* !!! FIXME: real documentation53* - Redetect devices54* - This invalidates all existing device information from previous queries!55* - There is an implicit (re)detect upon SDL_Init().56*/57extern DECLSPEC int SDLCALL SDL_RedetectInputDevices(void);5859/**60* \brief Get the number of mouse input devices available.61*/62extern DECLSPEC int SDLCALL SDL_GetNumInputDevices(void);6364/**65* \brief Gets the name of a device with the given index.66*67* \param index is the index of the device, whose name is to be returned.68*69* \return the name of the device with the specified index70*/71extern DECLSPEC const char *SDLCALL SDL_GetInputDeviceName(int index);727374extern DECLSPEC int SDLCALL SDL_IsDeviceDisconnected(int index);7576/* Ends C function definitions when using C++ */77#ifdef __cplusplus78/* *INDENT-OFF* */79}80/* *INDENT-ON* */81#endif82#include "close_code.h"8384#endif /* _SDL_mouse_h */8586/* vi: set ts=4 sw=4 expandtab: */878889