Allow RandR get output property to call into drivers

In order to report accurate values to users of the RandR property interface,
it's sometimes necessary to ask the driver to update the value (for example
when backlight brightness changes without the server's knowledge, due to hotkey
events or direct sysfs banging).

This patch wires up the core server code with a new xf86CrtcFuncs callback,
get_property, to allow for this.

The new code is available under the RANDR_13_INTERFACE define, which in turn
depends on the RANDR_12_INTERFACE code.
This commit is contained in:
Jesse Barnes 2008-03-06 13:47:44 -08:00
commit ca616b902b
5 changed files with 74 additions and 6 deletions

View file

@ -73,6 +73,14 @@ miRROutputSetProperty (ScreenPtr pScreen,
return TRUE;
}
Bool
miRROutputGetProperty (ScreenPtr pScreen,
RROutputPtr output,
Atom property)
{
return TRUE;
}
Bool
miRROutputValidateMode (ScreenPtr pScreen,
RROutputPtr output,
@ -116,6 +124,9 @@ miRandRInit (ScreenPtr pScreen)
pScrPriv->rrCrtcSet = miRRCrtcSet;
pScrPriv->rrCrtcSetGamma = miRRCrtcSetGamma;
pScrPriv->rrOutputSetProperty = miRROutputSetProperty;
#if RANDR_13_INTERFACE
pScrPriv->rrOutputGetProperty = miRROutputGetProperty;
#endif
pScrPriv->rrOutputValidateMode = miRROutputValidateMode;
pScrPriv->rrModeDestroy = miRRModeDestroy;