This might be a stupid question, but is there any way I can do this in WndProc? I assumed I wouldn't need WM_PAINT at all, due to it being a DirectX application, but that results in nothing being painted...

The problem I have is my DX button decends from TControl, which when I am flipping seems to leave a flicker of a black rect where I move my button in code (only for about 1 frame, it dissapears once its blitted another frame. Is it possible that my flip loop is not correct?

Any advice appreciated.

I am not using FlipToGDI btw!