ソースを参照

Merge branch 'master' of tig:migueldeicaza/gui.cs

Charlie Kindel 5 年 前
コミット
05a8171e24
2 ファイル変更5 行追加2 行削除
  1. 1 1
      Terminal.Gui/Core/Toplevel.cs
  2. 4 1
      Terminal.Gui/Core/Window.cs

+ 1 - 1
Terminal.Gui/Core/Toplevel.cs

@@ -264,7 +264,7 @@ namespace Terminal.Gui {
 			if (IsCurrentTop || this == Application.Top) {
 				if (NeedDisplay != null && !NeedDisplay.IsEmpty) {
 					Driver.SetAttribute (Colors.TopLevel.Normal);
-					Clear (Frame);
+					Clear (bounds);
 					Driver.SetAttribute (Colors.Base.Normal);
 				}
 				foreach (var view in Subviews) {

+ 4 - 1
Terminal.Gui/Core/Window.cs

@@ -201,7 +201,10 @@ namespace Terminal.Gui {
 				if (dragPosition.HasValue) {
 					if (SuperView == null) {
 						Application.Top.SetNeedsDisplay (Frame);
-						Application.Top.Redraw (Bounds);
+						// Redraw the entire app window using just our Frame. Since we are 
+						// Application.Top, and our Frame always == our Bounds (Location is always (0,0))
+						// our Frame is actually view-relative (which is what Redraw takes).
+						Application.Top.Redraw (Frame);
 					} else {
 						SuperView.SetNeedsDisplay (Frame);
 					}