Commit d78ac2f1 authored by Adam Jackson's avatar Adam Jackson 🥃

mi: Factor out miSaveScreen

Reviewed-by: Eric Anholt's avatarEric Anholt <eric@anholt.net>
Signed-off-by: Adam Jackson's avatarAdam Jackson <ajax@redhat.com>
parent 0a9415cf
......@@ -461,12 +461,6 @@ vfbStoreColors(ColormapPtr pmap, int ndef, xColorItem * pdefs)
}
}
static Bool
vfbSaveScreen(ScreenPtr pScreen, int on)
{
return TRUE;
}
#ifdef HAVE_MMAP
/* this flushes any changes to the screens out to the mmapped file */
......@@ -935,8 +929,6 @@ vfbScreenInit(ScreenPtr pScreen, int argc, char **argv)
return FALSE;
pScreen->InstallColormap = vfbInstallColormap;
pScreen->SaveScreen = vfbSaveScreen;
pScreen->StoreColors = vfbStoreColors;
miDCInitialize(pScreen, &vfbPointerCursorFuncs);
......
......@@ -171,20 +171,6 @@ DarwinPrintBanner(void)
ErrorF("Build Date: %s\n", BUILD_DATE);
}
/*
* DarwinSaveScreen
* X screensaver support. Not implemented.
*/
static Bool
DarwinSaveScreen(ScreenPtr pScreen, int on)
{
// FIXME
if (on == SCREEN_SAVER_FORCER) {}
else if (on == SCREEN_SAVER_ON) {}
else {}
return TRUE;
}
/*
* DarwinScreenInit
* This is a callback from dix during AddScreen() from InitOutput().
......@@ -271,9 +257,6 @@ DarwinScreenInit(ScreenPtr pScreen, int argc, char **argv)
ShmRegisterFbFuncs(pScreen);
#endif
// this must be initialized (why doesn't X have a default?)
pScreen->SaveScreen = DarwinSaveScreen;
// finish mode dependent screen setup including cursor support
if (!QuartzSetupScreen(pScreen->myNum, pScreen)) {
return FALSE;
......
......@@ -614,12 +614,6 @@ xwl_unrealize_window(WindowPtr window)
return ret;
}
static Bool
xwl_save_screen(ScreenPtr pScreen, int on)
{
return TRUE;
}
static void
frame_callback(void *data,
struct wl_callback *callback,
......@@ -1066,8 +1060,6 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
SetNotifyFd(xwl_screen->wayland_fd, socket_handler, X_NOTIFY_READ, xwl_screen);
RegisterBlockAndWakeupHandlers(block_handler, wakeup_handler, xwl_screen);
pScreen->SaveScreen = xwl_save_screen;
pScreen->blackPixel = 0;
pScreen->whitePixel = 1;
......
......@@ -63,17 +63,6 @@ static RootlessFrameProcsRec winMWExtWMProcs = {
};
#endif
/*
* Prototypes
*/
/*
* Local functions
*/
static Bool
winSaveScreen(ScreenPtr pScreen, int on);
/*
* Determine what type of screen we are initializing
* and call the appropriate procedure to intiailize
......@@ -327,9 +316,6 @@ winFinishScreenInitFB(int i, ScreenPtr pScreen, int argc, char **argv)
pScreen->whitePixel = 1;
}
/* Place our save screen function */
pScreen->SaveScreen = winSaveScreen;
/* Finish fb initialization */
if (!fbFinishScreenInit(pScreen,
pScreenInfo->pfb,
......@@ -552,10 +538,3 @@ winFinishScreenInitFB(int i, ScreenPtr pScreen, int argc, char **argv)
return TRUE;
}
/* See Porting Layer Definition - p. 33 */
static Bool
winSaveScreen(ScreenPtr pScreen, int on)
{
return TRUE;
}
......@@ -124,6 +124,12 @@ miCloseScreen(ScreenPtr pScreen)
return ((*pScreen->DestroyPixmap) ((PixmapPtr) pScreen->devPrivate));
}
static Bool
miSaveScreen(ScreenPtr pScreen, int on)
{
return TRUE;
}
/* With the introduction of pixmap privates, the "screen pixmap" can no
* longer be created in miScreenInit, since all the modules that could
* possibly ask for pixmap private space have not been initialized at
......@@ -242,7 +248,9 @@ miScreenInit(ScreenPtr pScreen, void *pbits, /* pointer to screen bits */
pScreen->CloseScreen = miCloseScreen;
}
/* else CloseScreen */
/* QueryBestSize, SaveScreen, GetImage, GetSpans */
/* QueryBestSize */
pScreen->SaveScreen = miSaveScreen;
/* GetImage, GetSpans */
pScreen->SourceValidate = (SourceValidateProcPtr) 0;
/* CreateWindow, DestroyWindow, PositionWindow, ChangeWindowAttributes */
/* RealizeWindow, UnrealizeWindow */
......
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