summaryrefslogtreecommitdiff
path: root/beryl-plugins/src/thumbnail.c
diff options
context:
space:
mode:
authoronestone <onestone@d7aaf104-2d23-0410-ae22-9d23157bf5a3>2007-01-21 21:59:12 +0000
committeronestone <onestone@d7aaf104-2d23-0410-ae22-9d23157bf5a3>2007-01-21 21:59:12 +0000
commit27f866d9df72e4c0fe6cee30cfcdb0543e64f43a (patch)
tree04d61d46e5399d8bd2175c288ac86a328db031bf /beryl-plugins/src/thumbnail.c
parent461ab31c499255df0f3708a67653a45976bf04fb (diff)
downloadmarex-dev-27f866d9df72e4c0fe6cee30cfcdb0543e64f43a.tar.gz
marex-dev-27f866d9df72e4c0fe6cee30cfcdb0543e64f43a.tar.bz2
beryl-plugins: thumbnail: fixed position calculation. closes #902
git-svn-id: file:///beryl/trunk@2934 d7aaf104-2d23-0410-ae22-9d23157bf5a3
Diffstat (limited to 'beryl-plugins/src/thumbnail.c')
-rw-r--r--beryl-plugins/src/thumbnail.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/beryl-plugins/src/thumbnail.c b/beryl-plugins/src/thumbnail.c
index 7a7257a..ac4bde4 100644
--- a/beryl-plugins/src/thumbnail.c
+++ b/beryl-plugins/src/thumbnail.c
@@ -300,8 +300,8 @@ thumbUpdateThumbnail( CompScreen *s)
tmpPos[0] = ox1 + off;
if (tmpPos[0] + off + ts->thumb.width > ox2)
{
- if (ts->thumb.width + (2*off) - ow > 0)
- tmpPos[0] = ox2 - tmpPos[0] - off;
+ if (ts->thumb.width + (2*off) < ow)
+ tmpPos[0] = ox2 - ts->thumb.width - off;
else
tmpPos[0] = ox1 + off;
}
@@ -333,8 +333,8 @@ thumbUpdateThumbnail( CompScreen *s)
tmpPos[1] = oy1 + off;
if (tmpPos[1] + off + ts->thumb.height > oy2)
{
- if (ts->thumb.height + (2*off) - oh > 0)
- tmpPos[1] = oy2 - tmpPos[1] - off;
+ if (ts->thumb.height + (2*off) < oh)
+ tmpPos[1] = oy2 - ts->thumb.height - off;
else
tmpPos[1] = oy1 + off;
}