1
0
mirror of git://projects.qi-hardware.com/antorcha.git synced 2024-11-25 20:57:31 +02:00

tools/plot.c: clear sample mode screen with C

This commit is contained in:
Werner Almesberger 2012-06-21 18:56:18 -03:00
parent 87050bc12a
commit 77bd5797d3

View File

@ -80,6 +80,13 @@ int plot(int x, int y)
switch (event.type) { switch (event.type) {
case SDL_KEYDOWN: case SDL_KEYDOWN:
switch (event.key.keysym.sym) { switch (event.key.keysym.sym) {
case SDLK_c:
SDL_LockSurface(surf);
SDL_FillRect(surf, NULL,
SDL_MapRGB(surf->format, 0, 0, 0));
SDL_UpdateRect(surf, 0, 0, 0, 0);
SDL_UnlockSurface(surf);
break;
case SDLK_q: case SDLK_q:
return 0; return 0;
default: default: