randr: Cleanup rrSetupPixmapSharing()
protopix is completely redundant with mscreenpix. Get rid of it. We don't need rrScrPriv, so remove it. [ajax: also squash an unused variable in RRCrtcDetachScanoutPixmap, though it'll come back when the rest of this series lands] Reviewed-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Alex Goins <agoins@nvidia.com>
This commit is contained in:
parent
8d3f0e964e
commit
c7f4aef8f4
|
@ -379,11 +379,8 @@ void
|
||||||
RRCrtcDetachScanoutPixmap(RRCrtcPtr crtc)
|
RRCrtcDetachScanoutPixmap(RRCrtcPtr crtc)
|
||||||
{
|
{
|
||||||
ScreenPtr master = crtc->pScreen->current_master;
|
ScreenPtr master = crtc->pScreen->current_master;
|
||||||
PixmapPtr mscreenpix;
|
|
||||||
rrScrPriv(crtc->pScreen);
|
rrScrPriv(crtc->pScreen);
|
||||||
|
|
||||||
mscreenpix = master->GetScreenPixmap(master);
|
|
||||||
|
|
||||||
pScrPriv->rrCrtcSetScanoutPixmap(crtc, NULL);
|
pScrPriv->rrCrtcSetScanoutPixmap(crtc, NULL);
|
||||||
if (crtc->scanout_pixmap) {
|
if (crtc->scanout_pixmap) {
|
||||||
rrDestroySharedPixmap(crtc, crtc->scanout_pixmap);
|
rrDestroySharedPixmap(crtc, crtc->scanout_pixmap);
|
||||||
|
@ -429,8 +426,6 @@ rrSetupPixmapSharing(RRCrtcPtr crtc, int width, int height,
|
||||||
ScreenPtr master = crtc->pScreen->current_master;
|
ScreenPtr master = crtc->pScreen->current_master;
|
||||||
int depth;
|
int depth;
|
||||||
PixmapPtr mscreenpix;
|
PixmapPtr mscreenpix;
|
||||||
PixmapPtr protopix = master->GetScreenPixmap(master);
|
|
||||||
rrScrPriv(crtc->pScreen);
|
|
||||||
PixmapPtr spix;
|
PixmapPtr spix;
|
||||||
|
|
||||||
/* create a pixmap on the master screen,
|
/* create a pixmap on the master screen,
|
||||||
|
@ -442,7 +437,7 @@ rrSetupPixmapSharing(RRCrtcPtr crtc, int width, int height,
|
||||||
*/
|
*/
|
||||||
|
|
||||||
mscreenpix = master->GetScreenPixmap(master);
|
mscreenpix = master->GetScreenPixmap(master);
|
||||||
depth = protopix->drawable.depth;
|
depth = mscreenpix->drawable.depth;
|
||||||
|
|
||||||
if (crtc->scanout_pixmap)
|
if (crtc->scanout_pixmap)
|
||||||
RRCrtcDetachScanoutPixmap(crtc);
|
RRCrtcDetachScanoutPixmap(crtc);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user