openXmlPng(editor, fc.getSelectedFile());
}
else if (fc.getSelectedFile().getAbsolutePath()
.toLowerCase().endsWith(".txt"))
{
mxGdDocument document = new mxGdDocument();
document.parse(mxUtils.readFile(fc
.getSelectedFile()
.getAbsolutePath()));
openGD(editor, fc.getSelectedFile(),
document);
}
else
{
Document document = mxUtils
.parseXml(mxUtils.readFile(fc
.getSelectedFile()
.getAbsolutePath()));
if (fc.getSelectedFile().getAbsolutePath()
.toLowerCase().endsWith(".vdx"))
{
openVdx(editor, fc.getSelectedFile(),
document);
}
else
{
mxCodec codec = new mxCodec(document);
codec.decode(
document.getDocumentElement(),
graph.getModel());
editor.setCurrentFile(fc
.getSelectedFile());
}