private void cloneToolStripMenuItem_Click(object sender, EventArgs e)
{
TreeView treeView = GetTreeView(treeViewTabControl.SelectedIndex);
TreeNode selectedNode = treeView.SelectedNode;
string filePath = selectedNode.Tag != null ? selectedNode.Tag.ToString() : null;
if (filePath == null)
{
MessageBox.Show("Invalid effect file!");
return;
}
FileData selectedFileData = GetFileDataFromPath(filePath);
CloneEffectFileCallback callback = new CloneEffectFileCallback(this, selectedFileData);
CloneDialog dialog = new CloneDialog(selectedFileData.FileName, selectedFileData.GetNameForCloning());
dialog.SetCallback(callback);
dialog.ShowDialog();
}