Index: /trunk/src/VBox/Frontends/VBoxManage/VBoxManageSnapshot.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VBoxManage/VBoxManageSnapshot.cpp	(revision 23878)
+++ /trunk/src/VBox/Frontends/VBoxManage/VBoxManageSnapshot.cpp	(revision 23879)
@@ -181,5 +181,5 @@
 
             ComPtr<IProgress> progress;
-            CHECK_ERROR_BREAK(console, DiscardSnapshot(guid, progress.asOutParam()));
+            CHECK_ERROR_BREAK(console, DeleteSnapshot(guid, progress.asOutParam()));
 
             showProgress(progress);
@@ -200,7 +200,5 @@
             if (   (a->argc != 3)
                 || (   strcmp(a->argv[2], "--state")
-                    && strcmp(a->argv[2], "-state")
-                    && strcmp(a->argv[2], "--all")
-                    && strcmp(a->argv[2], "-all")))
+                    && strcmp(a->argv[2], "-state")))
             {
                 errorSyntax(USAGE_SNAPSHOT, "Invalid parameter '%s'", Utf8Str(a->argv[2]).raw());
@@ -208,31 +206,22 @@
                 break;
             }
-            bool fAll = false;
-            if (   !strcmp(a->argv[2], "--all")
-                || !strcmp(a->argv[2], "-all"))
-                fAll = true;
-
-            ComPtr<IProgress> progress;
-
-            if (fAll)
-            {
-                CHECK_ERROR_BREAK(console, DiscardCurrentSnapshotAndState(progress.asOutParam()));
-            }
-            else
-            {
-                CHECK_ERROR_BREAK(console, DiscardCurrentState(progress.asOutParam()));
-            }
-
-            showProgress(progress);
+
+            ComPtr<ISnapshot> pCurrentSnapshot;
+            CHECK_ERROR_BREAK(machine, COMGETTER(CurrentSnapshot)(pCurrentSnapshot.asOutParam()));
+
+            ComPtr<IProgress> pProgress;
+            CHECK_ERROR_BREAK(console, RestoreSnapshot(pCurrentSnapshot, pProgress.asOutParam()));
+
+            showProgress(pProgress);
             LONG iRc;
-            progress->COMGETTER(ResultCode)(&iRc);
+            pProgress->COMGETTER(ResultCode)(&iRc);
             rc = iRc;
             if (FAILED(rc))
             {
-                com::ProgressErrorInfo info(progress);
+                com::ProgressErrorInfo info(pProgress);
                 if (info.isBasicAvailable())
-                    RTPrintf("Error: failed to discard. Error message: %lS\n", info.getText().raw());
-                else
-                    RTPrintf("Error: failed to discard. No error message available!\n");
+                    RTPrintf("Error: failed to restore snapshot. Error message: %lS\n", info.getText().raw());
+                else
+                    RTPrintf("Error: failed to restore snapshot. No error message available!\n");
             }
 
Index: /trunk/src/VBox/Frontends/VBoxSDL/VBoxSDL.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VBoxSDL/VBoxSDL.cpp	(revision 23878)
+++ /trunk/src/VBox/Frontends/VBoxSDL/VBoxSDL.cpp	(revision 23879)
@@ -602,19 +602,20 @@
         switch (machineState)
         {
-            case MachineState_Null:                return "<null>";
-            case MachineState_Running:             return "Running";
-            case MachineState_Restoring:           return "Restoring";
-            case MachineState_TeleportingFrom:     return "TeleportingFrom";
-            case MachineState_Starting:            return "Starting";
-            case MachineState_PoweredOff:          return "PoweredOff";
-            case MachineState_Saved:               return "Saved";
-            case MachineState_Aborted:             return "Aborted";
-            case MachineState_Stopping:            return "Stopping";
-            case MachineState_Paused:              return "Paused";
-            case MachineState_Stuck:               return "Stuck";
-            case MachineState_Saving:              return "Saving";
-            case MachineState_Discarding:          return "Discarding";
-            case MachineState_SettingUp:           return "SettingUp";
-            default:                               return "no idea";
+            case MachineState_Null:                 return "<null>";
+            case MachineState_PoweredOff:           return "PoweredOff";
+            case MachineState_Saved:                return "Saved";
+            case MachineState_Aborted:              return "Aborted";
+            case MachineState_Running:              return "Running";
+            case MachineState_Paused:               return "Paused";
+            case MachineState_Stuck:                return "GuruMeditation";
+            case MachineState_Starting:             return "Starting";
+            case MachineState_Stopping:             return "Stopping";
+            case MachineState_Saving:               return "Saving";
+            case MachineState_Restoring:            return "Restoring";
+            case MachineState_TeleportingFrom:      return "TeleportingFrom";
+            case MachineState_RestoringSnapshot:    return "RestoringSnapshot";
+            case MachineState_DeletingSnapshot:     return "DeletingSnapshot";
+            case MachineState_SettingUp:            return "SettingUp";
+            default:                                return "no idea";
         }
     }
@@ -1774,5 +1775,9 @@
         {
             gProgress = NULL;
-            CHECK_ERROR(gConsole, DiscardCurrentState(gProgress.asOutParam()));
+
+            ComPtr<ISnapshot> pCurrentSnapshot;
+            CHECK_ERROR_BREAK(gMachine, COMGETTER(CurrentSnapshot)(pCurrentSnapshot.asOutParam()));
+
+            CHECK_ERROR(gConsole, RestoreSnapshot(pCurrentSnapshot, gProgress.asOutParam()));
             rc = gProgress->WaitForCompletion(-1);
         }
Index: /trunk/src/VBox/Frontends/VirtualBox/include/VBoxSnapshotsWgt.h
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/include/VBoxSnapshotsWgt.h	(revision 23878)
+++ /trunk/src/VBox/Frontends/VirtualBox/include/VBoxSnapshotsWgt.h	(revision 23879)
@@ -60,5 +60,4 @@
     void takeSnapshot();
     void discardCurState();
