/****************************************************************************
** ui.h extension file, included from the uic-generated form implementation.
**
** If you want to add, delete, or rename functions or slots, use
** Qt Designer to update this file, preserving your code.
**
** You should not define a constructor or destructor in this file.
** Instead, write your code in functions called init() and destroy().
** These will automatically be called by the form's constructor and
** destructor.
**
**   Created : 
**        by : Varol Okan 
** Copyright : (c) Varol Okan
** License   : GPL v 2.0
**
*****************************************************************************/
#include <qfiledialog.h>

#include "global.h"

void uiNewWizard::slotBrowseTemp()
{
	// This function will browse for the directory where the DVD is to be build.
	QString qsPathName = QFileDialog::getExistingDirectory ( m_pEditTempPath->text() );
	if  ( (qsPathName.isEmpty()) || (qsPathName.isNull()) )
		return;
	m_pEditTempPath->setText(qsPathName);
}

void uiNewWizard::slotBrowseDVDPath()
{
	// This function will browse for the directory where the DVD is to be build.
	QString qsPathName = QFileDialog::getExistingDirectory (Global::qsCurrentPath);
//	QString qsPathName = QFileDialog::getExistingDirectory (m_pEditTempPath->text());
	if  ( (qsPathName.isEmpty()) || (qsPathName.isNull()) )
		return;
	m_pEditDVDPath->setText(qsPathName);
}


void uiNewWizard::slotSelectionCHanged( const QString &qsText)
{
    if (qsText.isEmpty())
	setFinishEnabled (DVDOutputPath, false);
    else
	setFinishEnabled (DVDOutputPath, true);
}


void uiNewWizard::slotProjectNameChanged( const QString & )
{
	m_pLabelTempOut->setText(m_pEditTempPath->text() + QString ("/") + m_pEditProjectName->text());
}
