The Gemara in Megillah 6b says that it is forbidden to eulogize and fast on the fourteenth and fifteenth of the first Adar.

The Rosh in Megillah in Perek 1, siman 7 says that this halacha applies only in the following scenario: Klal Yisroel already read the Megillah on the fourteenth of Adar and in the middle of the day Bais Din decides to make it a leap year. In such an instance one is not allowed to fast or eulogize. In the event that the Megillah was not read when they announce the leap year, then one would be able to fast or eulogize someone.

The Tur 697 brings down the RifRambam and the S’mag who argue with this and say that it would be forbidden to fast or eulogize on any given leap year even in the event that they did not read the Megillah. The Shulchan Aruch brings both opinions and the Rema paskens like the Rif and like those who agree with him.

We see from the Rosh that once Klal Yisroel started celebrating Purim, and then the leap year was announced, the celebration is halted, but not entirely. If the Megillah was read and then it was decided that that year would be a leap year, one may not fast nor give a eulogy. On the other hand, one does not give mishloach manos or matanos lo’evyonim on that day.

A person from Chutz L’aretz is in Eretz Yisroel for a Yom Tov and he decides in middle of the second day of Yom Tov (Yom Tov Sheini Shel Galiyos) that he will stay in Eretz Yisroel to live from then onward. The Teshuvos L’Horos Nosson Vol.12:27 brings in the name of the Chazon Ish that this person’s Yom Tov stops in the middle of the day and all hilchos Yom Tov do not apply anymore.

The question arises, why is the case of Purim treated differently in middle of the day? We just mentioned above that hilchos Purim do not get completely cut off, whereas on Yom Tov it does. Why is this so?

One may differentiate between Purim Kotton and Yom Tov. On Purim, even if you will say that it may get cut, it will still have the name of Purim Kotton and therefore one would still be forbidden to fast or eulogize because of this. In the case of Yom Tov it is different; because the minute Yom Tov gets cut, it is not considered Yom Tov at all to a person living in Eretz Yisroel.