mainwindow.cpp
changeset 517 b525fdd445c4
parent 514 497fab7d1404
child 526 eacf1b165d2d
     1.1 --- a/mainwindow.cpp	Wed Jun 20 10:51:45 2007 +0000
     1.2 +++ b/mainwindow.cpp	Wed Jun 20 10:51:45 2007 +0000
     1.3 @@ -8,7 +8,6 @@
     1.4  #include "branchpropwindow.h"
     1.5  #include "exportoofiledialog.h"
     1.6  #include "exports.h"
     1.7 -#include "exportxhtmldialog.h"
     1.8  #include "file.h"
     1.9  #include "flagrowobj.h"
    1.10  #include "historywindow.h"
    1.11 @@ -2293,7 +2292,7 @@
    1.12  		currentMapEditor()->importDir();	
    1.13  }
    1.14  
    1.15 -void Main::fileExportXML()
    1.16 +void Main::fileExportXML()	//FIXME not scriptable yet
    1.17  {
    1.18  	if (currentMapEditor())
    1.19  	{
    1.20 @@ -2304,41 +2303,13 @@
    1.21  }
    1.22  
    1.23  
    1.24 -void Main::fileExportXHTML()
    1.25 +void Main::fileExportXHTML()	
    1.26  {
    1.27  	MapEditor *me=currentMapEditor();
    1.28 -	QString dir;
    1.29 -	if (me)
    1.30 -	{
    1.31 -		ExportXHTMLDialog dia(this);
    1.32 -		dia.setFilePath (me->getFilePath() );
    1.33 -		dia.setMapName (me->getMapName() );
    1.34 -		dia.readSettings();
    1.35 -		
    1.36 -		if (dia.exec()==QDialog::Accepted)
    1.37 -		{
    1.38 -			QString dir=dia.getDir();
    1.39 -			// Check, if warnings should be used before overwriting
    1.40 -			// the output directory
    1.41 -			WarningDialog warn;
    1.42 -			warn.showCancelButton (true);
    1.43 -			warn.setText(QString(
    1.44 -				"The directory %1 is not empty.\n"
    1.45 -				"Do you risk to overwrite some of its contents?").arg(dir));
    1.46 -			warn.setCaption("Warning: Directory not empty");
    1.47 -			warn.setShowAgainName("mainwindow/overwrite-dir-xhtml");
    1.48 -			if (warn.exec()==QDialog::Accepted)
    1.49 -			{
    1.50 -				me->exportXML (dia.getDir() );
    1.51 -				dia.doExport(me->getMapName() );
    1.52 -				if (dia.hasChanged())
    1.53 -					me->setChanged();
    1.54 -			}	
    1.55 -		}
    1.56 -	}	
    1.57 +	if (me) me->exportXHTML();
    1.58  }
    1.59  
    1.60 -void Main::fileExportImage()
    1.61 +void Main::fileExportImage()	
    1.62  {
    1.63  	MapEditor *me=currentMapEditor();
    1.64  	if (me) me->exportImage();
    1.65 @@ -2350,7 +2321,7 @@
    1.66  	if (me) me->exportASCII();
    1.67  }
    1.68  
    1.69 -void Main::fileExportCSV()
    1.70 +void Main::fileExportCSV()	//FIXME not scriptable yet
    1.71  {
    1.72  	MapEditor *me=currentMapEditor();
    1.73  	if (me)
    1.74 @@ -2369,7 +2340,7 @@
    1.75  	}
    1.76  }
    1.77  
    1.78 -void Main::fileExportLaTeX()
    1.79 +void Main::fileExportLaTeX()	//FIXME not scriptable yet
    1.80  {
    1.81  	MapEditor *me=currentMapEditor();
    1.82  	if (me)
    1.83 @@ -2388,7 +2359,7 @@
    1.84  	}
    1.85  }
    1.86  
    1.87 -void Main::fileExportKDEBookmarks()
    1.88 +void Main::fileExportKDEBookmarks()	//FIXME not scriptable yet
    1.89  {
    1.90  	ExportKDEBookmarks ex;
    1.91  	MapEditor *me=currentMapEditor();
    1.92 @@ -2399,7 +2370,7 @@
    1.93  	}	
    1.94  }
    1.95  
    1.96 -void Main::fileExportTaskjuggler()
    1.97 +void Main::fileExportTaskjuggler()	//FIXME not scriptable yet
    1.98  {
    1.99  	ExportTaskjuggler ex;
   1.100  	MapEditor *me=currentMapEditor();
   1.101 @@ -2418,7 +2389,7 @@
   1.102  	}	
   1.103  }
   1.104  
   1.105 -void Main::fileExportOOPresentation()
   1.106 +void Main::fileExportOOPresentation()	//FIXME not scriptable yet
   1.107  {
   1.108  	ExportOOFileDialog *fd=new ExportOOFileDialog( this,vymName+" - "+tr("Export to")+" Open Office");
   1.109  	// TODO add preview in dialog