filemanager/src/filemanager/src/backuprestore/fmbackupview.cpp
changeset 16 ada7962b4308
parent 14 1957042d8c7e
child 18 edd66bde63a4
child 25 b7bfdea70ca2
child 37 15bc28c9dd51
--- a/filemanager/src/filemanager/src/backuprestore/fmbackupview.cpp	Fri Apr 16 14:53:38 2010 +0300
+++ b/filemanager/src/filemanager/src/backuprestore/fmbackupview.cpp	Mon May 03 12:24:39 2010 +0300
@@ -55,18 +55,18 @@
 #ifdef FM_CHANGE_ORIENT_ENABLE
 	action = new HbAction( this );
     action->setObjectName( "rotateAction" );
-    action->setText( tr( "Change orientation" ) );
+    action->setText( hbTrId( "Change orientation" ) );
     menu()->addAction( action );
 #endif
 
 	action = new HbAction( this );
     action->setObjectName( "backupAction" );
-    action->setText( tr( "Start backup" ) );
+    action->setText( hbTrId( "Start backup" ) );
     menu()->addAction( action );
 
 	action = new HbAction( this );
     action->setObjectName( "deleteBackupAction" );
-    action->setText( tr( "Delete backup" ) );
+    action->setText( hbTrId( "Delete backup" ) );
     menu()->addAction( action );
 
 }
@@ -96,13 +96,19 @@
     case FmErrNone:
         break;
     case FmErrWrongParam:
-        HbMessageBox::information( QString( tr("Operation canceled with wrong param!") ) );
+        HbMessageBox::information( QString( hbTrId("Operation canceled with wrong param!") ) );
         break;
     case FmErrAlreadyStarted:
-        HbMessageBox::information( QString( tr("Operation canceled because already started!") ) );
+        HbMessageBox::information( QString( hbTrId("Operation canceled because already started!") ) );
+        break;
+    case FmErrPathNotFound:
+        HbMessageBox::information( QString( hbTrId("Operation canceled because can not find target drive!") ) );
+        break;
+    case FmErrAlreadyExists:
+        HbMessageBox::information( QString( hbTrId("backup canceled") ) );
         break;
     default:
-        HbMessageBox::information( QString( tr("Operation canceled with error!") ) );
+        HbMessageBox::information( QString( hbTrId("backup failed") ) );
         break;
     }
 }
@@ -120,21 +126,7 @@
 
 void FmBackupView::on_backupAction_triggered()
 {
-    int ret = mOperationService->asyncBackup();
-    switch( ret )
-    {
-    case FmErrNone:
-        break;
-    case FmErrWrongParam:
-        HbMessageBox::information( QString( tr("Operation canceled with wrong param!") ) );
-        break;
-    case FmErrAlreadyStarted:
-        HbMessageBox::information( QString( tr("Operation canceled because already started!") ) );
-        break;
-    default:
-        HbMessageBox::information( QString( tr("Operation canceled with error!") ) );
-        break;
-    }
+    on_leftAction_triggered();
 }
 
 void FmBackupView::on_deleteBackupAction_triggered()