In both cases the problem appears. I seem to be able to restore the images locking and unlocking them with LockImage/UnlockImage.
However, I should still need to find a way to detect this graphicslost.
I tried testing if the TImage = null or TGraphics = null, but they remain valid.
Sometimes, only the lower half of the image dissapears. Then, when trying it again, the rest of the image dissapears as well.
Beside the images, the DrawText command doesn't work either after this. I'm not loading/setting any fonts.
And at one point, I got an unhandled memory exception on "Flip".
Isn't there a GraphicsLost() function ?
However, I should still need to find a way to detect this graphicslost.
I tried testing if the TImage = null or TGraphics = null, but they remain valid.
Sometimes, only the lower half of the image dissapears. Then, when trying it again, the rest of the image dissapears as well.
Beside the images, the DrawText command doesn't work either after this. I'm not loading/setting any fonts.
And at one point, I got an unhandled memory exception on "Flip".
Isn't there a GraphicsLost() function ?