(a) Mujahid (may Allah have mercy on him) said that the Messenger of Allah (peace and blessings be upon him) was reciting in prayer, and he heard a young man of the Ansar reciting, so this verse was revealed: "And when the Qur'an is being recited, listen attentively and keep silent." [Surah al-A'raf: 204]
(b) Through another chain it has reached us from Mujahid (may Allah have mercy on him) that he said: This verse is about the Friday sermon; and in a third narration the words are "in the prayer and the sermon".
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصلاة / 2886