| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2014 Opera Software ASA. All rights reserved. | 3 * Copyright (C) 2014 Opera Software ASA. 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 are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * 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 399 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 410 } | 410 } |
| 411 | 411 |
| 412 void WebPluginContainerImpl::scrollRect(const WebRect& rect) | 412 void WebPluginContainerImpl::scrollRect(const WebRect& rect) |
| 413 { | 413 { |
| 414 invalidateRect(rect); | 414 invalidateRect(rect); |
| 415 } | 415 } |
| 416 | 416 |
| 417 void WebPluginContainerImpl::reportGeometry() | 417 void WebPluginContainerImpl::reportGeometry() |
| 418 { | 418 { |
| 419 // We cannot compute geometry without a parent or layoutObject. | 419 // We cannot compute geometry without a parent or layoutObject. |
| 420 if (!parent() || !m_element->layoutObject()) | 420 if (!parent() || !m_element || !m_element->layoutObject()) |
| 421 return; | 421 return; |
| 422 | 422 |
| 423 IntRect windowRect, clipRect, unobscuredRect; | 423 IntRect windowRect, clipRect, unobscuredRect; |
| 424 Vector<IntRect> cutOutRects; | 424 Vector<IntRect> cutOutRects; |
| 425 calculateGeometry(windowRect, clipRect, unobscuredRect, cutOutRects); | 425 calculateGeometry(windowRect, clipRect, unobscuredRect, cutOutRects); |
| 426 | 426 |
| 427 m_webPlugin->updateGeometry(windowRect, clipRect, unobscuredRect, cutOutRect
s, isVisible()); | 427 m_webPlugin->updateGeometry(windowRect, clipRect, unobscuredRect, cutOutRect
s, isVisible()); |
| 428 | 428 |
| 429 if (m_scrollbarGroup) { | 429 if (m_scrollbarGroup) { |
| 430 m_scrollbarGroup->scrollAnimator()->contentsResized(); | 430 m_scrollbarGroup->scrollAnimator()->contentsResized(); |
| (...skipping 583 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1014 for (size_t i = 0; i < cutOutRects.size(); i++) | 1014 for (size_t i = 0; i < cutOutRects.size(); i++) |
| 1015 cutOutRects[i].move(-frameRect().x(), -frameRect().y()); | 1015 cutOutRects[i].move(-frameRect().x(), -frameRect().y()); |
| 1016 } | 1016 } |
| 1017 | 1017 |
| 1018 bool WebPluginContainerImpl::pluginShouldPersist() const | 1018 bool WebPluginContainerImpl::pluginShouldPersist() const |
| 1019 { | 1019 { |
| 1020 return m_webPlugin->shouldPersist(); | 1020 return m_webPlugin->shouldPersist(); |
| 1021 } | 1021 } |
| 1022 | 1022 |
| 1023 } // namespace blink | 1023 } // namespace blink |
| OLD | NEW |