소스 검색

Merge pull request #87880 from kitbdev/fix-textedit-freeze

Fix freeze in TextEdit with `scroll_past_end_of_file` and `fit_content_height`
Rémi Verschelde 1 년 전
부모
커밋
c23cc08b1c
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      scene/gui/text_edit.cpp

+ 1 - 1
scene/gui/text_edit.cpp

@@ -7333,7 +7333,7 @@ void TextEdit::_update_scrollbars() {
 
 	int visible_rows = get_visible_line_count();
 	int total_rows = draw_placeholder ? placeholder_wraped_rows.size() - 1 : get_total_visible_line_count();
-	if (scroll_past_end_of_file_enabled) {
+	if (scroll_past_end_of_file_enabled && !fit_content_height) {
 		total_rows += visible_rows - 1;
 	}