X-Git-Url: https://main.carlh.net/gitweb/?p=dcpomatic.git;a=blobdiff_plain;f=src%2Fwx%2Fnormal_job_view.cc;h=6c9c08fa720ccb64f21c90c8e25ab1d64fec3d08;hp=9bfa332c965b2bb90ba6afe7c88c17d7a1b683c6;hb=dd9be86db6cde0afa5da0d1d1ac43b42e05dca26;hpb=ad5c8849fc3ef5aad88201f28db5474a60db4436 diff --git a/src/wx/normal_job_view.cc b/src/wx/normal_job_view.cc index 9bfa332c9..6c9c08fa7 100644 --- a/src/wx/normal_job_view.cc +++ b/src/wx/normal_job_view.cc @@ -1,5 +1,5 @@ /* - Copyright (C) 2012-2016 Carl Hetherington + Copyright (C) 2012-2017 Carl Hetherington This file is part of DCP-o-matic. @@ -19,10 +19,11 @@ */ #include "normal_job_view.h" +#include "dcpomatic_button.h" #include "lib/job.h" #include -using boost::shared_ptr; +using std::shared_ptr; NormalJobView::NormalJobView (shared_ptr job, wxWindow* parent, wxWindow* container, wxFlexGridSizer* table) : JobView (job, parent, container, table) @@ -34,7 +35,7 @@ NormalJobView::NormalJobView (shared_ptr job, wxWindow* parent, wxWindow* c void NormalJobView::finish_setup (wxWindow* parent, wxSizer* sizer) { - _pause = new wxButton (parent, wxID_ANY, _("Pause")); + _pause = new Button (parent, _("Pause")); _pause->Bind (wxEVT_BUTTON, boost::bind (&NormalJobView::pause_clicked, this)); sizer->Add (_pause, 1, wxALIGN_CENTER_VERTICAL); } @@ -48,11 +49,11 @@ NormalJobView::insert_position () const void NormalJobView::pause_clicked () { - if (_job->paused()) { + if (_job->paused_by_user()) { _job->resume (); _pause->SetLabel (_("Pause")); } else { - _job->pause (); + _job->pause_by_user (); _pause->SetLabel (_("Resume")); } }