Mercurial > hg > forks > UniversalIndentGUI
changeset 75:4954b0ca36e0
[Add] Feature Request ID 1660068: If no config file name is given in the uigui ini file, it is assumed to call the indenter only via command line.
git-svn-id: svn://svn.code.sf.net/p/universalindent/code/trunk@232 59b1889a-e5ac-428c-b0c7-476e01d41282
author | thomas_-_s <thomas_-_s@59b1889a-e5ac-428c-b0c7-476e01d41282> |
---|---|
date | Wed, 14 Feb 2007 21:26:02 +0000 |
parents | 7664e005dbc4 |
children | be5bb071e6c5 |
files | src/indenthandler.cpp |
diffstat | 1 files changed, 10 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/indenthandler.cpp Wed Feb 14 21:24:32 2007 +0000 +++ b/src/indenthandler.cpp Wed Feb 14 21:26:02 2007 +0000 @@ -89,7 +89,10 @@ // generate the parameter string that will be save to the indenters config file QString parameterString = getParameterString(); - writeConfigFile( parameterString ); + + if ( !configFilename.isEmpty() ) { + writeConfigFile( parameterString ); + } QString formattedSourceCode; bool wineInstalled = true; @@ -102,6 +105,12 @@ QFile::remove(dataDirctoryStr + inputFileName + inputFileExtension); QFile outSrcFile(dataDirctoryStr + inputFileName + inputFileExtension); QString indentCallString = inputFileParameter + inputFileName + inputFileExtension; + + // If the config file name is empty it is assumed that all parameters are sent via command line call + if ( configFilename.isEmpty() ) { + indentCallString += " " + parameterString; + } + if ( outputFileParameter != "none" ) { indentCallString += " "+ outputFileParameter + outputFileName + inputFileExtension; }