From aeeec0b013b9e63fe5c022db4e0fa5e176d05c79 Mon Sep 17 00:00:00 2001 From: Adam Johnson Date: Sat, 16 Apr 2011 15:55:06 -0400 Subject: [PATCH] Fix for ComponentMgr not showing anything. Make the ini file error more accurate as well. --- Sources/Tools/MaxComponent/plComponentMgr.cpp | 8 +++++++- Sources/Tools/MaxMain/GlobalUtility.cpp | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/Sources/Tools/MaxComponent/plComponentMgr.cpp b/Sources/Tools/MaxComponent/plComponentMgr.cpp index 65708ee9..0dcdd0a9 100644 --- a/Sources/Tools/MaxComponent/plComponentMgr.cpp +++ b/Sources/Tools/MaxComponent/plComponentMgr.cpp @@ -87,8 +87,14 @@ int IDescCompare(ClassDesc *desc1, ClassDesc *desc2); void plComponentMgr::Register(ClassDesc *desc) { - // Organize desc's by category and name + // No descs? Go ahead and push it to the back... + if (fDescs.size() == 0) + { + fDescs.push_back(desc); + return; + } + // Organize desc's by category and name std::vector::iterator it; for (it = fDescs.begin(); it != fDescs.end(); it++) { diff --git a/Sources/Tools/MaxMain/GlobalUtility.cpp b/Sources/Tools/MaxMain/GlobalUtility.cpp index 321d7674..6449f3ac 100644 --- a/Sources/Tools/MaxMain/GlobalUtility.cpp +++ b/Sources/Tools/MaxMain/GlobalUtility.cpp @@ -203,7 +203,7 @@ DWORD PlasmaMax::Start() const char* pathTemp = plMaxConfig::GetClientPath(false, true); if (pathTemp == nil) { - hsMessageBox("PlasmaMAX2.ini is missing the Client Path", "Error", hsMessageBoxNormal); + hsMessageBox("PlasmaMAX2.ini is missing or invalid", "Plasma/2.0 Error", hsMessageBoxNormal); } else {