mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-12-16 11:48:06 +01:00
Use en-Us locale when using ToUpper() (#6177)
This commit is contained in:
committed by
GitHub
parent
3bd6c363de
commit
c3652786ff
@@ -109,13 +109,14 @@ Foreach-Object {
|
|||||||
# Each line of the resgen text file is of the form ResourceName=ResourceValue with no spaces.
|
# Each line of the resgen text file is of the form ResourceName=ResourceValue with no spaces.
|
||||||
$content = $line -split "=", 2
|
$content = $line -split "=", 2
|
||||||
|
|
||||||
|
$culture = [System.Globalization.CultureInfo]::GetCultureInfo('en-US')
|
||||||
# Each resource is named as IDS_ResxResourceName, in uppercase
|
# Each resource is named as IDS_ResxResourceName, in uppercase
|
||||||
$lineInRCFormat = "IDS_" + $content[0].ToUpper() + " L`"" + $content[1] + "`""
|
$lineInRCFormat = "IDS_" + $content[0].ToUpper($culture) + " L`"" + $content[1] + "`""
|
||||||
$newLinesForRCFile = $newLinesForRCFile + "`r`n " + $lineInRCFormat
|
$newLinesForRCFile = $newLinesForRCFile + "`r`n " + $lineInRCFormat
|
||||||
|
|
||||||
# Resource header file needs to be updated only for one language
|
# Resource header file needs to be updated only for one language
|
||||||
if (!$headerFileUpdated) {
|
if (!$headerFileUpdated) {
|
||||||
$lineInHeaderFormat = "#define IDS_" + $content[0].ToUpper() + " " + $count.ToString()
|
$lineInHeaderFormat = "#define IDS_" + $content[0].ToUpper($culture) + " " + $count.ToString()
|
||||||
$newLinesForHeaderFile = $newLinesForHeaderFile + "`r`n" + $lineInHeaderFormat
|
$newLinesForHeaderFile = $newLinesForHeaderFile + "`r`n" + $lineInHeaderFormat
|
||||||
$count++
|
$count++
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user