Example #1
0
static int _X_COLD
SProcRRChangeOutputProperty(ClientPtr client)
{
    REQUEST(xRRChangeOutputPropertyReq);

    REQUEST_AT_LEAST_SIZE(xRRChangeOutputPropertyReq);
    swaps(&stuff->length);
    swapl(&stuff->output);
    swapl(&stuff->property);
    swapl(&stuff->type);
    swapl(&stuff->nUnits);
    switch (stuff->format) {
    case 8:
        break;
    case 16:
        SwapRestS(stuff);
        break;
    case 32:
        SwapRestL(stuff);
        break;
    default:
        client->errorValue = stuff->format;
        return BadValue;
    }
    return (*ProcRandrVector[stuff->randrReqType]) (client);
}
Example #2
0
static int
SProcLbxChangeProperty(ClientPtr client)
{
    register int n;

    REQUEST(xLbxChangePropertyReq);

    swaps(&stuff->length, n);
    REQUEST_AT_LEAST_SIZE(xLbxChangePropertyReq);
    swapl(&stuff->window, n);
    swapl(&stuff->property, n);
    swapl(&stuff->type, n);
    swapl(&stuff->nUnits, n);
    switch (stuff->format) {
    case 8:
	break;
    case 16:
	SwapRestS(stuff);
	break;
    case 32:
	SwapRestL(stuff);
	break;
    }
    return ProcLbxChangeProperty(client);
}
Example #3
0
     /* cannot use XETSwPoly for this one, because xFillPolyReq
      * is longer than xPolyPointReq, and we don't want to swap
      * the difference as shorts! 
      */
void XETSwFillPoly(register xFillPolyReq *data, ClientPtr client)
{
    register char n;

    swapl(&(data->drawable), n);
    swapl(&(data->gc), n);
    SwapRestS(data);
    swaps(&(data->length), n);
}
Example #4
0
void XETSwSetClipRectangles(register xSetClipRectanglesReq *data, ClientPtr
client)
{
    register char n;
    swapl(&(data->gc), n);
    swaps(&(data->xOrigin), n);
    swaps(&(data->yOrigin), n);
    SwapRestS(data);
    swaps(&(data->length), n);
}
Example #5
0
int _X_COLD
SProcXFixesCreateRegion(ClientPtr client)
{
    REQUEST(xXFixesCreateRegionReq);

    swaps(&stuff->length);
    REQUEST_AT_LEAST_SIZE(xXFixesCreateRegionReq);
    swapl(&stuff->region);
    SwapRestS(stuff);
    return (*ProcXFixesVector[stuff->xfixesReqType]) (client);
}
Example #6
0
int
SProcXFixesSetRegion (ClientPtr client)
{
    int n;
    REQUEST (xXFixesSetRegionReq);

    swaps (&stuff->length, n);
    REQUEST_AT_LEAST_SIZE(xXFixesSetRegionReq);
    swapl (&stuff->region, n);
    SwapRestS(stuff);
    return (*ProcXFixesVector[stuff->xfixesReqType]) (client);
}
Example #7
0
static int _X_COLD
SProcRRSetCrtcGamma(ClientPtr client)
{
    REQUEST(xRRSetCrtcGammaReq);

    REQUEST_AT_LEAST_SIZE(xRRSetCrtcGammaReq);
    swaps(&stuff->length);
    swapl(&stuff->crtc);
    swaps(&stuff->size);
    SwapRestS(stuff);
    return (*ProcRandrVector[stuff->randrReqType]) (client);
}
Example #8
0
/* cannot use SProcPoly for this one, because xFillPolyReq
   is longer than xPolyPointReq, and we don't want to swap
   the difference as shorts! */
int
SProcFillPoly(ClientPtr client)
{
    char n;

    REQUEST(xFillPolyReq);
    swaps(&stuff->length, n);
    REQUEST_AT_LEAST_SIZE(xFillPolyReq);
    swapl(&stuff->drawable, n);
    swapl(&stuff->gc, n);
    SwapRestS(stuff);
    return((* ProcVector[X_FillPoly])(client));
}
Example #9
0
/* The following routine is used for all Poly drawing requests
   (except FillPoly, which uses a different request format) */
int
SProcPoly(ClientPtr client)
{
    char n;

    REQUEST(xPolyPointReq);
    swaps(&stuff->length, n);
    REQUEST_AT_LEAST_SIZE(xPolyPointReq);
    swapl(&stuff->drawable, n);
    swapl(&stuff->gc, n);
    SwapRestS(stuff);
    return((* ProcVector[stuff->reqType])(client));
}
Example #10
0
int
SProcSetClipRectangles(ClientPtr client)
{
    char n;
    REQUEST(xSetClipRectanglesReq);
    swaps(&stuff->length, n);
    REQUEST_AT_LEAST_SIZE(xSetClipRectanglesReq);
    swapl(&stuff->gc, n);
    swaps(&stuff->xOrigin, n);
    swaps(&stuff->yOrigin, n);
    SwapRestS(stuff);
    return((* ProcVector[X_SetClipRectangles])(client));
}
Example #11
0
static int
SProcShapeRectangles(ClientPtr client)
{
    REQUEST(xShapeRectanglesReq);

    swaps(&stuff->length);
    REQUEST_AT_LEAST_SIZE(xShapeRectanglesReq);
    swapl(&stuff->dest);
    swaps(&stuff->xOff);
    swaps(&stuff->yOff);
    SwapRestS(stuff);
    return ProcShapeRectangles(client);
}
Example #12
0
int
SProcChangeProperty(ClientPtr client)
{
    char n;
    REQUEST(xChangePropertyReq);
    swaps(&stuff->length, n);
    REQUEST_AT_LEAST_SIZE(xChangePropertyReq);
    swapl(&stuff->window, n);
    swapl(&stuff->property, n);
    swapl(&stuff->type, n);
    swapl(&stuff->nUnits, n);
    switch ( stuff->format ) {
        case 8 :
	    break;
        case 16:
	    SwapRestS(stuff);
	    break;
	case 32:
	    SwapRestL(stuff);
	    break;
	}
    return((* ProcVector[X_ChangeProperty])(client));
}
Example #13
0
static int _X_COLD
SProcRRChangeProviderProperty(ClientPtr client)
{
    REQUEST(xRRChangeProviderPropertyReq);

    REQUEST_AT_LEAST_SIZE(xRRChangeProviderPropertyReq);
    swaps(&stuff->length);
    swapl(&stuff->provider);
    swapl(&stuff->property);
    swapl(&stuff->type);
    swapl(&stuff->nUnits);
    switch (stuff->format) {
    case 8:
        break;
    case 16:
        SwapRestS(stuff);
        break;
    case 32:
        SwapRestL(stuff);
        break;
    }
    return ProcRandrVector[stuff->randrReqType] (client);
}