mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-11 20:16:02 +00:00
Everywhere: Pass backing store into Navigable::paint()
...instead of Gfx::Bitmap, which makes it possible to access and directly paint into IOSurface on macOS.
This commit is contained in:
parent
c4e935aa97
commit
c62cc915df
Notes:
sideshowbarker
2024-07-17 02:56:25 +09:00
Author: https://github.com/kalenikaliaksandr
Commit: c62cc915df
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/294
18 changed files with 145 additions and 30 deletions
|
@ -1174,8 +1174,10 @@ JS::GCPtr<DOM::Node> TraversableNavigable::currently_focused_area()
|
|||
return candidate;
|
||||
}
|
||||
|
||||
void TraversableNavigable::paint(Web::DevicePixelRect const& content_rect, Gfx::Bitmap& target, Web::PaintOptions paint_options)
|
||||
void TraversableNavigable::paint(Web::DevicePixelRect const& content_rect, Painting::BackingStore& backing_store, Web::PaintOptions paint_options)
|
||||
{
|
||||
auto& target = backing_store.bitmap();
|
||||
|
||||
Painting::DisplayList display_list;
|
||||
Painting::DisplayListRecorder display_list_recorder(display_list);
|
||||
|
||||
|
|
|
@ -12,6 +12,7 @@
|
|||
#include <LibWeb/HTML/SessionHistoryTraversalQueue.h>
|
||||
#include <LibWeb/HTML/VisibilityState.h>
|
||||
#include <LibWeb/Page/Page.h>
|
||||
#include <WebContent/BackingStoreManager.h>
|
||||
|
||||
namespace Web::HTML {
|
||||
|
||||
|
@ -85,7 +86,7 @@ public:
|
|||
|
||||
[[nodiscard]] JS::GCPtr<DOM::Node> currently_focused_area();
|
||||
|
||||
void paint(Web::DevicePixelRect const&, Gfx::Bitmap&, Web::PaintOptions);
|
||||
void paint(Web::DevicePixelRect const&, Painting::BackingStore&, Web::PaintOptions);
|
||||
|
||||
private:
|
||||
TraversableNavigable(JS::NonnullGCPtr<Page>);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue