How is it possible that the Fw 190 fires through the propeller from 4 different places as you can see in the picture below? There are two machine guns right in front of the pilot, and one at either side on the wing, close to the body of the plane.
This answer is specific to how this was achieved via mechanical means in earlier aircraft and not specific to the Fw 190.
It's called a "Synchronization Gear" and it allows the gun to fire only when the blade is not in front of the barrel.
[From Wikipedia] Interestingly, the linkage between the propeller and the gun is achieved with a spinning drive shaft rather than a reciprocating rod. The impulses needed to operate the trigger, or in this case to prevent the trigger from operating, were produced by a cam wheel with two lobes at 180° apart situated at the gun itself, since the gun is interrupted by both blades of the propeller.
These have been around since before 1920, long before the aircraft you mention in your original post.
The one on the Fokker (not Focke-Wulff, but still German) differs a little bit from the patent image above:
But not significantly, the basic idea is that the trigger mechanism follows a cam lobe which is tied to the propeller shaft. When the cam lobe spins, the trigger is allowed to fire the gun only when the propeller isn't "in the way".
See Wikipedia Article on the Synchronization Gear for more information.
The Internet is incredible. I found a PDF of the manual for the armament of the Fw-190 online here. In it, the components are described sufficiently to be sure that synchronization in the FW-190 was achieved electrically.
General arrangement of the armament in the Fw-190 (picture source). The pipes running to the wing cannons feed hot air from the engine to the ammunition box to keep the temperature there above -35°.
The Wikipedia page on gun synchronization already mentions that with firing rates above 400 rounds/minute, mechanical synchronization became unreliable, and at the end of WW I, the first electrical gun synchronization by Siemens was used in LVG attack planes, and Aviatik employed their own system. The much higher firing rate of WW II guns required electrical synchronization, and only some Russian fighters continued to use mechanical synchronization into and even beyond WW II.
Since WWI, there was a device called a Synchronisation Gear which staggered the firing of the gun so that it would not hit the propeller of the plane.
I can't seem to locate the reference but the synchronizing gear was not at first used with the forward firing gun. The inventor of the forward firing gun had steel plates mounted to his propellers to deflect the occasional round that might hit the prop. This was satisfactory right up until he got his prop shot off. That's when the synchronizing systems were sought out.