X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=xgamelist.c;h=54f417d33e6000f3ea649dbd8407cae9bab9589d;hb=29f26a97a226db6e7bdd0927e67cf5a5ce3dd065;hp=9784bf7ae00f666db1a8bf338b31a2bcec282c8a;hpb=848e9dfc57a2db0255eb1adbd2c01c61fe26c4ed;p=xboard.git diff --git a/xgamelist.c b/xgamelist.c index 9784bf7..54f417d 100644 --- a/xgamelist.c +++ b/xgamelist.c @@ -335,11 +335,9 @@ GameListPrepare(int byPos) int nstrings; ListGame *lg; char **st, *line; -struct { - long sec; /* Assuming this is >= 32 bits */ - int ms; /* Assuming this is >= 16 bits */ -} t,t2; GetTimeMark(&t); + TimeMark t, t2; + GetTimeMark(&t); if(st = glc->strings) while(*st) free(*st++); nstrings = ((ListGame *) gameList.tailPred)->number; glc->strings = (char **) malloc((nstrings + 1) * sizeof(char *)); @@ -394,7 +392,7 @@ GameListReplace(int page) XawListChange(listwidg, list, 0, 0, True); XtSetValues(listwidg, &arg, 1); XawListHighlight(listwidg, 0); - snprintf(buf, MSG_SIZ, "%s- %d/%d games (%d-%d-%d)", glc->filename, listLength, ((ListGame *) gameList.tailPred)->number, wins, losses, draws); + snprintf(buf, MSG_SIZ, _("%s - %d/%d games (%d-%d-%d)"), glc->filename, listLength, ((ListGame *) gameList.tailPred)->number, wins, losses, draws); XtSetArg(arg, XtNtitle, buf); XtSetValues(glc->shell, &arg, 1); } @@ -481,6 +479,8 @@ GameListPopUp(fp, filename) if (glc == NULL) { glc = (GameListClosure *) calloc(1, sizeof(GameListClosure)); glc->x = glc->y = -1; + glc->filename = NULL; + glc->shell = NULL; } GameListPrepare(False); // [HGM] filter: code put in separate routine @@ -490,7 +490,6 @@ GameListPopUp(fp, filename) if (glc->filename != NULL) free(glc->filename); glc->filename = StrSave(filename); - if (glc->shell == NULL) { glc->shell = GameListCreate(filename, GameListCallback, glc); } else {