mapeditor.cpp
changeset 631 ba4a99830ad1
parent 628 d7d0708b1c60
child 638 3436b8eb3d9b
     1.1 --- a/mapeditor.cpp	Tue Dec 04 12:32:59 2007 +0000
     1.2 +++ b/mapeditor.cpp	Wed Dec 05 14:58:03 2007 +0000
     1.3 @@ -1624,23 +1624,26 @@
     1.4  
     1.5  	QString saveFile;
     1.6  	if (savemode==CompleteMap || xelection.isEmpty())
     1.7 +	{
     1.8 +		// Save complete map
     1.9  		saveFile=saveToDir (fileDir,mapName+"-",true,QPointF(),NULL);
    1.10 +		mapChanged=false;
    1.11 +		mapUnsaved=false;
    1.12 +		autosaveTimer->stop();
    1.13 +	}
    1.14  	else	
    1.15  	{
    1.16 -		// TODO take care of multiselections
    1.17 +		// Save part of map
    1.18  		if (xelection.type()==Selection::FloatImage)
    1.19  			saveFloatImage();
    1.20  		else	
    1.21  			saveFile=saveToDir (fileDir,mapName+"-",true,QPointF(),xelection.getBranch());	
    1.22 -		return 0;	
    1.23 +		// TODO take care of multiselections
    1.24  	}	
    1.25  
    1.26  	if (!saveStringToDisk(fileDir+fname,saveFile))
    1.27  		return 1;
    1.28  
    1.29 -	mapChanged=false;
    1.30 -	mapUnsaved=false;
    1.31 -	autosaveTimer->stop();
    1.32  	updateActions();
    1.33  	return 0;
    1.34  }