summaryrefslogtreecommitdiff
path: root/meme/gui.c
diff options
context:
space:
mode:
authorWerner Almesberger <werner@almesberger.net>2015-03-16 15:44:34 (GMT)
committerWerner Almesberger <werner@almesberger.net>2015-03-16 15:44:34 (GMT)
commit7a36d4f5b214d62268a085dad665b09c41f2b3c7 (patch)
tree9a5934c45ccae9d15cc346a10061ad04001953ef /meme/gui.c
parent542ea751bc0d739ac4ff8490abd66726dd7c08ee (diff)
downloadmisc-7a36d4f5b214d62268a085dad665b09c41f2b3c7.zip
misc-7a36d4f5b214d62268a085dad665b09c41f2b3c7.tar.gz
misc-7a36d4f5b214d62268a085dad665b09c41f2b3c7.tar.bz2
meme/, vispcb/: separate paths from "struct overlay"
Diffstat (limited to 'meme/gui.c')
-rw-r--r--meme/gui.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/meme/gui.c b/meme/gui.c
index 847fb4b..056912b 100644
--- a/meme/gui.c
+++ b/meme/gui.c
@@ -1198,7 +1198,7 @@ static void delayed_motion(void *user)
static bool event_loop(SDL_Surface **surf, const char *logfile,
- const struct overlay *const *overlays, unsigned n_overlays)
+ const struct overlay overlays[], unsigned n_overlays)
{
SDL_Surface *s = *surf;
SDL_Event event;
@@ -1253,15 +1253,15 @@ static bool event_loop(SDL_Surface **surf, const char *logfile,
return 1;
case SDLK_1:
if (n_overlays)
- overlay = overlays[0];
+ overlay = overlays + 0;
return 0;
case SDLK_2:
if (n_overlays > 1)
- overlay = overlays[1];
+ overlay = overlays + 1;
return 0;
case SDLK_3:
if (n_overlays > 2)
- overlay = overlays[2];
+ overlay = overlays + 2;
return 0;
default:
break;
@@ -1301,7 +1301,7 @@ static bool event_loop(SDL_Surface **surf, const char *logfile,
void gui(const char *logfile,
- const struct overlay *const *overlays, unsigned n_overlays)
+ const struct overlay overlays[], unsigned n_overlays)
{
SDL_Surface *surf;
@@ -1328,7 +1328,7 @@ void gui(const char *logfile,
auto_scale();
if (n_overlays)
- overlay = overlays[0];
+ overlay = overlays;
while (1) {
struct time t;