mirror of
https://github.com/love2d/love.git
synced 2026-08-17 19:23:38 +02:00
Fix a use of std::remove_if
--HG-- branch : minor
This commit is contained in:
@@ -245,10 +245,12 @@ std::vector<Window::ContextAttribs> Window::getContextAttribsList() const
|
|||||||
|
|
||||||
if (removeES3)
|
if (removeES3)
|
||||||
{
|
{
|
||||||
std::remove_if(attribslist.begin(), attribslist.end(), [](ContextAttribs a)
|
auto it = std::remove_if(attribslist.begin(), attribslist.end(), [](ContextAttribs a)
|
||||||
{
|
{
|
||||||
return a.gles && a.versionMajor >= 3;
|
return a.gles && a.versionMajor >= 3;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
attribslist.erase(it, attribslist.end());
|
||||||
}
|
}
|
||||||
|
|
||||||
// Move OpenGL ES to the front of the list if we should prefer GLES.
|
// Move OpenGL ES to the front of the list if we should prefer GLES.
|
||||||
|
|||||||
Reference in New Issue
Block a user