Bug 411273 - Switch busy/wait cursor on OS X to use the system's busyButClickableCursor. r=smichaud
authorJosiah Bruner <josiah@programmer.net>
Tue, 14 Jan 2014 09:36:41 -0500
changeset 163588 12ec0bd6b782bbea922a4735a0f43c4f997e65b8
parent 163587 5f9f55f174e7923384a7fd7c505fbabf0d9edcbf
child 163589 a0b1c4cf207a6ee001773c6d44120f467a394503
push id26002
push userryanvm@gmail.com
push dateWed, 15 Jan 2014 19:34:12 +0000
treeherdermozilla-central@09a8ed7cbb0b [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssmichaud
bugs411273
milestone29.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 411273 - Switch busy/wait cursor on OS X to use the system's busyButClickableCursor. r=smichaud
widget/cocoa/cursors/spin1.png
widget/cocoa/cursors/spin2.png
widget/cocoa/cursors/spin3.png
widget/cocoa/cursors/spin4.png
widget/cocoa/nsCursorManager.h
widget/cocoa/nsCursorManager.mm
deleted file mode 100644
index 4b632bbb200e107c17bd735194effac1b6193931..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
GIT binary patch
literal 0
Hc$@<O00001
deleted file mode 100644
index f9a1fc144bafacbae5ec38a330d65798c6c73184..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
GIT binary patch
literal 0
Hc$@<O00001
deleted file mode 100644
index fc0875f3206fd33aa1bb12c6b91129371278f18d..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
GIT binary patch
literal 0
Hc$@<O00001
deleted file mode 100644
index fd2983afb667a83f49418f668ab174e761bb7d74..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
GIT binary patch
literal 0
Hc$@<O00001
--- a/widget/cocoa/nsCursorManager.h
+++ b/widget/cocoa/nsCursorManager.h
@@ -51,9 +51,15 @@
 
 /*! @method     dispose
     @abstract   Releases the shared instance of the cursor manager.
     @discussion Use dispose to clean up the cursor manager and associated cursors.
 */
 + (void) dispose;
 @end
 
+@interface NSCursor (Undocumented)
+// busyButClickableCursor is an undocumented NSCursor API, but has been in use since
+// at least OS X 10.4 and through 10.9.
++ (NSCursor*)busyButClickableCursor;
+@end
+
 #endif // nsCursorManager_h_
--- a/widget/cocoa/nsCursorManager.mm
+++ b/widget/cocoa/nsCursorManager.mm
@@ -77,22 +77,17 @@ static const nsCursor sCustomCursor = eC
   switch(aCursor)
   {
     SEL cursorSelector;
     case eCursor_standard:
       return [nsMacCursor cursorWithCursor:[NSCursor arrowCursor] type:aCursor];
     case eCursor_wait:
     case eCursor_spinning:
     {
-      NSCursor* cursor1 = [nsMacCursor cocoaCursorWithImageNamed:@"spin1" hotSpot:NSMakePoint(1.0, 1.0)];
-      NSCursor* cursor2 = [nsMacCursor cocoaCursorWithImageNamed:@"spin2" hotSpot:NSMakePoint(1.0, 1.0)];
-      NSCursor* cursor3 = [nsMacCursor cocoaCursorWithImageNamed:@"spin3" hotSpot:NSMakePoint(1.0, 1.0)];
-      NSCursor* cursor4 = [nsMacCursor cocoaCursorWithImageNamed:@"spin4" hotSpot:NSMakePoint(1.0, 1.0)];
-      NSArray* spinCursorFrames = [[[NSArray alloc] initWithObjects:cursor1, cursor2, cursor3, cursor4, nil] autorelease];
-      return [nsMacCursor cursorWithFrames:spinCursorFrames type:aCursor];
+      return [nsMacCursor cursorWithCursor:[NSCursor busyButClickableCursor] type:aCursor];
     }
     case eCursor_select:
       return [nsMacCursor cursorWithCursor:[NSCursor IBeamCursor] type:aCursor];
     case eCursor_hyperlink:
       return [nsMacCursor cursorWithCursor:[NSCursor pointingHandCursor] type:aCursor];
     case eCursor_crosshair:
       return [nsMacCursor cursorWithCursor:[NSCursor crosshairCursor] type:aCursor];
     case eCursor_move: