mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-19 12:28:22 +01:00
Misc bug fixes
This commit is contained in:
@@ -2160,7 +2160,7 @@ wheelRender(W_ColorPanel *panel)
|
||||
unsigned long ofs = 0;
|
||||
unsigned char shift = getShift(sizeof(unsigned char));
|
||||
|
||||
image = RCreateImage(colorWheelSize+4, colorWheelSize+4, False);
|
||||
image = RCreateImage(colorWheelSize+4, colorWheelSize+4, True);
|
||||
if (!image) {
|
||||
wwarning(NO_MEMORY_ERR);
|
||||
return;
|
||||
@@ -2180,11 +2180,13 @@ wheelRender(W_ColorPanel *panel)
|
||||
panel->wheelMtrx->data[1][ofs] ]);
|
||||
*(ptr++) = (unsigned char)(panel->wheelMtrx->values[
|
||||
panel->wheelMtrx->data[2][ofs] ]);
|
||||
*(ptr++) = 0;
|
||||
}
|
||||
else {
|
||||
*(ptr++) = (unsigned char)(gray.red);
|
||||
*(ptr++) = (unsigned char)(gray.green);
|
||||
*(ptr++) = (unsigned char)(gray.blue);
|
||||
*(ptr++) = 255;
|
||||
}
|
||||
ofs++;
|
||||
}
|
||||
@@ -3003,8 +3005,8 @@ customPalettePositionSelection(W_ColorPanel *panel, int x, int y)
|
||||
panel->palx = x;
|
||||
panel->paly = y;
|
||||
|
||||
ofs = rint(x * panel->palXRatio) + rint(y * panel->palYRatio) *
|
||||
panel->customPaletteImg->width * 3;
|
||||
ofs = (rint(x * panel->palXRatio) + rint(y * panel->palYRatio) *
|
||||
panel->customPaletteImg->width) * 3;
|
||||
|
||||
panel->color.rgb.red = panel->customPaletteImg->data[ofs];
|
||||
panel->color.rgb.green = panel->customPaletteImg->data[ofs+1];
|
||||
|
||||
@@ -37,8 +37,14 @@ wSoundServerGrab(Window wm_win)
|
||||
}
|
||||
|
||||
XGetClassHint (dpy, lstChildren[indexCount], retHint);
|
||||
|
||||
if (retHint->res_class) {
|
||||
if (strcmp("WMSoundServer", retHint->res_class) == 0) {
|
||||
if (strcmp("WMSoundServer", retHint->res_class)==0 ||
|
||||
/*strcmp("WSoundServer", retHint->res_class)==0 ||*/
|
||||
(retHint->res_name &&
|
||||
strcmp("wsoundserver", retHint->res_name)==0 &&
|
||||
strcmp("DockApp", retHint->res_class)==0)) {
|
||||
|
||||
soundServer = lstChildren[indexCount];
|
||||
XFree(lstChildren);
|
||||
if(retHint) {
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Raster graphics library
|
||||
*
|
||||
* Copyright (c) 1997-2000 Alfredo K. Kojima
|
||||
* Copyright (c) 1998-2000 Dan Pascu
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Library General Public
|
||||
@@ -249,7 +250,7 @@ renderDGradient(unsigned width, unsigned height, int r0, int g0, int b0,
|
||||
return NULL;
|
||||
}
|
||||
|
||||
a = (((width - 1)<<16) / ((height - 1)<<16)) * 3;
|
||||
a = (((width - 1)<<16) / (height - 1)) * 3;
|
||||
|
||||
width *= 3;
|
||||
/* copy the first line to the other lines with corresponding offset */
|
||||
|
||||
Reference in New Issue
Block a user