I bet he was probably sick when you got him even though he didn't show it. Then with all the new stress of being moved and new water conditions, ect, made him septable to the fungus. So after going through more stress of everything, ich (who are always present in the water) attacked him because of his weaken immune system. As for the dropsy, no one really knows how or why fish get it, but i bet the stress of all this didn't help. It's great that he pulled through it though

. And finally, when you decided to just let him be, he didn't have anymore things to stress him like the meds and moving him back and forth. Well that's my take on it.