[client] overlay: move keybinds and config into the overlays

This adds a new `earlyInit` call which allows the overlay to register
options before actually being intialized. Also the keybind handling and
state tracking for each overlay has been moved internal to the overlay
itself.
This commit is contained in:
Geoffrey McRae
2021-08-05 06:40:06 +10:00
parent d90e658e3b
commit 6c84c0eca6
12 changed files with 83 additions and 56 deletions

View File

@@ -31,8 +31,11 @@ struct LG_OverlayOps
/* internal name of the overlay for debugging */
const char * name;
/* called very early to allow for option registration, optional */
void (*earlyInit)(void);
/* called when the overlay is registered */
bool (*init)(void ** udata, void * params);
bool (*init)(void ** udata, const void * params);
/* final free */
void (*free)(void * udata);