Skip to content

Commit efb774c

Browse files
committed
Updated Cursor function
1 parent 078b1e7 commit efb774c

File tree

7 files changed

+29
-29
lines changed

7 files changed

+29
-29
lines changed

src/Sophia_Script_for_Windows_10/Module/Sophia.psm1

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4828,7 +4828,7 @@ function AeroShaking
48284828
Cursors -Default
48294829
48304830
.LINK
4831-
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-v2-886489356
4831+
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-886489356
48324832
48334833
.NOTES
48344834
The 14/12/24 version
@@ -14062,13 +14062,13 @@ function DNSoverHTTPS
1406214062
"Enable"
1406314063
{
1406414064
# Set a primary and secondary DNS servers
14065-
if (-not (Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
14065+
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
1406614066
{
14067-
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
14067+
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1406814068
}
1406914069
else
1407014070
{
14071-
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
14071+
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1407214072
}
1407314073

1407414074
foreach ($InterfaceGuid in $InterfaceGuids)

src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3725,7 +3725,7 @@ function AppsLanguageSwitch
37253725
Cursors -Default
37263726
37273727
.LINK
3728-
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-v2-886489356
3728+
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-886489356
37293729
37303730
.NOTES
37313731
The 14/12/24 version
@@ -5594,7 +5594,7 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int
55945594

55955595
# Contents of the hidden desktop.ini file for each type of user folders
55965596
$DesktopINI = @{
5597-
"Desktop" = ""
5597+
"Desktop" = "",
55985598
"[.ShellClassInfo]",
55995599
"LocalizedResourceName=@%SystemRoot%\System32\shell32.dll,-21769",
56005600
"IconResource=%SystemRoot%\System32\imageres.dll,-183"

src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4107,7 +4107,7 @@ function AeroShaking
41074107
Cursors -Default
41084108
41094109
.LINK
4110-
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-v2-886489356
4110+
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-886489356
41114111
41124112
.NOTES
41134113
The 14/12/24 version
@@ -5992,7 +5992,7 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int
59925992

59935993
# Contents of the hidden desktop.ini file for each type of user folders
59945994
$DesktopINI = @{
5995-
"Desktop" = ""
5995+
"Desktop" = "",
59965996
"[.ShellClassInfo]",
59975997
"LocalizedResourceName=@%SystemRoot%\System32\shell32.dll,-21769",
59985998
"IconResource=%SystemRoot%\System32\imageres.dll,-183"
@@ -11946,13 +11946,13 @@ function DNSoverHTTPS
1194611946
"Enable"
1194711947
{
1194811948
# Set a primary and secondary DNS servers
11949-
if (-not (Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
11949+
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
1195011950
{
11951-
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
11951+
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1195211952
}
1195311953
else
1195411954
{
11955-
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
11955+
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1195611956
}
1195711957

1195811958
foreach ($InterfaceGuid in $InterfaceGuids)

src/Sophia_Script_for_Windows_10_PowerShell_7/Module/Sophia.psm1

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4846,7 +4846,7 @@ function AeroShaking
48464846
Cursors -Default
48474847
48484848
.LINK
4849-
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-v2-886489356
4849+
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-886489356
48504850
48514851
.NOTES
48524852
The 14/12/24 version
@@ -7022,7 +7022,7 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int
70227022

70237023
# Contents of the hidden desktop.ini file for each type of user folders
70247024
$DesktopINI = @{
7025-
"Desktop" = ""
7025+
"Desktop" = "",
70267026
"[.ShellClassInfo]",
70277027
"LocalizedResourceName=@%SystemRoot%\System32\shell32.dll,-21769",
70287028
"IconResource=%SystemRoot%\System32\imageres.dll,-183"
@@ -14092,13 +14092,13 @@ function DNSoverHTTPS
1409214092
"Enable"
1409314093
{
1409414094
# Set a primary and secondary DNS servers
14095-
if (-not (Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
14095+
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
1409614096
{
14097-
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
14097+
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1409814098
}
1409914099
else
1410014100
{
14101-
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
14101+
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1410214102
}
1410314103

1410414104
foreach ($InterfaceGuid in $InterfaceGuids)

src/Sophia_Script_for_Windows_11/Module/Sophia.psm1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13090,13 +13090,13 @@ function DNSoverHTTPS
1309013090
"Enable"
1309113091
{
1309213092
# Set a primary and secondary DNS servers
13093-
if (-not (Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
13093+
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
1309413094
{
13095-
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
13095+
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1309613096
}
1309713097
else
1309813098
{
13099-
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
13099+
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1310013100
}
1310113101

1310213102
foreach ($InterfaceGuid in $InterfaceGuids)

src/Sophia_Script_for_Windows_11_LTSC_2024/Module/Sophia.psm1

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4072,7 +4072,7 @@ function AeroShaking
40724072
Cursors -Default
40734073
40744074
.LINK
4075-
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-v2-886489356
4075+
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-886489356
40764076
40774077
.NOTES
40784078
The 14/12/24 version
@@ -6250,7 +6250,7 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int
62506250

62516251
# Contents of the hidden desktop.ini file for each type of user folders
62526252
$DesktopINI = @{
6253-
"Desktop" = ""
6253+
"Desktop" = "",
62546254
"[.ShellClassInfo]",
62556255
"LocalizedResourceName=@%SystemRoot%\System32\shell32.dll,-21769",
62566256
"IconResource=%SystemRoot%\System32\imageres.dll,-183"
@@ -9099,8 +9099,8 @@ function Install-VCRedist
90999099
else
91009100
{
91019101
Write-Information -MessageData "" -InformationAction Continue
9102-
Write-Verbose -Message ($Localization.Skipped -f $MyInvocation.Line.Trim()) -Verbose ###
9103-
Write-Error -Message ($Localization.Skipped -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
9102+
Write-Verbose -Message ($Localization.Skipped -f ("{0} -{1} {2}" -f $MyInvocation.MyCommand.Name, $MyInvocation.BoundParameters.Keys.Trim(), $_)) -Verbose
9103+
Write-Error -Message ($Localization.Skipped -f ("{0} -{1} {2}" -f $MyInvocation.MyCommand.Name, $MyInvocation.BoundParameters.Keys.Trim(), $_)) -ErrorAction SilentlyContinue
91049104
}
91059105
}
91069106
}
@@ -12372,13 +12372,13 @@ function DNSoverHTTPS
1237212372
"Enable"
1237312373
{
1237412374
# Set a primary and secondary DNS servers
12375-
if (-not (Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
12375+
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
1237612376
{
12377-
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
12377+
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1237812378
}
1237912379
else
1238012380
{
12381-
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
12381+
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1238212382
}
1238312383

1238412384
foreach ($InterfaceGuid in $InterfaceGuids)

src/Sophia_Script_for_Windows_11_PowerShell_7/Module/Sophia.psm1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4248,7 +4248,7 @@ function AeroShaking
42484248
Cursors -Default
42494249

42504250
.LINK
4251-
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-v2-886489356
4251+
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-886489356
42524252

42534253
.NOTES
42544254
The 14/12/24 version
@@ -10977,7 +10977,7 @@ function XboxGameBar
1097710977

1097810978
<#
1097910979
.SYNOPSIS
10980-
Game Bar tips
10980+
Xbox Game Bar tips
1098110981

1098210982
.PARAMETER Disable
1098310983
Disable Xbox Game Bar tips
@@ -13120,7 +13120,7 @@ function DNSoverHTTPS
1312013120
"Enable"
1312113121
{
1312213122
# Set a primary and secondary DNS servers
13123-
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent) ###
13123+
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
1312413124
{
1312513125
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
1312613126
}

0 commit comments

Comments
 (0)