| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008, 2009, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008, 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 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 contentRect.moveBy(paintOffset); | 182 contentRect.moveBy(paintOffset); |
| 183 GraphicsContext* context = paintInfo.context; | 183 GraphicsContext* context = paintInfo.context; |
| 184 bool clip = !contentRect.contains(rect); | 184 bool clip = !contentRect.contains(rect); |
| 185 if (clip) { | 185 if (clip) { |
| 186 context->save(); | 186 context->save(); |
| 187 context->clip(contentRect); | 187 context->clip(contentRect); |
| 188 } | 188 } |
| 189 | 189 |
| 190 if (displayingPoster) | 190 if (displayingPoster) |
| 191 paintIntoRect(context, rect); | 191 paintIntoRect(context, rect); |
| 192 else if (document()->view() && document()->view()->paintBehavior() & PaintBe
haviorFlattenCompositingLayers) | 192 else if (document().view() && document().view()->paintBehavior() & PaintBeha
viorFlattenCompositingLayers) |
| 193 mediaPlayer->paintCurrentFrameInContext(context, pixelSnappedIntRect(rec
t)); | 193 mediaPlayer->paintCurrentFrameInContext(context, pixelSnappedIntRect(rec
t)); |
| 194 else | 194 else |
| 195 mediaPlayer->paint(context, pixelSnappedIntRect(rect)); | 195 mediaPlayer->paint(context, pixelSnappedIntRect(rect)); |
| 196 | 196 |
| 197 if (clip) | 197 if (clip) |
| 198 context->restore(); | 198 context->restore(); |
| 199 } | 199 } |
| 200 | 200 |
| 201 void RenderVideo::layout() | 201 void RenderVideo::layout() |
| 202 { | 202 { |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 289 } | 289 } |
| 290 | 290 |
| 291 LayoutUnit RenderVideo::offsetHeight() const | 291 LayoutUnit RenderVideo::offsetHeight() const |
| 292 { | 292 { |
| 293 if (const RenderBlock* block = rendererPlaceholder(this)) | 293 if (const RenderBlock* block = rendererPlaceholder(this)) |
| 294 return block->offsetHeight(); | 294 return block->offsetHeight(); |
| 295 return RenderMedia::offsetHeight(); | 295 return RenderMedia::offsetHeight(); |
| 296 } | 296 } |
| 297 | 297 |
| 298 } // namespace WebCore | 298 } // namespace WebCore |
| OLD | NEW |