X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Ftools%2Fdcpomatic_create.cc;h=d4d4df29b814f109066c0d87dc1ad3ae910a0288;hb=e60bb3e51bd1508b149e6b8f6608f09b5196ae26;hp=c30f4e51e7fc66c7963f3aaa2f65b3c7b9c1296d;hpb=e7bc3bd16456c17bc6fe1d7981040b14e820505e;p=dcpomatic.git diff --git a/src/tools/dcpomatic_create.cc b/src/tools/dcpomatic_create.cc index c30f4e51e..d4d4df29b 100644 --- a/src/tools/dcpomatic_create.cc +++ b/src/tools/dcpomatic_create.cc @@ -28,7 +28,7 @@ #include "lib/util.h" #include "lib/content_factory.h" #include "lib/job_manager.h" -#include "lib/ui_signaller.h" +#include "lib/signal_manager.h" #include "lib/job.h" #include "lib/dcp_content_type.h" #include "lib/ratio.h" @@ -59,11 +59,11 @@ help (string n) << " -o, --output output directory\n"; } -class SimpleUISignaller : public UISignaller +class SimpleSignalManager : public SignalManager { public: /* Do nothing in this method so that UI events happen in our thread - when we call UISignaller::ui_idle(). + when we call SignalManager::ui_idle(). */ void wake_ui () {} }; @@ -79,9 +79,9 @@ main (int argc, char* argv[]) Ratio const * content_ratio = 0; int still_length = 10; boost::filesystem::path output; - + int option_index = 0; - while (1) { + while (true) { static struct option long_options[] = { { "version", no_argument, 0, 'v'}, { "help", no_argument, 0, 'h'}, @@ -161,7 +161,7 @@ main (int argc, char* argv[]) exit (EXIT_FAILURE); } - ui_signaller = new SimpleUISignaller (); + signal_manager = new SimpleSignalManager (); try { shared_ptr film (new Film (output, false)); @@ -171,7 +171,7 @@ main (int argc, char* argv[]) film->set_container (container_ratio); film->set_dcp_content_type (dcp_content_type); - + for (int i = optind; i < argc; ++i) { shared_ptr c = content_factory (film, argv[i]); shared_ptr vc = dynamic_pointer_cast (c); @@ -180,11 +180,11 @@ main (int argc, char* argv[]) } film->examine_and_add_content (c); } - + JobManager* jm = JobManager::instance (); while (jm->work_to_do ()) {} - while (ui_signaller->ui_idle() > 0) {} + while (signal_manager->ui_idle() > 0) {} ContentList content = film->content (); for (ContentList::iterator i = content.begin(); i != content.end(); ++i) { @@ -214,6 +214,6 @@ main (int argc, char* argv[]) cerr << argv[0] << ": " << e.what() << "\n"; exit (EXIT_FAILURE); } - + return 0; }