| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009, 2010 Apple 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 927 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 938 FramePainter(*m_layoutView.frameView()) | 938 FramePainter(*m_layoutView.frameView()) |
| 939 .paintScrollCorner(builder.context(), interestRect); | 939 .paintScrollCorner(builder.context(), interestRect); |
| 940 } | 940 } |
| 941 | 941 |
| 942 // Replay the painted scrollbar content with the GraphicsLayer backing as the | 942 // Replay the painted scrollbar content with the GraphicsLayer backing as the |
| 943 // DisplayItemClient in order for the resulting DrawingDisplayItem to produce | 943 // DisplayItemClient in order for the resulting DrawingDisplayItem to produce |
| 944 // the correct visualRect (i.e., the bounds of the involved GraphicsLayer). | 944 // the correct visualRect (i.e., the bounds of the involved GraphicsLayer). |
| 945 DrawingRecorder drawingRecorder(context, *graphicsLayer, | 945 DrawingRecorder drawingRecorder(context, *graphicsLayer, |
| 946 DisplayItem::kScrollbarCompositedScrollbar, | 946 DisplayItem::kScrollbarCompositedScrollbar, |
| 947 layerBounds); | 947 layerBounds); |
| 948 builder.endRecording()->playback(context.canvas()); | 948 context.canvas()->drawPicture(builder.endRecording()); |
| 949 } | 949 } |
| 950 | 950 |
| 951 Scrollbar* PaintLayerCompositor::graphicsLayerToScrollbar( | 951 Scrollbar* PaintLayerCompositor::graphicsLayerToScrollbar( |
| 952 const GraphicsLayer* graphicsLayer) const { | 952 const GraphicsLayer* graphicsLayer) const { |
| 953 if (graphicsLayer == layerForHorizontalScrollbar()) { | 953 if (graphicsLayer == layerForHorizontalScrollbar()) { |
| 954 return m_layoutView.frameView()->horizontalScrollbar(); | 954 return m_layoutView.frameView()->horizontalScrollbar(); |
| 955 } | 955 } |
| 956 if (graphicsLayer == layerForVerticalScrollbar()) { | 956 if (graphicsLayer == layerForVerticalScrollbar()) { |
| 957 return m_layoutView.frameView()->verticalScrollbar(); | 957 return m_layoutView.frameView()->verticalScrollbar(); |
| 958 } | 958 } |
| (...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1356 } else if (graphicsLayer == m_scrollLayer.get()) { | 1356 } else if (graphicsLayer == m_scrollLayer.get()) { |
| 1357 name = "Frame Scrolling Layer"; | 1357 name = "Frame Scrolling Layer"; |
| 1358 } else { | 1358 } else { |
| 1359 ASSERT_NOT_REACHED(); | 1359 ASSERT_NOT_REACHED(); |
| 1360 } | 1360 } |
| 1361 | 1361 |
| 1362 return name; | 1362 return name; |
| 1363 } | 1363 } |
| 1364 | 1364 |
| 1365 } // namespace blink | 1365 } // namespace blink |
| OLD | NEW |