In both scenarios, the shareholder can get the same amount of cash if they want it. Except with a dividend, they are forced to pay tax now.
I suppose there could exist a jurisdiction where dividends are taxed less than capital gains. I would be curious to know if there are any.