2017-07-18 16:41:40 +00:00
|
|
|
/*
|
|
|
|
* Mr. 4th Dimention - Allen Webster
|
|
|
|
*
|
|
|
|
* 18.07.2017
|
|
|
|
*
|
|
|
|
* Code to link system functions using a name convention
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
// TOP
|
|
|
|
|
|
|
|
// TODO(allen): Should auto-gen this!
|
|
|
|
|
2017-07-18 17:44:54 +00:00
|
|
|
#define SYSLINK(name) sysfunc.name = system_##name
|
2017-07-18 16:41:40 +00:00
|
|
|
|
|
|
|
internal void
|
2017-07-19 16:33:12 +00:00
|
|
|
link_system_code(){
|
2017-07-18 16:41:40 +00:00
|
|
|
SYSLINK(set_file_list);
|
|
|
|
SYSLINK(get_canonical);
|
|
|
|
SYSLINK(add_listener);
|
|
|
|
SYSLINK(remove_listener);
|
|
|
|
SYSLINK(get_file_change);
|
|
|
|
SYSLINK(load_handle);
|
|
|
|
SYSLINK(load_size);
|
|
|
|
SYSLINK(load_file);
|
|
|
|
SYSLINK(load_close);
|
|
|
|
SYSLINK(save_file);
|
|
|
|
|
|
|
|
SYSLINK(now_time);
|
|
|
|
|
|
|
|
SYSLINK(post_clipboard);
|
|
|
|
|
|
|
|
SYSLINK(create_coroutine);
|
|
|
|
SYSLINK(launch_coroutine);
|
|
|
|
SYSLINK(resume_coroutine);
|
|
|
|
SYSLINK(yield_coroutine);
|
|
|
|
|
|
|
|
SYSLINK(cli_call);
|
|
|
|
SYSLINK(cli_begin_update);
|
|
|
|
SYSLINK(cli_update_step);
|
|
|
|
SYSLINK(cli_end_update);
|
|
|
|
|
|
|
|
SYSLINK(post_job);
|
|
|
|
SYSLINK(cancel_job);
|
|
|
|
SYSLINK(check_cancel);
|
|
|
|
SYSLINK(grow_thread_memory);
|
|
|
|
SYSLINK(acquire_lock);
|
|
|
|
SYSLINK(release_lock);
|
|
|
|
|
|
|
|
SYSLINK(memory_allocate);
|
|
|
|
SYSLINK(memory_set_protection);
|
|
|
|
SYSLINK(memory_free);
|
2017-11-30 15:44:08 +00:00
|
|
|
|
2017-07-18 16:41:40 +00:00
|
|
|
SYSLINK(file_exists);
|
|
|
|
SYSLINK(directory_cd);
|
2017-07-19 16:33:12 +00:00
|
|
|
SYSLINK(get_current_path);
|
2017-07-18 16:41:40 +00:00
|
|
|
SYSLINK(get_4ed_path);
|
2017-11-30 15:44:08 +00:00
|
|
|
|
2017-07-18 22:09:16 +00:00
|
|
|
SYSLINK(set_fullscreen);
|
2017-07-18 16:41:40 +00:00
|
|
|
SYSLINK(is_fullscreen);
|
|
|
|
SYSLINK(show_mouse_cursor);
|
|
|
|
SYSLINK(send_exit_signal);
|
2017-11-30 15:44:08 +00:00
|
|
|
SYSLINK(set_title);
|
2017-07-18 16:41:40 +00:00
|
|
|
|
|
|
|
SYSLINK(log);
|
2017-07-18 20:51:44 +00:00
|
|
|
#if defined(FRED_INTERNAL)
|
2017-07-18 16:41:40 +00:00
|
|
|
SYSLINK(internal_get_thread_states);
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
|
|
|
|
// BOTTOM
|
|
|
|
|