| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 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 17 matching lines...) Expand all Loading... |
| 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 29 */ | 29 */ |
| 30 | 30 |
| 31 #include "config.h" | 31 #include "config.h" |
| 32 #include "WebViewImpl.h" | 32 #include "WebViewImpl.h" |
| 33 | 33 |
| 34 #include "AutoFillPopupMenuClient.h" | 34 #include "AutoFillPopupMenuClient.h" |
| 35 #include "AXObjectCache.h" | 35 #include "AXObjectCache.h" |
| 36 #include "BackForwardListImpl.h" | 36 #include "BackForwardListImpl.h" |
| 37 #include "Chrome.h" | 37 #include "Chrome.h" |
| 38 #include "ChromiumBridge.h" |
| 38 #include "ColorSpace.h" | 39 #include "ColorSpace.h" |
| 39 #include "CompositionUnderlineVectorBuilder.h" | 40 #include "CompositionUnderlineVectorBuilder.h" |
| 40 #include "ContextMenu.h" | 41 #include "ContextMenu.h" |
| 41 #include "ContextMenuController.h" | 42 #include "ContextMenuController.h" |
| 42 #include "ContextMenuItem.h" | 43 #include "ContextMenuItem.h" |
| 43 #include "CSSStyleSelector.h" | 44 #include "CSSStyleSelector.h" |
| 44 #include "CSSValueKeywords.h" | 45 #include "CSSValueKeywords.h" |
| 45 #include "Cursor.h" | 46 #include "Cursor.h" |
| 46 #include "DeviceOrientationClientProxy.h" | 47 #include "DeviceOrientationClientProxy.h" |
| 47 #include "Document.h" | 48 #include "Document.h" |
| (...skipping 2319 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2367 | 2368 |
| 2368 // FIXME: add a smarter damage aggregation logic and/or unify with | 2369 // FIXME: add a smarter damage aggregation logic and/or unify with |
| 2369 // LayerChromium's damage logic | 2370 // LayerChromium's damage logic |
| 2370 m_rootLayerDirtyRect.unite(rect); | 2371 m_rootLayerDirtyRect.unite(rect); |
| 2371 setRootLayerNeedsDisplay(); | 2372 setRootLayerNeedsDisplay(); |
| 2372 } | 2373 } |
| 2373 | 2374 |
| 2374 | 2375 |
| 2375 void WebViewImpl::setIsAcceleratedCompositingActive(bool active) | 2376 void WebViewImpl::setIsAcceleratedCompositingActive(bool active) |
| 2376 { | 2377 { |
| 2378 ChromiumBridge::histogramEnumeration("GPU.setIsAcceleratedCompositingActive"
, active * 2 + m_isAcceleratedCompositingActive, 4); |
| 2379 |
| 2377 if (m_isAcceleratedCompositingActive == active) | 2380 if (m_isAcceleratedCompositingActive == active) |
| 2378 return; | 2381 return; |
| 2379 | 2382 |
| 2380 if (!active) { | 2383 if (!active) { |
| 2381 m_isAcceleratedCompositingActive = false; | 2384 m_isAcceleratedCompositingActive = false; |
| 2382 if (m_layerRenderer) | 2385 if (m_layerRenderer) |
| 2383 m_layerRenderer->finish(); // finish all GL rendering before we hide
the window? | 2386 m_layerRenderer->finish(); // finish all GL rendering before we hide
the window? |
| 2384 m_client->didActivateAcceleratedCompositing(false); | 2387 m_client->didActivateAcceleratedCompositing(false); |
| 2385 return; | 2388 return; |
| 2386 } | 2389 } |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2537 m_temporaryOnscreenGraphicsContext3D->reshape(std::max(1, m_size
.width), std::max(1, m_size.height)); | 2540 m_temporaryOnscreenGraphicsContext3D->reshape(std::max(1, m_size
.width), std::max(1, m_size.height)); |
| 2538 context = m_temporaryOnscreenGraphicsContext3D.get(); | 2541 context = m_temporaryOnscreenGraphicsContext3D.get(); |
| 2539 } | 2542 } |
| 2540 return GraphicsContext3DInternal::extractWebGraphicsContext3D(context); | 2543 return GraphicsContext3DInternal::extractWebGraphicsContext3D(context); |
| 2541 } | 2544 } |
| 2542 #endif | 2545 #endif |
| 2543 return 0; | 2546 return 0; |
| 2544 } | 2547 } |
| 2545 | 2548 |
| 2546 } // namespace WebKit | 2549 } // namespace WebKit |
| OLD | NEW |