From a221a6e9f5ff7a9460beaa0fbb4da53e5616eca1 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Wed, 2 Jul 2014 11:50:28 -0700 Subject: UI restructure: use a global variable to hold the dive we show / edit There is massive confusion about what we display when and where and which dive structure (or pointer to a dive structure) contains which information at which stage. This is the first step towards restructuring all of this. This creates a global variable displayed_dive which at any point in time should be what is displayed on screen (both in the profile and in the maintab). It removes the editedDive concept from MainTab. Signed-off-by: Dirk Hohndel --- dive.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'dive.h') diff --git a/dive.h b/dive.h index de0d826e3..b325f11fa 100644 --- a/dive.h +++ b/dive.h @@ -414,7 +414,7 @@ struct dive_table { }; extern struct dive_table dive_table; - +extern struct dive displayed_dive; extern int selected_dive; extern unsigned int dc_number; #define current_dive (get_dive(selected_dive)) -- cgit v1.2.3-70-g09d2