March 28, 2024, 11:33:55 AM

News:

IonicWind Snippit Manager 2.xx Released!  Install it on a memory stick and take it with you!  With or without IWBasic!


Example executable

Started by Ionic Wind Support Team, December 10, 2005, 12:00:42 AM

Previous topic - Next topic

0 Members and 3 Guests are viewing this topic.

Ionic Wind Support Team

December 10, 2005, 12:00:42 AM Last Edit: May 16, 2006, 02:30:13 PM by Ionic Wizard
The executable for this code is downloadable at the end of the post.

Nothing spectacular mind you.  Still not too bad considering the amount of work just to get OOP working properly.


class mywindow : Cwindow
{
//overridden functions.
declare OnClose(),int;
declare OnCreate(),int;
declare OnTimer(int nIDEvent),int;
}

mywindow::OnClose(),int
{
StopTimer();
Destroy();
return TRUE;
}

mywindow::OnCreate(),int
{
CenterWindow();
return TRUE;
}

mywindow::OnTimer(int nIDEvent),int
{
for(x=0;x<10;x++)
{
Line(rand(300),rand(260)+40,rand(300),rand(260)+40,RGB(rand(0xff),rand(0xff),rand(0xff)));
}
return TRUE;
}

global sub main()
{
mywindow w;
w.Create(0,0,300,300,AWS_CAPTION|AWS_VISIBLE|AWS_BORDER|AWS_SYSMENU|AWS_AUTODRAW|AWS_SIZE,0,"test window",NULL);
w.WriteText(10,10,"Aurora's first window");
w.StartTimer(10);
do {
wait();
}until w.m_hwnd = 0;
return;
}
Ionic Wind Support Team

Zen

Hey cool. Nice to see it coming along. How long do you think it will be untill we can have a go?

Lewis

Ionic Wind Support Team

A couple of hours ;)

Stuffing methods into the window class as we speak.

Paul.
Ionic Wind Support Team

Zen

Excellent, i didnt think it would be that soon. Looking forward to it.

Lewis

Ionic Wind Support Team

Still working on the release.  Got a logic bug I am trying to track down regarding class methods being marked external when the shouldn't be.
Ionic Wind Support Team