diff --git a/intern/ghost/GHOST_Types.h b/intern/ghost/GHOST_Types.h index e317f3d0603..79255936ca5 100644 --- a/intern/ghost/GHOST_Types.h +++ b/intern/ghost/GHOST_Types.h @@ -363,6 +363,9 @@ typedef enum { GHOST_kStandardCursorLeftHandle, GHOST_kStandardCursorRightHandle, GHOST_kStandardCursorBothHandles, + GHOST_kStandardCursorHandOpen, + GHOST_kStandardCursorHandClosed, + GHOST_kStandardCursorHandPoint, GHOST_kStandardCursorCustom, #define GHOST_kStandardCursorNumCursors (int(GHOST_kStandardCursorCustom) + 1) diff --git a/intern/ghost/intern/GHOST_SystemWayland.cc b/intern/ghost/intern/GHOST_SystemWayland.cc index 9102bbb028e..5396b738a93 100644 --- a/intern/ghost/intern/GHOST_SystemWayland.cc +++ b/intern/ghost/intern/GHOST_SystemWayland.cc @@ -2246,6 +2246,9 @@ static const GWL_Cursor_ShapeInfo ghost_wl_cursors = []() -> GWL_Cursor_ShapeInf CASE_CURSOR(GHOST_kStandardCursorZoomIn, "zoom-in"); CASE_CURSOR(GHOST_kStandardCursorZoomOut, "zoom-out"); CASE_CURSOR(GHOST_kStandardCursorMove, "move"); + CASE_CURSOR(GHOST_kStandardCursorHandOpen, "move"); + CASE_CURSOR(GHOST_kStandardCursorHandClosed, "move"); + CASE_CURSOR(GHOST_kStandardCursorHandPoint, "move"); CASE_CURSOR(GHOST_kStandardCursorNSEWScroll, "all-scroll"); CASE_CURSOR(GHOST_kStandardCursorNSScroll, "size_ver"); CASE_CURSOR(GHOST_kStandardCursorEWScroll, "size_hor"); diff --git a/intern/ghost/intern/GHOST_WindowCocoa.mm b/intern/ghost/intern/GHOST_WindowCocoa.mm index 016c16857f2..c10237d7426 100644 --- a/intern/ghost/intern/GHOST_WindowCocoa.mm +++ b/intern/ghost/intern/GHOST_WindowCocoa.mm @@ -971,6 +971,12 @@ NSCursor *GHOST_WindowCocoa::getStandardCursor(GHOST_TStandardCursor shape) cons return [NSCursor operationNotAllowedCursor]; case GHOST_kStandardCursorMove: return [NSCursor openHandCursor]; + case GHOST_kStandardCursorHandOpen: + return [NSCursor openHandCursor]; + case GHOST_kStandardCursorHandClosed: + return [NSCursor closedHandCursor]; + case GHOST_kStandardCursorHandPoint: + return [NSCursor pointingHandCursor]; case GHOST_kStandardCursorDefault: return [NSCursor arrowCursor]; case GHOST_kStandardCursorKnife: diff --git a/intern/ghost/intern/GHOST_WindowWin32.cc b/intern/ghost/intern/GHOST_WindowWin32.cc index 67a763f13f4..b2de8093dca 100644 --- a/intern/ghost/intern/GHOST_WindowWin32.cc +++ b/intern/ghost/intern/GHOST_WindowWin32.cc @@ -758,8 +758,17 @@ HCURSOR GHOST_WindowWin32::getStandardCursor(GHOST_TStandardCursor shape) const cursor = ::LoadImage(module, "zoomout_cursor", IMAGE_CURSOR, cx, cy, flags); break; case GHOST_kStandardCursorMove: + cursor = ::LoadImage(nullptr, IDC_SIZEALL, IMAGE_CURSOR, cx, cy, flags); + break; + case GHOST_kStandardCursorHandOpen: cursor = ::LoadImage(module, "handopen_cursor", IMAGE_CURSOR, cx, cy, flags); break; + case GHOST_kStandardCursorHandClosed: + cursor = ::LoadImage(module, "handclosed_cursor", IMAGE_CURSOR, cx, cy, flags); + break; + case GHOST_kStandardCursorHandPoint: + cursor = ::LoadImage(module, "handpoint_cursor", IMAGE_CURSOR, cx, cy, flags); + break; case GHOST_kStandardCursorNSEWScroll: cursor = ::LoadImage(module, "scrollnsew_cursor", IMAGE_CURSOR, cx, cy, flags); break; diff --git a/release/windows/icons/cursors/handclosed.cur b/release/windows/icons/cursors/handclosed.cur new file mode 100644 index 00000000000..1e358d80bc1 Binary files /dev/null and b/release/windows/icons/cursors/handclosed.cur differ diff --git a/release/windows/icons/cursors/handopen.cur b/release/windows/icons/cursors/handopen.cur index cba18448873..d63932f0c97 100644 Binary files a/release/windows/icons/cursors/handopen.cur and b/release/windows/icons/cursors/handopen.cur differ diff --git a/release/windows/icons/cursors/handpoint.cur b/release/windows/icons/cursors/handpoint.cur new file mode 100644 index 00000000000..92befab2469 Binary files /dev/null and b/release/windows/icons/cursors/handpoint.cur differ diff --git a/release/windows/icons/winblender.rc b/release/windows/icons/winblender.rc index 2bfcddaa4ca..eb78a4d30d4 100644 --- a/release/windows/icons/winblender.rc +++ b/release/windows/icons/winblender.rc @@ -26,6 +26,8 @@ crossC_cursor CURSOR "cursors/crossc.cur" eraser_cursor CURSOR "cursors/eraser.cur" eyedropper_cursor CURSOR "cursors/eyedropper.cur" handopen_cursor CURSOR "cursors/handopen.cur" +handclosed_cursor CURSOR "cursors/handclosed.cur" +handpoint_cursor CURSOR "cursors/handpoint.cur" knife_cursor CURSOR "cursors/knife.cur" pencil_cursor CURSOR "cursors/pencil.cur" scrollew_cursor CURSOR "cursors/scrollew.cur" diff --git a/source/blender/makesrna/intern/rna_wm_api.cc b/source/blender/makesrna/intern/rna_wm_api.cc index 4673b1b21cf..dcae09fa778 100644 --- a/source/blender/makesrna/intern/rna_wm_api.cc +++ b/source/blender/makesrna/intern/rna_wm_api.cc @@ -45,7 +45,9 @@ const EnumPropertyItem rna_enum_window_cursor_items[] = { {WM_CURSOR_PAINT, "PAINT_CROSS", 0, "Paint Cross", ""}, {WM_CURSOR_DOT, "DOT", 0, "Dot Cursor", ""}, {WM_CURSOR_ERASER, "ERASER", 0, "Eraser", ""}, - {WM_CURSOR_HAND, "HAND", 0, "Hand", ""}, + {WM_CURSOR_HAND, "HAND", 0, "Open Hand", ""}, + {WM_CURSOR_HAND_POINT, "HAND_POINT", 0, "Pointing Hand", ""}, + {WM_CURSOR_HAND_CLOSED, "HAND_CLOSED", 0, "Closed Hand", ""}, {WM_CURSOR_EW_SCROLL, "SCROLL_X", 0, "Scroll-X", ""}, {WM_CURSOR_NS_SCROLL, "SCROLL_Y", 0, "Scroll-Y", ""}, {WM_CURSOR_NSEW_SCROLL, "SCROLL_XY", 0, "Scroll-XY", ""}, diff --git a/source/blender/windowmanager/intern/wm_cursors.cc b/source/blender/windowmanager/intern/wm_cursors.cc index ed12e81fecc..709549ed61f 100644 --- a/source/blender/windowmanager/intern/wm_cursors.cc +++ b/source/blender/windowmanager/intern/wm_cursors.cc @@ -49,6 +49,8 @@ static GHOST_TStandardCursor convert_to_ghost_standard_cursor(WMCursorType curs) case WM_CURSOR_EDIT: case WM_CURSOR_CROSS: return GHOST_kStandardCursorCrosshair; + case WM_CURSOR_MOVE: + return GHOST_kStandardCursorMove; case WM_CURSOR_X_MOVE: return GHOST_kStandardCursorLeftRight; case WM_CURSOR_Y_MOVE: @@ -56,7 +58,11 @@ static GHOST_TStandardCursor convert_to_ghost_standard_cursor(WMCursorType curs) case WM_CURSOR_COPY: return GHOST_kStandardCursorCopy; case WM_CURSOR_HAND: - return GHOST_kStandardCursorMove; + return GHOST_kStandardCursorHandOpen; + case WM_CURSOR_HAND_CLOSED: + return GHOST_kStandardCursorHandClosed; + case WM_CURSOR_HAND_POINT: + return GHOST_kStandardCursorHandPoint; case WM_CURSOR_H_SPLIT: return GHOST_kStandardCursorHorizontalSplit; case WM_CURSOR_V_SPLIT: diff --git a/source/blender/windowmanager/wm_cursors.hh b/source/blender/windowmanager/wm_cursors.hh index c689420bf4d..69258d95a11 100644 --- a/source/blender/windowmanager/wm_cursors.hh +++ b/source/blender/windowmanager/wm_cursors.hh @@ -18,7 +18,10 @@ enum WMCursorType { WM_CURSOR_STOP, WM_CURSOR_EDIT, WM_CURSOR_COPY, + WM_CURSOR_MOVE, WM_CURSOR_HAND, + WM_CURSOR_HAND_CLOSED, + WM_CURSOR_HAND_POINT, WM_CURSOR_CROSS, WM_CURSOR_PAINT,