mirror of
https://github.com/shadowfacts/lwjgl2-arm64.git
synced 2026-04-05 22:45:50 +00:00
Display.setIcon: Preserve icon buffer positions
This commit is contained in:
parent
32da20827a
commit
d3b13b23dd
1 changed files with 2 additions and 0 deletions
|
|
@ -1020,7 +1020,9 @@ public final class Display {
|
|||
cached_icons = new ByteBuffer[icons.length];
|
||||
for(int i=0;i<icons.length; i++) {
|
||||
cached_icons[i] = BufferUtils.createByteBuffer(icons[i].capacity());
|
||||
int old_position = icons[i].position();
|
||||
cached_icons[i].put(icons[i]);
|
||||
icons[i].position(old_position);
|
||||
cached_icons[i].flip();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue