Merge pull request #175 from xiaozhuai/master

fix #172
This commit is contained in:
ZeRo° Xu 2021-03-02 14:36:13 +08:00 committed by GitHub
commit 4f526d597b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -102,7 +102,7 @@ function get_edid() {
let index++ let index++
MonitorName=("$(echo ${display:190:24} | xxd -p -r)") MonitorName=("$(echo ${display:190:24} | xxd -p -r)")
VendorID=${display:16:4} VendorID=${display:16:4}
ProductID=${gMonitor:22:2}${gMonitor:20:2} ProductID=${display:22:2}${display:20:2}
if [[ ${VendorID} == 0610 ]]; then if [[ ${VendorID} == 0610 ]]; then
MonitorName="Apple Display" MonitorName="Apple Display"
@ -197,7 +197,7 @@ function get_edid() {
echo '------------------------------------' echo '------------------------------------'
for display in "${gDisplayInf[@]}"; do for display in "${gDisplayInf[@]}"; do
let index++ let index++
printf " %d | ${display:16:4} | ${gMonitor:22:2}${gMonitor:20:2}\n" $index printf " %d | ${display:16:4} | ${display:22:2}${display:20:2}\n" $index
done done
echo '------------------------------------' echo '------------------------------------'
read -p "Choose the display: " selection read -p "Choose the display: " selection