summaryrefslogtreecommitdiff
path: root/core/input
diff options
context:
space:
mode:
authorMarcel Admiraal <madmiraal@users.noreply.github.com>2020-12-15 12:04:21 +0000
committerMarcel Admiraal <madmiraal@users.noreply.github.com>2020-12-28 10:39:56 +0000
commit5b937d493f0046543a77a0be7920ad39f1e5fc3c (patch)
tree975e0a7384bc6fc7cf5b73b9ddc1e8eef13579d8 /core/input
parent886571e0fc54914f161ab3f1ccf9bfe40411bc20 (diff)
Rename empty() to is_empty()
Diffstat (limited to 'core/input')
-rw-r--r--core/input/input.cpp2
-rw-r--r--core/input/input_event.cpp2
-rw-r--r--core/input/input_map.cpp4
3 files changed, 4 insertions, 4 deletions
diff --git a/core/input/input.cpp b/core/input/input.cpp
index 153656e44a..c49193562e 100644
--- a/core/input/input.cpp
+++ b/core/input/input.cpp
@@ -806,7 +806,7 @@ void Input::accumulate_input_event(const Ref<InputEvent> &p_event) {
parse_input_event(p_event);
return;
}
- if (!accumulated_events.empty() && accumulated_events.back()->get()->accumulate(p_event)) {
+ if (!accumulated_events.is_empty() && accumulated_events.back()->get()->accumulate(p_event)) {
return; //event was accumulated, exit
}
diff --git a/core/input/input_event.cpp b/core/input/input_event.cpp
index 82bfaa82a5..bdfa5dff5f 100644
--- a/core/input/input_event.cpp
+++ b/core/input/input_event.cpp
@@ -210,7 +210,7 @@ String InputEventWithModifiers::as_text() const {
mod_names.push_back(find_keycode_name(KEY_META));
}
- if (!mod_names.empty()) {
+ if (!mod_names.is_empty()) {
return String("+").join(mod_names);
} else {
return "";
diff --git a/core/input/input_map.cpp b/core/input/input_map.cpp
index 979809c7af..45e2ddc71d 100644
--- a/core/input/input_map.cpp
+++ b/core/input/input_map.cpp
@@ -71,7 +71,7 @@ void InputMap::erase_action(const StringName &p_action) {
Array InputMap::_get_actions() {
Array ret;
List<StringName> actions = get_actions();
- if (actions.empty()) {
+ if (actions.is_empty()) {
return ret;
}
@@ -84,7 +84,7 @@ Array InputMap::_get_actions() {
List<StringName> InputMap::get_actions() const {
List<StringName> actions = List<StringName>();
- if (input_map.empty()) {
+ if (input_map.is_empty()) {
return actions;
}