Commit 2505d49b authored by Morten Stenshorne's avatar Morten Stenshorne Committed by Commit Bot

Use LayoutObjectFactory in ImageInputType.

Change-Id: I46e6c87cbb74cd94e219d16be7c39dbc2e2b4c30
Reviewed-on: https://chromium-review.googlesource.com/1118175
Commit-Queue: Emil A Eklund <eae@chromium.org>
Reviewed-by: default avatarEmil A Eklund <eae@chromium.org>
Cr-Commit-Position: refs/heads/master@{#571652}
parent 36c9bc71
......@@ -36,6 +36,7 @@
#include "third_party/blink/renderer/core/layout/adjust_for_absolute_zoom.h"
#include "third_party/blink/renderer/core/layout/layout_block_flow.h"
#include "third_party/blink/renderer/core/layout/layout_image.h"
#include "third_party/blink/renderer/core/layout/layout_object_factory.h"
#include "third_party/blink/renderer/platform/wtf/text/string_builder.h"
namespace blink {
......@@ -106,7 +107,7 @@ void ImageInputType::HandleDOMActivateEvent(Event* event) {
LayoutObject* ImageInputType::CreateLayoutObject(
const ComputedStyle& style) const {
if (use_fallback_content_)
return new LayoutBlockFlow(&GetElement());
return LayoutObjectFactory::CreateBlockFlow(GetElement(), style);
LayoutImage* image = new LayoutImage(&GetElement());
image->SetImageResource(LayoutImageResource::Create());
return image;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment