--- a/filemanager/src/filemanager/src/operationservice/fmoperationthread.h Fri Jul 23 11:12:24 2010 +0800
+++ b/filemanager/src/filemanager/src/operationservice/fmoperationthread.h Thu Aug 05 11:30:07 2010 +0800
@@ -19,7 +19,7 @@
#ifndef FMOPERATIONTHREAD_H
#define FMOPERATIONTHREAD_H
-#include "fmoperationservice.h"
+#include "fmoperationbase.h"
#include "fmcommon.h"
#include <QString>
@@ -27,51 +27,14 @@
#include <QThread>
-class FmDriveDetailsSize;
-class FmOperationBase;
-
-class FmOperationCopy;
-class FmOperationMove;
-class FmOperationRemove;
-
class FmOperationThread : public QThread
{
Q_OBJECT
public:
FmOperationThread( QObject *parent );
~FmOperationThread();
-
- int asyncCopy( FmOperationBase* operationBase );
- int asyncMove( FmOperationBase *operationBase );
- int asyncRemove( FmOperationBase *operationBase );
-
- int asyncFormat( FmOperationBase *operationBase );
- int asyncViewDriveDetails( FmOperationBase *operationBase );
- int asyncViewFolderDetails( FmOperationBase *operationBase );
- void stop();
-
-signals:
- void askForRename( const QString &srcFile, QString *destFile );
- void askForReplace( const QString &srcFile, const QString &destFile, bool *isAccepted );
- void driveSpaceChanged();
-
- void showNote(const char*);
- void notifyWaiting( bool cancelable );
- void notifyPreparing( bool cancelable ); // this step could not be used if not needed.
- void notifyStart( bool cancelable, int maxSteps );
- void notifyProgress( int currentStep );
-
- void notifyFinish();
- void notifyError(int error, QString errString );
- void notifyCanceled();
-
-private slots:
- void onAskForRename( const QString &srcFile, QString *destFile );
- void onAskForReplace( const QString &srcFile, const QString &destFile, bool *isAccepted );
- void onShowNote( const char *noteString );
- void on_operationElement_notifyPreparing( bool cancelable );
- void on_operationElement_notifyStart( bool cancelable, int maxSteps );
- void on_operationElement_notifyProgress( int currentStep );
+ int prepareOperationAndStart( FmOperationBase* operationBase );
+ void stop();
protected:
void run();