meta-wayland-pointer: Remove the surface->window conditional

This commit is contained in:
Adel Gadllah 2014-04-25 20:38:24 +02:00
parent f051e05b0a
commit 657318d4d3

View File

@ -719,17 +719,14 @@ meta_wayland_pointer_get_relative_coordinates (MetaWaylandPointer *pointer,
{ {
float xf = 0.0f, yf = 0.0f; float xf = 0.0f, yf = 0.0f;
if (surface->window) ClutterActor *actor = CLUTTER_ACTOR (surface->surface_actor);
if (actor)
{ {
ClutterActor *actor = CLUTTER_ACTOR (surface->surface_actor); ClutterPoint pos;
clutter_input_device_get_coords (pointer->device, NULL, &pos);
if (actor) clutter_actor_transform_stage_point (actor, pos.x, pos.y, &xf, &yf);
{
ClutterPoint pos;
clutter_input_device_get_coords (pointer->device, NULL, &pos);
clutter_actor_transform_stage_point (actor, pos.x, pos.y, &xf, &yf);
}
} }
*sx = wl_fixed_from_double (xf); *sx = wl_fixed_from_double (xf);