forked from AuroraMiddleware/gtk
Merge branch 'source-device-testinput' into 'gtk-3-24'
testinput: we must get the source of the source device See merge request GNOME/gtk!1938
This commit is contained in:
commit
85473d942c
@ -194,7 +194,7 @@ button_press_event (GtkWidget *widget, GdkEventButton *event)
|
||||
|
||||
print_axes (event->device, event->axes);
|
||||
gdk_event_get_axis ((GdkEvent *)event, GDK_AXIS_PRESSURE, &pressure);
|
||||
draw_brush (widget, gdk_device_get_source (event->device),
|
||||
draw_brush (widget, gdk_device_get_source (gdk_event_get_source_device (event)),
|
||||
event->x, event->y, pressure);
|
||||
|
||||
motion_time = event->time;
|
||||
@ -239,10 +239,10 @@ motion_notify_event (GtkWidget *widget, GdkEventMotion *event)
|
||||
gdk_device_get_axis (event->device, events[i]->axes, GDK_AXIS_X, &x);
|
||||
gdk_device_get_axis (event->device, events[i]->axes, GDK_AXIS_Y, &y);
|
||||
gdk_device_get_axis (event->device, events[i]->axes, GDK_AXIS_PRESSURE, &pressure);
|
||||
draw_brush (widget, gdk_device_get_source (event->device),
|
||||
draw_brush (widget, gdk_device_get_source (gdk_event_get_source_device (event)),
|
||||
x, y, pressure);
|
||||
|
||||
print_axes (event->device, events[i]->axes);
|
||||
print_axes (gdk_event_get_source_device (event), events[i]->axes);
|
||||
}
|
||||
gdk_device_free_history (events, n_events);
|
||||
}
|
||||
@ -252,7 +252,7 @@ motion_notify_event (GtkWidget *widget, GdkEventMotion *event)
|
||||
|
||||
gdk_event_get_axis ((GdkEvent *)event, GDK_AXIS_PRESSURE, &pressure);
|
||||
|
||||
draw_brush (widget, gdk_device_get_source (event->device),
|
||||
draw_brush (widget, gdk_device_get_source (gdk_event_get_source_device (event)),
|
||||
event->x, event->y, pressure);
|
||||
}
|
||||
motion_time = event->time;
|
||||
|
Loading…
Reference in New Issue
Block a user