How to re-solder the resistor in order to reprogram the Atmega8U2
Looks like you ripped a pad off. To prevent that in the future, try using more flux and dropping the temp (Max around 320*C/610*F). The iron shouldn't be in contact with the board for more than about 3 seconds. No force should be necessary to remove components. 

Not to worry though. Common beginner's mistake and not too hard to fix.

To prep this for repair: 


Gently clean the area up with 91% isopropyl alcohol and cotton swabs. 
Carefully scrape away the solder mask (blue paint) on what's left of the copper trace all the way back to the via (little hole). Try to remove all the solder mask from the via. Straighten and flatten the pulled up trace. 
Clean, flux, and tin (apply as thin layer of solder) to the trace and remaining pad. Filling in the via is OK as it will give better surface area to attach the repair. 
Flux and solder the resistor to the remaining pad to keep it in place and properly aligned for the repair. 


To repair the damage: 


We need to bridge the gap created by the damaged pad. A globby solder bridge may work, but wire is much better. 
Find a piece of thin gauge solid core wire (30-22AWG. Some 24AWG from an ethernet cable would do fine). 
Orient the wire so that it's directly over the remaining trace and also making contact with that end of the resistor. 
You can trim it to size now or after soldering. It may be easier to keep in place if you trim it after soldering as long as you have some fine flush cut pliers. Either way, leave enough that it covers the entire cleaned and tinned portion of the trace. 
Flux and solder the wire to both the resistor and trace. This will complete the circuit. 
Clean again with alcohol. Let dry. Test the board. 


Give this Adafruit article a read. I've got extensive professional soldering training and endorse it fully as the best beginners soldering guide I've found.