Update the dive units without destroyng and rebuilding the dive list

Just iterate over the dive list entries, updating them one by one.

This avoids the "selection destroyed" when the dive units are changed.
And it's cleaner anyway.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Linus Torvalds 2011-09-07 12:01:37 -07:00
parent 19dd61b126
commit 7bbcf2fabd
3 changed files with 86 additions and 53 deletions

View file

@ -15,5 +15,6 @@ extern int selected_dive;
extern struct DiveList dive_list_create(void);
extern void dive_list_update_dives(struct DiveList);
extern void update_dive_list_units(struct DiveList *);
#endif