diff options
author | Havoc Pennington <hp@pobox.com> | 2001-08-06 04:43:31 +0000 |
---|---|---|
committer | rhp <rhp> | 2001-08-06 04:43:31 +0000 |
commit | 47ce823aa524d6d33b56749983f1a241232cc51a (patch) | |
tree | 3cfbc5a28e2449339c2cff036fc42ce2214dc193 | |
parent | 971419c880265fa11cd6009077db5e8cf2ce0a92 (diff) | |
download | metacity-47ce823aa524d6d33b56749983f1a241232cc51a.tar.gz |
draw animation for shading too
2001-08-06 Havoc Pennington <hp@pobox.com>
* src/window.c (meta_window_shade): draw animation
for shading too
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | README | 7 | ||||
-rw-r--r-- | configure.in | 2 | ||||
-rw-r--r-- | src/effects.h | 3 | ||||
-rw-r--r-- | src/window.c | 22 |
5 files changed, 33 insertions, 6 deletions
@@ -1,3 +1,8 @@ +2001-08-06 Havoc Pennington <hp@pobox.com> + + * src/window.c (meta_window_shade): draw animation + for shading too + 2001-08-05 Anders Carlsson <andersca@gnu.org> * src/display.h, src/display.c: Add _NET_WM_ICON_GEOMETRY atom. @@ -123,6 +123,10 @@ METACITY FEATURES - Uses Pango to render text, so has cool i18n capabilities. Supports UTF-8 window titles and such. + - There are simple animations for actions such as minimization, + to help users see what is happening. Should probably + have a few more of these. + METACITY BUGS, NON-FEATURES, AND CAVEATS === @@ -167,9 +171,6 @@ METACITY BUGS, NON-FEATURES, AND CAVEATS another. (But sometimes I don't see the flicker, so I'm not sure.) - - Various operations, such as minimize, maximize, etc., should - have simple animations to make them clearer to users. - - I haven't even read the ICCCM section about colormaps. So if you have an 8-bit display you are basically screwed. diff --git a/configure.in b/configure.in index c129b343..9e275c64 100644 --- a/configure.in +++ b/configure.in @@ -2,7 +2,7 @@ AC_INIT(src/display.c) AM_CONFIG_HEADER(config.h) -AM_INIT_AUTOMAKE(metacity, 2.3.2) +AM_INIT_AUTOMAKE(metacity, 2.3.3) GETTEXT_PACKAGE=metacity AC_SUBST(GETTEXT_PACKAGE) diff --git a/src/effects.h b/src/effects.h index d564103e..867f6c06 100644 --- a/src/effects.h +++ b/src/effects.h @@ -28,6 +28,9 @@ #define META_MINIMIZE_ANIMATION_STEPS 16 #define META_MINIMIZE_ANIMATION_DELAY 20 +#define META_SHADE_ANIMATION_STEPS 7 +#define META_SHADE_ANIMATION_DELAY 15 + void meta_effects_draw_box_animation (MetaScreen *screen, MetaRectangle *initial_rect, MetaRectangle *destination_rect, diff --git a/src/window.c b/src/window.c index 917ddee0..519efa39 100644 --- a/src/window.c +++ b/src/window.c @@ -1064,10 +1064,28 @@ meta_window_shade (MetaWindow *window) meta_verbose ("Shading %s\n", window->desc); if (!window->shaded) { - window->shaded = TRUE; + { + /* Animation */ + MetaRectangle starting_size; + MetaRectangle titlebar_size; + + meta_window_get_outer_rect (window, &starting_size); + if (window->frame) + starting_size.y += window->frame->child_y; + titlebar_size = starting_size; + titlebar_size.height = 0; + + meta_effects_draw_box_animation (window->screen, + &starting_size, + &titlebar_size, + META_SHADE_ANIMATION_STEPS, + META_SHADE_ANIMATION_DELAY); + } - meta_window_focus (window, CurrentTime); + window->shaded = TRUE; + meta_window_focus (window, CurrentTime); + meta_window_queue_move_resize (window); meta_window_queue_calc_showing (window); |