OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
3 * Copyright (C) 2013 Apple Inc. All rights reserved. | 3 * Copyright (C) 2013 Apple Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * | 8 * |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 1704 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1715 return nullptr; | 1715 return nullptr; |
1716 } | 1716 } |
1717 | 1717 |
1718 Page* page = document->page(); | 1718 Page* page = document->page(); |
1719 if (!page) | 1719 if (!page) |
1720 return nullptr; | 1720 return nullptr; |
1721 | 1721 |
1722 return page->nonFastScrollableRects(document->frame()); | 1722 return page->nonFastScrollableRects(document->frame()); |
1723 } | 1723 } |
1724 | 1724 |
1725 void Internals::garbageCollectDocumentResources(Document* document) const | |
1726 { | |
1727 ASSERT(document); | |
1728 ResourceFetcher* fetcher = document->fetcher(); | |
1729 if (!fetcher) | |
1730 return; | |
1731 fetcher->garbageCollectDocumentResources(); | |
1732 } | |
1733 | |
1734 void Internals::evictAllResources() const | 1725 void Internals::evictAllResources() const |
1735 { | 1726 { |
1736 memoryCache()->evictResources(); | 1727 memoryCache()->evictResources(); |
1737 } | 1728 } |
1738 | 1729 |
1739 String Internals::counterValue(Element* element) | 1730 String Internals::counterValue(Element* element) |
1740 { | 1731 { |
1741 if (!element) | 1732 if (!element) |
1742 return String(); | 1733 return String(); |
1743 | 1734 |
(...skipping 800 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2544 mediaElement->setNetworkState(static_cast<WebMediaPlayer::NetworkState>(stat
e)); | 2535 mediaElement->setNetworkState(static_cast<WebMediaPlayer::NetworkState>(stat
e)); |
2545 } | 2536 } |
2546 | 2537 |
2547 // TODO(liberato): remove once autoplay gesture override experiment concludes. | 2538 // TODO(liberato): remove once autoplay gesture override experiment concludes. |
2548 void Internals::triggerAutoplayViewportCheck(HTMLMediaElement* element) | 2539 void Internals::triggerAutoplayViewportCheck(HTMLMediaElement* element) |
2549 { | 2540 { |
2550 element->triggerAutoplayViewportCheckForTesting(); | 2541 element->triggerAutoplayViewportCheckForTesting(); |
2551 } | 2542 } |
2552 | 2543 |
2553 } // namespace blink | 2544 } // namespace blink |
OLD | NEW |