diff options
| author | Dana Jansens <danakj@orodu.net> | 2007-05-05 05:58:35 +0000 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2007-05-05 05:58:35 +0000 |
| commit | 08e42acaadf8868abb94dc75da0daa9c6e4e2d1c (patch) | |
| tree | b174c5af594786bd9dd023936fdb8f4400f8e09d /openbox/frame.h | |
| parent | fde5ca09e9ea7ab08b6dc06723f19bad6d03af22 (diff) | |
animate iconify/reestore. yeah.
Diffstat (limited to 'openbox/frame.h')
| -rw-r--r-- | openbox/frame.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/openbox/frame.h b/openbox/frame.h index 19bade78..8f210b0c 100644 --- a/openbox/frame.h +++ b/openbox/frame.h @@ -27,6 +27,8 @@ typedef struct _ObFrame ObFrame; struct _ObClient; +typedef void (*ObFrameIconifyAnimateFunc)(gpointer data); + typedef enum { OB_FRAME_CONTEXT_NONE, OB_FRAME_CONTEXT_DESKTOP, @@ -142,6 +144,17 @@ struct _ObFrame gboolean flashing; gboolean flash_on; GTimeVal flash_end; + + /*! The step which the client is currently in for animating iconify and + restore. + 0 means that it is not animating. FRAME_ANIMATE_ICONIFY_STEPS is the + first step for iconifying, and -FRAME_ANIMATE_ICONIFY_STEPS is the + forst step for restoring. It counts towards 0 either way. Visually, + +x == -(FRAME_ANIMATE_ICONIFY_STEPS-x+1) + */ + gint iconify_animation_step; + ObFrameIconifyAnimateFunc iconify_animation_cb; + gpointer iconify_animation_data; }; ObFrame *frame_new(struct _ObClient *c); @@ -178,4 +191,11 @@ void frame_frame_gravity(ObFrame *self, gint *x, gint *y, gint w, gint h); void frame_flash_start(ObFrame *self); void frame_flash_stop(ObFrame *self); +/*! Start an animation for iconifying or restoring a frame. The callback + will be called when the animation finishes. But if another animation is + started in the meantime, the callback will never get called. */ +void frame_begin_iconify_animation(ObFrame *self, gboolean iconifying, + ObFrameIconifyAnimateFunc callback, + gpointer data); + #endif |
