summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--editor/plugins/animation_player_editor_plugin.cpp4
-rw-r--r--editor/plugins/animation_player_editor_plugin.h1
-rw-r--r--editor/plugins/script_text_editor.cpp2
-rw-r--r--editor/plugins/shader_editor_plugin.cpp4
-rw-r--r--misc/scripts/sort-demos.sh29
-rw-r--r--modules/jsonrpc/jsonrpc.cpp10
-rw-r--r--scene/3d/camera.cpp6
-rw-r--r--scene/animation/animation_blend_tree.cpp4
8 files changed, 17 insertions, 43 deletions
diff --git a/editor/plugins/animation_player_editor_plugin.cpp b/editor/plugins/animation_player_editor_plugin.cpp
index 2d00324c84..60ef88d2e3 100644
--- a/editor/plugins/animation_player_editor_plugin.cpp
+++ b/editor/plugins/animation_player_editor_plugin.cpp
@@ -304,6 +304,7 @@ void AnimationPlayerEditor::_animation_selected(int p_which) {
AnimationPlayerEditor::singleton->get_track_editor()->update_keying();
EditorNode::get_singleton()->update_keying();
+ _animation_key_editor_seek(timeline_position, false);
}
void AnimationPlayerEditor::_animation_new() {
@@ -1072,6 +1073,8 @@ void AnimationPlayerEditor::_animation_key_editor_anim_len_changed(float p_len)
void AnimationPlayerEditor::_animation_key_editor_seek(float p_pos, bool p_drag) {
+ timeline_position = p_pos;
+
if (!is_visible_in_tree())
return;
if (!player)
@@ -1753,6 +1756,7 @@ AnimationPlayerEditor::AnimationPlayerEditor(EditorNode *p_editor, AnimationPlay
renaming = false;
last_active = false;
+ timeline_position = 0;
set_process_unhandled_key_input(true);
diff --git a/editor/plugins/animation_player_editor_plugin.h b/editor/plugins/animation_player_editor_plugin.h
index eed7344395..663ffd57f3 100644
--- a/editor/plugins/animation_player_editor_plugin.h
+++ b/editor/plugins/animation_player_editor_plugin.h
@@ -107,6 +107,7 @@ class AnimationPlayerEditor : public VBoxContainer {
UndoRedo *undo_redo;
Ref<Texture> autoplay_icon;
bool last_active;
+ float timeline_position;
EditorFileDialog *file;
AcceptDialog *accept;
diff --git a/editor/plugins/script_text_editor.cpp b/editor/plugins/script_text_editor.cpp
index 9d3c580f02..ecb2354aa1 100644
--- a/editor/plugins/script_text_editor.cpp
+++ b/editor/plugins/script_text_editor.cpp
@@ -814,7 +814,7 @@ void ScriptTextEditor::_code_complete_script(const String &p_code, List<ScriptCo
}
String hint;
Error err = script->get_language()->complete_code(p_code, script->get_path(), base, r_options, r_force, hint);
- if (err == OK && hint != "") {
+ if (err == OK) {
code_editor->get_text_edit()->set_code_hint(hint);
}
}
diff --git a/editor/plugins/shader_editor_plugin.cpp b/editor/plugins/shader_editor_plugin.cpp
index df3e23a9e9..80f63b4f48 100644
--- a/editor/plugins/shader_editor_plugin.cpp
+++ b/editor/plugins/shader_editor_plugin.cpp
@@ -202,9 +202,7 @@ void ShaderTextEditor::_code_complete_script(const String &p_code, List<ScriptCo
if (err != OK)
ERR_PRINT("Shaderlang complete failed");
- if (calltip != "") {
- get_text_edit()->set_code_hint(calltip);
- }
+ get_text_edit()->set_code_hint(calltip);
}
void ShaderTextEditor::_validate_script() {
diff --git a/misc/scripts/sort-demos.sh b/misc/scripts/sort-demos.sh
deleted file mode 100644
index 5e01b86b46..0000000000
--- a/misc/scripts/sort-demos.sh
+++ /dev/null
@@ -1,29 +0,0 @@
-#!/bin/bash
-# When scanning for demos, the project manager sorts them based on their
-# timestamp, i.e. last modification date. This can make for a pretty
-# messy output, so this script 'touches' each project.godot file in reverse
-# alphabetical order to ensure a nice listing.
-#
-# It's good practice to run it once before packaging demos on the build
-# server.
-
-if [ ! -d "demos" ]; then
- echo "Run this script from the root directory where 'demos/' is contained."
- exit 1
-fi
-
-if [ -e demos.list ]; then
- rm -f demos.list
-fi
-
-for dir in 2d 3d gui misc viewport; do
- find "demos/$dir" -name "project.godot" |sort >> demos.list
-done
-cat demos.list |sort -r > demos_r.list
-
-while read line; do
- touch $line
- sleep 0.2
-done < demos_r.list
-
-#rm -f demos.list demos_r.list
diff --git a/modules/jsonrpc/jsonrpc.cpp b/modules/jsonrpc/jsonrpc.cpp
index e1bba60f2f..ea90cce83d 100644
--- a/modules/jsonrpc/jsonrpc.cpp
+++ b/modules/jsonrpc/jsonrpc.cpp
@@ -47,11 +47,11 @@ void JSONRPC::_bind_methods() {
ClassDB::bind_method(D_METHOD("make_notification", "method", "params"), &JSONRPC::make_notification);
ClassDB::bind_method(D_METHOD("make_response_error", "code", "message", "id"), &JSONRPC::make_response_error, DEFVAL(Variant()));
- BIND_ENUM_CONSTANT(PARSE_ERROR)
- BIND_ENUM_CONSTANT(INVALID_REQUEST)
- BIND_ENUM_CONSTANT(METHOD_NOT_FOUND)
- BIND_ENUM_CONSTANT(INVALID_PARAMS)
- BIND_ENUM_CONSTANT(INTERNAL_ERROR)
+ BIND_ENUM_CONSTANT(PARSE_ERROR);
+ BIND_ENUM_CONSTANT(INVALID_REQUEST);
+ BIND_ENUM_CONSTANT(METHOD_NOT_FOUND);
+ BIND_ENUM_CONSTANT(INVALID_PARAMS);
+ BIND_ENUM_CONSTANT(INTERNAL_ERROR);
}
Dictionary JSONRPC::make_response_error(int p_code, const String &p_message, const Variant &p_id) const {
diff --git a/scene/3d/camera.cpp b/scene/3d/camera.cpp
index 9f8510248c..9797b5f3ab 100644
--- a/scene/3d/camera.cpp
+++ b/scene/3d/camera.cpp
@@ -548,9 +548,9 @@ void Camera::_bind_methods() {
BIND_ENUM_CONSTANT(KEEP_WIDTH);
BIND_ENUM_CONSTANT(KEEP_HEIGHT);
- BIND_ENUM_CONSTANT(DOPPLER_TRACKING_DISABLED)
- BIND_ENUM_CONSTANT(DOPPLER_TRACKING_IDLE_STEP)
- BIND_ENUM_CONSTANT(DOPPLER_TRACKING_PHYSICS_STEP)
+ BIND_ENUM_CONSTANT(DOPPLER_TRACKING_DISABLED);
+ BIND_ENUM_CONSTANT(DOPPLER_TRACKING_IDLE_STEP);
+ BIND_ENUM_CONSTANT(DOPPLER_TRACKING_PHYSICS_STEP);
}
float Camera::get_fov() const {
diff --git a/scene/animation/animation_blend_tree.cpp b/scene/animation/animation_blend_tree.cpp
index 20a09696e1..6f67d01a1c 100644
--- a/scene/animation/animation_blend_tree.cpp
+++ b/scene/animation/animation_blend_tree.cpp
@@ -350,8 +350,8 @@ void AnimationNodeOneShot::_bind_methods() {
ADD_GROUP("", "");
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "sync"), "set_use_sync", "is_using_sync");
- BIND_ENUM_CONSTANT(MIX_MODE_BLEND)
- BIND_ENUM_CONSTANT(MIX_MODE_ADD)
+ BIND_ENUM_CONSTANT(MIX_MODE_BLEND);
+ BIND_ENUM_CONSTANT(MIX_MODE_ADD);
}
AnimationNodeOneShot::AnimationNodeOneShot() {