Restore warnings, and provide macros for C++11.

Restore 2 disabled warnings, disabled by default as stated in
the Visual Studio documentation:

http://msdn.microsoft.com/en-us/library/aa984150.aspx

Signed-off-by: Daniel S. Reichenbach <daniel@kogitoapp.com>
Fixed a race condition in Thread.

Reference count will be incremented before spawning the Thread that
will execute the task, otherwise the thread might finish, decRef the
task and delete it.

Signed-off-by: Daniel S. Reichenbach <daniel@kogitoapp.com>