[commit] r2511 - trunk/GME/ObjectInspector

GMESRC Repository Notifications gme-commit at list.isis.vanderbilt.edu
Fri Jul 11 17:16:19 CDT 2014


Author: ksmyth
Date: Fri Jul 11 17:16:19 2014
New Revision: 2511

Log:
Support multi-line attribute editor with spaces in path (surround by quotes)

Modified:
   trunk/GME/ObjectInspector/InPlaceManager.cpp

Modified: trunk/GME/ObjectInspector/InPlaceManager.cpp
==============================================================================
--- trunk/GME/ObjectInspector/InPlaceManager.cpp	Fri Jul 11 17:16:07 2014	(r2510)
+++ trunk/GME/ObjectInspector/InPlaceManager.cpp	Fri Jul 11 17:16:19 2014	(r2511)
@@ -476,7 +476,7 @@
 		catch (hresult_exception &) {
 		}
 
-		CString szCommandLine = _T(" ");
+		CString szCommandLine = szAppPath + _T(" ");
 		szCommandLine += szTempFileName;
 		int nCommandLineLength = szCommandLine.GetLength();
 
@@ -488,7 +488,7 @@
 
 		// start notepad.exe with the XML file name as the command line parameter
 
-		launched = ::CreateProcess(szAppPath,szCommandLine.GetBuffer(nCommandLineLength),
+		launched = ::CreateProcess(NULL, szCommandLine.GetBuffer(nCommandLineLength),
 			NULL,NULL,FALSE,0,NULL,NULL,&startUpInfo,&processInfo);
 		szCommandLine.ReleaseBuffer();
 		CloseHandle(processInfo.hProcess);
@@ -496,7 +496,10 @@
 	}
 
 	// DWORD h = ::WaitForSingleObject(processInfo.hProcess, INFINITE);
-	if( launched) m_EditorButton.MessageBox(_T("Click OK to finish."), _T("Using External Text Editor"), MB_ICONINFORMATION);
+	if (launched)
+	{
+		m_EditorButton.MessageBox(_T("Click OK to finish."), _T("Using External Text Editor"), MB_ICONINFORMATION);
+	}
 
 	// open temporary file
 	if (tempFile.Open(szTempFileName, CFile::modeRead | CFile::typeText) == 0) {


More information about the gme-commit mailing list