mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 01:32:45 +00:00 
			
		
		
		
	 268b9c5d90
			
		
	
	
		268b9c5d90
		
	
	
	
	
		
			
			This removes a set of complex reference cycles between DOM, layout tree and browsing context. It also makes lifetimes much easier to reason about, as the DOM and layout trees are now free to keep each other alive.
		
			
				
	
	
		
			27 lines
		
	
	
	
		
			787 B
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			27 lines
		
	
	
	
		
			787 B
		
	
	
	
		
			C++
		
	
	
	
	
	
| /*
 | |
|  * Copyright (c) 2022, the SerenityOS developers.
 | |
|  *
 | |
|  * SPDX-License-Identifier: BSD-2-Clause
 | |
|  */
 | |
| 
 | |
| #pragma once
 | |
| 
 | |
| #include <LibWeb/HTML/HTMLProgressElement.h>
 | |
| #include <LibWeb/Layout/LabelableNode.h>
 | |
| 
 | |
| namespace Web::Layout {
 | |
| 
 | |
| class Progress : public LabelableNode {
 | |
|     JS_CELL(Progress, LabelableNode);
 | |
| 
 | |
| public:
 | |
|     Progress(DOM::Document&, HTML::HTMLProgressElement&, NonnullRefPtr<CSS::StyleProperties>);
 | |
|     virtual ~Progress() override;
 | |
| 
 | |
|     const HTML::HTMLProgressElement& dom_node() const { return static_cast<const HTML::HTMLProgressElement&>(LabelableNode::dom_node()); }
 | |
|     HTML::HTMLProgressElement& dom_node() { return static_cast<HTML::HTMLProgressElement&>(LabelableNode::dom_node()); }
 | |
| 
 | |
|     virtual RefPtr<Painting::Paintable> create_paintable() const override;
 | |
| };
 | |
| 
 | |
| }
 |