Hi, for now, I think the call to GetEvent is not neccessary. From the link above, you can see in its screenshot that there is a window with black background and a title bar with the "iiiiSkipBo" text. There is also a minimize, maximize and close buttons. When I ran this program in Ubuntu, it produces some black pixels with no window at all.
If I am wrong, please correct me. If I need to call the GetEvent, what will I do there? Is it something like
while (App.GetEvent(Event))
{
if (Event.Type == sf::Event::window_opened??)
//display titlebar here
}
Thanks!
No, you don't have to explicitly draw the Titlebar. Otherwise Laurent wouldn't have complaints about not being able to change the Titlebar every once in a while. XD
If you don't want to handle any events, just use this:
while (App.GetEvent(&Event)) // The & is required so that you don't get Memory Leaks and can actually use the Event variable
{
}
That way, the Window Event Queue won't overflow, you don't use any of the events, and the Window works properly. However, if you want the "X" button on the Titlebar to work, you will have to add a little event handling to the window.