Mercurial > vim
comparison src/dict.c @ 17123:efc6f5e3b543 v8.1.1561
patch 8.1.1561: popup_setoptions() is not implemented yet
commit https://github.com/vim/vim/commit/ae943150d3a2868a89df802c9f530331474451ec
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Jun 16 22:54:14 2019 +0200
patch 8.1.1561: popup_setoptions() is not implemented yet
Problem: Popup_setoptions() is not implemented yet.
Solution: Implement popup_setoptions(). Also add more fields to
popup_getoptions().
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 16 Jun 2019 23:00:05 +0200 |
parents | 23645f9a5ce2 |
children | 3fd0765f454f |
comparison
equal
deleted
inserted
replaced
17122:310e8655d123 | 17123:efc6f5e3b543 |
---|---|
446 } | 446 } |
447 return OK; | 447 return OK; |
448 } | 448 } |
449 | 449 |
450 /* | 450 /* |
451 * Add a callback to dictionary "d". | |
452 * Returns FAIL when out of memory and when key already exists. | |
453 */ | |
454 int | |
455 dict_add_callback(dict_T *d, char *key, callback_T *cb) | |
456 { | |
457 dictitem_T *item; | |
458 | |
459 item = dictitem_alloc((char_u *)key); | |
460 if (item == NULL) | |
461 return FAIL; | |
462 put_callback(cb, &item->di_tv); | |
463 if (dict_add(d, item) == FAIL) | |
464 { | |
465 dictitem_free(item); | |
466 return FAIL; | |
467 } | |
468 return OK; | |
469 } | |
470 | |
471 /* | |
451 * Initializes "iter" for iterating over dictionary items with | 472 * Initializes "iter" for iterating over dictionary items with |
452 * dict_iterate_next(). | 473 * dict_iterate_next(). |
453 * If "var" is not a Dict or an empty Dict then there will be nothing to | 474 * If "var" is not a Dict or an empty Dict then there will be nothing to |
454 * iterate over, no error is given. | 475 * iterate over, no error is given. |
455 * NOTE: The dictionary must not change until iterating is finished! | 476 * NOTE: The dictionary must not change until iterating is finished! |