After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 697522 - While the get_scroll_delta function is well introspected, it is not accessible from a child class of ClutterEvent.
While the get_scroll_delta function is well introspected, it is not accessibl...
Status: RESOLVED NOTABUG
Product: clutter
Classification: Platform
Component: ClutterStage
1.12.x
Other Linux
: Normal normal
: ---
Assigned To: clutter-maint
clutter-maint
Depends on:
Blocks:
 
 
Reported: 2013-04-08 00:08 UTC by Mathieu Duponchelle
Modified: 2014-03-09 23:07 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Mathieu Duponchelle 2013-04-08 00:08:46 UTC
In ipython, do this to reproduce:
Clutter.ScrollEvent.get<tab>

No result shows up, I have a brand new fedora 18 installation with clutter 1.12.

Have a nice day :)
Comment 1 Emmanuele Bassi (:ebassi) 2013-04-08 10:22:58 UTC
clutter_event_get_scroll_delta() takes a ClutterEvent by design, like all the clutter_event_* methods. you're supposed to use a Clutter.Event, not the "subclasses" — especially from a higher language perspective: the "subclasses" are mostly an artefact of the C API.
Comment 2 Mathieu Duponchelle 2013-04-08 12:30:31 UTC
Except that the "scroll-event" signal sends me a ScrollEvent.
Comment 3 Emmanuele Bassi (:ebassi) 2013-04-08 15:03:10 UTC
strictly speaking, it's sending you a pointer to a ClutterEvent, and taking advantage of the memory layout of the ClutterEvent structure, you can cast it to a ClutterScrollEvent.

in Python, you can assume you're getting a Clutter.Event, not a ScrollEvent.
Comment 4 Mathieu Duponchelle 2013-04-09 17:48:59 UTC
I understand how inheriting works in C :)

http://paste.fedoraproject.org/7011/52952013

this script illustrates the problem, which probably arises from the fact that ClutterScrollEvent et al. are Boxed types.
Comment 5 Mathieu Duponchelle 2013-04-09 17:55:01 UTC
The annotations are wrong by the way :

 * @event: (type ClutterScrollEvent): a #ClutterScrollEvent
Comment 6 Mathieu Duponchelle 2014-03-09 23:07:35 UTC
Hey, not sure why that bug was closed as NOTABUG ?