From 9a390c235dc24785395ac416dd959de146a1b241 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Thu, 22 May 2008 03:57:55 +0000 Subject: [PATCH] svn path=/trunk/boinc/; revision=15272 --- client/main.C | 1 + clientgui/ViewResources.cpp | 7 ++++--- lib/boinc_cmd.C | 4 +++- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/client/main.C b/client/main.C index 8ed615ae6e..a325a3f253 100644 --- a/client/main.C +++ b/client/main.C @@ -25,6 +25,7 @@ #define _CONSOLE 1 #include "boinc_win.h" #include "win_service.h" +#include "win_util.h" extern HINSTANCE g_hClientLibraryDll; static HANDLE g_hWin9xMonitorSystemThread = NULL; diff --git a/clientgui/ViewResources.cpp b/clientgui/ViewResources.cpp index 1357c2403e..e40650c705 100644 --- a/clientgui/ViewResources.cpp +++ b/clientgui/ViewResources.cpp @@ -253,7 +253,7 @@ void CViewResources::OnListRender( wxTimerEvent& WXUNUSED(event) ) { // used by BOINC double boinc_total = project_total + pDoc->disk_usage.d_boinc; - FormatDiskSpace(boinc_total, diskspace); + FormatDiskSpace(boinc_total, diskspace); part.SetLabel(_("used by BOINC - ") + diskspace); part.SetValue(boinc_total); part.SetColour(wxColour(0,0,0)); @@ -272,9 +272,10 @@ void CViewResources::OnListRender( wxTimerEvent& WXUNUSED(event) ) { } // free disk space - FormatDiskSpace(free-avail, diskspace); + double not_avail = free - avail; + FormatDiskSpace(not_avail, diskspace); part.SetLabel(_("free, not available to BOINC - ") + diskspace); - part.SetValue(free-avail); + part.SetValue(not_avail); part.SetColour(wxColour(238,238,238)); m_pieCtrlTotal->m_Series.Add(part); diff --git a/lib/boinc_cmd.C b/lib/boinc_cmd.C index c5a2829281..b5830d6275 100644 --- a/lib/boinc_cmd.C +++ b/lib/boinc_cmd.C @@ -26,7 +26,9 @@ #include "boinc_win.h" #endif -#ifndef _WIN32 +#ifdef _WIN32 +#include "win_util.h" +#else #include "config.h" #include #include