Commit Graph

28 Commits

Author SHA1 Message Date
Emmanuele Bassi
b0446d66fe 2007-11-23 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/clutter-event.h: Add more documentation.
2007-11-23 17:07:46 +00:00
Emmanuele Bassi
07079204ac 2007-11-23 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/clutter-actor.c:
	* clutter/clutter-alpha.c:
	* clutter/clutter-effect.c:
	* clutter/clutter-event.c:
	* clutter/clutter-event.h:
	* clutter/clutter-group.h:
	* clutter/clutter-model.c:,
	* clutter/clutter-script.c:
	* clutter/clutter-scriptable.h:
	* clutter/clutter-stage.c: Documentation fixes.

	* clutter/clutter-score.c: Fix implementation.
2007-11-23 13:11:10 +00:00
Øyvind Kolås
95338ba67b * clutter/clutter-event.h: made ClutterEventAny have a source field,
rearanged other structs to have source in the same position.
* clutter/clutter-event.c: (clutter_event_get_source): modified to use
the any event.
(clutter_event_free): removed unused variable.
* clutter/clutter-main.c: (deliver_event), (clutter_do_event): reduced
amount of code. As well as deliver button-release events to the stage.
2007-11-12 19:12:02 +00:00
Matthew Allum
dd99f024bf 2007-10-15 Matthew Allum <mallum@openedhand.com>
* clutter/clutter-actor.c:
        More events documentation.

        * clutter/clutter-event.c:
        * clutter/clutter-event.h:
        Add synthetic flag and make put_event use it
        (via modded patch from pippin)

        * clutter/clutter-main.c: (clutter_do_event):
        dont use put event anymore when pushing enter/leave events.
2007-10-15 16:50:59 +00:00
Matthew Allum
bc13e907cc 2007-10-03 Matthew Allum <mallum@openedhand.com>
* clutter/clutter-actor.c:
        * clutter/clutter-event.c:
        * clutter/clutter-event.h:
        * clutter/clutter-main.c:
        * clutter/clutter-private.h:
        * clutter/eglnative/clutter-event-egl.c:
        * clutter/eglx/clutter-event-egl.c:
        * clutter/glx/clutter-event-glx.c:
        * clutter/sdl/clutter-event-sdl.c:
        Remove seperate double/triple click events and replace with
        a click_count member.
        Move calculating click counts from backend to do_event()
        Initial implementation of ENTER/LEAVE events.

        * tests/test-events.c:
        Add code to test above.

        * tests/test-behave.c:
        Sync with newer API.

        * clutter/clutter-score.c:
        Silence a warning.
