/*****************************************************************************
 *
 *  mediaeditor.cpp -- Media editor (operates at stream level).
 *
 *  Copyright (C) 2010 Starbuck <starbuck@labdv.com>
 *  All rights reserved.
 *
 *  This file is part of the JobManager module of the DVDx 4 application.
 *
 *  GNU Lesser General Public License Usage
 *  This file may be used under the terms of the GNU Lesser General
 *  Public License version 2.1 as published by the Free Software
 *  Foundation and appearing in the file LICENSE.LGPL included in the
 *  packaging of this file.  Please review the following information to
 *  ensure the GNU Lesser General Public License version 2.1 requirements
 *  will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
 *
 *  GNU General Public License Usage
 *  Alternatively, this file may be used under the terms of the GNU
 *  General Public License version 3.0 as published by the Free Software
 *  Foundation and appearing in the file LICENSE.GPL included in the
 *  packaging of this file.  Please review the following information to
 *  ensure the GNU General Public License version 3.0 requirements will be
 *  met: http://www.gnu.org/copyleft/gpl.html.
 *
 *****************************************************************************/

#include "mediaeditor.h"
#include <QDebug>

extern Console *console;

MediaEditor::MediaEditor(JobManager *jobManager)
	: QObject()
{
	m_console = console;

	Q_CHECK_PTR(jobManager);

	m_jobManager = jobManager;
}

void MediaEditor::setDeleteOnFinish(bool yes)
{
	if (yes)	
	{
		connect(this, SIGNAL(finished()), this, SLOT(deleteLater()));
	}
	else
	{
		disconnect(this, SIGNAL(finished()), this, SLOT(deleteLater()));
	}
}

void MediaEditor::setOutputFolder(const QString &outputFolder)
{
	m_outputFolder = outputFolder;
}

void MediaEditor::setProcessLatency(const int start, const int finished, const int kill)
{
	m_processLatency.start = start;
	m_processLatency.finished = finished;
	m_processLatency.kill = kill;
}
