Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(559)

Side by Side Diff: Source/WebCore/platform/graphics/chromium/cc/CCThreadProxy.cpp

Issue 10883032: Merge 126540 - [chromium] Fix lost context when textures are evicted (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1229/
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 867 matching lines...) Expand 10 before | Expand all | Expand 10 after
878 878
879 size_t CCThreadProxy::maxPartialTextureUpdates() const 879 size_t CCThreadProxy::maxPartialTextureUpdates() const
880 { 880 {
881 return CCTextureUpdateController::maxPartialTextureUpdates(); 881 return CCTextureUpdateController::maxPartialTextureUpdates();
882 } 882 }
883 883
884 void CCThreadProxy::recreateContextOnImplThread(CCCompletionEvent* completion, C CGraphicsContext* contextPtr, bool* recreateSucceeded, LayerRendererCapabilities * capabilities) 884 void CCThreadProxy::recreateContextOnImplThread(CCCompletionEvent* completion, C CGraphicsContext* contextPtr, bool* recreateSucceeded, LayerRendererCapabilities * capabilities)
885 { 885 {
886 TRACE_EVENT0("cc", "CCThreadProxy::recreateContextOnImplThread"); 886 TRACE_EVENT0("cc", "CCThreadProxy::recreateContextOnImplThread");
887 ASSERT(isImplThread()); 887 ASSERT(isImplThread());
888 m_layerTreeHost->deleteContentsTexturesOnImplThread(m_layerTreeHostImpl->res ourceProvider()); 888 if (!m_layerTreeHostImpl->contentsTexturesPurged())
889 m_layerTreeHost->deleteContentsTexturesOnImplThread(m_layerTreeHostImpl- >resourceProvider());
889 *recreateSucceeded = m_layerTreeHostImpl->initializeLayerRenderer(adoptPtr(c ontextPtr), textureUploader); 890 *recreateSucceeded = m_layerTreeHostImpl->initializeLayerRenderer(adoptPtr(c ontextPtr), textureUploader);
890 if (*recreateSucceeded) { 891 if (*recreateSucceeded) {
891 *capabilities = m_layerTreeHostImpl->layerRendererCapabilities(); 892 *capabilities = m_layerTreeHostImpl->layerRendererCapabilities();
892 m_schedulerOnImplThread->didRecreateContext(); 893 m_schedulerOnImplThread->didRecreateContext();
893 } 894 }
894 completion->signal(); 895 completion->signal();
895 } 896 }
896 897
897 void CCThreadProxy::implSideRenderingStatsOnImplThread(CCCompletionEvent* comple tion, CCRenderingStats* stats) 898 void CCThreadProxy::implSideRenderingStatsOnImplThread(CCCompletionEvent* comple tion, CCRenderingStats* stats)
898 { 899 {
899 ASSERT(isImplThread()); 900 ASSERT(isImplThread());
900 m_layerTreeHostImpl->renderingStats(*stats); 901 m_layerTreeHostImpl->renderingStats(*stats);
901 completion->signal(); 902 completion->signal();
902 } 903 }
903 904
904 } // namespace WebCore 905 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698