diff --git a/source/tools/atlas/AtlasUI/ScenarioEditor/Sections/Terrain/Terrain.cpp b/source/tools/atlas/AtlasUI/ScenarioEditor/Sections/Terrain/Terrain.cpp index 51452f0fce..c73ac4ab8b 100644 --- a/source/tools/atlas/AtlasUI/ScenarioEditor/Sections/Terrain/Terrain.cpp +++ b/source/tools/atlas/AtlasUI/ScenarioEditor/Sections/Terrain/Terrain.cpp @@ -48,11 +48,11 @@ #include #include #include +#include #include #include #include #include -#include #include #include #include @@ -546,13 +546,14 @@ BEGIN_EVENT_TABLE(TextureNotebookPage, wxPanel) END_EVENT_TABLE(); -class TextureNotebook : public wxNotebook +class TextureNotebook : public wxChoicebook { public: TextureNotebook(ScenarioEditor& scenarioEditor, wxWindow *parent) - : wxNotebook(parent, wxID_ANY/*, wxDefaultPosition, wxDefaultSize, wxNB_FIXEDWIDTH*/), + : wxChoicebook(parent, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxCHB_TOP), m_ScenarioEditor(scenarioEditor) { + GetChoiceCtrl()->SetMaxSize(wxSize{300, 100}); } void LoadTerrain() @@ -607,8 +608,8 @@ private: DECLARE_EVENT_TABLE(); }; -BEGIN_EVENT_TABLE(TextureNotebook, wxNotebook) - EVT_NOTEBOOK_PAGE_CHANGED(wxID_ANY, TextureNotebook::OnPageChanged) +BEGIN_EVENT_TABLE(TextureNotebook, wxChoicebook) + EVT_CHOICEBOOK_PAGE_CHANGED(wxID_ANY, TextureNotebook::OnPageChanged) END_EVENT_TABLE(); //////////////////////////////////////////////////////////////////////////