devsound/a3fdevsound/src/devsoundadaptor/mmfdevsoundadaptationbody.cpp
branchRCL_3
changeset 12 b74061f7f3d2
parent 0 40261b775718
child 23 545d349d14da
--- a/devsound/a3fdevsound/src/devsoundadaptor/mmfdevsoundadaptationbody.cpp	Wed Mar 31 23:56:23 2010 +0300
+++ b/devsound/a3fdevsound/src/devsoundadaptor/mmfdevsoundadaptationbody.cpp	Wed Apr 14 17:32:53 2010 +0300
@@ -1243,3 +1243,15 @@
 	ASSERT(iDevAudio);
 	iDevAudio->GetAudioControl()->BufferErrorEvent();
 	}
+
+void CMMFDevSoundAdaptation::CBody::RollbackAdaptorActiveStateToBeforeCommit()
+	{
+	DP_CONTEXT(CMMFDevSoundAdaptation::CBody::RollbackAdaptorActiveStateToBeforeCommit *CD1*, CtxDevSound, DPLOCAL);
+	DP_IN();
+	TDevSoundAdaptorState previousState = iDevAudio->PreviousState();
+	// Set previous state to the active state set after state changing Commit call
+	iDevAudio->SetPreviousState(iDevAudio->ActiveState());
+	// Set active state to the previous state set before state changing Commit call
+	iDevAudio->SetActiveState(previousState);
+	DP_OUT();
+	}