📄 wxgpsevent.h
字号:
/* * Roadnav * wxGPSEvent.h * * Copyright (c) 2004 - 2007 Richard L. Lynch <rllynch@users.sourceforge.net> * * This program is free software; you can redistribute it and/or * modify it under the terms of version 2 of the GNU General Public License * as published by the Free Software Foundation. * * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA *////////////////////////////////////////////////////////////////////////////////// \file////// GPS event class./////////////////////////////////////////////////////////////////////////////////#ifndef WXGPSEVENT_H#define WXGPSEVENT_H#include <wx/wx.h>#include "libroadnav/Point.h"#define MAX_GPS_SATELLITES 32//////////////////////////////////////////////////////////////////////////////////// \brief Information about a particular GPS satellites that's in view./////////////////////////////////////////////////////////////////////////////////struct SSatelliteInfo{ int m_iID; double m_fElevation; double m_fAzimuth; double m_fSNR;};//////////////////////////////////////////////////////////////////////////////////// \brief This is a wxEvent used to pass GPS data to the MapFrame class./////////////////////////////////////////////////////////////////////////////////class wxGPSEvent : public wxEvent{ public: wxGPSEvent(); wxGPSEvent(bool bEnabled, bool bActive, bool bLocked, const Point & pt, double fSpeed, double fHeading, const wxString & strLockType, int nSatUsedForLock, const SSatelliteInfo * parSatellitesVisible, int nSatellitesVisible, const wxString & strErrorMessage); virtual wxEvent * Clone() const; wxGPSEvent & operator =(const wxGPSEvent & p); bool m_bEnabled; bool m_bActive; bool m_bLocked; Point m_pt; double m_fSpeed; double m_fHeading; wxString m_strLockType; int m_nSatUsedForLock; SSatelliteInfo m_arSatellitesVisible[MAX_GPS_SATELLITES]; int m_nSatellitesVisible; wxString m_strErrorMessage;};DECLARE_EVENT_TYPE(wxEVT_GPS_ACTION, -1)typedef void (wxEvtHandler::*wxGPSEventFunction)(wxGPSEvent&);#define EVT_GPS(fn) \ DECLARE_EVENT_TABLE_ENTRY( wxEVT_GPS_ACTION, wxID_ANY, wxID_ANY, \ (wxObjectEventFunction) (wxEventFunction) \ wxStaticCastEvent( wxGPSEventFunction, & fn ), (wxObject *) NULL ),#endif // #ifndef WXGPSEVENT_H
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -