void MussaWindow::clear()
{
+ if (motif_editor != 0) {
+ motif_editor->hide();
+ delete motif_editor;
+ }
+
aligned_windows.clear();
browser->clear();
}
void MussaWindow::editMotifs()
{
- if (motif_editor != 0) {
- motif_editor->hide();
- delete motif_editor;
+ if (not motif_editor) {
+ motif_editor = new MotifEditor(analysis);
+ connect(motif_editor, SIGNAL(changedMotifs()),
+ this, SLOT(updateAnnotations()));
}
- motif_editor = new MotifEditor(analysis);
- connect(motif_editor, SIGNAL(changedMotifs()),
- this, SLOT(updateAnnotations()));
motif_editor->show();
}