OpenCPN Partial API docs
Loading...
Searching...
No Matches
plugin_comm.h
Go to the documentation of this file.
1/***************************************************************************
2 * Copyright (C) 2024 Alec Leamas *
3 * *
4 * This program is free software; you can redistribute it and/or modify *
5 * it under the terms of the GNU General Public License as published by *
6 * the Free Software Foundation; either version 2 of the License, or *
7 * (at your option) any later version. *
8 * *
9 * This program is distributed in the hope that it will be useful, *
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
12 * GNU General Public License for more details. *
13 * *
14 * You should have received a copy of the GNU General Public License *
15 * along with this program; if not, see <https://www.gnu.org/licenses/>. *
16 **************************************************************************/
17
24#ifndef PLUGIN_COMM_H
25#define PLUGIN_COMM_H
26
27#include <wx/event.h>
28#include <wx/jsonval.h>
29#include <wx/string.h>
30
31#include "model/ocpn_types.h"
32
33void SendMessageToAllPlugins(const wxString& message_id,
34 const wxString& message_body);
35
36void SendJSONMessageToAllPlugins(const wxString& message_id, wxJSONValue v);
37
38void SendAISSentenceToAllPlugIns(const wxString& sentence);
39
40void SendPositionFixToAllPlugIns(GenericPosDatEx* ppos);
41
42void SendActiveLegInfoToAllPlugIns(const ActiveLegDat* leg_info);
43
44bool SendMouseEventToPlugins(wxMouseEvent& event);
45
46bool SendKeyEventToPlugins(wxKeyEvent& event);
47
48void SendPreShutdownHookToPlugins();
49
50void SendCursorLatLonToAllPlugIns(double lat, double lon);
51
69void SendNMEASentenceToAllPlugIns(const wxString& sentence);
70
71int GetJSONMessageTargetCount();
72
73void SendVectorChartObjectInfo(const wxString& chart, const wxString& feature,
74 const wxString& objname, double& lat,
75 double& lon, double& scale, int& nativescale);
76
77#endif // PLUGIN_COMM_H
The JSON value class implementation.
Definition jsonval.h:84
Navigation data types.
void SendNMEASentenceToAllPlugIns(const wxString &sentence)
Distribute a NMEA 0183 sentence to all plugins that have registered interest by setting the WANTS_NME...
A generic position and navigation data structure.
Definition ocpn_types.h:68