Index: trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_misc.c
===================================================================
--- trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_misc.c	(revision 50178)
+++ trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_misc.c	(revision 50184)
@@ -238,4 +238,8 @@
         }
         cr_server.projectionOverride = GL_TRUE;
+        break;
+
+    case GL_HH_SET_TMPCTX_MAKE_CURRENT:
+        /*we should not receive it from the guest! */
         break;
 
@@ -673,5 +677,5 @@
         Ctx.Base.id = cr_server.MainContextInfo.SpuContext;
         Ctx.Base.visualBits = cr_server.MainContextInfo.CreateInfo.visualBits;
-        rc = CrBltInit(&cr_server.Blitter, &Ctx, true, true, NULL, &cr_server.head_spu->dispatch_table);
+        rc = CrBltInit(&cr_server.Blitter, &Ctx, true, true, NULL, &cr_server.TmpCtxDispatch);
         if (RT_SUCCESS(rc))
         {
@@ -685,4 +689,14 @@
         }
     }
+
+    if (!CrBltMuralGetCurrentInfo(&cr_server.Blitter)->Base.id)
+    {
+        CRMuralInfo *dummy = crServerGetDummyMural(cr_server.MainContextInfo.CreateInfo.visualBits);
+        CR_BLITTER_WINDOW DummyInfo;
+        CRASSERT(dummy);
+        crServerVBoxBlitterWinInit(&DummyInfo, dummy);
+        CrBltMuralSetCurrentInfo(&cr_server.Blitter, &DummyInfo);
+    }
+
     return &cr_server.Blitter;
 }
@@ -1347,11 +1361,33 @@
     if (pCtx)
     {
-        GLint curSrvSpuCtx = cr_server.currentCtxInfo && cr_server.currentCtxInfo->SpuContext > 0 ? cr_server.currentCtxInfo->SpuContext : cr_server.MainContextInfo.SpuContext;
-        bool fSwitchToTmpCtx = (curSrvSpuCtx != context);
         CRMuralInfo *pCurrentMural = cr_server.currentMural;
-        CRContextInfo *pCurCtxInfo = cr_server.currentCtxInfo;
-        pCurCtx = pCurCtxInfo ? pCurCtxInfo->pContext : NULL;
-
-        CRASSERT(pCurCtx == pCtx);
+
+        pCurCtx = cr_server.currentCtxInfo ? cr_server.currentCtxInfo->pContext : cr_server.MainContextInfo.pContext;
+        Assert(pCurCtx == pCtx);
+
+        if (!context)
+        {
+            if (pCurrentMural)
+            {
+                Assert(cr_server.currentCtxInfo);
+                context = cr_server.currentCtxInfo->SpuContext > 0 ? cr_server.currentCtxInfo->SpuContext : cr_server.MainContextInfo.SpuContext;
+                window = pCurrentMural->spuWindow;
+            }
+            else
+            {
+                CRMuralInfo * pDummy;
+                Assert(!cr_server.currentCtxInfo);
+                pDummy = crServerGetDummyMural(cr_server.MainContextInfo.CreateInfo.visualBits);
+                context = cr_server.MainContextInfo.SpuContext;
+                window = pDummy->spuWindow;
+            }
+
+
+            fDoPrePostProcess = -1;
+        }
+        else
+        {
+            fDoPrePostProcess = 1;
+        }
 
         if (pCurrentMural)
@@ -1365,6 +1401,4 @@
             idReadFBO = 0;
         }
-
-        fDoPrePostProcess = fSwitchToTmpCtx ? 1 : -1;
     }
     else
@@ -1384,7 +1418,13 @@
 void crServerInitTmpCtxDispatch()
 {
+    MakeCurrentFunc_t pfnMakeCurrent;
+
     crSPUInitDispatchTable(&cr_server.TmpCtxDispatch);
     crSPUCopyDispatchTable(&cr_server.TmpCtxDispatch, &cr_server.head_spu->dispatch_table);
     cr_server.TmpCtxDispatch.MakeCurrent = crServerMakeTmpCtxCurrent;
+
+    pfnMakeCurrent = crServerMakeTmpCtxCurrent;
+    cr_server.head_spu->dispatch_table.ChromiumParametervCR(GL_HH_SET_TMPCTX_MAKE_CURRENT, GL_BYTE, sizeof (void*), &pfnMakeCurrent);
+
 }
 
