From a3b20e176b00697a519f5324ba56cbc9e9ac59ab Mon Sep 17 00:00:00 2001 From: Ray Greenwell Date: Sat, 15 Aug 2009 00:06:12 +0000 Subject: [PATCH] Scratched an itch... Removed the unholy 'alreadyDisplayed' hack and associated return value from ChatDisplay. The localtype should be used to determine whether something should be displayed. If not, why should ChatDisplay registration order matter? It shouldn't. If there are two ChatDisplays that could potentially show the same message and you only want one of them to, sort that out in your own fuckin' code. I'm not changing the Java side right now because I'd have to patch-up a bunch of projects... git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@5916 542714f4-19e9-0310-aa3c-eee0fc999fb1 --- src/as/com/threerings/crowd/chat/client/ChatDirector.as | 5 +---- src/as/com/threerings/crowd/chat/client/ChatDisplay.as | 4 +--- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/src/as/com/threerings/crowd/chat/client/ChatDirector.as b/src/as/com/threerings/crowd/chat/client/ChatDirector.as index 2a4e75ddd..d205d04f7 100644 --- a/src/as/com/threerings/crowd/chat/client/ChatDirector.as +++ b/src/as/com/threerings/crowd/chat/client/ChatDirector.as @@ -729,11 +729,8 @@ public class ChatDirector extends BasicDirector */ protected function dispatchPreparedMessage (message :ChatMessage) :void { - var displayed :Boolean = false; _displays.apply(function (disp :ChatDisplay) :void { - if (disp.displayMessage(message, displayed)) { - displayed = true; - } + disp.displayMessage(message); }); } diff --git a/src/as/com/threerings/crowd/chat/client/ChatDisplay.as b/src/as/com/threerings/crowd/chat/client/ChatDisplay.as index 669aee6be..7c702d9a1 100644 --- a/src/as/com/threerings/crowd/chat/client/ChatDisplay.as +++ b/src/as/com/threerings/crowd/chat/client/ChatDisplay.as @@ -39,9 +39,7 @@ public interface ChatDisplay * Called to display a chat message. * * @see ChatMessage - * @return true if the message was displayed here. */ - function displayMessage ( - msg :ChatMessage, alreadyDisplayed :Boolean) :Boolean; + function displayMessage (msg :ChatMessage) :void; } }