Skip to content

Commit

Permalink
#48, #51
Browse files Browse the repository at this point in the history
Fix Some Social Buttons
Reduce FileReads for DX/WDDM
Kill DXDIAG devs... I mean non-sense
  • Loading branch information
rcmaehl committed Jun 27, 2021
1 parent 21c53c3 commit d5a6c83
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions WhyNotWin11.au3
Original file line number Diff line number Diff line change
Expand Up @@ -81,15 +81,15 @@ Func Main()

; Top Most Interaction for Socials
$hGithub = GUICtrlCreateLabel("", 12, 100, 32, 32)
GUICtrlSetTip(-1, "Github")
GUICtrlSetTip(-1, "GitHub")
GUICtrlSetCursor(-1, 0)

$hDonate = GUICtrlCreateLabel("", 56, 100, 32, 32)
GUICtrlSetTip(-1, "Donate")
GUICtrlSetCursor(-1, 0)

$hDiscord = GUICtrlCreateLabel("", 12, 144, 32, 32)
GUICtrlSetTip(-1, "Email Me")
GUICtrlSetTip(-1, "Discord")
GUICtrlSetCursor(-1, 0)

$hLTT = GUICtrlCreateLabel("", 56, 144, 32, 32)
Expand Down Expand Up @@ -375,24 +375,25 @@ Func Main()

; DirectX 12 takes a while. Grab the result once done
Case Not ProcessExists("dxdiag.exe") And FileExists($hDXFile)
$sDXFile = StringStripWS(StringStripCR(FileRead($hDXFile)), $STR_STRIPALL)
Select
Case StringInStr(FileRead($hDXFile), "DDI Version: 12") And StringInStr(FileRead($hDXFile), "Driver Model: 3") ; Non-English Languages
Case StringInStr($sDXFile, "DDIVersion:12") And StringInStr($sDXFile, "DriverModel:3") ; Non-English Languages
ContinueCase
Case StringInStr(FileRead($hDXFile), "DDI Version: 12") And StringInStr(FileRead($hDXFile), "Driver Model: WDDM 3")
Case StringInStr($sDXFile, "DDIVersion:12") And StringInStr($sDXFile, "DriverModel:WDDM3")
GUICtrlSetData($hCheck[5][0], "OK")
GUICtrlSetBkColor($hCheck[5][0], 0x4CC355)
GUICtrlSetData($hCheck[5][2], "DirectX 12, WDDM 3")
Case StringInStr(FileRead($hDXFile), "DDI Version: 12") And StringInStr(FileRead($hDXFile), "Driver Model: 2") ; Non-English Languages
Case StringInStr($sDXFile, "DDIVersion:12") And StringInStr($sDXFile, "DriverModel:2") ; Non-English Languages
ContinueCase
Case StringInStr(FileRead($hDXFile), "DDI Version: 12") And StringInStr(FileRead($hDXFile), "Driver Model: WDDM 2")
Case StringInStr($sDXFile, "DDIVersion:12") And StringInStr($sDXFile, "DriverModel:WDDM2")
GUICtrlSetData($hCheck[5][0], "OK")
GUICtrlSetBkColor($hCheck[5][0], 0x4CC355)
GUICtrlSetData($hCheck[5][2], "DirectX 12, WDDM 2")
Case Not StringInStr(FileRead($hDXFile), "DDI Version: 12") And StringInStr(FileRead($hDXFile), "Driver Model: WDDM 2")
Case Not StringInStr($sDXFile, "DDIVersion:12") And StringInStr($sDXFile, "DriverModel:WDDM2")
GUICtrlSetData($hCheck[5][0], "X")
GUICtrlSetBkColor($hCheck[5][0], 0xFA113D)
GUICtrlSetData($hCheck[5][2], "No DirectX 12, but WDDM2")
Case StringInStr(FileRead($hDXFile), "DDI Version: 12") And Not StringInStr(FileRead($hDXFile), "Driver Model: WDDM 2")
Case StringInStr($sDXFile, "DDIVersion:12") And Not StringInStr($sDXFile, "DriverModel:WDDM2")
GUICtrlSetData($hCheck[5][0], "X")
GUICtrlSetBkColor($hCheck[5][0], 0xFA113D)
GUICtrlSetData($hCheck[5][2], "DirectX 12, but no WDDM2")
Expand Down

0 comments on commit d5a6c83

Please sign in to comment.