Selaa lähdekoodia

minor change in sequence of activities within Invalidate

git-svn-id: https://svn.inf.ethz.ch/svn/lecturers/a2/trunk@6793 8c9fc860-2736-0410-a75d-ab315db34111
eth.hunzikerp 9 vuotta sitten
vanhempi
commit
1a69fc20e1
1 muutettua tiedostoa jossa 6 lisäystä ja 5 poistoa
  1. 6 5
      source/WMTextView.Mod

+ 6 - 5
source/WMTextView.Mod

@@ -833,14 +833,14 @@ TYPE
 		PROCEDURE Initialize*;
 		BEGIN
 			ASSERT(IsCallFromSequencer());
-			(*Initialize^;
-			RecacheProperties;*)
+			(*Initialize^; RecacheProperties;*)
+			
+			IF text#NIL THEN	Resized 	END; (*implicit redundant invalidate in Resized *)(*! Resized is probably redundant*)
 			
-			cursor.SetVisible(FALSE);
-			IF text#NIL THEN	Resized 	END;
 			(* from now on, bidi-formatting can be done *)
 			layout.initialized := TRUE;
 			Initialize^;
+			cursor.SetVisible(FALSE);
 		END Initialize;
 
 		PROCEDURE Finalize;
@@ -900,6 +900,7 @@ TYPE
 		BEGIN
 			ASSERT(IsCallFromSequencer());
 			RecacheProperties^;
+			
 			defaultTextColorI := defaultTextColor.Get();
 			defaultTextBgColorI := defaultTextBgColor.Get();
 			isMultiLineI := isMultiLine.Get();
@@ -1061,7 +1062,7 @@ TYPE
 		VAR prevWidth: LONGINT;
 		BEGIN
 			ASSERT(IsCallFromSequencer());
-			Resized^;
+			Resized^; (*? here, an implicit Invalidate() is triggered - this is probably redundant *)
 			prevWidth := layout.paperWidth;
 			layout.paperWidth := bounds.GetWidth() - (bordersI.l + bordersI.r);
 			borderClip.r := bounds.GetWidth() - bordersI.r; borderClip.b := bounds.GetHeight() - bordersI.b;