make apps customizable
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
#include "Print.h"
|
||||
|
||||
Print::Print(void* h, App& a) : Module(h, a) {
|
||||
Print::Print(void* h, Archimedes::App* a) : Archimedes::Module(h, a) {
|
||||
name = "Print";
|
||||
}
|
||||
|
||||
@@ -10,5 +10,9 @@ Print::~Print() {
|
||||
|
||||
void Print::run() {
|
||||
std::cout << "Print lib loaded and run!\n";
|
||||
app.stopModule(self);
|
||||
|
||||
for(auto m : Archimedes::Module::GetModules())
|
||||
std::cout << m << std::endl;
|
||||
|
||||
app->stopModule(self);
|
||||
}
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
#include "../../../include/Archimedes.h"
|
||||
#include "Archimedes.h"
|
||||
|
||||
class Print : public Module {
|
||||
class Print : public Archimedes::Module {
|
||||
|
||||
public:
|
||||
Print(void*, App&);
|
||||
Print(void*, Archimedes::App*);
|
||||
~Print();
|
||||
void run();
|
||||
void onLoad() {}
|
||||
@@ -11,7 +11,7 @@ class Print : public Module {
|
||||
};
|
||||
|
||||
extern "C" {
|
||||
Module* create(void* handle, App& app) {
|
||||
Archimedes::Module* create(void* handle, Archimedes::App* app) {
|
||||
return new Print(handle, app);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user