diff --git a/lib/api/GwApi.h b/lib/api/GwApi.h index afef372..9611707 100644 --- a/lib/api/GwApi.h +++ b/lib/api/GwApi.h @@ -129,4 +129,7 @@ class GwApi{ #ifndef DECLARE_CAPABILITY #define DECLARE_CAPABILITY(name,value) #endif +#ifndef DECLARE_STRING_CAPABILITY +#define DECLARE_STRING_CAPABILITY(name,value) +#endif #endif diff --git a/lib/exampletask/GwExampleTask.h b/lib/exampletask/GwExampleTask.h index b759c93..cb128a5 100644 --- a/lib/exampletask/GwExampleTask.h +++ b/lib/exampletask/GwExampleTask.h @@ -46,4 +46,6 @@ DECLARE_CAPABILITY(testboard2,true); //hide some config value //just set HIDE + the name of the config item to true DECLARE_CAPABILITY(HIDEminXdrInterval,true); + +DECLARE_STRING_CAPABILITY(HELP_URL,"https://www.wellenvogel.de"); #endif \ No newline at end of file diff --git a/lib/usercode/GwUserCode.cpp b/lib/usercode/GwUserCode.cpp index df5a633..1e36e13 100644 --- a/lib/usercode/GwUserCode.cpp +++ b/lib/usercode/GwUserCode.cpp @@ -41,7 +41,8 @@ class GwUserCapability{ #define DECLARE_USERTASK(task) GwUserTaskDef __##task##__(task,#task); #define DECLARE_USERTASK_PARAM(task,...) GwUserTaskDef __##task##__(task,#task,__VA_ARGS__); #define DECLARE_INITFUNCTION(task) GwInitTask __Init##task##__(task,#task); -#define DECLARE_CAPABILITY(name,value) GwUserCapability __CAP##name##__(#name,#value); +#define DECLARE_CAPABILITY(name,value) GwUserCapability __CAP##name##__(#name,#value); +#define DECLARE_STRING_CAPABILITY(name,value) GwUserCapability __CAP##name##__(#name,value); #include "GwApi.h" #include "GwUserTasks.h" class TaskApi : public GwApi diff --git a/web/index.html b/web/index.html index c5bde6e..a607101 100644 --- a/web/index.html +++ b/web/index.html @@ -21,6 +21,7 @@