-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
kinetic-scroll-view: Various fixes for the motion buffer #98
base: master
Are you sure you want to change the base?
Commits on Sep 22, 2015
-
kinetic-scroll-view: Handle ClutterTimeline:stopped not :completed
The former is always emitted when the timeline stops (either due to reaching its duration, or due to clutter_timeline_stop() being called); the latter is only emitted in the first case. Changing signals means we can eliminate manual cleanup code after calls to clutter_timeline_stop(). clutter-project#98
Philip Withnall committedSep 22, 2015 Configuration menu - View commit details
-
Copy full SHA for a3ea35b - Browse repository at this point
Copy the full SHA a3ea35bView commit details -
kinetic-scroll-view: Grow the motion buffer over time
The motion buffer contains a history of motion events for the current scrolling action, starting from the initial touch event. This is used at the release of the scroll to work out an average origin coordinate, which is then used in the calculation of whether to use kinetic scrolling. Previously, the oldest entry in the motion buffer was removed if the buffer filled up, then the buffer was expanded in size. This meant that for scrolling actions with many motion events, the average taken over the events would quickly creep towards the location of the most recent motion event. This meant that, often, the threshold for starting a kinetic scroll was not reached, and hence kinetic scrolling would not happen. Stop removing the oldest entry from the buffer, and instead grow it indefinitely. This does make the widget prone to consuming all the system’s memory if the user scrolls around for a _very_ long time. This may be better fixed by calculating a moving average instead, and eliminating the motion buffer. clutter-project#98
Philip Withnall committedSep 22, 2015 Configuration menu - View commit details
-
Copy full SHA for f1322a7 - Browse repository at this point
Copy the full SHA f1322a7View commit details -
kinetic-scroll-view: Add more debug output
Philip Withnall committedSep 22, 2015 Configuration menu - View commit details
-
Copy full SHA for 66bf2f4 - Browse repository at this point
Copy the full SHA 66bf2f4View commit details -
kinetic-scroll-view: Replace motion buffer with a moving average
The motion buffer stored each motion event which happened in a sequence (for example, a single swipe) on the kinetic scroll view, in order that the average event coordinates and time could be computed at the end of the sequence (on releasing the touchscreen). This could lead to problems with very long event sequences — potentially allocating a huge event array and leading to allocation failure. Avoid that by computing the average of the events as they are received. clutter-project#98
Philip Withnall committedSep 22, 2015 Configuration menu - View commit details
-
Copy full SHA for a5610ad - Browse repository at this point
Copy the full SHA a5610adView commit details -
kinetic-scroll-view: Use gint64 for timestamps rather than GTimeVal
GTimeVal is a pain to use and the use of glong means the potential for overflow when summing several timestamps on 32-bit platforms is quite high. Instead, use gint64 and g_get_real_time(). clutter-project#98
Philip Withnall committedSep 22, 2015 Configuration menu - View commit details
-
Copy full SHA for 50b91be - Browse repository at this point
Copy the full SHA 50b91beView commit details -
kinetic-scroll-view: Include timestamps in debug messages
This makes debugging problems in the MxKineticScrollView a lot easier. Note that _KINETIC_DEBUG must be defined to enable debug messages. clutter-project#98
Philip Withnall committedSep 22, 2015 Configuration menu - View commit details
-
Copy full SHA for 60fc20e - Browse repository at this point
Copy the full SHA 60fc20eView commit details