https://github.com/libsdl-org/Maelstrom/commit/3ca0187343dcb597221891562428903cfb15d16c
From 3ca0187343dcb597221891562428903cfb15d16c Mon Sep 17 00:00:00 2001
From: Sam Lantinga <[EMAIL REDACTED]>
Date: Mon, 31 Oct 2011 19:05:42 -0400
Subject: [PATCH] Added an arbitrary area for holding elements
---
MaelstromUI.cpp | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/MaelstromUI.cpp b/MaelstromUI.cpp
index 88cba024..50383d0a 100644
--- a/MaelstromUI.cpp
+++ b/MaelstromUI.cpp
@@ -191,7 +191,9 @@ MaelstromUI::CreatePanelDelegate(UIPanel *panel, const char *delegate)
UIElement *
MaelstromUI::CreateElement(UIBaseElement *parent, const char *type, const char *name)
{
- if (strcasecmp(type, "Line") == 0) {
+ if (strcasecmp(type, "Area") == 0) {
+ return new UIElement(parent, name);
+ } else if (strcasecmp(type, "Line") == 0) {
return new UIElementLine(parent, name);
} else if (strcasecmp(type, "Rectangle") == 0) {
return new UIElementRect(parent, name);