From 3e272f6797494d87c1d9c2c3a5220065736525d7 Mon Sep 17 00:00:00 2001 From: Matt Ebb Date: Mon, 19 Jun 2006 04:04:31 +0000 Subject: * Patch from Ed Halley: "Swaps left and right bytes of small cursors for Carbon on Intel." This fixes garbled cursors on Intel Mac builds. Tested on my G4 too and it works fine. --- intern/ghost/intern/GHOST_WindowCarbon.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'intern') diff --git a/intern/ghost/intern/GHOST_WindowCarbon.cpp b/intern/ghost/intern/GHOST_WindowCarbon.cpp index 5ddacd5f21f..30c88ccd777 100644 --- a/intern/ghost/intern/GHOST_WindowCarbon.cpp +++ b/intern/ghost/intern/GHOST_WindowCarbon.cpp @@ -690,8 +690,14 @@ GHOST_TSuccess GHOST_WindowCarbon::setWindowCustomCursorShape(GHOST_TUns8 *bitma if (!m_customCursor) return GHOST_kFailure; for (y=0; y<16; y++) { +#if !defined(__LITTLE_ENDIAN__) m_customCursor->data[y] = uns16ReverseBits((bitmap[2*y]<<0) | (bitmap[2*y+1]<<8)); m_customCursor->mask[y] = uns16ReverseBits((mask[2*y]<<0) | (mask[2*y+1]<<8)); +#else + m_customCursor->data[y] = uns16ReverseBits((bitmap[2*y+1]<<0) | (bitmap[2*y]<<8)); + m_customCursor->mask[y] = uns16ReverseBits((mask[2*y+1]<<0) | (mask[2*y]<<8)); +#endif + } m_customCursor->hotSpot.h = hotX; -- cgit v1.2.3