diff options
author | maniac <maniac@d7aaf104-2d23-0410-ae22-9d23157bf5a3> | 2007-02-15 18:43:47 +0000 |
---|---|---|
committer | maniac <maniac@d7aaf104-2d23-0410-ae22-9d23157bf5a3> | 2007-02-15 18:43:47 +0000 |
commit | 8dd7b691b09985e41eae01e47852760e59b1ee3e (patch) | |
tree | 75d9010bceb78d1bacbf34a6a2b609a17f187a11 | |
parent | 0f2ef70050b891f26b9cc0317299c35381c36203 (diff) | |
download | marex-dev-8dd7b691b09985e41eae01e47852760e59b1ee3e.tar.gz marex-dev-8dd7b691b09985e41eae01e47852760e59b1ee3e.tar.bz2 |
water plugin: only decrement water win wave vertex count if those waves actually are drawn
git-svn-id: file:///beryl/trunk@4087 d7aaf104-2d23-0410-ae22-9d23157bf5a3
-rw-r--r-- | beryl-plugins/src/water.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/beryl-plugins/src/water.c b/beryl-plugins/src/water.c index faa5f6b..b51416b 100644 --- a/beryl-plugins/src/water.c +++ b/beryl-plugins/src/water.c @@ -1113,7 +1113,12 @@ static void waterPreparePaintScreen(CompScreen * s, int msSinceLastPaint) { WATER_SCREEN(s); - if (ws->count) + Bool drawWaves = TRUE; + + if (ws->current.w) + drawWaves = ((s->x == ws->current.vpX) && (s->y == ws->current.vpY)); + + if (ws->count && drawWaves) { ws->count -= 10; if (ws->count < 0) |