-    void discardCurSnapAndState();
     void showSnapshotDetails();
 
@@ -91,5 +90,4 @@
     QAction         *mTakeSnapshotAction;
     QAction         *mRevertToCurSnapAction;
-    QAction         *mDiscardCurSnapAndStateAction;
     QAction         *mShowSnapshotDetailsAction;
 };
Index: /trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleWnd.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleWnd.cpp	(revision 23878)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleWnd.cpp	(revision 23879)
@@ -1388,5 +1388,5 @@
                         if (dlg.mCbDiscardCurState->isChecked() && dlg.mCbDiscardCurState->isVisibleTo (&dlg))
                         {
-                            CProgress progress = console.DiscardCurrentState();
+                            CProgress progress = console.RestoreSnapshot(machine.GetCurrentSnapshot());
                             if (console.isOk())
                             {
Index: /trunk/src/VBox/Frontends/VirtualBox/src/VBoxGlobal.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/VBoxGlobal.cpp	(revision 23878)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/VBoxGlobal.cpp	(revision 23879)
@@ -2643,5 +2643,6 @@
     mMachineStates [KMachineState_Restoring] =  tr ("Restoring", "MachineState");
     mMachineStates [KMachineState_TeleportingFrom] = tr ("Teleporting From", "MachineState");
-    mMachineStates [KMachineState_Discarding] = tr ("Discarding", "MachineState");
+    mMachineStates [KMachineState_RestoringSnapshot] = tr ("Restoring Snapshot", "MachineState");
+    mMachineStates [KMachineState_DeletingSnapshot] = tr ("Deleting Snapshot", "MachineState");
     mMachineStates [KMachineState_SettingUp] =  tr ("Setting Up", "MachineState");
 
@@ -4613,5 +4614,6 @@
         {KMachineState_Restoring, ":/state_restoring_16px.png"},
         {KMachineState_TeleportingFrom, ":/state_restoring_16px.png"}, /** @todo Live Migration: New icon? (not really important) */
-        {KMachineState_Discarding, ":/state_discarding_16px.png"},
+        {KMachineState_RestoringSnapshot, ":/state_discarding_16px.png"},
+        {KMachineState_DeletingSnapshot, ":/state_discarding_16px.png"},
         {KMachineState_SettingUp, ":/settings_16px.png"},
     };
@@ -4635,5 +4637,6 @@
     mVMStateColors.insert (KMachineState_Restoring,     new QColor (Qt::green));
     mVMStateColors.insert (KMachineState_TeleportingFrom, new QColor (Qt::green));
-    mVMStateColors.insert (KMachineState_Discarding,    new QColor (Qt::green));
+    mVMStateColors.insert (KMachineState_RestoringSnapshot, new QColor (Qt::green));
+    mVMStateColors.insert (KMachineState_DeletingSnapshot, new QColor (Qt::green));
     mVMStateColors.insert (KMachineState_SettingUp,     new QColor (Qt::green));
 
Index: /trunk/src/VBox/Frontends/VirtualBox/src/VBoxSnapshotsWgt.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/VBoxSnapshotsWgt.cpp	(revision 23878)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/VBoxSnapshotsWgt.cpp	(revision 23879)
@@ -256,5 +256,4 @@
     , mTakeSnapshotAction (new QAction (this))
     , mRevertToCurSnapAction (new QAction (mCurStateActionGroup))
-    , mDiscardCurSnapAndStateAction (new QAction (mCurStateActionGroup))
     , mShowSnapshotDetailsAction (new QAction (this))
 {
@@ -292,8 +291,4 @@
         ":/discard_cur_state_22px.png", ":/discard_cur_state_16px.png",
         ":/discard_cur_state_dis_22px.png", ":/discard_cur_state_dis_16px.png"));