2007-10-03 09:28:16 +00:00
Matthew Allum
956f6b6238 2007-09-30 Matthew Allum <mallum@openedhand.com>
* clutter/clutter-event.h:
        Removed unused POINTER_ENTER and POINTER_LEAVE states. (#546)
        * clutter/clutter-stage.c: (clutter_stage_fullscreen),
        (clutter_stage_unfullscreen):
        Only Change fullscreen prop if the backend implements fullscreen
        methods. (#545)
2007-09-30 22:27:52 +00:00
Matthew Allum
5ab0ed5a00 2007-09-27 Matthew Allum <mallum@openedhand.com>
* clutter/clutter-event.c:
        * clutter/clutter-event.h:
        * clutter/clutter-main.c:
        Further event tweaks;
        - Ref the event actor source
        - Protect against off stage events (button releases)
        - Move more into ClutterEventAny
        - Add a click count to button event (as yet unused)
        - Minor cleanups

        * clutter/clutter-actor.c:
        Make scale x/y a property.

        * clutter/clutter-private.h:
        Remove _clutter_actor_apply_modelview*

        * clutter/eglx/clutter-backend-egl.c:
        Warning cleanup

        * clutter/eglx/clutter-stage-egl.c:
        * clutter/glx/clutter-stage-glx.c:
        * clutter/sdl/clutter-stage-sdl.c:
        Avoid setting viewport directly, but set sync flag.

        * clutter/pango/pangoclutter-render.c: (draw_glyph):
        Minor cleanups.

        * clutter/Makefile.am:
        * tests/Makefile.am:
        * tests/test-score.c
        * clutter/clutter.h:
        * clutter/clutter-score.h:
        * clutter/clutter-score.c:
        Add very initial (broken) ClutterScore implementation.
2007-09-27 21:38:38 +00:00
Matthew Allum
1ceaf04ac7 2007-08-24 Matthew Allum <mallum@openedhand.com>
* clutter/clutter-actor.c:
        * clutter/clutter-event.h:
        * clutter/clutter-main.c:
        * clutter/clutter-stage.c:
        * clutter/clutter-stage.h:
        * clutter/glx/clutter-backend-glx.c:
        * clutter/glx/clutter-backend-glx.h:
        * clutter/glx/clutter-event-glx.c:
        * clutter/glx/clutter-stage-glx.c:
        * clutter/glx/clutter-stage-glx.h:
        Add initial support for stage state events.
        Fix fullscreening for an already mapped stage.

        * tests/test-events.c:
        Print out info from the above. Blue button now toggles
        fullscreen.

        * clutter/clutter-effect.c:
        * clutter/clutter-effect.h:
        Add a setting for templates to ref or clone underlying
        timelines. (As to improve sync issues like those in foofone)

        * tests/test-timeline.c:
        Also add completed signals.

        * clutter/cogl/gles/cogl.c: (cogl_texture_image_2d):
        * configure.ac:
        Forward port from stable branch. RGB Image fixes gles
        and check for lower case libgles_cm.
2007-08-24 15:12:52 +00:00
Matthew Allum
8ad4dde16b 2007-08-13 Matthew Allum <mallum@openedhand.com>
* clutter/clutter-actor.c:
        * clutter/clutter-actor.h:
        * clutter/clutter-event.c:
        * clutter/clutter-event.h:
        * clutter/clutter-main.c:
        * clutter/clutter-main.h:
        * clutter/clutter-private.h:
        * clutter/clutter-stage.c:
        * clutter/clutter-stage.h:
        * clutter/clutter-types.h:
        Initial implementation of actors emmitting event signals (423);
        - Actors set_reactive() to receive mouse events.
          (call clutter_enable_motion_events() for per action motion events)
        - clutter_stage_set_key_focus () to direct key events.
        - Events bubble up to parents (ending at stage)
          (original source identified by clutter_event_get_source())
        TODO:
        - enter/leave notifys for actors.
        - stage specific events - fullscreen
        - grabs

        * tests/test-events.c:
        Extend a little to use new API

        * clutter/cogl/gl/cogl.c:
        * clutter/glx/clutter-backend-glx.c:
        Move get_proc_address into cogl and out of backend.
        (shaders will need it)

        * clutter/clutter-group.c: (clutter_group_real_lower):
        Fix a minor compile warning.

        * TODO:
        Sync up.
2007-08-13 20:48:01 +00:00
Emmanuele Bassi
d7caae7f6a 2007-07-04 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/*: Loads of fixes for the API reference.
2007-07-04 14:00:41 +00:00
Emmanuele Bassi
c22543be1f Update Clutter event structures to use the ModifierType enum 2007-06-11 09:02:40 +00:00
Emmanuele Bassi
a8c3d1652b Use a full enum for the modifier masks 2007-06-11 09:02:28 +00:00
Emmanuele Bassi
b2d01d86c2 Add support for WM_PROTOCOLS to the ClutterStage window
Supporting WM_PROTOCOLS allows handling the WM_DELETE_WINDOW ClientMessage,
which is then relayed to the ClutterStage actor in form of the "delete-event"
signal. Returning TRUE will block the propagation and won't close the
stage window.
2007-04-19 15:26:54 +00:00
Emmanuele Bassi
8b7504dea2 Merge from stable: add XEMBED support
Add the XEMBED protocol support in the GLX backend, for embedding the
stage window into another X window. This allows cross-toolkit inclusion
and makes clutter-gtk possible.
2007-04-19 15:24:57 +00:00
Emmanuele Bassi
1722c6fec4 Add missing template files. 2007-04-19 15:22:49 +00:00
Emmanuele Bassi
246a84d528 Merge from stable: add XEMBED support
Add the XEMBED protocol support in the GLX backend, for embedding the
stage window into another X window. This allows cross-toolkit inclusion
and makes clutter-gtk possible.
2007-04-16 16:50:40 +00:00
Emmanuele Bassi
922aafbd2d Remove the unused ClutterEventFlags enum and the flags member of
the ClutterEvent structure. ClutterEvent objects are not added until
translated so they do not need a 'pending' state.
2007-03-25 11:48:02 +00:00
Emmanuele Bassi
4bd3fa583e 2007-03-22 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/clutter-private.h: Remove inclusion of backend-specific
	headers; update the main context object; add the declarations for
	the event queue functions.

	* clutter/clutter-backend.[ch]: Add the abstract ClutterBackend
	object, which holds backend-specific settings, the main stage,
	and the event queue. Every backend must implement a subclass of
	ClutterBackend and ClutterStage.

	* clutter/clutter-feature.c: Protect the GLX specific calls
	behing #ifdef HAVE_CLUTTER_GLX.

	* clutter/clutter-actor.c:
	* clutter/clutter-group.c:
	* clutter/clutter-clone-texture.c: Include GL/gl.h

	* clutter/clutter-event.[ch]: Update public API and implement the
	event queue private API; hold a reference on the event objects;
	move out the keysym-to-unicode table; add the new event types.

	* clutter/clutter-color.h: Include clutter-fixed.h

	* clutter/clutter-main.c: Update API; get the main stage
	from the backend object; process the event received from the
	queue; lock/unlock the main mutex if we have one; move the
	initialisation process sooner in the init sequence, in order to
	have the backend object when we check for options; call the
	backed vfuncs in the pre/post parse hooks.

	* clutter/clutter-stage.c: Make ClutterStage and abstract class,
	implemented by the backends.

	* clutter/clutter/glx/clutter-glx.h:
	* clutter/clutter/glx/clutter-backend-glx.[ch]:
	* clutter/clutter/glx/clutter-event-glx.c:
	* clutter/clutter/glx/clutter-stage-glx.[ch]:
	* clutter/clutter/glx/Makefile.am: Add the GLX backend.

	* clutter/clutter/egl/clutter-backend-egl.[ch]:
	* clutter/clutter/egl/clutter-event-egl.c:
	* clutter/clutter/egl/clutter-stage-egl.[ch]:
	* clutter/clutter/egl/Makefile.am: Add the stub for a EGL backend.

	* examples/*.c: Update for the new API.
2007-03-22 18:21:59 +00:00
Emmanuele Bassi
0033b539b8 2006-12-27 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/clutter-stage.[ch]:
	* clutter/clutter-event.[ch]: Revert changes; this is what
	happens when you keep old tree around.
2006-12-27 18:25:43 +00:00
Emmanuele Bassi
89de2fa269 2006-12-27 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/clutter-color.h:
	* clutter/clutter-color.c: Add clutter_color_to_string(),
	which creates a hex-encoded color string from a ClutterColor.
2006-12-27 18:19:34 +00:00
Emmanuele Bassi
4d168e81fa 2006-12-13 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/clutter-actor.c:
	* clutter/clutter-clone-texture.c:
	* clutter/clutter-event.h:
	* clutter/clutter-stage.c:
	* clutter/clutter-texture.c:
	* clutter/clutter-timeline.c: Update the inline apidoc.
2006-12-13 18:12:09 +00:00
Emmanuele Bassi
10fbfb1659 2006-12-12 Emmanuele Bassi <ebassi@openedhand.com>
Rework part of the show/hide machinery.  Allow groups sub-classes
	and composite actors to override show_all/hide_all in order to
	decide which children they wish to show/hide.  This means that
	if an actor overrides the default show/hide virtual methods, it'll
	have to chain up to the parent class show/hide.  While we're at it,
	provide the fully recursive clutter_actor_show_all() and
	clutter_actor_hide_all() methods.

	* clutter/clutter-behaviour-path.c: Add apidoc for the ClutterKnot
	functions; add pathological equality case for clutter_knot_equal().

	* clutter/clutter-event.h:
	* clutter/clutter-feature.h:
	* clutter/clutter-behaviour.c:
	* clutter/clutter-behaviour-scale.c:Fix parameters name so that
	gtk-doc doesn't complain.

	* clutter/clutter-actor.c:
	* clutter/clutter-event.c: Add apidoc

	* clutter/clutter-actor.h:
	* clutter/clutter-actor.c: Add a clutter_actor_show_all() and a
	clutter_actor_hide_all() functions; provide a mechanism for
	groups and composited actors to programmatically select what to
	show/hide when clutter_actor_show_all() and clutter_actor_hide_all()
	are called.  If you are overriding the ClutterActor::show or
	the ClutterActor::hide virtual methods you should chain up with
	the parent class.

	* clutter/clutter-group.c: Override show_all and hide_all and
	recursively show/hide every child inside the group;
	clutter_group_show_all() and clutter_group_hide_all() remain as non
	recursive versions of clutter_actor_show_all() and
	clutter_actor_hide_all() (maybe we should rename them in order
	to avoid name clashes with the bindings).

	* clutter/clutter-stage.c:
	* clutter/clutter-texture.c: Chain up with parent class show
	and hide vfuncs.

	* clutter/clutter-clone-texture.h:
	* clutter/clutter-clone-texture.c: Provide API for changing the
	parent texture of a clone texture actor.

	* examples/behave.c:
	* examples/super-oh.c:
	* examples/test.c: Use clutter_actor_show_all() instead of
	clutter_group_show_all().
2006-12-12 20:20:04 +00:00
Matthew Allum
93f102fc85 2006-09-14 Matthew Allum <mallum@openedhand.com>
Various fixes from Bastien Nocera:

        * clutter/clutter-event.h:
        * clutter/clutter-stage.c: (clutter_stage_unrealize),
        (clutter_stage_realize), (clutter_stage_request_coords),
        (clutter_stage_dispose), (clutter_stage_init):
        * clutter/clutter-stage.h:
        * gtk/gtk-clutter-test.c: (input_cb), (frame_cb), (main):
        * gtk/gtk-clutter.c: (realize):
        Misc fixes (#152)

        * clutter/clutter-group.c: (clutter_group_remove):
        Remove uneeded ref count (#143)

        * examples/super-oh.c: (input_cb):
        Handle key release rather than presses (#154)

        * configure.ac:
        Add old style X libs check when x11.pc unavailable (#101)
2006-09-14 17:18:54 +00:00
Emmanuele Bassi
ce5c1150f2 2006-07-09 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/clutter-event.h: Change the name of the
	ClutterEvent union members to something a little shorter.
2006-07-10 10:52:04 +00:00
Iain Holmes
5a01d0ab1c Shuffle some layout so that gapi2-parser can understand everything 2006-06-23 15:13:11 +00:00
Matthew Allum
7806e409fb 2006-06-05 Matthew Allum <mallum@openedhand.com>
* clutter/clutter-event.h:
        Remove send_event field. Clutter shouldn't need it.

        * clutter/clutter-main.c: (clutter_dispatch_x_event):
        Dont malloc a new clutter event for each xevent.

        * clutter/clutter-stage.h:
        * clutter/clutter-stage.c: (clutter_stage_class_init),
        (clutter_stage_get_default):
        Dont ref stage from clutter_stage_get_default.

        * examples/super-oh.c: (main):
        Remove some now uneeded debug g_prints
2006-06-05 21:44:13 +00:00
Emmanuele Bassi
f6fe9e7412 2006-06-05 Emmanuele Bassi <ebassi@openedhand.com>
* clutter-color.h:
	* clutter-color.c: Reimplement ClutterColor as a boxed type;
	add convenience API for color handling, like: add, subtract,
	shade, HSL color-space conversion, packing and unpacking.

	* clutter-private.h: Update ClutterMainContext, and export the
	main context pointer here.

	* clutter-rectangle.h:
	* clutter-rectangle.c: Update the color-related code; make
	clutter_rectangle_new() and empty constructor and provide
	clutter_rectangle_new_with_color(); provide color setter
	and getter API.

	* clutter-label.h:
	* clutter-label.c: Rename the "font" property to "font-name";
	update the color-related code to the new ClutterColor object;
	rename clutter_label_new() to clutter_label_new_with_text(),
	and add setters and getters for the properties.

	* clutter-marshal.list: Add VOID:OBJECT and VOID:BOXED marshallers
	generators.

	* clutter-stage.h:
	* clutter-stage.c: Rework the API: provide a default constructor
	for a singleton object, named clutter_stage_get_default(), which
	supercedes the clutter_stage() function in clutter-main; provide
	new events: button-press-event, button-release-event,
	key-press-event and key-release-event; update the color-related
	code;

	(clutter_stage_snapshot): Allow negative width and height when
	taking a snapshot (meaning: use full width/height).

	(clutter_stage_get_element_at_pos): Rename clutter_stage_pick().

	* clutter-element.c (clutter_element_paint): Clean up the
	stage and color related code.

	* clutter-event.h:
	* clutter-event.c: Add generic ClutterAnyEvent type; add
	clutter_event_new(), clutter_event_copy() and clutter_event_free();
	make ClutterEvent a boxed type.

	* clutter-main.h:
	* clutter-main.c: Remove clutter_stage(); add clutter_main_quit(),
	for cleanly quitting from clutter_main(); add multiple mainloops
	support; allocate the ClutterCntx instead of adding it to the
	stack; re-work the ClutterEvent dispatching.

	* clutter-group.c (clutter_group_add), (clutter_group_remove): Keep
	a reference on the element when added to a ClutterGroup.

	* examples/rects.py
	* examples/test.c:
	* examples/test-text.c:
	* examples/video-cube.c:
	* examples/super-oh.c:
	* examples/test-video.c: Update.
2006-06-05 13:38:31 +00:00
Matthew Allum
342ea125f1 Merge gobject-branch into trunk 2006-05-29 08:59:36 +00:00