Added some REFLECT_ macros, so the reflection code doesn't have to mess with the internals of reflection.

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@218 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2007-03-18 22:45:02 +00:00
parent f2ce80d88a
commit dcfee659d0
10 changed files with 52 additions and 25 deletions
+3 -3
View File
@@ -36,12 +36,12 @@ Field::Field()
Field::~Field() {}
IMPLEMENT_REFLECTION(Field) {
if (!tag.reading()) {
REFLECT_IF_NOT_READING {
String type = typeName();
REFLECT(type);
}
REFLECT(name);
if (tag.reading()) name = cannocial_name_form(name);
REFLECT_IF_READING name = cannocial_name_form(name);
REFLECT(description);
REFLECT_N("icon", icon_filename);
REFLECT(editable);
@@ -53,7 +53,7 @@ IMPLEMENT_REFLECTION(Field) {
REFLECT(card_list_visible);
REFLECT(card_list_allow);
REFLECT(card_list_name);
if (tag.reading() && card_list_name.empty()) card_list_name = name;
REFLECT_IF_READING if(card_list_name.empty()) card_list_name = name;
REFLECT_N("card_list_alignment", card_list_align);
REFLECT(tab_index);
}