26#ifndef _N0183_DLG_CTX_FACTORY_H__
27#define _N0183_DLG_CTX_FACTORY_H__
37static bool ConfirmOverwrite() {
39 OCPNMessageBox(NULL, _(
"Overwrite Garmin device route number 1?"),
40 _(
"OpenCPN Message"), wxOK | wxCANCEL | wxICON_QUESTION);
46 dlg_ctx.set_value = [dialog](
int v) {
47 if (!dialog || !dialog->GetProgressGauge())
return;
48 dialog->GetProgressGauge()->SetValue(v);
49 dialog->GetProgressGauge()->Refresh();
50 dialog->GetProgressGauge()->Update();
52 dlg_ctx.set_range = [dialog](
int r) {
53 if (!dialog || !dialog->GetProgressGauge())
return;
54 dialog->GetProgressGauge()->SetRange(r);
56 dlg_ctx.pulse = [dialog](void) {
57 if (!dialog || !dialog->GetProgressGauge())
return;
58 dialog->GetProgressGauge()->Pulse();
60 dlg_ctx.set_message = [dialog](
const std::string& s) {
61 dialog->SetMessage(wxString(s));
63 dlg_ctx.confirm_overwrite = []() {
return ConfirmOverwrite(); };
Dialog for sending routes/waypoints to a GPS device.
NMEA Data Multiplexer Object.
General purpose GUI support.
Send route/waypoint to GPS dialog.