I'm going to restate a lot of what Jar said, but try to break it down to even easier bite sized chunks.
Dinosaurs (technically it wasn't "dinosaurs" that evolved into birds, but I'm trying to keep this simple) didn't evolve wings and then feathers.
Feathers came before wings.
There are several fossils from China which actually managed to preserve the imprints of feathers in fine volcanic ash - EXTREMELY rare.
What we've seen is that prior to the development of the wing there were downy feathers for insolation, and even symetrical feathers (feathers which were exactly the same on either side) which could be used for camoflauge, sexual attractiveness, cooling/heating - but could not be used for flight.
In other words, these creatures were covered in feathers long before they took to the air.
So, from having feathers, to using feathers to slow a fall, lengthen a hop, or even glide from tree to tree isn't that big of a step.
From there it's all small steps to flight.