OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "config.h" | 5 #include "config.h" |
6 | 6 |
7 #include "CCLayerTreeHost.h" | 7 #include "CCLayerTreeHost.h" |
8 | 8 |
9 #include "CCFontAtlas.h" | 9 #include "CCFontAtlas.h" |
10 #include "CCGraphicsContext.h" | 10 #include "CCGraphicsContext.h" |
(...skipping 376 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
387 } | 387 } |
388 | 388 |
389 void CCLayerTreeHost::setVisible(bool visible) | 389 void CCLayerTreeHost::setVisible(bool visible) |
390 { | 390 { |
391 if (m_visible == visible) | 391 if (m_visible == visible) |
392 return; | 392 return; |
393 m_visible = visible; | 393 m_visible = visible; |
394 m_proxy->setVisible(visible); | 394 m_proxy->setVisible(visible); |
395 } | 395 } |
396 | 396 |
397 void CCLayerTreeHost::evictAllContentTextures() | 397 void CCLayerTreeHost::unlinkAllContentTextures() |
398 { | 398 { |
399 ASSERT(CCProxy::isMainThread()); | 399 ASSERT(CCProxy::isMainThread()); |
400 ASSERT(m_contentsTextureManager.get()); | 400 ASSERT(m_contentsTextureManager.get()); |
401 m_contentsTextureManager->allBackingTexturesWereDeleted(); | 401 m_contentsTextureManager->unlinkAllBackings(); |
| 402 } |
| 403 |
| 404 void CCLayerTreeHost::deleteUnlinkedTextures() |
| 405 { |
| 406 ASSERT(CCProxy::isImplThread() && CCProxy::isMainThreadBlocked()); |
| 407 ASSERT(m_contentsTextureManager.get()); |
| 408 m_contentsTextureManager->deleteAllUnlinkedBackings(); |
402 } | 409 } |
403 | 410 |
404 void CCLayerTreeHost::startPageScaleAnimation(const IntSize& targetPosition, boo
l useAnchor, float scale, double durationSec) | 411 void CCLayerTreeHost::startPageScaleAnimation(const IntSize& targetPosition, boo
l useAnchor, float scale, double durationSec) |
405 { | 412 { |
406 m_proxy->startPageScaleAnimation(targetPosition, useAnchor, scale, durationS
ec); | 413 m_proxy->startPageScaleAnimation(targetPosition, useAnchor, scale, durationS
ec); |
407 } | 414 } |
408 | 415 |
409 void CCLayerTreeHost::loseContext(int numTimes) | 416 void CCLayerTreeHost::loseContext(int numTimes) |
410 { | 417 { |
411 TRACE_EVENT1("cc", "CCLayerTreeHost::loseCompositorContext", "numTimes", num
Times); | 418 TRACE_EVENT1("cc", "CCLayerTreeHost::loseCompositorContext", "numTimes", num
Times); |
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
772 else | 779 else |
773 layer->notifyAnimationFinished(wallClockTime); | 780 layer->notifyAnimationFinished(wallClockTime); |
774 } | 781 } |
775 } | 782 } |
776 | 783 |
777 for (size_t childIndex = 0; childIndex < layer->children().size(); ++childIn
dex) | 784 for (size_t childIndex = 0; childIndex < layer->children().size(); ++childIn
dex) |
778 setAnimationEventsRecursive(events, layer->children()[childIndex].get(),
wallClockTime); | 785 setAnimationEventsRecursive(events, layer->children()[childIndex].get(),
wallClockTime); |
779 } | 786 } |
780 | 787 |
781 } // namespace WebCore | 788 } // namespace WebCore |
OLD | NEW |