Contents of /trunk/xpdf/patches/xpdf-3.01-resize.patch
Parent Directory | Revision Log
Revision 153 -
(show annotations)
(download)
Tue May 8 20:52:56 2007 UTC (17 years, 4 months ago) by niro
File size: 1232 byte(s)
Tue May 8 20:52:56 2007 UTC (17 years, 4 months ago) by niro
File size: 1232 byte(s)
-import
1 | --- xpdf-3.01/xpdf/XPDFCore.cc.resize 2005-10-06 23:40:10.000000000 +0200 |
2 | +++ xpdf-3.01/xpdf/XPDFCore.cc 2005-10-06 23:40:10.000000000 +0200 |
3 | @@ -979,6 +979,9 @@ |
4 | XPDFCore *core = (XPDFCore *)ptr; |
5 | XEvent event; |
6 | Widget top; |
7 | + Window rootWin; |
8 | + int x1, y1; |
9 | + Guint w1, h1, bw1, depth1; |
10 | Arg args[2]; |
11 | int n; |
12 | Dimension w, h; |
13 | @@ -986,15 +989,20 @@ |
14 | |
15 | // find the top-most widget which has an associated window, and look |
16 | // for a pending ConfigureNotify in the event queue -- if there is |
17 | - // one, that means we're still resizing, and we want to skip the |
18 | - // current event |
19 | + // one, and it specifies a different width or height, that means |
20 | + // we're still resizing, and we want to skip the current event |
21 | for (top = core->parentWidget; |
22 | XtParent(top) && XtWindow(XtParent(top)); |
23 | top = XtParent(top)) ; |
24 | if (XCheckTypedWindowEvent(core->display, XtWindow(top), |
25 | ConfigureNotify, &event)) { |
26 | XPutBackEvent(core->display, &event); |
27 | - return; |
28 | + XGetGeometry(core->display, event.xconfigure.window, |
29 | + &rootWin, &x1, &y1, &w1, &h1, &bw1, &depth1); |
30 | + if ((Guint)event.xconfigure.width != w1 || |
31 | + (Guint)event.xconfigure.height != h1) { |
32 | + return; |
33 | + } |
34 | } |
35 | |
36 | n = 0; |