diff options
-rw-r--r-- | core/input_map.cpp | 18 | ||||
-rw-r--r-- | core/input_map.h | 2 | ||||
-rw-r--r-- | core/method_bind.h | 2 | ||||
-rw-r--r-- | core/object.cpp | 8 | ||||
-rw-r--r-- | doc/base/classes.xml | 2 | ||||
-rw-r--r-- | modules/gdscript/gd_script.cpp | 2 | ||||
-rw-r--r-- | scene/animation/animation_player.cpp | 2 | ||||
-rw-r--r-- | servers/visual/shader_language.cpp | 2 | ||||
-rw-r--r-- | tools/docdump/class_list.xml | 2 | ||||
-rw-r--r-- | tools/editor/project_export.cpp | 2 |
10 files changed, 30 insertions, 12 deletions
diff --git a/core/input_map.cpp b/core/input_map.cpp index 83b1e757da..1196c0c863 100644 --- a/core/input_map.cpp +++ b/core/input_map.cpp @@ -42,7 +42,7 @@ void InputMap::_bind_methods() { ObjectTypeDB::bind_method(_MD("action_add_event","action","event"),&InputMap::action_add_event); ObjectTypeDB::bind_method(_MD("action_has_event","action","event"),&InputMap::action_has_event); ObjectTypeDB::bind_method(_MD("action_erase_event","action","event"),&InputMap::action_erase_event); - ObjectTypeDB::bind_method(_MD("get_action_list","action"),&InputMap::get_action_list); + ObjectTypeDB::bind_method(_MD("get_action_list","action"),&InputMap::_get_action_list); ObjectTypeDB::bind_method(_MD("event_is_action","event","action"),&InputMap::event_is_action); ObjectTypeDB::bind_method(_MD("load_from_globals"),&InputMap::load_from_globals); @@ -162,6 +162,22 @@ void InputMap::action_erase_event(const StringName& p_action,const InputEvent& p } + +Array InputMap::_get_action_list(const StringName& p_action) { + + Array ret; + const List<InputEvent> *al = get_action_list(p_action); + if (al) { + for(List<InputEvent>::Element *E=al->front();E;E=E->next()) { + + ret.push_back(E->get());; + } + } + + return ret; + +} + const List<InputEvent> *InputMap::get_action_list(const StringName& p_action) { const Map<StringName, Action>::Element *E=input_map.find(p_action); diff --git a/core/input_map.h b/core/input_map.h index 875a39555f..c5b21b1457 100644 --- a/core/input_map.h +++ b/core/input_map.h @@ -46,6 +46,8 @@ class InputMap : public Object { List<InputEvent>::Element *_find_event(List<InputEvent> &p_list,const InputEvent& p_event) const; + Array _get_action_list(const StringName& p_action); + protected: static void _bind_methods(); diff --git a/core/method_bind.h b/core/method_bind.h index 49c64bd11c..85c1084f80 100644 --- a/core/method_bind.h +++ b/core/method_bind.h @@ -298,7 +298,7 @@ MethodBind* create_native_method_bind( Variant (T::*p_method)(const Variant**,in // tale of an amazing hack.. // -// if you declare an unexisting class.. +// if you declare an nonexistent class.. class __UnexistingClass; diff --git a/core/object.cpp b/core/object.cpp index c1904d05d7..1a51e79a9f 100644 --- a/core/object.cpp +++ b/core/object.cpp @@ -1319,7 +1319,7 @@ Error Object::connect(const StringName& p_signal, Object *p_to_object, const Str if (!s) { bool signal_is_valid = ObjectTypeDB::has_signal(get_type_name(),p_signal); if (!signal_is_valid) { - ERR_EXPLAIN("Attempt to connect to unexisting signal: "+p_signal); + ERR_EXPLAIN("Attempt to connect to nonexistent signal: "+p_signal); ERR_FAIL_COND_V(!signal_is_valid,ERR_INVALID_PARAMETER); } signal_map[p_signal]=Signal(); @@ -1356,7 +1356,7 @@ bool Object::is_connected(const StringName& p_signal, Object *p_to_object, const bool signal_is_valid = ObjectTypeDB::has_signal(get_type_name(),p_signal); if (signal_is_valid) return false; - ERR_EXPLAIN("Unexisting signal: "+p_signal); + ERR_EXPLAIN("Nonexistent signal: "+p_signal); ERR_FAIL_COND_V(!s,false); } @@ -1373,7 +1373,7 @@ void Object::disconnect(const StringName& p_signal, Object *p_to_object, const S ERR_FAIL_NULL(p_to_object); Signal *s = signal_map.getptr(p_signal); if (!s) { - ERR_EXPLAIN("Unexisting signal: "+p_signal); + ERR_EXPLAIN("Nonexistent signal: "+p_signal); ERR_FAIL_COND(!s); } if (s->lock>0) { @@ -1384,7 +1384,7 @@ void Object::disconnect(const StringName& p_signal, Object *p_to_object, const S Signal::Target target(p_to_object->get_instance_ID(),p_to_method); if (!s->slot_map.has(target)) { - ERR_EXPLAIN("Disconnecting unexisting signal '"+p_signal+"', slot: "+itos(target._id)+":"+target.method); + ERR_EXPLAIN("Disconnecting nonexistent signal '"+p_signal+"', slot: "+itos(target._id)+":"+target.method); ERR_FAIL(); } int prev = p_to_object->connections.size(); diff --git a/doc/base/classes.xml b/doc/base/classes.xml index 901bfa1253..57ca460979 100644 --- a/doc/base/classes.xml +++ b/doc/base/classes.xml @@ -9655,7 +9655,7 @@ </signals> <constants> <constant name="MODE_OPEN_FILE" value="0"> - Editor will not allow to select unexisting files. + Editor will not allow to select nonexistent files. </constant> <constant name="MODE_OPEN_FILES" value="1"> </constant> diff --git a/modules/gdscript/gd_script.cpp b/modules/gdscript/gd_script.cpp index c9b00f49ac..ceca1ff2b9 100644 --- a/modules/gdscript/gd_script.cpp +++ b/modules/gdscript/gd_script.cpp @@ -140,7 +140,7 @@ String GDFunction::_get_call_error(const Variant::CallError& p_err, const String } else if (p_err.error==Variant::CallError::CALL_ERROR_TOO_FEW_ARGUMENTS) { err_text="Invalid call to "+p_where+". Expected "+itos(p_err.argument)+" arguments."; } else if (p_err.error==Variant::CallError::CALL_ERROR_INVALID_METHOD) { - err_text="Invalid call. Unexisting "+p_where+"."; + err_text="Invalid call. Nonexistent "+p_where+"."; } else if (p_err.error==Variant::CallError::CALL_ERROR_INSTANCE_IS_NULL) { err_text="Attempt to call "+p_where+" on a null instance."; } else { diff --git a/scene/animation/animation_player.cpp b/scene/animation/animation_player.cpp index 51afe6b3fc..4949b33c47 100644 --- a/scene/animation/animation_player.cpp +++ b/scene/animation/animation_player.cpp @@ -295,7 +295,7 @@ void AnimationPlayer::_generate_node_caches(AnimationData* p_anim) { p_anim->node_cache[i]->bone_idx=p_anim->node_cache[i]->skeleton->find_bone(bone_name); if (p_anim->node_cache[i]->bone_idx<0) { - // broken track (unexisting bone) + // broken track (nonexistent bone) p_anim->node_cache[i]->skeleton=NULL; p_anim->node_cache[i]->spatial=NULL; printf("bone is %ls\n", String(bone_name).c_str()); diff --git a/servers/visual/shader_language.cpp b/servers/visual/shader_language.cpp index 77b7ddbc93..ea56306241 100644 --- a/servers/visual/shader_language.cpp +++ b/servers/visual/shader_language.cpp @@ -1714,7 +1714,7 @@ Error ShaderLanguage::parse_expression(Parser& parser,Node *p_parent,Node **r_ex if (!existing) { - parser.set_error("Unexisting identifier in expression: "+identifier); + parser.set_error("Nonexistent identifier in expression: "+identifier); return ERR_PARSE_ERROR; } diff --git a/tools/docdump/class_list.xml b/tools/docdump/class_list.xml index ab33cef7d7..3d07f84177 100644 --- a/tools/docdump/class_list.xml +++ b/tools/docdump/class_list.xml @@ -3140,7 +3140,7 @@ <constant name="MODE_OPEN_DIR" value="1"> </constant> <constant name="MODE_OPEN_FILE" value="0"> - Editor will not allow to select unexisting files. + Editor will not allow to select nonexistent files. </constant> <constant name="MODE_SAVE_FILE" value="2"> Editor will warn when a file exists. diff --git a/tools/editor/project_export.cpp b/tools/editor/project_export.cpp index 374dda852b..ab27ac7fa9 100644 --- a/tools/editor/project_export.cpp +++ b/tools/editor/project_export.cpp @@ -1653,7 +1653,7 @@ Error ProjectExport::export_project(const String& p_preset) { if (saver.is_null()) { memdelete(d); - ERR_EXPLAIN("Preset '"+preset+"' references unexisting saver: "+type); + ERR_EXPLAIN("Preset '"+preset+"' references nonexistent saver: "+type); ERR_FAIL_COND_V(saver.is_null(),ERR_INVALID_DATA); } |