From 641ff015333c81bdddf61ce66329e46f74625615 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Mon, 2 Mar 2009 00:28:38 +0000 Subject: [PATCH] Manager: message tweak svn path=/trunk/boinc/; revision=17420 --- clientgui/DlgItemProperties.cpp | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/clientgui/DlgItemProperties.cpp b/clientgui/DlgItemProperties.cpp index c03809de5d..0c5c6afbc3 100755 --- a/clientgui/DlgItemProperties.cpp +++ b/clientgui/DlgItemProperties.cpp @@ -137,19 +137,15 @@ void CDlgItemProperties::renderInfos(PROJECT* project_in) { addSection(_("Scheduling")); addProperty(_("CPU scheduling priority"),wxString::Format(wxT("%0.2f"), project->short_term_debt)); addProperty(_("CPU work fetch priority"),wxString::Format(wxT("%0.2f"), project->cpu_long_term_debt)); - if (project->cpu_backoff_time > dtime()) { - addProperty(_("CPU work fetch deferred for"), FormatTime(project->cpu_backoff_time - dtime())); - } else { - addProperty(_("CPU work fetch not deferred "), _("")); - } + double x = project->cpu_backoff_time - dtime(); + if (x<0) x = 0; + addProperty(_("CPU work fetch deferred for"), FormatTime(x)); addProperty(_("CPU work fetch deferral interval"), FormatTime(project->cpu_backoff_interval)); if (pDoc->state.have_cuda) { addProperty(_("NVIDIA GPU work fetch priority"),wxString::Format(wxT("%0.2f"), project->cuda_debt)); - if (project->cuda_backoff_time > dtime()) { - addProperty(_("NVIDIA GPU work fetch deferred for"), FormatTime(project->cuda_backoff_time - dtime())); - } else { - addProperty(_("NVIDIA GPU work fetch not deferred "), _("")); - } + x = project->cuda_backoff_time > dtime(); + if (x<0) x = 0; + addProperty(_("NVIDIA GPU work fetch deferred for"), FormatTime(x)); addProperty(_("NVIDIA GPU work fetch deferral interval"), FormatTime(project->cuda_backoff_interval)); } addProperty(_("Duration correction factor"),wxString::Format(wxT("%0.4f"), project->duration_correction_factor));