From 71cfa4fb7948389de61408c53cb13d693d3c41a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ji=C5=99=C3=AD=20Klime=C5=A1?= Date: Fri, 11 Dec 2015 15:14:59 +0100 Subject: [PATCH] tui: prefill a secret in the entry if we have a value (cherry picked from commit a1536fe3d1ca85f321b6498d884a38eacf02de90) --- clients/tui/nmt-password-dialog.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/clients/tui/nmt-password-dialog.c b/clients/tui/nmt-password-dialog.c index aeece1211f..bf29dcf5a1 100644 --- a/clients/tui/nmt-password-dialog.c +++ b/clients/tui/nmt-password-dialog.c @@ -154,6 +154,8 @@ nmt_password_dialog_constructed (GObject *object) if (secret->password) flags |= NMT_NEWT_ENTRY_PASSWORD; widget = nmt_newt_entry_new (30, flags); + if (secret->value) + nmt_newt_entry_set_text (NMT_NEWT_ENTRY (widget), secret->value); nmt_newt_grid_add (secret_grid, widget, 1, i); g_ptr_array_add (priv->entries, widget);