From 666e8be63e02f9e14c011d867377830096878fd4 Mon Sep 17 00:00:00 2001 From: jkulawik Date: Mon, 28 Sep 2020 22:32:25 +0200 Subject: [PATCH] Community version labels --- HPL2/tools/editors/common/EditorWindowLowerToolbar.cpp | 10 ++++++++++ HPL2/tools/editors/common/EditorWindowLowerToolbar.h | 5 +++++ HPL2/tools/editors/leveleditor/LevelEditor.cpp | 6 +++++- 3 files changed, 20 insertions(+), 1 deletion(-) diff --git a/HPL2/tools/editors/common/EditorWindowLowerToolbar.cpp b/HPL2/tools/editors/common/EditorWindowLowerToolbar.cpp index 61319f033..497819240 100644 --- a/HPL2/tools/editors/common/EditorWindowLowerToolbar.cpp +++ b/HPL2/tools/editors/common/EditorWindowLowerToolbar.cpp @@ -251,6 +251,16 @@ iWidget* iEditorWindowLowerToolbar::AddClipPlaneControls() return mpGClipPlanes; } +iWidget* iEditorWindowLowerToolbar::AddCommunityCredits() +{ + //mpVersionLabelDummy = mpSet->CreateWidgetGroup(0, cVector2f(290,43), _W("Credits"), mpBGFrame); + mpVersionLabelDummy = mpSet->CreateWidgetDummy(0, mpBGFrame); + + mpGridPresetLabel = mpSet->CreateWidgetLabel(cVector3f(200, 4, 0.1f), cVector2f(32, 20), _W("Level Editor - Community version 1.0"), mpVersionLabelDummy); + + return mpVersionLabelDummy; +} + //--------------------------------------------------------------- void iEditorWindowLowerToolbar::SetFocusedClipPlane(int alX) diff --git a/HPL2/tools/editors/common/EditorWindowLowerToolbar.h b/HPL2/tools/editors/common/EditorWindowLowerToolbar.h index 9f75b9502..febfd5256 100644 --- a/HPL2/tools/editors/common/EditorWindowLowerToolbar.h +++ b/HPL2/tools/editors/common/EditorWindowLowerToolbar.h @@ -41,6 +41,7 @@ class iEditorWindowLowerToolbar : public iEditorWindow iWidget* AddLightingControls(); iWidget* AddCameraControls(); iWidget* AddClipPlaneControls(); + iWidget* AddCommunityCredits(); void SetFocusedClipPlane(int alX); int GetFocusedClipPlane(); @@ -100,6 +101,10 @@ class iEditorWindowLowerToolbar : public iEditorWindow cWidgetButton* mpBClipNormalSwitch; cEditorInputNumber* mpInpClipPlaneHeight; cWidgetButton* mpBClipPlaneCullSide; + + //Credits + cWidgetDummy* mpVersionLabelDummy; + cWidgetLabel* mpVersionLabel; }; //-------------------------------------------------------------------- diff --git a/HPL2/tools/editors/leveleditor/LevelEditor.cpp b/HPL2/tools/editors/leveleditor/LevelEditor.cpp index ecee800da..1fa05f2b2 100644 --- a/HPL2/tools/editors/leveleditor/LevelEditor.cpp +++ b/HPL2/tools/editors/leveleditor/LevelEditor.cpp @@ -561,6 +561,10 @@ void cLevelEditor::OnInitLayout() vHandlePos += cVector3f(pHandle->GetSize().x+10, 0, 0); pHandle = mpLowerToolbar->AddClipPlaneControls(); pHandle->SetPosition(vHandlePos); + //New stuff: + vHandlePos += cVector3f(pHandle->GetSize().x+10, 0, 0); + pHandle = mpLowerToolbar->AddCommunityCredits(); + pHandle->SetPosition(vHandlePos); //////////////////////////////////// // Search Window @@ -685,7 +689,7 @@ void cLevelEditor::OnLoadConfig() } // Window caption - msCaption = "HPL Level Editor"; + msCaption = "HPL Level Editor (Community Edition)"; SetLogFile(GetHomeDir() + _W("LevelEditor.log"));