changed preview generator functions to a static function

This commit is contained in:
itsmattkc
2019-02-25 22:07:19 -08:00
parent 47d0065eff
commit a1455ce9c7
6 changed files with 14 additions and 4 deletions
+8
View File
@@ -593,3 +593,11 @@ void PreviewGenerator::cancel() {
cancelled_ = true;
wait();
}
void PreviewGenerator::AnalyzeMedia(Media *m)
{
// PreviewGenerator's constructor starts the thread, sets a reference of itself as the media's generator,
// and connects its thread completion to its own deletion, therefore handling its own memory. Nothing else needs to
// be done.
new PreviewGenerator(m);
}