Fixed particular slowdown in OS X startup window

During loading of .pk3 that stores hundred of .wad's significant amount of time were spent on scrolling text to the last line
The same applies to other cases like output of thousands warnings/errors
This commit is contained in:
alexey.lysiuk 2016-02-28 11:03:40 +02:00 committed by Christoph Oelckers
parent c687394f72
commit 145b7be0a1

View file

@ -312,10 +312,11 @@ void FConsoleWindow::AddText(const char* message)
}
if ([m_window isVisible])
{
UpdateTimed([&]()
{
[m_textView scrollRangeToVisible:NSMakeRange(m_characterCount, 0)];
[[NSRunLoop currentRunLoop] limitDateForMode:NSDefaultRunLoopMode];
});
}
}