Both are grammatically possible, but the first is the normal expression. The second would make more sense with a different verb: I smiled after noticing him glance at me.
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.