Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
riscos: Increase the number of supported joystick buttons
  • Loading branch information
ccawley2011 committed Feb 13, 2020
1 parent 718b76b commit 7c875d9
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 5 deletions.
4 changes: 2 additions & 2 deletions README.RISCOS
Expand Up @@ -83,7 +83,7 @@ The following list is an overview of how much of the SDL is implemented. The are
video - Mostly done. Doesn't cover gamma, YUV-overlay or OpenGL.
Window Manager - Mostly done. SetIcon not implemented.
Events - Mostly done. Resize and some joystick events missing.
Joystick - Currently assumes a single joystick with 4 buttons.
Joystick - Currently assumes a single joystick with 8 buttons.
Audio - Done
CDROM - Not implemented.
Threads - Done
Expand Down Expand Up @@ -115,7 +115,7 @@ SDL_EnableUNICODE
Unicode translation used here is only really accurate for 7 bit characters.

SDL_NumJoysticks/JoystickName etc.
Hardcoded to expect only 1 joystick with 4 buttons if the Joystick module is loaded.
Hardcoded to expect only 1 joystick with 8 buttons if the Joystick module is loaded.

SDL_GetTicks
Timer used has only a centisecond accuracy. This applies to other time related functions.
Expand Down
1 change: 1 addition & 0 deletions WhatsNew
Expand Up @@ -85,6 +85,7 @@ Changes include:
- RISC OS: implement SDL_WM_IconifyWindow()
- RISC OS: send SDL_APPACTIVE events when iconizing the window.
- RISC OS: support creating windows with the SDL_NOFRAME flag set.
- RISC OS: increase the number of supported joystick buttons.
- Configuration: fix library detection selecting wrong lib (bug 2795.)
- Configuration: fix detecting dynamic library support on powerpc64le
(bug 3481.)
Expand Down
3 changes: 3 additions & 0 deletions docs.html
Expand Up @@ -209,6 +209,9 @@ <H2> SDL 1.2.16 Release Notes </H2>
<P>
RISC OS: support creating windows with the SDL_NOFRAME flag set.
</P>
<P>
RISC OS: increase the number of supported joystick buttons.
</P>
<P>
Configuration: fix library detection selecting wrong lib (bug <a href="https://bugzilla.libsdl.org/show_bug.cgi?id=2795">2795</a>.)
</P>
Expand Down
6 changes: 3 additions & 3 deletions src/joystick/riscos/SDL_sysjoystick.c
Expand Up @@ -27,7 +27,7 @@
RISC OS - Joystick support by Alan Buckley (alan_baa@hotmail.com) - 10 April 2003
Note: Currently assumes joystick is present if joystick module is loaded
and that there is one joystick with four buttons.
and that there is one joystick with eight buttons.
*/

/* This is the system specific header for the SDL joystick API */
Expand Down Expand Up @@ -94,8 +94,8 @@ int SDL_SYS_JoystickOpen(SDL_Joystick *joystick)
return -1;
}

/* Don't know how to get exact count of buttons so assume max of 4 for now */
joystick->nbuttons=4;
/* Don't know how to get exact count of buttons so assume max of 8 for now */
joystick->nbuttons=8;

joystick->nhats=0;
joystick->nballs=0;
Expand Down

0 comments on commit 7c875d9

Please sign in to comment.