diff --git a/main.cpp b/main.cpp new file mode 100644 index 0000000000000000000000000000000000000000..26b45162368f7e7e454aceaccd6d682b59f6244f --- /dev/null +++ b/main.cpp @@ -0,0 +1,78 @@ +#include "graphics.hpp" +#include "widgets.hpp" +#include "application.hpp" +#include "checkbox.hpp" +//#include "spinbox.hpp" +//#include "dropdown.hpp" +//#include "statictext.hpp" +#include "textedit.hpp" +//#include "multiline.hpp" +#include "palya.hpp" + +#include <iostream> +#include <fstream> +#include <vector> +#include <string> + +using namespace std; +using namespace genv; + +const int ablak_szel=702; +const int ablak_mag=702; + +class MyApp : public Application +{ +public: + MyApp() + { + p = new Palya(this, 0, 0, 702, "mo1.txt", "fe1.txt"); + } + + void action(string id) + { + /*if (id=="enter") + save(); + + else if (id=="space" && cb->xelt_e()) + save2();*/ + } + + /*void save() + { + std::ofstream file(te1->get_szoveg()); + file << te2->get_szoveg(); + file.close(); + } + + void save2() + { + std::ofstream file(te2->get_szoveg()); + file << te1->get_szoveg(); + file.close(); + }*/ + +protected: + Palya* p; +}; + +int main() +{ + gout.open(ablak_szel,ablak_mag); + + /*std::ofstream file("mentes.txt"); + for (int i=0; i<9; i++) + { + for (int j=0; j<9; j++) + { + file << "0"; + } + file << endl; + } + file.close();*/ + + MyApp app; + + app.event_loop(); + + return 0; +}