OpenCPN Partial API docs
Loading...
Searching...
No Matches
SendToGpsDlg.h
1/***************************************************************************
2 *
3 * Project: OpenCPN
4 *
5 ***************************************************************************
6 * Copyright (C) 2010 by David S. Register *
7 * *
8 * This program is free software; you can redistribute it and/or modify *
9 * it under the terms of the GNU General Public License as published by *
10 * the Free Software Foundation; either version 2 of the License, or *
11 * (at your option) any later version. *
12 * *
13 * This program is distributed in the hope that it will be useful, *
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16 * GNU General Public License for more details. *
17 * *
18 * You should have received a copy of the GNU General Public License *
19 * along with this program; if not, write to the *
20 * Free Software Foundation, Inc., *
21 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
22 ***************************************************************************
23 */
24
25#ifndef __SENDTOGPSDLG_H__
26#define __SENDTOGPSDLG_H__
27
28#include <wx/wxprec.h>
29#ifndef WX_PRECOMP
30#include <wx/wx.h>
31#endif // precompiled headers
32
33#include <wx/dialog.h>
34
35// Constants for SendToGps... Dialog
36#define ID_STGDIALOG 10005
37#define SYMBOL_STG_STYLE \
38 wxCAPTION | wxRESIZE_BORDER | wxSYSTEM_MENU | wxCLOSE_BOX | \
39 wxFRAME_FLOAT_ON_PARENT
40#define SYMBOL_STG_TITLE _("Send to GPS")
41#define SYMBOL_STG_IDNAME ID_STGDIALOG
42#define SYMBOL_STG_SIZE wxSize(500, 500)
43#define SYMBOL_STG_POSITION wxDefaultPosition
44
45enum { ID_STG_CANCEL = 10000, ID_STG_OK, ID_STG_CHOICE_COMM };
46
47class Route;
48class RoutePoint;
49// class wxButton;
50// class wxGauge;
51// class wxComboBox;
52
56class SendToGpsDlg : public wxDialog {
57 DECLARE_DYNAMIC_CLASS(SendToGpsDlg)
58 DECLARE_EVENT_TABLE()
59
60public:
62 SendToGpsDlg(wxWindow* parent, wxWindowID id, const wxString& caption,
63 const wxString& hint, const wxPoint& pos, const wxSize& size,
64 long style);
66
67 bool Create(wxWindow* parent, wxWindowID id = SYMBOL_STG_IDNAME,
68 const wxString& caption = SYMBOL_STG_TITLE,
69 const wxString& hint = SYMBOL_STG_TITLE,
70 const wxPoint& pos = SYMBOL_STG_POSITION,
71 const wxSize& size = SYMBOL_STG_SIZE,
72 long style = SYMBOL_STG_STYLE);
73 void SetRoute(Route* pRoute) { m_pRoute = pRoute; }
74 void SetWaypoint(RoutePoint* pRoutePoint) { m_pRoutePoint = pRoutePoint; }
75 wxGauge* GetProgressGauge() { return m_pgauge; }
76 void SetMessage(wxString message);
77
78private:
79 void CreateControls(const wxString& hint);
80
81 void OnCancelClick(wxCommandEvent& event);
82 void OnSendClick(wxCommandEvent& event);
83
84 Route* m_pRoute;
85 RoutePoint* m_pRoutePoint;
86 wxComboBox* m_itemCommListBox;
87 wxGauge* m_pgauge;
88 wxButton* m_CancelButton;
89 wxButton* m_SendButton;
90 wxStaticText* premtext;
91};
92
93#endif
Definition: route.h:70
Route "Send to GPS..." Dialog Definition.
Definition: SendToGpsDlg.h:56