- show correct material j3m in SceneExplorer

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7184 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
This commit is contained in:
nor..67 2011-04-04 17:05:27 +00:00
parent 6cab407283
commit c6a3a78b1e

View File

@ -81,7 +81,11 @@ public class MaterialPropertyEditor implements PropertyEditor {
}
public String getAsText() {
return material.toString();
String name = material.getAssetName();
if (name == null) {
name = "stored in file";
}
return name;
}
public void setAsText(final String text) throws IllegalArgumentException {
@ -109,7 +113,9 @@ public class MaterialPropertyEditor implements PropertyEditor {
public String[] getTags() {
SceneRequest request = SceneApplication.getApplication().getCurrentSceneRequest();
if(request==null) return new String[]{};
if (request == null) {
return new String[]{};
}
String[] mats = request.getManager().getMaterials();
return mats;
}