diff options
author | George Marques <george@gmarqu.es> | 2020-06-11 19:31:28 -0300 |
---|---|---|
committer | George Marques <george@gmarqu.es> | 2020-07-20 11:38:40 -0300 |
commit | 95c0909290508620bd330c2b4f7120c92cd73f0c (patch) | |
tree | d2189483464b272e02556dbe253f0c0556af2a91 /editor/plugins/script_text_editor.cpp | |
parent | 9a76ab8b6a787edd6e09be4b7833eaf8703cbff7 (diff) |
Add warning checks in GDScript analyzer
Reenable checking those when validating code.
Diffstat (limited to 'editor/plugins/script_text_editor.cpp')
-rw-r--r-- | editor/plugins/script_text_editor.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/editor/plugins/script_text_editor.cpp b/editor/plugins/script_text_editor.cpp index 1e03d9dfab..f4fdf8ccb0 100644 --- a/editor/plugins/script_text_editor.cpp +++ b/editor/plugins/script_text_editor.cpp @@ -494,7 +494,7 @@ void ScriptTextEditor::_validate_script() { ScriptLanguage::Warning w = E->get(); Dictionary ignore_meta; - ignore_meta["line"] = w.line; + ignore_meta["line"] = w.start_line; ignore_meta["code"] = w.string_code.to_lower(); warnings_panel->push_cell(); warnings_panel->push_meta(ignore_meta); @@ -506,9 +506,9 @@ void ScriptTextEditor::_validate_script() { warnings_panel->pop(); // Cell. warnings_panel->push_cell(); - warnings_panel->push_meta(w.line - 1); + warnings_panel->push_meta(w.start_line - 1); warnings_panel->push_color(warnings_panel->get_theme_color("warning_color", "Editor")); - warnings_panel->add_text(TTR("Line") + " " + itos(w.line)); + warnings_panel->add_text(TTR("Line") + " " + itos(w.start_line)); warnings_panel->add_text(" (" + w.string_code + "):"); warnings_panel->pop(); // Color. warnings_panel->pop(); // Meta goto. |