1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-22 16:25:07 +00:00

WindowServer+LibGUI: Add "help" cursor

This commit is contained in:
Linus Groh 2020-07-07 20:01:29 +01:00 committed by Andreas Kling
parent b86a59ec05
commit b8a8e417f1
7 changed files with 8 additions and 0 deletions

View file

@ -17,6 +17,7 @@ IBeam=/res/cursors/i-beam.png
Disallowed=/res/cursors/disallowed.png
Move=/res/cursors/move.png
Hand=/res/cursors/hand.png
Help=/res/cursors/help.png
Drag=/res/cursors/drag.png
[Input]

BIN
Base/res/cursors/help.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

View file

@ -49,6 +49,7 @@ enum class StandardCursor {
ResizeColumn,
ResizeRow,
Hand,
Help,
Drag,
Move,
};

View file

@ -72,6 +72,8 @@ RefPtr<Cursor> Cursor::create(StandardCursor standard_cursor)
return WindowManager::the().resize_row_cursor();
case StandardCursor::Hand:
return WindowManager::the().hand_cursor();
case StandardCursor::Help:
return WindowManager::the().help_cursor();
case StandardCursor::Drag:
return WindowManager::the().drag_cursor();
case StandardCursor::Move:

View file

@ -41,6 +41,7 @@ enum class StandardCursor {
ResizeColumn,
ResizeRow,
Hand,
Help,
Drag,
Move,
};

View file

@ -113,6 +113,7 @@ void WindowManager::reload_config(bool set_screen)
m_arrow_cursor = get_cursor("Arrow", { 2, 2 });
m_hand_cursor = get_cursor("Hand", { 8, 4 });
m_help_cursor = get_cursor("Help", { 1, 1 });
m_resize_horizontally_cursor = get_cursor("ResizeH");
m_resize_vertically_cursor = get_cursor("ResizeV");
m_resize_diagonally_tlbr_cursor = get_cursor("ResizeDTLBR");

View file

@ -122,6 +122,7 @@ public:
const Cursor& active_cursor() const;
const Cursor& arrow_cursor() const { return *m_arrow_cursor; }
const Cursor& hand_cursor() const { return *m_hand_cursor; }
const Cursor& help_cursor() const { return *m_help_cursor; }
const Cursor& resize_horizontally_cursor() const { return *m_resize_horizontally_cursor; }
const Cursor& resize_vertically_cursor() const { return *m_resize_vertically_cursor; }
const Cursor& resize_diagonally_tlbr_cursor() const { return *m_resize_diagonally_tlbr_cursor; }
@ -204,6 +205,7 @@ private:
RefPtr<Cursor> m_arrow_cursor;
RefPtr<Cursor> m_hand_cursor;
RefPtr<Cursor> m_help_cursor;
RefPtr<Cursor> m_resize_horizontally_cursor;
RefPtr<Cursor> m_resize_vertically_cursor;
RefPtr<Cursor> m_resize_diagonally_tlbr_cursor;