02.08.2023

This commit is contained in:
Jonathan Jenne
2023-08-02 12:05:51 +02:00
parent 13cf091d8e
commit c8b2f21fea
12 changed files with 212 additions and 75 deletions

View File

@@ -22,11 +22,12 @@ Public Class FieldEditorController
ElementModel = New ElementModel(pState)
End Sub
Public Sub AddOrUpdateElement(pAnnotation As AnnotationStickyNote, pReceiverId As Integer)
Public Sub AddOrUpdateElement(pAnnotation As AnnotationStickyNote)
Dim oTag As String() = pAnnotation.Tag.Split("|"c)
Dim oPage = Integer.Parse(oTag(0))
Dim oIndex = Integer.Parse(oTag(1))
Dim oELement = Elements.Where(Function(e) e.AnnotationIndex = oIndex And e.Page = oPage).SingleOrDefault()
Dim oReceiverId = Integer.Parse(oTag(0))
Dim oPage = Integer.Parse(oTag(1))
Dim oIndex = Integer.Parse(oTag(2))
Dim oELement = Elements.Where(Function(e) e.AnnotationIndex = oIndex And e.Page = oPage And e.ReceiverId = oReceiverId).SingleOrDefault()
If oELement IsNot Nothing Then
oELement.Height = pAnnotation.Height
@@ -41,7 +42,7 @@ Public Class FieldEditorController
.X = pAnnotation.Left,
.Y = pAnnotation.Top,
.DocumentId = Document.Id,
.ReceiverId = pReceiverId,
.ReceiverId = oReceiverId,
.AnnotationIndex = oIndex,
.Page = oPage
})