Syeikh Abu 'Abdurrahman was teaching about Solat al-Eid, and he told us that the Hijra calendar is based on the movement of the moon, and not the sun.
Narrated Ibn Umar (radiyallahu 'anhuma): I heard the Apostle of Allah (sallallahu 'alayhi wasallam) saying, "When you see the crescent (of the month of Ramadan), start fasting, and when you see the crescent (of the month of Shawwal), stop fasting; and if the sky is overcast (and you can't see It) then regard the crescent (month) of Ramadan (as of 30 days)."
A man sitting on the chair in the last row asked him: "Muslims now should change their calendar and use the sun. Why must it be the moon?" The syeikh replied: "Why must it be the sun then?"