1.1 --- a/mapeditor.cpp Mon Mar 16 15:40:49 2009 +0000
1.2 +++ b/mapeditor.cpp Thu Mar 19 11:48:33 2009 +0000
1.3 @@ -301,6 +301,9 @@
1.4 mapAttr+= attribut("author",model->getAuthor()) +
1.5 attribut("comment",model->getComment()) +
1.6 attribut("date",model->getDate()) +
1.7 + attribut("date",model->getDate()) +
1.8 + attribut("countBranches", QString().number(model->countBranches())) +
1.9 +
1.10 attribut("backgroundColor", mapScene->backgroundBrush().color().name() ) +
1.11 attribut("selectionColor", xelection.getColor().name() ) +
1.12 attribut("linkStyle", ls ) +
1.13 @@ -1854,7 +1857,7 @@
1.14 if (!saveStringToDisk(fileDir+mapFileName,saveFile))
1.15 {
1.16 err=aborted;
1.17 - QMessageBox::critical (0,"Critical error in MapEditor::save",QString("could not sage %1").arg(fileDir+mapFileName));
1.18 + QMessageBox::critical (0,"Critical error in MapEditor::save",QString("could not save %1").arg(fileDir+mapFileName));
1.19 }
1.20
1.21 if (zipped)
1.22 @@ -5283,6 +5286,12 @@
1.23
1.24 void MapEditor::autosave()
1.25 {
1.26 + if (filePath=="")
1.27 + {
1.28 + if (debug) cout <<" ME::autosave rejected, no filepath available\n";
1.29 + return;
1.30 + }
1.31 +
1.32 QDateTime now=QDateTime().currentDateTime();
1.33 /* FIXME debug
1.34 cout << "ME::autosave checking "<<qPrintable(filePath)<<"...\n";
1.35 @@ -5291,6 +5300,7 @@
1.36 cout << " time: "<<qPrintable (now.toString())<<endl;
1.37 cout << " zipped="<<zipped<<endl;
1.38 */
1.39 +
1.40 // Disable autosave, while we have gone back in history
1.41 int redosAvail=undoSet.readNumEntry (QString("/history/redosAvail"));
1.42 if (redosAvail>0) return;