I was setting the window to be of type WS_POPUP. Don't do that. Don't pass in anything except maybe WS_VISIBLE to the createWindow call and that will fix a lot of problems.
Thanks for pointing me at the app code it gave me the examples I needed to run this down.