Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
godot
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
community
godot
Commits
22f0de8a
Commit
22f0de8a
authored
Jun 11, 2020
by
Tomasz Chabora
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix custom types in node list search
parent
cbcc0eac
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
create_dialog.cpp
editor/create_dialog.cpp
+5
-3
No files found.
editor/create_dialog.cpp
View file @
22f0de8a
...
...
@@ -347,20 +347,22 @@ void CreateDialog::_update_search() {
}
else
{
bool
found
=
false
;
String
type2
=
type
;
bool
cpp_type2
=
cpp_type
;
if
(
!
cpp_type
&&
!
search_loaded_scripts
.
has
(
type
))
{
search_loaded_scripts
[
type
]
=
ed
.
script_class_load_script
(
type
);
}
while
(
type2
!=
""
&&
(
cpp_type
?
ClassDB
::
is_parent_class
(
type2
,
base_type
)
:
ed
.
script_class_is_parent
(
type2
,
base_type
))
&&
type2
!=
base_type
)
{
while
(
type2
!=
""
&&
(
cpp_type
2
?
ClassDB
::
is_parent_class
(
type2
,
base_type
)
:
ed
.
script_class_is_parent
(
type2
,
base_type
))
&&
type2
!=
base_type
)
{
if
(
search_box
->
get_text
().
is_subsequence_ofi
(
type2
))
{
found
=
true
;
break
;
}
type2
=
cpp_type
?
ClassDB
::
get_parent_class
(
type2
)
:
ed
.
script_class_get_base
(
type2
);
type2
=
cpp_type2
?
ClassDB
::
get_parent_class
(
type2
)
:
ed
.
script_class_get_base
(
type2
);
cpp_type2
=
cpp_type2
||
ClassDB
::
class_exists
(
type2
);
// Built-in class can't inherit from custom type, so we can skip the check if it's already true.
if
(
!
cpp_type
&&
!
search_loaded_scripts
.
has
(
type2
))
{
if
(
!
cpp_type
2
&&
!
search_loaded_scripts
.
has
(
type2
))
{
search_loaded_scripts
[
type2
]
=
ed
.
script_class_load_script
(
type2
);
}
}
...
...
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