| OLD | NEW |
| 1 /* | 1 /* |
| 2 * This file is part of the WebKit project. | 2 * This file is part of the WebKit project. |
| 3 * | 3 * |
| 4 * Copyright (C) 2006 Apple Computer, Inc. | 4 * Copyright (C) 2006 Apple Computer, Inc. |
| 5 * Copyright (C) 2008, 2009 Google, Inc. | 5 * Copyright (C) 2008, 2009 Google, Inc. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 } | 63 } |
| 64 | 64 |
| 65 class ThemePainter : public TransparencyWin { | 65 class ThemePainter : public TransparencyWin { |
| 66 public: | 66 public: |
| 67 ThemePainter(GraphicsContext* context, const IntRect& r) | 67 ThemePainter(GraphicsContext* context, const IntRect& r) |
| 68 { | 68 { |
| 69 TransformMode transformMode = getTransformMode(context->getCTM()); | 69 TransformMode transformMode = getTransformMode(context->getCTM()); |
| 70 init(context, getLayerMode(context, transformMode), transformMode, r); | 70 init(context, getLayerMode(context, transformMode), transformMode, r); |
| 71 } | 71 } |
| 72 | 72 |
| 73 ~ThemePainter() |
| 74 { |
| 75 composite(); |
| 76 } |
| 77 |
| 73 private: | 78 private: |
| 74 static LayerMode getLayerMode(GraphicsContext* context, TransformMode transf
ormMode) | 79 static LayerMode getLayerMode(GraphicsContext* context, TransformMode transf
ormMode) |
| 75 { | 80 { |
| 76 if (context->platformContext()->isDrawingToImageBuffer()) // Might have
transparent background. | 81 if (context->platformContext()->isDrawingToImageBuffer()) // Might have
transparent background. |
| 77 return WhiteLayer; | 82 return WhiteLayer; |
| 78 else if (canvasHasMultipleLayers(context->platformContext()->canvas()))
// Needs antialiasing help. | 83 else if (canvasHasMultipleLayers(context->platformContext()->canvas()))
// Needs antialiasing help. |
| 79 return OpaqueCompositeLayer; | 84 return OpaqueCompositeLayer; |
| 80 else // Nothing interesting. | 85 else // Nothing interesting. |
| 81 return transformMode == KeepTransform ? NoLayer : OpaqueCompositeLay
er; | 86 return transformMode == KeepTransform ? NoLayer : OpaqueCompositeLay
er; |
| 82 } | 87 } |
| (...skipping 581 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 664 // static | 669 // static |
| 665 void RenderThemeChromiumWin::setFindInPageMode(bool enable) { | 670 void RenderThemeChromiumWin::setFindInPageMode(bool enable) { |
| 666 if (m_findInPageMode == enable) | 671 if (m_findInPageMode == enable) |
| 667 return; | 672 return; |
| 668 | 673 |
| 669 m_findInPageMode = enable; | 674 m_findInPageMode = enable; |
| 670 theme()->platformColorsDidChange(); | 675 theme()->platformColorsDidChange(); |
| 671 } | 676 } |
| 672 | 677 |
| 673 } // namespace WebCore | 678 } // namespace WebCore |
| OLD | NEW |