aboutsummaryrefslogtreecommitdiff
path: root/engines/glk/glk_api.h
diff options
context:
space:
mode:
authorPaul Gilbert2019-04-13 21:41:40 -0700
committerPaul Gilbert2019-04-14 08:34:49 -0700
commit9a6d62c0c64afc11fc3e20a9c88d64a9412d2fb1 (patch)
treef1201dc30861bb69c2fcda56181fef12134e834a /engines/glk/glk_api.h
parent7fba5444ee822202aa02fb7e5cef49baba76c630 (diff)
downloadscummvm-rg350-9a6d62c0c64afc11fc3e20a9c88d64a9412d2fb1.tar.gz
scummvm-rg350-9a6d62c0c64afc11fc3e20a9c88d64a9412d2fb1.tar.bz2
scummvm-rg350-9a6d62c0c64afc11fc3e20a9c88d64a9412d2fb1.zip
GLK: Added core Glk dispatch code
Diffstat (limited to 'engines/glk/glk_api.h')
-rw-r--r--engines/glk/glk_api.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/engines/glk/glk_api.h b/engines/glk/glk_api.h
index 55994fd3c1..9e4a230cd9 100644
--- a/engines/glk/glk_api.h
+++ b/engines/glk/glk_api.h
@@ -32,6 +32,18 @@
namespace Glk {
+class GlkAPI;
+
+typedef void (GlkAPI::*GlkFunction)();
+
+struct gidispatch_function_struct {
+ uint32 id;
+ const char *name;
+ GlkFunction fnptr;
+};
+typedef gidispatch_function_struct gidispatch_function_t;
+
+
/**
* Implements the GLK interface
*/
@@ -283,6 +295,18 @@ public:
void garglk_window_get_cursor(winid_t win, uint *xpos, uint *ypos);
void garglk_window_get_cursor_current(uint *xpos, uint *ypos);
+
+ /* dispa methods */
+
+ uint32 gidispatch_count_classes() const;
+ const gidispatch_intconst_t *gidispatch_get_class(uint32 index) const;
+ uint32 gidispatch_count_intconst() const;
+ const gidispatch_intconst_t *gidispatch_get_intconst(uint32 index) const;
+ uint32 gidispatch_count_functions() const;
+ gidispatch_function_t *gidispatch_get_function(uint32 index) const;
+ gidispatch_function_t *gidispatch_get_function_by_id(uint32 id) const;
+ const char *gidispatch_prototype(uint32 funcnum) const;
+ void gidispatch_call(uint32 funcnum, uint32 numargs, gluniversal_t *arglist);
};
} // End of namespace Glk