Degrease that shit, oily metal will not take paint worth a shit, clean and dry..
Try Slip 2000 725, I've never used it but Pat Rogers recommends it
I would hit up the
Barbasol or
Simple Green simply because they will break the grease without melting plastics.
I don't know what to tell you to do about the parts that move like the safety selector, you don't want to have to break the paint to free that part. Maybe paint the gap with wax so you can clean it out.. I don't know. For sure you can tape over those areas to keep paint out.
Stuff paper in all the holes to keep paint out of the barrel and fire control group, don't fuck around.
Read the can of before you paint, start to spray past the part you're painting, CLEAN YOUR TIPS, go from light to dark, cheap paint is bullshit, Flat or Matte but no Semi or Gloss because shine sucks, don't paint rubber make sure the lens caps are on and tight and don't get screwed up over thinking it because it will wear off.
Oh yeah.. take picture and FLECK THAT SHIT!