Răsfoiți Sursa

Merge pull request #962 from BDisp/set-relative-layout

Fixes #961. Recreates the Frame when necessary.
Charlie Kindel 4 ani în urmă
părinte
comite
ec1f7c2684
1 a modificat fișierele cu 4 adăugiri și 1 ștergeri
  1. 4 1
      Terminal.Gui/Core/View.cs

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

@@ -1690,7 +1690,10 @@ namespace Terminal.Gui {
 				else
 					h = Math.Max (height.Anchor (hostFrame.Height - _y), 0);
 			}
-			Frame = new Rect (_x, _y, w, h);
+			var r = new Rect (_x, _y, w, h);
+			if (Frame != r) {
+				Frame = new Rect (_x, _y, w, h);
+			}
 		}
 
 		// https://en.wikipedia.org/wiki/Topological_sorting