Skip to content

Commit

Permalink
Updated Cursor function
Browse files Browse the repository at this point in the history
  • Loading branch information
farag2 committed Jan 3, 2025
1 parent 078b1e7 commit efb774c
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 29 deletions.
8 changes: 4 additions & 4 deletions src/Sophia_Script_for_Windows_10/Module/Sophia.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -4828,7 +4828,7 @@ function AeroShaking
Cursors -Default
.LINK
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-v2-886489356
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-886489356
.NOTES
The 14/12/24 version
Expand Down Expand Up @@ -14062,13 +14062,13 @@ function DNSoverHTTPS
"Enable"
{
# Set a primary and secondary DNS servers
if (-not (Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
{
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
}
else
{
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
}

foreach ($InterfaceGuid in $InterfaceGuids)
Expand Down
4 changes: 2 additions & 2 deletions src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -3725,7 +3725,7 @@ function AppsLanguageSwitch
Cursors -Default
.LINK
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-v2-886489356
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-886489356
.NOTES
The 14/12/24 version
Expand Down Expand Up @@ -5594,7 +5594,7 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int

# Contents of the hidden desktop.ini file for each type of user folders
$DesktopINI = @{
"Desktop" = ""
"Desktop" = "",
"[.ShellClassInfo]",
"LocalizedResourceName=@%SystemRoot%\System32\shell32.dll,-21769",
"IconResource=%SystemRoot%\System32\imageres.dll,-183"
Expand Down
10 changes: 5 additions & 5 deletions src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -4107,7 +4107,7 @@ function AeroShaking
Cursors -Default
.LINK
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-v2-886489356
https://www.deviantart.com/jepricreations/art/Windows-11-Cursors-Concept-886489356
.NOTES
The 14/12/24 version
Expand Down Expand Up @@ -5992,7 +5992,7 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int

# Contents of the hidden desktop.ini file for each type of user folders
$DesktopINI = @{
"Desktop" = ""
"Desktop" = "",
"[.ShellClassInfo]",
"LocalizedResourceName=@%SystemRoot%\System32\shell32.dll,-21769",
"IconResource=%SystemRoot%\System32\imageres.dll,-183"
Expand Down Expand Up @@ -11946,13 +11946,13 @@ function DNSoverHTTPS
"Enable"
{
# Set a primary and secondary DNS servers
if (-not (Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
{
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
}
else
{
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
}

foreach ($InterfaceGuid in $InterfaceGuids)
Expand Down
10 changes: 5 additions & 5 deletions src/Sophia_Script_for_Windows_10_PowerShell_7/Module/Sophia.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -4846,7 +4846,7 @@ function AeroShaking
Cursors -Default

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

.NOTES
The 14/12/24 version
Expand Down Expand Up @@ -7022,7 +7022,7 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int

# Contents of the hidden desktop.ini file for each type of user folders
$DesktopINI = @{
"Desktop" = ""
"Desktop" = "",
"[.ShellClassInfo]",
"LocalizedResourceName=@%SystemRoot%\System32\shell32.dll,-21769",
"IconResource=%SystemRoot%\System32\imageres.dll,-183"
Expand Down Expand Up @@ -14092,13 +14092,13 @@ function DNSoverHTTPS
"Enable"
{
# Set a primary and secondary DNS servers
if (-not (Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
{
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
}
else
{
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
}

foreach ($InterfaceGuid in $InterfaceGuids)
Expand Down
6 changes: 3 additions & 3 deletions src/Sophia_Script_for_Windows_11/Module/Sophia.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -13090,13 +13090,13 @@ function DNSoverHTTPS
"Enable"
{
# Set a primary and secondary DNS servers
if (-not (Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
{
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
}
else
{
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
}

foreach ($InterfaceGuid in $InterfaceGuids)
Expand Down
14 changes: 7 additions & 7 deletions src/Sophia_Script_for_Windows_11_LTSC_2024/Module/Sophia.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -4072,7 +4072,7 @@ function AeroShaking
Cursors -Default

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

.NOTES
The 14/12/24 version
Expand Down Expand Up @@ -6250,7 +6250,7 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int

# Contents of the hidden desktop.ini file for each type of user folders
$DesktopINI = @{
"Desktop" = ""
"Desktop" = "",
"[.ShellClassInfo]",
"LocalizedResourceName=@%SystemRoot%\System32\shell32.dll,-21769",
"IconResource=%SystemRoot%\System32\imageres.dll,-183"
Expand Down Expand Up @@ -9099,8 +9099,8 @@ function Install-VCRedist
else
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message ($Localization.Skipped -f $MyInvocation.Line.Trim()) -Verbose ###
Write-Error -Message ($Localization.Skipped -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Verbose -Message ($Localization.Skipped -f ("{0} -{1} {2}" -f $MyInvocation.MyCommand.Name, $MyInvocation.BoundParameters.Keys.Trim(), $_)) -Verbose
Write-Error -Message ($Localization.Skipped -f ("{0} -{1} {2}" -f $MyInvocation.MyCommand.Name, $MyInvocation.BoundParameters.Keys.Trim(), $_)) -ErrorAction SilentlyContinue
}
}
}
Expand Down Expand Up @@ -12372,13 +12372,13 @@ function DNSoverHTTPS
"Enable"
{
# Set a primary and secondary DNS servers
if (-not (Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
if ((Get-CimInstance -ClassName CIM_ComputerSystem).HypervisorPresent)
{
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
}
else
{
Get-NetRoute | Where-Object -FilterScript {$_.DestinationPrefix -eq "0.0.0.0/0"} | Get-NetAdapter | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
Get-NetAdapter -Physical | Get-NetIPInterface -AddressFamily IPv4 | Set-DnsClientServerAddress -ServerAddresses $PrimaryDNS, $SecondaryDNS
}

foreach ($InterfaceGuid in $InterfaceGuids)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4248,7 +4248,7 @@ function AeroShaking
Cursors -Default

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

.NOTES
The 14/12/24 version
Expand Down Expand Up @@ -10977,7 +10977,7 @@ function XboxGameBar

<#
.SYNOPSIS
Game Bar tips
Xbox Game Bar tips

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

0 comments on commit efb774c

Please sign in to comment.