Wrappable.cpp 376 B

123456789101112131415161718192021222324
  1. /*
  2. * Copyright (c) 2020, Andreas Kling <kling@serenityos.org>
  3. *
  4. * SPDX-License-Identifier: BSD-2-Clause
  5. */
  6. #include <LibWeb/Bindings/Wrappable.h>
  7. #include <LibWeb/Bindings/Wrapper.h>
  8. namespace Web {
  9. namespace Bindings {
  10. Wrappable::~Wrappable()
  11. {
  12. }
  13. void Wrappable::set_wrapper(Wrapper& wrapper)
  14. {
  15. VERIFY(!m_wrapper);
  16. m_wrapper = wrapper.make_weak_ptr();
  17. }
  18. }
  19. }