Skip to content

Commit 3f12bb1

Browse files
author
nitrocaster
committed
Merge xrXMLParser into xrCore. Close #43.
1 parent 7e5ea13 commit 3f12bb1

17 files changed

+45
-358
lines changed

src/engine.sln

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -79,8 +79,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xrRender_R2", "Layers\xrRen
7979
EndProject
8080
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xrSound", "xrSound\xrSound.vcxproj", "{CCCA7859-EB86-493E-9B53-C4235F45B3C5}"
8181
EndProject
82-
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xrXMLParser", "xrXMLParser\xrXMLParser.vcxproj", "{94A1C366-3D19-48E6-8170-4ADC2E70DF98}"
83-
EndProject
8482
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "LW_Export_80", "plugins\lw\LW_Export80.vcxproj", "{F573DE85-0866-4775-955F-6C3241D2AE80}"
8583
EndProject
8684
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "LW_Server", "plugins\lw\LW_Server.vcxproj", "{6BA3121A-ACBC-4685-9246-4549CA1EFFFD}"
@@ -883,36 +881,6 @@ Global
883881
{CCCA7859-EB86-493E-9B53-C4235F45B3C5}.Release|Win32.ActiveCfg = Release|Win32
884882
{CCCA7859-EB86-493E-9B53-C4235F45B3C5}.Release|Win32.Build.0 = Release|Win32
885883
{CCCA7859-EB86-493E-9B53-C4235F45B3C5}.Release|x64.ActiveCfg = Release|Win32
886-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Debug_Dedicated|Mixed Platforms.ActiveCfg = Debug|Win32
887-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Debug_Dedicated|Mixed Platforms.Build.0 = Debug|Win32
888-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Debug_Dedicated|Win32.ActiveCfg = Debug|Win32
889-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Debug_Dedicated|x64.ActiveCfg = Release|Win32
890-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Debug_Dedicated|x64.Build.0 = Release|Win32
891-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
892-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Debug|Mixed Platforms.Build.0 = Debug|Win32
893-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Debug|Win32.ActiveCfg = Debug|Win32
894-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Debug|Win32.Build.0 = Debug|Win32
895-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Debug|x64.ActiveCfg = Debug|Win32
896-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Mixed_Dedicated|Mixed Platforms.ActiveCfg = Mixed|Win32
897-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Mixed_Dedicated|Mixed Platforms.Build.0 = Mixed|Win32
898-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Mixed_Dedicated|Win32.ActiveCfg = Mixed|Win32
899-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Mixed_Dedicated|x64.ActiveCfg = Release|Win32
900-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Mixed_Dedicated|x64.Build.0 = Release|Win32
901-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Mixed|Mixed Platforms.ActiveCfg = Mixed|Win32
902-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Mixed|Mixed Platforms.Build.0 = Mixed|Win32
903-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Mixed|Win32.ActiveCfg = Mixed|Win32
904-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Mixed|Win32.Build.0 = Mixed|Win32
905-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Mixed|x64.ActiveCfg = Mixed|Win32
906-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Release_Dedicated|Mixed Platforms.ActiveCfg = Release|Win32
907-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Release_Dedicated|Mixed Platforms.Build.0 = Release|Win32
908-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Release_Dedicated|Win32.ActiveCfg = Release|Win32
909-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Release_Dedicated|x64.ActiveCfg = Release|Win32
910-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Release_Dedicated|x64.Build.0 = Release|Win32
911-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Release|Mixed Platforms.ActiveCfg = Release|Win32
912-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Release|Mixed Platforms.Build.0 = Release|Win32
913-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Release|Win32.ActiveCfg = Release|Win32
914-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Release|Win32.Build.0 = Release|Win32
915-
{94A1C366-3D19-48E6-8170-4ADC2E70DF98}.Release|x64.ActiveCfg = Release|Win32
916884
{F573DE85-0866-4775-955F-6C3241D2AE80}.Debug_Dedicated|Mixed Platforms.ActiveCfg = Debug|Win32
917885
{F573DE85-0866-4775-955F-6C3241D2AE80}.Debug_Dedicated|Mixed Platforms.Build.0 = Debug|Win32
918886
{F573DE85-0866-4775-955F-6C3241D2AE80}.Debug_Dedicated|Win32.ActiveCfg = Debug|Win32
File renamed without changes.

src/xrXMLParser/tinystr.h renamed to src/xrCore/Xml/tinystr.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ class TiXmlString
256256
{
257257
// The rep_ is really an array of ints. (see the allocator, above).
258258
// Cast it back before delete, so the compiler won't incorrectly call destructors.
259-
xr_free( reinterpret_cast<int*>( rep_ ) );
259+
xr_free( reinterpret_cast<int *&>( rep_ ) );
260260
}
261261
}
262262

