فهرست منبع

Fixes LineEdit text selection with mouse selecting more than intended

(cherry picked from commit 3d8497318401040979242ae04271d6c0f5b253e9)
Waldson Patrício 9 سال پیش
والد
کامیت
73b40d1457
1فایلهای تغییر یافته به همراه0 افزوده شده و 10 حذف شده
  1. 0 10
      scene/gui/line_edit.cpp

+ 0 - 10
scene/gui/line_edit.cpp

@@ -806,16 +806,6 @@ void LineEdit::set_cursor_at_pixel_pos(int p_x) {
 		pixel_ofs+=char_w;
 
 		if (pixel_ofs > p_x) { //found what we look for
-
-
-			if ( (pixel_ofs-p_x) < (char_w >> 1 ) ) {
-
-				ofs+=1;
-			} else if ( (pixel_ofs-p_x) > (char_w >> 1 ) ) {
-
-				ofs-=1;
-			}
-
 			break;
 		}