From: Theodore Tso Date: Sat, 10 Apr 1999 02:58:18 +0000 (+0000) Subject: gic.c (gic_prompter), vardlg.c (vardlg_build), gic.h, vardlg.h: Update X-Git-Tag: krb5-1.1-beta1~235 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=d7d6e9a4abb3c4ea400a19d2f00f71ce76f55d37;p=krb5.git gic.c (gic_prompter), vardlg.c (vardlg_build), gic.h, vardlg.h: Update to use new prompter prototype which takes an extra argument for the window titlebar name. (From Frank Cusack) [krb5-kdc/662] git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@11350 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/windows/lib/ChangeLog b/src/windows/lib/ChangeLog index 2ef32b09a..686fb7e78 100644 --- a/src/windows/lib/ChangeLog +++ b/src/windows/lib/ChangeLog @@ -1,3 +1,10 @@ +1999-04-01 Theodore Ts'o + + * gic.c (gic_prompter), vardlg.c (vardlg_build), gic.h, vardlg.h: + Update to use new prompter prototype which takes an extra + argument for the window titlebar name. (From Frank + Cusack) [krb5-kdc/662] + Fri Mar 12 15:54:17 1999 Theodore Y. Ts'o * Makefile.in (clean-windows): Don't blow away Krbcc32.lib by diff --git a/src/windows/lib/gic.c b/src/windows/lib/gic.c index 35ac8a86f..51e752dc0 100644 --- a/src/windows/lib/gic.c +++ b/src/windows/lib/gic.c @@ -131,8 +131,8 @@ gic_dialog(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) * broken environment */ krb5_error_code KRB5_CALLCONV -gic_prompter(krb5_context ctx, void *data, const char *banner, - int num_prompts, krb5_prompt prompts[]) +gic_prompter(krb5_context ctx, void *data, const char *name, + const char *banner, int num_prompts, krb5_prompt prompts[]) { int rc; void *dlg; @@ -145,7 +145,8 @@ gic_prompter(krb5_context ctx, void *data, const char *banner, if (gd->width == 0) gd->width = 450; - dlg = vardlg_build((WORD)(gd->width), gd->banner, (WORD)num_prompts, prompts, (WORD)(gd->id)); + dlg = vardlg_build((WORD)(gd->width), name, gd->banner, + (WORD)num_prompts, prompts, (WORD)(gd->id)); rc = DialogBoxIndirect(gd->hinstance, (LPDLGTEMPLATE)dlg, gd->hwnd, gic_dialog); diff --git a/src/windows/lib/gic.h b/src/windows/lib/gic.h index ddea368e4..23213163d 100644 --- a/src/windows/lib/gic.h +++ b/src/windows/lib/gic.h @@ -23,6 +23,6 @@ typedef struct { } gic_data; krb5_error_code KRB5_CALLCONV gic_prompter(krb5_context, void *, const char *, - int, krb5_prompt []); + const char *, int, krb5_prompt []); #endif /* _WINDOWS_LIB_GIC_H */ diff --git a/src/windows/lib/vardlg.c b/src/windows/lib/vardlg.c index 41d897bf7..dae8cdbbc 100644 --- a/src/windows/lib/vardlg.c +++ b/src/windows/lib/vardlg.c @@ -171,8 +171,8 @@ ADD_DLGITEM(unsigned char *dlg, short x, short y, short cx, short cy, * fields for each item. */ void * -vardlg_build(WORD cx, const char *banner, WORD n, krb5_prompt prompts[], - WORD id) +vardlg_build(WORD cx, const char *name, const char *banner, + WORD n, krb5_prompt prompts[], WORD id) { unsigned char *p; WORD i; @@ -187,7 +187,10 @@ vardlg_build(WORD cx, const char *banner, WORD n, krb5_prompt prompts[], /* * Store the dialog template */ - p += ADD_DLGTEMPLATE(p, 0, 0, cx, 0, "KerbNet", "MS Sans Serif", 8, + p += ADD_DLGTEMPLATE(p, 0, 0, cx, 0, name ? + strlen(name) < 30 ? name : "Kerberos V5" : + "Kerberos V5", + "MS Sans Serif", 8, (WORD)(n * 2 + 3)); /* diff --git a/src/windows/lib/vardlg.h b/src/windows/lib/vardlg.h index e832e51de..e609d4a1d 100644 --- a/src/windows/lib/vardlg.h +++ b/src/windows/lib/vardlg.h @@ -25,7 +25,7 @@ * If there are items, we also create a Cancel button and one (label, entry) * fields for each item. */ -void *vardlg_build(WORD, const char *, WORD, krb5_prompt *, WORD); +void *vardlg_build(WORD, const char *, const char *, WORD, krb5_prompt *, WORD); void vardlg_config(HWND, WORD, const char *, WORD, krb5_prompt *, WORD);