瀏覽代碼

Fixes #88 - TextureBrowser: Release the old Texture when setting the path to a new one.

MeFisto94 9 年之前
父節點
當前提交
94565fc3ea
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      jme3-core/src/com/jme3/gde/core/properties/TextureBrowser.java

+ 1 - 0
jme3-core/src/com/jme3/gde/core/properties/TextureBrowser.java

@@ -234,6 +234,7 @@ private void noTexturebuttonActionPerformed(java.awt.event.ActionEvent evt) {//G
             selected = selected.substring(0, selected.lastIndexOf("/"));
 //            Texture tex = assetManager.loadTexture(selected);
 //            editor.setValue(tex);
+            editor.setValue(null); // Invalidate the old texture
             editor.setAsText(selected);
             return true;
         }