mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 02:52:43 +00:00 
			
		
		
		
	 bcebca62d3
			
		
	
	
		bcebca62d3
		
	
	
	
	
		
			
			Also remove the unused StyleValue::to_rect() because an EdgeRect is only ever held by a RectStyleValue.
		
			
				
	
	
		
			28 lines
		
	
	
	
		
			484 B
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			28 lines
		
	
	
	
		
			484 B
		
	
	
	
		
			C++
		
	
	
	
	
	
| /*
 | |
|  * Copyright (c) 2022, the SerenityOS developers.
 | |
|  *
 | |
|  * SPDX-License-Identifier: BSD-2-Clause
 | |
|  */
 | |
| 
 | |
| #include "Clip.h"
 | |
| 
 | |
| namespace Web::CSS {
 | |
| 
 | |
| Clip::Clip(Type type, EdgeRect edge_rect)
 | |
|     : m_type(type)
 | |
|     , m_edge_rect(edge_rect)
 | |
| {
 | |
| }
 | |
| 
 | |
| Clip::Clip(EdgeRect edge_rect)
 | |
|     : m_type(Type::Rect)
 | |
|     , m_edge_rect(edge_rect)
 | |
| {
 | |
| }
 | |
| 
 | |
| Clip Clip::make_auto()
 | |
| {
 | |
|     return Clip(Type::Auto, EdgeRect { Length::make_auto(), Length::make_auto(), Length::make_auto(), Length::make_auto() });
 | |
| }
 | |
| 
 | |
| }
 |