MOOS 0.2375
|
00001 00002 // 00003 // MOOS - Mission Oriented Operating Suite 00004 // 00005 // A suit of Applications and Libraries for Mobile Robotics Research 00006 // Copyright (C) 2001-2005 Massachusetts Institute of Technology and 00007 // Oxford University. 00008 // 00009 // This software was written by Paul Newman at MIT 2001-2002 and Oxford 00010 // University 2003-2005. email: pnewman@robots.ox.ac.uk. 00011 // 00012 // This file is part of a MOOS Utility Component. 00013 // 00014 // This program is free software; you can redistribute it and/or 00015 // modify it under the terms of the GNU General Public License as 00016 // published by the Free Software Foundation; either version 2 of the 00017 // License, or (at your option) any later version. 00018 // 00019 // This program is distributed in the hope that it will be useful, 00020 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00021 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00022 // General Public License for more details. 00023 // 00024 // You should have received a copy of the GNU General Public License 00025 // along with this program; if not, write to the Free Software 00026 // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 00027 // 02111-1307, USA. 00028 // 00030 #ifdef _WIN32 00031 #pragma warning(disable : 4786) 00032 #endif 00033 00034 #ifndef PlayBackWindowh 00035 #define PlayBackWindowh 00036 #include "MOOSPlayBackIndex.h" 00037 00038 00039 #include <FL/Fl.H> 00040 #include <FL/Fl_Group.H> 00041 #include <FLTKVW/MOOSFLTKUI.h> 00042 #include <FL/Fl_Check_Browser.H> 00043 00044 class CPlaybackWindow : public CMOOSFLTKUI 00045 { 00046 private : 00047 typedef CMOOSFLTKUI BASE; 00048 enum ID 00049 { 00050 ID_MOOS, 00051 ID_PLAY, 00052 ID_STOP, 00053 ID_REWIND, 00054 ID_WARP, 00055 ID_PROGRESS, 00056 ID_FILE, 00057 ID_SOURCE, 00058 ID_CLOCK, 00059 ID_MOOS_CONFIGURE, 00060 00061 ID_SEEK, 00062 }; 00063 enum Mode{PLAYING,STOPPED} m_eMode; 00064 00065 public: 00066 00067 CPlaybackWindow( int X, int Y, int W, int H, const char *l ); 00068 void OnControlWidget(Fl_Widget* pWidget,int ID); 00069 bool OnPlayButton(); 00070 bool OnStopButton(); 00071 bool MakeMessageFilter(); 00072 virtual void OnTimer(); 00073 bool OnNewMail(MOOSMSG_LIST &NewMail); 00074 bool OnMOOS(); 00075 bool OnFile(); 00076 bool OnWarp(); 00077 bool ShowProgress(); 00078 bool OnMOOSConnect(); 00079 bool OnMOOSDisconnect(); 00080 bool OnProgress(); 00081 bool OnMOOSConfigure(); 00082 void OnGUIRefresh(); 00083 bool SetTitle(bool bOnline = false); 00084 bool ManageWidgetStates(); 00085 00086 Fl_Window * GetRootWindow(); 00087 CMOOSPlayBackIndex m_PlayBack; 00088 std::string m_sFileName; 00089 Fl_Check_Browser * pSourceCheck; 00090 CMOOSCommClient m_Comms; 00091 std::string m_sServerHost; 00092 long m_lServerPort; 00093 int m_nTimerHits; 00094 double m_dfTimerInterval; 00095 00096 double m_dfSeekTime; 00097 00098 }; 00099 00100 #endif