Skip to content

Commit 2b3140e

Browse files
committed
xrEngine/LightAnimLibrary: use xr_string instead of shared_str
1 parent 4fa498a commit 2b3140e

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

src/editors/LevelEditor/EditLightAnim.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
#include "EditLightAnim.h"
77
#include "Scene.h"
8-
#include "LightAnimLibrary.h"
8+
#include "xrEngine/LightAnimLibrary.h"
99
#include "editors/ECore/Editor/ColorPicker.h"
1010
#include "editors/ECore/Editor/ui_main.h"
1111
//---------------------------------------------------------------------------
@@ -162,7 +162,7 @@ void TfrmEditLightAnim::InitItems()
162162
{
163163
ListItemsVec items;
164164
for (LAItemIt it = LALib.Items.begin(); it != LALib.Items.end(); it++)
165-
LHelper().CreateItem(items, *(*it)->cName, 0, 0, 0);
165+
LHelper().CreateItem(items, (*it)->cName.c_str(), 0, 0, 0);
166166
m_Items->AssignItems(items, false, true);
167167
}
168168

@@ -255,7 +255,7 @@ void __fastcall TfrmEditLightAnim::ebAddAnimClick(TObject* Sender)
255255
pref.c_str(), 2, fastdelegate::bind<TFindObjectByName>(this, &TfrmEditLightAnim::FindItemByName), false, true);
256256
CLAItem* I = LALib.AppendItem(name.c_str(), 0);
257257
InitItems();
258-
m_Items->SelectItem(*I->cName, true, false, true);
258+
m_Items->SelectItem(I->cName.c_str(), true, false, true);
259259
OnModified();
260260
}
261261

@@ -271,7 +271,7 @@ void __fastcall TfrmEditLightAnim::ebCloneClick(TObject* Sender)
271271
fastdelegate::bind<TFindObjectByName>(this, &TfrmEditLightAnim::FindItemByName), false, true);
272272
CLAItem* I = LALib.AppendItem(name.c_str(), m_CurrentItem);
273273
InitItems();
274-
m_Items->SelectItem(*I->cName, true, false, true);
274+
m_Items->SelectItem(I->cName.c_str(), true, false, true);
275275
OnModified();
276276
}
277277
else

src/xrEngine/LightAnimLibrary.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ LAItemIt ELightAnimLibrary::FindItemI(LPCSTR name)
269269
{
270270
if (name && name[0])
271271
for (LAItemIt it = Items.begin(); it != Items.end(); it++)
272-
if (0 == xr_strcmp((*it)->cName, name))
272+
if (0 == xr_strcmp((*it)->cName.c_str(), name))
273273
return it;
274274
return Items.end();
275275
}

src/xrEngine/LightAnimLibrary.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
class ENGINE_API CLAItem
1111
{
1212
public:
13-
shared_str cName;
13+
xr_string cName;
1414
float fFPS;
1515
using KeyMap = xr_map<int, u32>;
1616
KeyMap Keys;

0 commit comments

Comments
 (0)