patches/xscreensaver-11-dpms.diff
author alanc
Thu, 27 May 2010 03:04:15 +0000
changeset 18039 93dd6ed68b16
parent 18027 aecb9b8c6ef2
permissions -rw-r--r--
2010-05-26 Alan Coopersmith <[email protected]> * patches/xscreensaver-02-Sun.app-defaults.diff, * patches/xscreensaver-03-GNOME-desktop.diff, * patches/xscreensaver-04-solaris-paths.diff, * patches/xscreensaver-05-dont-bug-jwz.diff, * patches/xscreensaver-06-gtk-lock.diff, * patches/xscreensaver-07-allow-root.diff, * patches/xscreensaver-08-passwdTimeout-pref.diff, * patches/xscreensaver-09-xinput.diff, * patches/xscreensaver-10-i18n.diff, * patches/xscreensaver-11-dpms.diff, * patches/xscreensaver-12-gl-error-capture.diff, * patches/xscreensaver-13-trusted.diff, * patches/xscreensaver-14-pam_audit.diff, * patches/xscreensaver-15-OpenSolaris-colors.diff, * patches/xscreensaver-16-barcode-hack.diff, * patches/xscreensaver-17-glsnake.diff, * patches/xscreensaver-18-bug-6461887.diff, * patches/xscreensaver-19-bug-6573182.diff, * patches/xscreensaver-20-bug-6610282.diff, * patches/xscreensaver-21-bug-6583181.diff, * patches/xscreensaver-22-notice_events.diff, * patches/xscreensaver-23-bug-6583247.diff, * patches/xscreensaver-25-bug-6859039.diff, * patches/xscreensaver-26-bug-xrandr.diff: - Make code more readable/maintainable by cleaning up comments, making formatting & indentation consistent. - Fix some copyright dates based on history from X gate - Change a few more #ifdef sun to #ifdef __sun for consistency.

/*
 * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
 *
 * Permission is hereby granted, free of charge, to any person obtaining a
 * copy of this software and associated documentation files (the "Software"),
 * to deal in the Software without restriction, including without limitation
 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
 * and/or sell copies of the Software, and to permit persons to whom the
 * Software is furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice (including the next
 * paragraph) shall be included in all copies or substantial portions of the
 * Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 * DEALINGS IN THE SOFTWARE.
 */

Allow xset dpms settings to override .xscreensaver.


diff -Nurp -x '*~' -x '*.orig' xscreensaver-5.11/driver/timers.c xscreensaver-5.11/driver/timers.c
--- xscreensaver-5.11/driver/timers.c	2009-05-27 17:19:00.463193000 -0700
+++ xscreensaver-5.11/driver/timers.c	2009-05-27 17:19:17.662370000 -0700
@@ -1499,6 +1499,8 @@ watchdog_timer (XtPointer closure, XtInt
 
   /* If the DPMS settings on the server have changed, change them back to
      what ~/.xscreensaver says they should be. */
+  /* mali- No!! if someone uses xset then let the changes be picked by
+   * xscreensaver...do not have to regulate everything from .xscreensaver.
   sync_server_dpms_settings (si->dpy,
                              (p->dpms_enabled_p  &&
                               p->mode != DONT_BLANK),
@@ -1506,6 +1508,7 @@ watchdog_timer (XtPointer closure, XtInt
                              p->dpms_suspend / 1000,
                              p->dpms_off / 1000,
                              False);
+  **/
 
   if (si->screen_blanked_p)
     {
diff -Nurp -x '*~' -x '*.orig' xscreensaver-5.11/driver/xscreensaver.c xscreensaver-5.11/driver/xscreensaver.c
--- xscreensaver-5.11/driver/xscreensaver.c	2009-05-27 17:19:00.469448000 -0700
+++ xscreensaver-5.11/driver/xscreensaver.c	2009-05-27 17:19:17.663626000 -0700
@@ -1528,6 +1528,10 @@ main (int argc, char **argv)
   init_sigchld ();
 
   disable_builtin_screensaver (si, True);
+/*****
+  mali- this may need to be taken out in future if it hinders user
+  setting dpms values through xset.
+ *****/
   sync_server_dpms_settings (si->dpy,
                              (p->dpms_enabled_p  &&
                               p->mode != DONT_BLANK),