Hi Pritpal, Good job, the code looks quite clean now, except for some regular warnings that can be safely ignored for now.
The remaining important ones are these (see below): --- wvgutils.c .\wvgutils.c(1263) : warning C4244: 'function' : conversion from 'HB_PTRDIFF' to 'ULONG', possible loss of data wincallb.c .\wincallb.c(417) : warning C4305: 'type cast' : truncation from 'BYTE *' to 'ULONG' .\wincallb.c(419) : warning C4305: 'type cast' : truncation from 'void *' to 'ULONG' .\wincallb.c(431) : warning C4305: 'type cast' : truncation from 'void *' to 'ULONG' .\wincallb.c(432) : warning C4305: 'type cast' : truncation from 'void *' to 'ULONG' .\wincallb.c(433) : warning C4305: 'type cast' : truncation from 'void *' to 'ULONG' .\wincallb.c(434) : warning C4305: 'type cast' : truncation from 'void *' to 'ULONG' -- > [ In .\wvgutils.c(1264) the previous version (commented in > code) was correct, you probably need to cast the whole > expression manually to '( ULONG )'. ] > > No, this code works only as is now, otherwise not. > I do not know what to do with it. I see. Same code is used BTW in hbwhat, so that one's wrong also. I seem to recall seeing the solution from Przemek, bug forgot where it was, and couldn't find it now either. Casting a pointer to WORD is definitely wrong though for 64-bit, should use PTRDIFF in some ways or another. > <<<<<<<<< > gtwvg.c > .\gtwvg.c(3338) : warning C4306: 'type cast' : conversion from 'int' to > 'HWND' of greater size>>>>>>>>>>>>>> > > The warnings above are in SetWindowPos( hWnd, hWndParent, ... ) > Here if <hWndParent> <> NULL then it is being treated as "int" in 64 bits, > Otherwise "HWND". Should it be guarded against #if (_WIN_IE >= 0500) ? Rather HB_OS_WIN_64. But I think it's fine like this, it seems harmless. > <<<<<<<<< > wincallb.c > .\wincallb.c(348) : warning C4152: nonstandard extension, function/data > pointer conversion in expression > .\wincallb.c(391) : warning C4152: nonstandard extension, function/data > pointer conversion in expression > .\wincallb.c(417) : warning C4305: 'type cast' : truncation from 'BYTE *' > to > 'ULONG' > .\wincallb.c(419) : warning C4305: 'type cast' : truncation from 'void *' > to > 'ULONG' > .\wincallb.c(431) : warning C4305: 'type cast' : truncation from 'void *' > to > 'ULONG' > .\wincallb.c(432) : warning C4305: 'type cast' : truncation from 'void *' > to > 'ULONG' > .\wincallb.c(433) : warning C4305: 'type cast' : truncation from 'void *' > to > 'ULONG' > .\wincallb.c(434) : warning C4305: 'type cast' : truncation from 'void *' > to > 'ULONG' > >>>>>>>> > > I do not know how to fix it. These functions are important though. This code seems to be x86 (32-bit) specific, it's even using byte coded assembler. Probably this part shouldn't be used if we want to achieve 64-bit (or WinCE/ARM, or Itanium) support. I'm not sure how important it is, or can it be swapped for some portable solutions. One solution could be to write CALLBACK specific C wrappers for Harbour, instead of using this generic solution. Little more coding, but much cleaner. Brgds, Viktor
_______________________________________________ Harbour mailing list [email protected] http://lists.harbour-project.org/mailman/listinfo/harbour
