Add one method-const qualifier to TreeSearchPanel
This commit is contained in:
parent
585d9663d6
commit
f7d546fc3c
|
@ -511,7 +511,7 @@ TreeSearchPanel::TreeSearchPanel() {
|
|||
set_visible(false);
|
||||
}
|
||||
|
||||
TreeSearch::TreeSearchMode TreeSearchPanel::get_search_mode() {
|
||||
TreeSearch::TreeSearchMode TreeSearchPanel::get_search_mode() const{
|
||||
if (!check_button_filter_highlight || !check_button_filter_highlight->is_pressed()) {
|
||||
return TreeSearch::TreeSearchMode::HIGHLIGHT;
|
||||
}
|
||||
|
|
|
@ -56,7 +56,7 @@ private:
|
|||
// linearized ordering of tree items.
|
||||
Vector<TreeItem *> ordered_tree_items;
|
||||
// entires that match the search mask.
|
||||
// TODO: Decide if this can be removed. It can be implicitly infered from number_matches.
|
||||
// TODO: Decide if this can be removed. It can be implicitly inferred from number_matches.
|
||||
Vector<TreeItem *> matching_entries;
|
||||
// number of descendant matches for each tree item.
|
||||
HashMap<TreeItem *, int> number_matches;
|
||||
|
@ -90,7 +90,7 @@ private:
|
|||
void _select_first_match();
|
||||
void _select_next_match();
|
||||
|
||||
// TODO: make p_vec `const` once Vector::bsearch is const. See: https://github.com/godotengine/godot/pull/90341
|
||||
// TODO: make p_vec ref `const` once Vector::bsearch is const. See: https://github.com/godotengine/godot/pull/90341
|
||||
template <typename T>
|
||||
bool _vector_has_bsearch(Vector<T *> &p_vec, T *element) const;
|
||||
|
||||
|
@ -130,7 +130,7 @@ protected:
|
|||
static void _bind_methods();
|
||||
|
||||
public:
|
||||
TreeSearch::TreeSearchMode get_search_mode();
|
||||
TreeSearch::TreeSearchMode get_search_mode() const;
|
||||
String get_text() const;
|
||||
void show_and_focus();
|
||||
TreeSearchPanel();
|
||||
|
|
Loading…
Reference in New Issue