Index: trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_presenter.cpp
===================================================================
--- trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_presenter.cpp	(revision 50178)
+++ trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_presenter.cpp	(revision 50184)
@@ -330,5 +330,5 @@
     CRTextureObj *pTobj = pFbTex->pTobj;
 
-    CrTdBltDataCleanup(pTex);
+    CrTdBltDataCleanupNe(pTex);
 
     if (pTobj)
@@ -2433,5 +2433,33 @@
         }
 
-    	return vrdpFrame(hNewEntry);
+        const VBOXVR_SCR_COMPOSITOR_ENTRY* pReplacedEntry = CrFbEntryGetCompositorEntry(hReplacedEntry);
+        CR_TEXDATA *pReplacedTex = CrVrScrCompositorEntryTexGet(pReplacedEntry);
+        const VBOXVR_SCR_COMPOSITOR_ENTRY* pNewEntry = CrFbEntryGetCompositorEntry(hNewEntry);
+        CR_TEXDATA *pNewTex = CrVrScrCompositorEntryTexGet(pNewEntry);
+
+        rc = CrTdBltEnter(pReplacedTex);
+        if (RT_SUCCESS(rc))
+        {
+            if (pNewTex != pReplacedTex)
+            {
+                CrTdBltDataDiscard(pReplacedTex);
+                rc = CrTdBltEnter(pNewTex);
+                if (RT_SUCCESS(rc))
+                {
+                    rc = vrdpFrame(hNewEntry);
+                    CrTdBltLeave(pNewTex);
+                }
+                else
+                    WARN(("CrTdBltEnter failed %d", rc));
+            }
+            else
+                rc = vrdpFrame(hNewEntry);
+
+            CrTdBltLeave(pReplacedTex);
+        }
+        else
+            WARN(("CrTdBltEnter failed %d", rc));
+
+    	return rc;
     }
 
@@ -2445,5 +2473,17 @@
         }
 
-    	return vrdpFrame(hEntry);
+        const VBOXVR_SCR_COMPOSITOR_ENTRY* pEntry = CrFbEntryGetCompositorEntry(hEntry);
+        CR_TEXDATA *pTex = CrVrScrCompositorEntryTexGet(pEntry);
+
+        rc = CrTdBltEnter(pTex);
+        if (RT_SUCCESS(rc))
+        {
+            rc = vrdpFrame(hEntry);
+            CrTdBltLeave(pTex);
+        }
+        else
+            WARN(("CrTdBltEnter failed %d", rc));
+
+    	return rc;
     }
 
@@ -2597,4 +2637,5 @@
     	CR_TEXDATA *pTex = CrVrScrCompositorEntryTexGet(pEntry);
     	const CR_BLITTER_IMG *pImg;
+        CrTdBltDataDiscard(pTex);
     	int rc = CrTdBltDataAcquire(pTex, GL_BGRA, !!(CrVrScrCompositorEntryFlagsGet(pEntry) & CRBLT_F_INVERT_SRC_YCOORDS), &pImg);
     	if (!RT_SUCCESS(rc))
Index: trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_window.c
===================================================================
--- trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_window.c	(revision 50178)
+++ trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_window.c	(revision 50184)
@@ -196,4 +196,5 @@
     		CR_BLITTER_WINDOW DummyInfo;
     		CRASSERT(dummy);
+    		crServerVBoxBlitterWinInit(&DummyInfo, dummy);
     		CrBltMuralSetCurrentInfo(pBlitter, &DummyInfo);
     	}
Index: trunk/src/VBox/HostServices/SharedOpenGL/render/renderspu.c
===================================================================
--- trunk/src/VBox/HostServices/SharedOpenGL/render/renderspu.c	(revision 50178)
+++ trunk/src/VBox/HostServices/SharedOpenGL/render/renderspu.c	(revision 50184)
@@ -1545,10 +1545,10 @@
     		memcpy(&render_spu.blitterDispatch.MakeCurrent, values, count);
     	else
-    		crWarning("unexpected type(%#x) - count(%d) pair", type, count);
+    		WARN(("unexpected type(%#x) - count(%d) pair", type, count));
     	break;
 
     default:
 #if 0
-        crWarning("Unhandled target in renderspuChromiumParametervCR(0x%x)", (int) target);
+        WARN(("Unhandled target in renderspuChromiumParametervCR(0x%x)", (int) target));
 #endif
         break;
