From 2256237cd9ce65d7dad3d4309440a78f4ab4f347 Mon Sep 17 00:00:00 2001 From: Pavel Roskin Date: Thu, 27 Nov 2003 09:55:15 +0000 Subject: [PATCH] * wtools.c (quick_dialog_skip): Perform tilde expansion on input widgets that use cd completion. --- src/ChangeLog | 3 +++ src/wtools.c | 9 +++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 25c339420..70dba06ed 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,8 @@ 2003-11-27 Pavel Roskin + * wtools.c (quick_dialog_skip): Perform tilde expansion on input + widgets that use cd completion. + * utilunix.c (tilde_expand): Preserve tilde if the username could not be found. Don't ever return NULL. Change callers not to check for NULL. diff --git a/src/wtools.c b/src/wtools.c index bfb0ba014..e4dd6cc30 100644 --- a/src/wtools.c +++ b/src/wtools.c @@ -316,7 +316,8 @@ quick_dialog_skip (QuickDialog *qd, int nskip) if (qd->xpos == -1) dd = create_dlg (0, 0, qd->ylen, qd->xlen, dialog_colors, NULL, - qd->help, qd->title, DLG_CENTER | DLG_TRYUP | DLG_REVERSE); + qd->help, qd->title, + DLG_CENTER | DLG_TRYUP | DLG_REVERSE); else dd = create_dlg (qd->ypos, qd->xpos, qd->ylen, qd->xlen, dialog_colors, NULL, qd->help, qd->title, @@ -401,7 +402,11 @@ quick_dialog_skip (QuickDialog *qd, int nskip) break; case quick_input: - *qw->str_result = g_strdup (((WInput *) w)->buffer); + if (qw->value & 2) + *qw->str_result = + tilde_expand (((WInput *) w)->buffer); + else + *qw->str_result = g_strdup (((WInput *) w)->buffer); break; } }