Because his goals and your interests are now aligned.
Broadly speaking, the Gates Foundation wants to improve the world. It doesn't care about making a profit, it just wants to get the most improvement for the money it has available to spend. It can choose freely what kind of energy production to promote, and it is clearly choosing based on a bang-for-the-buck basis.
When Gates was running Microsoft, his goal was to make Microsoft bigger. Microsoft's mission statement of "enabling people and businesses throughout the world to realize their full potential" was actually subordinate to the goal of growing Microsoft, which is why one-Windows-running-on-everything was promoted over, say, clear standards and interoperability for Office files.