comparison gui/src/MainWindow.cpp @ 14669:7605e7136b50 gui

Discarded initFileEditor, instead put that in the constructor. Speedup for updating the symbol table by lowering complexity from n² to n. Fixed problem with hangup on quit. * FileEditor: Removed initFileEditor, put that code into the constructor. * WorkspaceModel: Simplified updating the symbol table. * OctaveLink: Add quit_allowed = true to prevent hangup on quit.
author Jacob Dawid <jacob.dawid@googlemail.com>
date Tue, 22 May 2012 11:00:24 +0200
parents c8453a013000
children 7fbea449737d
comparison
equal deleted inserted replaced
14668:6a6733a55982 14669:7605e7136b50
51 } 51 }
52 52
53 void 53 void
54 MainWindow::newEditorWindow (QString fileName) 54 MainWindow::newEditorWindow (QString fileName)
55 { 55 {
56 FileEditor *fileEditor = new FileEditor (); 56 FileEditor *fileEditor = new FileEditor (m_terminalView, m_lexer, this);
57 fileEditor->setAttribute (Qt::WA_DeleteOnClose); 57 fileEditor->setAttribute (Qt::WA_DeleteOnClose);
58 fileEditor->initEditor(m_terminalView, m_lexer, this); // init necessary informations for editor
59 58
60 if (fileName.isEmpty ()) 59 if (fileName.isEmpty ())
61 fileEditor->newFile (); 60 fileEditor->newFile ();
62 else 61 else
63 fileEditor->loadFile (fileName); 62 fileEditor->loadFile (fileName);