44#AutoIt3Wrapper_Icon= AppControl.ico
55#AutoIt3Wrapper_UseX64= y
66#AutoIt3Wrapper_Res_Description= App Control Policy Manager
7- #AutoIt3Wrapper_Res_Fileversion= 4.7 .0.0
8- #AutoIt3Wrapper_Res_ProductVersion= 4.7 .0
7+ #AutoIt3Wrapper_Res_Fileversion= 4.8 .0.0
8+ #AutoIt3Wrapper_Res_ProductVersion= 4.8 .0
99#AutoIt3Wrapper_Res_ProductName= AppControlPolicyManager
1010#AutoIt3Wrapper_Res_LegalCopyright= @ 2024 WildByDesign
1111#AutoIt3Wrapper_Res_Language= 1033
3939#include " includes\GUIListViewEx.au3"
4040#include " includes\XML.au3"
4141
42- Global $programversion = " 4.7 "
42+ Global $programversion = " 4.8 "
4343
4444; Opt('MustDeclareVars', 1)
4545
@@ -59,6 +59,7 @@ Global $hGUI, $cListView, $hListView
5959Global $out , $arpol , $arraycount , $policycount , $policyoutput , $policycorrect , $CountTotal , $ExitButton , $TestButton , $Label2 , $aContent , $iLV_Index
6060Global $CountEnforced = 0
6161
62+ If $isDarkMode = True Then
6263Global $iDllGDI = DllOpen (" gdi32.dll" )
6364Global $iDllUSER32 = DllOpen (" user32.dll" )
6465
@@ -70,6 +71,7 @@ For $i = 0 To UBound($aCol)-1
7071 $aCol [$i ][0 ] = _BGR2RGB($aCol [$i ][0 ])
7172 $aCol [$i ][1 ] = _BGR2RGB($aCol [$i ][1 ])
7273Next
74+ EndIf
7375
7476; Fake older build for testing
7577; Global $WinBuild = "22621"
@@ -195,7 +197,13 @@ If $is24H2 = True Then
195197 Local $string13 = StringReplace ($string12 , " {" , " " )
196198 Local $string14 = StringReplace ($string13 , " }" , " " )
197199 Local $string15 = StringReplace ($string14 , " Version : " , " " )
198- Local $finalparse = $string15
200+ Local $string16 = StringReplace ($string15 , " ..." , " " )
201+ Local $string17 = StringReplace ($string16 , " Default Policy." , " Default Policy" )
202+ Local $string18 = StringReplace ($string17 , " Integrity Policy." , " Integrity Policy" )
203+ Local $string19 = StringReplace ($string18 , " Supplemental Policies." , " Supplemental Policies" )
204+ Local $string20 = StringReplace ($string19 , " Code Trust." , " Code Trust" )
205+ Local $string21 = StringReplace ($string20 , " Rule Protection." , " Rule Protection" )
206+ Local $finalparse = $string21
199207
200208Else
201209
@@ -218,7 +226,13 @@ Else
218226 Local $string15 = StringReplace ($string14 , " Version : " , " " )
219227 Local $string16 = StringStripWS ($string15 , $STR_STRIPSPACES )
220228 Local $string17 = StringReplace ($string16 , " PolicyOptions :" , " *" )
221- Local $finalparse = $string17
229+ Local $string18 = StringReplace ($string17 , " ..." , " " )
230+ Local $string19 = StringReplace ($string18 , " Default Policy." , " Default Policy" )
231+ Local $string20 = StringReplace ($string19 , " Integrity Policy." , " Integrity Policy" )
232+ Local $string21 = StringReplace ($string20 , " Supplemental Policies." , " Supplemental Policies" )
233+ Local $string22 = StringReplace ($string21 , " Code Trust." , " Code Trust" )
234+ Local $string23 = StringReplace ($string22 , " Rule Protection." , " Rule Protection" )
235+ Local $finalparse = $string23
222236
223237EndIf
224238
@@ -923,7 +937,7 @@ Global $topstatus9 = StringStripWS($topstatus8, $STR_STRIPLEADING + $STR_STRIPTR
923937
924938Endfunc
925939
926- Local $exStyles = BitOR ($LVS_EX_FULLROWSELECT , $LVS_EX_CHECKBOXES , $LVS_EX_INFOTIP ), $cListView
940+ Local $exStyles = BitOR ($LVS_EX_FULLROWSELECT , $LVS_EX_CHECKBOXES ), $cListView
927941
928942; $hGUI = GUICreate("App Control Policy Manager", 1220, 560, -1, -1, 0x00CF0000)
929943$hGUI = GUICreate (" App Control Policy Manager" , 1220 , 594 , - 1 , - 1 , 0x00CF0000 )
@@ -1000,6 +1014,7 @@ _GUICtrlListView_SetExtendedListViewStyle($hListView, $exStyles)
10001014
10011015_GUICtrlListView_AddArray($hListView ,$aWords )
10021016
1017+ If $isDarkMode = True Then
10031018; get handle to child SysHeader32 control of ListView
10041019Global $hHeader = HWnd (GUICtrlSendMsg ($cListView , $LVM_GETHEADER , 0 , 0 ))
10051020; Turn off theme for header
@@ -1011,6 +1026,7 @@ Global $wProcOld = _WinAPI_SetWindowLong($hListView, $GWL_WNDPROC, DllCallbackGe
10111026; Optional: Flat Header - remove header 3D button effect
10121027Global $iStyle = _WinAPI_GetWindowLong($hHeader , $GWL_STYLE )
10131028_WinAPI_SetWindowLong($hHeader , $GWL_STYLE , BitOR ($iStyle , $HDS_FLAT ))
1029+ EndIf
10141030
10151031CountTotal()
10161032Func CountTotal()
0 commit comments