From: Emmanuele Bassi Date: Tue, 28 Dec 2010 17:36:27 +0000 (+0000) Subject: stage-window: Add set_accept_focus() vfunc X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e1cd6f49b2afcb1738ee2e95f03aa77b8c696e7b;p=profile%2Fivi%2Fclutter.git stage-window: Add set_accept_focus() vfunc Allow Stage implementations to set whether or not they want to accept key focus when being shown. http://bugzilla.clutter-project.org/show_bug.cgi?id=2500 --- diff --git a/clutter/clutter-stage-window.c b/clutter/clutter-stage-window.c index ce88a5d..173f2df 100644 --- a/clutter/clutter-stage-window.c +++ b/clutter/clutter-stage-window.c @@ -168,3 +168,15 @@ _clutter_stage_window_ignoring_redraw_clips (ClutterStageWindow *window) return TRUE; } +void +_clutter_stage_window_set_accept_focus (ClutterStageWindow *window, + gboolean accept_focus) +{ + ClutterStageWindowIface *iface; + + g_return_if_fail (CLUTTER_IS_STAGE_WINDOW (window)); + + iface = CLUTTER_STAGE_WINDOW_GET_IFACE (window); + if (iface->set_accept_focus) + iface->set_accept_focus (window, accept_focus); +} diff --git a/clutter/clutter-stage-window.h b/clutter/clutter-stage-window.h index 814d8d5..fb985c1 100644 --- a/clutter/clutter-stage-window.h +++ b/clutter/clutter-stage-window.h @@ -63,6 +63,9 @@ struct _ClutterStageWindowIface ClutterGeometry *stage_rectangle); gboolean (* has_redraw_clips) (ClutterStageWindow *stage_window); gboolean (* ignoring_redraw_clips) (ClutterStageWindow *stage_window); + + void (* set_accept_focus) (ClutterStageWindow *stage_window, + gboolean accept_focus); }; GType clutter_stage_window_get_type (void) G_GNUC_CONST; @@ -97,6 +100,9 @@ void _clutter_stage_window_add_redraw_clip (ClutterStageWindow *w gboolean _clutter_stage_window_has_redraw_clips (ClutterStageWindow *window); gboolean _clutter_stage_window_ignoring_redraw_clips (ClutterStageWindow *window); +void _clutter_stage_window_set_accept_focus (ClutterStageWindow *window, + gboolean accept_focus); + G_END_DECLS #endif /* __CLUTTER_STAGE_WINDOW_H__ */