automagic_settings.h

main 53 lines · 1.6 KB Raw
Alex Alex Commit Map Editor 18/10/2026 23:40
1#ifndef RME_AUTOMAGIC_SETTINGS_H_
2#define RME_AUTOMAGIC_SETTINGS_H_
3
4#include <wx/dialog.h>
5#include <wx/checkbox.h>
6#include <wx/button.h>
7#include <wx/sizer.h>
8#include <wx/stattext.h>
9#include <wx/statbox.h>
10#include <wx/spinctrl.h>
11
12class AutomagicSettingsDialog : public wxDialog {
13public:
14 AutomagicSettingsDialog(wxWindow* parent);
15 virtual ~AutomagicSettingsDialog();
16
17 // Get the current settings from the dialog
18 bool IsAutomagicEnabled() const;
19 bool IsSameGroundTypeBorderEnabled() const;
20 bool IsWallsRepelBordersEnabled() const;
21 bool IsLayerCarpetsEnabled() const;
22 bool IsBorderizeDeleteEnabled() const;
23 // New custom border methods
24 bool IsCustomBorderEnabled() const;
25 int GetCustomBorderId() const;
26
27protected:
28 // Event handlers
29 void OnClickOK(wxCommandEvent& event);
30 void OnClickCancel(wxCommandEvent& event);
31 void OnAutomagicCheck(wxCommandEvent& event);
32 void OnSameGroundTypeCheck(wxCommandEvent& event);
33 void OnClose(wxCloseEvent& event);
34 void OnCustomBorderCheck(wxCommandEvent& event); // New event handler
35
36 // UI elements
37 wxCheckBox* automagic_enabled_checkbox;
38 wxCheckBox* same_ground_type_checkbox;
39 wxCheckBox* walls_repel_borders_checkbox;
40 wxCheckBox* layer_carpets_checkbox;
41 wxCheckBox* borderize_delete_checkbox;
42 // New UI elements for custom border
43 wxCheckBox* custom_border_checkbox;
44 wxSpinCtrl* custom_border_id_field;
45 wxStaticText* custom_border_id_label;
46 wxStdDialogButtonSizer* buttons_sizer;
47 wxButton* ok_button;
48 wxButton* cancel_button;
49
50 DECLARE_EVENT_TABLE()
51};
52
53#endif // RME_AUTOMAGIC_SETTINGS_H_
Top