]> git.saurik.com Git - wxWidgets.git/blobdiff - utils/helpview/src/helpview.cpp
update the intl.* files directly from genlang.py script instead of generating snippet...
[wxWidgets.git] / utils / helpview / src / helpview.cpp
index 290b2dab09810e7d3a3bc80a372e22b6ad6f8908..bbb44a061d209fc3ef03cfbca5cf0fe887438d07 100644 (file)
@@ -55,11 +55,11 @@ bool hvApp::OnInit()
     delete wxLog::SetActiveTarget(new wxLogStderr); // So dialog boxes aren't used
 #endif
 
     delete wxLog::SetActiveTarget(new wxLogStderr); // So dialog boxes aren't used
 #endif
 
-    wxArtProvider::PushProvider(new AlternateArtProvider);
+    wxArtProvider::Push(new AlternateArtProvider);
 
 
-#ifdef __WXMAC__
+#if defined( __WXOSX_MAC__ ) && wxOSX_USE_CARBON
     wxApp::s_macAboutMenuItemId = wxID_ABOUT;
     wxApp::s_macAboutMenuItemId = wxID_ABOUT;
-    wxFileName::MacRegisterDefaultTypeAndCreator( "htb" , 'HTBD' , 'HTBA' ) ;
+    wxFileName::MacRegisterDefaultTypeAndCreator( wxT("htb") , 'HTBD' , 'HTBA' ) ;
 #endif
 
     int istyle = wxHF_DEFAULT_STYLE;
 #endif
 
     int istyle = wxHF_DEFAULT_STYLE;
@@ -152,7 +152,7 @@ bool hvApp::OnInit()
             wxEmptyString,
             wxEmptyString,
             wxT("Help books (*.htb)|*.htb|Help books (*.zip)|*.zip|HTML Help Project (*.hhp)|*.hhp"),
             wxEmptyString,
             wxEmptyString,
             wxT("Help books (*.htb)|*.htb|Help books (*.zip)|*.zip|HTML Help Project (*.hhp)|*.hhp"),
-            wxOPEN | wxFILE_MUST_EXIST,
+            wxFD_OPEN | wxFD_FILE_MUST_EXIST,
             NULL);
 
         if (!s.empty())
             NULL);
 
         if (!s.empty())
@@ -259,7 +259,7 @@ bool hvApp::OpenBook(wxHtmlHelpController* controller)
         _(
         "Help books (*.htb)|*.htb|Help books (*.zip)|*.zip|\
         HTML Help Project (*.hhp)|*.hhp"),
         _(
         "Help books (*.htb)|*.htb|Help books (*.zip)|*.zip|\
         HTML Help Project (*.hhp)|*.hhp"),
-        wxOPEN | wxFILE_MUST_EXIST,
+        wxFD_OPEN | wxFD_FILE_MUST_EXIST,
         NULL);
 
     if ( !s.empty() )
         NULL);
 
     if ( !s.empty() )
@@ -407,14 +407,12 @@ hvConnection::~hvConnection()
     wxGetApp().GetConnections().DeleteObject(this);
 }
 
     wxGetApp().GetConnections().DeleteObject(this);
 }
 
-bool hvConnection::OnExecute(const wxString& WXUNUSED(topic),
-                             wxChar *data,
-                             int WXUNUSED(size),
-                             wxIPCFormat WXUNUSED(format))
+bool hvConnection::OnExec(const wxString& WXUNUSED(topic),
+                          const wxString& data)
 {
     //    wxLogStatus("Execute command: %s", data);
 
 {
     //    wxLogStatus("Execute command: %s", data);
 
-    if ( !wxStrncmp( data, wxT("--intstring"), 11 ) )
+    if ( data == "--intstring" )
     {
         long i;
         wxString argStr = data;
     {
         long i;
         wxString argStr = data;
@@ -438,10 +436,12 @@ bool hvConnection::OnExecute(const wxString& WXUNUSED(topic),
 
 bool hvConnection::OnPoke(const wxString& WXUNUSED(topic),
                           const wxString& item,
 
 bool hvConnection::OnPoke(const wxString& WXUNUSED(topic),
                           const wxString& item,
-                          wxChar *data,
-                          int WXUNUSED(size),
-                          wxIPCFormat WXUNUSED(format))
+                          const void *buf,
+                          size_t size,
+                          wxIPCFormat format)
 {
 {
+    const wxString data = GetTextFromData(buf, size, format);
+
     //    wxLogStatus("Poke command: %s = %s", item.c_str(), data);
     //topic is not tested
 
     //    wxLogStatus("Poke command: %s = %s", item.c_str(), data);
     //topic is not tested
 
@@ -488,18 +488,4 @@ bool hvConnection::OnPoke(const wxString& WXUNUSED(topic),
     return true;
 }
 
     return true;
 }
 
-wxChar *hvConnection::OnRequest(const wxString& WXUNUSED(topic),
-                                const wxString& WXUNUSED(item),
-                                int * WXUNUSED(size),
-                                wxIPCFormat WXUNUSED(format))
-{
-    return NULL;
-}
-
-bool hvConnection::OnStartAdvise(const wxString& WXUNUSED(topic),
-                                 const wxString& WXUNUSED(item))
-{
-    return true;
-}
-
 #endif // #if wxUSE_IPC
 #endif // #if wxUSE_IPC