gesture: Make gtk_gesture_get_last_update_time() private

This commit is contained in:
Carlos Garnacho 2014-05-06 18:22:57 +02:00
parent 83d5795154
commit 44a960199b
5 changed files with 10 additions and 25 deletions

View File

@ -7936,7 +7936,6 @@ gtk_gesture_detach
<SUBSECTION>
gtk_gesture_get_last_updated_sequence
gtk_gesture_get_last_update_time
gtk_gesture_get_last_event
gtk_gesture_get_point
gtk_gesture_get_bounding_box

View File

@ -993,22 +993,8 @@ gtk_gesture_get_point (GtkGesture *gesture,
return TRUE;
}
/**
* gtk_gesture_get_last_update_time:
* @gesture: a #GtkGesture
* @sequence: (allow-none): a #GdkEventSequence, or %NULL for pointer events
* @evtime: (out) (allow-none): return location for last update time
*
* If @sequence is being interpreted by @gesture, this function
* returns %TRUE and fills @evtime with the last event time it
* received from that @sequence.
*
* Returns: %TRUE if @sequence is currently interpreted
*
* Since: 3.14
**/
gboolean
gtk_gesture_get_last_update_time (GtkGesture *gesture,
_gtk_gesture_get_last_update_time (GtkGesture *gesture,
GdkEventSequence *sequence,
guint32 *evtime)
{

View File

@ -76,11 +76,6 @@ gboolean gtk_gesture_get_point (GtkGesture *gesture,
gdouble *x,
gdouble *y);
GDK_AVAILABLE_IN_3_14
gboolean gtk_gesture_get_last_update_time (GtkGesture *gesture,
GdkEventSequence *sequence,
guint32 *evtime);
GDK_AVAILABLE_IN_3_14
gboolean gtk_gesture_get_bounding_box (GtkGesture *gesture,
GdkRectangle *rect);
GDK_AVAILABLE_IN_3_14

View File

@ -66,6 +66,10 @@ gboolean _gtk_gesture_get_pointer_emulating_sequence
gboolean _gtk_gesture_cancel_sequence (GtkGesture *gesture,
GdkEventSequence *sequence);
gboolean _gtk_gesture_get_last_update_time (GtkGesture *gesture,
GdkEventSequence *sequence,
guint32 *evtime);
G_END_DECLS
#endif /* __GTK_GESTURE_PRIVATE_H__ */

View File

@ -38,6 +38,7 @@
#include "config.h"
#include "gtkgestureswipe.h"
#include "gtkgestureswipeprivate.h"
#include "gtkgestureprivate.h"
#include "gtkmarshalers.h"
#define CAPTURE_THRESHOLD_MS 150
@ -112,7 +113,7 @@ gtk_gesture_swipe_update (GtkGesture *gesture,
gdouble x, y;
priv = gtk_gesture_swipe_get_instance_private (swipe);
gtk_gesture_get_last_update_time (gesture, sequence, &new.evtime);
_gtk_gesture_get_last_update_time (gesture, sequence, &new.evtime);
gtk_gesture_get_point (gesture, sequence, &x, &y);
new.point.x = x;
@ -137,7 +138,7 @@ _gtk_gesture_swipe_calculate_velocity (GtkGestureSwipe *gesture,
*velocity_x = *velocity_y = 0;
sequence = gtk_gesture_single_get_current_sequence (GTK_GESTURE_SINGLE (gesture));
gtk_gesture_get_last_update_time (GTK_GESTURE (gesture), sequence, &evtime);
_gtk_gesture_get_last_update_time (GTK_GESTURE (gesture), sequence, &evtime);
_gtk_gesture_swipe_clear_backlog (gesture, evtime);
if (priv->events->len == 0)