Protect sectond call of nsevent hasPreciseScrollingDeltas from pre-Lion

This commit is contained in:
John Ralls 2012-09-03 16:56:46 -07:00
parent fa029fd787
commit f2ab3af20a

View File

@ -1386,7 +1386,8 @@ gdk_event_translate (GdkEvent *event,
if (dx != 0.0 || dy != 0.0)
{
if ([nsevent hasPreciseScrollingDeltas])
#ifdef AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
if (gdk_quartz_osx_version() >= GDK_OSX_LION &[nsevent hasPreciseScrollingDeltas])
{
GdkEvent *emulated_event;
@ -1398,6 +1399,7 @@ gdk_event_translate (GdkEvent *event,
append_event (emulated_event, TRUE);
}
else
#endif
fill_scroll_event (window, event, nsevent,
x, y, x_root, y_root,
dx, dy, direction);