mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 17:12:43 +00:00 
			
		
		
		
	LibDraw: Rename ImageLoader => ImageDecoder
ImageLoader was not the right name for this, as there is no loading happening, only decoding. :^)
This commit is contained in:
		
							parent
							
								
									02e787f8a4
								
							
						
					
					
						commit
						f970578cd4
					
				
					 8 changed files with 32 additions and 32 deletions
				
			
		|  | @ -34,7 +34,7 @@ void HTMLImageElement::load_image(const String& src) | |||
|         } | ||||
| 
 | ||||
|         m_image_data = data; | ||||
|         m_image_loader = ImageLoader::create(m_image_data.data(), m_image_data.size()); | ||||
|         m_image_loader = ImageDecoder::create(m_image_data.data(), m_image_data.size()); | ||||
|         document().update_layout(); | ||||
|     }); | ||||
| } | ||||
|  |  | |||
|  | @ -1,7 +1,7 @@ | |||
| #pragma once | ||||
| 
 | ||||
| #include <LibDraw/GraphicsBitmap.h> | ||||
| #include <LibDraw/ImageLoader.h> | ||||
| #include <LibDraw/ImageDecoder.h> | ||||
| #include <LibHTML/DOM/HTMLElement.h> | ||||
| 
 | ||||
| class HTMLImageElement : public HTMLElement { | ||||
|  | @ -17,14 +17,14 @@ public: | |||
|     int preferred_height() const; | ||||
| 
 | ||||
|     const GraphicsBitmap* bitmap() const; | ||||
|     const ImageLoader* image_loader() const { return m_image_loader; } | ||||
|     const ImageDecoder* image_loader() const { return m_image_loader; } | ||||
| 
 | ||||
| private: | ||||
|     void load_image(const String& src); | ||||
| 
 | ||||
|     virtual RefPtr<LayoutNode> create_layout_node(const StyleProperties* parent_style) const override; | ||||
| 
 | ||||
|     RefPtr<ImageLoader> m_image_loader; | ||||
|     RefPtr<ImageDecoder> m_image_loader; | ||||
|     mutable RefPtr<GraphicsBitmap> m_bitmap; | ||||
|     ByteBuffer m_image_data; | ||||
| }; | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Andreas Kling
						Andreas Kling