user32: correct the caption bar and it's buttons' sizes

Peter Oberndorfer kumbayo84 at arcor.de
Wed Feb 13 13:03:22 CST 2008


On Mittwoch 13 Februar 2008, Divan Burger wrote:
> 

What is the problem without the patch?
is the caption bar drawn too high 1 pixel?

I ask because i have a patch that restores the 1 pixel
high line between the caption bar and the client area
(and at the same time decreases the height of the caption bar)
see it attached

for the NC_DrawXXXButton functions:
you also need to update hittest calculation
else the wrong buttons are activated.
For example when you press the mouse down on the left side of the close 
button, but maximize gets activated

>     case SM_CYCAPTION:
>         if (!spi_loaded[SPI_NONCLIENTMETRICS_IDX]) load_nonclient_metrics();
>-        return nonclient_metrics.iCaptionHeight + 1;
>+        return nonclient_metrics.iCaptionHeight;

this breaks a test in sysparams.c:2416
ok_gsm( SM_CYCAPTION, ncm.iCaptionHeight+1);
and 5 other tests

Greetings Peter
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-fix-caption-bar-being-too-high-by-1-pixel.patch
Type: text/x-diff
Size: 1041 bytes
Desc: not available
Url : http://www.winehq.org/pipermail/wine-patches/attachments/20080213/56f01b56/attachment.patch 


More information about the wine-patches mailing list