#pragma once #include #include #include class ComExcute { public: typedef void (*handle_t)(void*); class config { public: handle_t handle; QString name; config(const char* name, handle_t handle); ~config(); }; std::vector configs; int add_excute(ComExcute::config config); }; extern ComExcute com_excute; void com_excute_init(); #define EXPORT_HANDLE(name) ComExcute::config cmd_##name(#name, name)