The long and short of it...
99.9% of all unintended discharges of a weapon are caused by human factors, and NOT the design of the firearm. The problem is human error.
Because humans are at play, and humans have lots of areas where they can get things wrong... there is NOTHING, not anything that you can add to the mechanics of the firearms to allow it to fire when you want and not fire when you don't because the operator has made a mistake.
Not even some theoretical future mind reading tech... Its simply impossible to factor out all of the human element.
Good designs can mitigate potential problems with certain times the firearm is handled... Like when it is being stripped for cleaning. Pistols like the Sig 320, require the slide locked to the rear and the magazine removed in order to strip it for cleaning. Other designs can increase the human element chance for error, but proper adherence to safety measures would prevent problems.
But when it comes time to shoot, or to draw the weapon in order to cover a potentially dangerous individual... the pistol MUST by necessity, be in a state of ready. Meaning a simple trigger squeeze is all that is needed to discharge the weapon. If no immediate need to discharge the weapon, the trigger finger must be kept out of the trigger guard away from the trigger.
So DA only, DA/SA in DA mode, SA with external safety... None of that matters when the person operating the firearm does not do their part for the safe operation of the firearm.
One could make the argument that a SA with a very short and light trigger is more prone to error due to sympathetic finger movements under stress... but it has been shown all trigger types are susceptible to it.
A Glock type trigger is neither short nor particularly light... It is a little shorter and lighter than some DAO pistols, but not others.
Making a trigger heavier is not the answer either... Even if the pull is buttery smooth... a heavy trigger pull is a huge detriment to good accuracy. Even well trained shooters tend to need to slow down to ensure good accuracy with a heavy DA trigger.
With the poor training that most police officers receive, and the fact most of them are not "gun" people who like to train on their own... Means the skills to master a long heavy trigger are not going to be there.
Which means lowered accuracy even on the training range, accuracy which gets worse in stressful situations... Meaning more chance of collateral damage and bystanders getting shot accidentally.
Not too long back there was an incident in NYC where bystanders where shot when police where shooting at a suspect. They fired several rounds, and missed the suspect with most of them.
Safeties on most firearms are there to increase safety while carrying the weapon... Some designs need the safety to make them drop safe, others simply to prevent accidents when faced with the wide variety of factors that comes from moving around an environment. Be it a pistol in a holster, or a rifle through the woods.
They are not there to make the firearm safer when it comes time to actually use the firearm. As has been said by me and others, the safety is to be disengaged before you put the firearm into action. It can do nothing to prevent an unintended discharge at that point.
Some holdover military forces like the US require a safety, due to an older mindset as far as training is concerned. Military doctrine tends to not like to change much. Its why the Beretta 92 design gained a decocker and safety, when only a decocker was really needed.
The safety was a hold over from the fact they have been training with safeties for over 75 years at that point... So why not keep doing what worked before.
So, human error is the cause of almost all unintended discharges of firearms... and the only way to combat that factor is proper and regular training. Even then, human error can creep in, as even the best trained have been caught making mistakes like resting fingers on triggers.
So any time a firearm is in use, a small chance of danger is going to be present.
But such is with anything a human is involved in. It's why we have around 35,000 deaths due to automobile crashes each year in the US.
Infrastructure fails...
Industrial accidents...
Its all due to human error... all of it.