OmagCUT :

- Cambio tema disponibile nella OptionsPageUC (necessario riavvio programma per applicarlo)
This commit is contained in:
Renzo Lanza
2019-09-20 12:44:53 +00:00
parent b4922b6704
commit 7be2395fc3
192 changed files with 1781 additions and 3702 deletions
+41 -11
View File
@@ -522,17 +522,23 @@ Public Class TwoStateButton
Public ReadOnly Property ImageSource As String
Get
Dim sNewIcons As String
If (m_MainWindow.m_OptionsPageUC.ThemesCmBx.SelectedIndex = 0) Then
sNewIcons = ""
Else
sNewIcons = "NewIcons\"
End If
' Se variabile di stato "Nothing" o non collegato a CN, imposto immagine fissa
If StateFlag = BTN_STATE_NOTHING Or Not m_MainWindow.m_bNCLink Or IsNothing(FImageName) Or String.IsNullOrWhiteSpace(FImageName) Then
' ritorno immagine dello stato true
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & TImageName
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & TImageName
End If
If m_IsChecked Then
' ritorno immagine dello stato true
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & TImageName
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & TImageName
Else
' ritorno immagine dello stato false
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & FImageName
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & FImageName
End If
End Get
End Property
@@ -555,7 +561,13 @@ Public Class NoStateButton
Public ReadOnly Property ImageSource As String
Get
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & TImageName
Dim sNewIcons As String
If (m_MainWindow.m_OptionsPageUC.ThemesCmBx.SelectedIndex = 0) Then
sNewIcons = ""
Else
sNewIcons = "NewIcons\"
End If
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & TImageName
End Get
End Property
@@ -614,8 +626,14 @@ Public Class ThreeStateButton
End Property
Public ReadOnly Property ImageSource As String
Get
Dim sNewIcons As String
If (m_MainWindow.m_OptionsPageUC.ThemesCmBx.SelectedIndex = 0) Then
sNewIcons = ""
Else
sNewIcons = "NewIcons\"
End If
' ritorno immagine dello stato true
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & TImageName
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & TImageName
End Get
End Property
@@ -676,17 +694,23 @@ Public Class DoubleCommandButton
Public ReadOnly Property ImageSource As String
Get
Dim sNewIcons As String
If (m_MainWindow.m_OptionsPageUC.ThemesCmBx.SelectedIndex = 0) Then
sNewIcons = ""
Else
sNewIcons = "NewIcons\"
End If
' Se variabile di stato "Nothing" o non collegato a CN, imposto immagine fissa
If StateFlag = BTN_STATE_NOTHING Or Not m_MainWindow.m_bNCLink Or IsNothing(FImageName) Or String.IsNullOrWhiteSpace(FImageName) Then
' ritorno immagine dello stato true
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & TImageName
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & TImageName
End If
If m_IsChecked Then
' ritorno immagine dello stato true
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & TImageName
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & TImageName
Else
' ritorno immagine dello stato false
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & FImageName
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & FImageName
End If
End Get
End Property
@@ -712,17 +736,23 @@ Public Class PressedCommandButton
Public ReadOnly Property ImageSource As String
Get
Dim sNewIcons As String
If (m_MainWindow.m_OptionsPageUC.ThemesCmBx.SelectedIndex = 0) Then
sNewIcons = ""
Else
sNewIcons = "NewIcons\"
End If
' Se variabile di stato "Nothing" o non collegato a CN, imposto immagine fissa
If StateFlag = BTN_STATE_NOTHING Or Not m_MainWindow.m_bNCLink Or IsNothing(FImageName) Or String.IsNullOrWhiteSpace(FImageName) Then
' ritorno immagine dello stato true
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & TImageName
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & TImageName
End If
If m_IsPressed Then
' ritorno immagine dello stato true
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & TImageName
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & TImageName
Else
' ritorno immagine dello stato false
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & FImageName
Return m_MainWindow.GetResourcesDir() & "\MachineButtonsImage\" & sNewIcons & FImageName
End If
End Get
End Property