#include "lib/job_manager.h"
#include "lib/exceptions.h"
#include "lib/cinema.h"
-#include "lib/kdm.h"
+#include "lib/screen_kdm.h"
#include "lib/send_kdm_email_job.h"
#include "lib/server_finder.h"
#include "lib/update_checker.h"
#include "lib/cross.h"
#include "lib/content_factory.h"
#include "lib/compose.hpp"
+#include "lib/cinema_kdms.h"
#include <dcp/exceptions.h>
#include <wx/generic/aboutdlgg.h>
#include <wx/stdpaths.h>
}
try {
+ list<ScreenKDM> screen_kdms = _film->make_kdms (d->screens(), d->cpl(), d->from(), d->until(), d->formulation());
if (d->write_to ()) {
- write_kdm_files (_film, d->screens (), d->cpl (), d->from (), d->until (), d->formulation (), d->directory ());
+ ScreenKDM::write_files (
+ _film->name(),
+ screen_kdms,
+ d->directory()
+ );
} else {
JobManager::instance()->add (
- shared_ptr<Job> (new SendKDMEmailJob (_film, d->screens (), d->cpl (), d->from (), d->until (), d->formulation ()))
+ shared_ptr<Job> (new SendKDMEmailJob (
+ _film->name(),
+ _film->dcp_name(),
+ d->from(),
+ d->until(),
+ CinemaKDMs::collect (screen_kdms)
+ ))
);
}
} catch (dcp::NotEncryptedError& e) {