Skip to content

Commit fdc6fc5

Browse files
committed
Revert "Revert "Added xrUICore project. Some ui files moved to xrUICore""
This reverts commit 0b24d96.
1 parent 39dd000 commit fdc6fc5

File tree

455 files changed

+4835
-4298
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

455 files changed

+4835
-4298
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
[string_table]
2+
language = rus
3+
font_prefix = ;_west ;_cent
4+
5+
[Languages]
6+
eng
7+
rus

src/Common/CommonImportExport.inl

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,12 @@
7272
#define XRSOUND_API XR_IMPORT
7373
#endif
7474

75+
#ifdef XRUICORE_EXPORTS
76+
#define XRUICORE_API XR_EXPORT
77+
#else
78+
#define XRUICORE_API XR_IMPORT
79+
#endif
80+
7581
#ifndef ENGINE_API
7682
#ifndef NO_ENGINE_API
7783
#ifdef ENGINE_BUILD

src/engine.sln

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,8 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xrECore", "editors\xrECore\
248248
EndProject
249249
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xrEditor", "editors\xrEditor\xrEditor.vcxproj", "{BE4B23E7-2CA8-4607-A473-116C4242F23D}"
250250
EndProject
251+
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xrUICore", "xrUICore\xrUICore.vcxproj", "{37B3642C-B706-4C93-BC54-BADADC8FC9B1}"
252+
EndProject
251253
Global
252254
GlobalSection(SolutionConfigurationPlatforms) = preSolution
253255
Debug|x64 = Debug|x64
@@ -1125,6 +1127,18 @@ Global
11251127
{BE4B23E7-2CA8-4607-A473-116C4242F23D}.Release|x64.Build.0 = Release|x64
11261128
{BE4B23E7-2CA8-4607-A473-116C4242F23D}.Release|x86.ActiveCfg = Release|Win32
11271129
{BE4B23E7-2CA8-4607-A473-116C4242F23D}.Release|x86.Build.0 = Release|Win32
1130+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Debug|x64.ActiveCfg = Debug|x64
1131+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Debug|x64.Build.0 = Debug|x64
1132+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Debug|x86.ActiveCfg = Debug|Win32
1133+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Debug|x86.Build.0 = Debug|Win32
1134+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Mixed|x64.ActiveCfg = Mixed|x64
1135+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Mixed|x64.Build.0 = Mixed|x64
1136+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Mixed|x86.ActiveCfg = Mixed|Win32
1137+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Mixed|x86.Build.0 = Mixed|Win32
1138+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Release|x64.ActiveCfg = Release|x64
1139+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Release|x64.Build.0 = Release|x64
1140+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Release|x86.ActiveCfg = Release|Win32
1141+
{37B3642C-B706-4C93-BC54-BADADC8FC9B1}.Release|x86.Build.0 = Release|Win32
11281142
EndGlobalSection
11291143
GlobalSection(SolutionProperties) = preSolution
11301144
HideSolutionNode = FALSE

src/utils/xrSE_Factory/xrUIXmlParser.cpp

Lines changed: 1 addition & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -14,59 +14,9 @@ shared_str CUIXml::correct_file_name(pcstr path, pcstr fn)
1414
return fn;
1515
}
1616

17-
//#define LOG_ALL_XMLS
18-
#ifdef LOG_ALL_XMLS
19-
int ListXmlCount = 0;
20-
struct DBGList_
21-
{
22-
int num;
23-
bool closed;
24-
};
25-
xr_vector<DBGList_> dbg_list_xmls;
26-
void dump_list_xmls()
27-
{
28-
Msg("------Total xmls %d", dbg_list_xmls.size());
29-
xr_vector<DBGList_>::iterator _it = dbg_list_xmls.begin();
30-
for (; _it != dbg_list_xmls.end(); ++_it)
31-
if (!(*_it).closed)
32-
Msg("--leak detected ---- xml = %d", (*_it).num);
33-
}
34-
#else
35-
void dump_list_xmls() {}
36-
#endif
37-
3817
CUIXml::CUIXml()
3918
{
40-
#ifdef LOG_ALL_XMLS
41-
ListXmlCount++;
42-
m_dbg_id = ListXmlCount;
43-
dbg_list_xmls.push_back(DBGList_());
44-
dbg_list_xmls.back().num = m_dbg_id;
45-
dbg_list_xmls.back().closed = false;
46-
#endif
4719
}
4820

