Well, to get to the heart of that issue, you need to use very technical terms.
From the game's standpoint, by default, "Button 1" is "Fire All" and "Button 2" is "Fire Secondary." Generally, Button 1 is the trigger. However, things aren't always logical with joystick manufacturers. Kinda like how I expected the double-detent trigger on my X52 to be button 1 and 2...they're button 1 and 13, if I remember correctly.
In the case of the #1 (cockpit) position on planes: Fire All fires all selected gun banks (and ignores bombs, rockets, and fuel tanks as I remember). Fire Primary will fire only the top armament, which is generally the smaller of the two sets of guns and isn't generally toggled even though there's a key for it. Fire Secondary will fire the secondary bank regardless of whether a gun, bomb, rocket, or fuel tank is selected.
In the case of the #2-#9 (gunner) positions on planes: Fire All fires all turret positions (not the cockpit) that can possibly fire on the current point of aim. Fire Primary will only fire the current gun position you are in. Fire Secondary has no use.
In the case of the #2 (main gun) position on vehicles with a heavy gun: I may be remembering incorrectly, but I believe Fire All and Fire Primary are the same in this case; they fire only the main gun. Fire Secondary will fire the coaxial machine gun, if available.
In the case of the #3-#9 (gunner) positions on vehicles (and #2 on vehicles lacking a heavy gun, like the troop LVT): Fire All will fire all guns that can reach the current aiming point (though I THINK hull guns on tanks are not included in this). Fire Primary will fire only the current gun position. Fire Secondary has no use.