// aptinput.cpp -- input widget for airports // // Written by Frederic Bouvier, started August 2003. // // Copyright (C) 2003 Frederic Bouvier - fredb@users.sourceforge.net // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License as // published by the Free Software Foundation; either version 2 of the // License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, but // WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU // General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. // // $Id: aptinput.hpp,v 1.4 2005/05/09 07:01:49 fredb Exp $ #ifndef _aptinput_hpp_ #define _aptinput_hpp_ #include class FGSD_AirportWindow { public: virtual void handle_key( int dir, int pos ) = 0; }; class FGSD_AirportInput : public Fl_Input { public: FGSD_AirportInput(FGSD_AirportWindow *win, int x,int y,int w,int h,const char *l = 0) : Fl_Input(x,y,w,h,l), _w( win ) {} int handle(int e); private: int handle_arrow(int dir); FGSD_AirportWindow *_w; }; #endif