summaryrefslogblamecommitdiff
path: root/Source/Applications/Demos/cxxdemo.cpp
blob: 36cfd276357a237009a978bc40c0978a3f7ffb02 (plain) (tree)
1
2
3
4
5
6
7
8
9
                                
                                 
                               
 



                                 
                                                                                                  





                    
                                          

                                   
                                 
                                           
                                       
                             
         



                                                                                          
 
#include <Syscall/Syscall.wtf.h>
#include <Binding/Thread.class.h>
#include <Binding/File.class.h>

#include <App/ShellApp.proto.h>

class CPPDemo : public ShellApp {
	public:
	CPPDemo() : ShellApp("CPPDemo.app", "A demo application using the C++ Melon framework") {}
	int run();
};

APP(CPPDemo);

int CPPDemo::run() {
	outvt << "Enter some text plz : ";
	String s = invt.readLine();
	outvt << s;
	Thread t = Thread::get();
	for (char c = ' '; c <= 'z'; c++) {
		t.sleep((u32int)c / 4);
		outvt.put(c);
	}
	outvt << "\n";
	outvt << "Salut les gens ! c'est le progrès !!!\nLe boeuf mort est juste là : ";
	outvt << 0xDEADBEEF;
	outvt << "\n";
}