summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/script_debugger_remote.cpp14
-rw-r--r--doc/classes/AudioServer.xml28
-rw-r--r--doc/classes/Basis.xml8
-rw-r--r--doc/classes/Camera2D.xml4
-rw-r--r--doc/classes/Control.xml2
-rw-r--r--doc/classes/EditorInterface.xml16
-rw-r--r--doc/classes/EditorPlugin.xml4
-rw-r--r--doc/classes/Image.xml12
-rw-r--r--doc/classes/VisualShaderNodeVectorScalarMix.xml13
-rw-r--r--editor/editor_spin_slider.cpp5
-rw-r--r--editor/plugins/script_editor_plugin.cpp1
-rw-r--r--editor/plugins/script_text_editor.cpp1
-rw-r--r--editor/plugins/text_editor.cpp14
-rw-r--r--editor/plugins/text_editor.h1
-rw-r--r--modules/gridmap/grid_map_editor_plugin.cpp8
-rw-r--r--modules/mono/build_scripts/mono_configure.py6
-rw-r--r--platform/SCsub2
-rw-r--r--platform/javascript/detect.py3
-rw-r--r--scene/gui/spin_box.cpp4
19 files changed, 106 insertions, 40 deletions
diff --git a/core/script_debugger_remote.cpp b/core/script_debugger_remote.cpp
index 5f01e043c4..6dd9054aaa 100644
--- a/core/script_debugger_remote.cpp
+++ b/core/script_debugger_remote.cpp
@@ -601,9 +601,19 @@ void ScriptDebuggerRemote::_send_object_id(ObjectID p_id) {
}
}
}
+
if (Node *node = Object::cast_to<Node>(obj)) {
- PropertyInfo pi(Variant::NODE_PATH, String("Node/path"));
- properties.push_front(PropertyDesc(pi, node->get_path()));
+ // in some cases node will not be in tree here
+ // for instance where it created as variable and not yet added to tree
+ // in such cases we can't ask for it's path
+ if (node->is_inside_tree()) {
+ PropertyInfo pi(Variant::NODE_PATH, String("Node/path"));
+ properties.push_front(PropertyDesc(pi, node->get_path()));
+ } else {
+ PropertyInfo pi(Variant::STRING, String("Node/path"));
+ properties.push_front(PropertyDesc(pi, "[Orphan]"));
+ }
+
} else if (Resource *res = Object::cast_to<Resource>(obj)) {
if (Script *s = Object::cast_to<Script>(res)) {
Map<StringName, Variant> constants;
diff --git a/doc/classes/AudioServer.xml b/doc/classes/AudioServer.xml
index 6f82b103db..2d3ceebed5 100644
--- a/doc/classes/AudioServer.xml
+++ b/doc/classes/AudioServer.xml
@@ -32,12 +32,6 @@
Adds an [AudioEffect] effect to the bus [code]bus_idx[/code] at [code]at_position[/code].
</description>
</method>
- <method name="capture_get_device">
- <return type="String">
- </return>
- <description>
- </description>
- </method>
<method name="capture_get_device_list">
<return type="Array">
</return>
@@ -45,14 +39,6 @@
Returns the names of all audio input devices detected on the system.
</description>
</method>
- <method name="capture_set_device">
- <return type="void">
- </return>
- <argument index="0" name="name" type="String">
- </argument>
- <description>
- </description>
- </method>
<method name="capture_start">
<return type="int" enum="Error">
</return>
@@ -423,17 +409,25 @@
<member name="bus_count" type="int" setter="set_bus_count" getter="get_bus_count" default="1">
Number of available audio buses.
</member>
+ <member name="capture_device" type="String" setter="capture_set_device" getter="capture_get_device" default="&quot;&quot;">
+ Name of the current device for audio input (see [method capture_get_device_list]).
+ </member>
<member name="device" type="String" setter="set_device" getter="get_device" default="&quot;Default&quot;">
Name of the current device for audio output (see [method get_device_list]).
</member>
- <member name="capture_device" type="String" setter="capture_set_device" getter="capture_get_device" default="&quot;Default&quot;">
- Name of the current device for audio input (see [method capture_get_device_list]).
- </member>
<member name="global_rate_scale" type="float" setter="set_global_rate_scale" getter="get_global_rate_scale" default="1.0">
Scales the rate at which audio is played (i.e. setting it to [code]0.5[/code] will make the audio be played twice as fast).
</member>
</members>
<signals>
+ <signal name="audio_mix_callback">
+ <description>
+ </description>
+ </signal>
+ <signal name="audio_update_callback">
+ <description>
+ </description>
+ </signal>
<signal name="bus_layout_changed">
<description>
Emitted when the [AudioBusLayout] changes.
diff --git a/doc/classes/Basis.xml b/doc/classes/Basis.xml
index 4d5c76a75c..df9438e695 100644
--- a/doc/classes/Basis.xml
+++ b/doc/classes/Basis.xml
@@ -208,5 +208,13 @@
</member>
</members>
<constants>
+ <constant name="IDENTITY" value="Basis( 1, 0, 0, 0, 1, 0, 0, 0, 1 )">
+ </constant>
+ <constant name="FLIP_X" value="Basis( -1, 0, 0, 0, 1, 0, 0, 0, 1 )">
+ </constant>
+ <constant name="FLIP_Y" value="Basis( 1, 0, 0, 0, -1, 0, 0, 0, 1 )">
+ </constant>
+ <constant name="FLIP_Z" value="Basis( 1, 0, 0, 0, 1, 0, 0, 0, -1 )">
+ </constant>
</constants>
</class>
diff --git a/doc/classes/Camera2D.xml b/doc/classes/Camera2D.xml
index f524a02934..16fb483249 100644
--- a/doc/classes/Camera2D.xml
+++ b/doc/classes/Camera2D.xml
@@ -110,7 +110,7 @@
<member name="drag_margin_bottom" type="float" setter="set_drag_margin" getter="get_drag_margin" default="0.2">
Bottom margin needed to drag the camera. A value of [code]1[/code] makes the camera move only when reaching the edge of the screen.
</member>
- <member name="drag_margin_h_enabled" type="bool" setter="set_h_drag_enabled" getter="is_h_drag_enabled" default="true">
+ <member name="drag_margin_h_enabled" type="bool" setter="set_h_drag_enabled" getter="is_h_drag_enabled" default="false">
If [code]true[/code], the camera only moves when reaching the horizontal drag margins. If [code]false[/code], the camera moves horizontally regardless of margins.
</member>
<member name="drag_margin_left" type="float" setter="set_drag_margin" getter="get_drag_margin" default="0.2">
@@ -122,7 +122,7 @@
<member name="drag_margin_top" type="float" setter="set_drag_margin" getter="get_drag_margin" default="0.2">
Top margin needed to drag the camera. A value of [code]1[/code] makes the camera move only when reaching the edge of the screen.
</member>
- <member name="drag_margin_v_enabled" type="bool" setter="set_v_drag_enabled" getter="is_v_drag_enabled" default="true">
+ <member name="drag_margin_v_enabled" type="bool" setter="set_v_drag_enabled" getter="is_v_drag_enabled" default="false">
If [code]true[/code], the camera only moves when reaching the vertical drag margins. If [code]false[/code], the camera moves vertically regardless of margins.
</member>
<member name="editor_draw_drag_margin" type="bool" setter="set_margin_drawing_enabled" getter="is_margin_drawing_enabled" default="false">
diff --git a/doc/classes/Control.xml b/doc/classes/Control.xml
index 6c3cf66c20..acceffb3bf 100644
--- a/doc/classes/Control.xml
+++ b/doc/classes/Control.xml
@@ -229,7 +229,7 @@
[codeblock]
func _ready():
modulate = get_color("font_color", "Button") #get the color defined for button fonts
- [/codeblock]
+ [/codeblock]
</description>
</method>
<method name="get_combined_minimum_size" qualifiers="const">
diff --git a/doc/classes/EditorInterface.xml b/doc/classes/EditorInterface.xml
index d55e810c9e..4f7a6d89a9 100644
--- a/doc/classes/EditorInterface.xml
+++ b/doc/classes/EditorInterface.xml
@@ -169,6 +169,22 @@
Selects the file, with the path provided by [code]file[/code], in the FileSystem dock.
</description>
</method>
+ <method name="set_distraction_free_mode">
+ <return type="void">
+ </return>
+ <argument index="0" name="enter" type="bool">
+ </argument>
+ <description>
+ </description>
+ </method>
+ <method name="set_main_screen_editor">
+ <return type="void">
+ </return>
+ <argument index="0" name="name" type="String">
+ </argument>
+ <description>
+ </description>
+ </method>
<method name="set_plugin_enabled">
<return type="void">
</return>
diff --git a/doc/classes/EditorPlugin.xml b/doc/classes/EditorPlugin.xml
index fddc5e9d36..89e2f0580b 100644
--- a/doc/classes/EditorPlugin.xml
+++ b/doc/classes/EditorPlugin.xml
@@ -128,7 +128,7 @@
<argument index="3" name="ud" type="Variant" default="null">
</argument>
<description>
- Adds a custom menu to [b]Project &gt; Tools[/b] as [code]name[/code] that calls [code]callback[/code] on an instance of [code]handler[/code] with a parameter [code]ud[/code] when user activates it.
+ Adds a custom menu item to [b]Project &gt; Tools[/b] as [code]name[/code] that calls [code]callback[/code] on an instance of [code]handler[/code] with a parameter [code]ud[/code] when user activates it.
</description>
</method>
<method name="add_tool_submenu_item">
@@ -139,7 +139,7 @@
<argument index="1" name="submenu" type="Object">
</argument>
<description>
- Like [method add_tool_menu_item] but adds the [code]submenu[/code] item inside the [code]name[/code] menu.
+ Adds a custom submenu under [b]Project &gt; Tools &gt;[/b] [code]name[/code]. [code]submenu[/code] should be an object of class [PopupMenu]. This submenu should be cleaned up using [code]remove_tool_menu_item(name)[/code].
</description>
</method>
<method name="apply_changes" qualifiers="virtual">
diff --git a/doc/classes/Image.xml b/doc/classes/Image.xml
index a4df0d5c19..10be66feb8 100644
--- a/doc/classes/Image.xml
+++ b/doc/classes/Image.xml
@@ -406,24 +406,24 @@
<description>
</description>
</method>
- <method name="save_png" qualifiers="const">
+ <method name="save_exr" qualifiers="const">
<return type="int" enum="Error">
</return>
<argument index="0" name="path" type="String">
</argument>
+ <argument index="1" name="grayscale" type="bool" default="false">
+ </argument>
<description>
- Saves the image as a PNG file to [code]path[/code].
+ Saves the image as an EXR file to [code]path[/code]. If grayscale is true and the image has only one channel, it will be saved explicitely as monochrome rather than one red channel. This function will return [constant ERR_UNAVAILABLE] if Godot was compiled without the TinyEXR module.
</description>
</method>
- <method name="save_exr" qualifiers="const">
+ <method name="save_png" qualifiers="const">
<return type="int" enum="Error">
</return>
<argument index="0" name="path" type="String">
</argument>
- <argument index="1" name="grayscale" type="bool" default="false">
- </argument>
<description>
- Saves the image as an EXR file to [code]path[/code]. If grayscale is true and the image has only one channel, it will be saved explicitely as monochrome rather than one red channel. This function will return [constant ERR_UNAVAILABLE] if Godot was compiled without the TinyEXR module.
+ Saves the image as a PNG file to [code]path[/code].
</description>
</method>
<method name="set_pixel">
diff --git a/doc/classes/VisualShaderNodeVectorScalarMix.xml b/doc/classes/VisualShaderNodeVectorScalarMix.xml
new file mode 100644
index 0000000000..d83c2e7d44
--- /dev/null
+++ b/doc/classes/VisualShaderNodeVectorScalarMix.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="VisualShaderNodeVectorScalarMix" inherits="VisualShaderNode" category="Core" version="3.2">
+ <brief_description>
+ </brief_description>
+ <description>
+ </description>
+ <tutorials>
+ </tutorials>
+ <methods>
+ </methods>
+ <constants>
+ </constants>
+</class>
diff --git a/editor/editor_spin_slider.cpp b/editor/editor_spin_slider.cpp
index 9966394025..379b8a2980 100644
--- a/editor/editor_spin_slider.cpp
+++ b/editor/editor_spin_slider.cpp
@@ -347,6 +347,11 @@ void EditorSpinSlider::_value_input_closed() {
//focus_exited signal
void EditorSpinSlider::_value_focus_exited() {
+
+ // discontinue because the focus_exit was caused by right-click context menu
+ if (value_input->get_menu()->is_visible())
+ return;
+
_evaluate_input_text();
// focus is not on the same element after the vlalue_input was exited
// -> focus is on next element
diff --git a/editor/plugins/script_editor_plugin.cpp b/editor/plugins/script_editor_plugin.cpp
index ec391186c3..1072c3cad1 100644
--- a/editor/plugins/script_editor_plugin.cpp
+++ b/editor/plugins/script_editor_plugin.cpp
@@ -1072,6 +1072,7 @@ void ScriptEditor::_menu_option(int p_option) {
save_all_scripts();
} break;
case SEARCH_IN_FILES: {
+
_on_find_in_files_requested("");
} break;
case SEARCH_HELP: {
diff --git a/editor/plugins/script_text_editor.cpp b/editor/plugins/script_text_editor.cpp
index 98e0edd581..87248c53b1 100644
--- a/editor/plugins/script_text_editor.cpp
+++ b/editor/plugins/script_text_editor.cpp
@@ -1197,7 +1197,6 @@ void ScriptTextEditor::_edit_option(int p_op) {
// Yep, because it doesn't make sense to instance this dialog for every single script open...
// So this will be delegated to the ScriptEditor.
emit_signal("search_in_files_requested", selected_text);
-
} break;
case SEARCH_LOCATE_FUNCTION: {
diff --git a/editor/plugins/text_editor.cpp b/editor/plugins/text_editor.cpp
index eb0794ba77..89e419ede8 100644
--- a/editor/plugins/text_editor.cpp
+++ b/editor/plugins/text_editor.cpp
@@ -482,6 +482,14 @@ void TextEditor::_edit_option(int p_op) {
code_editor->get_find_replace_bar()->popup_replace();
} break;
+ case SEARCH_IN_FILES: {
+
+ String selected_text = code_editor->get_text_edit()->get_selection_text();
+
+ // Yep, because it doesn't make sense to instance this dialog for every single script open...
+ // So this will be delegated to the ScriptEditor.
+ emit_signal("search_in_files_requested", selected_text);
+ } break;
case SEARCH_GOTO_LINE: {
goto_line_dialog->popup_find_line(tx);
@@ -558,7 +566,7 @@ void TextEditor::_text_edit_gui_input(const Ref<InputEvent> &ev) {
int to_column = tx->get_selection_to_column();
if (row < from_line || row > to_line || (row == from_line && col < from_column) || (row == to_line && col > to_column)) {
- // Right click is outside the selected text
+ // Right click is outside the selected text.
tx->deselect();
}
}
@@ -636,13 +644,15 @@ TextEditor::TextEditor() {
search_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/find_next"), SEARCH_FIND_NEXT);
search_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/find_previous"), SEARCH_FIND_PREV);
search_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/replace"), SEARCH_REPLACE);
+ search_menu->get_popup()->add_separator();
+ search_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/find_in_files"), SEARCH_IN_FILES);
edit_menu = memnew(MenuButton);
+ edit_hb->add_child(edit_menu);
edit_menu->set_text(TTR("Edit"));
edit_menu->set_switch_on_hover(true);
edit_menu->get_popup()->connect("id_pressed", this, "_edit_option");
- edit_hb->add_child(edit_menu);
edit_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/undo"), EDIT_UNDO);
edit_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/redo"), EDIT_REDO);
edit_menu->get_popup()->add_separator();
diff --git a/editor/plugins/text_editor.h b/editor/plugins/text_editor.h
index c69e1672c5..c8b49a61e0 100644
--- a/editor/plugins/text_editor.h
+++ b/editor/plugins/text_editor.h
@@ -87,6 +87,7 @@ private:
SEARCH_FIND_NEXT,
SEARCH_FIND_PREV,
SEARCH_REPLACE,
+ SEARCH_IN_FILES,
SEARCH_GOTO_LINE,
BOOKMARK_TOGGLE,
BOOKMARK_GOTO_NEXT,
diff --git a/modules/gridmap/grid_map_editor_plugin.cpp b/modules/gridmap/grid_map_editor_plugin.cpp
index 5a21833ffa..9712f2b5e7 100644
--- a/modules/gridmap/grid_map_editor_plugin.cpp
+++ b/modules/gridmap/grid_map_editor_plugin.cpp
@@ -863,19 +863,21 @@ void GridMapEditor::_icon_size_changed(float p_value) {
void GridMapEditor::update_palette() {
int selected = mesh_library_palette->get_current();
+ float min_size = EDITOR_DEF("editors/grid_map/preview_size", 64);
+ min_size *= EDSCALE;
+
mesh_library_palette->clear();
if (display_mode == DISPLAY_THUMBNAIL) {
mesh_library_palette->set_max_columns(0);
mesh_library_palette->set_icon_mode(ItemList::ICON_MODE_TOP);
+ mesh_library_palette->set_fixed_column_width(min_size * MAX(size_slider->get_value(), 1.5));
} else if (display_mode == DISPLAY_LIST) {
mesh_library_palette->set_max_columns(1);
mesh_library_palette->set_icon_mode(ItemList::ICON_MODE_LEFT);
+ mesh_library_palette->set_fixed_column_width(0);
}
- float min_size = EDITOR_DEF("editors/grid_map/preview_size", 64);
- min_size *= EDSCALE;
mesh_library_palette->set_fixed_icon_size(Size2(min_size, min_size));
- mesh_library_palette->set_fixed_column_width(min_size * MAX(size_slider->get_value(), 1.5));
mesh_library_palette->set_max_text_lines(2);
Ref<MeshLibrary> mesh_library = node->get_mesh_library();
diff --git a/modules/mono/build_scripts/mono_configure.py b/modules/mono/build_scripts/mono_configure.py
index 9f0eb58896..f751719531 100644
--- a/modules/mono/build_scripts/mono_configure.py
+++ b/modules/mono/build_scripts/mono_configure.py
@@ -113,8 +113,8 @@ def configure(env, env_mono):
else:
env.Append(LINKFLAGS=os.path.join(mono_lib_path, mono_static_lib_name + lib_suffix))
- env.Append(LIBS='psapi')
- env.Append(LIBS='version')
+ env.Append(LIBS=['psapi'])
+ env.Append(LIBS=['version'])
else:
mono_lib_name = find_file_in_dir(mono_lib_path, mono_lib_names, extension='.lib')
@@ -124,7 +124,7 @@ def configure(env, env_mono):
if env.msvc:
env.Append(LINKFLAGS=mono_lib_name + Environment()['LIBSUFFIX'])
else:
- env.Append(LIBS=mono_lib_name)
+ env.Append(LIBS=[mono_lib_name])
mono_bin_path = os.path.join(mono_root, 'bin')
diff --git a/platform/SCsub b/platform/SCsub
index 20c89ae8c6..38bab59d74 100644
--- a/platform/SCsub
+++ b/platform/SCsub
@@ -29,4 +29,4 @@ with open_utf8('register_platform_apis.gen.cpp', 'w') as f:
env.add_source_files(env.platform_sources, 'register_platform_apis.gen.cpp')
lib = env.add_library('platform', env.platform_sources)
-env.Prepend(LIBS=lib)
+env.Prepend(LIBS=[lib])
diff --git a/platform/javascript/detect.py b/platform/javascript/detect.py
index ac43392700..a0d6ac9214 100644
--- a/platform/javascript/detect.py
+++ b/platform/javascript/detect.py
@@ -141,3 +141,6 @@ def configure(env):
# TODO: Reevaluate usage of this setting now that engine.js manages engine runtime.
env.Append(LINKFLAGS=['-s', 'NO_EXIT_RUNTIME=1'])
+
+ #adding flag due to issue with emscripten 1.38.41 callMain method https://github.com/emscripten-core/emscripten/blob/incoming/ChangeLog.md#v13841-08072019
+ env.Append(LINKFLAGS=['-s', 'EXTRA_EXPORTED_RUNTIME_METHODS=["callMain"]'])
diff --git a/scene/gui/spin_box.cpp b/scene/gui/spin_box.cpp
index db277d3705..6ada0cba97 100644
--- a/scene/gui/spin_box.cpp
+++ b/scene/gui/spin_box.cpp
@@ -170,6 +170,10 @@ void SpinBox::_gui_input(const Ref<InputEvent> &p_event) {
void SpinBox::_line_edit_focus_exit() {
+ // discontinue because the focus_exit was caused by right-click context menu
+ if (line_edit->get_menu()->is_visible())
+ return;
+
_text_entered(line_edit->get_text());
}