Ticket #3763 (accepted task) — at Version 2
Introduce run_listbox_with_data()
Reported by: | mooffie | Owned by: | mooffie |
---|---|---|---|
Priority: | major | Milestone: | 4.8.19 |
Component: | mc-core | Version: | master |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Branch state: | merged | Votes for changeset: |
Description (last modified by mooffie) (diff)
The problem:
Functions that use run_listbox() can be complicated and breakable, if they need to figure out some pointer given the number of the item selected.
(For example, in the case of edit_window_list() this will make its code break if we change how widgets are Z-ordered --which was the 1st solution I tried for #3760.)
The solution:
A listbox can already store pointers. So we introduce a variant of run_listbox() which returns pointers. We then use it to simplify a couple of functions.
Change History
Note: See
TracTickets for help on using
tickets.
branch: 3763_run_listbox_with_data
Initial changeset:11c1aff4d343096ef555b7fcec05a625f2e020c2
(There are 3 commits here.)