-    mDiscardCurSnapAndStateAction->setIcon (VBoxGlobal::iconSetFull (
-        QSize (22, 22), QSize (16, 16),
-        ":/discard_cur_state_snapshot_22px.png", ":/discard_cur_state_snapshot_16px.png",
-        ":/discard_cur_state_snapshot_dis_22px.png", ":/discard_cur_state_snapshot_dis_16px.png"));
     mShowSnapshotDetailsAction->setIcon (VBoxGlobal::iconSetFull (
         QSize (22, 22), QSize (16, 16),
@@ -304,5 +299,4 @@
     mTakeSnapshotAction->setShortcut (QString ("Ctrl+Shift+S"));
     mRevertToCurSnapAction->setShortcut (QString ("Ctrl+Shift+R"));
-    mDiscardCurSnapAndStateAction->setShortcut (QString ("Ctrl+Shift+B"));
     mShowSnapshotDetailsAction->setShortcut (QString ("Ctrl+Space"));
 
@@ -321,6 +315,4 @@
     connect (mRevertToCurSnapAction, SIGNAL (triggered()),
              this, SLOT (discardCurState()));
-    connect (mDiscardCurSnapAndStateAction, SIGNAL (triggered()),
-             this, SLOT (discardCurSnapAndState()));
     connect (mShowSnapshotDetailsAction, SIGNAL (triggered()),
              this, SLOT (showSnapshotDetails()));
@@ -467,5 +459,5 @@
 
     CConsole console = session.GetConsole();
-    CProgress progress = console.DiscardSnapshot (snapId);
+    CProgress progress = console.DeleteSnapshot(snapId);
     if (console.isOk())
     {
@@ -552,5 +544,5 @@
 
     CConsole console = session.GetConsole();
-    CProgress progress = console.DiscardCurrentState();
+    CProgress progress = console.RestoreSnapshot(mMachine.GetCurrentSnapshot());
     if (console.isOk())
     {
@@ -564,35 +556,4 @@
     else
         vboxProblem().cannotDiscardCurrentState (console);
-
-    session.Close();
-}
-
-void VBoxSnapshotsWgt::discardCurSnapAndState()
-{
-    if (!vboxProblem().askAboutSnapshotAndStateDiscarding())
-        return;
-
-    SnapshotWgtItem *item = mTreeWidget->selectedItems().isEmpty() ? 0 :
-        static_cast<SnapshotWgtItem*> (mTreeWidget->selectedItems() [0]);
-    AssertReturn (item, (void) 0);
-
-    /* Open a direct session (this call will handle all errors) */
-    CSession session = vboxGlobal().openSession (mMachineId);
-    if (session.isNull())
-        return;
-
-    CConsole console = session.GetConsole();
-    CProgress progress = console.DiscardCurrentSnapshotAndState();
-    if (console.isOk())
-    {
-        /* Show the progress dialog */
-        vboxProblem().showModalProgressDialog (progress, mMachine.GetName(),
-                                               vboxProblem().mainWindowShown());
-
-        if (progress.GetResultCode() != 0)
-            vboxProblem().cannotDiscardCurrentSnapshotAndState (progress);
-    }
-    else
-        vboxProblem().cannotDiscardCurrentSnapshotAndState (console);
 
     session.Close();
@@ -688,5 +649,4 @@
     mTakeSnapshotAction->setText (tr ("Take &Snapshot"));
     mRevertToCurSnapAction->setText (tr ("&Revert to Current Snapshot"));
-    mDiscardCurSnapAndStateAction->setText (tr ("D&iscard Current Snapshot and State"));
     mShowSnapshotDetailsAction->setText (tr ("S&how Details"));
 
@@ -694,5 +654,4 @@
     mTakeSnapshotAction->setStatusTip (tr ("Take a snapshot of the current virtual machine state"));
     mRevertToCurSnapAction->setStatusTip (tr ("Restore the virtual machine state from the state stored in the current snapshot"));
-    mDiscardCurSnapAndStateAction->setStatusTip (tr ("Discard the current snapshot and revert the machine to the state it had before the snapshot was taken"));
     mShowSnapshotDetailsAction->setStatusTip (tr ("Show details of the selected snapshot"));
 
@@ -703,6 +662,4 @@
     mRevertToCurSnapAction->setToolTip (mRevertToCurSnapAction->text().remove ('&').remove ('.') +
         QString (" (%1)").arg (mRevertToCurSnapAction->shortcut().toString()));
-    mDiscardCurSnapAndStateAction->setToolTip (mDiscardCurSnapAndStateAction->text().remove ('&').remove ('.') +
-        QString (" (%1)").arg (mDiscardCurSnapAndStateAction->shortcut().toString()));
     mShowSnapshotDetailsAction->setToolTip (mShowSnapshotDetailsAction->text().remove ('&').remove ('.') +
         QString (" (%1)").arg (mShowSnapshotDetailsAction->shortcut().toString()));
Index: /trunk/src/VBox/Main/ConsoleImpl.cpp
===================================================================
--- /trunk/src/VBox/Main/ConsoleImpl.cpp	(revision 23878)
+++ /trunk/src/VBox/Main/ConsoleImpl.cpp	(revision 23879)
@@ -2516,5 +2516,5 @@
 }
 
-STDMETHODIMP Console::DiscardSnapshot(IN_BSTR aId, IProgress **aProgress)
+STDMETHODIMP Console::DeleteSnapshot(IN_BSTR aId, IProgress **aProgress)
 {
     CheckComArgExpr(aId, Guid(aId).isEmpty() == false);
@@ -2532,5 +2532,5 @@
 
     MachineState_T machineState = MachineState_Null;
-    HRESULT rc = mControl->DiscardSnapshot(this, aId, &machineState, aProgress);
+    HRESULT rc = mControl->DeleteSnapshot(this, aId, &machineState, aProgress);
     CheckComRCReturnRC(rc);
 
@@ -2539,5 +2539,5 @@
 }
 
-STDMETHODIMP Console::DiscardCurrentState(IProgress **aProgress)
+STDMETHODIMP Console::RestoreSnapshot(ISnapshot *aSnapshot, IProgress **aProgress)
 {
     AutoCaller autoCaller(this);
@@ -2548,30 +2548,9 @@
     if (Global::IsOnlineOrTransient(mMachineState))
         return setError(VBOX_E_INVALID_VM_STATE,
-            tr("Cannot discard the current state of the running machine (machine state: %s)"),
-            Global::stringifyMachineState(mMachineState));
+                        tr("Cannot discard the current state of the running machine (machine state: %s)"),
+                        Global::stringifyMachineState(mMachineState));
 
     MachineState_T machineState = MachineState_Null;
-    HRESULT rc = mControl->DiscardCurrentState(this, &machineState, aProgress);
-    CheckComRCReturnRC(rc);
-
-    setMachineStateLocally(machineState);
-    return S_OK;
-}
-
-STDMETHODIMP Console::DiscardCurrentSnapshotAndState(IProgress **aProgress)
-{
-    AutoCaller autoCaller(this);
-    CheckComRCReturnRC(autoCaller.rc());
-
-    AutoWriteLock alock(this);
-
-    if (Global::IsOnlineOrTransient(mMachineState))
-        return setError(VBOX_E_INVALID_VM_STATE,
-            tr("Cannot discard the current snapshot and state of the running machine (machine state: %s)"),
-            Global::stringifyMachineState(mMachineState));
-
-    MachineState_T machineState = MachineState_Null;
-    HRESULT rc =
-        mControl->DiscardCurrentSnapshotAndState(this, &machineState, aProgress);
+    HRESULT rc = mControl->RestoreSnapshot(this, aSnapshot, &machineState, aProgress);
     CheckComRCReturnRC(rc);
 
@@ -4031,7 +4010,8 @@
     AutoWriteLock alock(this);
 
-    AssertReturn(mMachineState == MachineState_Saving ||
-                  mMachineState == MachineState_Discarding,
-                  E_FAIL);
+    AssertReturn(    mMachineState == MachineState_Saving
+                  || mMachineState == MachineState_RestoringSnapshot
+                  || mMachineState == MachineState_DeletingSnapshot,
+                 E_FAIL);
 
     return setMachineStateLocally(aMachineState);
Index: /trunk/src/VBox/Main/Global.cpp
===================================================================
--- /trunk/src/VBox/Main/Global.cpp	(revision 23878)
+++ /trunk/src/VBox/Main/Global.cpp	(revision 23879)
@@ -186,18 +186,19 @@
     switch (aState)
     {
-        case MachineState_Null:         return "Null";
-        case MachineState_PoweredOff:   return "PoweredOff";
-        case MachineState_Saved:        return "Saved";
-        case MachineState_Aborted:      return "Aborted";
-        case MachineState_Running:      return "Running";
-        case MachineState_Paused:       return "Paused";
-        case MachineState_Stuck:        return "GuruMeditation";
-        case MachineState_Starting:     return "Starting";
-        case MachineState_Stopping:     return "Stopping";
-        case MachineState_Saving:       return "Saving";
-        case MachineState_Restoring:    return "Restoring";
-        case MachineState_TeleportingFrom: return "TeleportingFrom";
-        case MachineState_Discarding:   return "Discarding";
-        case MachineState_SettingUp:    return "SettingUp";
+        case MachineState_Null:                 return "Null";
+        case MachineState_PoweredOff:           return "PoweredOff";
+        case MachineState_Saved:                return "Saved";
+        case MachineState_Aborted:              return "Aborted";
+        case MachineState_Running:              return "Running";
+        case MachineState_Paused:               return "Paused";
+        case MachineState_Stuck:                return "GuruMeditation";
+        case MachineState_Starting:             return "Starting";
+        case MachineState_Stopping:             return "Stopping";
+        case MachineState_Saving:               return "Saving";
+        case MachineState_Restoring:            return "Restoring";
+        case MachineState_TeleportingFrom:      return "TeleportingFrom";
+        case MachineState_RestoringSnapshot:    return "RestoringSnapshot";
+        case MachineState_DeletingSnapshot:     return "DeletingSnapshot";
+        case MachineState_SettingUp:            return "SettingUp";
         default:
         {
Index: /trunk/src/VBox/Main/MachineImpl.cpp
===================================================================
--- /trunk/src/VBox/Main/MachineImpl.cpp	(revision 23878)
+++ /trunk/src/VBox/Main/MachineImpl.cpp	(revision 23879)
@@ -6528,6 +6528,8 @@
 
     /* must be in a protective state because we leave the lock below */
-    AssertReturn(   mData->mMachineState == MachineState_Saving
-                 || mData->mMachineState == MachineState_Discarding, E_FAIL);
+    AssertReturn(    mData->mMachineState == MachineState_Saving
+                  || mData->mMachineState == MachineState_RestoringSnapshot
+                  || mData->mMachineState == MachineState_DeletingSnapshot,
+                 E_FAIL);
 
     HRESULT rc = S_OK;
@@ -6744,9 +6746,9 @@
          * protected) */
         MachineState_T oldState = mData->mMachineState;
-        if (oldState != MachineState_Saving &&
-            oldState != MachineState_Discarding)
-        {
+        if (    oldState != MachineState_Saving
+             && oldState != MachineState_RestoringSnapshot
+             && oldState != MachineState_DeletingSnapshot
+           )
             setMachineState (MachineState_SettingUp);
-        }
 
         alock.leave();
@@ -7573,15 +7575,15 @@
 
 /** Discard snapshot task */
-struct SessionMachine::DiscardSnapshotTask
+struct SessionMachine::DeleteSnapshotTask
     : public SessionMachine::Task
 {
-    DiscardSnapshotTask(SessionMachine *m, Progress *p, Snapshot *s)
-        : Task (m, p),
-          snapshot (s)
+    DeleteSnapshotTask(SessionMachine *m, Progress *p, Snapshot *s)
+        : Task(m, p),
+          snapshot(s)
     {}
 
-    DiscardSnapshotTask (const Task &task, Snapshot *s)
-        : Task (task)
-        , snapshot (s)
+    DeleteSnapshotTask (const Task &task, Snapshot *s)
+        : Task(task)
+        , snapshot(s)
     {}
 
@@ -7594,9 +7596,9 @@
 };
 
-/** Discard current state task */
-struct SessionMachine::DiscardCurrentStateTask
+/** Restore snapshot state task */
+struct SessionMachine::RestoreSnapshotTask
     : public SessionMachine::Task
 {
-    DiscardCurrentStateTask(SessionMachine *m, Progress *p, bool discardCurSnapshot)
+    RestoreSnapshotTask(SessionMachine *m, Progress *p, bool discardCurSnapshot)
         : Task(m, p),
           discardCurrentSnapshot(discardCurSnapshot)
@@ -7605,5 +7607,5 @@
     void handler()
     {
-        machine->discardCurrentStateHandler(*this);
+        machine->restoreSnapshotHandler(*this);
     }
 
@@ -8605,8 +8607,8 @@
  *  @note Locks mParent + this + children objects for writing!
  */
-STDMETHODIMP SessionMachine::DiscardSnapshot(IConsole *aInitiator,
-                                             IN_BSTR aId,
-                                             MachineState_T *aMachineState,
-                                             IProgress **aProgress)
+STDMETHODIMP SessionMachine::DeleteSnapshot(IConsole *aInitiator,
+                                            IN_BSTR aId,
+                                            MachineState_T *aMachineState,
+                                            IProgress **aProgress)
 {
     LogFlowThisFunc(("\n"));
@@ -8648,5 +8650,5 @@
         {
             rc = saveSettings();
-            CheckComRCReturnRC (rc);
+            CheckComRCReturnRC(rc);
         }
     }
@@ -8657,18 +8659,22 @@
     ComObjPtr<Progress> progress;
     progress.createObject();
-    rc = progress->init (mParent, aInitiator,
-                         Bstr(Utf8StrFmt(tr("Discarding snapshot '%s'"),
-                                            snapshot->getName().c_str())),
-                         FALSE /* aCancelable */,
-                         1 + (ULONG)snapshot->getSnapshotMachine()->mMediaData->mAttachments.size() +
-                         (snapshot->stateFilePath().isNull() ? 0 : 1),
-                         Bstr (tr ("Preparing to discard snapshot")));
-    AssertComRCReturn (rc, rc);
+    rc = progress->init(mParent, aInitiator,
+                        BstrFmt(tr("Discarding snapshot '%s'"),
+                                snapshot->getName().c_str()),
+                        FALSE /* aCancelable */,
+                        1 + (ULONG)snapshot->getSnapshotMachine()->mMediaData->mAttachments.size() +
+                        (snapshot->stateFilePath().isNull() ? 0 : 1),
+                        Bstr (tr ("Preparing to discard snapshot")));
+    AssertComRCReturn(rc, rc);
 
     /* create and start the task on a separate thread */
-    DiscardSnapshotTask *task = new DiscardSnapshotTask (this, progress, snapshot);
-    int vrc = RTThreadCreate (NULL, taskHandler,
-                              (void *) task,
-                              0, RTTHREADTYPE_MAIN_WORKER, 0, "DiscardSnapshot");
+    DeleteSnapshotTask *task = new DeleteSnapshotTask(this, progress, snapshot);
+    int vrc = RTThreadCreate(NULL,
+                             taskHandler,
+                             (void*)task,
+                             0,
+                             RTTHREADTYPE_MAIN_WORKER,
+                             0,
+                             "DeleteSnapshot");
     if (RT_FAILURE(vrc))
         delete task;
@@ -8676,5 +8682,5 @@
 
     /* set the proper machine state (note: after creating a Task instance) */
-    setMachineState(MachineState_Discarding);
+    setMachineState(MachineState_DeletingSnapshot);
 
     /* return the progress to the caller */
@@ -8690,6 +8696,8 @@
  *  @note Locks this + children objects for writing!
  */
-STDMETHODIMP SessionMachine::DiscardCurrentState (
-    IConsole *aInitiator, MachineState_T *aMachineState, IProgress **aProgress)
+STDMETHODIMP SessionMachine::RestoreSnapshot(IConsole *aInitiator,
+                                             ISnapshot *aSnapshot,
+                                             MachineState_T *aMachineState,
+                                             IProgress **aProgress)
 {
     LogFlowThisFunc(("\n"));
@@ -8703,5 +8711,6 @@
     AutoWriteLock alock(this);
 
-    ComAssertRet (!Global::IsOnlineOrTransient (mData->mMachineState), E_FAIL);
+    ComAssertRet(!Global::IsOnlineOrTransient(mData->mMachineState),
+                 E_FAIL);
 
     if (mData->mCurrentSnapshot.isNull())
@@ -8726,97 +8735,12 @@
     /* create and start the task on a separate thread (note that it will not
      * start working until we release alock) */
-    DiscardCurrentStateTask *task =
-        new DiscardCurrentStateTask (this, progress, false /* discardCurSnapshot */);
-    int vrc = RTThreadCreate (NULL, taskHandler,
-                              (void *) task,
-                              0, RTTHREADTYPE_MAIN_WORKER, 0, "DiscardCurState");
-    if (RT_FAILURE(vrc))
-    {
-        delete task;
-        ComAssertRCRet (vrc, E_FAIL);
-    }
-
-    /* set the proper machine state (note: after creating a Task instance) */
-    setMachineState (MachineState_Discarding);
-
-    /* return the progress to the caller */
-    progress.queryInterfaceTo(aProgress);
-
-    /* return the new state to the caller */
-    *aMachineState = mData->mMachineState;
-
-    return S_OK;
-}
-
-/**
- *  @note Locks thos object for writing!
- */
-STDMETHODIMP SessionMachine::DiscardCurrentSnapshotAndState(IConsole *aInitiator,
-                                                            MachineState_T *aMachineState,
-                                                            IProgress **aProgress)
-{
-    LogFlowThisFunc(("\n"));
-
-    AssertReturn(aInitiator, E_INVALIDARG);
-    AssertReturn(aMachineState && aProgress, E_POINTER);
-
-    AutoCaller autoCaller(this);
-    AssertComRCReturn (autoCaller.rc(), autoCaller.rc());
-
-    AutoWriteLock alock(this);
-
-    ComAssertRet (!Global::IsOnlineOrTransient (mData->mMachineState), E_FAIL);
-
-    if (mData->mCurrentSnapshot.isNull())
-        return setError(VBOX_E_INVALID_OBJECT_STATE,
-                        tr("Could not discard the current state of the machine '%ls' "
-                           "because it doesn't have any snapshots"),
-                        mUserData->mName.raw());
-
-    /* create a progress object. The number of operations is:
-     *   1 (preparing) + # of hard disks in the current snapshot +
-     *   # of hard disks in the previous snapshot +
-     *   1 if we need to copy the saved state file of the previous snapshot +
-     *   1 if the current snapshot is online
-     * or (if there is no previous snapshot):
-     *   1 (preparing) + # of hard disks in the current snapshot * 2 +
-     *   1 if we need to copy the saved state file of the current snapshot * 2
-     */
-    ComObjPtr<Progress> progress;
-    progress.createObject();
-    {
-        ComObjPtr<Snapshot> curSnapshot = mData->mCurrentSnapshot;
-        ComObjPtr<Snapshot> prevSnapshot = mData->mCurrentSnapshot->parent();
-
-        ULONG opCount = 1;
-        if (prevSnapshot)
-        {
-            opCount += (ULONG)curSnapshot->getSnapshotMachine()->mMediaData->mAttachments.size();
-            opCount += (ULONG)prevSnapshot->getSnapshotMachine()->mMediaData->mAttachments.size();
-            if (prevSnapshot->stateFilePath())
-                ++opCount;
-            if (curSnapshot->stateFilePath())
-                ++opCount;
-        }
-        else
-        {
-            opCount +=
-                (ULONG)curSnapshot->getSnapshotMachine()->mMediaData->mAttachments.size() * 2;
-            if (curSnapshot->stateFilePath())
-                opCount += 2;
-        }
-
-        progress->init(mParent, aInitiator,
-                       Bstr (tr ("Discarding current machine snapshot and state")),
-                       FALSE /* aCancelable */, opCount,
-                       Bstr (tr ("Preparing to discard current snapshot and state")));
-    }
-
-    /* create and start the task on a separate thread */
-    DiscardCurrentStateTask *task =
-        new DiscardCurrentStateTask (this, progress, true /* discardCurSnapshot */);
-    int vrc = RTThreadCreate(NULL, taskHandler,
-                             (void *) task,
-                             0, RTTHREADTYPE_MAIN_WORKER, 0, "DiscardCurStSnp");
+    RestoreSnapshotTask *task = new RestoreSnapshotTask(this, progress, false /* discardCurSnapshot */);
+    int vrc = RTThreadCreate(NULL,
+                             taskHandler,
+                             (void*)task,
+                             0,
+                             RTTHREADTYPE_MAIN_WORKER,
+                             0,
+                             "DiscardCurState");
     if (RT_FAILURE(vrc))
     {
@@ -8826,5 +8750,5 @@
 
     /* set the proper machine state (note: after creating a Task instance) */
-    setMachineState(MachineState_Discarding);
+    setMachineState(MachineState_RestoringSnapshot);
 
     /* return the progress to the caller */
@@ -9558,5 +9482,5 @@
 /**
  * Discard snapshot task handler. Must be called only by
- * DiscardSnapshotTask::handler()!
+ * DeleteSnapshotTask::handler()!
  *
  * When aTask.subTask is true, the associated progress object is left
@@ -9566,5 +9490,5 @@
  * @note Locks mParent + this + child objects for writing!
  */
-void SessionMachine::discardSnapshotHandler(DiscardSnapshotTask &aTask)
+void SessionMachine::discardSnapshotHandler(DeleteSnapshotTask &aTask)
 {
     LogFlowThisFuncEnter();
@@ -9843,10 +9767,10 @@
 
 /**
- * Discard current state task handler. Must be called only by
- * DiscardCurrentStateTask::handler()!
+ * Restore snapshot state task handler. Must be called only by
+ * RestoreSnapshotTask::handler()!
  *
  * @note Locks mParent + this object for writing.
  */
-void SessionMachine::discardCurrentStateHandler (DiscardCurrentStateTask &aTask)
+void SessionMachine::restoreSnapshotHandler(RestoreSnapshotTask &aTask)
 {
     LogFlowThisFuncEnter();
@@ -9859,7 +9783,8 @@
         /* we might have been uninitialized because the session was accidentally
          * closed by the client, so don't assert */
-        aTask.progress->notifyComplete (
-            E_FAIL, COM_IIDOF (IMachine), getComponentName(),
-            tr ("The session has been accidentally closed"));
+        aTask.progress->notifyComplete(E_FAIL,
+                                       COM_IIDOF(IMachine),
+                                       getComponentName(),
+                                       tr("The session has been accidentally closed"));
 
         LogFlowThisFuncLeave();
@@ -9881,5 +9806,5 @@
      * session) */
     if (isModified())
-        rollback (false /* aNotify */);
+        rollback(false /* aNotify */);
 
     HRESULT rc = S_OK;
@@ -9910,5 +9835,5 @@
              * snapshot first */
 
-            DiscardSnapshotTask subTask (aTask, mData->mCurrentSnapshot);
+            DeleteSnapshotTask subTask (aTask, mData->mCurrentSnapshot);
             subTask.subTask = true;
             discardSnapshotHandler (subTask);
@@ -10059,5 +9984,5 @@
              * after discarding the current state. */
 
-            DiscardSnapshotTask subTask (aTask, mData->mCurrentSnapshot);
+            DeleteSnapshotTask subTask (aTask, mData->mCurrentSnapshot);
             subTask.subTask = true;
             discardSnapshotHandler (subTask);
@@ -10395,5 +10320,6 @@
     }
     else if (   oldMachineState >= MachineState_Running
-             && oldMachineState != MachineState_Discarding
+             && oldMachineState != MachineState_RestoringSnapshot
+             && oldMachineState != MachineState_DeletingSnapshot
              && oldMachineState != MachineState_SettingUp
              && aMachineState < MachineState_Running
Index: /trunk/src/VBox/Main/idl/VirtualBox.xidl
===================================================================
--- /trunk/src/VBox/Main/idl/VirtualBox.xidl	(revision 23878)
+++ /trunk/src/VBox/Main/idl/VirtualBox.xidl	(revision 23879)
@@ -574,7 +574,7 @@
     +-&gt; PoweredOff --+
     |                |
-    |   Aborted -----+--&gt;[discardSnapshot()    ]-------------&gt; Discarding --+
-    |                |   [discardCurrentState()]                            |
-    +-&gt; Saved -------+   [discardCurrentSnapshotAndState()]                 |
+    |   Aborted -----+--&gt;[restoreSnapshot()    ]-------&gt; RestoringSnapshot -+
+    |                |   [deleteSnapshot()     ]-------&gt; DeletingSnapshot --+
+    +-&gt; Saved -------+                                                      |
     |                                                                       |
     +---(Saved if restored from an online snapshot, PoweredOff otherwise)---+
@@ -678,10 +678,16 @@
       </desc>
     </const>
-    <const name="Discarding"            value="12">
-      <desc>
-        Snapshot of the machine is being discarded.
-      </desc>
-    </const>
-    <const name="SettingUp"             value="13">
+    <const name="RestoringSnapshot"     value="12">
+      <desc>
+        A machine snapshot is being restored; this typically does not take long.
+      </desc>
+    </const>
+    <const name="DeletingSnapshot"      value="13">
+      <desc>
+        A machine snapshot is being deleted; this can take a long time since this
+        may require merging differencing hard disk images.
+      </desc>
+    </const>
+    <const name="SettingUp"             value="14">
       <desc>
         Lengthy setup operation is in progress.
@@ -705,5 +711,5 @@
       </desc>
     </const>
-    <const name="LastTransient"  value="13" wsmap="suppress"> <!-- SettingUp -->
+    <const name="LastTransient"  value="14" wsmap="suppress"> <!-- SettingUp -->
       <desc>
         Pseudo-state: last transient state (for use in relational expressions).
@@ -3631,5 +3637,5 @@
   <interface
      name="IInternalMachineControl" extends="$unknown"
-     uuid="6c08103e-b8e6-44fb-bc6c-36067153d4bd"
+     uuid="4e2b8f0f-6575-49d2-bb19-5cd15a6ca2f0"
      internal="yes"
      wsmap="suppress"
@@ -3854,7 +3860,7 @@
     </method>
 
-    <method name="discardSnapshot">
-      <desc>
-        Gets called by IConsole::discardSnapshot.
+    <method name="deleteSnapshot">
+      <desc>
+        Gets called by IConsole::deleteSnapshot.
         <result name="VBOX_E_INVALID_OBJECT_STATE">
           Snapshot has more than one child snapshot.
@@ -3875,31 +3881,13 @@
     </method>
 
-    <method name="discardCurrentState">
-      <desc>
-        Gets called by IConsole::discardCurrentState.
-        <result name="VBOX_E_INVALID_OBJECT_STATE">
-          Virtual machine does not have any snapshot.
-        </result>
+    <method name="restoreSnapshot">
+      <desc>
+        Gets called by IConsole::RestoreSnapshot.
       </desc>
       <param name="initiator" type="IConsole" dir="in">
         <desc>The console object that initiated this call.</desc>
       </param>
-      <param name="machineState" type="MachineState" dir="out">
-        <desc>New machine state after this operation is started.</desc>
-      </param>
-      <param name="progress" type="IProgress" dir="return">
-        <desc>Progress object to track the operation completion.</desc>
-      </param>
-    </method>
-
-    <method name="discardCurrentSnapshotAndState">
-      <desc>
-        Gets called by IConsole::discardCurrentSnapshotAndState.
-        <result name="VBOX_E_INVALID_OBJECT_STATE">
-          Virtual machine does not have any snapshot.
-        </result>
-      </desc>
-      <param name="initiator" type="IConsole" dir="in">
-        <desc>The console object that initiated this call.</desc>
+      <param name="snapshot" type="ISnapshot" dir="in">
+        <desc>The snapshot to restore the VM state from.</desc>
       </param>
       <param name="machineState" type="MachineState" dir="out">
@@ -4454,6 +4442,9 @@
       <desc>
         Current snapshot of this machine. This is @c null if the machine
-        currently has no snapshots. Otherwise, this is always the last snapshot
-        in the current implementation; see <link to="ISnapshot"/> for details.
+        currently has no snapshots. If it is not @c null, then it was
+        set by one of <link to="Console::takeSnapshot" />,
+        <link to="Console::deleteSnapshot" />
+        or <link to="Console::restoreSnapshot" />, depending on which
+        was called last. See <link to="ISnapshot"/> for details.
       </desc>
     </attribute>
@@ -4471,12 +4462,12 @@
         identical to the state stored in the current snapshot.
 
-        The current state is identical to the current snapshot right
-        after one of the following calls are made:
+        The current state is identical to the current snapshot only
+        directly after one of the following calls are made:
+
         <ul>
-          <li><link to="IConsole::discardCurrentState"/> or
-            <link to="IConsole::discardCurrentSnapshotAndState"/>
+          <li><link to="IConsole::restoreSnapshot"/>
           </li>
           <li><link to="IConsole::takeSnapshot"/> (issued on a
-            powered off or saved machine, for which
+            "powered off" or "saved" machine, for which
             <link to="#settingsModified"/> returns @c false)
           </li>
@@ -6088,5 +6079,5 @@
   <interface
      name="IConsole" extends="$unknown"
-     uuid="03312360-0364-4b7a-ad71-1a8450133774"
+     uuid="55dd56a5-1d1d-4d81-b742-b082b9571be6"
      wsmap="managed"
      >
@@ -6642,5 +6633,5 @@
     </method>
 
-    <method name="discardSnapshot">
+    <method name="deleteSnapshot">
       <desc>
         Starts discarding the specified snapshot asynchronously.
@@ -6738,8 +6729,8 @@
     </method>
 
-    <method name="discardCurrentState">
+    <method name="restoreSnapshot">
       <desc>
         Starts resetting the machine's current state to the state contained
-        in the current snapshot, asynchronously. All current settings of the
+        in the given snapshot, asynchronously. All current settings of the
         machine will be reset and changes stored in differencing media
         will be lost.
@@ -6749,8 +6740,8 @@
         media are created for all normal media of the machine.
 
-        If the current snapshot of the machine is an online snapshot, the
-        machine will go to the <link to="MachineState_Saved"> saved
-        state</link>, so that the next time it is powered on, the execution
-        state will be restored from the current snapshot.
+        If the given snapshot is an online snapshot, the machine will go to
+        the <link to="MachineState_Saved"> saved state</link>, so that the
+        next time it is powered on, the execution state will be restored
+        from the state of the snapshot.
 
         <note>
@@ -6769,56 +6760,7 @@
         </result>
       </desc>
-      <param name="progress" type="IProgress" dir="return">
-        <desc>Progress object to track the operation completion.</desc>
-      </param>
-    </method>
-
-    <method name="discardCurrentSnapshotAndState">
-      <desc>
-
-        This method is equivalent to
-        doing <link to="IConsole::discardSnapshot">discardSnapshot</link>
-        (currentSnapshot.id(), progress) followed by
-        <link to="IConsole::discardCurrentState"/>.
-
-        As a result, the machine will be fully restored from the
-        snapshot preceding the current snapshot, while both the current
-        snapshot and the current machine state will be discarded.
-
-        If the current snapshot is the first snapshot of the machine (i.e. it
-        has the only snapshot), the current machine state will be
-        discarded <b>before</b> discarding the snapshot. In other words, the
-        machine will be restored from its last snapshot, before discarding
-        it. This differs from performing a single
-        <link to="IConsole::discardSnapshot"/> call (note that no
-        <link to="IConsole::discardCurrentState"/> will be possible after it)
-        to the effect that the latter will preserve the current state instead of
-        discarding it.
-
-        Unless explicitly mentioned otherwise, all remarks and
-        limitations of the above two methods also apply to this method.
-
-        <note>
-          The machine must not be running, otherwise the operation
-          will fail.
-        </note>
-
-        <note>
-          If the machine state is <link to="MachineState_Saved">Saved</link>
-          prior to this operation, the saved state file will be implicitly
-          discarded (as if <link to="#forgetSavedState"/> were
-          called).
-        </note>
-
-        <note>
-          This method is more efficient than calling both of the above
-          methods separately: it requires less IPC calls and provides
-          a single progress object.
-        </note>
-
-        <result name="VBOX_E_INVALID_VM_STATE">
-          Virtual machine is running.
-        </result>
-      </desc>
+      <param name="snapshot" type="ISnapshot" dir="in">
+        <desc>The snapshot to restore the VM state from.</desc>
+      </param>
       <param name="progress" type="IProgress" dir="return">
         <desc>Progress object to track the operation completion.</desc>
@@ -8174,5 +8116,5 @@
           </li>
 
-          <li><link to="IConsole::discardCurrentState"/>: this goes back to
+          <li><link to="IConsole::restoreSnapshot"/>: this goes back to
               a previous snapshot. This resets the machine's state to that of
               the previous snapshot by deleting the differencing image of each
@@ -8183,5 +8125,5 @@
           </li>
 
-          <li><link to="IConsole::discardSnapshot"/>: deletes a snapshot
+          <li><link to="IConsole::deleteSnapshot"/>: deletes a snapshot
               without affecting the current machine state.
 
@@ -8194,13 +8136,4 @@
               by this operation, except that parent disk images will be modified
               to contain the disk data associated with the snapshot being deleted.
-          </li>
-
-          <li><link to="IConsole::discardCurrentSnapshotAndState"/>:
-              this completely reverts the virtual machine to the state it was in
-              before the current snapshot has been taken. Effectively, this goes
-              back to the state before the current snapshot, which might be
-              an earlier snapshot.
-
-              The current state, as well as the current snapshot, are lost.
           </li>
       </ul>
Index: /trunk/src/VBox/Main/include/ConsoleImpl.h
===================================================================
--- /trunk/src/VBox/Main/include/ConsoleImpl.h	(revision 23878)
+++ /trunk/src/VBox/Main/include/ConsoleImpl.h	(revision 23879)
@@ -145,7 +145,6 @@
     STDMETHOD(TakeSnapshot) (IN_BSTR aName, IN_BSTR aDescription,
                              IProgress **aProgress);
-    STDMETHOD(DiscardSnapshot) (IN_BSTR aId, IProgress **aProgress);
-    STDMETHOD(DiscardCurrentState) (IProgress **aProgress);
-    STDMETHOD(DiscardCurrentSnapshotAndState) (IProgress **aProgress);
+    STDMETHOD(DeleteSnapshot)(IN_BSTR aId, IProgress **aProgress);
+    STDMETHOD(RestoreSnapshot)(ISnapshot *aSnapshot, IProgress **aProgress);
     STDMETHOD(Teleport)(IN_BSTR aHostname, ULONG aPort, IN_BSTR aPassword, IProgress **aProgress);
     STDMETHOD(RegisterCallback) (IConsoleCallback *aCallback);
Index: /trunk/src/VBox/Main/include/MachineImpl.h
===================================================================
--- /trunk/src/VBox/Main/include/MachineImpl.h	(revision 23878)
+++ /trunk/src/VBox/Main/include/MachineImpl.h	(revision 23879)
@@ -968,10 +968,10 @@
                                    BSTR *aStateFilePath);
     STDMETHOD(EndTakingSnapshot)(BOOL aSuccess);
-    STDMETHOD(DiscardSnapshot)(IConsole *aInitiator, IN_BSTR aId,
-                               MachineState_T *aMachineState, IProgress **aProgress);
-    STDMETHOD(DiscardCurrentState)(IConsole *aInitiator, MachineState_T *aMachineState,
-                                   IProgress **aProgress);
-    STDMETHOD(DiscardCurrentSnapshotAndState)(IConsole *aInitiator, MachineState_T *aMachineState,
-                                              IProgress **aProgress);
+    STDMETHOD(DeleteSnapshot)(IConsole *aInitiator, IN_BSTR aId,
+                              MachineState_T *aMachineState, IProgress **aProgress);
+    STDMETHOD(RestoreSnapshot)(IConsole *aInitiator,
+                               ISnapshot *aSnapshot,
+                               MachineState_T *aMachineState,
+                               IProgress **aProgress);
     STDMETHOD(PullGuestProperties)(ComSafeArrayOut(BSTR, aNames), ComSafeArrayOut(BSTR, aValues),
               ComSafeArrayOut(ULONG64, aTimestamps), ComSafeArrayOut(BSTR, aFlags));
@@ -1024,9 +1024,9 @@
 
     struct Task;
-    struct DiscardSnapshotTask;
-    struct DiscardCurrentStateTask;
-
-    friend struct DiscardSnapshotTask;
-    friend struct DiscardCurrentStateTask;
+    struct DeleteSnapshotTask;
+    struct RestoreSnapshotTask;
+
+    friend struct DeleteSnapshotTask;
+    friend struct RestoreSnapshotTask;
 
     void uninit(Uninit::Reason aReason);
@@ -1037,6 +1037,6 @@
     typedef std::map<ComObjPtr<Machine>, MachineState_T> AffectedMachines;
 
-    void discardSnapshotHandler(DiscardSnapshotTask &aTask);
-    void discardCurrentStateHandler(DiscardCurrentStateTask &aTask);
+    void discardSnapshotHandler(DeleteSnapshotTask &aTask);
+    void restoreSnapshotHandler(RestoreSnapshotTask &aTask);
 
     HRESULT lockMedia();
