- add OgreMeshKey support to OgreXMLDataObject

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@8109 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
3.0
nor..67 14 years ago
parent b78b994242
commit b569d2e0ef
  1. 11
      sdk/jme3-ogrexml/src/com/jme3/gde/ogrexml/OgreXMLDataObject.java

@ -31,7 +31,9 @@
*/ */
package com.jme3.gde.ogrexml; package com.jme3.gde.ogrexml;
import com.jme3.asset.ModelKey;
import com.jme3.gde.core.assets.SpatialAssetDataObject; import com.jme3.gde.core.assets.SpatialAssetDataObject;
import com.jme3.scene.plugins.ogre.OgreMeshKey;
import java.io.IOException; import java.io.IOException;
import org.openide.filesystems.FileObject; import org.openide.filesystems.FileObject;
import org.openide.loaders.DataObjectExistsException; import org.openide.loaders.DataObjectExistsException;
@ -43,4 +45,13 @@ public class OgreXMLDataObject extends SpatialAssetDataObject {
super(pf, loader); super(pf, loader);
} }
@Override
public ModelKey getAssetKey() {
if(super.getAssetKey() instanceof OgreMeshKey){
return (OgreMeshKey)assetKey;
}
assetKey = new OgreMeshKey(super.getAssetKey().getName());
return (OgreMeshKey)assetKey;
}
} }

Loading…
Cancel
Save