How does this power supply schematic work?
This is a secondary side regulated flyback architecture. 
The diodes are used to rectify the 220V to have a sine wave between 0 - 220V. The capacitor is to get a somehow DC like voltage.

The U6 TOP264EG switches the current through the coil of the primary side. This induce a voltage on the two secondary side winding's.

The TOP264EG regulates the switching according to its input pin 3. The optocuppler ISO5 (and the feadback network R29, C33, U7, R31, R32) basically "tells" the U6 if the secondary 5V output voltage is above or below the limit. Based on this the duty cycle of the switching is changed according to the needs of the secondary 5V side.

The third winding is to give the ISO5 a fitting supply voltage around 5V based on the primary side ground.

The 5v secondary side is rectified to DC by C31, L1 and C32