application/application.h

changeset 95
e92c72705da4
parent 89
2fbb3cac05a5
child 97
5a3d27b8e6b0
equal deleted inserted replaced
94:7fdf1489b82f 95:e92c72705da4
50 #define RESOURCEVIEWER_STATE_MODIFIED 2000 50 #define RESOURCEVIEWER_STATE_MODIFIED 2000
51 51
52 typedef struct DavApp { 52 typedef struct DavApp {
53 DavConfig *dav_config; 53 DavConfig *dav_config;
54 UiList *repos; 54 UiList *repos;
55 UiList *transfers;
55 } DavApp; 56 } DavApp;
56 57
58 // download/upload
59 typedef struct DavTransfer {
60 char *label;
61 size_t label_len;
62 double progress;
63 UiObject *window;
64 time_t last_update;
65 } DavTransfer;
57 66
58 typedef enum DavResourceViewType { 67 typedef enum DavResourceViewType {
59 DAV_RESOURCE_VIEW_PROPERTIES = 0, 68 DAV_RESOURCE_VIEW_PROPERTIES = 0,
60 DAV_RESOURCE_VIEW_TEXT, 69 DAV_RESOURCE_VIEW_TEXT,
61 DAV_RESOURCE_VIEW_IMAGE 70 DAV_RESOURCE_VIEW_IMAGE
65 74
66 /* 75 /*
67 * main window document object 76 * main window document object
68 */ 77 */
69 typedef struct DavBrowser { 78 typedef struct DavBrowser {
79 UiObject *window;
80
70 UiContext *ctx; 81 UiContext *ctx;
71 DavSession *sn; 82 DavSession *sn;
72 UiThreadpool *dav_queue; 83 UiThreadpool *dav_queue;
73 84
74 CxMap *res_open_inprogress; 85 CxMap *res_open_inprogress;
160 */ 171 */
161 void application_create_menu(void); 172 void application_create_menu(void);
162 173
163 DavApp* get_application(void); 174 DavApp* get_application(void);
164 175
176 void* transfers_getlabel(void *data, int col);
177
178 void application_register_transfer(DavTransfer *trans);
179 void application_remove_transfer(DavTransfer *trans);
180 void application_update_transferlist(void);
181
165 DavApp* application_create_app_document(void); 182 DavApp* application_create_app_document(void);
166 183
167 void application_update_repolist(DavApp *app); 184 void application_update_repolist(DavApp *app);
168 185
169 DavContext* application_dav_context(void); 186 DavContext* application_dav_context(void);
193 void action_mkcol(UiEvent *event, void *data); 210 void action_mkcol(UiEvent *event, void *data);
194 211
195 void action_open_settings(UiEvent *event, void *data); 212 void action_open_settings(UiEvent *event, void *data);
196 213
197 void action_open_properties(UiEvent *event, void *data); 214 void action_open_properties(UiEvent *event, void *data);
215
216 void action_transfer_selected(UiEvent *event, void *data);
198 217
199 #ifdef __cplusplus 218 #ifdef __cplusplus
200 } 219 }
201 #endif 220 #endif
202 221

mercurial