From 6651ceec96e227ff2f04d78741f1e859db0de745 Mon Sep 17 00:00:00 2001 From: sachiel Date: Wed, 22 Sep 2010 14:52:23 +0000 Subject: [PATCH] Don't include Edje_Edit.h in edje_private.h and make it obvious at compile time that this API is not meant to be used outside of editors. git-svn-id: http://svn.enlightenment.org/svn/e/trunk/edje@52593 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- src/lib/Edje_Edit.h | 4 ++++ src/lib/edje_edit.c | 3 +++ src/lib/edje_private.h | 1 - 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/lib/Edje_Edit.h b/src/lib/Edje_Edit.h index d9314ea..7c3a324 100644 --- a/src/lib/Edje_Edit.h +++ b/src/lib/Edje_Edit.h @@ -1,6 +1,10 @@ #ifndef _EDJE_EDIT_H #define _EDJE_EDIT_H +#ifndef EDJE_EDIT_IS_UNSTABLE_AND_I_KNOW_ABOUT_IT +#error "Do not use the Edje_Edit API unless you know what you are doing. It's meant only for writing editors and nothing else." +#endif + #include #ifdef EAPI diff --git a/src/lib/edje_edit.c b/src/lib/edje_edit.c index 9d6878d..184211e 100644 --- a/src/lib/edje_edit.c +++ b/src/lib/edje_edit.c @@ -30,6 +30,9 @@ #include "edje_private.h" +#define EDJE_EDIT_IS_UNSTABLE_AND_I_KNOW_ABOUT_IT +#include "Edje_Edit.h" + static const char EDJE_EDIT_ERROR_GROUP_CURRENTLY_USED_STR[] = "Current group cannot be deleted"; static const char EDJE_EDIT_ERROR_GROUP_REFERENCED_STR[] = "Group still in use"; static const char EDJE_EDIT_ERROR_GROUP_DOES_NOT_EXIST_STR[] = "Group does not exist"; diff --git a/src/lib/edje_private.h b/src/lib/edje_private.h index efbb6ff..8ffc141 100644 --- a/src/lib/edje_private.h +++ b/src/lib/edje_private.h @@ -35,7 +35,6 @@ void *alloca (size_t); #include #include "Edje.h" -#include "Edje_Edit.h" #include #include -- 2.7.4