One last bit of information which I think may be very important: the problem only occurs if the window is maximized. If not, I cannot manage to reproduce the freeze. There may be some other ways, but, considering the short amount of time I tried, I couldn't make it freeze if the window was unmaximized.