renamed m_MapFile into m_helpDir because this is what it really is

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@38393 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2006-03-27 20:05:07 +00:00
parent 5536310df9
commit 2364556be3
2 changed files with 8 additions and 8 deletions

View File

@@ -144,7 +144,7 @@ public:
protected: protected:
/// Filename of currently active map file. /// Filename of currently active map file.
wxString m_MapFile; wxString m_helpDir;
/// How many entries do we have in the map file? /// How many entries do we have in the map file?
int m_NumOfEntries; int m_NumOfEntries;
/// A list containing all id,url,documentation triples. /// A list containing all id,url,documentation triples.

View File

@@ -115,7 +115,7 @@ wxExtHelpController::DisplayHelp(const wxString &relativeURL)
#if defined(__WXMSW__) #if defined(__WXMSW__)
wxString url; wxString url;
url << m_MapFile << '\\' << relativeURL.BeforeFirst('#'); url << m_helpDir << '\\' << relativeURL.BeforeFirst('#');
bool bOk = (int)ShellExecute(NULL, wxT("open"), url.c_str(), bool bOk = (int)ShellExecute(NULL, wxT("open"), url.c_str(),
NULL, NULL, SW_SHOWNORMAL ) > 32; NULL, NULL, SW_SHOWNORMAL ) > 32;
if ( !bOk ) if ( !bOk )
@@ -128,7 +128,7 @@ wxExtHelpController::DisplayHelp(const wxString &relativeURL)
#elif defined(__OS2__) #elif defined(__OS2__)
wxString url; wxString url;
url << m_MapFile << '\\' << relativeURL.BeforeFirst('#'); url << m_helpDir << '\\' << relativeURL.BeforeFirst('#');
// will have to fix for OS/2, later.....DW // will have to fix for OS/2, later.....DW
// bool bOk = (int)ShellExecute(NULL, "open", url, // bool bOk = (int)ShellExecute(NULL, "open", url,
// NULL, NULL, SW_SHOWNORMAL ) > 32; // NULL, NULL, SW_SHOWNORMAL ) > 32;
@@ -145,7 +145,7 @@ wxExtHelpController::DisplayHelp(const wxString &relativeURL)
wxString command; wxString command;
command = m_BrowserName; command = m_BrowserName;
command << wxT(" file://") command << wxT(" file://")
<< m_MapFile << wxFILE_SEP_PATH << relativeURL; << m_helpDir << wxFILE_SEP_PATH << relativeURL;
return wxExecute(command) != 0; return wxExecute(command) != 0;
#else // UNIX #else // UNIX
@@ -170,7 +170,7 @@ wxExtHelpController::DisplayHelp(const wxString &relativeURL)
{ {
long success; long success;
command << m_BrowserName << wxT(" -remote openURL(") command << m_BrowserName << wxT(" -remote openURL(")
<< wxT("file://") << m_MapFile << wxT("file://") << m_helpDir
<< wxFILE_SEP_PATH << relativeURL << wxT(")"); << wxFILE_SEP_PATH << relativeURL << wxT(")");
success = wxExecute(command); success = wxExecute(command);
if(success != 0 ) // returns PID on success if(success != 0 ) // returns PID on success
@@ -180,7 +180,7 @@ wxExtHelpController::DisplayHelp(const wxString &relativeURL)
#endif #endif
command = m_BrowserName; command = m_BrowserName;
command << wxT(" file://") command << wxT(" file://")
<< m_MapFile << wxFILE_SEP_PATH << relativeURL; << m_helpDir << wxFILE_SEP_PATH << relativeURL;
return wxExecute(command) != 0; return wxExecute(command) != 0;
#endif #endif
} }
@@ -366,7 +366,7 @@ bool wxExtHelpController::LoadFile(const wxString& file)
return false; return false;
} }
m_MapFile = helpDir.GetFullPath(); // now it's valid m_helpDir = helpDir.GetFullPath(); // now it's valid
return true; return true;
} }
@@ -393,7 +393,7 @@ wxExtHelpController::DisplayContents()
bool rc = false; bool rc = false;
wxString file; wxString file;
file << m_MapFile << wxFILE_SEP_PATH << contents; file << m_helpDir << wxFILE_SEP_PATH << contents;
if(file.Contains(wxT('#'))) if(file.Contains(wxT('#')))
file = file.BeforeLast(wxT('#')); file = file.BeforeLast(wxT('#'));
if(contents.length() && wxFileExists(file)) if(contents.length() && wxFileExists(file))