From bbecbd01cb9e669cc2dec42a71f68e49df21cf01 Mon Sep 17 00:00:00 2001 From: Dario Sassi Date: Mon, 10 Apr 2017 07:54:45 +0000 Subject: [PATCH] EgtUILib 1.8d1 : - In New, Open, Insert and Import delegato zoom a eventi On.. chiamati alla fine. --- Controller.vb | 19 ++++++++----------- My Project/AssemblyInfo.vb | 4 ++-- 2 files changed, 10 insertions(+), 13 deletions(-) diff --git a/Controller.vb b/Controller.vb index f3751f7..365b3fe 100644 --- a/Controller.vb +++ b/Controller.vb @@ -22,6 +22,7 @@ Public Class Controller Public Event OnNewProject(ByVal sender As Object, ByVal bOk As Boolean) Public Event OnOpeningProject(ByVal sender As Object) Public Event OnOpenProject(ByVal sender As Object, ByVal sFile As String, ByVal bOk As Boolean) + Public Event OnInsertedProject(ByVal sender As Object, ByVal sFile As String, ByVal bOk As Boolean) Public Event OnSavingProject(ByVal sender As Object) Public Event OnSavedProject(ByVal sender As Object, ByVal sFile As String, ByVal bOk As Boolean) Public Event OnSavingObject(ByVal sender As Object) @@ -222,8 +223,6 @@ Public Class Controller EgtResetModified() End If DisableCommandLog() - ' aggiorno - EgtZoom(ZM.ALL) RaiseEvent UpdateUI(Me, True) ' Gestione risultato RaiseEvent OnNewProject(Me, bOk) @@ -259,11 +258,10 @@ Public Class Controller EnableCommandLog() Dim bOk As Boolean = EgtOpenFile(sFile) DisableCommandLog() - EgtZoom(ZM.ALL) m_Scene.Cursor = Cursors.Default ' Aggiornamento RaiseEvent UpdateUI(Me, True) - 'Gestione risultato + ' Gestione risultato RaiseEvent OnOpenProject(Me, sFile, bOk) Return bOk End Function @@ -302,10 +300,11 @@ Public Class Controller EgtResetCurrPartLayer() End If DisableCommandLog() - EgtZoom(ZM.ALL) m_Scene.Cursor = Cursors.Default ' Aggiornamento RaiseEvent UpdateUI(Me, True) + ' Gestione risultato + RaiseEvent OnInsertedProject(Me, sFile, bOk) Return bOk End Function @@ -471,11 +470,10 @@ Public Class Controller End If EgtResetCurrPartLayer() DisableCommandLog() - EgtZoom(ZM.ALL) m_Scene.Cursor = Cursors.Default ' Aggiornamento RaiseEvent UpdateUI(Me, True) - 'Gestione risultato + ' Gestione risultato RaiseEvent OnImportedProject(Me, sFile, bOk) Return bOk End Function @@ -546,7 +544,7 @@ Public Class Controller End If 'Ne verifico il tipo Dim sExt As String = UCase(IO.Path.GetExtension(sFile)) - If (sExt <> ".LUA" And sExt <> ".TSC") Then + If sExt <> ".LUA" And sExt <> ".TSC" Then MessageBox.Show("Script type unknow", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error) Return False End If @@ -556,20 +554,19 @@ Public Class Controller m_Scene.Cursor = Cursors.WaitCursor EnableCommandLog() Dim bOk As Boolean = False - If (sExt = ".LUA") Then + If sExt = ".LUA" Then bOk = EgtLuaExecFile(sFile) Else bOk = EgtTscExecFile(sFile) End If DisableCommandLog() - ' EgtZoom(ZM.ALL) m_Scene.Cursor = Cursors.Default ' Aggiornamento RaiseEvent UpdateUI(Me, True) 'Gestione risultato Dim sError As String = String.Empty If Not bOk Then - If (sExt = ".LUA") Then + If sExt = ".LUA" Then EgtLuaGetLastError(sError) Else sError = "Error executing script" diff --git a/My Project/AssemblyInfo.vb b/My Project/AssemblyInfo.vb index 01d5194..3643b6e 100644 --- a/My Project/AssemblyInfo.vb +++ b/My Project/AssemblyInfo.vb @@ -35,5 +35,5 @@ Imports System.Runtime.InteropServices ' È possibile specificare tutti i valori oppure impostare valori predefiniti per i numeri relativi alla revisione e alla build ' utilizzando l'asterisco (*) come descritto di seguito: - - + +