diff options
author | Adriaan Moors <adriaan.moors@typesafe.com> | 2013-12-09 14:57:44 -0800 |
---|---|---|
committer | Adriaan Moors <adriaan.moors@typesafe.com> | 2013-12-09 14:57:44 -0800 |
commit | a444ed778843ca67689f6550c95bdb945fbfde51 (patch) | |
tree | 37f170a13255689d0a0a9294baddc1c52b078c82 | |
parent | db19ddf36ef657e137e2b24fc70375f8476da327 (diff) | |
parent | c955cf4c2ee88d1f94cd45aeee238fc5344d2f18 (diff) | |
download | scala-a444ed778843ca67689f6550c95bdb945fbfde51.tar.gz scala-a444ed778843ca67689f6550c95bdb945fbfde51.tar.bz2 scala-a444ed778843ca67689f6550c95bdb945fbfde51.zip |
Merge pull request #3244 from rtyley/si-8019-swing-publisher-check-pf-defined
SI-8019 Make Publisher check PartialFunction is defined for Event
-rw-r--r-- | src/swing/scala/swing/Publisher.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/swing/scala/swing/Publisher.scala b/src/swing/scala/swing/Publisher.scala index 96207de808..578ef71e09 100644 --- a/src/swing/scala/swing/Publisher.scala +++ b/src/swing/scala/swing/Publisher.scala @@ -44,7 +44,7 @@ trait Publisher extends Reactor { /** * Notify all registered reactions. */ - def publish(e: Event) { for (l <- listeners) l(e) } + def publish(e: Event) { for (l <- listeners) if (l.isDefinedAt(e)) l(e) } listenTo(this) } |