|
|
@@ -23,6 +23,9 @@ Class MainWindow
|
|
|
|
' Coefficiente di scalatura della finestra rispetto a standard
|
|
|
|
' Coefficiente di scalatura della finestra rispetto a standard
|
|
|
|
Friend m_dMWinScale As Double = 1
|
|
|
|
Friend m_dMWinScale As Double = 1
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
' Variabile che definisce l'avvio forzato in modalità FRAME
|
|
|
|
|
|
|
|
Friend m_OnlyFrame As Boolean = False
|
|
|
|
|
|
|
|
|
|
|
|
' Dichiarazione delle Page UserControl
|
|
|
|
' Dichiarazione delle Page UserControl
|
|
|
|
Friend m_WorkInProgressPageUC As WorkInProgressPageUC
|
|
|
|
Friend m_WorkInProgressPageUC As WorkInProgressPageUC
|
|
|
|
Friend m_CurrentProjectPageUC As CurrentProjectPageUC
|
|
|
|
Friend m_CurrentProjectPageUC As CurrentProjectPageUC
|
|
|
@@ -101,6 +104,7 @@ Class MainWindow
|
|
|
|
REGISTRATION = 2 ^ 20 ' 1048576
|
|
|
|
REGISTRATION = 2 ^ 20 ' 1048576
|
|
|
|
SIMPLESTATISTICS = 2 ^ 21 ' 2097152
|
|
|
|
SIMPLESTATISTICS = 2 ^ 21 ' 2097152
|
|
|
|
COMPOFRAME = 2 ^ 22 ' 4194304
|
|
|
|
COMPOFRAME = 2 ^ 22 ' 4194304
|
|
|
|
|
|
|
|
CUT_LIGHT = 2 ^ 23 ' 8388608
|
|
|
|
End Enum
|
|
|
|
End Enum
|
|
|
|
' Opzione nesting automatico
|
|
|
|
' Opzione nesting automatico
|
|
|
|
Private m_bAutoNest As Boolean = False
|
|
|
|
Private m_bAutoNest As Boolean = False
|
|
|
@@ -343,6 +347,12 @@ Class MainWindow
|
|
|
|
EgtGetKeyOptions(9423, 2512, 1, m_nKeyOptions)
|
|
|
|
EgtGetKeyOptions(9423, 2512, 1, m_nKeyOptions)
|
|
|
|
' Verifico abilitazione prodotto
|
|
|
|
' Verifico abilitazione prodotto
|
|
|
|
Dim bProd As Boolean = GetKeyOption(KEY_OPT.CUT_BASE)
|
|
|
|
Dim bProd As Boolean = GetKeyOption(KEY_OPT.CUT_BASE)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
' Impostazione per programma OnlyFrame: solo se CUT_BASE non attivo
|
|
|
|
|
|
|
|
If Not bProd Then
|
|
|
|
|
|
|
|
m_OnlyFrame = GetKeyOption(KEY_OPT.CUT_LIGHT)
|
|
|
|
|
|
|
|
End If
|
|
|
|
|
|
|
|
|
|
|
|
' Inizializzazione generale di EgtInterface
|
|
|
|
' Inizializzazione generale di EgtInterface
|
|
|
|
m_nDebug = GetPrivateProfileInt(S_GENERAL, K_DEBUG, 0, m_sIniFile)
|
|
|
|
m_nDebug = GetPrivateProfileInt(S_GENERAL, K_DEBUG, 0, m_sIniFile)
|
|
|
|
m_sVersion = My.Application.Info.Version.Major.ToString() & "." &
|
|
|
|
m_sVersion = My.Application.Info.Version.Major.ToString() & "." &
|
|
|
@@ -1270,7 +1280,11 @@ Class MainWindow
|
|
|
|
m_ProdLineTimer.Start()
|
|
|
|
m_ProdLineTimer.Start()
|
|
|
|
End If
|
|
|
|
End If
|
|
|
|
' di default attivo la pagina CadCut
|
|
|
|
' di default attivo la pagina CadCut
|
|
|
|
|
|
|
|
If m_OnlyFrame Then
|
|
|
|
|
|
|
|
m_ActivePage = MainWindow.Pages.FrameCut
|
|
|
|
|
|
|
|
Else
|
|
|
|
m_ActivePage = MainWindow.Pages.CadCut
|
|
|
|
m_ActivePage = MainWindow.Pages.CadCut
|
|
|
|
|
|
|
|
End If
|
|
|
|
' seleziono il tipo di avvio
|
|
|
|
' seleziono il tipo di avvio
|
|
|
|
m_CurrentProjectPageUC.StartProgram()
|
|
|
|
m_CurrentProjectPageUC.StartProgram()
|
|
|
|
' aggiorno la grafica
|
|
|
|
' aggiorno la grafica
|
|
|
@@ -1307,8 +1321,33 @@ Class MainWindow
|
|
|
|
Dim bHeadH1 As Boolean = (EgtGetHeadId("H1") <> GDB_ID.NULL)
|
|
|
|
Dim bHeadH1 As Boolean = (EgtGetHeadId("H1") <> GDB_ID.NULL)
|
|
|
|
EgtSetCurrentContext(nCurrCtx)
|
|
|
|
EgtSetCurrentContext(nCurrCtx)
|
|
|
|
' Aggiorno interfaccia
|
|
|
|
' Aggiorno interfaccia
|
|
|
|
|
|
|
|
If m_OnlyFrame Then
|
|
|
|
|
|
|
|
If nPrjType = CurrentProjectPageUC.PRJ_TYPE.FLATS And m_ActivePage <> Pages.RawPart Then
|
|
|
|
|
|
|
|
Dim FrameWnd As New EgtMsgBox(Me, "NON PUOI", "La tua licenza non è abilitata CAD", EgtMsgBox.Buttons.OK, EgtMsgBox.Icons.NULL)
|
|
|
|
|
|
|
|
'' Gestione stato FastGrid
|
|
|
|
|
|
|
|
'm_CadCutPageUC.m_FastGridSlabManager.OnPreNewProject()
|
|
|
|
|
|
|
|
' Cancello progetto salvato con nome da file ini
|
|
|
|
|
|
|
|
WritePrivateProfileString(S_GENERAL, K_LASTNAMEPROJ, "", GetIniFile())
|
|
|
|
|
|
|
|
' Scelta tavola della macchina
|
|
|
|
|
|
|
|
Dim nTabInd As Integer = m_CadCutPageUC.m_ProjectMgr.ChooseTable()
|
|
|
|
|
|
|
|
' Creo nuovo progetto
|
|
|
|
|
|
|
|
m_CurrentProjectPageUC.NewProject(nTabInd, False)
|
|
|
|
|
|
|
|
'' Gestione stato FastGrid
|
|
|
|
|
|
|
|
'm_CadCutPageUC.m_FastGridSlabManager.OnPostNewProject()
|
|
|
|
|
|
|
|
FrameCutBtn_Click(Nothing, Nothing)
|
|
|
|
|
|
|
|
CadCutBtn.IsEnabled = False
|
|
|
|
|
|
|
|
Else
|
|
|
|
|
|
|
|
FrameCutBtn.IsEnabled = True
|
|
|
|
|
|
|
|
CadCutBtn.IsEnabled = False
|
|
|
|
|
|
|
|
' Attivo il pulsante FRAME
|
|
|
|
|
|
|
|
'FrameCutBtn.IsChecked = True
|
|
|
|
|
|
|
|
'CadCutBtn.IsChecked = False
|
|
|
|
|
|
|
|
End If
|
|
|
|
|
|
|
|
Else
|
|
|
|
CadCutBtn.IsEnabled = (nPrjType <> CurrentProjectPageUC.PRJ_TYPE.FRAMES)
|
|
|
|
CadCutBtn.IsEnabled = (nPrjType <> CurrentProjectPageUC.PRJ_TYPE.FRAMES)
|
|
|
|
FrameCutBtn.IsEnabled = (nPrjType <> CurrentProjectPageUC.PRJ_TYPE.FLATS) AndAlso bHeadH1
|
|
|
|
FrameCutBtn.IsEnabled = (nPrjType <> CurrentProjectPageUC.PRJ_TYPE.FLATS) AndAlso bHeadH1
|
|
|
|
|
|
|
|
End If
|
|
|
|
|
|
|
|
|
|
|
|
' DirectCutBtn.IsEnabled = bHeadH1
|
|
|
|
' DirectCutBtn.IsEnabled = bHeadH1
|
|
|
|
End Sub
|
|
|
|
End Sub
|
|
|
|
|
|
|
|
|
|
|
|