From eb5261da229fbbd08f2f60f603b723aabc8cc157 Mon Sep 17 00:00:00 2001 From: soramimi Date: Tue, 16 Jan 2024 22:48:29 +0900 Subject: [PATCH] =?UTF-8?q?GPG=E5=AF=BE=E5=BF=9C=20(wip)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/CommitPropertyDialog.cpp | 12 +++---- src/CommitPropertyDialog.ui | 68 ++++++++++++++++++++++-------------- 2 files changed, 47 insertions(+), 33 deletions(-) diff --git a/src/CommitPropertyDialog.cpp b/src/CommitPropertyDialog.cpp index 6ef8ca6b..8c16ebb8 100644 --- a/src/CommitPropertyDialog.cpp +++ b/src/CommitPropertyDialog.cpp @@ -77,10 +77,10 @@ void CommitPropertyDialog::init(MainWindow *mw) auto s = mainwindow()->git()->log_show_signature(m->commit.commit_id); if (s) { sig = *s; - int n = sig.fingerprint.size(); - if (n > 0) { - QList keys; - if (gpg::listKeys(global->appsettings.gpg_command, &keys)) { + QList keys; + if (gpg::listKeys(global->appsettings.gpg_command, &keys)) { + int n = sig.fingerprint.size(); + if (n > 0) { for (gpg::Data const &key : keys) { if (n == key.fingerprint.size()) { auto const *p1 = sig.fingerprint.data(); @@ -135,8 +135,8 @@ void CommitPropertyDialog::updateAvatar(bool request) widget->setVisible(false); } }; - // SetAvatar(ui->lineEdit_mail->text(), ui->widget_user_avatar); - // SetAvatar(ui->lineEdit_sign_mail->text(), ui->widget_sign_avatar); + SetAvatar(ui->lineEdit_mail->text(), ui->widget_user_avatar); + SetAvatar(ui->lineEdit_sign_mail->text(), ui->widget_sign_avatar); } void CommitPropertyDialog::avatarReady() diff --git a/src/CommitPropertyDialog.ui b/src/CommitPropertyDialog.ui index 6f6e6373..61d96c5e 100644 --- a/src/CommitPropertyDialog.ui +++ b/src/CommitPropertyDialog.ui @@ -131,37 +131,51 @@ - - - - - ID - - - - - - - - - - Name - - + + + + + + + ID + + + + + + + + + + Name + + + + + + + + + + Mail + + + + + + + - - - - - - - Mail + + + + + 80 + 80 + - - -