Mercurial > pidgin
comparison src/request.h @ 13282:a651bfe0a922
[gaim-migrate @ 15648]
Part of SF Patch #1175520 from Dennis Nezic with changes by Sadrul to support GTK+ < 2.4
This adds the folder selection function to the request API.
committer: Tailor Script <tailor@pidgin.im>
| author | Richard Laager <rlaager@wiktel.com> |
|---|---|
| date | Tue, 14 Feb 2006 07:45:07 +0000 |
| parents | 3638606a5afa |
| children | 29f03c8fba4a |
comparison
equal
deleted
inserted
replaced
| 13281:e629076386f1 | 13282:a651bfe0a922 |
|---|---|
| 40 { | 40 { |
| 41 GAIM_REQUEST_INPUT = 0, /**< Text input request. */ | 41 GAIM_REQUEST_INPUT = 0, /**< Text input request. */ |
| 42 GAIM_REQUEST_CHOICE, /**< Multiple-choice request. */ | 42 GAIM_REQUEST_CHOICE, /**< Multiple-choice request. */ |
| 43 GAIM_REQUEST_ACTION, /**< Action request. */ | 43 GAIM_REQUEST_ACTION, /**< Action request. */ |
| 44 GAIM_REQUEST_FIELDS, /**< Multiple fields request. */ | 44 GAIM_REQUEST_FIELDS, /**< Multiple fields request. */ |
| 45 GAIM_REQUEST_FILE /**< File open or save request. */ | 45 GAIM_REQUEST_FILE, /**< File open or save request. */ |
| 46 GAIM_REQUEST_FOLDER /**< Folder selection request. */ | |
| 46 | 47 |
| 47 } GaimRequestType; | 48 } GaimRequestType; |
| 48 | 49 |
| 49 /** | 50 /** |
| 50 * A type of field. | 51 * A type of field. |
| 203 void *user_data); | 204 void *user_data); |
| 204 void *(*request_file)(const char *title, const char *filename, | 205 void *(*request_file)(const char *title, const char *filename, |
| 205 gboolean savedialog, GCallback ok_cb, | 206 gboolean savedialog, GCallback ok_cb, |
| 206 GCallback cancel_cb, void *user_data); | 207 GCallback cancel_cb, void *user_data); |
| 207 void (*close_request)(GaimRequestType type, void *ui_handle); | 208 void (*close_request)(GaimRequestType type, void *ui_handle); |
| 209 void *(*request_folder)(const char *title, const char *dirname, | |
| 210 GCallback ok_cb, GCallback cancel_cb, | |
| 211 void *user_data); | |
| 208 } GaimRequestUiOps; | 212 } GaimRequestUiOps; |
| 209 | 213 |
| 210 typedef void (*GaimRequestInputCb)(void *, const char *); | 214 typedef void (*GaimRequestInputCb)(void *, const char *); |
| 211 typedef void (*GaimRequestActionCb)(void *, int); | 215 typedef void (*GaimRequestActionCb)(void *, int); |
| 212 typedef void (*GaimRequestChoiceCb)(void *, int); | 216 typedef void (*GaimRequestChoiceCb)(void *, int); |
| 1369 void *gaim_request_file(void *handle, const char *title, const char *filename, | 1373 void *gaim_request_file(void *handle, const char *title, const char *filename, |
| 1370 gboolean savedialog, | 1374 gboolean savedialog, |
| 1371 GCallback ok_cb, GCallback cancel_cb, | 1375 GCallback ok_cb, GCallback cancel_cb, |
| 1372 void *user_data); | 1376 void *user_data); |
| 1373 | 1377 |
| 1378 /** | |
| 1379 * Displays a folder select dialog. Returns the selected filename to | |
| 1380 * the callback. | |
| 1381 * | |
| 1382 * @param handle The plugin or connection handle. For some | |
| 1383 * things this is EXTREMELY important. See | |
| 1384 * the comments on gaim_request_input. | |
| 1385 * @param title The title for the dialog (may be @c NULL) | |
| 1386 * @param dirname The default directory name (may be @c NULL) | |
| 1387 * @param ok_cb The callback for the @c OK button. | |
| 1388 * @param cancel_cb The callback for the @c Cancel button. | |
| 1389 * @param user_data The data to pass to the callback. | |
| 1390 * | |
| 1391 * @return A UI-specific handle. | |
| 1392 */ | |
| 1393 void *gaim_request_folder(void *handle, const char *title, const char *dirname, | |
| 1394 GCallback ok_cb, GCallback cancel_cb, | |
| 1395 void *user_data); | |
| 1396 | |
| 1374 /*@}*/ | 1397 /*@}*/ |
| 1375 | 1398 |
| 1376 /**************************************************************************/ | 1399 /**************************************************************************/ |
| 1377 /** @name UI Registration Functions */ | 1400 /** @name UI Registration Functions */ |
| 1378 /**************************************************************************/ | 1401 /**************************************************************************/ |
