/[winpt]/trunk/Include/wptContext.h
ViewVC logotype

Annotation of /trunk/Include/wptContext.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 23 - (hide annotations)
Fri Sep 30 10:10:16 2005 UTC (19 years, 5 months ago) by twoaday
File MIME type: text/plain
File size: 3238 byte(s)
Almost finished phase 1 of the WinPT GPGME port.
Still need more cleanup, comments and tests.


1 twoaday 2 /* wptContext.h - Internal file to store private contexts
2     * Copyright (C) 2001-2005 Timo Schulz
3     *
4     * This file is part of WinPT.
5     *
6     * WinPT is free software; you can redistribute it and/or modify
7     * it under the terms of the GNU General Public License as published by
8     * the Free Software Foundation; either version 2 of the License, or
9     * (at your option) any later version.
10     *
11     * WinPT is distributed in the hope that it will be useful,
12     * but WITHOUT ANY WARRANTY; without even the implied warranty of
13     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14     * GNU General Public License for more details.
15     *
16     * You should have received a copy of the GNU General Public License
17     * along with WinPT; if not, write to the Free Software Foundation,
18     * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
19     */
20    
21     #ifndef WPT_CONTEXT_H
22     #define WPT_CONTEXT_H
23    
24     struct subclass_s {
25     HWND dlg;
26 twoaday 23 WNDPROC old; /* old window procedure */
27     WNDPROC current; /* the subclass window procedure */
28 twoaday 2 void * opaque;
29     };
30    
31 twoaday 23 /* Container for a gpgme key. */
32 twoaday 2 struct winpt_key_s {
33 twoaday 23 const char *uid;
34     const char *keyid;
35     unsigned int key_pair:1; /* is a complete key. */
36     unsigned int is_protected:1; /* secret key is protected. */
37     unsigned int update:1; /* 1=need to reload key. */
38     unsigned int is_v3:1; /* key is version 3 (RSA/MD5) */
39 twoaday 2 unsigned int flags;
40 twoaday 22 gpgme_key_t ctx;
41 twoaday 23 struct keycache_s *ext;
42     /* Callback structure if a listview needs to be updated. */
43 twoaday 2 struct {
44 twoaday 23 listview_ctrl_t ctl; /* the listview control. */
45     int idx; /* selected index. */
46 twoaday 2 int new_val;
47     } callback;
48     };
49     typedef struct winpt_key_s * winpt_key_t;
50    
51     struct text_input_s {
52 twoaday 23 char *data; /* input data. */
53     size_t length; /* length of input data. */
54     int type; /* type of data (0=text data for signature) */
55 twoaday 2 };
56    
57     struct date_s {
58 twoaday 23 int cancel; /* cancel was hit. */
59     const char * text; /* text used as the title. */
60     SYSTEMTIME st; /* selected time by the user. */
61 twoaday 2 };
62    
63     struct md_file_s {
64     int mdalgo;
65     listview_ctrl_t lv;
66     };
67    
68     struct secdel_confirm_s {
69 twoaday 23 unsigned int yes:1; /* if yes=1 user confirmed delete. */
70     listview_ctrl_t lv_files;/* listview control with the files to delete. */
71 twoaday 2 };
72    
73     struct import_status_s {
74     int import_res[14];
75     unsigned int rev_cert:1;
76     };
77    
78     struct progress_filter_s {
79 twoaday 4 HWND hwnd;
80 twoaday 2 HWND dlg;
81     HANDLE thread_hd;
82     int error;
83 twoaday 23 const char *what;
84 twoaday 2 int type;
85     unsigned curr;
86     unsigned total;
87     };
88    
89    
90 twoaday 18 struct URL_ctx_s {
91 twoaday 23 const char *title; /* title for the dialog. */
92     const char *desc; /* description of what to do. */
93     char url[256]; /* the selected URL. */
94 twoaday 2 char proxy[64];
95 twoaday 23 int port; /* the port to use. */
96     int cancel; /* user cancelled operation. */
97     int check; /* use strict URL checking. */
98 twoaday 2 };
99    
100 twoaday 22 struct first_start_s {
101     int choice;
102     };
103    
104     struct genkey_s {
105     gpgme_key_t newkey;
106 twoaday 2 int interactive;
107 twoaday 22 unsigned int first_start:1;
108 twoaday 2 };
109    
110     #endif /* WPT_CONTEXT_H */

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26