diff options
author | Andreas Kling <kling@serenityos.org> | 2020-06-02 20:27:26 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-06-02 20:32:38 +0200 |
commit | d4ddb0013cda7a8ef59e01883c643cac53448ef6 (patch) | |
tree | 752128ff443b89bb1f15c3f785396535747d4ed3 /Base/home/anon | |
parent | 1c6e4e04a8c02b27d24d65a99df3faa83762d5b9 (diff) | |
download | serenity-d4ddb0013cda7a8ef59e01883c643cac53448ef6.zip |
LibWeb: Share decoded images at the Resource level :^)
This patch adds ImageResource as a subclass of Resource. This new class
also keeps a Gfx::ImageDecoder so that we can share decoded bitmaps
between all clients of an image resource inside LibWeb.
With this, we now share both encoded and decoded data for images. :^)
I had to change how the purgeable-volatile flag is updated to keep the
volatile-images-outside-the-visible-viewport optimization working.
HTMLImageElement now inherits from ImageResourceClient (a subclass of
ResourceClient with additional image-specific stuff) and informs its
ImageResource about whether it's inside the viewport or outside.
This is pretty awesome! :^)
Diffstat (limited to 'Base/home/anon')
-rw-r--r-- | Base/home/anon/www/many-buggies.html | 9 | ||||
-rw-r--r-- | Base/home/anon/www/welcome.html | 1 |
2 files changed, 10 insertions, 0 deletions
diff --git a/Base/home/anon/www/many-buggies.html b/Base/home/anon/www/many-buggies.html new file mode 100644 index 0000000000..aa012e9595 --- /dev/null +++ b/Base/home/anon/www/many-buggies.html @@ -0,0 +1,9 @@ +<html> + <body> +<img src=http://serenityos.org/buggie.png> +<img src=http://serenityos.org/buggie.png> +<img src=http://serenityos.org/buggie.png> +<img src=http://serenityos.org/buggie.png> +<img src=http://serenityos.org/buggie.png> + </body> +</html> diff --git a/Base/home/anon/www/welcome.html b/Base/home/anon/www/welcome.html index 4a7fa634ce..46e8aa17af 100644 --- a/Base/home/anon/www/welcome.html +++ b/Base/home/anon/www/welcome.html @@ -28,6 +28,7 @@ span#ua { <p>Your user agent is: <b><span id="ua"></span></b></p> <p>Some small test pages:</p> <ul> + <li><a href="many.html">many buggies</a></li> <li><a href="palette.html">system palette color css extension</a></li> <li><a href="inline-block-link.html">link inside display: inline-block</a></li> <li><a href="set-interval.html">setInterval() test</a></li> |