Public Sub Initialize
Private getFormPosition() As String = Regex.Split(",", func.getFormPosition)
form.Initialize("form", getFormPosition(2), getFormPosition(3))
form.Title="test"
form.Icon = fx.LoadImage(File.DirAssets, "icon.png")
func.CenterForm(form)
form.Show
FixedWidth=form.WindowWidth
FixedHeight=form.WindowHeight
End Sub
Sub IsMaximized(frm As Form) As Boolean
Dim joForm As JavaObject = frm
Dim joStage As JavaObject = joForm.GetField("stage")
Dim Maximized As Boolean = joStage.RunMethod("isMaximized", Null)
Return Maximized
End Sub
Private Sub form_Resize (Width As Double, Height As Double)
If Not(IsMaximized(form)) Then
If form.Width<>FixedWidth Or form.Height<>FixedHeight Then
form.WindowWidth = FixedWidth
form.WindowHeight = FixedHeight
End If
End If
End Sub