public void UpdateDataEditor() { if (sed != null) { sed.saveData(null, null); sed.Parent = null; } sed = null; if (SelectedObjects == null) { return; } int type = getSpriteType(); if (type != -1 && SpriteData.datas.ContainsKey(type)) { sed = new SpriteData.SpriteDataEditor(SelectedObjects, SpriteData.datas[type], EdControl); spriteDataPanel.Controls.Add(sed); sed.Dock = DockStyle.Fill; //sed.Parent = spriteDataPanel; spriteDataPanel.Visible = true; } else { spriteDataPanel.Visible = false; } }
public void UpdateDataEditor() { if (sed != null) { sed.saveData(null, null); sed.Parent = null; } sed = null; if (SelectedObjects == null) return; int type = getSpriteType(); if (type != -1 && SpriteData.datas.ContainsKey(type)) { sed = new SpriteData.SpriteDataEditor(SelectedObjects, SpriteData.datas[type], EdControl); spriteDataPanel.Controls.Add(sed); sed.Dock = DockStyle.Fill; //sed.Parent = spriteDataPanel; spriteDataPanel.Visible = true; } else { spriteDataPanel.Visible = false; } }