Use GTK cursors for zoom-in or zoom-out css cursors (
bug 1328724)
get_gtk_cursor attempts to use themed cursor icons for most css cursor types,
but left these two out. Now it will try to use the theme for these as well,
and fall back to the generic FF set used previously.
MozReview-Commit-ID: 9QHV0mc5AxK
--- a/widget/gtk/nsWindow.cpp
+++ b/widget/gtk/nsWindow.cpp
@@ -5190,20 +5190,24 @@ get_gtk_cursor(nsCursor aCursor)
newType = MOZ_CURSOR_HAND_GRABBING;
break;
case eCursor_spinning:
gdkcursor = gdk_cursor_new_from_name(defaultDisplay, "progress");
if (!gdkcursor)
newType = MOZ_CURSOR_SPINNING;
break;
case eCursor_zoom_in:
- newType = MOZ_CURSOR_ZOOM_IN;
+ gdkcursor = gdk_cursor_new_from_name(defaultDisplay, "zoom-in");
+ if (!gdkcursor)
+ newType = MOZ_CURSOR_ZOOM_IN;
break;
case eCursor_zoom_out:
- newType = MOZ_CURSOR_ZOOM_OUT;
+ gdkcursor = gdk_cursor_new_from_name(defaultDisplay, "zoom-out");
+ if (!gdkcursor)
+ newType = MOZ_CURSOR_ZOOM_OUT;
break;
case eCursor_not_allowed:
gdkcursor = gdk_cursor_new_from_name(defaultDisplay, "not-allowed");
if (!gdkcursor) // nonstandard, yet common
gdkcursor = gdk_cursor_new_from_name(defaultDisplay, "crossed_circle");
if (!gdkcursor)
newType = MOZ_CURSOR_NOT_ALLOWED;
break;