mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-09-13 02:42:09 +02:00
Display (Windows): rename VRR to DRR
This commit is contained in:
@@ -45,7 +45,7 @@ FFDisplayResult* ffdsAppendDisplay(
|
||||
display->manufactureYear = 0;
|
||||
display->manufactureWeek = 0;
|
||||
display->serial = 0;
|
||||
display->vrrStatus = FF_DISPLAY_VRR_STATUS_UNKNOWN;
|
||||
display->drrStatus = FF_DISPLAY_DRR_STATUS_UNKNOWN;
|
||||
|
||||
return display;
|
||||
}
|
||||
|
||||
@@ -62,9 +62,9 @@ typedef enum __attribute__((__packed__)) FFDisplayHdrStatus
|
||||
|
||||
typedef enum __attribute__((__packed__)) FFDisplayVrrStatus
|
||||
{
|
||||
FF_DISPLAY_VRR_STATUS_UNKNOWN,
|
||||
FF_DISPLAY_VRR_STATUS_DISABLED,
|
||||
FF_DISPLAY_VRR_STATUS_ENABLED,
|
||||
FF_DISPLAY_DRR_STATUS_UNKNOWN,
|
||||
FF_DISPLAY_DRR_STATUS_DISABLED,
|
||||
FF_DISPLAY_DRR_STATUS_ENABLED,
|
||||
} FFDisplayVrrStatus;
|
||||
|
||||
typedef struct FFDisplayResult
|
||||
@@ -90,7 +90,7 @@ typedef struct FFDisplayResult
|
||||
uint16_t manufactureYear;
|
||||
uint16_t manufactureWeek;
|
||||
uint32_t serial;
|
||||
FFDisplayVrrStatus vrrStatus;
|
||||
FFDisplayVrrStatus drrStatus;
|
||||
} FFDisplayResult;
|
||||
|
||||
typedef struct FFDisplayServerResult
|
||||
|
||||
@@ -229,7 +229,7 @@ static void detectDisplays(FFDisplayServerResult* ds)
|
||||
}
|
||||
if (edidLength > 0)
|
||||
ffEdidGetSerialAndManufactureDate(edidData, &display->serial, &display->manufactureYear, &display->manufactureWeek);
|
||||
display->vrrStatus = path->flags & DISPLAYCONFIG_PATH_BOOST_REFRESH_RATE ? FF_DISPLAY_VRR_STATUS_ENABLED : FF_DISPLAY_VRR_STATUS_DISABLED;
|
||||
display->drrStatus = path->flags & DISPLAYCONFIG_PATH_BOOST_REFRESH_RATE ? FF_DISPLAY_DRR_STATUS_ENABLED : FF_DISPLAY_DRR_STATUS_DISABLED;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -348,18 +348,18 @@ bool ffGenerateDisplayJsonResult(FF_MAYBE_UNUSED FFDisplayOptions* options, yyjs
|
||||
yyjson_mut_obj_add_uint(doc, output, "height", item->height);
|
||||
yyjson_mut_obj_add_real(doc, output, "refreshRate", item->refreshRate);
|
||||
|
||||
if (item->vrrStatus == FF_DISPLAY_VRR_STATUS_UNKNOWN)
|
||||
yyjson_mut_obj_add_null(doc, output, "vrrStatus");
|
||||
else switch (item->vrrStatus)
|
||||
if (item->drrStatus == FF_DISPLAY_DRR_STATUS_UNKNOWN)
|
||||
yyjson_mut_obj_add_null(doc, output, "drrStatus");
|
||||
else switch (item->drrStatus)
|
||||
{
|
||||
case FF_DISPLAY_VRR_STATUS_DISABLED:
|
||||
yyjson_mut_obj_add_str(doc, output, "vrrStatus", "Disabled");
|
||||
case FF_DISPLAY_DRR_STATUS_DISABLED:
|
||||
yyjson_mut_obj_add_str(doc, output, "drrStatus", "Disabled");
|
||||
break;
|
||||
case FF_DISPLAY_VRR_STATUS_ENABLED:
|
||||
yyjson_mut_obj_add_str(doc, output, "vrrStatus", "Enabled");
|
||||
case FF_DISPLAY_DRR_STATUS_ENABLED:
|
||||
yyjson_mut_obj_add_str(doc, output, "drrStatus", "Enabled");
|
||||
break;
|
||||
default:
|
||||
yyjson_mut_obj_add_str(doc, output, "vrrStatus", "Unknown");
|
||||
yyjson_mut_obj_add_str(doc, output, "drrStatus", "Unknown");
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user