Changed order, because typedefs were not available in includes.

The plugin did not compile on my linux box, because DWORD was not defined in CSocket.h and CThread.h included from main.h. Fixed this by putting the typedefs above the includes.