From c863f2b27a2434e9d316b3f6a9bcb6a20abaeff9 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Fri, 6 Nov 2015 22:35:58 -0800 Subject: [PATCH] Manager: use thousands-separator formatting in a couple of places --- clientgui/DlgItemProperties.cpp | 2 +- clientgui/ViewProjects.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/clientgui/DlgItemProperties.cpp b/clientgui/DlgItemProperties.cpp index 2b21fbbea3..cdcdcd8f12 100644 --- a/clientgui/DlgItemProperties.cpp +++ b/clientgui/DlgItemProperties.cpp @@ -313,7 +313,7 @@ void CDlgItemProperties::renderInfos(PROJECT* project_in) { if (!project->non_cpu_intensive) { addSection(_("Scheduling")); - addProperty(_("Scheduling priority"), wxString::Format(wxT("%0.2f"), project->sched_priority)); + addProperty(_("Scheduling priority"), format_number(project->sched_priority, 2)); show_rsc(_("CPU"), project->rsc_desc_cpu); if (pDoc->state.host_info.coprocs.have_nvidia()) { show_rsc( diff --git a/clientgui/ViewProjects.cpp b/clientgui/ViewProjects.cpp index 34b5236aba..fbaa653896 100644 --- a/clientgui/ViewProjects.cpp +++ b/clientgui/ViewProjects.cpp @@ -1125,8 +1125,8 @@ void CViewProjects::GetDocResourcePercent(wxInt32 item, double& fBuffer) const { } -wxInt32 CViewProjects::FormatResourceShare(double fBuffer, double fBufferPercent, wxString& strBuffer) const { - strBuffer.Printf(wxT("%0.0f (%0.2f%%)"), fBuffer, fBufferPercent); +wxInt32 CViewProjects::FormatResourceShare(double share, double share_pct, wxString& strBuffer) const { + strBuffer.Printf(wxT("%s (%s%%)"), format_number(share, 0), format_number(share_pct, 2)); return 0; }