summaryrefslogtreecommitdiff
path: root/beryl-plugins/src/thumbnail.c
diff options
context:
space:
mode:
authorracarr <racarr@d7aaf104-2d23-0410-ae22-9d23157bf5a3>2007-01-26 22:10:30 +0000
committerracarr <racarr@d7aaf104-2d23-0410-ae22-9d23157bf5a3>2007-01-26 22:10:30 +0000
commit5509f5a2667f77199b266a4ce4135cebc778942b (patch)
tree6c4c0a149842de220ee822c7575440a519aef398 /beryl-plugins/src/thumbnail.c
parent381ab03ff83ae68f45eda22e787c23e07556344a (diff)
downloadmarex-dev-5509f5a2667f77199b266a4ce4135cebc778942b.tar.gz
marex-dev-5509f5a2667f77199b266a4ce4135cebc778942b.tar.bz2
Fix thumbnail resize bug stuff
git-svn-id: file:///beryl/trunk@3230 d7aaf104-2d23-0410-ae22-9d23157bf5a3
Diffstat (limited to 'beryl-plugins/src/thumbnail.c')
-rw-r--r--beryl-plugins/src/thumbnail.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/beryl-plugins/src/thumbnail.c b/beryl-plugins/src/thumbnail.c
index 40093b4..9c8f805 100644
--- a/beryl-plugins/src/thumbnail.c
+++ b/beryl-plugins/src/thumbnail.c
@@ -162,6 +162,7 @@ typedef struct _ThumbScreen {
PaintWindowProc paintWindow;
DonePaintScreenProc donePaintScreen;
DamageWindowRectProc damageWindowRect;
+ WindowResizeNotifyProc windowResizeNotify;
CompWindow *dock;
CompWindow *pointedWin;
@@ -931,6 +932,17 @@ thumbSetScreenOption (CompScreen *screen,
return FALSE;
}
+static void
+thumbWindowResizeNotify(CompWindow *w, int dx, int dy, int dwidth, int dheight)
+{
+ THUMB_SCREEN ( w->screen );
+
+ thumbUpdateThumbnail(w->screen);
+
+ UNWRAP(ts,w->screen,windowResizeNotify);
+ (*w->screen->windowResizeNotify) (w,dx,dy,dwidth,dheight);
+ WRAP(ts,w->screen,windowResizeNotify,thumbWindowResizeNotify);
+}
static void
thumbHandleEvent (CompDisplay *d,
@@ -1435,6 +1447,7 @@ thumbInitScreen (CompPlugin *p,
WRAP (ts, s, preparePaintScreen, thumbPreparePaintScreen);
WRAP (ts, s, donePaintScreen, thumbDonePaintScreen);
WRAP (ts, s, paintWindow, thumbPaintWindow);
+ WRAP(ts,s,windowResizeNotify, thumbWindowResizeNotify);
ts->dock = NULL;
ts->pointedWin = NULL;
@@ -1472,6 +1485,7 @@ thumbFiniScreen (CompPlugin *p,
UNWRAP (ts, s, preparePaintScreen);
UNWRAP (ts, s, donePaintScreen);
UNWRAP (ts, s, paintWindow);
+ UNWRAP(ts,s,windowResizeNotify);
if (ts->mouseTimeout)
compRemoveTimeout (ts->mouseTimeout);