SFML community forums

Bindings - other languages => DotNet => Topic started by: Kasko on December 14, 2018, 07:13:29 pm

Title: Why dragging the window prevents the window from being closed by window.Close()
Post by: Kasko on December 14, 2018, 07:13:29 pm
I tried to separate the event loop and the main loop so that the window continues rendering while dragging the window. I have achieved this through another thread.

But when I am dragging the window and meanwhile the code calls window.Close() the window stays open until I release the left mouse button.
Title: Re: Why dragging the window prevents the window from being closed by window.Close()
Post by: Gleade on December 21, 2018, 01:41:23 am
So, what's the problem here exactly? When would a user be exiting the application while simultaneously dragging the applications window?

Anyway, window events are "paused" until the window is released (as you have noticed).

Off-topic Note: I'd recommend creating a simple title for threads, and actually asking the question in the thread itself.
Title: Re: Why dragging the window prevents the window from being closed by window.Close()
Post by: yewbie on January 17, 2019, 09:36:53 pm
Your event loop is probably waiting for the message to return, are you doing message peek?
Post your windows event loop code.