randr: don't directly set changed bits in randr screen
Introduce a wrapper interface so we can fix things up for multi-gpu situations later. This just introduces the API for now. Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
parent
451ba4bd41
commit
f9c8248b83
|
@ -464,6 +464,14 @@ TellChanged(WindowPtr pWin, pointer value)
|
|||
return WT_WALKCHILDREN;
|
||||
}
|
||||
|
||||
void
|
||||
RRSetChanged(ScreenPtr pScreen)
|
||||
{
|
||||
rrScrPriv(pScreen);
|
||||
|
||||
pScrPriv->changed = TRUE;
|
||||
}
|
||||
|
||||
/*
|
||||
* Something changed; send events and adjust pointer position
|
||||
*/
|
||||
|
|
|
@ -486,6 +486,10 @@ extern _X_EXPORT void
|
|||
RRDeliverScreenEvent(ClientPtr client, WindowPtr pWin, ScreenPtr pScreen);
|
||||
|
||||
/* randr.c */
|
||||
/* set a screen change on the primary screen */
|
||||
extern _X_EXPORT void
|
||||
RRSetChanged(ScreenPtr pScreen);
|
||||
|
||||
/*
|
||||
* Send all pending events
|
||||
*/
|
||||
|
|
|
@ -39,7 +39,7 @@ RRCrtcChanged(RRCrtcPtr crtc, Bool layoutChanged)
|
|||
if (pScreen) {
|
||||
rrScrPriv(pScreen);
|
||||
|
||||
pScrPriv->changed = TRUE;
|
||||
RRSetChanged(pScreen);
|
||||
/*
|
||||
* Send ConfigureNotify on any layout change
|
||||
*/
|
||||
|
|
|
@ -225,7 +225,7 @@ RRScreenSetSizeRange(ScreenPtr pScreen,
|
|||
pScrPriv->minHeight = minHeight;
|
||||
pScrPriv->maxWidth = maxWidth;
|
||||
pScrPriv->maxHeight = maxHeight;
|
||||
pScrPriv->changed = TRUE;
|
||||
RRSetChanged(pScreen);
|
||||
pScrPriv->configChanged = TRUE;
|
||||
}
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@ RROutputChanged(RROutputPtr output, Bool configChanged)
|
|||
output->changed = TRUE;
|
||||
if (pScreen) {
|
||||
rrScrPriv(pScreen);
|
||||
pScrPriv->changed = TRUE;
|
||||
RRSetChanged(pScreen);
|
||||
if (configChanged)
|
||||
pScrPriv->configChanged = TRUE;
|
||||
}
|
||||
|
|
|
@ -143,7 +143,7 @@ RRScreenSizeNotify(ScreenPtr pScreen)
|
|||
pScrPriv->height = pScreen->height;
|
||||
pScrPriv->mmWidth = pScreen->mmWidth;
|
||||
pScrPriv->mmHeight = pScreen->mmHeight;
|
||||
pScrPriv->changed = TRUE;
|
||||
RRSetChanged(pScreen);
|
||||
/* pScrPriv->sizeChanged = TRUE; */
|
||||
|
||||
RRTellChanged(pScreen);
|
||||
|
|
Loading…
Reference in New Issue
Block a user