VerifyDigitalSignatureControl.xaml.cs 874 B

123456789101112131415161718192021222324252627282930
  1. using System;
  2. using System.Windows;
  3. using Compdfkit_Tools.PDFControl;
  4. using ComPDFKit.DigitalSign;
  5. namespace Compdfkit_Tools.PDFControl
  6. {
  7. public partial class VerifyDigitalSignatureControl : Window
  8. {
  9. private CPDFSignature signature;
  10. public event EventHandler<CPDFSignature> ViewCertificateEvent;
  11. public VerifyDigitalSignatureControl()
  12. {
  13. InitializeComponent();
  14. }
  15. public void InitWithSignature(CPDFSignature signature)
  16. {
  17. DigitalSignatureInfoControl.InitWithSignature(signature);
  18. DigitalSignatureValiditySummaryControl.InitWithSignature(signature);
  19. this.signature = signature;
  20. }
  21. private void ViewCertificates_OnClick(object sender, RoutedEventArgs e)
  22. {
  23. ViewCertificateEvent?.Invoke(this, signature);
  24. }
  25. }
  26. }