Modified: trunk/Source/WebCore/platform/mac/CursorMac.mm (96776 => 96777)
--- trunk/Source/WebCore/platform/mac/CursorMac.mm 2011-10-06 00:51:56 UTC (rev 96776)
+++ trunk/Source/WebCore/platform/mac/CursorMac.mm 2011-10-06 00:56:43 UTC (rev 96777)
@@ -79,21 +79,25 @@
case Cursor::Pointer:
m_platformCursor = [NSCursor arrowCursor];
break;
+
case Cursor::Cross:
m_platformCursor = [NSCursor crosshairCursor];
break;
+
case Cursor::Hand:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
m_platformCursor = [NSCursor pointingHandCursor];
#else
// The pointingHandCursor from NSCursor does not have a shadow on
- // older versions of Mac OS X, so use our own custom cursor.
+ // older versions of OS X, so use our own custom cursor.
m_platformCursor = createNamedCursor("linkCursor", 6, 1);
#endif
break;
+
case Cursor::IBeam:
m_platformCursor = [NSCursor IBeamCursor];
break;
+
case Cursor::Wait:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
m_platformCursor = wkCursor("BusyButClickable");
@@ -101,9 +105,16 @@
m_platformCursor = createNamedCursor("waitCursor", 7, 7);
#endif
break;
+
case Cursor::Help:
+#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
+ m_platformCursor = wkCursor("Help");
+ if (m_platformCursor)
+ break;
+#endif
m_platformCursor = createNamedCursor("helpCursor", 8, 8);
break;
+
case Cursor::Move:
case Cursor::MiddlePanning:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
@@ -112,6 +123,7 @@
m_platformCursor = createNamedCursor("moveCursor", 7, 7);
#endif
break;
+
case Cursor::EastResize:
case Cursor::EastPanning:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
@@ -120,6 +132,7 @@
m_platformCursor = createNamedCursor("eastResizeCursor", 14, 7);
#endif
break;
+
case Cursor::NorthResize:
case Cursor::NorthPanning:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
@@ -128,6 +141,7 @@
m_platformCursor = createNamedCursor("northResizeCursor", 7, 1);
#endif
break;
+
case Cursor::NorthEastResize:
case Cursor::NorthEastPanning:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
@@ -136,6 +150,7 @@
m_platformCursor = createNamedCursor("northEastResizeCursor", 14, 1);
#endif
break;
+
case Cursor::NorthWestResize:
case Cursor::NorthWestPanning:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
@@ -144,6 +159,7 @@
m_platformCursor = createNamedCursor("northWestResizeCursor", 0, 0);
#endif
break;
+
case Cursor::SouthResize:
case Cursor::SouthPanning:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
@@ -152,6 +168,7 @@
m_platformCursor = createNamedCursor("southResizeCursor", 7, 14);
#endif
break;
+
case Cursor::SouthEastResize:
case Cursor::SouthEastPanning:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
@@ -160,6 +177,7 @@
m_platformCursor = createNamedCursor("southEastResizeCursor", 14, 14);
#endif
break;
+
case Cursor::SouthWestResize:
case Cursor::SouthWestPanning:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
@@ -168,6 +186,7 @@
m_platformCursor = createNamedCursor("southWestResizeCursor", 1, 14);
#endif
break;
+
case Cursor::WestResize:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
m_platformCursor = wkCursor("ResizeWest");
@@ -175,6 +194,7 @@
m_platformCursor = createNamedCursor("westResizeCursor", 1, 7);
#endif
break;
+
case Cursor::NorthSouthResize:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
m_platformCursor = wkCursor("ResizeNorthSouth");
@@ -182,6 +202,7 @@
m_platformCursor = createNamedCursor("northSouthResizeCursor", 7, 7);
#endif
break;
+
case Cursor::EastWestResize:
case Cursor::WestPanning:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
@@ -190,6 +211,7 @@
m_platformCursor = createNamedCursor("eastWestResizeCursor", 7, 7);
#endif
break;
+
case Cursor::NorthEastSouthWestResize:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
m_platformCursor = wkCursor("ResizeNortheastSouthwest");
@@ -197,6 +219,7 @@
m_platformCursor = createNamedCursor("northEastSouthWestResizeCursor", 7, 7);
#endif
break;
+
case Cursor::NorthWestSouthEastResize:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
m_platformCursor = wkCursor("ResizeNorthwestSoutheast");
@@ -204,12 +227,15 @@
m_platformCursor = createNamedCursor("northWestSouthEastResizeCursor", 7, 7);
#endif
break;
+
case Cursor::ColumnResize:
m_platformCursor = [NSCursor resizeLeftRightCursor];
break;
+
case Cursor::RowResize:
m_platformCursor = [NSCursor resizeUpDownCursor];
break;
+
case Cursor::VerticalText:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
m_platformCursor = [NSCursor IBeamCursorForVerticalLayout];
@@ -217,9 +243,16 @@
m_platformCursor = createNamedCursor("verticalTextCursor", 7, 7);
#endif
break;
+
case Cursor::Cell:
+#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
+ m_platformCursor = wkCursor("Cell");
+ if (m_platformCursor)
+ break;
+#endif
m_platformCursor = createNamedCursor("cellCursor", 7, 7);
break;
+
case Cursor::ContextMenu:
#if !defined(BUILDING_ON_LEOPARD)
m_platformCursor = [NSCursor contextualMenuCursor];
@@ -227,6 +260,7 @@
m_platformCursor = createNamedCursor("contextMenuCursor", 3, 2);
#endif
break;
+
case Cursor::Alias:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
m_platformCursor = wkCursor("MakeAlias");
@@ -234,6 +268,7 @@
m_platformCursor = createNamedCursor("aliasCursor", 11, 3);
#endif
break;
+
case Cursor::Progress:
#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
m_platformCursor = wkCursor("BusyButClickable");
@@ -241,6 +276,7 @@
m_platformCursor = createNamedCursor("progressCursor", 3, 2);
#endif
break;
+
case Cursor::NoDrop:
#if !defined(BUILDING_ON_LEOPARD)
m_platformCursor = [NSCursor operationNotAllowedCursor];
@@ -248,6 +284,7 @@
m_platformCursor = createNamedCursor("noDropCursor", 3, 1);
#endif
break;
+
case Cursor::Copy:
#if !defined(BUILDING_ON_LEOPARD)
m_platformCursor = [NSCursor dragCopyCursor];
@@ -255,9 +292,11 @@
m_platformCursor = createNamedCursor("copyCursor", 3, 2);
#endif
break;
+
case Cursor::None:
m_platformCursor = createNamedCursor("noneCursor", 7, 7);
break;
+
case Cursor::NotAllowed:
#if !defined(BUILDING_ON_LEOPARD)
m_platformCursor = [NSCursor operationNotAllowedCursor];
@@ -265,18 +304,33 @@
m_platformCursor = createNamedCursor("notAllowedCursor", 11, 11);
#endif
break;
+
case Cursor::ZoomIn:
+#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
+ m_platformCursor = wkCursor("ZoomIn");
+ if (m_platformCursor)
+ break;
+#endif
m_platformCursor = createNamedCursor("zoomInCursor", 7, 7);
break;
+
case Cursor::ZoomOut:
+#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
+ m_platformCursor = wkCursor("ZoomOut");
+ if (m_platformCursor)
+ break;
+#endif
m_platformCursor = createNamedCursor("zoomOutCursor", 7, 7);
break;
+
case Cursor::Grab:
m_platformCursor = [NSCursor openHandCursor];
break;
+
case Cursor::Grabbing:
m_platformCursor = [NSCursor closedHandCursor];
break;
+
case Cursor::Custom:
m_platformCursor = createCustomCursor(m_image.get(), m_hotSpot);
break;