1 // ATCdisplay.hxx - class to manage the graphical display of ATC messages.
2 // - The idea is to separate the display of ATC messages from their
3 // - generation so that the generation may come from any source.
5 // Written by David Luff, started October 2001.
7 // Copyright (C) 2001 David C Luff - david.luff@nottingham.ac.uk
9 // This program is free software; you can redistribute it and/or
10 // modify it under the terms of the GNU General Public License as
11 // published by the Free Software Foundation; either version 2 of the
12 // License, or (at your option) any later version.
14 // This program is distributed in the hope that it will be useful, but
15 // WITHOUT ANY WARRANTY; without even the implied warranty of
16 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 // General Public License for more details.
19 // You should have received a copy of the GNU General Public License
20 // along with this program; if not, write to the Free Software
21 // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23 #ifndef _FG_ATC_DISPLAY_HXX
24 #define _FG_ATC_DISPLAY_HXX
42 // ASSUMPTION - with two radios the list won't be long so we don't need to map the id's
43 typedef vector<atcMessage> atcMessageList;
44 typedef atcMessageList::iterator atcMessageListIterator;
49 bool rep_msg; // Flag to indicate there is a repeating transmission to display
50 bool change_msg_flag; // Flag to indicate that the repeating message has changed
51 float dsp_offset1; // Used to set the correct position of scrolling display
53 string rep_msg_str; // The repeating transmission to play
54 atcMessageList msgList;
55 atcMessageListIterator msgList_itr;
63 // Display any registered messages
66 // Register a single message for display when possible
67 void RegisterSingleMessage(string msg); // OK - I know passing a string in and out is probably not good but it will have to do for now.
69 /* For now we will assume only one repeating message at once */
70 // This is not really robust
72 // Register a continuously repeating message
73 void RegisterRepeatingMessage(string msg);
75 // Change a repeating message - assume that the message changes after the string has finished for now
76 void ChangeRepeatingMessage(string newmsg);
78 // Cancel the current repeating message
79 void CancelRepeatingMessage();
82 extern FGATCDisplay *current_atcdisplay;
84 #endif // _FG_ATC_DISPLAY_HXX