I'm not quite sure about that… maybe it's to indicate how much you enjoy being around your Pokémon? Either that, or it could be the other way around—it's to show us how much our Pokémon enjoy being around us.
Mega evolved Pokémon get an increase in some of their stats, which help them to move faster, take more hits, land harder attacks, etc. etc. For example, when Blastoise makes its transformation to Mega Blastoise, it gets a major boost in both of its defensive stats. Thanks to that, it gets the chance to survive for a few additional turns and stall your opponent.
Besides experience boost, you also get a higher base attack power in the move "Return," I think. It hasn't been confirmed though, but that could most likely be the case. d: The power of Return does depend on how much your Pokémon love you, so, yeah.