version 1.136, 2007/04/26 10:38:16
|
version 1.137, 2007/04/26 15:13:52
|
Line 364 void AllowReloadingTemplate(char* templa
|
Line 364 void AllowReloadingTemplate(char* templa
|
} |
} |
|
|
|
|
|
/*---------------------------------------------------------------------- |
|
----------------------------------------------------------------------*/ |
ThotBool isEOSorWhiteSpace (const char c) |
ThotBool isEOSorWhiteSpace (const char c) |
{ |
{ |
return c == SPACE || c == '\t' || c == '\n' || c == EOS; |
return c == SPACE || c == TAB || c == EOL || c ==__CR__ || c == EOS; |
|
} |
|
ThotBool isWhiteSpace (const char c) |
|
{ |
|
return c == SPACE || c == TAB || c == EOL || c ==__CR__; |
} |
} |
|
|
/*---------------------------------------------------------------------- |
/*---------------------------------------------------------------------- |
Line 408 void giveItems (char *text, int size, st
|
Line 414 void giveItems (char *text, int size, st
|
for (i = 0; i < *nbitems; i++) |
for (i = 0; i < *nbitems; i++) |
{ |
{ |
labelSize = 0; |
labelSize = 0; |
while (isEOSorWhiteSpace (*iter)) |
while (isWhiteSpace (*iter)) |
iter++; |
iter++; |
|
if (*iter != EOS) |
while (!isEOSorWhiteSpace (*iter)) |
|
{ |
{ |
temp[labelSize++] = *iter; |
while (!isEOSorWhiteSpace (*iter)) |
iter++; |
{ |
} |
temp[labelSize++] = *iter; |
|
iter++; |
|
} |
|
|
temp[labelSize] = EOS; |
temp[labelSize] = EOS; |
menu[i].label = (char *) TtaStrdup (temp); |
menu[i].label = (char *) TtaStrdup (temp); |
menu[i].type = SimpleTypeNat; /* @@@@@ ???? @@@@@ */ |
menu[i].type = SimpleTypeNat; /* @@@@@ ???? @@@@@ */ |
*items = menu; |
} |
} |
} |
|
*items = menu; |
#endif /* TEMPLATES */ |
#endif /* TEMPLATES */ |
} |
} |
|
|
Line 851 ThotBool RepeatButtonClicked (NotifyElem
|
Line 859 ThotBool RepeatButtonClicked (NotifyElem
|
{ |
{ |
listtypes = Template_ExpandTypes(t, types); |
listtypes = Template_ExpandTypes(t, types); |
result = QueryStringFromMenu(doc, listtypes); |
result = QueryStringFromMenu(doc, listtypes); |
|
TtaFreeMemory(listtypes); |
if (result) |
if (result) |
{ |
{ |
decl = Template_GetDeclaration(t, result); |
decl = Template_GetDeclaration(t, result); |
Line 884 ThotBool RepeatButtonClicked (NotifyElem
|
Line 893 ThotBool RepeatButtonClicked (NotifyElem
|
} |
} |
} |
} |
} |
} |
// TtaFreeMemory(listtypes); |
|
} |
} |
TtaFreeMemory(types); |
TtaFreeMemory(types); |
TtaFreeMemory(result); |
TtaFreeMemory(result); |