mirror of https://github.com/BOINC/boinc.git
Merge branch 'master' of ssh://boinc.berkeley.edu/boinc
Conflicts: checkin_notes
This commit is contained in:
commit
08126182b6
7996
checkin_notes
7996
checkin_notes
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -150,6 +150,10 @@ mach_port_t gEventHandle = NULL;
|
||||||
#define _SC_PAGESIZE _SC_PAGE_SIZE
|
#define _SC_PAGESIZE _SC_PAGE_SIZE
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if HAVE_DPMS
|
||||||
|
#include <X11/extensions/dpms.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#if HAVE_XSS
|
#if HAVE_XSS
|
||||||
#include <X11/extensions/scrnsaver.h>
|
#include <X11/extensions/scrnsaver.h>
|
||||||
#endif
|
#endif
|
||||||
|
@ -1806,7 +1810,51 @@ bool xss_idle(long idle_treshold) {
|
||||||
|
|
||||||
if(disp != NULL) {
|
if(disp != NULL) {
|
||||||
XScreenSaverQueryInfo(disp, DefaultRootWindow(disp), xssInfo);
|
XScreenSaverQueryInfo(disp, DefaultRootWindow(disp), xssInfo);
|
||||||
idle_time = xssInfo->idle / 1000; // xssInfo->idle is in ms
|
|
||||||
|
idle_time = xssInfo->idle;
|
||||||
|
|
||||||
|
#if HAVE_DPMS
|
||||||
|
int dummy;
|
||||||
|
CARD16 standby, suspend, off;
|
||||||
|
CARD16 state;
|
||||||
|
BOOL onoff;
|
||||||
|
|
||||||
|
if (DPMSQueryExtension(disp, &dummy, &dummy)) {
|
||||||
|
if (DPMSCapable(disp)) {
|
||||||
|
DPMSGetTimeouts(disp, &standby, &suspend, &off);
|
||||||
|
DPMSInfo(disp, &state, &onoff);
|
||||||
|
|
||||||
|
if (onoff) {
|
||||||
|
switch (state) {
|
||||||
|
case DPMSModeStandby:
|
||||||
|
/* this check is a littlebit paranoid, but be sure */
|
||||||
|
if (idle_time < (unsigned) (standby * 1000)) {
|
||||||
|
idle_time += (standby * 1000);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case DPMSModeSuspend:
|
||||||
|
if (idle_time < (unsigned) ((suspend + standby) * 1000)) {
|
||||||
|
idle_time += ((suspend + standby) * 1000);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case DPMSModeOff:
|
||||||
|
if (idle_time < (unsigned) ((off + suspend + standby) * 1000)) {
|
||||||
|
idle_time += ((off + suspend + standby) * 1000);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case DPMSModeOn:
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// convert from milliseconds to seconds
|
||||||
|
idle_time = idle_time / 1000;
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
disp = XOpenDisplay(NULL);
|
disp = XOpenDisplay(NULL);
|
||||||
// XOpenDisplay may return NULL if there is no running X
|
// XOpenDisplay may return NULL if there is no running X
|
||||||
|
|
|
@ -847,6 +847,9 @@ fi
|
||||||
LIBS=$svlibs
|
LIBS=$svlibs
|
||||||
|
|
||||||
if (test "$enable_xss" == yes) && (test "$have_Xss" == yes); then
|
if (test "$enable_xss" == yes) && (test "$have_Xss" == yes); then
|
||||||
|
SAH_CHECK_LIB([xcb-dpms],[DPMSQueryExtension],[
|
||||||
|
AC_DEFINE([HAVE_DPMS],[1],[Define to 1 if you have xcb-dpms library])
|
||||||
|
CLIENTLIBS="${sah_lib_last} ${CLIENTLIBS}"])
|
||||||
SAH_CHECK_LIB([Xss],[XScreenSaverAllocInfo],[
|
SAH_CHECK_LIB([Xss],[XScreenSaverAllocInfo],[
|
||||||
AC_DEFINE([HAVE_XSS],[1],[Define to 1 if you have xss library])
|
AC_DEFINE([HAVE_XSS],[1],[Define to 1 if you have xss library])
|
||||||
CLIENTLIBS="${sah_lib_last} ${CLIENTLIBS}"])
|
CLIENTLIBS="${sah_lib_last} ${CLIENTLIBS}"])
|
||||||
|
|
|
@ -0,0 +1,10 @@
|
||||||
|
#!/bin/bash
|
||||||
|
# Provide a go between the historical way BOINC has tracked commit changes with the way
|
||||||
|
# git manages historical information. Basically mimic the checkin_notes file with the
|
||||||
|
# output of various git commands
|
||||||
|
#
|
||||||
|
|
||||||
|
# Command line customizations here
|
||||||
|
|
||||||
|
# Get a list of commit ids to extract the log information for
|
||||||
|
git log --name-status --pretty=fuller --since="$1 day ago"
|
|
@ -215,7 +215,6 @@ int VBOX_VM::initialize() {
|
||||||
command = "--version ";
|
command = "--version ";
|
||||||
vbm_popen(command, output, "version check");
|
vbm_popen(command, output, "version check");
|
||||||
|
|
||||||
#ifdef _WIN32
|
|
||||||
// Remove \r or \n from the output spew
|
// Remove \r or \n from the output spew
|
||||||
string::iterator iter = output.begin();
|
string::iterator iter = output.begin();
|
||||||
while (iter != output.end()) {
|
while (iter != output.end()) {
|
||||||
|
@ -225,7 +224,6 @@ int VBOX_VM::initialize() {
|
||||||
++iter;
|
++iter;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
virtualbox_version = "VirtualBox " + output;
|
virtualbox_version = "VirtualBox " + output;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue