[Goodies-commits] r7377 - in xfce4-power-manager/trunk: . doc doc/C settings src

Ali Abdallah aliov at xfce.org
Wed May 20 10:31:38 CEST 2009


Author: aliov
Date: 2009-05-20 08:31:38 +0000 (Wed, 20 May 2009)
New Revision: 7377

Added:
   xfce4-power-manager/trunk/doc/C/xfce4-power-manager.xml.in
Removed:
   xfce4-power-manager/trunk/doc/C/xfce4-power-manager.xml
Modified:
   xfce4-power-manager/trunk/ChangeLog
   xfce4-power-manager/trunk/configure.ac.in
   xfce4-power-manager/trunk/doc/C/Makefile.am
   xfce4-power-manager/trunk/doc/C/xfce4-power-manager.html
   xfce4-power-manager/trunk/doc/Makefile.am
   xfce4-power-manager/trunk/settings/xfpm-settings-main.c
   xfce4-power-manager/trunk/settings/xfpm-settings.c
   xfce4-power-manager/trunk/src/xfpm-engine.c
   xfce4-power-manager/trunk/src/xfpm-main.c
   xfce4-power-manager/trunk/src/xfpm-shutdown.c
   xfce4-power-manager/trunk/src/xfpm-shutdown.h
   xfce4-power-manager/trunk/src/xfpm-tray-icon.c
Log:
	* :Correct the makefile of the doc
	* :Reduce suspend/hibernate timeout if the user disable screen saver lock

Modified: xfce4-power-manager/trunk/ChangeLog
===================================================================
--- xfce4-power-manager/trunk/ChangeLog	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/ChangeLog	2009-05-20 08:31:38 UTC (rev 7377)
@@ -1,3 +1,7 @@
+2009-05-20 10:30
+	* :Correct the makefile of the doc
+	* :Reduce suspend/hibernate timeout if the user disable screen saver lock
+
 2009-05-19 14:15
 	* RC2: release
 

Modified: xfce4-power-manager/trunk/configure.ac.in
===================================================================
--- xfce4-power-manager/trunk/configure.ac.in	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/configure.ac.in	2009-05-20 08:31:38 UTC (rev 7377)
@@ -3,7 +3,7 @@
 m4_define([xfpm_version_minor],  [8])
 m4_define([xfpm_version_micro],  [0])
 m4_define([xfpm_version_build],  [])
