summaryrefslogtreecommitdiff
path: root/src/wx/job_manager_view.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2015-02-04 09:20:28 +0000
committerCarl Hetherington <cth@carlh.net>2015-02-04 09:20:28 +0000
commit0acdcc34f5d582474d586f75d5be627155ad9e08 (patch)
tree0d5d2ba3fc8b6fa1ff67e78a3622fdf729c8e964 /src/wx/job_manager_view.cc
parent072b0b1de6c1bd0b58079affc7e807cc29eb0631 (diff)
Don't truncate job statuses in the command line interface, only in the GUI.
Diffstat (limited to 'src/wx/job_manager_view.cc')
-rw-r--r--src/wx/job_manager_view.cc13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/wx/job_manager_view.cc b/src/wx/job_manager_view.cc
index 783535a12..3593d2357 100644
--- a/src/wx/job_manager_view.cc
+++ b/src/wx/job_manager_view.cc
@@ -108,9 +108,18 @@ private:
}
}
+ void update_status ()
+ {
+ string s = _job->status ();
+ if (s.length() > 25) {
+ s = s.substr (0, 25) + "...";
+ }
+ checked_set (_message, s);
+ }
+
void progress ()
{
- checked_set (_message, _job->status ());
+ update_status ();
update_job_name ();
if (_job->progress ()) {
_gauge->SetValue (min (100.0f, _job->progress().get() * 100));
@@ -121,7 +130,7 @@ private:
void finished ()
{
- checked_set (_message, _job->status ());
+ update_status ();
update_job_name ();
if (!_job->finished_cancelled ()) {