mirror of
https://github.com/CTCaer/RetroArch.git
synced 2025-01-10 21:10:15 +00:00
Add install_signal_handler callback
This commit is contained in:
parent
1a148da76a
commit
6cdc34e891
@ -280,5 +280,6 @@ frontend_ctx_driver_t frontend_ctx_ctr = {
|
||||
frontend_ctr_parse_drive_list,
|
||||
NULL, /* get_mem_total */
|
||||
NULL, /* get_mem_free */
|
||||
NULL, /* install_signal_handler */
|
||||
"ctr",
|
||||
};
|
||||
|
@ -723,5 +723,6 @@ frontend_ctx_driver_t frontend_ctx_darwin = {
|
||||
frontend_darwin_parse_drive_list,
|
||||
frontend_darwin_get_mem_total,
|
||||
frontend_darwin_get_mem_used,
|
||||
NULL, /* install_signal_handler */
|
||||
"darwin",
|
||||
};
|
||||
|
@ -526,5 +526,6 @@ frontend_ctx_driver_t frontend_ctx_gx = {
|
||||
frontend_gx_parse_drive_list,
|
||||
frontend_gx_get_mem_total,
|
||||
frontend_gx_get_mem_used,
|
||||
NULL, /* install_signal_handler */
|
||||
"gx",
|
||||
};
|
||||
|
@ -1995,6 +1995,7 @@ frontend_ctx_driver_t frontend_ctx_linux = {
|
||||
#endif
|
||||
frontend_linux_get_mem_total,
|
||||
frontend_linux_get_mem_used,
|
||||
NULL, /* install_signal_handler */
|
||||
#ifdef ANDROID
|
||||
"android"
|
||||
#else
|
||||
|
@ -37,5 +37,6 @@ frontend_ctx_driver_t frontend_ctx_null = {
|
||||
NULL, /* parse_drive_list */
|
||||
NULL, /* get_mem_total */
|
||||
NULL, /* get_mem_free */
|
||||
NULL, /* install_signal_handler */
|
||||
"null",
|
||||
};
|
||||
|
@ -542,5 +542,6 @@ frontend_ctx_driver_t frontend_ctx_ps3 = {
|
||||
frontend_ps3_parse_drive_list,
|
||||
NULL, /* get_mem_total */
|
||||
NULL, /* get_mem_free */
|
||||
NULL, /* install_signal_handler */
|
||||
"ps3",
|
||||
};
|
||||
|
@ -407,6 +407,7 @@ frontend_ctx_driver_t frontend_ctx_psp = {
|
||||
frontend_psp_parse_drive_list,
|
||||
NULL, /* get_mem_total */
|
||||
NULL, /* get_mem_free */
|
||||
NULL, /* install_signal_handler */
|
||||
#ifdef VITA
|
||||
"vita",
|
||||
#else
|
||||
|
@ -86,5 +86,6 @@ frontend_ctx_driver_t frontend_ctx_qnx = {
|
||||
NULL, /* parse_drive_list */
|
||||
NULL, /* get_mem_total */
|
||||
NULL, /* get_mem_free */
|
||||
NULL, /* install_signal_handler */
|
||||
"qnx",
|
||||
};
|
||||
|
@ -333,5 +333,6 @@ frontend_ctx_driver_t frontend_ctx_win32 = {
|
||||
frontend_win32_parse_drive_list,
|
||||
frontend_win32_get_mem_total,
|
||||
frontend_win32_get_mem_used,
|
||||
NULL, /* install_signal_handler */
|
||||
"win32"
|
||||
};
|
||||
|
@ -1408,5 +1408,6 @@ frontend_ctx_driver_t frontend_ctx_xdk = {
|
||||
frontend_xdk_parse_drive_list,
|
||||
NULL, /* get_mem_total */
|
||||
NULL, /* get_mem_free */
|
||||
NULL, /* install_signal_handler */
|
||||
"xdk",
|
||||
};
|
||||
|
@ -85,5 +85,6 @@ frontend_ctx_driver_t frontend_ctx_qnx = {
|
||||
NULL, /* get_powerstate */
|
||||
NULL, /* parse_drive_list */
|
||||
NULL, /* get_mem_total */
|
||||
NULL, /* install_signal_handler */
|
||||
"xenon",
|
||||
};
|
||||
|
@ -324,4 +324,12 @@ uint64_t frontend_driver_get_used_memory(void)
|
||||
return 0;
|
||||
return frontend->get_used_mem();
|
||||
}
|
||||
|
||||
void frontend_driver_install_sighandler(void)
|
||||
{
|
||||
frontend_ctx_driver_t *frontend = frontend_get_ptr();
|
||||
if (!frontend || !frontend->install_signal_handler)
|
||||
return;
|
||||
frontend->install_signal_handler();
|
||||
}
|
||||
#endif
|
||||
|
@ -82,6 +82,7 @@ typedef struct frontend_ctx_driver
|
||||
int (*parse_drive_list)(void*);
|
||||
uint64_t (*get_total_mem)(void);
|
||||
uint64_t (*get_used_mem)(void);
|
||||
void (*install_signal_handler)(void);
|
||||
|
||||
const char *ident;
|
||||
|
||||
@ -159,6 +160,8 @@ uint64_t frontend_driver_get_total_memory(void);
|
||||
|
||||
uint64_t frontend_driver_get_used_memory(void);
|
||||
|
||||
void frontend_driver_install_sighandler(void);
|
||||
|
||||
RETRO_END_DECLS
|
||||
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user