summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEamon Walsh <ewalsh@tycho.nsa.gov>2007-11-19 16:55:09 -0500
committerEamon Walsh <ewalsh@moss-charon.epoch.ncsc.mil>2007-11-19 16:59:34 -0500
commit60be452c2e88342f92a76ba5ec7d90b5b0211aaf (patch)
treec96350b4a3f01713ad4e4f80cf5972ef19572f5e
parenta95bb52b4366d85fc049130c60af5c9e727c565b (diff)
xace: restore the old SaveScreens function and introduce new API, since the
old version is called from drivers...
-rw-r--r--Xext/saver.c4
-rw-r--r--Xext/xtest.c2
-rw-r--r--dix/dispatch.c2
-rw-r--r--dix/main.c4
-rw-r--r--dix/window.c8
-rw-r--r--hw/darwin/darwinEvents.c2
-rw-r--r--hw/dmx/dmxdpms.c2
-rw-r--r--hw/xfree86/common/xf86DPMS.c2
-rw-r--r--hw/xfree86/common/xf86Events.c4
-rw-r--r--hw/xfree86/common/xf86PM.c2
-rw-r--r--hw/xfree86/loader/dixsym.c1
-rw-r--r--include/window.h6
-rw-r--r--mi/mieq.c2
-rw-r--r--os/WaitFor.c2
14 files changed, 27 insertions, 16 deletions
diff --git a/Xext/saver.c b/Xext/saver.c
index 6905fc678..43dd3e2de 100644
--- a/Xext/saver.c
+++ b/Xext/saver.c
@@ -468,8 +468,8 @@ ScreenSaverFreeAttr (value, id)
pPriv->attr = NULL;
if (pPriv->hasWindow)
{
- SaveScreens (serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
- SaveScreens (serverClient, SCREEN_SAVER_FORCER, ScreenSaverActive);
+ dixSaveScreens (serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
+ dixSaveScreens (serverClient, SCREEN_SAVER_FORCER, ScreenSaverActive);
}
CheckScreenPrivate (pScreen);
return TRUE;
diff --git a/Xext/xtest.c b/Xext/xtest.c
index 3895a0073..effa3b904 100644
--- a/Xext/xtest.c
+++ b/Xext/xtest.c
@@ -459,7 +459,7 @@ ProcXTestFakeInput(client)
break;
}
if (screenIsSaved == SCREEN_SAVER_ON)
- SaveScreens(serverClient, SCREEN_SAVER_OFF, ScreenSaverReset);
+ dixSaveScreens(serverClient, SCREEN_SAVER_OFF, ScreenSaverReset);
ev->u.keyButtonPointer.time = currentTime.milliseconds;
(*dev->public.processInputProc)(ev, dev, nev);
return client->noClientException;
diff --git a/dix/dispatch.c b/dix/dispatch.c
index f7196fde7..0c8e6b133 100644
--- a/dix/dispatch.c
+++ b/dix/dispatch.c
@@ -3582,7 +3582,7 @@ int ProcForceScreenSaver(ClientPtr client)
client->errorValue = stuff->mode;
return BadValue;
}
- rc = SaveScreens(client, SCREEN_SAVER_FORCER, (int)stuff->mode);
+ rc = dixSaveScreens(client, SCREEN_SAVER_FORCER, (int)stuff->mode);
if (rc != Success)
return rc;
return client->noClientException;
diff --git a/dix/main.c b/dix/main.c
index 543e94c86..bc00ac5e5 100644
--- a/dix/main.c
+++ b/dix/main.c
@@ -425,7 +425,7 @@ main(int argc, char *argv[], char *envp[])
for (i = 0; i < screenInfo.numScreens; i++)
InitRootWindow(WindowTable[i]);
DefineInitialRootWindow(WindowTable[0]);
- SaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
+ dixSaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
#ifdef PANORAMIX
if (!noPanoramiXExtension) {
@@ -446,7 +446,7 @@ main(int argc, char *argv[], char *envp[])
/* Now free up whatever must be freed */
if (screenIsSaved == SCREEN_SAVER_ON)
- SaveScreens(serverClient, SCREEN_SAVER_OFF, ScreenSaverReset);
+ dixSaveScreens(serverClient, SCREEN_SAVER_OFF, ScreenSaverReset);
FreeScreenSaverTimer();
CloseDownExtensions();
diff --git a/dix/window.c b/dix/window.c
index f183aa3b7..f12c82b08 100644
--- a/dix/window.c
+++ b/dix/window.c
@@ -3337,7 +3337,7 @@ static void DrawLogo(
#endif
_X_EXPORT int
-SaveScreens(ClientPtr client, int on, int mode)
+dixSaveScreens(ClientPtr client, int on, int mode)
{
int rc, i, what, type;
@@ -3455,6 +3455,12 @@ SaveScreens(ClientPtr client, int on, int mode)
return Success;
}
+_X_EXPORT int
+SaveScreens(int on, int mode)
+{
+ return dixSaveScreens(serverClient, on, mode);
+}
+
static Bool
TileScreenSaver(int i, int kind)
{
diff --git a/hw/darwin/darwinEvents.c b/hw/darwin/darwinEvents.c
index 97ad8577e..4980cf271 100644
--- a/hw/darwin/darwinEvents.c
+++ b/hw/darwin/darwinEvents.c
@@ -276,7 +276,7 @@ void ProcessInputEvents(void) {
while (darwinEventQueue.head != darwinEventQueue.tail)
{
if (screenIsSaved == SCREEN_SAVER_ON)
- SaveScreens(serverClient, SCREEN_SAVER_OFF, ScreenSaverReset);
+ dixSaveScreens(serverClient, SCREEN_SAVER_OFF, ScreenSaverReset);
e = &darwinEventQueue.events[darwinEventQueue.head];
xe = e->event;
diff --git a/hw/dmx/dmxdpms.c b/hw/dmx/dmxdpms.c
index 8c745a6aa..2af160556 100644
--- a/hw/dmx/dmxdpms.c
+++ b/hw/dmx/dmxdpms.c
@@ -175,7 +175,7 @@ void dmxDPMSTerm(DMXScreenInfo *dmxScreen)
void dmxDPMSWakeup(void)
{
if (screenIsSaved == SCREEN_SAVER_ON)
- SaveScreens(serverClient, SCREEN_SAVER_OFF, ScreenSaverReset);
+ dixSaveScreens(serverClient, SCREEN_SAVER_OFF, ScreenSaverReset);
#ifdef DPMSExtension
if (DPMSPowerLevel) DPMSSet(serverClient, 0);
#endif
diff --git a/hw/xfree86/common/xf86DPMS.c b/hw/xfree86/common/xf86DPMS.c
index 536d38e8f..43efb8ed4 100644
--- a/hw/xfree86/common/xf86DPMS.c
+++ b/hw/xfree86/common/xf86DPMS.c
@@ -153,7 +153,7 @@ DPMSSet(ClientPtr client, int level)
return Success;
if (level != DPMSModeOn) {
- rc = SaveScreens(client, SCREEN_SAVER_FORCER, ScreenSaverActive);
+ rc = dixSaveScreens(client, SCREEN_SAVER_FORCER, ScreenSaverActive);
if (rc != Success)
return rc;
}
diff --git a/hw/xfree86/common/xf86Events.c b/hw/xfree86/common/xf86Events.c
index bc2fe0912..2b7cb121d 100644
--- a/hw/xfree86/common/xf86Events.c
+++ b/hw/xfree86/common/xf86Events.c
@@ -906,7 +906,7 @@ xf86VTSwitch()
(*xf86Screens[i]->EnableDisableFBAccess) (i, TRUE);
}
}
- SaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
+ dixSaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
pInfo = xf86InputDevs;
while (pInfo) {
@@ -970,7 +970,7 @@ xf86VTSwitch()
}
/* Turn screen saver off when switching back */
- SaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
+ dixSaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
pInfo = xf86InputDevs;
while (pInfo) {
diff --git a/hw/xfree86/common/xf86PM.c b/hw/xfree86/common/xf86PM.c
index 278a51474..7c8320dee 100644
--- a/hw/xfree86/common/xf86PM.c
+++ b/hw/xfree86/common/xf86PM.c
@@ -116,7 +116,7 @@ resume(pmEvent event, Bool undo)
if (xf86Screens[i]->EnableDisableFBAccess)
(*xf86Screens[i]->EnableDisableFBAccess) (i, TRUE);
}
- SaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
+ dixSaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
pInfo = xf86InputDevs;
while (pInfo) {
EnableDevice(pInfo->dev);
diff --git a/hw/xfree86/loader/dixsym.c b/hw/xfree86/loader/dixsym.c
index 139e23c6e..1a259f5e8 100644
--- a/hw/xfree86/loader/dixsym.c
+++ b/hw/xfree86/loader/dixsym.c
@@ -319,6 +319,7 @@ _X_HIDDEN void *dixLookupTab[] = {
SYMFUNC(NotClippedByChildren)
SYMFUNC(ResizeChildrenWinSize)
SYMFUNC(SaveScreens)
+ SYMFUNC(dixSaveScreens)
SYMFUNC(SendVisibilityNotify)
SYMFUNC(SetWinSize)
SYMFUNC(SetBorderSize)
diff --git a/include/window.h b/include/window.h
index f85eceb2d..9943f903c 100644
--- a/include/window.h
+++ b/include/window.h
@@ -204,11 +204,15 @@ extern RegionPtr NotClippedByChildren(
extern void SendVisibilityNotify(
WindowPtr /*pWin*/);
-extern int SaveScreens(
+extern int dixSaveScreens(
ClientPtr client,
int on,
int mode);
+extern int SaveScreens(
+ int on,
+ int mode);
+
extern WindowPtr FindWindowWithOptional(
WindowPtr /*w*/);
diff --git a/mi/mieq.c b/mi/mieq.c
index 5093023c7..d946e7d04 100644
--- a/mi/mieq.c
+++ b/mi/mieq.c
@@ -200,7 +200,7 @@ mieqProcessInputEvents(void)
while (miEventQueue.head != miEventQueue.tail) {
if (screenIsSaved == SCREEN_SAVER_ON)
- SaveScreens (serverClient, SCREEN_SAVER_OFF, ScreenSaverReset);
+ dixSaveScreens (serverClient, SCREEN_SAVER_OFF, ScreenSaverReset);
#ifdef DPMSExtension
else if (DPMSPowerLevel != DPMSModeOn)
SetScreenSaverTimer();
diff --git a/os/WaitFor.c b/os/WaitFor.c
index 9281ba8ea..cfba251b0 100644
--- a/os/WaitFor.c
+++ b/os/WaitFor.c
@@ -647,7 +647,7 @@ ScreenSaverTimeoutExpire(OsTimerPtr timer,CARD32 now,pointer arg)
}
ResetOsBuffers(); /* not ideal, but better than nothing */
- SaveScreens(serverClient, SCREEN_SAVER_ON, ScreenSaverActive);
+ dixSaveScreens(serverClient, SCREEN_SAVER_ON, ScreenSaverActive);
if (ScreenSaverInterval > 0)
{