summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2022-09-14 07:59:59 +0200
committerGitHub <noreply@github.com>2022-09-14 07:59:59 +0200
commitdbd6fa7e33defd8ec0857a8312339a1b0e33ab01 (patch)
tree5ef9ae79c2ccf112f67371c6a0298eea341d3030
parente5963cf3dd91f626e5bd3d24d51fee7bb96e7a5d (diff)
parent2ece5b4a6b476bb16f842819a22f7f13e41d677d (diff)
Merge pull request #65737 from bruvzg/font_do_not_emit_from_dtr
[Font] Remove unnecessary cleanup and `changed` signal emission from the destructor.
-rw-r--r--scene/resources/font.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/scene/resources/font.cpp b/scene/resources/font.cpp
index 189d8d5502..3d9e4e4a63 100644
--- a/scene/resources/font.cpp
+++ b/scene/resources/font.cpp
@@ -554,7 +554,6 @@ Font::Font() {
}
Font::~Font() {
- reset_state();
}
/*************************************************************************/
@@ -2433,11 +2432,10 @@ int32_t FontFile::get_glyph_index(int p_size, char32_t p_char, char32_t p_variat
}
FontFile::FontFile() {
- /* NOP */
}
FontFile::~FontFile() {
- reset_state();
+ _clear_cache();
}
/*************************************************************************/
@@ -2688,7 +2686,6 @@ FontVariation::FontVariation() {
}
FontVariation::~FontVariation() {
- reset_state();
}
/*************************************************************************/
@@ -3081,5 +3078,4 @@ SystemFont::SystemFont() {
}
SystemFont::~SystemFont() {
- reset_state();
}