OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2010 Apple Inc. All rights reserv
ed. | 4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2010 Apple Inc. All rights reserv
ed. |
5 * Copyright (C) 2010 Google Inc. All rights reserved. | 5 * Copyright (C) 2010 Google Inc. All rights reserved. |
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 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
173 // also heavily discussed by Hixie on bugzilla | 173 // also heavily discussed by Hixie on bugzilla |
174 String alt = getAttribute(altAttr); | 174 String alt = getAttribute(altAttr); |
175 // fall back to title attribute | 175 // fall back to title attribute |
176 if (alt.isNull()) | 176 if (alt.isNull()) |
177 alt = getAttribute(titleAttr); | 177 alt = getAttribute(titleAttr); |
178 return alt; | 178 return alt; |
179 } | 179 } |
180 | 180 |
181 RenderObject* HTMLImageElement::createRenderer(RenderArena* arena, RenderStyle*
style) | 181 RenderObject* HTMLImageElement::createRenderer(RenderArena* arena, RenderStyle*
style) |
182 { | 182 { |
183 if (style->contentData()) | 183 if (style->contentData()) |
184 return RenderObject::createObject(this, style); | 184 return RenderObject::createObject(this, style); |
185 | 185 |
186 RenderImage* image = new (arena) RenderImage(this); | 186 RenderImage* image = new (arena) RenderImage(this); |
187 image->setImageResource(RenderImageResource::create()); | 187 image->setImageResource(RenderImageResource::create()); |
188 return image; | 188 return image; |
189 } | 189 } |
190 | 190 |
191 void HTMLImageElement::attach() | 191 void HTMLImageElement::attach() |
192 { | 192 { |
193 HTMLElement::attach(); | 193 HTMLElement::attach(); |
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
394 addSubresourceURL(urls, document()->completeURL(getAttribute(usemapAttr))); | 394 addSubresourceURL(urls, document()->completeURL(getAttribute(usemapAttr))); |
395 } | 395 } |
396 | 396 |
397 void HTMLImageElement::willMoveToNewOwnerDocument() | 397 void HTMLImageElement::willMoveToNewOwnerDocument() |
398 { | 398 { |
399 m_imageLoader.elementWillMoveToNewOwnerDocument(); | 399 m_imageLoader.elementWillMoveToNewOwnerDocument(); |
400 HTMLElement::willMoveToNewOwnerDocument(); | 400 HTMLElement::willMoveToNewOwnerDocument(); |
401 } | 401 } |
402 | 402 |
403 } | 403 } |
OLD | NEW |