| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 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 are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 105 | 105 |
| 106 WebElement WebDocument::createElement(const WebString& tagName) | 106 WebElement WebDocument::createElement(const WebString& tagName) |
| 107 { | 107 { |
| 108 TrackExceptionState exceptionState; | 108 TrackExceptionState exceptionState; |
| 109 WebElement element(unwrap<Document>()->createElement(tagName, exceptionState
)); | 109 WebElement element(unwrap<Document>()->createElement(tagName, exceptionState
)); |
| 110 if (exceptionState.had_exception()) | 110 if (exceptionState.had_exception()) |
| 111 return WebElement(); | 111 return WebElement(); |
| 112 return element; | 112 return element; |
| 113 } | 113 } |
| 114 | 114 |
| 115 void WebDocument::pauseAnimationsForTesting(double pauseTime) const { | |
| 116 constUnwrap<Document>()->frame()->view()->updateLayoutAndStyleForPainting(); | |
| 117 constUnwrap<Document>()->timeline().pauseAnimationsForTesting(pauseTime); | |
| 118 } | |
| 119 | |
| 120 WebDocument::WebDocument(const PassRefPtr<Document>& elem) | 115 WebDocument::WebDocument(const PassRefPtr<Document>& elem) |
| 121 : WebNode(elem) | 116 : WebNode(elem) |
| 122 { | 117 { |
| 123 } | 118 } |
| 124 | 119 |
| 125 WebDocument& WebDocument::operator=(const PassRefPtr<Document>& elem) | 120 WebDocument& WebDocument::operator=(const PassRefPtr<Document>& elem) |
| 126 { | 121 { |
| 127 m_private = elem; | 122 m_private = elem; |
| 128 return *this; | 123 return *this; |
| 129 } | 124 } |
| 130 | 125 |
| 131 WebDocument::operator PassRefPtr<Document>() const | 126 WebDocument::operator PassRefPtr<Document>() const |
| 132 { | 127 { |
| 133 return toDocument(m_private.get()); | 128 return toDocument(m_private.get()); |
| 134 } | 129 } |
| 135 | 130 |
| 136 } // namespace blink | 131 } // namespace blink |
| OLD | NEW |