RetroArch/input/drivers/cocoa_input.h

58 lines
1.5 KiB
C
Raw Normal View History

/* RetroArch - A frontend for libretro.
2017-01-22 13:40:32 +01:00
* Copyright (C) 2011-2017 - Daniel De Matteis
2014-01-01 01:50:59 +01:00
* Copyright (C) 2013-2014 - Jason Fetters
*
* RetroArch is free software: you can redistribute it and/or modify it under the terms
* of the GNU General Public License as published by the Free Software Found-
* ation, either version 3 of the License, or (at your option) any later version.
*
* RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
* PURPOSE. See the GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License along with RetroArch.
* If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef __COCOA_INPUT_H__
#define __COCOA_INPUT_H__
2015-04-04 23:27:42 +02:00
#include <stdint.h>
#include <boolean.h>
#ifdef HAVE_CONFIG_H
#include "../../config.def.h"
#endif
2019-07-21 08:59:39 -07:00
#include "../input_driver.h"
2014-09-02 16:50:28 +02:00
/* Input responder */
2015-04-04 23:27:42 +02:00
#define MAX_TOUCHES 16
typedef struct
{
int16_t screen_x, screen_y;
int16_t fixed_x, fixed_y;
int16_t full_x, full_y;
} cocoa_touch_data_t;
typedef struct
{
uint32_t touch_count;
uint32_t mouse_buttons;
2020-08-31 03:40:36 +02:00
cocoa_touch_data_t touches[MAX_TOUCHES]; /* int16_t alignment */
2015-11-16 06:46:29 +01:00
int16_t mouse_x_last;
int16_t mouse_y_last;
int16_t window_pos_x;
int16_t window_pos_y;
int16_t mouse_rel_x;
int16_t mouse_rel_y;
2015-03-11 00:35:26 +01:00
int16_t mouse_wu;
int16_t mouse_wd;
2016-10-05 02:00:11 +02:00
int16_t mouse_wl;
int16_t mouse_wr;
} cocoa_input_data_t;
#endif