Corrected the ChatWindow and View cleanup

This commit is contained in:
Chad Pilkey 2015-05-26 15:21:41 -04:00
parent d765f3b65c
commit 1b7b40763c
2 changed files with 12 additions and 0 deletions

View File

@ -104,6 +104,17 @@ package org.bigbluebutton.web.chat.views {
override public function destroy():void {
super.destroy();
//view.dispose();
view.messageList.dataProvider = null;
chatMessageService.sendMessageOnSuccessSignal.remove(onSendSuccess);
chatMessageService.sendMessageOnFailureSignal.remove(onSendFailure);
view.messageList.removeEventListener(FlexEvent.UPDATE_COMPLETE, listUpdateCompleteHandler);
view.sendButton.removeEventListener(MouseEvent.CLICK, sendButtonClickHandler);
view.inputArea.removeEventListener(KeyboardEvent.KEY_DOWN, inputAreaKeyDownHandler);
userSession.userList.userRemovedSignal.remove(userRemoved);
userSession.userList.userAddedSignal.remove(userAdded);
view = null;
}
}

View File

@ -44,6 +44,7 @@ package org.bigbluebutton.web.chat.views {
override public function destroy():void {
super.destroy();
//view.dispose();
chatMessagesSession.chatMessageChangeSignal.remove(newMessageReceived);
view = null;
}
}