application/window.c

changeset 87
5360027fb282
parent 83
a612adaee43d
equal deleted inserted replaced
86:8e7c57c23133 87:5360027fb282
280 280
281 ui_show(obj); 281 ui_show(obj);
282 } 282 }
283 283
284 284
285 void transfer_window_init(UiObject *dialog, ui_callback btncallback) {
286 ui_window_size(dialog, 550, 120);
287 ui_grid(dialog, .margin = 10, .spacing = 10, .fill = TRUE) {
288 ui_llabel(dialog, .varname = "label_top_left", .hexpand = TRUE);
289 ui_rlabel(dialog, .varname = "label_top_right");
290 ui_newline(dialog);
291
292 ui_progressbar(dialog, .varname = "progressbar", .min = 0, .max = 100, .colspan = 2, .hexpand = TRUE);
293 ui_newline(dialog);
294
295 ui_llabel(dialog, .varname = "label_bottom_left", .hexpand = TRUE);
296 ui_rlabel(dialog, .varname = "label_bottom_right");
297 ui_newline(dialog);
298
299 ui_label(dialog, .vexpand = TRUE);
300 ui_newline(dialog);
301
302 ui_hbox(dialog, .colspan = 2, .hexpand = TRUE) {
303 ui_label(dialog, .hexpand = TRUE);
304 ui_button(dialog, .label = "Cancel", .onclick = btncallback);
305 }
306 }
307 }
308
285 309
286 static UiPathElm* dav_get_pathelm(const char *full_path, size_t len, size_t *ret_nelm, void* data) { 310 static UiPathElm* dav_get_pathelm(const char *full_path, size_t len, size_t *ret_nelm, void* data) {
287 if (len == 0) { 311 if (len == 0) {
288 *ret_nelm = 0; 312 *ret_nelm = 0;
289 return NULL; 313 return NULL;

mercurial