2016-11-07 15:41:01 +01:00
|
|
|
/*
|
|
|
|
* Template C-- program.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#define MEMSIZE 4096*10
|
|
|
|
|
2016-11-30 15:30:05 +01:00
|
|
|
#include <io.h>
|
|
|
|
#include <gui.h>
|
2016-11-07 15:41:01 +01:00
|
|
|
|
|
|
|
proc_info Form;
|
|
|
|
|
|
|
|
void main()
|
|
|
|
{
|
|
|
|
word btn;
|
|
|
|
loop() switch(WaitEvent())
|
|
|
|
{
|
|
|
|
case evButton:
|
|
|
|
btn = GetButtonID();
|
|
|
|
if (btn == 1) ExitProcess();
|
|
|
|
break;
|
|
|
|
|
|
|
|
case evKey:
|
|
|
|
GetKeys();
|
|
|
|
if (key_scancode == SCAN_CODE_ESC) ExitProcess();
|
|
|
|
break;
|
|
|
|
|
|
|
|
case evReDraw:
|
|
|
|
draw_window();
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
void draw_window()
|
|
|
|
{
|
2016-11-23 12:37:13 +01:00
|
|
|
DefineAndDrawWindow(215, 100, 350, 300, 0x34, 0xEEEeee, "Window title",0);
|
2016-11-07 15:41:01 +01:00
|
|
|
GetProcessInfo(#Form, SelfInfo);
|
|
|
|
}
|