This commit is contained in:
Jonathan Jenne 2023-12-07 14:50:24 +01:00
parent b2f6076fb2
commit dbeabab832
2 changed files with 11 additions and 11 deletions

View File

@ -128,13 +128,12 @@ Partial Public Class frmEnvelopeEditor
Dim oDocument As EnvelopeDocument = DirectCast(ViewDocuments.GetFocusedRow(), EnvelopeDocument)
Dim oGDPictureKey As String = "21182889975216572111813147150675976632"
Dim oForm As New frmFieldEditor() With {
Dim oForm As New frmFieldEditor(State) With {
.Document = Controller.Envelope.Documents.
Where(Function(d) d.Filename = oDocument.Filename).
SingleOrDefault(),
.GDPictureKey = oGDPictureKey,
.Receivers = Controller.Envelope.Receivers.ToList,
.State = State
.Receivers = Controller.Envelope.Receivers.ToList
}
oForm.ShowDialog()

View File

@ -10,8 +10,9 @@ Imports GdPicture14
Imports GdPicture14.Annotations
Partial Public Class frmFieldEditor
Private LogConfig As LogConfig
Private Logger As Logger
Private ReadOnly LogConfig As LogConfig
Private ReadOnly Logger As Logger
Public ReadOnly Property State As State
Private GDViewer As GdViewer
Private Manager As AnnotationManager
@ -21,7 +22,6 @@ Partial Public Class frmFieldEditor
Public Property GDPictureKey As String = ""
Public Property Receivers As List(Of EnvelopeReceiver)
Public Property SelectedReceiver As EnvelopeReceiver = Nothing
Public Property State As State
Private UnsavedChanges As Boolean = False
@ -29,15 +29,16 @@ Partial Public Class frmFieldEditor
Private Const SIGNATURE_WIDTH As Single = 1
Private Const SIGNATURE_HEIGHT As Single = 0.5
Public Sub New()
Public Sub New(pState As State)
InitializeComponent()
LogConfig = pState.LogConfig
Logger = pState.LogConfig.GetLogger()
State = pState
End Sub
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles Me.Load
LogConfig = New LogConfig(LogConfig.PathType.CustomPath, Application.StartupPath, CompanyName:="Digital Data", ProductName:="EnvelopeGenerator")
Logger = LogConfig.GetLogger()
Me.Text = State.DbConfig.ExternalProgramName + " - Signatur-Editor"
Text = $"{State.DbConfig.ExternalProgramName} - {Resources.Envelope.Signature_Editor}"
If Document Is Nothing Then
Throw New ArgumentNullException("Document")