2005/5/9

     
 

acdk_wx Minimal Sample

artefaktur

A minimal sample creating GUI application.



A minimal sample in  CfgScript:

using acdk.wx;

class MyApp
extends acdk.wx.App
{
  MyApp() {}
  bool onInit()
  {
    (new Frame()).show(true);
    return true; 
  }
}

StringArray args = new StringArray(0);
acdk.wx.App.createGui("MyApp", args);

A minimal sample in ACDK C++:

class Main 
: extends App
{
public:
  bool onInit()
  {
    (new Frame("Hello Wx"))->show(true);
    return true;
  }
};

int
main(int argc, char* argv[], char** envptr)
{
  RStringArray args = new StringArray(0);
  return App::createGui(new MyApp(), args);
}