* Added BCursorID enumeration in App Kit's Cursor.h and new constructor which

takes such an id.
 * Reused the existing mechanism to to have hardcoded tokens for the system
   cursors, i.e. removed cursor_which enumeration from ServerProtocol.h and
   used BCursorID where cursor_which was previously used.
 * Reworked CursorManager.h and CursorSet.h accordingly and removed some methods
   that where intended to replace system cursors with client cursors, since
   those would break the reference counting and forget to maintain the cursor
   list.
 * Replaced the cursors in CursorData.h/cpp with the new ones I just designed.
 * Removed HaikuSystemCursor.h and HaikuLogo.h from the source, as those are/were
   no longer used.

I hope I will not get too much beating for this one... :-) I know the new
default cursor is slightly larger, but I believe the old one was just too small.
Also I noticed that the cursor may be slightly too dark, at least the old one
seems noticeably brighter when compared side by side (the new one has a slight
gradient). That is something I may correct at least. Otherwise I hope nothing
is broken, I've tested in QEMU and so far everything works as intended.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35782 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Stephan Aßmus 2010-03-07 23:12:34 +00:00
parent 7d0b880b3c
commit e59dc33e21
12 changed files with 3785 additions and 6402 deletions

View File

@ -10,10 +10,44 @@
#include <InterfaceDefs.h>
enum BCursorID {
B_CURSOR_ID_SYSTEM_DEFAULT = 1,
B_CURSOR_ID_CONTEXT_MENU = 3,
B_CURSOR_ID_COPY = 4,
B_CURSOR_ID_CROSS_HAIR = 5,
B_CURSOR_ID_FOLLOW_LINK = 6,
B_CURSOR_ID_GRAB = 7,
B_CURSOR_ID_GRABBING = 8,
B_CURSOR_ID_HELP = 9,
B_CURSOR_ID_I_BEAM = 2,
B_CURSOR_ID_I_BEAM_HORIZONTAL = 10,
B_CURSOR_ID_MOVE = 11,
B_CURSOR_ID_NO_CURSOR = 12,
B_CURSOR_ID_NOT_ALLOWED = 13,
B_CURSOR_ID_PROGRESS = 14,
B_CURSOR_ID_RESIZE_NORTH = 15,
B_CURSOR_ID_RESIZE_EAST = 16,
B_CURSOR_ID_RESIZE_SOUTH = 17,
B_CURSOR_ID_RESIZE_WEST = 18,
B_CURSOR_ID_RESIZE_NORTH_EAST = 19,
B_CURSOR_ID_RESIZE_NORTH_WEST = 20,
B_CURSOR_ID_RESIZE_SOUTH_EAST = 21,
B_CURSOR_ID_RESIZE_SOUTH_WEST = 22,
B_CURSOR_ID_RESIZE_NORTH_SOUTH = 23,
B_CURSOR_ID_RESIZE_EAST_WEST = 24,
B_CURSOR_ID_RESIZE_NORTH_EAST_SOUTH_WEST = 25,
B_CURSOR_ID_RESIZE_NORTH_WEST_SOUTH_EAST = 26,
B_CURSOR_ID_ZOOM_IN = 27,
B_CURSOR_ID_ZOOM_OUT = 28
};
class BCursor : BArchivable {
public:
BCursor(const void* cursorData);
BCursor(const BCursor& other);
BCursor(BCursorID id);
BCursor(BMessage* data);
virtual ~BCursor();

View File

@ -332,22 +332,6 @@ enum {
AS_LAST_CODE
};
// Cursor types, currently they are all private besides the first two
enum cursor_which {
B_CURSOR_DEFAULT = 1,
B_CURSOR_TEXT,
B_CURSOR_MOVE,
B_CURSOR_DRAG,
B_CURSOR_RESIZE,
B_CURSOR_RESIZE_NWSE,
B_CURSOR_RESIZE_NESW,
B_CURSOR_RESIZE_NS,
B_CURSOR_RESIZE_EW,
B_CURSOR_OTHER,
B_CURSOR_APP,
B_CURSOR_INVALID
};
// bitmap allocation flags
enum {
kAllocator = 0x1,

View File

@ -26,7 +26,6 @@ const BCursor *B_CURSOR_SYSTEM_DEFAULT;
const BCursor *B_CURSOR_I_BEAM;
// these are initialized in BApplication::InitData()
BCursor::BCursor(const void *cursorData)
:
fServerToken(-1),
@ -37,7 +36,7 @@ BCursor::BCursor(const void *cursorData)
if (data == B_HAND_CURSOR || data == B_I_BEAM_CURSOR) {
// just use the default cursors from the app_server
fServerToken = data == B_HAND_CURSOR ?
B_CURSOR_DEFAULT : B_CURSOR_TEXT;
B_CURSOR_ID_SYSTEM_DEFAULT : B_CURSOR_ID_I_BEAM;
return;
}
@ -62,6 +61,14 @@ BCursor::BCursor(const void *cursorData)
}
BCursor::BCursor(BCursorID id)
:
fServerToken(id),
fNeedToFree(false)
{
}
BCursor::BCursor(const BCursor& other)
:
fServerToken(-1),

File diff suppressed because it is too large Load Diff

View File

@ -1,16 +1,46 @@
#ifndef CURSORDATA_H_
#define CURSORDATA_H_
/*
* Copyright 2010 Stephan Aßmus <superstippi@gmx.de>.
* All rights reserved. Distributed under the terms of the MIT License.
*/
#ifndef CURSOR_DATA_H
#define CURSOR_DATA_H
#include <SupportDefs.h>
extern uint8 default_cursor_data[];
extern uint8 default_text_data[];
extern uint8 default_move_data[];
extern uint8 default_drag_data[];
extern uint8 default_resize_data[];
extern uint8 default_resize_ew_data[];
extern uint8 default_resize_ns_data[];
extern uint8 default_resize_nwse_data[];
extern uint8 default_resize_nesw_data[];
#include <GraphicsDefs.h>
#endif
const uint32 kCursorWidth = 22;
const uint32 kCursorHeight = 22;
const color_space kCursorFormat = B_RGBA32;
extern const uint8 kCursorContextMenuBits[];
extern const uint8 kCursorCopyBits[];
extern const uint8 kCursorCrossHairBits[];
extern const uint8 kCursorFollowLinkBits[];
extern const uint8 kCursorGrabBits[];
extern const uint8 kCursorGrabbingBits[];
extern const uint8 kCursorHelpBits[];
extern const uint8 kCursorIBeamBits[];
extern const uint8 kCursorIBeamHorizontalBits[];
extern const uint8 kCursorMoveBits[];
extern const uint8 kCursorNoCursor[];
extern const uint8 kCursorNotAllowedBits[];
extern const uint8 kCursorProgressBits[];
extern const uint8 kCursorResizeEastBits[];
extern const uint8 kCursorResizeEastWestBits[];
extern const uint8 kCursorResizeNorthBits[];
extern const uint8 kCursorResizeNorthEastBits[];
extern const uint8 kCursorResizeNorthEastSouthWestBits[];
extern const uint8 kCursorResizeNorthSouthBits[];
extern const uint8 kCursorResizeNorthWestBits[];
extern const uint8 kCursorResizeNorthWestSouthEastBits[];
extern const uint8 kCursorResizeSouthBits[];
extern const uint8 kCursorResizeSouthEastBits[];
extern const uint8 kCursorResizeSouthWestBits[];
extern const uint8 kCursorResizeWestBits[];
extern const uint8 kCursorSystemDefaultBits[];
extern const uint8 kCursorZoomInBits[];
extern const uint8 kCursorZoomOutBits[];
#endif // CURSOR_DATA_H

View File

@ -13,7 +13,6 @@
#include "CursorManager.h"
#include "CursorData.h"
#include "HaikuSystemCursor.h"
#include "ServerCursor.h"
#include "ServerConfig.h"
#include "ServerTokenSpace.h"
@ -30,51 +29,74 @@ CursorManager::CursorManager()
:
BLocker("CursorManager")
{
// Set system cursors to "unassigned"
// ToDo: decide about default cursor
#if 1
fDefaultCursor = new ServerCursor(kHaikuCursorBits, kHaikuCursorWidth,
kHaikuCursorHeight, kHaikuCursorFormat);
// we just happen to know where the hotspot is
fDefaultCursor->SetHotSpot(BPoint(1, 0));
#else
fDefaultCursor = new ServerCursor(default_cursor_data);
#endif
AddCursor(fDefaultCursor, B_CURSOR_DEFAULT);
fTextCursor = new ServerCursor(default_text_data);
AddCursor(fTextCursor, B_CURSOR_TEXT);
fMoveCursor = new ServerCursor(default_move_data);
AddCursor(fMoveCursor);
fDragCursor = new ServerCursor(default_drag_data);
AddCursor(fDragCursor);
fResizeCursor = new ServerCursor(default_resize_data);
AddCursor(fResizeCursor);
fNWSECursor = new ServerCursor(default_resize_nwse_data);
AddCursor(fNWSECursor);
fNESWCursor = new ServerCursor(default_resize_nesw_data);
AddCursor(fNESWCursor);
fNSCursor = new ServerCursor(default_resize_ns_data);
AddCursor(fNSCursor);
fEWCursor = new ServerCursor(default_resize_ew_data);
AddCursor(fEWCursor);
// Init system cursors
const BPoint kHandHotspot(1, 1);
const BPoint kResizeHotspot(8, 8);
_InitCursor(fCursorSystemDefault, kCursorSystemDefaultBits,
B_CURSOR_ID_SYSTEM_DEFAULT, kHandHotspot);
_InitCursor(fCursorContextMenu, kCursorContextMenuBits,
B_CURSOR_ID_CONTEXT_MENU, kHandHotspot);
_InitCursor(fCursorCopy, kCursorCopyBits,
B_CURSOR_ID_COPY, kHandHotspot);
_InitCursor(fCursorCrossHair, kCursorCrossHairBits,
B_CURSOR_ID_CROSS_HAIR, BPoint(10, 10));
_InitCursor(fCursorFollowLink, kCursorFollowLinkBits,
B_CURSOR_ID_FOLLOW_LINK, kHandHotspot);
_InitCursor(fCursorGrab, kCursorGrabBits,
B_CURSOR_ID_GRAB, kHandHotspot);
_InitCursor(fCursorGrabbing, kCursorGrabbingBits,
B_CURSOR_ID_GRABBING, kHandHotspot);
_InitCursor(fCursorHelp, kCursorHelpBits,
B_CURSOR_ID_HELP, BPoint(0, 8));
_InitCursor(fCursorIBeam, kCursorIBeamBits,
B_CURSOR_ID_I_BEAM, BPoint(7, 9));
_InitCursor(fCursorIBeamHorizontal, kCursorIBeamHorizontalBits,
B_CURSOR_ID_I_BEAM_HORIZONTAL, BPoint(8, 8));
_InitCursor(fCursorMove, kCursorMoveBits,
B_CURSOR_ID_MOVE, kResizeHotspot);
_InitCursor(fCursorNoCursor, 0, B_CURSOR_ID_NO_CURSOR, BPoint(0, 0));
_InitCursor(fCursorNotAllowed, kCursorNotAllowedBits,
B_CURSOR_ID_NOT_ALLOWED, BPoint(8, 8));
_InitCursor(fCursorProgress, kCursorProgressBits,
B_CURSOR_ID_PROGRESS, BPoint(7, 10));
_InitCursor(fCursorResizeEast, kCursorResizeEastBits,
B_CURSOR_ID_RESIZE_EAST, kResizeHotspot);
_InitCursor(fCursorResizeEastWest, kCursorResizeEastWestBits,
B_CURSOR_ID_RESIZE_EAST_WEST, kResizeHotspot);
_InitCursor(fCursorResizeNorth, kCursorResizeNorthBits,
B_CURSOR_ID_RESIZE_NORTH, kResizeHotspot);
_InitCursor(fCursorResizeNorthEast, kCursorResizeNorthEastBits,
B_CURSOR_ID_RESIZE_NORTH_EAST, kResizeHotspot);
_InitCursor(fCursorResizeNorthEastSouthWest,
kCursorResizeNorthEastSouthWestBits,
B_CURSOR_ID_RESIZE_NORTH_EAST_SOUTH_WEST, kResizeHotspot);
_InitCursor(fCursorResizeNorthSouth, kCursorResizeNorthSouthBits,
B_CURSOR_ID_RESIZE_NORTH_SOUTH, kResizeHotspot);
_InitCursor(fCursorResizeNorthWest, kCursorResizeNorthWestBits,
B_CURSOR_ID_RESIZE_NORTH_WEST, kResizeHotspot);
_InitCursor(fCursorResizeNorthWestSouthEast,
kCursorResizeNorthWestSouthEastBits,
B_CURSOR_ID_RESIZE_NORTH_WEST_SOUTH_EAST, kResizeHotspot);
_InitCursor(fCursorResizeSouth, kCursorResizeSouthBits,
B_CURSOR_ID_RESIZE_SOUTH, kResizeHotspot);
_InitCursor(fCursorResizeSouthEast, kCursorResizeSouthEastBits,
B_CURSOR_ID_RESIZE_SOUTH_EAST, kResizeHotspot);
_InitCursor(fCursorResizeSouthWest, kCursorResizeSouthWestBits,
B_CURSOR_ID_RESIZE_SOUTH_WEST, kResizeHotspot);
_InitCursor(fCursorResizeWest, kCursorResizeWestBits,
B_CURSOR_ID_RESIZE_WEST, kResizeHotspot);
_InitCursor(fCursorZoomIn, kCursorZoomInBits,
B_CURSOR_ID_ZOOM_IN, BPoint(6, 6));
_InitCursor(fCursorZoomOut, kCursorZoomOutBits,
B_CURSOR_ID_ZOOM_OUT, BPoint(6, 6));
}
//! Does all the teardown
CursorManager::~CursorManager()
{
for (int32 i = 0; i < fCursorList.CountItems(); i++) {
for (int32 i = 0; i < fCursorList.CountItems(); i++)
delete (ServerCursor*)fCursorList.ItemAtFast(i);
}
}
@ -95,9 +117,8 @@ CursorManager::CreateCursor(team_id clientTeam, const uint8* cursorData)
cursor = NULL;
}
}
} else {
} else
cursor->AcquireReference();
}
Unlock();
@ -112,19 +133,20 @@ CursorManager::CreateCursor(team_id clientTeam, const uint8* cursorData)
int32
CursorManager::AddCursor(ServerCursor* cursor, int32 token)
{
if (!cursor || !Lock())
if (!cursor)
return B_BAD_VALUE;
if (!Lock())
return B_ERROR;
if (!fCursorList.AddItem(cursor)) {
Unlock();
return B_ERROR;
return B_NO_MEMORY;
}
if (token == -1) {
if (token == -1)
token = fTokenSpace.NewToken(kCursorToken, cursor);
} else {
else
fTokenSpace.SetToken(token, kCursorToken, cursor);
}
cursor->fToken = token;
cursor->AttachedToManager(this);
@ -170,7 +192,7 @@ CursorManager::DeleteCursors(team_id team)
return;
for (int32 index = fCursorList.CountItems(); index-- > 0;) {
ServerCursor *cursor = (ServerCursor*)fCursorList.ItemAtFast(index);
ServerCursor* cursor = (ServerCursor*)fCursorList.ItemAtFast(index);
if (cursor->OwningTeam() == team)
cursor->ReleaseReference();
}
@ -188,7 +210,7 @@ CursorManager::DeleteCursors(team_id team)
path to a non-CursorSet file.
*/
void
CursorManager::SetCursorSet(const char *path)
CursorManager::SetCursorSet(const char* path)
{
BAutolock locker (this);
@ -197,52 +219,42 @@ CursorManager::SetCursorSet(const char *path)
if (!path || cursorSet.Load(path) != B_OK)
return;
ServerCursor *cursor = NULL;
if (cursorSet.FindCursor(B_CURSOR_DEFAULT, &cursor) == B_OK) {
delete fDefaultCursor;
fDefaultCursor = cursor;
}
if (cursorSet.FindCursor(B_CURSOR_TEXT, &cursor) == B_OK) {
delete fTextCursor;
fTextCursor = cursor;
}
if (cursorSet.FindCursor(B_CURSOR_MOVE, &cursor) == B_OK) {
delete fMoveCursor;
fMoveCursor = cursor;
}
if (cursorSet.FindCursor(B_CURSOR_DRAG, &cursor) == B_OK) {
delete fDragCursor;
fDragCursor = cursor;
}
if (cursorSet.FindCursor(B_CURSOR_RESIZE, &cursor) == B_OK) {
delete fResizeCursor;
fResizeCursor = cursor;
}
if (cursorSet.FindCursor(B_CURSOR_RESIZE_NWSE, &cursor) == B_OK) {
delete fNWSECursor;
fNWSECursor = cursor;
}
if (cursorSet.FindCursor(B_CURSOR_RESIZE_NESW, &cursor) == B_OK) {
delete fNESWCursor;
fNESWCursor = cursor;
}
if (cursorSet.FindCursor(B_CURSOR_RESIZE_NS, &cursor) == B_OK) {
delete fNSCursor;
fNSCursor = cursor;
}
if (cursorSet.FindCursor(B_CURSOR_RESIZE_EW, &cursor) == B_OK) {
delete fEWCursor;
fEWCursor = cursor;
}
_LoadCursor(fCursorSystemDefault, cursorSet, B_CURSOR_ID_SYSTEM_DEFAULT);
_LoadCursor(fCursorContextMenu, cursorSet, B_CURSOR_ID_CONTEXT_MENU);
_LoadCursor(fCursorCopy, cursorSet, B_CURSOR_ID_COPY);
_LoadCursor(fCursorCrossHair, cursorSet, B_CURSOR_ID_CROSS_HAIR);
_LoadCursor(fCursorFollowLink, cursorSet, B_CURSOR_ID_FOLLOW_LINK);
_LoadCursor(fCursorGrab, cursorSet, B_CURSOR_ID_GRAB);
_LoadCursor(fCursorGrabbing, cursorSet, B_CURSOR_ID_GRABBING);
_LoadCursor(fCursorHelp, cursorSet, B_CURSOR_ID_HELP);
_LoadCursor(fCursorIBeam, cursorSet, B_CURSOR_ID_I_BEAM);
_LoadCursor(fCursorIBeamHorizontal, cursorSet,
B_CURSOR_ID_I_BEAM_HORIZONTAL);
_LoadCursor(fCursorMove, cursorSet, B_CURSOR_ID_MOVE);
_LoadCursor(fCursorNotAllowed, cursorSet, B_CURSOR_ID_NOT_ALLOWED);
_LoadCursor(fCursorProgress, cursorSet, B_CURSOR_ID_PROGRESS);
_LoadCursor(fCursorResizeEast, cursorSet, B_CURSOR_ID_RESIZE_EAST);
_LoadCursor(fCursorResizeEastWest, cursorSet,
B_CURSOR_ID_RESIZE_EAST_WEST);
_LoadCursor(fCursorResizeNorth, cursorSet, B_CURSOR_ID_RESIZE_NORTH);
_LoadCursor(fCursorResizeNorthEast, cursorSet,
B_CURSOR_ID_RESIZE_NORTH_EAST);
_LoadCursor(fCursorResizeNorthEastSouthWest, cursorSet,
B_CURSOR_ID_RESIZE_NORTH_EAST_SOUTH_WEST);
_LoadCursor(fCursorResizeNorthSouth, cursorSet,
B_CURSOR_ID_RESIZE_NORTH_SOUTH);
_LoadCursor(fCursorResizeNorthWest, cursorSet,
B_CURSOR_ID_RESIZE_NORTH_WEST);
_LoadCursor(fCursorResizeNorthWestSouthEast, cursorSet,
B_CURSOR_ID_RESIZE_NORTH_WEST_SOUTH_EAST);
_LoadCursor(fCursorResizeSouth, cursorSet, B_CURSOR_ID_RESIZE_SOUTH);
_LoadCursor(fCursorResizeSouthEast, cursorSet,
B_CURSOR_ID_RESIZE_SOUTH_EAST);
_LoadCursor(fCursorResizeSouthWest, cursorSet,
B_CURSOR_ID_RESIZE_SOUTH_WEST);
_LoadCursor(fCursorResizeWest, cursorSet, B_CURSOR_ID_RESIZE_WEST);
_LoadCursor(fCursorZoomIn, cursorSet, B_CURSOR_ID_ZOOM_IN);
_LoadCursor(fCursorZoomOut, cursorSet, B_CURSOR_ID_ZOOM_OUT);
}
@ -251,30 +263,68 @@ CursorManager::SetCursorSet(const char *path)
\return Pointer to the particular cursor used or NULL if which is
invalid or the cursor has not been assigned
*/
ServerCursor *
CursorManager::GetCursor(cursor_which which)
ServerCursor*
CursorManager::GetCursor(BCursorID which)
{
BAutolock locker(this);
switch (which) {
case B_CURSOR_DEFAULT:
return fDefaultCursor;
case B_CURSOR_TEXT:
return fTextCursor;
case B_CURSOR_MOVE:
return fMoveCursor;
case B_CURSOR_DRAG:
return fDragCursor;
case B_CURSOR_RESIZE:
return fResizeCursor;
case B_CURSOR_RESIZE_NWSE:
return fNWSECursor;
case B_CURSOR_RESIZE_NESW:
return fNESWCursor;
case B_CURSOR_RESIZE_NS:
return fNSCursor;
case B_CURSOR_RESIZE_EW:
return fEWCursor;
case B_CURSOR_ID_SYSTEM_DEFAULT:
return fCursorSystemDefault;
case B_CURSOR_ID_CONTEXT_MENU:
return fCursorContextMenu;
case B_CURSOR_ID_COPY:
return fCursorCopy;
case B_CURSOR_ID_CROSS_HAIR:
return fCursorCrossHair;
case B_CURSOR_ID_FOLLOW_LINK:
return fCursorFollowLink;
case B_CURSOR_ID_GRAB:
return fCursorGrab;
case B_CURSOR_ID_GRABBING:
return fCursorGrabbing;
case B_CURSOR_ID_HELP:
return fCursorHelp;
case B_CURSOR_ID_I_BEAM:
return fCursorIBeam;
case B_CURSOR_ID_I_BEAM_HORIZONTAL:
return fCursorIBeamHorizontal;
case B_CURSOR_ID_MOVE:
return fCursorMove;
case B_CURSOR_ID_NO_CURSOR:
return fCursorNoCursor;
case B_CURSOR_ID_NOT_ALLOWED:
return fCursorNotAllowed;
case B_CURSOR_ID_PROGRESS:
return fCursorProgress;
case B_CURSOR_ID_RESIZE_EAST:
return fCursorResizeEast;
case B_CURSOR_ID_RESIZE_EAST_WEST:
return fCursorResizeEastWest;
case B_CURSOR_ID_RESIZE_NORTH:
return fCursorResizeNorth;
case B_CURSOR_ID_RESIZE_NORTH_EAST:
return fCursorResizeNorthEast;
case B_CURSOR_ID_RESIZE_NORTH_EAST_SOUTH_WEST:
return fCursorResizeNorthEastSouthWest;
case B_CURSOR_ID_RESIZE_NORTH_SOUTH:
return fCursorResizeNorthSouth;
case B_CURSOR_ID_RESIZE_NORTH_WEST:
return fCursorResizeNorthWest;
case B_CURSOR_ID_RESIZE_NORTH_WEST_SOUTH_EAST:
return fCursorResizeNorthWestSouthEast;
case B_CURSOR_ID_RESIZE_SOUTH:
return fCursorResizeSouth;
case B_CURSOR_ID_RESIZE_SOUTH_EAST:
return fCursorResizeSouthEast;
case B_CURSOR_ID_RESIZE_SOUTH_WEST:
return fCursorResizeSouthWest;
case B_CURSOR_ID_RESIZE_WEST:
return fCursorResizeWest;
case B_CURSOR_ID_ZOOM_IN:
return fCursorZoomIn;
case B_CURSOR_ID_ZOOM_OUT:
return fCursorZoomOut;
default:
return NULL;
@ -282,132 +332,6 @@ CursorManager::GetCursor(cursor_which which)
}
/*! \brief Gets the current system cursor value
\return The current cursor value or CURSOR_OTHER if some non-system cursor
*/
cursor_which
CursorManager::GetCursorWhich()
{
Lock();
// ToDo: Where is fCurrentWhich set?
cursor_which which;
which = fCurrentWhich;
Unlock();
return which;
}
/*! \brief Sets the specified system cursor to the a particular cursor
\param which Which system cursor to change
\param token The ID of the cursor to become the new one
A word of warning: once a cursor has been assigned to the system, the
system will take ownership of the cursor and deleting the cursor
will have no effect on the system.
*/
void
CursorManager::ChangeCursor(cursor_which which, int32 token)
{
Lock();
// Find the cursor, based on the token
ServerCursor *cursor = FindCursor(token);
// Did we find a cursor with this token?
if (!cursor) {
Unlock();
return;
}
// Do the assignment
switch (which) {
case B_CURSOR_DEFAULT:
delete fDefaultCursor;
fDefaultCursor = cursor;
break;
case B_CURSOR_TEXT:
delete fTextCursor;
fTextCursor = cursor;
break;
case B_CURSOR_MOVE:
delete fMoveCursor;
fMoveCursor = cursor;
break;
case B_CURSOR_DRAG:
delete fDragCursor;
fDragCursor = cursor;
break;
case B_CURSOR_RESIZE:
delete fResizeCursor;
fResizeCursor = cursor;
break;
case B_CURSOR_RESIZE_NWSE:
delete fNWSECursor;
fNWSECursor = cursor;
break;
case B_CURSOR_RESIZE_NESW:
delete fNESWCursor;
fNESWCursor = cursor;
break;
case B_CURSOR_RESIZE_NS:
delete fNSCursor;
fNSCursor = cursor;
break;
case B_CURSOR_RESIZE_EW:
delete fEWCursor;
fEWCursor = cursor;
break;
default:
Unlock();
return;
}
fCursorList.RemoveItem(cursor);
Unlock();
}
//! Sets the cursors to the defaults and saves them to CURSOR_SETTINGS_DIR/"d
void
CursorManager::SetDefaults()
{
Lock();
CursorSet cursorSet("Default");
cursorSet.AddCursor(B_CURSOR_DEFAULT, default_cursor_data);
cursorSet.AddCursor(B_CURSOR_TEXT, default_text_data);
cursorSet.AddCursor(B_CURSOR_MOVE, default_move_data);
cursorSet.AddCursor(B_CURSOR_DRAG, default_drag_data);
cursorSet.AddCursor(B_CURSOR_RESIZE, default_resize_data);
cursorSet.AddCursor(B_CURSOR_RESIZE_NWSE, default_resize_nwse_data);
cursorSet.AddCursor(B_CURSOR_RESIZE_NESW, default_resize_nesw_data);
cursorSet.AddCursor(B_CURSOR_RESIZE_NS, default_resize_ns_data);
cursorSet.AddCursor(B_CURSOR_RESIZE_EW, default_resize_ew_data);
#if 0
BDirectory dir;
if (dir.SetTo(CURSOR_SET_DIR) == B_ENTRY_NOT_FOUND)
create_directory(CURSOR_SET_DIR, 0777);
BString string(CURSOR_SET_DIR);
string += "Default";
cursorSet.Save(string.String(), B_CREATE_FILE | B_FAIL_IF_EXISTS);
SetCursorSet(string.String());
#endif
Unlock();
}
/*! \brief Internal function which finds the cursor with a particular ID
\param token ID of the cursor to find
\return The cursor or NULL if not found
@ -428,7 +352,40 @@ CursorManager::FindCursor(int32 token)
}
ServerCursor *
void
CursorManager::_InitCursor(ServerCursor*& cursorMember,
const uint8* cursorBits, BCursorID id, const BPoint& hotSpot)
{
if (cursorBits) {
cursorMember = new ServerCursor(cursorBits, kCursorWidth,
kCursorHeight, kCursorFormat);
} else
cursorMember = new ServerCursor(kCursorNoCursor, 1, 1, kCursorFormat);
cursorMember->SetHotSpot(hotSpot);
AddCursor(cursorMember, id);
}
void
CursorManager::_LoadCursor(ServerCursor*& cursorMember, const CursorSet& set,
BCursorID id)
{
ServerCursor* cursor;
if (set.FindCursor(id, &cursor) == B_OK) {
int32 index = fCursorList.IndexOf(cursorMember);
if (index >= 0) {
ServerCursor* items = reinterpret_cast<ServerCursor*>(
fCursorList.Items());
items[index] = cursor;
}
delete cursorMember;
cursorMember = cursor;
}
}
ServerCursor*
CursorManager::_FindCursor(team_id clientTeam, const uint8* cursorData)
{
int32 count = fCursorList.CountItems();
@ -437,7 +394,6 @@ CursorManager::_FindCursor(team_id clientTeam, const uint8* cursorData)
if (cursor->OwningTeam() == clientTeam
&& cursor->CursorData()
&& memcmp(cursor->CursorData(), cursorData, 68) == 0) {
//printf("found already existing cursor\n");
return cursor;
}
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2001-2006, Haiku.
* Copyright 2001-2010, Haiku.
* Distributed under the terms of the MIT License.
*
* Authors:
@ -29,46 +29,68 @@ class ServerCursor;
of an application's cursors whenever an application closes.
*/
class CursorManager : public BLocker {
public:
CursorManager();
virtual ~CursorManager();
public:
CursorManager();
~CursorManager();
ServerCursor* CreateCursor(team_id clientTeam,
ServerCursor* CreateCursor(team_id clientTeam,
const uint8* cursorData);
int32 AddCursor(ServerCursor* cursor, int32 token = -1);
void DeleteCursors(team_id team);
int32 AddCursor(ServerCursor* cursor,
int32 token = -1);
void DeleteCursors(team_id team);
bool RemoveCursor(ServerCursor* cursor);
bool RemoveCursor(ServerCursor* cursor);
void SetCursorSet(const char* path);
ServerCursor* GetCursor(cursor_which which);
cursor_which GetCursorWhich();
void ChangeCursor(cursor_which which, int32 token);
void SetDefaults();
void SetCursorSet(const char* path);
ServerCursor* GetCursor(BCursorID which);
ServerCursor* FindCursor(int32 token);
ServerCursor* FindCursor(int32 token);
private:
ServerCursor* _FindCursor(team_id cientTeam,
private:
void _InitCursor(ServerCursor*& cursorMember,
const uint8* cursorBits, BCursorID id,
const BPoint& hotSpot = B_ORIGIN);
void _LoadCursor(ServerCursor*& cursorMember,
const CursorSet& set, BCursorID id);
ServerCursor* _FindCursor(team_id cientTeam,
const uint8* cursorData);
void _RemoveCursor(ServerCursor* cursor);
// ServerCursor* _RemoveCursor(int32 index);
void _RemoveCursor(ServerCursor* cursor);
BList fCursorList;
BTokenSpace fTokenSpace;
private:
BList fCursorList;
BTokenSpace fTokenSpace;
// System cursor members
ServerCursor *fDefaultCursor,
*fTextCursor,
*fMoveCursor,
*fDragCursor,
*fResizeCursor,
*fNWSECursor,
*fNESWCursor,
*fNSCursor,
*fEWCursor;
cursor_which fCurrentWhich;
// System cursor members
ServerCursor* fCursorSystemDefault;
ServerCursor* fCursorContextMenu;
ServerCursor* fCursorCopy;
ServerCursor* fCursorCrossHair;
ServerCursor* fCursorFollowLink;
ServerCursor* fCursorGrab;
ServerCursor* fCursorGrabbing;
ServerCursor* fCursorHelp;
ServerCursor* fCursorIBeam;
ServerCursor* fCursorIBeamHorizontal;
ServerCursor* fCursorMove;
ServerCursor* fCursorNoCursor;
ServerCursor* fCursorNotAllowed;
ServerCursor* fCursorProgress;
ServerCursor* fCursorResizeEast;
ServerCursor* fCursorResizeEastWest;
ServerCursor* fCursorResizeNorth;
ServerCursor* fCursorResizeNorthEast;
ServerCursor* fCursorResizeNorthEastSouthWest;
ServerCursor* fCursorResizeNorthSouth;
ServerCursor* fCursorResizeNorthWest;
ServerCursor* fCursorResizeNorthWestSouthEast;
ServerCursor* fCursorResizeSouth;
ServerCursor* fCursorResizeSouthEast;
ServerCursor* fCursorResizeSouthWest;
ServerCursor* fCursorResizeWest;
ServerCursor* fCursorZoomIn;
ServerCursor* fCursorZoomOut;
};
#endif /* CURSOR_MANAGER_H */
#endif // CURSOR_MANAGER_H

View File

@ -85,7 +85,7 @@ CursorSet::Load(const char *path)
\return B_BAD_VALUE if cursor is NULL, otherwise B_OK
*/
status_t
CursorSet::AddCursor(cursor_which which, const BBitmap *cursor, const BPoint &hotspot)
CursorSet::AddCursor(BCursorID which, const BBitmap *cursor, const BPoint &hotspot)
{
if (!cursor)
return B_BAD_VALUE;
@ -120,7 +120,7 @@ CursorSet::AddCursor(cursor_which which, const BBitmap *cursor, const BPoint &ho
function must convert the R5 cursor data into a BBitmap
*/
status_t
CursorSet::AddCursor(cursor_which which, uint8 *data)
CursorSet::AddCursor(BCursorID which, uint8 *data)
{
// Convert cursor data to a bitmap because all cursors are internally stored
// as bitmaps
@ -142,7 +142,7 @@ CursorSet::AddCursor(cursor_which which, uint8 *data)
\param which System cursor specifier defined in CursorSet.h
*/
void
CursorSet::RemoveCursor(cursor_which which)
CursorSet::RemoveCursor(BCursorID which)
{
RemoveData(_CursorWhichToString(which));
}
@ -162,7 +162,7 @@ CursorSet::RemoveCursor(cursor_which which)
BBitmaps created by this function are the responsibility of the caller.
*/
status_t
CursorSet::FindCursor(cursor_which which, BBitmap **cursor, BPoint *hotspot)
CursorSet::FindCursor(BCursorID which, BBitmap **cursor, BPoint *hotspot)
{
if (!cursor || !hotspot);
return B_BAD_VALUE;
@ -211,7 +211,7 @@ CursorSet::FindCursor(cursor_which which, BBitmap **cursor, BPoint *hotspot)
BBitmaps created by this function are the responsibility of the caller.
*/
status_t
CursorSet::FindCursor(cursor_which which, ServerCursor **_cursor)
CursorSet::FindCursor(BCursorID which, ServerCursor **_cursor) const
{
BMessage msg;
if (FindMessage(_CursorWhichToString(which), &msg) != B_OK)
@ -281,29 +281,65 @@ CursorSet::SetName(const char *name)
\return Name for the cursor specifier
*/
const char *
CursorSet::_CursorWhichToString(cursor_which which)
CursorSet::_CursorWhichToString(BCursorID which) const
{
switch (which) {
case B_CURSOR_DEFAULT:
return "Default";
case B_CURSOR_TEXT:
return "Text";
case B_CURSOR_MOVE:
case B_CURSOR_ID_SYSTEM_DEFAULT:
return "System default";
case B_CURSOR_ID_CONTEXT_MENU:
return "Context menu";
case B_CURSOR_ID_COPY:
return "Copy";
case B_CURSOR_ID_CROSS_HAIR:
return "Cross hair";
case B_CURSOR_ID_NO_CURSOR:
return "No cursor";
case B_CURSOR_ID_FOLLOW_LINK:
return "Follow link";
case B_CURSOR_ID_GRAB:
return "Grab";
case B_CURSOR_ID_GRABBING:
return "Grabbing";
case B_CURSOR_ID_HELP:
return "Help";
case B_CURSOR_ID_I_BEAM:
return "I-beam";
case B_CURSOR_ID_I_BEAM_HORIZONTAL:
return "I-beam horizontal";
case B_CURSOR_ID_MOVE:
return "Move";
case B_CURSOR_DRAG:
return "Drag";
case B_CURSOR_RESIZE:
return "Resize";
case B_CURSOR_RESIZE_NWSE:
return "Resize NWSE";
case B_CURSOR_RESIZE_NESW:
return "Resize NESW";
case B_CURSOR_RESIZE_NS:
return "Resize NS";
case B_CURSOR_RESIZE_EW:
return "Resize EW";
case B_CURSOR_OTHER:
return "Other";
case B_CURSOR_ID_NOT_ALLOWED:
return "Not allowed";
case B_CURSOR_ID_PROGRESS:
return "Progress";
case B_CURSOR_ID_RESIZE_NORTH:
return "Resize North";
case B_CURSOR_ID_RESIZE_EAST:
return "Resize East";
case B_CURSOR_ID_RESIZE_SOUTH:
return "Resize South";
case B_CURSOR_ID_RESIZE_WEST:
return "Resize West";
case B_CURSOR_ID_RESIZE_NORTH_EAST:
return "Resize North East";
case B_CURSOR_ID_RESIZE_NORTH_WEST:
return "Resize North West";
case B_CURSOR_ID_RESIZE_SOUTH_EAST:
return "Resize South East";
case B_CURSOR_ID_RESIZE_SOUTH_WEST:
return "Resize South West";
case B_CURSOR_ID_RESIZE_NORTH_SOUTH:
return "Resize North South";
case B_CURSOR_ID_RESIZE_EAST_WEST:
return "Resize East West";
case B_CURSOR_ID_RESIZE_NORTH_EAST_SOUTH_WEST:
return "Resize North East South West";
case B_CURSOR_ID_RESIZE_NORTH_WEST_SOUTH_EAST:
return "Resize North West South East";
case B_CURSOR_ID_ZOOM_IN:
return "Zoom in";
case B_CURSOR_ID_ZOOM_OUT:
return "Zoom out";
default:
return "Invalid";
}

View File

@ -27,16 +27,16 @@ class CursorSet : public BMessage {
status_t Save(const char *path,int32 saveflags=0);
status_t Load(const char *path);
status_t AddCursor(cursor_which which,const BBitmap *cursor, const BPoint &hotspot);
status_t AddCursor(cursor_which which, uint8 *data);
void RemoveCursor(cursor_which which);
status_t FindCursor(cursor_which which, BBitmap **cursor, BPoint *hotspot);
status_t FindCursor(cursor_which which, ServerCursor **cursor);
status_t AddCursor(BCursorID which,const BBitmap *cursor, const BPoint &hotspot);
status_t AddCursor(BCursorID which, uint8 *data);
void RemoveCursor(BCursorID which);
status_t FindCursor(BCursorID which, BBitmap **cursor, BPoint *hotspot);
status_t FindCursor(BCursorID which, ServerCursor **cursor) const;
void SetName(const char *name);
const char *GetName(void);
private:
const char *_CursorWhichToString(cursor_which which);
const char *_CursorWhichToString(BCursorID which) const;
BBitmap *_CursorDataToBitmap(uint8 *data);
};

View File

@ -473,7 +473,7 @@ void
Desktop::SetCursor(ServerCursor* newCursor)
{
if (newCursor == NULL)
newCursor = fCursorManager.GetCursor(B_CURSOR_DEFAULT);
newCursor = fCursorManager.GetCursor(B_CURSOR_ID_SYSTEM_DEFAULT);
HWInterface()->SetCursor(newCursor);
}

File diff suppressed because it is too large Load Diff

View File

@ -1,95 +0,0 @@
#ifndef HAIKU_SYSTEM_CURSOR_H
#define HAIKU_SYSTEM_CURSOR_H
#include <GraphicsDefs.h>
const uint32 kHaikuCursorWidth = 18;
const uint32 kHaikuCursorHeight = 18;
const color_space kHaikuCursorFormat = B_RGBA32;
const unsigned char kHaikuCursorBits[] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0xff,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0x1f,
0x00, 0x01, 0x01, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0x30, 0x00, 0x01, 0x01, 0x12, 0x00, 0x01, 0x01, 0x05,
0x00, 0x01, 0x01, 0x03, 0x00, 0x01, 0x01, 0x03, 0x00, 0x01, 0x01, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x10,
0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff,
0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0xff,
0x00, 0x01, 0x01, 0x10, 0x00, 0x01, 0x01, 0x08, 0x00, 0x01, 0x01, 0x03, 0x00, 0x01, 0x01, 0x02,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x08, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0xff,
0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0x10, 0x00, 0x01, 0x01, 0x07, 0x00, 0x01, 0x01, 0x01,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x02,
0x00, 0x01, 0x01, 0x12, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff,
0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff,
0x00, 0x01, 0x01, 0x1a, 0x00, 0x01, 0x01, 0x08, 0x00, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x0a, 0x00, 0x01, 0x01, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0x1a,
0x00, 0x01, 0x01, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0xff,
0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0x2e, 0x00, 0x01, 0x01, 0x10, 0x00, 0x01, 0x01, 0x02,
0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff,
0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0x37,
0x00, 0x01, 0x01, 0x15, 0x00, 0x01, 0x01, 0x02, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0x38, 0x00, 0x01, 0x01, 0x15, 0x00, 0x01, 0x01, 0x02,
0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0x38,
0x00, 0x01, 0x01, 0x15, 0x00, 0x01, 0x01, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x1f,
0x00, 0x01, 0x01, 0x2f, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0x38, 0x00, 0x01, 0x01, 0x15, 0x00, 0x01, 0x01, 0x02,
0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x08, 0x00, 0x01, 0x01, 0x12, 0x00, 0x01, 0x01, 0x1f,
0x00, 0x01, 0x01, 0x2f, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0xff, 0x00, 0x01, 0x01, 0x36,
0x00, 0x01, 0x01, 0x15, 0x00, 0x01, 0x01, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x01, 0x01, 0x03, 0x00, 0x01, 0x01, 0x08, 0x00, 0x01, 0x01, 0x12, 0x00, 0x01, 0x01, 0x1f,
0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x01, 0x46, 0x00, 0x01, 0x01, 0x3e,
0x00, 0x01, 0x01, 0x37, 0x00, 0x01, 0x01, 0x29, 0x00, 0x01, 0x01, 0x0f, 0x00, 0x01, 0x01, 0x02,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x01, 0x01, 0x03, 0x00, 0x01, 0x01, 0x09, 0x00, 0x01, 0x01, 0x1a, 0x00, 0x01, 0x01, 0x2e,
0x00, 0x01, 0x01, 0x37, 0x00, 0x01, 0x01, 0x38, 0x00, 0x01, 0x01, 0x38, 0x00, 0x01, 0x01, 0x37,
0x00, 0x01, 0x01, 0x2f, 0x00, 0x01, 0x01, 0x1f, 0x00, 0x01, 0x01, 0x16, 0x00, 0x01, 0x01, 0x0f,
0x00, 0x01, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01,
0x00, 0x01, 0x01, 0x07, 0x00, 0x01, 0x01, 0x10, 0x00, 0x01, 0x01, 0x15, 0x00, 0x01, 0x01, 0x16,
0x00, 0x01, 0x01, 0x16, 0x00, 0x01, 0x01, 0x15, 0x00, 0x01, 0x01, 0x10, 0x00, 0x01, 0x01, 0x08,
0x00, 0x01, 0x01, 0x03, 0x00, 0x01, 0x01, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x02,
0x00, 0x01, 0x01, 0x03, 0x00, 0x01, 0x01, 0x03, 0x00, 0x01, 0x01, 0x03, 0x00, 0x01, 0x01, 0x03,
0x00, 0x01, 0x01, 0x02, 0x00, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
#endif // HAIKU_SYSTEM_CURSOR_H