ReplacedBox.cpp 585 B

1234567891011121314151617181920212223
  1. /*
  2. * Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
  3. *
  4. * SPDX-License-Identifier: BSD-2-Clause
  5. */
  6. #include <LibWeb/DOM/Element.h>
  7. #include <LibWeb/Layout/BlockContainer.h>
  8. #include <LibWeb/Layout/InlineFormattingContext.h>
  9. #include <LibWeb/Layout/ReplacedBox.h>
  10. namespace Web::Layout {
  11. ReplacedBox::ReplacedBox(DOM::Document& document, DOM::Element& element, NonnullRefPtr<CSS::StyleProperties> style)
  12. : Box(document, &element, move(style))
  13. {
  14. // FIXME: Allow non-inline replaced elements.
  15. set_inline(true);
  16. }
  17. ReplacedBox::~ReplacedBox() = default;
  18. }