upgrade to .net6 part 2
This commit is contained in:
@@ -11,6 +11,7 @@ Imports OpenTK.Mathematics
|
|||||||
Imports OpenTK.WinForms
|
Imports OpenTK.WinForms
|
||||||
Imports OpenTK.Input
|
Imports OpenTK.Input
|
||||||
Imports OpenTK.Windowing.GraphicsLibraryFramework
|
Imports OpenTK.Windowing.GraphicsLibraryFramework
|
||||||
|
Imports Key = OpenTK3.Input.Key
|
||||||
|
|
||||||
Namespace PreviewN
|
Namespace PreviewN
|
||||||
|
|
||||||
@@ -31,6 +32,12 @@ Namespace PreviewN
|
|||||||
Public Property Scaling As Single = 500.0F
|
Public Property Scaling As Single = 500.0F
|
||||||
Public Property ClearColor As Color = Color.CornflowerBlue
|
Public Property ClearColor As Color = Color.CornflowerBlue
|
||||||
|
|
||||||
|
Public ReadOnly Property Keyboard As OpenTK3.Input.KeyboardState
|
||||||
|
Get
|
||||||
|
Return OpenTK3.Input.Keyboard.GetState
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
Public Property EnableCameraControlling As Boolean
|
Public Property EnableCameraControlling As Boolean
|
||||||
Get
|
Get
|
||||||
Return _EnableCameraControlling
|
Return _EnableCameraControlling
|
||||||
@@ -82,14 +89,14 @@ Namespace PreviewN
|
|||||||
|
|
||||||
Private ReadOnly Property IsStrgPressed As Boolean
|
Private ReadOnly Property IsStrgPressed As Boolean
|
||||||
Get
|
Get
|
||||||
Dim state As KeyboardState = Keyboard.GetState()
|
Dim state = Keyboard
|
||||||
Return state(Key.ControlLeft) OrElse state(Key.ControlRight)
|
Return state(Key.ControlLeft) OrElse state(Key.ControlRight)
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Private ReadOnly Property IsShiftPressed As Boolean
|
Private ReadOnly Property IsShiftPressed As Boolean
|
||||||
Get
|
Get
|
||||||
Dim state As KeyboardState = Keyboard.GetState()
|
Dim state = Keyboard
|
||||||
Return state(Key.ShiftLeft) OrElse state(Key.ShiftRight)
|
Return state(Key.ShiftLeft) OrElse state(Key.ShiftRight)
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
@@ -286,7 +293,7 @@ Namespace PreviewN
|
|||||||
Dim allowCamMove As Boolean = Not (IsMouseDown AndAlso IsShiftPressed)
|
Dim allowCamMove As Boolean = Not (IsMouseDown AndAlso IsShiftPressed)
|
||||||
|
|
||||||
If allowCamMove Then
|
If allowCamMove Then
|
||||||
Dim state As KeyboardState = Keyboard.GetState
|
Dim state = Keyboard
|
||||||
|
|
||||||
If state(Key.W) Then
|
If state(Key.W) Then
|
||||||
'camera.Move(moveSpeed, moveSpeed, camMtx)
|
'camera.Move(moveSpeed, moveSpeed, camMtx)
|
||||||
|
|||||||
@@ -1,9 +1,13 @@
|
|||||||
Imports System.Drawing
|
Imports System.Drawing
|
||||||
Imports System.Threading
|
Imports System.Threading
|
||||||
Imports System.Windows.Forms
|
Imports System.Windows.Forms
|
||||||
|
|
||||||
Imports OpenTK
|
Imports OpenTK
|
||||||
Imports OpenTK.Graphics.OpenGL
|
Imports OpenTK.Graphics.OpenGL
|
||||||
|
Imports OpenTK.Mathematics
|
||||||
|
|
||||||
Imports Pilz.S3DFileParser
|
Imports Pilz.S3DFileParser
|
||||||
|
|
||||||
Imports Bitmap = System.Drawing.Bitmap
|
Imports Bitmap = System.Drawing.Bitmap
|
||||||
Imports Color = System.Drawing.Color
|
Imports Color = System.Drawing.Color
|
||||||
Imports Image = System.Drawing.Image
|
Imports Image = System.Drawing.Image
|
||||||
|
|||||||
@@ -5,6 +5,7 @@
|
|||||||
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
|
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
|
||||||
<DocumentationFile>Pilz.Networking.xml</DocumentationFile>
|
<DocumentationFile>Pilz.Networking.xml</DocumentationFile>
|
||||||
<DefineTrace>true</DefineTrace>
|
<DefineTrace>true</DefineTrace>
|
||||||
|
<UseWindowsForms>true</UseWindowsForms>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
<DefineDebug>true</DefineDebug>
|
<DefineDebug>true</DefineDebug>
|
||||||
@@ -25,6 +26,7 @@
|
|||||||
<OptionInfer>On</OptionInfer>
|
<OptionInfer>On</OptionInfer>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Microsoft.VisualBasic" Version="10.3.0" />
|
||||||
<PackageReference Include="System.Data.DataSetExtensions" Version="4.5.0" />
|
<PackageReference Include="System.Data.DataSetExtensions" Version="4.5.0" />
|
||||||
<PackageReference Include="System.Net.Http" Version="4.3.4" />
|
<PackageReference Include="System.Net.Http" Version="4.3.4" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|||||||
Reference in New Issue
Block a user