X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/03a90749df32e712f6f0c7a0de7bb1f1b1380b95..ebef1625fa59c555e45d2aa278de0ff5674d6142:/utils/helpview/src/helpview.cpp diff --git a/utils/helpview/src/helpview.cpp b/utils/helpview/src/helpview.cpp index 14e98cf8dc..290b2dab09 100644 --- a/utils/helpview/src/helpview.cpp +++ b/utils/helpview/src/helpview.cpp @@ -10,10 +10,6 @@ // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#ifdef __GNUG__ -#pragma implementation "help.cpp" -#endif - // For compilers that support precompilation, includes "wx/wx.h". #include "wx/wxprec.h" @@ -22,7 +18,7 @@ #endif // for all others, include the necessary headers (this file is usually all you -// need because it includes almost all "standard" wxWindows headers +// need because it includes almost all "standard" wxWidgets headers #ifndef WX_PRECOMP #include "wx/wx.h" #endif @@ -48,7 +44,7 @@ IMPLEMENT_APP(hvApp) hvApp::hvApp() { -#if hvUSE_IPC +#if wxUSE_IPC m_server = NULL; #endif } @@ -68,14 +64,15 @@ bool hvApp::OnInit() int istyle = wxHF_DEFAULT_STYLE; - wxString service, windowName, book[10], titleFormat, argStr; + wxString service, windowName, titleFormat, argStr; + wxString book[10]; int bookCount = 0; int i; bool hasService = false; bool hasWindowName = false; bool createServer = false; -#if hvUSE_IPC +#if wxUSE_IPC m_server = NULL; #endif @@ -158,7 +155,7 @@ bool hvApp::OnInit() wxOPEN | wxFILE_MUST_EXIST, NULL); - if (!s.IsEmpty()) + if (!s.empty()) { book[0] = s; bookCount = 1; @@ -166,7 +163,7 @@ bool hvApp::OnInit() } #endif -#if hvUSE_IPC +#if wxUSE_IPC if ( createServer ) { @@ -185,13 +182,13 @@ bool hvApp::OnInit() wxUnusedVar(createServer); } -#endif // hvUSE_IPC +#endif // wxUSE_IPC //now add help wxInitAllImageHandlers(); wxFileSystem::AddHandler(new wxZipFSHandler); - SetVendorName(wxT("wxWindows") ); + SetVendorName(wxT("wxWidgets") ); SetAppName(wxT("wxHTMLHelpServer") ); wxConfig::Get(); // create an instance @@ -228,11 +225,11 @@ bool hvApp::OnInit() int hvApp::OnExit() { -#if hvUSE_IPC - wxNode* node = m_connections.GetFirst(); +#if wxUSE_IPC + wxObjectList::compatibility_iterator node = m_connections.GetFirst(); while (node) { - wxNode* next = node->GetNext(); + wxObjectList::compatibility_iterator next = node->GetNext(); hvConnection* connection = (hvConnection*) node->GetData(); connection->Disconnect(); delete connection; @@ -304,22 +301,7 @@ void hvApp::MacOpenFile(const wxString& filename) #define ART(artId, xpmRc) \ if ( id == artId ) return wxBitmap(xpmRc##_xpm); -// Compatibility hack to use wxApp::GetStdIcon of overriden by the user -#if WXWIN_COMPATIBILITY_2_2 -#define GET_STD_ICON_FROM_APP(iconId) \ - if ( client == wxART_MESSAGE_BOX ) \ -{ \ - wxIcon icon = wxTheApp->GetStdIcon(iconId); \ - if ( icon.Ok() ) \ -{ \ - wxBitmap bmp; \ - bmp.CopyFromIcon(icon); \ - return bmp; \ -} \ -} -#else #define GET_STD_ICON_FROM_APP(iconId) -#endif // There are two ways of getting the standard icon: either via XPMs or via // wxIcon ctor. This depends on the platform: @@ -395,12 +377,12 @@ wxBitmap AlternateArtProvider::CreateBitmap(const wxArtID& id, //ART(wxART_GO_HOME, home) - // Any wxWindows icons not implemented here + // Any wxWidgets icons not implemented here // will be provided by the default art provider. return wxNullBitmap; } -#if hvUSE_IPC +#if wxUSE_IPC wxConnectionBase *hvServer::OnAcceptConnection(const wxString& topic) { @@ -520,4 +502,4 @@ bool hvConnection::OnStartAdvise(const wxString& WXUNUSED(topic), return true; } -#endif // #if hvUSE_IPC +#endif // #if wxUSE_IPC