]>
Commit | Line | Data |
---|---|---|
de6a1a64 RC |
1 | /* |
2 | * Copyright (c) 2001, Robert Collins. | |
3 | * | |
4 | * This program is free software; you can redistribute it and/or modify | |
5 | * it under the terms of the GNU General Public License as published by | |
6 | * the Free Software Foundation; either version 2 of the License, or | |
7 | * (at your option) any later version. | |
8 | * | |
9 | * A copy of the GNU General Public License can be found at | |
10 | * http://www.gnu.org/ | |
11 | * | |
12 | * Written by Robert Collins <rbtcollins@hotmail.com> | |
13 | * | |
14 | */ | |
15 | ||
16 | #ifndef _SITE_H_ | |
17 | #define _SITE_H_ | |
18 | ||
19 | /* required to parse this file */ | |
ab57ceaa RC |
20 | #include <string.h> |
21 | #include <stdlib.h> | |
de6a1a64 | 22 | #include "list.h" |
3c054baf | 23 | #include "String++.h" |
de6a1a64 | 24 | |
ab57ceaa RC |
25 | #include "proppage.h" |
26 | ||
27 | class SitePage:public PropertyPage | |
28 | { | |
29 | public: | |
30 | SitePage () | |
31 | { | |
32 | }; | |
33 | virtual ~ SitePage () | |
34 | { | |
35 | }; | |
36 | ||
37 | bool Create (); | |
38 | ||
39 | virtual void OnInit (); | |
b7301c43 | 40 | virtual void OnActivate (); |
ab57ceaa RC |
41 | virtual long OnNext (); |
42 | virtual long OnBack (); | |
b7301c43 RC |
43 | |
44 | virtual bool OnMessageCmd (int id, HWND hwndctl, UINT code); | |
45 | ||
46 | void PopulateListBox(); | |
47 | void CheckControlsAndDisableAccordingly () const; | |
ab57ceaa RC |
48 | }; |
49 | ||
50 | void do_download_site_info (HINSTANCE h, HWND owner); | |
51 | ||
de6a1a64 RC |
52 | class site_list_type |
53 | { | |
54 | public: | |
076654e7 | 55 | site_list_type ():url (), displayed_url (), key () |
ab57ceaa RC |
56 | { |
57 | }; | |
3c054baf | 58 | site_list_type (String const &); |
de6a1a64 | 59 | /* workaround for missing placement new in gcc 2.95 */ |
3c054baf RC |
60 | void init (String const &); |
61 | ~site_list_type () {}; | |
62 | String url; | |
63 | String displayed_url; | |
64 | String key; | |
de6a1a64 RC |
65 | }; |
66 | ||
67 | /* user chosen sites */ | |
3c054baf | 68 | extern list < site_list_type, String, String::casecompare > site_list; |
de6a1a64 | 69 | /* potential sites */ |
3c054baf | 70 | extern list < site_list_type, String, String::casecompare > all_site_list; |
de6a1a64 RC |
71 | |
72 | void save_site_url (); | |
73 | ||
74 | #endif /* _SITE_H_ */ |