Added a note explaining the difference between an ideal implementation and

the one we have now.


git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@67 c613c5cb-e716-0410-b11b-feb51c14d237
This commit is contained in:
Ray Greenwell
2006-08-28 22:30:46 +00:00
parent ba1d173a30
commit b1ae928811
@@ -102,6 +102,8 @@ public class EZGamePanel extends JPanel
public void apply (Component comp) { public void apply (Component comp) {
if (comp instanceof Game) { if (comp instanceof Game) {
// only notify the Game if we haven't seen it before // only notify the Game if we haven't seen it before
// TODO: what we really want is a weak identity map,
// so that two keys that are equals() do not collide.
if (null == _seenGames.put(comp, Boolean.TRUE)) { if (null == _seenGames.put(comp, Boolean.TRUE)) {
((Game) comp).setGameObject(_ctrl.gameObjImpl); ((Game) comp).setGameObject(_ctrl.gameObjImpl);
} }