diff --git a/My Project/AssemblyInfo.vb b/My Project/AssemblyInfo.vb index e8619ee..71c2f49 100644 --- a/My Project/AssemblyInfo.vb +++ b/My Project/AssemblyInfo.vb @@ -46,5 +46,5 @@ Imports System.Runtime.InteropServices ' utilizzando l'asterisco (*) come descritto di seguito: ' - - + + diff --git a/Scene.vb b/Scene.vb index 5d98d40..8dbb069 100644 --- a/Scene.vb +++ b/Scene.vb @@ -224,8 +224,14 @@ Public Class Scene Public Event OnChangedSnapPointType(ByVal sender As Object, ByVal nSpType As SP, ByVal bForced As Boolean) '---- Mouse ----------- + Private m_bSetFocusOnMove As Boolean = True + ' Per correggere un problema con hot spot cursore, nei file cur รจ stato spostato di 4 pixel in Y+ (in basso) + Public Sub SetFocusOnMove(ByVal bVal As Boolean) + m_bSetFocusOnMove = bVal + End Sub + Protected Overrides Sub OnMouseDown(e As System.Windows.Forms.MouseEventArgs) ' Imposto il contesto della scena come corrente EgtSetCurrentContext(m_nGseContext) @@ -486,10 +492,12 @@ Public Class Scene EgtSetCurrentContext(m_nGseContext) End If ' Se sono abbastanza all'interno della scena (10% della dimensione), imposto il focus - Const BordPu As Double = 0.10000000000000001 - If e.Location.X > BordPu * Size.Width AndAlso e.Location.X < (1 - BordPu) * Size.Width AndAlso - e.Location.Y > BordPu * Size.Height AndAlso e.Location.Y < (1 - BordPu) * Size.Height Then - Focus() + If m_bSetFocusOnMove Then + Const BordPu As Double = 0.1 + If e.Location.X > BordPu * Size.Width AndAlso e.Location.X < (1 - BordPu) * Size.Width AndAlso + e.Location.Y > BordPu * Size.Height AndAlso e.Location.Y < (1 - BordPu) * Size.Height Then + Focus() + End If End If ' Visualizzo le coordinate del mouse ShowCursorPos(e.Location)