36#include <wx/listbook.h>
37#include <wx/dirctrl.h>
38#include <wx/spinctrl.h>
39#include <wx/listctrl.h>
41#include <wx/collpane.h>
42#include <wx/clrpicker.h>
43#include <wx/colourdata.h>
44#include "connections_dialog.h"
47#include <wx/timectrl.h>
53#include "time_textbox.h"
58#if wxCHECK_VERSION(2, 9, 0)
61#include "scrollingdialog.h"
65#include "pluginmanager.h"
67#ifndef __OCPN__ANDROID__
68#define __OCPN__OPTIONS_USE_LISTBOOK__
72class wxGenericDirCtrl;
88#define ID_DIALOG 10001
89#define SYMBOL_OPTIONS_STYLE \
90 wxCAPTION | wxRESIZE_BORDER | wxSYSTEM_MENU | wxCLOSE_BOX
91#define SYMBOL_OPTIONS_TITLE _("Options")
92#define SYMBOL_OPTIONS_IDNAME ID_DIALOG
93#define SYMBOL_OPTIONS_SIZE wxSize(500, 500)
94#define SYMBOL_OPTIONS_POSITION wxDefaultPosition
99 ID_AUTOANCHORMARKBOX1,
111 ID_CHECK_DISPLAYGRID,
115 ID_CHOICE_FONTELEMENT,
128 ID_FSTOOLBARCHECKBOX,
162 ID_SUPERSCAMINCHECKBOX,
165 ID_DISTANCEUNITSCHOICE,
169 ID_SHOWDEPTHUNITSBOX1,
182 ID_TRANSTOOLBARCHECKBOX,
188 ID_NATIONALTEXTCHECKBOX,
194 ID_SIZEMANUALRADIOBUTTON,
195 ID_OPWAYPOINTRANGERINGS,
201 ID_TRACKROTATECOMPUTER,
206 ID_SOGCOGFROMLLCHECKBOX,
207 ID_SOGCOGDAMPINTTEXTCTRL,
210 ID_DEFAULT_BOAT_SPEED,
214 ID_CONFIGEDIT_CANCEL,
226#define GENERIC_CHANGED 1
227#define S52_CHANGED 1 << 1
228#define FONT_CHANGED 1 << 2
229#define FORCE_UPDATE 1 << 3
230#define VISIT_CHARTS 1 << 4
231#define LOCALE_CHANGED 1 << 5
232#define TOOLBAR_CHANGED 1 << 6
233#define CHANGE_CHARTS 1 << 7
234#define SCAN_UPDATE 1 << 8
235#define GROUPS_CHANGED 1 << 9
236#define STYLE_CHANGED 1 << 10
237#define TIDES_CHANGED 1 << 11
238#define GL_CHANGED 1 << 12
239#define REBUILD_RASTER_CACHE 1 << 13
240#define NEED_NEW_OPTIONS 1 << 14
241#define PARSE_ENC 1 << 15
242#define CONFIG_CHANGED 1 << 16
245#define wxCLOSE_BOX 0x1000
247#ifndef wxFIXED_MINSIZE
248#define wxFIXED_MINSIZE 0
251#include <wx/arrimpl.cpp>
252WX_DEFINE_ARRAY_PTR(wxGenericDirCtrl *, ArrayOfDirCtrls);
273 explicit options(
MyFrame *parent, wxWindowID
id = SYMBOL_OPTIONS_IDNAME,
274 const wxString &caption = SYMBOL_OPTIONS_TITLE,
275 const wxPoint &pos = SYMBOL_OPTIONS_POSITION,
276 const wxSize &size = SYMBOL_OPTIONS_SIZE,
277 long style = SYMBOL_OPTIONS_STYLE);
280#if wxCHECK_VERSION(3, 0, 0)
281 bool SendIdleEvents(wxIdleEvent &event);
283 void SetInitialPage(
int page_sel,
int sub_page = -1);
286 void OnClose(wxCloseEvent &event);
288 void CreateListbookIcons();
289 void CreateControls(
void);
290 size_t CreatePanel(
const wxString &title);
291 wxScrolledWindow *AddPage(
size_t parent,
const wxString &title);
292 bool DeletePluginPage(wxScrolledWindow *page);
293 void SetColorScheme(ColorScheme cs);
294 void RecalculateSize(
void);
296 void SetInitChartDir(
const wxString &dir) { m_init_chart_dir = dir; }
297 void SetInitialSettings(
void);
298 void SetInitialVectorSettings(
void);
300 void SetCurrentDirList(ArrayOfCDI p) { m_CurrentDirList = p; }
301 void SetWorkDirListPtr(ArrayOfCDI *p) { m_pWorkDirList = p; }
302 ArrayOfCDI *GetWorkDirListPtr(
void) {
return m_pWorkDirList; }
304 void AddChartDir(
const wxString &dir);
306 void UpdateDisplayedChartDirList(ArrayOfCDI p);
307 void UpdateOptionsUnits(
void);
309 void SetConfigPtr(
MyConfig *p) { m_pConfig = p; }
310 void OnDebugcheckbox1Click(wxCommandEvent &event);
311 void OnDirctrlSelChanged(wxTreeEvent &event);
312 void OnButtonaddClick(wxCommandEvent &event);
313 void OnButtondeleteClick(wxCommandEvent &event);
314 void OnButtonParseENC(wxCommandEvent &event);
315 void OnButtoncompressClick(wxCommandEvent &event);
316 void OnButtonmigrateClick(wxCommandEvent &event);
317 void OnButtonEcdisHelp(wxCommandEvent &event);
318 void OnRadioboxSelected(wxCommandEvent &event);
319 void OnApplyClick(wxCommandEvent &event);
320 void OnXidOkClick(wxCommandEvent &event);
321 void OnCancelClick(wxCommandEvent &event);
322 void OnChooseFont(wxCommandEvent &event);
323 void OnFontChoice(wxCommandEvent &event);
324 void OnCPAWarnClick(wxCommandEvent &event);
325 void OnSyncCogPredClick(wxCommandEvent &event);
326 void OnSizeAutoButton(wxCommandEvent &event);
327 void OnSizeManualButton(wxCommandEvent &event);
329#if defined(__WXGTK__) || defined(__WXQT__)
330 void OnChooseFontColor(wxCommandEvent &event);
332 void OnGLClicked(wxCommandEvent &event);
333 void OnOpenGLOptions(wxCommandEvent &event);
334 void OnDisplayCategoryRadioButton(wxCommandEvent &event);
335 void OnButtonClearClick(wxCommandEvent &event);
336 void OnButtonSelectClick(wxCommandEvent &event);
337 void OnButtonSetStd(wxCommandEvent &event);
339 void OnPageChange(wxListbookEvent &event);
340 void OnTopNBPageChange(wxNotebookEvent &event);
341 void OnSubNBPageChange(wxNotebookEvent &event);
342 void DoOnPageChange(
size_t page);
344 wxString SelectSoundFile();
345 void OnButtonSelectSound(wxCommandEvent &event);
346 void OnButtonTestSound(wxCommandEvent &event);
348 void OnShowGpsWindowCheckboxClick(wxCommandEvent &event);
349 void OnZTCCheckboxClick(wxCommandEvent &event);
350 void OnRadarringSelect(wxCommandEvent &event);
351 void OnWaypointRangeRingSelect(wxCommandEvent &event);
352 void OnShipTypeSelect(wxCommandEvent &event);
353 void OnButtonGroups(wxCommandEvent &event);
354 void OnInsertTideDataLocation(wxCommandEvent &event);
355 void OnRemoveTideDataLocation(wxCommandEvent &event);
356 void OnCharHook(wxKeyEvent &event);
357 void OnChartsPageChange(wxListbookEvent &event);
358 void OnChartDirListSelect(wxCommandEvent &event);
359 void OnUnitsChoice(wxCommandEvent &event);
361 void UpdateWorkArrayFromDisplayPanel(
void);
362 ArrayOfCDI GetSelectedChartDirs();
363 ArrayOfCDI GetUnSelectedChartDirs();
364 void SetDirActionButtons();
366 void OnCreateConfig(wxCommandEvent &event);
367 void OnEditConfig(wxCommandEvent &event);
368 void OnDeleteConfig(wxCommandEvent &event);
369 void OnApplyConfig(wxCommandEvent &event);
370 void SetConfigButtonState();
371 void ClearConfigList();
372 void BuildConfigList();
373 void OnConfigMouseSelected(wxMouseEvent &event);
374 void OnDialogInit(wxInitDialogEvent& event);
377 bool GetNeedNew() {
return m_bneedNew; }
378 void SetNeedNew(
bool bnew) { m_bneedNew = bnew; }
379 int GetScrollRate() {
return m_scrollRate; }
380 void SetForceNewToolbarOnCancel(
bool val) { m_bForceNewToolbaronCancel = val; }
382 wxArrayString *GetSerialArray(){
return m_pSerialArray; }
385 static bool ShowToolTips(
void);
387#ifdef __OCPN__OPTIONS_USE_LISTBOOK__
388 wxListbook *m_pListbook;
390 wxNotebook *m_pListbook;
393 size_t m_pageDisplay, m_pageConnections, m_pageCharts, m_pageShips;
394 size_t m_pageUI, m_pagePlugins;
395 int lastPage, lastSubPage;
396 wxPoint lastWindowPos;
397 wxSize lastWindowSize;
398 wxButton *m_ApplyButton, *m_OKButton, *m_CancelButton;
400 ChartGroupArray *m_pGroupArray;
401 int m_groups_changed;
404 wxSizerFlags inputFlags, verticleInputFlags, labelFlags, groupInputFlags;
405 wxSizerFlags groupLabelFlags, groupLabelFlagsHoriz;
408 wxScrolledWindow *pDisplayPanel;
409 wxCheckBox *pShowStatusBar, *pShowMenuBar, *pShowChartBar, *pShowCompassWin;
410 wxCheckBox *pPrintShowIcon, *pCDOOutlines, *pSDepthUnits, *pSDisplayGrid;
411 wxCheckBox *pAutoAnchorMark, *pCDOQuilting, *pCBRaster, *pCBVector;
412 wxCheckBox *pCBCM93, *pCBLookAhead, *pSkewComp, *pOpenGL, *pSmoothPanZoom;
413 wxCheckBox *pFullScreenQuilt, *pMobile, *pResponsive, *pOverzoomEmphasis;
414 wxCheckBox *pOZScaleVector, *pToolbarAutoHideCB, *pInlandEcdis, *pRollover;
415 wxCheckBox *pZoomButtons;
416 wxTextCtrl *pCOGUPUpdateSecs, *m_pText_OSCOG_Predictor, *pScreenMM;
417 wxTextCtrl *pToolbarHideSecs, *m_pText_OSHDT_Predictor;
419 wxTextCtrl *pCmdSoundString;
421 wxChoice *m_pShipIconType, *m_pcTCDatasets;
422 wxSlider *m_pSlider_Zoom_Raster, *m_pSlider_GUI_Factor, *m_pSlider_Chart_Factor,
423 *m_pSlider_Ship_Factor, *m_pSlider_Text_Factor, *m_pSlider_ENCText_Factor;
424 wxSlider *m_pMouse_Zoom_Slider;
425 wxSlider *m_pSlider_Zoom_Vector;
426 wxSlider *m_pSlider_CM93_Zoom;
428 wxCheckBox *pSLiveETA;
429 wxTextCtrl *pSDefaultBoatSpeed;
431 wxRadioButton *pCBCourseUp, *pCBNorthUp, *pRBSizeAuto, *pRBSizeManual;
435 wxStaticText *itemStaticTextUserVar;
436 wxStaticText *itemStaticTextUserVar2;
437 wxButton *m_configDeleteButton, *m_configApplyButton;
439 void OnAISRolloverClick(wxCommandEvent &event);
440 void UpdateChartDirList();
442 void OnCanvasConfigSelectClick(
int ID,
bool selected);
450 wxBoxSizer *vectorPanel;
451 wxScrolledWindow *ps57Ctl;
455 wxChoice *pDispCat, *pPointStyle, *pBoundStyle, *p24Color;
456 wxButton *itemButtonClearList, *itemButtonSelectList, *itemButtonSetStd;
457 wxCheckBox *pCheck_SOUNDG, *pCheck_META, *pCheck_SHOWIMPTEXT;
458 wxCheckBox *pCheck_SCAMIN, *pCheck_SuperSCAMIN;
459 wxCheckBox *pCheck_ATONTEXT, *pCheck_LDISTEXT;
460 wxCheckBox *pCheck_XLSECTTEXT, *pCheck_DECLTEXT, *pCheck_NATIONALTEXT;
461 wxCheckBox *pSEnableCM93Offset;
462 wxTextCtrl *m_ShallowCtl, *m_SafetyCtl, *m_DeepCtl;
463 wxStaticText *m_depthUnitsShal, *m_depthUnitsSafe, *m_depthUnitsDeep;
467 wxChoice *pSDMMFormat, *pDistanceFormat, *pSpeedFormat, *pDepthUnitSelect,
469 wxCheckBox *pCBTrueShow, *pCBMagShow;
473 wxStaticBoxSizer *activeSizer;
474 wxBoxSizer *chartPanel;
477 ArrayOfCDI ActiveChartArray;
479 wxStaticBox *itemActiveChartStaticBox;
480 wxCheckBox *pUpdateCheckBox, *pScanCheckBox;
481 wxButton *pParseENCButton;
482 wxButton *m_removeBtn, *m_compressBtn;
483 wxButton *m_migrateBtn;
486 wxBoxSizer *boxSizerCharts;
487 wxScrolledWindow *m_scrollWinChartList;
488 wxScrolledWindow* chartPanelWin;
489 wxBoxSizer* cmdButtonSizer;
490 wxStaticBox* loadedBox;
491 std::vector<OCPNChartDirPanel *> panelVector;
492 wxArrayString activeChartList;
495 wxScrolledWindow *m_ChartDisplayPage;
498 wxCheckBox *m_pCheck_CPA_Max, *m_pCheck_CPA_Warn, *m_pCheck_CPA_WarnT;
499 wxCheckBox *m_pCheck_Mark_Lost, *m_pCheck_Remove_Lost;
500 wxCheckBox *m_pCheck_Show_COG, *m_pCheck_Sync_OCOG_ACOG;
501 wxCheckBox *m_pCheck_Show_Tracks, *m_pCheck_Hide_Moored,
502 *m_pCheck_Scale_Priority;
503 wxCheckBox *m_pCheck_AlertDialog, *m_pCheck_AlertAudio;
504 wxCheckBox *m_pCheck_Alert_Moored, *m_pCheck_Rollover_Class;
505 wxCheckBox *m_pCheck_Rollover_COG, *m_pCheck_Rollover_CPA;
506 wxCheckBox *m_pCheck_Ack_Timout, *m_pCheck_Show_Area_Notices;
507 wxCheckBox *m_pCheck_Draw_Target_Size, *m_pCheck_Draw_Realtime_Prediction;
508 wxCheckBox *m_pCheck_Show_Target_Name;
509 wxChoice *m_pWplAction;
510 wxCheckBox *m_pCheck_use_Wpl, *m_pCheck_ShowAllCPA;
511 wxTextCtrl *m_pText_CPA_Max, *m_pText_CPA_Warn, *m_pText_CPA_WarnT;
512 wxTextCtrl *m_pText_Mark_Lost, *m_pText_Remove_Lost, *m_pText_COG_Predictor;
513 wxTextCtrl *m_pText_Track_Length, *m_pText_Moored_Speed,
514 *m_pText_Scale_Priority;
515 wxTextCtrl *m_pText_ACK_Timeout, *m_pText_Show_Target_Name_Scale;
516 wxTextCtrl *m_pText_RealtPred_Speed;
519 wxScrolledWindow *m_DisplayConfigsPage;
525 wxScrolledWindow *m_scrollWinConfigList;
526 wxStaticText *m_templateTitleText;
527 wxStaticText *m_staticTextLastAppled;
528 wxStaticBoxSizer *m_templateStatusBoxSizer;
531 wxFlexGridSizer *realSizes;
532 wxTextCtrl *m_pOSLength, *m_pOSWidth, *m_pOSGPSOffsetX, *m_pOSGPSOffsetY;
533 wxTextCtrl *m_pOSMinSize, *m_pText_ACRadius;
534 wxStaticBoxSizer *dispOptions, *dispWaypointOptions;
535 wxScrolledWindow *itemPanelShip, *itemPanelRoutes;
536 wxBoxSizer *ownShip, *Routes;
537 wxCheckBox *pShowshipToActive;
538 wxChoice *m_shipToActiveStyle, *m_shipToActiveColor;
542 wxCheckBox *pScaMinChckB, *pScaMinOverruleChckB;
543 wxTextCtrl *m_pText_ScaMin;
546 wxBoxSizer *m_itemBoxSizerFontPanel;
547 wxChoice *m_itemFontElementListBox, *m_itemStyleListBox, *m_itemLangListBox;
548 wxStaticText *m_textSample;
552 wxComboBox *m_itemAISListBox;
558 wxScrolledWindow *itemPanelPlugins;
559 wxBoxSizer *itemBoxSizerPanelPlugins;
560 wxFlexGridSizer *radarGrid, *waypointradarGrid;
561 wxChoice *pNavAidRadarRingsNumberVisible, *pWaypointRangeRingsNumber;
563 wxChoice *m_itemRadarRingsUnits, *m_itemWaypointRangeRingsUnits;
566 wxChoice *pTrackPrecision;
567 wxTextCtrl *pNavAidRadarRingsStep, *pWaypointRangeRingsStep;
568 wxCheckBox *pSogCogFromLLCheckBox;
569 wxSpinCtrl *pSogCogFromLLDampInterval;
570 wxTextCtrl *m_pText_TP_Secs, *m_pText_TP_Dist;
571 wxCheckBox *pWayPointPreventDragging, *pConfirmObjectDeletion;
572 wxCheckBox *pEnableZoomToCursor, *pPreserveScale, *pPlayShipsBells;
573 wxCheckBox *pTransparentToolbar;
574 wxCheckBox *pAdvanceRouteWaypointOnArrivalOnly, *pTrackShowIcon;
575 wxCheckBox *pTrackDaily, *pTrackHighlite;
576 wxStaticText *pStatic_CallSign;
578#if wxCHECK_VERSION(2, 9, 0)
579#if wxUSE_TIMEPICKCTRL
583 wxTimePickerCtrl *pTrackRotateTime;
587 wxRadioButton *pTrackRotateComputerTime, *pTrackRotateUTC, *pTrackRotateLMT;
589 wxChoice *pSoundDeviceIndex;
590 wxStaticText *stSoundDeviceIndex;
592 wxArrayPtrVoid OBJLBoxArray;
593 wxString m_init_chart_dir;
594 wxArrayString *m_pSerialArray;
596 ArrayOfCDI m_CurrentDirList, *m_pWorkDirList;
601 bool m_bForceNewToolbaronCancel;
612 void CreatePanel_MMSI(
size_t parent,
int border_size,
int group_item_spacing);
613 void CreatePanel_AIS(
size_t parent,
int border_size,
int group_item_spacing);
614 void CreatePanel_Ownship(
size_t parent,
int border_size,
615 int group_item_spacing);
616 void CreatePanel_NMEA(
size_t parent,
int border_size,
int group_item_spacing);
617 void CreatePanel_ChartsLoad(
size_t parent,
int border_size,
618 int group_item_spacing);
619 void CreatePanel_VectorCharts(
size_t parent,
int border_size,
620 int group_item_spacing);
621 void CreatePanel_TidesCurrents(
size_t parent,
int border_size,
622 int group_item_spacing);
623 void CreatePanel_ChartGroups(
size_t parent,
int border_size,
624 int group_item_spacing);
625 void CreatePanel_Display(
size_t parent,
int border_size,
626 int group_item_spacing);
627 void CreatePanel_UI(
size_t parent,
int border_size,
int group_item_spacing);
628 void CreatePanel_Units(
size_t parent,
int border_size,
629 int group_item_spacing);
630 void CreatePanel_Sounds(
size_t parent,
int border_size,
631 int group_item_spacing);
632 void CreatePanel_Advanced(
size_t parent,
int border_size,
633 int group_item_spacing);
634 void CreatePanel_Configs(
size_t parent,
int border_size,
635 int group_item_spacing);
636 void CreatePanel_Routes(
size_t parent,
int border_size,
637 int group_item_spacing);
639 void OnAlertEnableButtonClick(wxCommandEvent &event);
640 void OnAlertAudioEnableButtonClick(wxCommandEvent &event);
642 void UpdateTemplateTitleText();
643 void CheckDeviceAccess(wxString &path);
645 wxListCtrl *tcDataSelected;
646 std::vector<int> marinersStdXref;
648 wxImageList *m_topImgList;
650 wxScrolledWindow *m_pNMEAForm;
651 void resetMarStdList(
bool bsetConfig,
bool bsetStd);
657 wxNotebookPage *m_groupsPage;
658 wxFont *dialogFont, *dialogFontPlus;
661 wxSize m_small_button_size;
664 int m_fontHeight, m_scrollRate;
668 wxBoxSizer *m_boxSizerConfigs;
669 wxColour m_panelBackgroundUnselected;
670 wxString m_selectedConfigPanelGUID;
671 wxSize m_colourPickerDefaultSize;
676 std::shared_ptr<ConnectionsDialog>comm_dialog;
678 DECLARE_EVENT_TABLE()
684 wxBitmap &bmp,
const wxPoint &pos = wxDefaultPosition,
685 const wxSize &size = wxDefaultSize);
688 void OnMouseSelected(wxMouseEvent &event);
689 void SetSelected(
bool selected);
690 void OnPaint(wxPaintEvent &event);
692 bool GetSelected() {
return m_bSelected; }
697 wxColour m_boxColour;
698 wxBitmap m_bmpNormal;
701 DECLARE_EVENT_TABLE()
709 void CreatePanel(
size_t parent,
int border_size,
int group_item_spacing);
710 void CompletePanel(
void);
711 void SetDBDirs(ArrayOfCDI &array) { m_db_dirs = array; }
712 void SetGroupArray(ChartGroupArray *pGroupArray) {
713 m_pGroupArray = pGroupArray;
715 void SetInitialSettings(
void);
716 void CompleteInitialSettings(
void);
717 void PopulateTrees(
void);
718 void PopulateTreeCtrl(wxTreeCtrl *ptc,
const wxArrayString &dir_array,
719 const wxColour &col, wxFont *pFont = NULL);
720 void BuildNotebookPages(ChartGroupArray *pGroupArray);
721 void EmptyChartGroupArray(ChartGroupArray *s);
722 void ClearGroupPages();
724 void OnNodeExpanded(wxTreeEvent &event);
725 void OnAvailableSelection(wxTreeEvent &event);
726 void OnInsertChartItem(wxCommandEvent &event);
727 void OnRemoveChartItem(wxCommandEvent &event);
728 void OnGroupPageChange(wxNotebookEvent &event);
729 void OnNewGroup(wxCommandEvent &event);
730 void OnDeleteGroup(wxCommandEvent &event);
732 ChartGroupArray *CloneChartGroupArray(ChartGroupArray *s);
733 wxTreeCtrl *AddEmptyGroupPage(
const wxString &label);
735 bool modified, m_UIcomplete, m_settingscomplete, m_treespopulated;
737 wxScrolledWindow *m_panel;
740 int FindGroupBranch(
ChartGroup *pGroup, wxTreeCtrl *ptree, wxTreeItemId item,
741 wxString *pbranch_adder);
744 wxFlexGridSizer *groupsSizer;
745 wxButton *m_pAddButton, *m_pRemoveButton, *m_pNewGroupButton;
746 wxButton *m_pDeleteGroupButton;
747 wxGenericDirCtrl *allAvailableCtl, *defaultAllCtl;
748 wxTreeCtrl *m_pActiveChartsTree, *lastSelectedCtl;
749 wxTreeItemId lastDeletedItem;
750 wxNotebook *m_GroupNB;
754 ArrayOfCDI m_db_dirs;
755 ArrayOfDirCtrls m_DirCtrlArray;
756 ChartGroupArray *m_pGroupArray;
758 int m_border_size, m_group_item_spacing, m_GroupSelectedPage;
760 wxBoxSizer *m_topSizer;
762 DECLARE_EVENT_TABLE()
766class OpenGLOptionsDlg :
private Uncopyable,
public wxDialog {
768 explicit OpenGLOptionsDlg(wxWindow *parent);
769 bool GetAcceleratedPanning(
void)
const;
770 bool GetTextureCompression(
void)
const;
771 bool GetPolygonSmoothing(
void)
const;
772 bool GetLineSmoothing(
void)
const;
773 bool GetShowFPS(
void)
const;
774 bool GetSoftwareGL(
void)
const;
775 bool GetTextureCompressionCaching(
void)
const;
776 bool GetRebuildCache(
void)
const;
777 int GetTextureMemorySize(
void)
const;
781 void OnButtonRebuild(wxCommandEvent &event);
782 void OnButtonClear(wxCommandEvent &event);
783 wxString GetTextureCacheSize(
void);
785 wxCheckBox *m_cbUseAcceleratedPanning, *m_cbTextureCompression;
786 wxCheckBox *m_cbTextureCompressionCaching, *m_cbShowFPS, *m_cbSoftwareGL,
787 *m_cbPolygonSmoothing, *m_cbLineSmoothing;
788 wxSpinCtrl *m_sTextureDimension, *m_sTextureMemorySize;
789 wxStaticText *m_cacheSize, *m_memorySize;
791 bool m_brebuild_cache;
793 DECLARE_EVENT_TABLE()
797#define ID_MMSI_PROPS_LIST 10073
811 explicit MMSIListCtrl(wxWindow *parent, wxWindowID
id,
const wxPoint &pos,
812 const wxSize &size,
long style);
815 wxString OnGetItemText(
long item,
long column)
const;
816 void OnListItemClick(wxListEvent &event);
817 void OnListItemActivated(wxListEvent &event);
818 void OnListItemRightClick(wxListEvent &event);
819 void PopupMenuHandler(wxCommandEvent &event);
824 DECLARE_EVENT_TABLE()
827#define ID_MMSIEDIT_OK 8191
828#define ID_MMSIEDIT_CANCEL 8192
829#define ID_MMSI_CTL 8193
830#define ID_DEF_MENU_MMSI_EDIT 8194
831#define ID_DEF_MENU_MMSI_DELETE 8195
836 wxWindowID
id = wxID_ANY,
837 const wxString &caption = wxEmptyString,
838 const wxPoint &pos = wxDefaultPosition,
839 const wxSize &size = wxDefaultSize,
long style = 0);
842 void SetColorScheme(ColorScheme cs);
843 void CreateControls(
void);
844 void OnMMSIEditCancelClick(wxCommandEvent &event);
845 void OnMMSIEditOKClick(wxCommandEvent &event);
846 void OnCtlUpdated(wxCommandEvent &event);
849 wxTextCtrl *m_MMSICtl, m_ShipNameCtl;
850 wxRadioButton *m_rbTypeTrackDefault, *m_rbTypeTrackAlways;
851 wxRadioButton *m_rbTypeTrackNever;
852 wxCheckBox *m_cbTrackPersist, *m_IgnoreButton, *m_MOBButton, *m_VDMButton,
854 wxButton *m_CancelButton, *m_OKButton;
859 DECLARE_EVENT_TABLE()
867 void OnNewButton(wxCommandEvent &event);
868 void SetColorScheme(ColorScheme cs);
869 void UpdateMMSIList(
void);
872 wxButton *m_pButtonNew;
881 const wxString &caption = wxEmptyString,
882 const wxPoint &pos = wxDefaultPosition,
883 const wxSize &size = wxDefaultSize,
887 void SetColorScheme(ColorScheme cs);
888 void CreateControls(
void);
889 void OnConfigEditCancelClick(wxCommandEvent &event);
890 void OnConfigEditOKClick(wxCommandEvent &event);
891 wxString GetCreatedTemplateGUID() {
return m_createdTemplateGUID; }
893 wxTextCtrl *m_TitleCtl, *m_DescriptionCtl;
894 wxButton *m_CancelButton, *m_OKButton;
895 wxString m_createdTemplateGUID;
896 DECLARE_EVENT_TABLE()
Keeps listening over it's lifespan, removes itself on destruction.