diff options
Diffstat (limited to 'src/mainwin.cc')
-rw-r--r-- | src/mainwin.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mainwin.cc b/src/mainwin.cc index 783772c..fd1c552 100644 --- a/src/mainwin.cc +++ b/src/mainwin.cc @@ -632,7 +632,9 @@ void MainWindow::compile(bool reload, bool forcedone) // if we haven't yet compiled the current text. else { QString current_doc = editor->toPlainText(); - if (current_doc != last_compiled_doc) shouldcompiletoplevel = true; + if (current_doc != last_compiled_doc && last_compiled_doc.size() == 0) { + shouldcompiletoplevel = true; + } } } else { |