-m4_define([xfpm_version_tag],[RC2])
+m4_define([xfpm_version_tag],[r at REVISION@])
 m4_define([xfpm_version], [xfpm_version_major().xfpm_version_minor().xfpm_version_micro()ifelse(xfpm_version_tag(), [svn], [xfpm_version_tag().xfpm_version_build()], [xfpm_version_tag()])])
 
 AC_INIT([xfce4-power-manager], [xfpm_version], [http://bugzilla.xfce.org/])
@@ -127,13 +127,41 @@
 fi
 AM_CONDITIONAL([BUILD_PANEL_PLUGINS], [test "x$build_panel_plugins" = "xyes"])
 
+#=======================================================#
+#              Generate html doc		        #
+#=======================================================#
+AC_ARG_ENABLE([xsltproc],
+              [AC_HELP_STRING([--enable-xsltproc],
+                              [Use xsltproc to generate HTML documentation @<:@default=no@:>@])],
+                              , [enable_xsltproc=no])
+if test "x$enable_xsltproc" = "xyes"; then
+    AC_PATH_PROG([XSLTPROC], [xsltproc], [no])
+    if test "x$XSLTPROC" = "xno"; then
+        AC_MSG_FAILURE([*** xsltproc was requested, but not found.])
+    fi
+fi
+AM_CONDITIONAL([HAVE_XSLTPROC], [test "x$enable_xsltproc" = "xyes"])
 
 #=======================================================#
+#              Support for doc translations	        #
+#=======================================================#
+AC_ARG_ENABLE([xml2po],
+              [AC_HELP_STRING([--enable-xml2po],
+                              [Use xml2po to translate documentation @<:@default=no@:>@])],
+              [], [enable_xml2po=no])
+if test "x$enable_xml2po" = "xyes"; then
+    AC_PATH_PROG([XML2PO], [xml2po], [no])
+    if test "x$XML2PO" = "xno"; then
+        AC_MSG_FAILURE([*** xml2po was requested, but not found.])
+    fi
+fi
+AM_CONDITIONAL([ENABLE_XML2PO], [test "x$enable_xml2po" = "xyes"])
+
+#=======================================================#
 #              Check for debugging support              #
 #=======================================================#
 XDT_FEATURE_DEBUG
 
-
 AC_OUTPUT([
 Makefile
 libxfpm/Makefile
@@ -148,6 +176,7 @@
 data/icons/scalable/actions/Makefile
 doc/Makefile
 doc/C/Makefile
+doc/C/xfce4-power-manager.xml
 doc/C/images/Makefile
 po/Makefile.in
 ])

Modified: xfce4-power-manager/trunk/doc/C/Makefile.am
===================================================================
--- xfce4-power-manager/trunk/doc/C/Makefile.am	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/doc/C/Makefile.am	2009-05-20 08:31:38 UTC (rev 7377)
@@ -1,5 +1,5 @@
 SUBDIRS = \
-  	 images
+	 images
 
 noinst_DATA = \
 	xfce4-power-manager.xml
@@ -11,6 +11,11 @@
 
 EXTRA_DIST = $(noinst_DATA) $(doc_DATA)
 
-html: $(srcdir)/xfce4-power-manager.xml
-	xsltproc $(top_srcdir)/doc/xfce-nochunk.xsl \
-		$(srcdir)/xfce4-power-manager.xml
+if MAINTAINER_MODE
+if HAVE_XSLTPROC
+
+xfce4-power-manager.html: $(srcdir)/xfce4-power-manager.xml
+	$(XSLTPROC) $(top_srcdir)/doc/xfce-nochunk.xsl $(srcdir)/xfce4-power-manager.xml
+
+endif
+endif

Modified: xfce4-power-manager/trunk/doc/C/xfce4-power-manager.html
===================================================================
--- xfce4-power-manager/trunk/doc/C/xfce4-power-manager.html	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/doc/C/xfce4-power-manager.html	2009-05-20 08:31:38 UTC (rev 7377)
@@ -1,5 +1,5 @@
-<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>Xfce 4 Power Manager</title><link rel="stylesheet" href="../xfce.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.73.2"><link rel="start" href="#xfce4-power-manager" title="Xfce 4 Power Manager"><link rel="next" href="#xfpm-intro" title="Introduction"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="article" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="xfce4-power-manager"></a>Xfce 4 Power Manager</h2></div><div><div class="authorgroup"><div class="author"><h3 class="author"><span class="firstname">Ali</span> <span class="surname">Abdallah</span></h3><div class="affiliation"><div class="address"><p><code class="email"><<a class="email" href="mailto:aliov at xfce.org">aliov at xfce.org</a>></code></p></div></div></div></div></div><div><span xmlns="http://www.w3.org/TR/xhtml1/transition
 al" class="releaseinfo">This manual describes <strong xmlns="" class="application"><code>xfce4-power-manager</code></strong> version 0.6.4
-<br></br></span></div><div><p class="copyright">Copyright © 2008 Ali Abdallah</p></div></div><hr></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><span class="sect1"><a href="#xfpm-intro">Introduction</a></span></dt><dd><dl><dt><span class="sect2"><a href="#xfpm-started">Getting Started</a></span></dt></dl></dd><dt><span class="sect1"><a href="#xfpm-configuration">Power Manager Configuration</a></span></dt><dd><dl><dt><span class="sect2"><a href="#xfpm-general">General Settings</a></span></dt><dt><span class="sect2"><a href="#xfpm-cpu">CPU Settings</a></span></dt><dt><span class="sect2"><a href="#xfpm-battery">Battery settings</a></span></dt><dt><span class="sect2"><a href="#xfpm-button">Keyboard shortcuts</a></span></dt><dt><span class="sect2"><a href="#xfpm-monitor">Monitor settings</a></span></dt></dl></dd><dt><span class="sect1"><a href="#xfpm-systray-notify">System Tray Icon and Notification</a></span></dt><dt><span class="sect1"><a href="#xfpm-faq">FAQ</a
 ></span></dt><dt><span class="sect1"><a href="#xfpm-about">About <strong class="application"><code>xfce4-power-manager</code></strong></a></span></dt></dl></div><p> </p><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="xfpm-intro"></a>Introduction</h2></div></div></div>
+<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>Xfce 4 Power Manager</title><link rel="stylesheet" href="../xfce.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.73.2"><link rel="start" href="#xfce4-power-manager" title="Xfce 4 Power Manager"><link rel="next" href="#xfpm-intro" title="Introduction"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="article" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="xfce4-power-manager"></a>Xfce 4 Power Manager</h2></div><div><div class="authorgroup"><div class="author"><h3 class="author"><span class="firstname">Ali</span> <span class="surname">Abdallah</span></h3><div class="affiliation"><div class="address"><p><code class="email"><<a class="email" href="mailto:aliov at xfce.org">aliov at xfce.org</a>></code></p></div></div></div></div></div><div><span xmlns="http://www.w3.org/TR/xhtml1/trans
 itional" class="releaseinfo">This manual describes <strong xmlns="" class="application"><code>xfce4-power-manager</code></strong> version 0.8.0r07351
+<br></br></span></div><div><p class="copyright">Copyright © 2008 Ali Abdallah</p></div></div><hr></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><span class="sect1"><a href="#xfpm-intro">Introduction</a></span></dt><dd><dl><dt><span class="sect2"><a href="#xfpm-started">Getting Started</a></span></dt></dl></dd><dt><span class="sect1"><a href="#xfpm-configuration">Power Manager Configuration</a></span></dt><dd><dl><dt><span class="sect2"><a href="#xfpm-general">General Settings</a></span></dt><dt><span class="sect2"><a href="#xfpm-cpu">CPU Settings</a></span></dt><dt><span class="sect2"><a href="#xfpm-battery">Battery settings</a></span></dt><dt><span class="sect2"><a href="#xfpm-button">Keyboard shortcuts</a></span></dt><dt><span class="sect2"><a href="#xfpm-monitor">Monitor settings</a></span></dt></dl></dd><dt><span class="sect1"><a href="#xfpm-systray-notify">System Tray Icon and Notification</a></span></dt><dt><span class="sect1"><a href="#xfpm-faq">FAQ</a>
 </span></dt><dt><span class="sect1"><a href="#xfpm-about">About <strong class="application"><code>xfce4-power-manager</code></strong></a></span></dt></dl></div><p> </p><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="xfpm-intro"></a>Introduction</h2></div></div></div>
   The Xfce4 power manager is a part of the Xfce goodies project and features cpu frequency control,
   battery monitoring, monitor DPMS control, LCD brightness control, lid sleep and power buttons controls.
   All those features can be controlled from the user interface settings dialog.
@@ -8,19 +8,19 @@
   a popup will be displayed to run the power manger if it is not already running. 
   Once the power manager is launched for the first time, it will place an autostart desktop file in your .config/autostart
   in order to be able to be launched automatically each time you log into your Xfce desktop.
-  </p></div></div><p> </p><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="xfpm-configuration"></a>Power Manager Configuration</h2></div></div></div><div class="figure"><a name="id2902531"></a><p class="title"><b>Figure 1. Power Manager settings</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/settings.png" alt="Power Manager settings"></div></div></div></div><p><br class="figure-break"></p><p>
+  </p></div></div><p> </p><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="xfpm-configuration"></a>Power Manager Configuration</h2></div></div></div><div class="figure"><a name="id2551345"></a><p class="title"><b>Figure 1. Power Manager settings</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/settings.png" alt="Power Manager settings"></div></div></div></div><p><br class="figure-break"></p><p>
   Almost all the <strong class="application"><code>xfce4-power-manager</code></strong> items are configurable from the configuration window, laptop users can set up 
-  a power profile for two different modes “on battery power” and “on ac power”, desktop users still can change 
+  a power profile for two different modes “on battery power” and “on ac power”, desktop users still can change 
   DPMS settings and CPU frequency.
   </p><p>
   The settings dialog differs from one system to another depending on the computer (PC,laptop,...) and on
   the available manageabale interfaces.  
   </p><p>
   In this section we will describe the possible configuration for the power manager.
-  </p><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="xfpm-general"></a>General Settings</h3></div></div></div><div class="figure"><a name="id2863889"></a><p class="title"><b>Figure 2. General settings</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/general-settings.png" alt="General settings"></div></div></div></div><p><br class="figure-break"></p><p>
+  </p><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="xfpm-general"></a>General Settings</h3></div></div></div><div class="figure"><a name="id2512626"></a><p class="title"><b>Figure 2. General settings</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/general-settings.png" alt="General settings"></div></div></div></div><p><br class="figure-break"></p><p>
 	Here you can select the configuration of the system tray icon, enable/disable cpu frequency and DPMS controls. 
 	For example, you would need to disable DPMS control when watching a movie.	
-	</p></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="xfpm-cpu"></a>CPU Settings</h3></div></div></div><div class="figure"><a name="id2863934"></a><p class="title"><b>Figure 3. CPU Linux governors</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/cpu-settings.png" alt="CPU Linux governors"></div></div></div></div><p><br class="figure-break"></p><p>
+	</p></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="xfpm-cpu"></a>CPU Settings</h3></div></div></div><div class="figure"><a name="id2512671"></a><p class="title"><b>Figure 3. CPU Linux governors</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/cpu-settings.png" alt="CPU Linux governors"></div></div></div></div><p><br class="figure-break"></p><p>
 	The linux governors found in the system are listed as radio buttons.
 	If the acpi_cpufreq module is not loaded in the kernel or the cpu itself does not support frequency
 	changes these options might not show.
@@ -34,8 +34,8 @@
 	 Same as Ondemand but differs in behaviour in that it gracefully increases and decreases 
 	 the CPU speed rather than jumping to max speed the moment there is any load on the CPU.
 	</p></dd></dl></div><p>
-NOTE:In <strong class="application"><code>xfce4-power-manager</code></strong> version 0.6.4 only Linux is supported for changing the CPU frequency.
-</p></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="xfpm-battery"></a>Battery settings</h3></div></div></div><div class="figure"><a name="id2864059"></a><p class="title"><b>Figure 4. Battery settings</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/battery-settings.png" alt="Battery settings"></div></div></div></div><p><br class="figure-break"></p><p>
+NOTE:In <strong class="application"><code>xfce4-power-manager</code></strong> version 0.8.0r07351 only Linux is supported for changing the CPU frequency.
+</p></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="xfpm-battery"></a>Battery settings</h3></div></div></div><div class="figure"><a name="id2517651"></a><p class="title"><b>Figure 4. Battery settings</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/battery-settings.png" alt="Battery settings"></div></div></div></div><p><br class="figure-break"></p><p>
 	The user can select the his critical battery percentage, usually this is for a laptop or
 	UPS battery, this option is important for a broken battery for example, which lasts only 5 minutes when it
 	is 10% charged.    
@@ -46,11 +46,11 @@
    The battery notification is a way to notify the user when the battery state changes ( ex: battery charge is full )
    <p>
    
-   </p></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="xfpm-button"></a>Keyboard shortcuts</h3></div></div></div><div class="figure"><a name="id2864116"></a><p class="title"><b>Figure 5. button control</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/button-settings.png" alt="button control"></div></div></div></div><p><br class="figure-break"></p>
+   </p></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="xfpm-button"></a>Keyboard shortcuts</h3></div></div></div><div class="figure"><a name="id2517708"></a><p class="title"><b>Figure 5. button control</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/button-settings.png" alt="button control"></div></div></div></div><p><br class="figure-break"></p>
    For those buttons you can define an action to be taken by the power manager when pressing to one of them 
    - for example when you close the laptop screen. 
     
-  </div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="xfpm-monitor"></a>Monitor settings</h3></div></div></div><div class="figure"><a name="id2868355"></a><p class="title"><b>Figure 6. Monitor DPMS and LCD brightness</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/monitor-settings.png" alt="Monitor DPMS and LCD brightness"></div></div></div></div><p><br class="figure-break"></p><p>
+  </div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="xfpm-monitor"></a>Monitor settings</h3></div></div></div><div class="figure"><a name="id2517749"></a><p class="title"><b>Figure 6. Monitor DPMS and LCD brightness</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/monitor-settings.png" alt="Monitor DPMS and LCD brightness"></div></div></div></div><p><br class="figure-break"></p><p>
 	DPMS is an old X extension that allows standby/suspend/turn off options of the monitor, usually the timeouts 
 	have to be consecutive, so standby timeout is less than suspend timeout and so on, but any option can always
 	be disabled.
@@ -58,8 +58,8 @@
 	For laptop users, clicking on the checkbox allows the power manager to reduce the screen luminosity when
 	it detects that system in running on battery power and increase it again when the system is running
 	on AC power.
-	</p></div></div><p> </p><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="xfpm-systray-notify"></a>System Tray Icon and Notification</h2></div></div></div><p>
-</p><div class="figure"><a name="id2868417"></a><p class="title"><b>Figure 7. Battery icon in the system tray</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/battery.png" alt="Battery icon in the system tray"></div></div></div></div><p><br class="figure-break"></p><p>
+	</p></div></div><p> </p><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="xfpm-systray-notify"></a>System Tray Icon and Notification</h2></div></div></div><p>
+</p><div class="figure"><a name="id2512977"></a><p class="title"><b>Figure 7. Battery icon in the system tray</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/battery.png" alt="Battery icon in the system tray"></div></div></div></div><p><br class="figure-break"></p><p>
 
 The "system tray" is an application running on a given X screen that can display small icons 
 provided by running applications. In Xfce, it is a panel plugin that catches the icon and resizes it
@@ -68,11 +68,11 @@
 </p><p>
 <strong class="application"><code>xfce4-power-manager</code></strong> uses GtkStatusIcon to display the different kinds of batteries found in the system.
 </p><p>
-</p><div class="figure"><a name="id2868466"></a><p class="title"><b>Figure 8. Battery Notification</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/battery-discharging.png" alt="Battery Notification"></div></div></div></div><p><br class="figure-break"></p><p>
+</p><div class="figure"><a name="id2513026"></a><p class="title"><b>Figure 8. Battery Notification</b></p><div class="figure-contents"><div class="screenshot"><div class="mediaobject"><img src="images/battery-discharging.png" alt="Battery Notification"></div></div></div></div><p><br class="figure-break"></p><p>
 
 To notify the user about the status of the battery, serious errors occured, the notification daemon is used
 to display such messages.
-</p></div><p> </p><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="xfpm-faq"></a>FAQ</h2></div></div></div><div class="variablelist"><dl><dt><span class="term">Q: Why the icons look very similar to the icon of gnome power manager?</span></dt><dd><p>A: No, they are not similar, they are the same, just there is no point of re-drawing icons,
+</p></div><p> </p><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="xfpm-faq"></a>FAQ</h2></div></div></div><div class="variablelist"><dl><dt><span class="term">Q: Why the icons look very similar to the icon of gnome power manager?</span></dt><dd><p>A: No, they are not similar, they are the same, just there is no point of re-drawing icons,
 	gnome power manager icons are good enough. Not all of them are used.  
 	</p></dd><dt><span class="term">Q: What is the difference between suspend and hibernate?</span></dt><dd><p>A: Suspend is a power save feature. When suspending, the computer is still using power,
 	since the running applications are kept in the memory, but it is the lowest power level that the computer
@@ -88,7 +88,7 @@
 	In the best cases, it will display a warning popup with different options.
 	</p></dd><dt><span class="term">Q: I select the option of the LCD brightness control but I do not see the brightness changing when I switch 
 	from AC adapter to battery power?</span></dt><dd><p>A: Your kernel does not have the right driver, or the driver is not loaded.
-	</p></dd></dl></div></div><p> </p><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="xfpm-about"></a>About <strong class="application"><code>xfce4-power-manager</code></strong></h2></div></div></div><p>
+	</p></dd></dl></div></div><p> </p><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="xfpm-about"></a>About <strong class="application"><code>xfce4-power-manager</code></strong></h2></div></div></div><p>
 	This power manager was written following the philosophy of Xfce, having light weight application that does
 	what the user is expecting from it.
 	</p><p>To report a bug or make a suggestion regarding this application or
@@ -97,7 +97,7 @@
     please ask on the <a class="ulink" href="http://lunar-linux.org/mailman/listinfo/xfce" target="_top">xfce</a> mailing list. Development discussion takes
     place on the <a class="ulink" href="http://lunar-linux.org/mailman/listinfo/xfce4-dev" target="_top">xfce4-dev</a> mailing list
     or on  <a class="ulink" href="http://lunar-linux.org/mailman/listinfo/xfce4-goodies-dev" target="_top">xfce4-goodies-dev</a> mailing list.
-  </p></div><p> </p><p> This program is distributed under the terms of the
+  </p></div><p> </p><p> This program is distributed under the terms of the
     GNU General Public License as published by the Free Software Foundation; 
     either version 2 of the License, or (at your option) any later version.
   </p><p>You should have received a copy of the GNU General Public License 

Added: xfce4-power-manager/trunk/doc/C/xfce4-power-manager.xml.in
===================================================================
--- xfce4-power-manager/trunk/doc/C/xfce4-power-manager.xml.in	                        (rev 0)
+++ xfce4-power-manager/trunk/doc/C/xfce4-power-manager.xml.in	2009-05-20 08:31:38 UTC (rev 7377)
@@ -0,0 +1,406 @@
+<?xml version='1.0'?> 
+<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" 
+          "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" [
+  <!ENTITY date "October 2008"> 
+  <!ENTITY appversion "@PACKAGE_VERSION@"> 
+  <!ENTITY app "<application>@PACKAGE_NAME@</application>"> 
+]>
+
+<article id="xfce4-power-manager" lang="en">
+<!-- Header --> 
+<articleinfo>
+
+  <title>Xfce 4 Power Manager</title>
+ 
+  <copyright>
+    <year>2008</year> <holder>Ali Abdallah</holder>
+  </copyright>
+
+
+<authorgroup>
+
+    <author>
+      <firstname>Ali</firstname> <surname>Abdallah</surname>
+      <affiliation>
+	<address><email>aliov at xfce.org</email></address>
+      </affiliation>
+    </author>
+    
+<!-- This is appropriate place for other contributors: translators,
+maintainers, etc. Commented out by default.
+
+    <othercredit role="translator">
+      <firstname>Latin</firstname> <surname>Translator 1</surname>
+      <affiliation>
+	<orgname>Latin Translation Team</orgname>
+	<address><email>translator at gnome.org</email> </address>
+      </affiliation> <contrib>Latin translation</contrib>
+    </othercredit>
+-->
+
+</authorgroup>
+
+<releaseinfo>This manual describes &app; version &appversion;
+</releaseinfo>
+
+</articleinfo>
+
+  <!-- extra space -->
+  <para> </para>
+    
+<sect1 id="xfpm-intro">
+  <title>Introduction</title>
+  The Xfce4 power manager is a part of the Xfce goodies project and features cpu frequency control,
+  battery monitoring, monitor DPMS control, LCD brightness control, lid sleep and power buttons controls.
+  All those features can be controlled from the user interface settings dialog.
+  <sect2 id="xfpm-started">
+  <title>Getting Started</title>
+  <para>To launch the Power Manager you need to run the following command &app; -r which you can do from the xfce run
+  command by pressing on ALT-F2, or by going to the Xfce settings manager and clicking on the Power Manager item -
+  a popup will be displayed to run the power manger if it is not already running. 
+  Once the power manager is launched for the first time, it will place an autostart desktop file in your .config/autostart
+  in order to be able to be launched automatically each time you log into your Xfce desktop.
+  </para> 
+  </sect2> 
+</sect1>
+
+ <!-- extra space -->
+  <para> </para>
+ 
+<sect1 id="xfpm-configuration">
+  <title>Power Manager Configuration</title>
+  <para><figure float="0">
+	<title>Power Manager settings</title>
+	<screenshot><mediaobject>
+	<imageobject>
+	<imagedata fileref="images/settings.png" format="PNG"/>
+	</imageobject>
+	<textobject>
+	<phrase></phrase>
+	</textobject>
+	</mediaobject></screenshot>
+</figure></para>
+  <para>
+  Almost all the &app; items are configurable from the configuration window, laptop users can set up 
+  a power profile for two different modes “on battery power” and “on ac power”, desktop users still can change 
+  DPMS settings and CPU frequency.
+  </para>
+  <para>
+  The settings dialog differs from one system to another depending on the computer (PC,laptop,...) and on
+  the available manageabale interfaces.  
+  </para>
+  <para>
+  In this section we will describe the possible configuration for the power manager.
+  </para>
+  <sect2 id="xfpm-general">
+  <title>General Settings</title>
+  <para><figure float="0">
+	<title>General settings</title>
+	<screenshot><mediaobject>
+	<imageobject>
+	<imagedata fileref="images/general-settings.png" format="png"/>
+	</imageobject>
+	<textobject>
+	<phrase></phrase>
+	</textobject>
+	</mediaobject></screenshot>
+	</figure></para>
+	<para>
+	Here you can select the configuration of the system tray icon, enable/disable cpu frequency and DPMS controls. 
+	For example, you would need to disable DPMS control when watching a movie.	
+	</para>
+  </sect2> 
+	  
+  
+  <sect2 id="xfpm-cpu">
+   <title>CPU Settings</title>
+   <para><figure float="0">
+	<title>CPU Linux governors</title>
+	<screenshot><mediaobject>
+	<imageobject>
+	<imagedata fileref="images/cpu-settings.png" format="PNG"/>
+	</imageobject>
+	<textobject>
+	<phrase></phrase>
+	</textobject>
+	</mediaobject></screenshot>
+	</figure></para>
+	<para>
+	The linux governors found in the system are listed as radio buttons.
+	If the acpi_cpufreq module is not loaded in the kernel or the cpu itself does not support frequency
+	changes these options might not show.
+	</para>
+	<para>Here is a brief descritption on linux cpu governors</para>
+		
+<variablelist>
+
+   <varlistentry>
+	<term>Best performance:</term>
+	<listitem>
+	<para> Set CPU to its maximum frequency: consume more power, 
+	and it is not ideal when running on battery.
+	</para>
+	</listitem>
+	</varlistentry>
+	
+	<varlistentry>
+	<term>Best power savings:</term>
+	<listitem>
+	<para> 
+	Set the CPU to its minimum frequency: ideal when running on battery power.	
+	</para>
+	</listitem>
+	</varlistentry>
+	
+	<varlistentry>
+	<term>Ondemand performance:</term>
+	<listitem>
+	<para> What you want is what you get: set the CPU depending on the
+	current usage.
+	</para>
+	</listitem>
+	</varlistentry>	
+	
+	<varlistentry>
+	<term>Good power savings:</term>
+	<listitem>
+	<para> 
+	 Same as Ondemand but differs in behaviour in that it gracefully increases and decreases 
+	 the CPU speed rather than jumping to max speed the moment there is any load on the CPU.
+	</para>
+	</listitem>
+	</varlistentry>	
+	
+</variablelist>
+<para>
+NOTE:In &app; version &appversion; only Linux is supported for changing the CPU frequency.
+</para>
+
+</sect2>  
+  
+  <sect2 id="xfpm-battery">
+    <title>Battery settings</title>
+	<para><figure float="0">
+	<title>Battery settings</title>
+	<screenshot><mediaobject>
+	<imageobject>
+	<imagedata fileref="images/battery-settings.png" format="PNG"/>
+	</imageobject>
+	<textobject>
+	<phrase></phrase>
+	</textobject>
+	</mediaobject></screenshot>
+</figure></para>
+	<para>
+	The user can select the his critical battery percentage, usually this is for a laptop or
+	UPS battery, this option is important for a broken battery for example, which lasts only 5 minutes when it
+	is 10% charged.    
+   </para>
+   <para>
+   The user can define an action to be taken by the power manager in case the battery that is giving the main power
+   for the computer reaches a critical charge level.
+   </para> 
+   The battery notification is a way to notify the user when the battery state changes ( ex: battery charge is full )
+   <para>
+   
+   </para>
+  </sect2>  
+  
+  <sect2 id="xfpm-button">
+    <title>Keyboard shortcuts</title>
+	<para><figure float="0">
+	<title>button control</title>
+	<screenshot><mediaobject>
+	<imageobject>
+	<imagedata fileref="images/button-settings.png" format="PNG"/>
+	</imageobject>
+	<textobject>
+	<phrase></phrase>
+	</textobject>
+	</mediaobject></screenshot>
+</figure></para>
+   For those buttons you can define an action to be taken by the power manager when pressing to one of them 
+   - for example when you close the laptop screen. 
+    
+  </sect2>  
+  
+  <sect2 id="xfpm-monitor">
+   <title>Monitor settings</title>
+   <para><figure float="0">
+	<title>Monitor DPMS and LCD brightness</title>
+	<screenshot><mediaobject>
+	<imageobject>
+	<imagedata fileref="images/monitor-settings.png" format="PNG"/>
+	</imageobject>
+	<textobject>
+	<phrase></phrase>
+	</textobject>
+	</mediaobject></screenshot>
+</figure></para>
+	<para>
+	DPMS is an old X extension that allows standby/suspend/turn off options of the monitor, usually the timeouts 
+	have to be consecutive, so standby timeout is less than suspend timeout and so on, but any option can always
+	be disabled.
+	</para>
+	<para>
+	For laptop users, clicking on the checkbox allows the power manager to reduce the screen luminosity when
+	it detects that system in running on battery power and increase it again when the system is running
+	on AC power.
+	</para>
+	</sect2>  
+</sect1>
+
+<!-- extra space -->
+  <para> </para>
+  
+<sect1 id="xfpm-systray-notify">
+<title>System Tray Icon and Notification</title>
+<para>
+<para><figure float="0">
+	<title>Battery icon in the system tray</title>
+	<screenshot><mediaobject>
+	<imageobject>
+	<imagedata fileref="images/battery.png" format="PNG"/>
+	</imageobject>
+	<textobject>
+	<phrase></phrase>
+	</textobject>
+	</mediaobject></screenshot>
+</figure></para>
+
+The "system tray" is an application running on a given X screen that can display small icons 
+provided by running applications. In Xfce, it is a panel plugin that catches the icon and resizes it
+to the size of the panel, if you don't have this plugin added to the panel you will not see any 
+tray icon, for example pidgin places an icon in the system tray as well as many other applications.
+</para>
+<para>
+&app; uses GtkStatusIcon to display the different kinds of batteries found in the system.
+</para>
+<para>
+<para><figure float="0">
+	<title>Battery Notification</title>
+	<screenshot><mediaobject>
+	<imageobject>
+	<imagedata fileref="images/battery-discharging.png" format="PNG"/>
+	</imageobject>
+	<textobject>
+	<phrase></phrase>
+	</textobject>
+	</mediaobject></screenshot>
+</figure></para>
+
+To notify the user about the status of the battery, serious errors occured, the notification daemon is used
+to display such messages.
+</para>
+</sect1>
+
+ <!-- extra space -->
+  <para> </para>
+  
+<sect1 id="xfpm-faq">
+  <title>FAQ</title>
+  <variablelist>
+
+   <varlistentry>
+	<term>Q: Why the icons look very similar to the icon of gnome power manager?</term>
+	<listitem>
+	<para>A: No, they are not similar, they are the same, just there is no point of re-drawing icons,
+	gnome power manager icons are good enough. Not all of them are used.  
+	</para>
+	</listitem>
+	</varlistentry>
+
+	 <varlistentry>
+	<term>Q: What is the difference between suspend and hibernate?</term>
+	<listitem>
+	<para>A: Suspend is a power save feature. When suspending, the computer is still using power,
+	since the running applications are kept in the memory, but it is the lowest power level that the computer
+	can use. While Hibernate saves the system state on the hard drive and turns off the power, when you start up your 
+	computer	again those data will be loaded and the system back up. 
+	</para>
+	</listitem>
+	</varlistentry>
+	
+	 <varlistentry>
+	<term>Q: Why the options of suspend/hibernate are not there or I can not select them?</term>
+	<listitem>
+	<para>A: Many possible reasons, for example your kernel is not compiled with suspend/hibernate options.
+	Another possible reason is the fact that you are not allowed to use them.
+	</para>
+	</listitem>
+	</varlistentry>
+	
+	 <varlistentry>
+	<term>Q: How the power manager actually suspend or hibernate my system?</term>
+	<listitem>
+	<para>A: The power manager checks if the user is allowed to use power management service, then send a D-Bus message 
+	to HAL asking to suspend/hibernate, usually the methods to suspend or hibernate used by HAL are scripts located in 
+	/usr/lib/hal/scripts/YourOs.
+	</para>
+	</listitem>
+	</varlistentry>
+	
+	 <varlistentry>
+	<term>Q: If the power manager puts the computer in hibernate because my battery charge is critical what will happen
+	if I turn it on again without plugging my adapter?</term>
+	<listitem>
+	<para>A: Nothing actually, the power manager had taken the action defined by the user already.
+	In the best cases, it will display a warning popup with different options.
+	</para>
+	</listitem>
+	</varlistentry>
+	
+	 <varlistentry>
+	<term>Q: I select the option of the LCD brightness control but I do not see the brightness changing when I switch 
+	from AC adapter to battery power?</term>
+	<listitem>
+	<para>A: Your kernel does not have the right driver, or the driver is not loaded.
+	</para>
+	</listitem>
+	</varlistentry>
+		
+</variablelist>
+</sect1>  
+
+ <!-- extra space -->
+  <para> </para>
+<sect1 id="xfpm-about">
+  <title>About &app;</title>
+  <para>
+	This power manager was written following the philosophy of Xfce, having light weight application that does
+	what the user is expecting from it.
+	</para>
+
+  <para>To report a bug or make a suggestion regarding this application or
+    this manual, use the bug tracking system at <ulink 
+      url="http://bugzilla.xfce.org/" 
+      type="http">http://bugzilla.xfce.org/</ulink>. 
+  </para>
+
+  <para>If you have questions about the use or installation of this package,
+    please ask on the <ulink 
+      url="http://lunar-linux.org/mailman/listinfo/xfce"
+      type="http">xfce</ulink> mailing list. Development discussion takes
+    place on the <ulink 
+      url="http://lunar-linux.org/mailman/listinfo/xfce4-dev"
+      type="http">xfce4-dev</ulink> mailing list
+    or on  <ulink 
+      url="http://lunar-linux.org/mailman/listinfo/xfce4-goodies-dev"
+      type="http">xfce4-goodies-dev</ulink> mailing list.
+  </para>
+  
+</sect1>  
+
+ <!-- extra space -->
+  <para> </para>
+  <para> This program is distributed under the terms of the
+    GNU General Public License as published by the Free Software Foundation; 
+    either version 2 of the License, or (at your option) any later version.
+  </para>
+
+  <para>You should have received a copy of the GNU General Public License 
+    along with this program; if not, write to the Free Software 
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA.
+  </para>
+
+</article>

Modified: xfce4-power-manager/trunk/doc/Makefile.am
===================================================================
--- xfce4-power-manager/trunk/doc/Makefile.am	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/doc/Makefile.am	2009-05-20 08:31:38 UTC (rev 7377)
@@ -1,10 +1,7 @@
 SUBDIRS = \
 	C 
-	
+
 noinst_DATA = \
 	xfce-nochunk.xsl
 
-EXTRA_DIST = $(noinst_DATA)
-
-html: Makefile
-	make -C C html
\ No newline at end of file
+EXTRA_DIST = $(noinst_DATA)
\ No newline at end of file

Modified: xfce4-power-manager/trunk/settings/xfpm-settings-main.c
===================================================================
--- xfce4-power-manager/trunk/settings/xfpm-settings-main.c	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/settings/xfpm-settings-main.c	2009-05-20 08:31:38 UTC (rev 7377)
@@ -75,7 +75,7 @@
 
     xfce_textdomain(GETTEXT_PACKAGE, LOCALEDIR, "UTF-8");
     
-    if( !gtk_init_with_args (&argc, &argv, "", option_entries, PACKAGE, &error)) 
+    if( !gtk_init_with_args (&argc, &argv, (gchar *)"", option_entries, (gchar *)PACKAGE, &error)) 
     {
         if( error) 
         {
@@ -95,9 +95,7 @@
     
     if ( error )
     {
-	g_error("%s\n",error->message);
-	g_error_free(error);
-	return EXIT_FAILURE;
+	g_error ("%s\n",error->message);
     }
 
     if ( xfpm_dbus_name_has_owner(dbus_g_connection_get_connection(bus), "org.xfce.PowerManager") ) 

Modified: xfce4-power-manager/trunk/settings/xfpm-settings.c
===================================================================
--- xfce4-power-manager/trunk/settings/xfpm-settings.c	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/settings/xfpm-settings.c	2009-05-20 08:31:38 UTC (rev 7377)
@@ -387,22 +387,19 @@
 	return g_strdup_printf ("%d %s", (gint)value, _("Minutes"));
     else if ( (gint)value == 60)
 	return g_strdup (_("One hour"));
-    else if ( (gint)value > 60 )
-    {
-	h = (gint)value/60;
-	min = (gint)value%60;
-	
-	if ( h <= 1 )
-	    if ( min == 0 )      return g_strdup_printf ("%s", _("One hour"));
-	    else if ( min == 1 ) return g_strdup_printf ("%s %s", _("One hour"),  _("one minute"));
-	    else                 return g_strdup_printf ("%s %d %s", _("One hour"), min, _("minutes"));
-	else 
-	    if ( min == 0 )      return g_strdup_printf ("%d %s", h, _("hours"));
-	    else if ( min == 1 ) return g_strdup_printf ("%d %s %s", h, _("hours"), _("one minute"));
-	    else            return g_strdup_printf ("%d %s %d %s", h, _("hours"), min, _("minutes"));
-    }
-	
-    return g_strdup_printf ("%d %s", (int)value, _("Minutes"));
+
+    /* value > 60 */
+    h = (gint)value/60;
+    min = (gint)value%60;
+    
+    if ( h <= 1 )
+	if ( min == 0 )      return g_strdup_printf ("%s", _("One hour"));
+	else if ( min == 1 ) return g_strdup_printf ("%s %s", _("One hour"),  _("one minute"));
+	else                 return g_strdup_printf ("%s %d %s", _("One hour"), min, _("minutes"));
+    else 
+	if ( min == 0 )      return g_strdup_printf ("%d %s", h, _("hours"));
+	else if ( min == 1 ) return g_strdup_printf ("%d %s %s", h, _("hours"), _("one minute"));
+	else            return g_strdup_printf ("%d %s %d %s", h, _("hours"), min, _("minutes"));
 }
 
 /*

Modified: xfce4-power-manager/trunk/src/xfpm-engine.c
===================================================================
--- xfce4-power-manager/trunk/src/xfpm-engine.c	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/src/xfpm-engine.c	2009-05-20 08:31:38 UTC (rev 7377)
@@ -177,19 +177,17 @@
 	{
 	    xfpm_shutdown_add_callback (engine->priv->shutdown, 
 					(GSourceFunc) xfpm_engine_do_hibernate,
-					2,
+					lock_screen,
 					engine);
 	}
 	else if (shutdown == XFPM_DO_SUSPEND)
 	{
 	    xfpm_shutdown_add_callback (engine->priv->shutdown, 
 					(GSourceFunc) xfpm_engine_do_suspend,
-					2,
+					lock_screen,
 					engine);
 	}
 
-	if (lock_screen)
-	    xfpm_lock_screen ();
     }
 }
 

Modified: xfce4-power-manager/trunk/src/xfpm-main.c
===================================================================
--- xfce4-power-manager/trunk/src/xfpm-main.c	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/src/xfpm-main.c	2009-05-20 08:31:38 UTC (rev 7377)
@@ -82,8 +82,8 @@
     
     manager = xfpm_manager_new (bus);
     
-     if ( xfce_posix_signal_handler_init (&error)) 
-     {
+    if ( xfce_posix_signal_handler_init (&error)) 
+    {
         xfce_posix_signal_handler_set_handler(SIGHUP,
                                               xfpm_quit_signal,
                                               manager, NULL);
@@ -102,11 +102,6 @@
         g_error_free(error);
     }
 
-    if ( no_daemon == FALSE && daemon(0,0) )
-    {
-	g_critical ("Could not daemonize");
-    }
- 
     xfpm_manager_start (manager);
     gtk_main ();
     
@@ -141,7 +136,7 @@
 
     xfce_textdomain (GETTEXT_PACKAGE, LOCALEDIR, "UTF-8");
 
-    if (!gtk_init_with_args (&argc, &argv, "", option_entries, PACKAGE, &error)) 
+    if (!gtk_init_with_args (&argc, &argv, (gchar *)"", option_entries, (gchar *)PACKAGE, &error)) 
     {
         if(G_LIKELY(error)) 
         {
@@ -177,6 +172,11 @@
        
     dbus_g_thread_init ();
     
+    if ( no_daemon == FALSE && daemon(0,0) )
+    {
+	g_critical ("Could not daemonize");
+    }
+    
     bus = dbus_g_bus_get(DBUS_BUS_SESSION, &error);
             
     if ( error )
@@ -187,12 +187,7 @@
 	xfpm_error (_("Xfce Power Manager"),
 		    message );
 			   
-	g_error("%s: \n",message);
-	g_print("\n");
-	g_error_free(error);
-	g_free(message);
-	
-	return EXIT_FAILURE;
+	g_error ("%s: \n", message);
     }
     
     if ( quit )

Modified: xfce4-power-manager/trunk/src/xfpm-shutdown.c
===================================================================
--- xfce4-power-manager/trunk/src/xfpm-shutdown.c	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/src/xfpm-shutdown.c	2009-05-20 08:31:38 UTC (rev 7377)
@@ -39,6 +39,7 @@
 #include "libxfpm/hal-monitor.h"
 
 #include "libxfpm/xfpm-string.h"
+#include "libxfpm/xfpm-common.h"
 
 #include "xfpm-shutdown.h"
 #include "xfpm-session.h"
@@ -378,16 +379,23 @@
 
 gboolean                  xfpm_shutdown_add_callback    (XfpmShutdown *shutdown,
 							 GSourceFunc func,
-							 guint timeout,
+							 gboolean lock_screen,
 							 gpointer data)
 {
     g_return_val_if_fail (XFPM_IS_SHUTDOWN (shutdown), FALSE);
     
     if (shutdown->priv->block_shutdown)
 	return FALSE;
+    
+    xfpm_send_message_to_network_manager ("sleep");
+    if ( lock_screen )
+	xfpm_lock_screen ();
 	
-    xfpm_send_message_to_network_manager ("sleep");
-    g_timeout_add_seconds (timeout, func, data);
+    if ( lock_screen )
+	g_timeout_add_seconds (2 , func, data);
+    else
+	g_timeout_add (100, func, data);
+	
     shutdown->priv->block_shutdown = TRUE;
     return TRUE;
 }

Modified: xfce4-power-manager/trunk/src/xfpm-shutdown.h
===================================================================
--- xfce4-power-manager/trunk/src/xfpm-shutdown.h	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/src/xfpm-shutdown.h	2009-05-20 08:31:38 UTC (rev 7377)
@@ -58,7 +58,7 @@
 
 gboolean                  xfpm_shutdown_add_callback    (XfpmShutdown *shutdown,
 							 GSourceFunc func,
-							 guint timeout,
+							 gboolean lock_screen,
 							 gpointer data);
 							 
 

Modified: xfce4-power-manager/trunk/src/xfpm-tray-icon.c
===================================================================
--- xfce4-power-manager/trunk/src/xfpm-tray-icon.c	2009-05-19 22:38:51 UTC (rev 7376)
+++ xfce4-power-manager/trunk/src/xfpm-tray-icon.c	2009-05-20 08:31:38 UTC (rev 7377)
@@ -172,12 +172,10 @@
     if ( ret ) 
     {
 	lock_screen = xfpm_xfconf_get_property_bool (tray->priv->conf, LOCK_SCREEN_ON_SLEEP);
-	if ( lock_screen )
-	    xfpm_lock_screen ();
 	    
 	xfpm_shutdown_add_callback (tray->priv->shutdown, 
 				    (GSourceFunc) xfpm_tray_icon_do_hibernate, 
-				    2,
+				    lock_screen,
 				    tray);
     }
 }
@@ -203,12 +201,10 @@
     if ( ret ) 
     {
 	lock_screen = xfpm_xfconf_get_property_bool (tray->priv->conf, LOCK_SCREEN_ON_SLEEP);
-	if ( lock_screen )
-	    xfpm_lock_screen ();
 	
 	xfpm_shutdown_add_callback (tray->priv->shutdown, 
 				    (GSourceFunc) xfpm_tray_icon_do_suspend, 
-				    2,
+				    lock_screen,
 				    tray);
 				    
     }




More information about the Goodies-commits mailing list