Modified Return key presses don't trigger ::activate so we would end
up adding an unprintable character to a single paragraph mode pango
layout which renders it as a box.
https://bugzilla.gnome.org/show_bug.cgi?id=623344
The code for calculating the content box when the aspect ratio is
greater than 1 was broken. The same code that did the calculation for
aspect ratio less than 1 should be used in all cases.
Fixes: https://bugzilla.gnome.org/682161
When we miss button release events (eg. when they happen outside
of our window) we must ensure that the corresponding point is
removed from the array of tracked points, otherwise GestureAction
will get very confused and will cancel all subsequent gestures.
https://bugzilla.gnome.org/show_bug.cgi?id=683471
When starting a new gesture before the momentum of the previous one
has finished the ::pan-stopped was counter-intuitively emitted
after the new ::gesture-begin.
Make use of gesture_prepare() to reset the state of the action
right before emitting ::gesture-begin.
https://bugzilla.gnome.org/show_bug.cgi?id=683431
We often mean that when key_focus == NULL, it's assumed to be on the
stage, and clutter_stage_get_key_focus() reflects this. We also do a
lot of check around the lines of key_focus == NULL instead of also
checking for the stage, so make sure to normalize it so that explicitly
grabbing the stage's key focus will not change our behaviour.
https://bugzilla.gnome.org/show_bug.cgi?id=683301
The ClutterEventSequence structure is a fully opaque type; on X11, it is
just an unsigned integer that gets converted into a pointer, but in the
future it may become a fully fledged data structure.
Obviously, we cannot tell people to just dereference the pointer into an
integer in order to use it, and still retain the ability to change the
type; for this reason, we need a proper accessor function to convert the
EventSequence into a touch detail, to be used with the XInput API.
The ordering of the evdev button numbers is the opposite of the
order in Clutter (the middle button is 3 instead of 2) so we need to
manually map the button numbers when creating a ClutterButtonEvent.
https://bugzilla.gnome.org/show_bug.cgi?id=680255
803b3bafb6 introduced a new issue for
multi touch events.
In the case where 2 touch events for 2 different touch points are
processed in the same iteration, a call to
_clutter_stage_remove_device() when processing the first event will
remove the stage setting of the InputDevice. That means Clutter will
skip the second event, because it can't find a stage to which relate
the event, so no related actor and so no emission.
To fix this we move the _clutter_stage_(add/remove)_device() calls
into the input device. This way the input device can find out exactly
when to call these functions (i.e. when no touch point were previously
active or when no touch point remain active).
https://bugzilla.gnome.org/show_bug.cgi?id=682362
Interpolating between two transformations expressed using a 3D matrix
can be achieved by decomposing the matrices into their transformations
and do a simple numeric interpolation between the initial and final
states, like we do for other data types.
Luckily for us, the CSS Transforms specification from the W3C provides
the decomposition algorithm, using the "unmatrix" code taken from the
book "Graphics Gems II, edited by Jim Arvo".
Once the matrices have been decomposed, we can simply interpolate the
transformations, and re-apply them onto the result matrix, using the
facilities that Clutter provides for interpolating between two known
GTypes.
Since Cogl version 1.11.2, Cogl no longer includes the EGL headers
from cogl.h if COGL_ENABLE_EXPERIMENTAL_2_0_API is defined. Instead
the application needs to include cogl-egl.h so that we can avoid
polluting the global namespace with X defines. Clutter defines the 2.0
define in its configure.ac and it is relying on Cogl to include the
right EGL header in clutter-egl-headers.h so we need to change which
header it includes.
When changing an implicit transition mid flight we may end up with an
easing state with a duration of zero milliseconds; this leads to the
implicit transition machinery setting the final state directly onto the
actor. If there is a running transition, though, we need to remove it
from the transitions table, otherwise it will keep running.
This regression happened when the update_transition() internal function
was merged into the create_transition() one.
Tested-by: Lionel Landwerlin <llandwerlin@gmail.com>
PanAction is a GestureAction-subclass that implements the panning
concept for scrollable actors, with the ability to emit interpolated
signals to emulate the kinetic inertia of the panning. PanAction provides:
• pan signal, notifying users of the panning gesture status;
• pan-stopped signal, emitted at the end of the interpolated phase
of the panning gesture, if enabled;
• pan-axis property, to allow constraining the dragging to a specific
axis;
• interpolated property, to enable or disable the inertial behaviour;
• deceleration property, to customize the rate at which the momentum
of the panning will be slowed down;
• acceleration-factor property, applied to the inertial momentum when
starting the interpolated sequence.
An interactive test is also provided.
https://bugzilla.gnome.org/show_bug.cgi?id=681648
Add some accessors to simplify common tasks for GestureAction users:
• clutter_gesture_action_get_motion_delta() to get the delta
on the X and Y axis in stage coordinates since the last motion
event, and the scalar distance travelled;
• clutter_gesture_action_get_velocity() to get an estimate of the
speed of the last motion event along the X and Y axis and as a
scalar value in pixels per millisecond.
https://bugzilla.gnome.org/show_bug.cgi?id=681648