-#define COMPILE_DATE_STRING "[2003-07-03 21:19]"
+#define COMPILE_DATE_STRING "[2003-07-04 09:17]"
if (element < NUM_FILE_ELEMENTS)
{
- if (element_info[element].custom_description != NULL)
- info_text = element_info[element].custom_description;
- else if (strlen(element_info[element].description) > 0)
+ if (strlen(element_info[element].description) > 0)
info_text = element_info[element].description;
+ else if (element_info[element].custom_description != NULL)
+ info_text = element_info[element].custom_description;
else if (element_info[element].editor_description != NULL)
info_text = element_info[element].editor_description;
}
strcpy(textinput_info[type_id].value, gi->text.value);
if (type_id == ED_TEXTINPUT_ID_ELEMENT_NAME)
+ {
CopyCustomElementPropertiesToGame(properties_element);
+
+ ModifyEditorElementList(); /* update changed button info text */
+ }
}
static void HandleSelectboxGadgets(struct GadgetInfo *gi)
{
int element = EL_CUSTOM_START + i;
- for(j=0; j<MAX_ELEMENT_NAME_LEN; j++)
+ for(j=0; j<MAX_ELEMENT_NAME_LEN + 1; j++)
element_info[element].description[j] = '\0';
- strcpy(element_info[element].description,
- element_info[element].editor_description);
+ if (element_info[element].custom_description != NULL)
+ strncpy(element_info[element].description,
+ element_info[element].custom_description, MAX_ELEMENT_NAME_LEN);
+ else
+ strcpy(element_info[element].description,
+ element_info[element].editor_description);
element_info[element].use_gfx_element = FALSE;
element_info[element].gfx_element = EL_EMPTY_SPACE;