Commit 3cbc4c10 authored by Dave Airlie's avatar Dave Airlie

randr: expose unattached providers to the clients.

This provides the unattached provider list to the clients.
Reviewed-by: Keith Packard's avatarKeith Packard <keithp@keithp.com>
Reviewed-by: Adam Jackson's avatarAdam Jackson <ajax@redhat.com>
Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
parent d0e138c3
......@@ -59,6 +59,7 @@ ProcRRGetProviders (ClientPtr client)
unsigned int extraLen;
RRProvider *providers;
int total_providers = 0, count_providers = 0;
ScreenPtr iter;
REQUEST_SIZE_MATCH(xRRGetProvidersReq);
rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess);
......@@ -71,6 +72,10 @@ ProcRRGetProviders (ClientPtr client)
if (pScrPriv->provider)
total_providers++;
xorg_list_for_each_entry(iter, &pScreen->unattached_list, unattached_head) {
pScrPriv = rrGetScrPriv(iter);
total_providers += pScrPriv->provider ? 1 : 0;
}
pScrPriv = rrGetScrPriv(pScreen);
rep.pad = 0;
......@@ -100,6 +105,9 @@ ProcRRGetProviders (ClientPtr client)
providers = (RRProvider *)extra;
ADD_PROVIDER(pScreen);
xorg_list_for_each_entry(iter, &pScreen->unattached_list, unattached_head) {
ADD_PROVIDER(iter);
}
}
if (client->swapped) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment