Ignore:
Timestamp:
Sep 25, 1999, 12:47:00 AM (26 years ago)
Author:
sandervl
Message:

Cursor fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kernel32/cvtcursorgrp.cpp

    r997 r1036  
    1 /* $Id: cvtcursorgrp.cpp,v 1.4 1999-09-21 08:24:53 sandervl Exp $ */
     1/* $Id: cvtcursorgrp.cpp,v 1.5 1999-09-24 22:47:00 sandervl Exp $ */
    22
    33/*
     
    3636 CursorResDir *rdir = (CursorResDir *)(chdr + 1);
    3737 int i, groupsize = 0, os2cursorsize;
    38  BITMAPARRAYFILEHEADER *bafh, *orgbafh;
     38 BITMAPARRAYFILEHEADER2 *bafh, *orgbafh;
    3939 CursorComponent       *cursorhdr;
    4040 Win32Resource         *winres;
     
    5656        rdir++;
    5757  }
    58   bafh    = (BITMAPARRAYFILEHEADER *)malloc(groupsize+chdr->cwCount*sizeof(BITMAPARRAYFILEHEADER));
     58  bafh    = (BITMAPARRAYFILEHEADER2 *)malloc(groupsize+chdr->cwCount*sizeof(BITMAPARRAYFILEHEADER2));
    5959  orgbafh = bafh;
    6060
     
    6262  for(i=0;i<chdr->cwCount;i++) {
    6363        bafh->usType    = BFT_BITMAPARRAY;
    64         bafh->cbSize    = sizeof(BITMAPARRAYFILEHEADER);
     64        bafh->cbSize    = sizeof(BITMAPARRAYFILEHEADER2);
    6565        bafh->cxDisplay = 0;
    6666        bafh->cyDisplay = 0;
     
    7575
    7676        cursorhdr = (CursorComponent *)winres->lockResource();
    77         os2cursor = ConvertCursor(cursorhdr, winres->getSize(), &os2cursorsize, (int)bafh - (int)orgbafh + sizeof(BITMAPARRAYFILEHEADER)-sizeof(BITMAPFILEHEADER));
     77        os2cursor = ConvertCursor(cursorhdr, winres->getSize(), &os2cursorsize, (int)bafh - (int)orgbafh + sizeof(BITMAPARRAYFILEHEADER2)-sizeof(BITMAPFILEHEADER));
    7878
    7979        if(os2cursor == NULL) {
     
    8585
    8686        if(i != chdr->cwCount -1) {
    87                 bafh->offNext = (int)&bafh->bfh - (int)orgbafh + os2cursorsize;
     87                bafh->offNext = (int)&bafh->bfh2 - (int)orgbafh + os2cursorsize;
    8888        }
    8989        else    bafh->offNext = 0;
    9090
    91         memcpy((char *)&bafh->bfh, os2cursor, os2cursorsize);
     91        memcpy((char *)&bafh->bfh2, os2cursor, os2cursorsize);
    9292        free(os2cursor);
    9393
    94         bafh = (BITMAPARRAYFILEHEADER *)((int)&bafh->bfh + os2cursorsize);
     94        bafh = (BITMAPARRAYFILEHEADER2 *)((int)&bafh->bfh2 + os2cursorsize);
    9595        delete winres;
    9696
Note: See TracChangeset for help on using the changeset viewer.