Skip to content

Commit 9b6a805

Browse files
committed
fix gcc build error
1 parent 1075825 commit 9b6a805

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

LAppModelWrapper.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ static PyObject* PyLAppModel_SetRandomExpression(PyLAppModelObject* self, PyObje
250250

251251
self->fadeout = fadeout;
252252

253-
std::string& expId = self->model->SetRandomExpression();
253+
const std::string expId = self->model->SetRandomExpression();
254254

255255
PyObject* pyExpIdStr = Py_BuildValue("s", expId.c_str());
256256

@@ -261,8 +261,8 @@ static PyObject* PyLAppModel_SetRandomExpression(PyLAppModelObject* self, PyObje
261261
}
262262
else
263263
{
264-
self->lastExpression = std::string(expId);
265-
Info("set default expression: %s", expId);
264+
self->lastExpression = expId;
265+
Info("set default expression: %s", expId.c_str());
266266
}
267267

268268
return pyExpIdStr;

package/test_getters.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,18 @@ def main():
3838

3939
expIds = model.GetExpressionIds()
4040
motionGroups = model.GetMotionGroups()
41+
paramIds = model.GetParamIds()
4142

4243
print(expIds)
4344

4445
print("===")
4546

4647
print(motionGroups)
4748

49+
print("===")
50+
51+
print(paramIds)
52+
4853
while True:
4954
for event in pygame.event.get():
5055
if event.type == pygame.QUIT:
@@ -55,6 +60,7 @@ def main():
5560
break
5661

5762
model.Update()
63+
paramIds = model.GetParamIds()
5864
expIds = model.GetExpressionIds()
5965
motionGroups = model.GetMotionGroups()
6066

0 commit comments

Comments
 (0)