/*
ProcessingDlg.Cpp
*/
#include "MainWindow.h"
#include <QtGui>
#include <QCloseEvent >
#include "ProcessingDlg.h"
#include "Config.h"
ProcessingDlg
::ProcessingDlg(QWidget *parent, MainWindow
*h
){
setupUi(this);
}
{
help->m_pProcessDlg = false;
delete help->m_pProcessDlg;
m_pevent->accept();
}
/*
ProcessingDlg.Cpp
*/
#include "MainWindow.h"
#include <QtGui>
#include <QCloseEvent >
#include "ProcessingDlg.h"
#include "Config.h"
ProcessingDlg::ProcessingDlg(QWidget *parent, MainWindow *h)
: QDialog(parent),help(h)
{
setupUi(this);
}
void ProcessingDlg::closeEvent(QCloseEvent *m_pevent)
{
help->m_pProcessDlg = false;
delete help->m_pProcessDlg;
m_pevent->accept();
}
To copy to clipboard, switch view to plain text mode
/*
ProcessingDlg.h
*/
#ifndef PROCESSINGDLG_H
#define PROCESSINGDLG_H
#include"ui_Processing.h"
class MainWindow;
class ProcessingDlg
: public QDialog,
public Ui
::Process{
Q_OBJECT
public:
ProcessingDlg
(QWidget *parent,MainWindow
*h
);
MainWindow *help;
protected:
public slots:
private:
Ui::Process ui;
public:
};
#endif
/*
ProcessingDlg.h
*/
#ifndef PROCESSINGDLG_H
#define PROCESSINGDLG_H
#include"ui_Processing.h"
class MainWindow;
class QLabel;
class ProcessingDlg : public QDialog, public Ui::Process
{
Q_OBJECT
public:
ProcessingDlg(QWidget *parent,MainWindow *h);
MainWindow *help;
protected:
void closeEvent(QCloseEvent *m_pevent);
public slots:
private:
Ui::Process ui;
public:
};
#endif
To copy to clipboard, switch view to plain text mode
if(!m_pProcessDlg)
m_pProcessDlg = new ProcessingDlg(m_pTab,this);
// Make FIle List of Directory
QFileInfoList m_pFinfo = CurrentDir.entryInfoList();
m_pEntries = m_pFinfo.count();
m_pProcessDlg->progressBar->setMaximum(m_pEntries);
m_pProcessDlg->progressBar->setValue(m_pCurrentEnt);
if(!CurrentDir.cd(DirPath))
{
QMessageBox::information(this,tr
("Error"),tr
("Can't Cd into %1").
arg(DirPath
));
return false;
}
m_pProcessDlg->labelDirectory->setText(DirPath);
if(!m_pProcessDlg)
m_pProcessDlg = new ProcessingDlg(m_pTab,this);
// Make FIle List of Directory
QFileInfoList m_pFinfo = CurrentDir.entryInfoList();
m_pEntries = m_pFinfo.count();
m_pProcessDlg->progressBar->setMaximum(m_pEntries);
m_pProcessDlg->progressBar->setValue(m_pCurrentEnt);
if(!CurrentDir.cd(DirPath))
{
QMessageBox::information(this,tr("Error"),tr("Can't Cd into %1").arg(DirPath));
return false;
}
m_pProcessDlg->labelDirectory->setText(DirPath);
To copy to clipboard, switch view to plain text mode
Hope this helps , thanks again for your time , it's greatly appreciated!
Patrick
Bookmarks