EventListener.st
changeset 1424 3198d7d846be
parent 1271 1fc0f8a774c7
child 1483 a820040c7240
--- a/EventListener.st	Thu Nov 09 20:42:15 2000 +0100
+++ b/EventListener.st	Fri Nov 10 12:19:39 2000 +0100
@@ -12,6 +12,8 @@
 
 
 
+"{ Package: 'stx:libview2' }"
+
 Object subclass:#EventListener
 	instanceVariableNames:''
 	classVariableNames:''
@@ -96,6 +98,12 @@
     "Modified: 23.4.1996 / 21:58:03 / cg"
 !
 
+hasKeyboardFocus:aBoolean view:aView
+    "not handled here - should be redefined in a concrete subclass"
+
+    ^ false
+!
+
 keyPress:key x:x y:y view:aView
     "not handled here - should be redefined in a concrete subclass"
 
@@ -177,8 +185,12 @@
      If false is returned, the event is processed as usual.
      Here, the event is dispatched into one of the button*/key* etc. methods"
 
-    ^ ev dispatchWithViewArgumentTo:self
-
+    Error handle:[:ex |
+        ('Listener [info]: error while processing event: ' , ex description) printCR.
+        ^ false
+    ] do:[
+        ^ ev dispatchWithViewArgumentTo:self
+    ]
 !
 
 unlisten
@@ -190,5 +202,5 @@
 !EventListener class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libview2/EventListener.st,v 1.18 1999-11-22 15:05:05 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libview2/EventListener.st,v 1.19 2000-11-10 11:19:39 tm Exp $'
 ! !