mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-11-01 10:32:35 +01:00
DisplayServer: support brightness detection (macOS)
This commit is contained in:
@@ -27,6 +27,9 @@ void ffPrintResolution(FFinstance* instance)
|
||||
if(result->refreshRate > 0)
|
||||
printf(" @ %iHz", result->refreshRate);
|
||||
|
||||
if(result->brightness >= 0)
|
||||
printf(" (☀️ %d%%)", result->brightness);
|
||||
|
||||
putchar('\n');
|
||||
}
|
||||
else
|
||||
@@ -34,7 +37,8 @@ void ffPrintResolution(FFinstance* instance)
|
||||
ffPrintFormat(instance, FF_RESOLUTION_MODULE_NAME, moduleIndex, &instance->config.resolution, FF_RESOLUTION_NUM_FORMAT_ARGS, (FFformatarg[]) {
|
||||
{FF_FORMAT_ARG_TYPE_INT, &result->width},
|
||||
{FF_FORMAT_ARG_TYPE_INT, &result->height},
|
||||
{FF_FORMAT_ARG_TYPE_INT, &result->refreshRate}
|
||||
{FF_FORMAT_ARG_TYPE_INT, &result->refreshRate},
|
||||
{FF_FORMAT_ARG_TYPE_INT, &result->brightness},
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user