The rounded corners look really dumb at this size.
[wxWidgets.git] / utils / helpview / src / remhelp.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: remhelp.h
3 // Purpose: Remote help controller class
4 // Author: Eric Dowty
5 // Modified by:
6 // Created: 2002-11-18
7 // Copyright: (c) Julian Smart
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
10
11 #ifndef _WX_REMHELP_H_
12 #define _WX_REMHELP_H_
13
14 #include <wx/helpbase.h>
15 #include <wx/ipc.h>
16 #include <wx/html/helpctrl.h>
17
18 class WXDLLIMPEXP_FWD_BASE wxConfigBase;
19
20 class rhhcConnection : public wxConnection
21 {
22 public:
23 rhhcConnection(bool *isconn_a);
24 virtual ~rhhcConnection();
25
26 bool OnAdvise(const wxString& topic, const wxString& item, char *data, int size, wxIPCFormat format);
27 bool OnDisconnect();
28 bool *isconn_3;
29
30 };
31
32 class rhhcClient: public wxClient
33 {
34 public:
35 rhhcClient(bool *isconn_a);
36 //~rhhcClient( );
37 wxConnectionBase *OnMakeConnection();
38 bool *isconn_2;
39 };
40
41 class wxRemoteHtmlHelpController : public wxHelpControllerBase
42 {
43 DECLARE_CLASS(wxRemoteHtmlHelpController)
44 public:
45 wxRemoteHtmlHelpController(int style = wxHF_DEFAULT_STYLE);
46 virtual ~wxRemoteHtmlHelpController();
47 void OnQuit(void);
48
49 void SetService(wxString& a_service);
50 void SetServer(wxString& a_appname); //could be wxHelpController::SetViewer
51
52 //standard wxHtmlHelpController functions
53 bool AddBook(const wxString& book, bool show_wait_msg = false);
54 void Display(const wxString& x);
55 void Display(const int id);
56 bool DisplayContents();
57 void DisplayIndex();
58 bool KeywordSearch(const wxString& keyword);
59 void SetTempDir(const wxString& path);
60 void SetTitleFormat(const wxString& format);
61
62 //dummies - config is in server
63 void UseConfig(wxConfigBase* config, const wxString& rootpath = wxEmptyString) {};
64 void ReadCustomization(wxConfigBase* cfg, wxString path = wxEmptyString) {};
65 void WriteCustomization(wxConfigBase* cfg, wxString path = wxEmptyString) {};
66
67 //virtuals from wxHelpControllerBase - not in wxHtmlHelpController
68 //won't compile without these
69 bool LoadFile(const class wxString &); //dummy
70 bool DisplaySection(int);
71 bool DisplayBlock(long);
72 bool Quit(void);
73
74 private:
75 void OnExit(wxCommandEvent& event);
76 bool DoConnection();
77
78 rhhcConnection *m_connection;
79 rhhcClient *m_client;
80 wxProcess *m_process;
81
82 int m_pid;
83 int m_style;
84 wxString m_appname;
85 wxString m_service;
86 wxString m_windowname;
87 wxString m_book;
88 bool isconn_1;
89 };
90
91 #endif
92 // _WX_REMHELP_H_