//System.out.println("AudiotTreatmentComponent Set live " + live);
//ChannelComponentMO channelComponent = (ChannelComponentMO) cellRef.get().getComponent(ChannelComponentMO.class);
ChannelComponentMO channelComponent = channelRef.get();
if (live == false) {
channelComponent.removeMessageReceiver(AudioTreatmentMenuChangeMessage.class);
channelComponent.removeMessageReceiver(AudioTreatmentRequestMessage.class);
channelComponent.removeMessageReceiver(AudioVolumeMessage.class);
removeProximityListener();
//cellRef.get().removeParentChangeListener(this);
//System.out.println("Removed parent change listener");
cleanup();
return;
}
ComponentMessageReceiverImpl receiver = new ComponentMessageReceiverImpl(cellRef.get());
channelComponent.addMessageReceiver(AudioTreatmentMenuChangeMessage.class, receiver);
channelComponent.addMessageReceiver(AudioTreatmentRequestMessage.class, receiver);
channelComponent.addMessageReceiver(AudioVolumeMessage.class, receiver);
initialize();
}