1

Closed

Support for x64 OS

description

When I tried to use Blake.NUI test applications in x64 OS they failed because of this line:
(uint)extraInfo.ToInt32() & PENTOUCHMASK) == PENTOUCHSIGNATURE
 
IntPtr is probably 64 bits which causes overflow and an exception.
 
This is how I solved this problem:
if (Environment.Is64BitProcess)
{
if (((uint)extraInfo.ToInt64() & PENTOUCHMASK) == PENTOUCHSIGNATURE)
    return true;
}
else
{
if (((uint)extraInfo.ToInt32() & PENTOUCHMASK) == PENTOUCHSIGNATURE)
    return true;
}
 
Maybe this is not very useful for Surface projects but it does not limit Windows 7 project to be strictly x86 bit.
Closed Sep 17, 2010 at 2:01 AM by JoshB
Fixed in changeset 66603

comments

JoshB wrote Sep 17, 2010 at 2:01 AM

Thanks for reporting! I had fixed this in my source but I like your solution better and have committed it.

wrote Sep 17, 2010 at 2:01 AM

wrote Sep 17, 2010 at 2:01 AM

wrote Feb 14, 2013 at 6:57 PM

wrote May 16, 2013 at 9:31 AM