Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
beat
beat.editor
Commits
523bf7cb
Commit
523bf7cb
authored
Jun 19, 2020
by
Samuel GAIST
Browse files
[widgets][algorithmeditor] Ensure generated name is schema compliant
parent
fad71d8d
Changes
1
Hide whitespace changes
Inline
Side-by-side
beat/editor/widgets/algorithmeditor.py
View file @
523bf7cb
...
@@ -691,13 +691,13 @@ class AlgorithmEditor(AbstractAssetEditor):
...
@@ -691,13 +691,13 @@ class AlgorithmEditor(AbstractAssetEditor):
self
.
add_result_button
.
clicked
.
connect
(
self
.
__onAddResult
)
self
.
add_result_button
.
clicked
.
connect
(
self
.
__onAddResult
)
def
__get_free_name
(
self
,
widget_list
):
def
__get_free_name
(
self
,
widget_list
):
name
=
"Change
Me"
name
=
"Change
_
Me"
i
=
1
i
=
1
restart
=
True
restart
=
True
while
restart
:
while
restart
:
for
widget
in
widget_list
:
for
widget
in
widget_list
:
if
widget
.
name
()
==
name
:
if
widget
.
name
()
==
name
:
name
=
f
"Change
Me
{
i
}
"
name
=
f
"Change
_
Me
_
{
i
}
"
i
+=
1
i
+=
1
break
break
else
:
else
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment