Merge jv
authorMerge Script
Wed, 02 Sep 2015 06:46:12 +0200
branchjv
changeset 6908 bc0ac54b098b
parent 6905 ebeee068a422 (current diff)
parent 6907 94dbd3782c96 (diff)
child 6910 222a3a9c372d
Merge
SimpleView.st
--- a/SimpleView.st	Sat Aug 15 06:40:00 2015 +0200
+++ b/SimpleView.st	Wed Sep 02 06:46:12 2015 +0200
@@ -10084,7 +10084,27 @@
      when problem or warning conditions arise.
      Someone may redefine this to flash its contents (instead of black/white)."
 
-    self fill:self blackColor.
+    self flash:messageOrNil withColor:self blackColor.
+
+    "
+     |v|
+
+     v := View new openAndWait.
+     Delay waitForSeconds:2.
+     v flash:'Hello World'.
+     Delay waitForSeconds:2.
+     v destroy
+    "
+!
+
+flash:messageOrNil withColor:flashColor
+    "flash the view - fill it black, then white, finally
+     redraw completely.
+     Can be used to wakeup the user :-)
+     when problem or warning conditions arise.
+     Someone may redefine this to flash its contents (instead of black/white)."
+
+    self fill:flashColor.
     messageOrNil notNil ifTrue:[
 	self withForeground:Color white do:[
 	    self displayString:messageOrNil centeredAt:(self center).
@@ -10106,7 +10126,7 @@
 
      v := View new openAndWait.
      Delay waitForSeconds:2.
-     v flash:'Hello World'.
+     v flash:'Hello World' withColor:Color red.
      Delay waitForSeconds:2.
      v destroy
     "