-/* gi_dispa.c: Dispatch layer for Glk API, version 0.7.3.
+/* gi_dispa.c: Dispatch layer for Glk API, version 0.7.4.
Designed by Andrew Plotkin <erkyrath@eblong.com>
http://eblong.com/zarf/glk/
- This file is copyright 1998-2011 by Andrew Plotkin. You may copy,
+ This file is copyright 1998-2012 by Andrew Plotkin. You may copy,
distribute, and incorporate it into your own programs, by any means
and under any conditions, as long as you do not modify it. You may
also modify this file, incorporate it into your own programs,
{ "gestalt_LineTerminatorKey", (19) },
{ "gestalt_LineTerminators", (18) },
{ "gestalt_MouseInput", (4) },
+ { "gestalt_ResourceStream", (22) },
{ "gestalt_Sound", (8) },
{ "gestalt_Sound2", (21) },
{ "gestalt_SoundMusic", (13) },
{ 0x016E, glk_date_to_simple_time_utc, "date_to_simple_time_utc" },
{ 0x016F, glk_date_to_simple_time_local, "date_to_simple_time_local" },
#endif /* GLK_MODULE_DATETIME */
+#ifdef GLK_MODULE_RESOURCE_STREAM
+ { 0x0049, glk_stream_open_resource, "stream_open_resource" },
+ { 0x013A, glk_stream_open_resource_uni, "stream_open_resource_uni" },
+#endif /* GLK_MODULE_RESOURCE_STREAM */
};
glui32 gidispatch_count_classes()
case 0x0042: /* stream_open_file */
return "4QcIuIu:Qb";
case 0x0043: /* stream_open_memory */
- return "4&+#!CnIuIu:Qb";
+ return "4&#!CnIuIu:Qb";
case 0x0044: /* stream_close */
return "2Qb<[2IuIu]:";
case 0x0045: /* stream_set_position */
case 0x0138: /* stream_open_file_uni */
return "4QcIuIu:Qb";
case 0x0139: /* stream_open_memory_uni */
- return "4&+#!IuIuIu:Qb";
+ return "4&#!IuIuIu:Qb";
case 0x0140: /* request_char_event_uni */
return "1Qa:";
case 0x0141: /* request_line_event_uni */
return "3>+[8IsIsIsIsIsIsIsIs]Iu:Is";
#endif /* GLK_MODULE_DATETIME */
+#ifdef GLK_MODULE_RESOURCE_STREAM
+ case 0x0049: /* stream_open_resource */
+ return "3IuIu:Qb";
+ case 0x013A: /* stream_open_resource_uni */
+ return "3IuIu:Qb";
+#endif /* GLK_MODULE_RESOURCE_STREAM */
+
default:
return NULL;
}
break;
#endif /* GLK_MODULE_DATETIME */
+#ifdef GLK_MODULE_RESOURCE_STREAM
+ case 0x0049: /* stream_open_resource */
+ arglist[3].opaqueref = glk_stream_open_resource(arglist[0].uint, arglist[1].uint);
+ break;
+ case 0x013A: /* stream_open_resource_uni */
+ arglist[3].opaqueref = glk_stream_open_resource_uni(arglist[0].uint, arglist[1].uint);
+ break;
+#endif /* GLK_MODULE_RESOURCE_STREAM */
+
default:
/* do nothing */
break;