4921
CUIXml::~CUIXml()
50-
{
51-
#ifdef LOG_ALL_XMLS
52-
xr_vector<DBGList_>::iterator _it = dbg_list_xmls.begin();
53-
bool bOK = false;
54-
for (; _it != dbg_list_xmls.end(); ++_it)
55-
{
56-
if ((*_it).num == m_dbg_id && !(*_it).closed)
57-
{
58-
bOK = true;
59-
(*_it).closed = true;
60-
dbg_list_xmls.erase(_it);
61-
break;
62-
}
63-
if ((*_it).num == m_dbg_id && (*_it).closed)
64-
{
65-
Msg("--XML [%d] already deleted", m_dbg_id);
66-
bOK = true;
67-
}
68-
}
69-
if (!bOK)
70-
Msg("CUIXml::~CUIXml.[%d] cannot find xml in list", m_dbg_id);
71-
#endif
72-
}
22+
{}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#include "stdafx.h"
2+
#include "IStringTable.h"
3+
4+
IStringTable* gStringTable = nullptr;
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
//////////////////////////////////////////////////////////////////////////
2+
// string_table.h: таблица строк, используемых в игре
3+
//////////////////////////////////////////////////////////////////////////
4+
5+
#pragma once
6+
#include "xrEngine/StringTable/IStringTableDefs.h"
7+
#include "xrCommon/xr_map.h"
8+
9+
class IStringTable
10+
{
11+
public:
12+
virtual ~IStringTable() {};
13+
14+
virtual STRING_VALUE translate(const STRING_ID& str_id) const = 0;
15+
virtual void rescan() = 0;
16+
};
17+
18+
extern ENGINE_API IStringTable* gStringTable;

src/xrGame/string_table_defs.h renamed to src/xrEngine/StringTable/IStringTableDefs.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,4 @@
22
#include "xrCore/xrstring.h"
33

44
typedef shared_str STRING_ID;
5-
//. typedef int STRING_INDEX;
65
typedef shared_str STRING_VALUE;
7-
8-
//. #define NO_STRING STRING_INDEX(-1)

src/xrEngine/xrEngine.vcxproj

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,8 @@
263263
<ClInclude Include="Stats.h" />
264264
<ClInclude Include="stdafx.h" />
265265
<ClInclude Include="std_classes.h" />
266+
<ClInclude Include="StringTable\IStringTable.h" />
267+
<ClInclude Include="StringTable\IStringTableDefs.h" />
266268
<ClInclude Include="Text_Console.h" />
267269
<ClInclude Include="thunderbolt.h" />
268270
<ClInclude Include="tntQAVI.h" />
@@ -278,6 +280,7 @@
278280
<ClInclude Include="xr_collide_form.h" />
279281
<ClInclude Include="xr_efflensflare.h" />
280282
<ClInclude Include="xr_input.h" />
283+
<ClInclude Include="xr_input_xinput.h" />
281284
<ClInclude Include="XR_IOConsole.h" />
282285
<ClInclude Include="xr_ioc_cmd.h" />
283286
<ClInclude Include="xr_object.h" />
@@ -372,6 +375,7 @@
372375
<ClCompile Include="stdafx.cpp">
373376
<PrecompiledHeader>Create</PrecompiledHeader>
374377
</ClCompile>
378+
<ClCompile Include="StringTable\IStringTable.cpp" />
375379
<ClCompile Include="Text_Console.cpp" />
376380
<ClCompile Include="Text_Console_WndProc.cpp" />
377381
<ClCompile Include="thunderbolt.cpp" />
@@ -385,6 +389,7 @@
385389
<ClCompile Include="xr_collide_form.cpp" />
386390
<ClCompile Include="xr_efflensflare.cpp" />
387391
<ClCompile Include="xr_input.cpp" />
392+
<ClCompile Include="xr_input_xinput.cpp" />
388393
<ClCompile Include="XR_IOConsole.cpp" />
389394
<ClCompile Include="XR_IOConsole_callback.cpp" />
390395
<ClCompile Include="XR_IOConsole_control.cpp" />

src/xrEngine/xrEngine.vcxproj.filters

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -232,6 +232,9 @@
232232
<Filter Include="Rendering Device">
233233
<UniqueIdentifier>{e4d34774-3a5b-468f-9400-12c702636fa1}</UniqueIdentifier>
234234
</Filter>
235+
<Filter Include="Game API\StringTable">
236+
<UniqueIdentifier>{948b4643-0f42-4027-ac44-dbe3702887f4}</UniqueIdentifier>
237+
</Filter>
235238
</ItemGroup>
236239
<ItemGroup>
237240
<ClInclude Include="defines.h">
@@ -564,6 +567,15 @@
564567
<ClInclude Include="Stats.h">
565568
<Filter>Rendering Device</Filter>
566569
</ClInclude>
570+
<ClInclude Include="xr_input_xinput.h">
571+
<Filter>Interfaces\Input</Filter>
572+
</ClInclude>
573+
<ClInclude Include="StringTable\IStringTable.h">
574+
<Filter>Game API\StringTable</Filter>
575+
</ClInclude>
576+
<ClInclude Include="StringTable\IStringTableDefs.h">
577+
<Filter>Game API\StringTable</Filter>
578+
</ClInclude>
567579
</ItemGroup>
568580
<ItemGroup>
569581
<ClCompile Include="defines.cpp">
@@ -881,6 +893,12 @@
881893
<ClCompile Include="Stats.cpp">
882894
<Filter>Rendering Device</Filter>
883895
</ClCompile>
896+
<ClCompile Include="xr_input_xinput.cpp">
897+
<Filter>Interfaces\Input</Filter>
898+
</ClCompile>
899+
<ClCompile Include="StringTable\IStringTable.cpp">
900+
<Filter>Game API\StringTable</Filter>
901+
</ClCompile>
884902
</ItemGroup>
885903
<ItemGroup>
886904
<Text Include="ClientServer.txt" />

0 commit comments

Comments
 (0)