mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 15:40:19 +00:00
LibGUI: Use widget override cursors in GUI::ResizeCorner
This commit is contained in:
parent
8f5b92865d
commit
69adaf3308
Notes:
sideshowbarker
2024-07-19 02:46:47 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/69adaf33089
2 changed files with 1 additions and 14 deletions
|
@ -77,6 +77,7 @@ static const int s_resize_corner_bitmap_height = 16;
|
|||
|
||||
ResizeCorner::ResizeCorner()
|
||||
{
|
||||
set_override_cursor(Gfx::StandardCursor::ResizeDiagonalTLBR);
|
||||
set_background_role(ColorRole::Button);
|
||||
set_size_policy(SizePolicy::Fixed, SizePolicy::Fixed);
|
||||
set_preferred_size(16, 18);
|
||||
|
@ -110,16 +111,4 @@ void ResizeCorner::mousedown_event(MouseEvent& event)
|
|||
Widget::mousedown_event(event);
|
||||
}
|
||||
|
||||
void ResizeCorner::enter_event(Core::Event& event)
|
||||
{
|
||||
window()->set_cursor(Gfx::StandardCursor::ResizeDiagonalTLBR);
|
||||
Widget::enter_event(event);
|
||||
}
|
||||
|
||||
void ResizeCorner::leave_event(Core::Event& event)
|
||||
{
|
||||
window()->set_cursor(Gfx::StandardCursor::None);
|
||||
Widget::leave_event(event);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -40,8 +40,6 @@ protected:
|
|||
|
||||
virtual void paint_event(PaintEvent&) override;
|
||||
virtual void mousedown_event(MouseEvent&) override;
|
||||
virtual void enter_event(Core::Event&) override;
|
||||
virtual void leave_event(Core::Event&) override;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue