mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/PCK-Studio.git
synced 2026-07-15 18:58:11 +00:00
CustomSkinEditor - Fix skin texture locking file handle
This commit is contained in:
@@ -136,10 +136,10 @@ namespace PckStudio.Forms.Editor
|
||||
|
||||
if (openFileDialog.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
using (var img = Image.FromFile(openFileDialog.FileName))
|
||||
{
|
||||
renderer3D1.Texture = img;
|
||||
}
|
||||
generateTextureCheckBox.Checked = false;
|
||||
// use stream to not leave handle open
|
||||
using (var imgFs = File.OpenRead(openFileDialog.FileName))
|
||||
renderer3D1.Texture = Image.FromStream(imgFs);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user