Renamed EditorResourcePreviewGenerator.should_generate_small_preview() to generate_small_preview_automatically()

Added can_generate_small_preview() so the generator uses generate() or generate_from_path() if it returns true
Added can_generate_small_preview() and generate_small_preview_automatically() to the scripting languages
This commit is contained in:
MrCdK
2019-05-20 10:45:12 +02:00
parent a940b4cf64
commit f8a9844d80
5 changed files with 57 additions and 13 deletions

View File

@ -48,7 +48,8 @@ public:
virtual Ref<Texture> generate(const RES &p_from, const Size2 p_size) const;
virtual Ref<Texture> generate_from_path(const String &p_path, const Size2 p_size) const;
virtual bool should_generate_small_preview() const;
virtual bool generate_small_preview_automatically() const;
virtual bool can_generate_small_preview() const;
EditorResourcePreviewGenerator();
};