File renamed without changes.

src/xrXMLParser/tinyxml.h renamed to src/xrCore/Xml/tinyxml.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ const TiXmlEncoding TIXML_DEFAULT_ENCODING = TIXML_ENCODING_UNKNOWN;
193193
A Decleration contains: Attributes (not on tree)
194194
@endverbatim
195195
*/
196-
class XRXMLPARSER_API TiXmlBase
196+
class XRCORE_API TiXmlBase
197197
{
198198
friend class TiXmlNode;
199199
friend class TiXmlElement;
@@ -418,7 +418,7 @@ class XRXMLPARSER_API TiXmlBase
418418
in a document, or stand on its own. The type of a TiXmlNode
419419
can be queried, and it can be cast to its more defined type.
420420
*/
421-
class XRXMLPARSER_API TiXmlNode : public TiXmlBase
421+
class XRCORE_API TiXmlNode : public TiXmlBase
422422
{
423423
friend class TiXmlDocument;
424424
friend class TiXmlElement;
File renamed without changes.
File renamed without changes.

src/xrXMLParser/xrXMLParser.cpp renamed to src/xrCore/Xml/xrXMLParser.cpp

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@
44
#include "xrXMLParser.h"
55

66

7-
XRXMLPARSER_API CXml::CXml()
7+
CXml::CXml()
88
: m_root (NULL),
99
m_pLocalRoot (NULL)
1010
{}
1111

12-
XRXMLPARSER_API CXml::~CXml()
12+
CXml::~CXml()
1313
{
1414
ClearInternal();
1515
}
@@ -456,19 +456,3 @@ LPCSTR CXml::CheckUniqueAttrib (XML_NODE* start_node, LPCSTR tag_name, LPCSTR at
456456
return NULL;
457457
}
458458
#endif
459-
460-
BOOL APIENTRY DllMain( HANDLE hModule,
461-
u32 ul_reason_for_call,
462-
LPVOID lpReserved
463-
)
464-
{
465-
switch (ul_reason_for_call)
466-
{
467-
case DLL_PROCESS_ATTACH: {
468-
break;
469-
}
470-
case DLL_PROCESS_DETACH:
471-
break;
472-
}
473-
return TRUE;
474-
}

src/xrXMLParser/xrXMLParser.h renamed to src/xrCore/Xml/xrXMLParser.h

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,6 @@
44

55
#include "Common/Platform.hpp"
66

7-
#ifdef XRXMLPARSER_EXPORTS
8-
#define XRXMLPARSER_API XR_EXPORT
9-
#else
10-
#define XRXMLPARSER_API XR_IMPORT
11-
#pragma comment (lib,"xrXMLParser.lib")
12-
#endif
13-
147
const LPCSTR CONFIG_PATH = "$game_config$";
158
const LPCSTR UI_PATH = "ui";
169

@@ -20,7 +13,7 @@ const LPCSTR UI_PATH = "ui";
2013
typedef TiXmlNode XML_NODE;
2114
typedef TiXmlAttribute XML_ATTRIBUTE;
2215

23-
class XRXMLPARSER_API CXml
16+
class XRCORE_API CXml
2417
{
2518
void Load (LPCSTR path_alias, LPCSTR xml_filename);
2619
public:

src/xrCore/xrCore.vcxproj

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,11 @@
254254
<ClCompile Include="Threading\Event.cpp" />
255255
<ClCompile Include="Threading\ttapi.cpp" />
256256
<ClCompile Include="Threading\Lock.cpp" />
257+
<ClCompile Include="Xml\tinystr.cpp" />
258+
<ClCompile Include="Xml\tinyxml.cpp" />
259+
<ClCompile Include="Xml\tinyxmlerror.cpp" />
260+
<ClCompile Include="Xml\tinyxmlparser.cpp" />
261+
<ClCompile Include="Xml\xrXMLParser.cpp" />
257262
<ClCompile Include="xrCore.cpp" />
258263
<ClCompile Include="ModuleLookup.cpp" />
259264
<ClCompile Include="xrDebug.cpp" />
@@ -372,6 +377,9 @@
372377
<ClInclude Include="Threading\ttapi.h" />
373378
<ClInclude Include="Threading\Lock.hpp" />
374379
<ClInclude Include="vector.h" />
380+
<ClInclude Include="Xml\tinystr.h" />
381+
<ClInclude Include="Xml\tinyxml.h" />
382+
<ClInclude Include="Xml\xrXMLParser.h" />
375383
<ClInclude Include="xrCore.h" />
376384
<ClInclude Include="ModuleLookup.hpp" />
377385
<ClInclude Include="xrDebug.h" />

0 commit comments

Comments
 (0)