IR Reflective Sensor Accuracy
I would not use an IR LED/transistor because:

1) You need to take care of modulation and detection of the signal yourself

2) If you do not do the above correctly you will have problems with false detections from sunlight or even just indoor lighting

3) Even if you get everything above right you still have to set up a mechanical barrier between IR LED and transistor to prevent crosstalk, and you have to do all the crosstalk compensation yourself, taking into account reflection of the cover glass

If this is a somewhat serious project I would use an integrated IR detection module such as the Vishay VCNL4010 which will take care of all of the above for you. It can be controlled via I2C. If it's just a hobby project then by all means do it with an IR LED/transistor pair - it will be a good learning experience.