aboutsummaryrefslogtreecommitdiffstats
path: root/src/screen_lyrics.c
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/screen_lyrics.c32
1 files changed, 13 insertions, 19 deletions
diff --git a/src/screen_lyrics.c b/src/screen_lyrics.c
index 2f63fb0ae..885a35a76 100644
--- a/src/screen_lyrics.c
+++ b/src/screen_lyrics.c
@@ -376,23 +376,17 @@ lyrics_lw(void)
return lw;
}
-screen_functions_t *
-get_screen_lyrics(void)
-{
- static screen_functions_t functions;
-
- memset(&functions, 0, sizeof(screen_functions_t));
- functions.init = lyrics_screen_init;
- functions.exit = lyrics_exit;
- functions.open = lyrics_open;
- functions.close = NULL;
- functions.resize = lyrics_resize;
- functions.paint = lyrics_paint;
- functions.update = lyrics_update;
- functions.cmd = lyrics_cmd;
- functions.get_lw = lyrics_lw;
- functions.get_title = lyrics_title;
-
- return &functions;
-}
+const struct screen_functions screen_lyrics = {
+ .init = lyrics_screen_init,
+ .exit = lyrics_exit,
+ .open = lyrics_open,
+ .close = NULL,
+ .resize = lyrics_resize,
+ .paint = lyrics_paint,
+ .update = lyrics_update,
+ .cmd = lyrics_cmd,
+ .get_lw = lyrics_lw,
+ .get_title = lyrics_title,
+};
+
#endif /* ENABLE_LYRICS_SCREEN */