mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-27 11:48:32 +00:00
LibHTML: Support rendering <img src> with file:// URLs
We can now show images loaded from local file:// URLs. Pretty neat :^)
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
#pragma once
|
||||
|
||||
#include <LibDraw/GraphicsBitmap.h>
|
||||
#include <LibHTML/DOM/HTMLElement.h>
|
||||
|
||||
class HTMLImageElement : public HTMLElement {
|
||||
@@ -10,6 +11,10 @@ public:
|
||||
String alt() const { return attribute("alt"); }
|
||||
String src() const { return attribute("src"); }
|
||||
|
||||
const GraphicsBitmap* bitmap() const;
|
||||
|
||||
private:
|
||||
virtual RefPtr<LayoutNode> create_layout_node(const StyleResolver&, const StyleProperties* parent_style) const override;
|
||||
|
||||
mutable RefPtr<GraphicsBitmap> m_bitmap;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user