js code:
// Get chat window size
var wndRect = Interop.Allocate(4);
Interop.Call("user32.dll", "GetWindowRect", ChatWnd.Handle, wndRect);
Debug.Trace("Left: " + wndRect.left +
", Top: " + wndRect.top +
", Right: " + wndRect.right +
", Bottom: " + wndRect.bottom);
Should be more like:
js code:
// Get chat window size
var wndRect = Interop.Allocate(16);
Interop.Call("user32.dll", "GetWindowRect", ChatWnd.Handle, wndRect);
Debug.Trace("Left: " + wndRect.ReadDWORD(0) +
", Top: " + wndRect.ReadDWORD(4) +
", Right: " + wndRect.ReadDWORD(8) +
", Bottom: " + wndRect.ReadDWORD(12));
Might be .ReadWORD instead of DWORD though... not used them in a while.