mirror of
https://github.com/godotengine/godot.git
synced 2025-11-01 14:11:15 +00:00
Add copy/paste options to preview material parameters in visual shader
This commit is contained in:
parent
cb411fa960
commit
485e7f899b
2 changed files with 80 additions and 1 deletions
|
|
@ -276,6 +276,7 @@ class VisualShaderEditor : public ShaderEditor {
|
|||
bool shader_preview_showed = true;
|
||||
|
||||
LineEdit *param_filter = nullptr;
|
||||
MenuButton *preview_tools = nullptr;
|
||||
String selected_param_id;
|
||||
Tree *parameters = nullptr;
|
||||
HashMap<String, PropertyInfo> parameter_props;
|
||||
|
|
@ -318,6 +319,11 @@ class VisualShaderEditor : public ShaderEditor {
|
|||
COLLAPSE_ALL
|
||||
};
|
||||
|
||||
enum PreviewToolsMenuOptions {
|
||||
COPY_PARAMS_FROM_MATERIAL,
|
||||
PASTE_PARAMS_TO_MATERIAL,
|
||||
};
|
||||
|
||||
#ifdef MINGW_ENABLED
|
||||
#undef DELETE
|
||||
#endif
|
||||
|
|
@ -367,6 +373,7 @@ class VisualShaderEditor : public ShaderEditor {
|
|||
void _show_add_varying_dialog();
|
||||
void _show_remove_varying_dialog();
|
||||
|
||||
void _preview_tools_menu_option(int p_idx);
|
||||
void _clear_preview_param();
|
||||
void _update_preview_parameter_list();
|
||||
bool _update_preview_parameter_tree();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue