From f606a1752d00ce343e9dfdf425e0e8000e24352d Mon Sep 17 00:00:00 2001 From: Dario Sassi Date: Sat, 22 Apr 2017 08:41:44 +0000 Subject: [PATCH] EgtDOORCreator 1.8d2 : - aggiunto controllo di abilitazione specifico del prodotto - migliorata gestione chiave non presente. --- EgtDOORCreator.vbproj | 4 ++-- IniFile.vb | 8 ++++++-- My Project/AssemblyInfo.vb | 6 +++--- ProjectManager/ProjectManagerViewModel.vb | 2 +- SceneManager/SceneManagerViewModel.vb | 11 ++++++----- 5 files changed, 18 insertions(+), 13 deletions(-) diff --git a/EgtDOORCreator.vbproj b/EgtDOORCreator.vbproj index abc0ad7..c5c9696 100644 --- a/EgtDOORCreator.vbproj +++ b/EgtDOORCreator.vbproj @@ -41,13 +41,13 @@ - true + false bin\x86\Release\ EgtDOORCreator.xml true - pdbonly + None x86 MinimumRecommendedRules.ruleset true diff --git a/IniFile.vb b/IniFile.vb index 5c9cb27..b767d66 100644 --- a/IniFile.vb +++ b/IniFile.vb @@ -16,8 +16,12 @@ Friend Module IniFile Friend m_nKeyLevel As Integer = 0 ' Opzioni attive sulla chiave Friend m_nKeyOptions As UInteger = 0 - - + Friend Enum KEY_OPT As UInteger + BASE = 1 + DOORS = 2 + GUNSTOCK = 4 + DOORCREATOR = 8 + End Enum Friend m_sConfigDir As String = String.Empty ' Path IniFile Friend m_sIniFile As String = String.Empty diff --git a/My Project/AssemblyInfo.vb b/My Project/AssemblyInfo.vb index a3f34c6..d0c9055 100644 --- a/My Project/AssemblyInfo.vb +++ b/My Project/AssemblyInfo.vb @@ -32,7 +32,7 @@ Imports System.Windows - + @@ -72,5 +72,5 @@ Imports System.Windows ' by using the '*' as shown below: ' - - + + diff --git a/ProjectManager/ProjectManagerViewModel.vb b/ProjectManager/ProjectManagerViewModel.vb index b2ae843..e9c3c02 100644 --- a/ProjectManager/ProjectManagerViewModel.vb +++ b/ProjectManager/ProjectManagerViewModel.vb @@ -474,7 +474,7 @@ Public Class ProjectManagerViewModel ' preparo la mail per il supporto Dim bEx As Boolean = False Try - Dim SendFeedbackWindow As New EgtWPFLib5.MapiMailMessage("EgtCAM5 Feedback - " & sKey) + Dim SendFeedbackWindow As New EgtWPFLib5.MapiMailMessage("EgtDOORCreator Feedback - " & sKey) SendFeedbackWindow.Recipients.Add(sSupportAddress) If Not String.IsNullOrWhiteSpace(sZipToCreate) AndAlso File.Exists(sZipToCreate) Then SendFeedbackWindow.Files.Add(IniFile.m_sTempDir & "\Feedback.zip") diff --git a/SceneManager/SceneManagerViewModel.vb b/SceneManager/SceneManagerViewModel.vb index a9610d9..8f64223 100644 --- a/SceneManager/SceneManagerViewModel.vb +++ b/SceneManager/SceneManagerViewModel.vb @@ -100,12 +100,13 @@ Public Class SceneManagerViewModel ' Box di avviso chiave mancante MessageBox.Show(EgtMsg(MSG_MISSINGKEYWD + 2) & vbCrLf & EgtMsg(MSG_MISSINGKEYWD + 3), EgtMsg(MSG_MISSINGKEYWD + 1), MessageBoxButton.OK, MessageBoxImage.Error) ' Chiudo il programma - - ' ' Verifico abilitazione prodotto - 'ElseIf (IniFile.m_nKeyOptions And KEY_OPT.BASE) = 0 Then - ' MsgBox(EgtMsg(MSG_MISSINGKEYWD + 5), MsgBoxStyle.OkOnly, EgtMsg(MSG_MISSINGKEYWD + 1)) + Application.Current.Shutdown() + ' Verifico abilitazione prodotto + ElseIf (IniFile.m_nKeyOptions And KEY_OPT.DOORCREATOR) = 0 Then + MsgBox(EgtMsg(MSG_MISSINGKEYWD + 5), MsgBoxStyle.OkOnly, EgtMsg(MSG_MISSINGKEYWD + 1)) ' Chiudo il programma - + Application.Current.Shutdown() + ' Tutto bene Else EgtSetCurrentContext(m_ProjectScene.GetCtx) PostInitializeScene()