Your fish are suffering from two disorders which are Swim Bladder Disorder (sbd)combined with Dropsy.
The symptoms for each illness are floating upside down=sbd and scales sticking out=Dropsy.
The main causes of sbd are a fish's shape, genetics and absorbing too much air when feeding. A fish's swim bladder is an organ fish have which enables them to maintain their balance, bouyancy and swim upright at will. When it becomes blocked, infected or has too much air it ceases to function properly as you are seeing.
The main cause of Dropsy is unfavorable water conditions usually as a result of not doing enough partial water changes.
What I suggest you do is place the fish back in the main tank. Do a 50% partial water change in the tank. Add some epsom salts to the water at a ratio of 1/8 teaspoon per every 5 gallons of water. The epsom salts might help to alleviate the swelling.
Also do not fill the tank water to the top of the tank, leave about 3 inches empty from the top of the tank as this will lessen the water pressure thus making easier for the fish.
Begin to feed the fish canned peas without the husk . Feed 1-2 peas twice a day making sure to clean out any uneaten peas after feeding as uneaten food will decay in the water. The peas should help clear out the fish's swim bladder. In the future when feeding flake food it's best to soak it apart in some seperated tank water so as to make ingesting air less likely.
In addition to the above recommendations you might consider to begin treatment with a medicine called Maracyn-Two which is effective in treating some cases of sbd and Dropsy. Maracyn-Two can be easily found at most major pet stores. Just follow the directions on the product label for usage.
Please note that the best preventative against fish disease is weekly 25% partial water changes, to not overfeed and to not overcrowd the fish.
Best wishes and please let me know if you have any questions.
.
YOUR TROPICAL FISH RESOURCE
OVER 20 YEARS EXPERIENCE W/TROPICAL FISH---BREEDING, MAINTAINING, CURING