scaffolding in preparation for adding simple load/export/save functionality
This commit is contained in:
@@ -9,6 +9,10 @@ int KEY_G = GLFW_KEY_G;
|
||||
int KEY_Y = GLFW_KEY_Y;
|
||||
int KEY_Z = GLFW_KEY_Z;
|
||||
|
||||
int KEY_S = GLFW_KEY_S;
|
||||
int KEY_E = GLFW_KEY_E;
|
||||
int KEY_I = GLFW_KEY_I;
|
||||
|
||||
// Calls function exported from SML
|
||||
void mouseMoveCallback(GLFWwindow *window, double xpos, double ypos) {
|
||||
mltonMouseMoveCallback((float)xpos, (float)ypos);
|
||||
|
||||
@@ -37,4 +37,11 @@ struct
|
||||
_symbol "KEY_Y" public : ( unit -> int ) * ( int -> unit );
|
||||
val (KEY_Z, _) =
|
||||
_symbol "KEY_Z" public : ( unit -> int ) * ( int -> unit );
|
||||
|
||||
val (KEY_S, _) =
|
||||
_symbol "KEY_S" public : ( unit -> int ) * ( int -> unit );
|
||||
val (KEY_E, _) =
|
||||
_symbol "KEY_E" public : ( unit -> int ) * ( int -> unit );
|
||||
val (KEY_I, _) =
|
||||
_symbol "KEY_I" public : ( unit -> int ) * ( int -> unit );
|
||||
end
|
||||
|
||||
15
message-types/io-msg.sml
Normal file
15
message-types/io-msg.sml
Normal file
@@ -0,0 +1,15 @@
|
||||
signature IO_MESSAGE =
|
||||
sig
|
||||
datatype t =
|
||||
SAVE_TRIANGLES of AppType.triangle list
|
||||
| EXPORT_FILE of AppType.triangle list
|
||||
| IMPORT_FILE
|
||||
end
|
||||
|
||||
structure IoMessage :> IO_MESSAGE =
|
||||
struct
|
||||
datatype t =
|
||||
SAVE_TRIANGLES of AppType.triangle list
|
||||
| EXPORT_FILE of AppType.triangle list
|
||||
| IMPORT_FILE
|
||||
end
|
||||
Reference in New Issue
Block a user