Change function and variable name (UndoType -> abortStarted)
authorAdam Banasiak <a.banasiak@samsung.com>
Tue, 10 Sep 2013 12:04:31 +0000 (14:04 +0200)
committerSoo-Hyun Choi <sh9.choi@samsung.com>
Wed, 11 Sep 2013 07:10:52 +0000 (16:10 +0900)
[Issue#]   LINUXWRT-358
[Problem]  Incorrect names of variable and function
[Cause]    N/A
[Solution] Rename function and variable names

Change-Id: Iea9bb7fecd8ec57f54d90bebb2e906abd4a8cde7

src/jobs/job.cpp
src/jobs/job.h
src/logic/installer_logic.cpp

index 335ab76..ec2bb7f 100644 (file)
@@ -20,7 +20,7 @@ namespace Jobs {
 Job::Job(InstallationType installType) :
     m_handle(0),
     m_installationType(installType),
-    m_UndoType(false),
+    m_abortStarted(false),
     m_paused(false)
 {}
 
@@ -29,14 +29,14 @@ InstallationType Job::GetInstallationType() const
     return m_installationType;
 }
 
-bool Job::GetUndoType() const
+bool Job::GetAbortStarted() const
 {
-    return m_UndoType;
+    return m_abortStarted;
 }
 
-void Job::SetUndoType(bool flag)
+void Job::SetAbortStarted(bool flag)
 {
-    m_UndoType = flag;
+    m_abortStarted = flag;
 }
 
 bool Job::IsPaused() const
index df81e5f..982b961 100644 (file)
@@ -41,8 +41,8 @@ class Job :
     InstallationType GetInstallationType() const;
 
     // Undo
-    void SetUndoType(bool flag);
-    bool GetUndoType() const;
+    void SetAbortStarted(bool flag);
+    bool GetAbortStarted() const;
 
     // Pause/resume support
     bool IsPaused() const;
@@ -61,7 +61,7 @@ class Job :
   private:
     JobHandle m_handle;
     InstallationType m_installationType;
-    bool m_UndoType; //TODO change name to m_AbortStarted
+    bool m_abortStarted;
     bool m_paused;
 };
 } //namespace Jobs
index a7927ce..5af7000 100644 (file)
@@ -145,7 +145,7 @@ bool InstallerLogic::NextStep(Jobs::Job *job)
             return !job->IsPaused();
         }
 
-        if (!job->GetUndoType()) {
+        if (!job->GetAbortStarted()) {
             //job successfully finished
 
             //send finished callback
@@ -174,7 +174,7 @@ bool InstallerLogic::NextStep(Jobs::Job *job)
         LogDebug("Exception occured: " << exc.getParam() <<
                 ". Reverting job...");
         bool hasAbortSteps = job->Abort();
-        job->SetUndoType(true);
+        job->SetAbortStarted(true);
         job->SaveExceptionData(exc);
 
         if (!hasAbortSteps) {