mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 04:09:13 +00:00
LibWeb+WebContent: Delete unused "has focus" flag from paint config
This commit is contained in:
parent
418409aa6f
commit
b73525ba0e
Notes:
github-actions[bot]
2025-07-04 14:14:20 +00:00
Author: https://github.com/kalenikaliaksandr
Commit: b73525ba0e
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5259
Reviewed-by: https://github.com/gmta ✅
7 changed files with 0 additions and 11 deletions
|
@ -6494,7 +6494,6 @@ RefPtr<Painting::DisplayList> Document::record_display_list(PaintConfig config)
|
|||
context.set_device_viewport_rect(viewport_rect);
|
||||
context.set_should_show_line_box_borders(config.should_show_line_box_borders);
|
||||
context.set_should_paint_overlay(config.paint_overlay);
|
||||
context.set_has_focus(config.has_focus);
|
||||
|
||||
update_paint_and_hit_testing_properties_if_needed();
|
||||
|
||||
|
|
|
@ -835,7 +835,6 @@ public:
|
|||
struct PaintConfig {
|
||||
bool paint_overlay { false };
|
||||
bool should_show_line_box_borders { false };
|
||||
bool has_focus { false };
|
||||
Optional<Gfx::IntRect> canvas_fill_rect {};
|
||||
|
||||
bool operator==(PaintConfig const& other) const = default;
|
||||
|
|
|
@ -1444,7 +1444,6 @@ RefPtr<Painting::DisplayList> TraversableNavigable::record_display_list(DevicePi
|
|||
DOM::Document::PaintConfig paint_config;
|
||||
paint_config.paint_overlay = paint_options.paint_overlay == PaintOptions::PaintOverlay::Yes;
|
||||
paint_config.should_show_line_box_borders = paint_options.should_show_line_box_borders;
|
||||
paint_config.has_focus = paint_options.has_focus;
|
||||
paint_config.canvas_fill_rect = Gfx::IntRect { {}, content_rect.size() };
|
||||
return document->record_display_list(paint_config);
|
||||
}
|
||||
|
|
|
@ -309,7 +309,6 @@ struct PaintOptions {
|
|||
|
||||
PaintOverlay paint_overlay { PaintOverlay::Yes };
|
||||
bool should_show_line_box_borders { false };
|
||||
bool has_focus { false };
|
||||
};
|
||||
|
||||
enum class DisplayListPlayerType {
|
||||
|
|
|
@ -58,7 +58,6 @@ void NavigableContainerViewportPaintable::paint(PaintContext& context, PaintPhas
|
|||
DOM::Document::PaintConfig paint_config;
|
||||
paint_config.paint_overlay = context.should_paint_overlay();
|
||||
paint_config.should_show_line_box_borders = context.should_show_line_box_borders();
|
||||
paint_config.has_focus = context.has_focus();
|
||||
auto display_list = const_cast<DOM::Document*>(hosted_document)->record_display_list(paint_config);
|
||||
auto scroll_state_snapshot = hosted_document->paintable()->scroll_state().snapshot();
|
||||
context.display_list_recorder().paint_nested_display_list(display_list, move(scroll_state_snapshot), context.enclosing_device_rect(absolute_rect).to_type<int>());
|
||||
|
|
|
@ -32,9 +32,6 @@ public:
|
|||
void set_device_viewport_rect(DevicePixelRect const& rect) { m_device_viewport_rect = rect; }
|
||||
CSSPixelRect css_viewport_rect() const;
|
||||
|
||||
bool has_focus() const { return m_focus; }
|
||||
void set_has_focus(bool focus) { m_focus = focus; }
|
||||
|
||||
void set_svg_transform(Gfx::AffineTransform transform)
|
||||
{
|
||||
m_svg_transform = transform;
|
||||
|
@ -75,7 +72,6 @@ public:
|
|||
clone.m_device_viewport_rect = m_device_viewport_rect;
|
||||
clone.m_should_show_line_box_borders = m_should_show_line_box_borders;
|
||||
clone.m_should_paint_overlay = m_should_paint_overlay;
|
||||
clone.m_focus = m_focus;
|
||||
return clone;
|
||||
}
|
||||
|
||||
|
@ -90,7 +86,6 @@ private:
|
|||
DevicePixelRect m_device_viewport_rect;
|
||||
bool m_should_show_line_box_borders { false };
|
||||
bool m_should_paint_overlay { true };
|
||||
bool m_focus { false };
|
||||
bool m_draw_svg_geometry_for_clip_path { false };
|
||||
Gfx::AffineTransform m_svg_transform;
|
||||
u64 m_paint_generation_id { 0 };
|
||||
|
|
|
@ -239,7 +239,6 @@ void PageClient::paint_next_frame()
|
|||
void PageClient::start_display_list_rendering(Web::DevicePixelRect const& content_rect, Web::Painting::BackingStore& target, Web::PaintOptions paint_options, Function<void()>&& callback)
|
||||
{
|
||||
paint_options.should_show_line_box_borders = m_should_show_line_box_borders;
|
||||
paint_options.has_focus = m_has_focus;
|
||||
auto& traversable = *page().top_level_traversable();
|
||||
auto display_list = traversable.record_display_list(content_rect, paint_options);
|
||||
if (!display_list) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue