summaryrefslogtreecommitdiff
path: root/redo/zz_test.go
diff options
context:
space:
mode:
authorPietro Gagliardi <[email protected]>2014-08-09 10:33:38 -0400
committerPietro Gagliardi <[email protected]>2014-08-09 10:33:38 -0400
commit6c1bf7aabd859c27f26898ead8572dd00f419d57 (patch)
tree25e012396edc1c09c4252ac12c1e4d5a5a47d51a /redo/zz_test.go
parentb4a97e871a5c6c390927f5bac9b84b0fe6b40c20 (diff)
Big change: with the current event model, it's safe to call Area.RepaintAll() (and the future Area.Repaint()) from within AreaHandler.Key() and AreaHandler.Mouse(); get rid of the bool returns from each. The future Area.Repaint() is important; the bool returns repainted the whole Area, which may not be optimal.
Diffstat (limited to 'redo/zz_test.go')
-rw-r--r--redo/zz_test.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/redo/zz_test.go b/redo/zz_test.go
index 59f577b..0dc1421 100644
--- a/redo/zz_test.go
+++ b/redo/zz_test.go
@@ -50,8 +50,8 @@ func (a *areaHandler) Paint(r image.Rectangle) *image.RGBA {
draw.Draw(i, r, &image.Uniform{color.RGBA{128,0,128,255}}, image.ZP, draw.Src)
return i
}
-func (a *areaHandler) Mouse(me MouseEvent) bool { fmt.Printf("%#v\n", me); return false }
-func (a *areaHandler) Key(ke KeyEvent) bool { fmt.Printf("%#v\n", ke); return false }
+func (a *areaHandler) Mouse(me MouseEvent) { fmt.Printf("%#v\n", me) }
+func (a *areaHandler) Key(ke KeyEvent) { fmt.Printf("%#v\n", ke) }
func (tw *testwin) make(done chan struct{}) {
tw.t = NewTab()