Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added output files to .gitignore #2

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Specify filepatterns you want git to ignore.
*.o
ROM.bin
mjfwest marked this conversation as resolved.
Show resolved Hide resolved
arcem
32 changes: 31 additions & 1 deletion sdl/DispKbd.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@ static const char *arrow[] = {
" ",
"0,0"};

static void ProcessKey(ARMul_State *state, SDL_Event event);

static SDL_Cursor *init_system_cursor(const char *image[])
{
int i, row, col;
Expand Down Expand Up @@ -348,7 +350,7 @@ void SDD_Name(Host_PollDisplay)(ARMul_State *state)
SDL_SetRelativeMouseMode(SDL_FALSE);
}

// ProcessKey(event);
ProcessKey(state, event);
break;

case SDL_QUIT:
Expand Down Expand Up @@ -435,6 +437,34 @@ SDD_HostColour SDD_Name(Host_GetColour)(ARMul_State *state, uint_fast16_t col)
return r << 16 | g << 8 | b;
}


static void ProcessKey(ARMul_State *state, SDL_Event event)
{

fprintf(stderr,"key = %d modifier = %d type = %d timestamp = %d\n",
event.key.keysym.sym,
event.key.keysym.mod,
event.key.type,
event.key.timestamp);

if (KBD.BuffOcc >= KBDBUFFLEN)
{
#ifdef DEBUG_KBD
fprintf(stderr, "KBD: Missed mouse event - buffer full\n");
#endif
return;
}

/*
KBD.Buffer[KBD.BuffOcc].KeyColToSend = ButtonNum;
KBD.Buffer[KBD.BuffOcc].KeyRowToSend = 7;
KBD.Buffer[KBD.BuffOcc].KeyUpNDown = UpNDown;
Now add it to the buffer */


}


// SDD_Row SDD_Name(Host_BeginRow)(ARMul_State *state,int row,int offset)
// - Function to return a SDD_Row instance suitable for accessing the indicated
// row, starting from the given X offset
Expand Down