Updated

A federal judge ruled Monday there is no constitutional right to carry a hidden gun in public — a decision that dealt a setback to gun-rights advocates who had challenged how much discretion California law enforcement officials have in issuing concealed weapons permits.

U.S. District Court Judge Morrison England Jr. in Sacramento supported a policy by Yolo County Sheriff Ed Prieto that says applicants must have a reason, such as a safety threat, to legally carry a concealed weapon in his county northwest of Sacramento.

Prieto was sued by opponents claiming sheriffs, who issue most concealed weapons permits, must give the documents to any applicant as long as they are not mentally ill, do not have a criminal background and complete a training course.

England signed the ruling Friday and it was filed in court on Monday.

Gun rights groups have filed similar lawsuits in Maryland, Massachusetts and New York, but Alan Gura of Alexandria, Va., an attorney for the gun groups, said none of the cases have been resolved.

Gura filed a notice Monday saying the groups will appeal Judge England's decision to the 9th U.S. Circuit Court of Appeals in San Francisco.

Gura had argued that Prieto's policy gives the sheriff arbitrary discretion over a fundamental constitutional right to bear arms.

England countered that California law currently lets gun owners carry an unloaded weapon so it can be quickly loaded and used in self-defense if needed.

As a result, "Yolo County's policy does not substantially burden plaintiffs' right to bear and keep arms," England wrote in his 16-page decision.

Meanwhile, the California state Assembly approved a bill Monday by Assemblyman Anthony Portantino, D-La Canada Flintridge, which would ban openly carrying unloaded handguns in public.

Portantino introduced the measure after some gun rights activists carried unloaded weapons in public as a political statement. The bill, AB144, now moves to the state Senate.

Gura said the gun groups disagree with England's open carry reasoning.

"Obviously it doesn't do anyone any good to walk around with an unloaded gun, especially in public, because that's just an advertisement for a criminal to take it off your person," Gura said. "They're not going to have time to start loading their handgun. Criminal events usually play out more quickly than that."

The pending legislation is unlikely to affect the appeal because the gun rights groups did not base their lawsuit on California's open carry law, said Prieto's attorney Serena Mercedes Sanders.

The Yolo County appeal is pne of two concealed carry lawsuit currently pending before the 9th U.S. Circuit Court of Appeals, she said.

A federal judge in the Southern District of California in December ruled against gun-rights organizations in a San Diego County case. That lawsuit was brought by a different attorney who used different legal arguments.

"No case has held that there is a right to carry a concealed weapon," Sanders said.

England also ruled against gun advocates' argument that Prieto's policy of requiring that applicants be of "good moral character" gives the government "unbridled discretion" over who can get a permit.

Prieto's seven-page policy limits permits to those who can demonstrate they have been victims of a violent crime, have had threats of violence, or business owners who carry large amounts of cash.

The Second Amendment Foundation, Calguns Foundation and three individuals sued in 2009, alleging Prieto's policy also violates First Amendment free speech rights and Fourteenth Amendment equal protection guarantees.

The judge disagreed.

"Regulating concealed firearms is an essential part of Yolo County's efforts to maintain public safety and prevent both gun-related crime and, most importantly, the death of its citizens. Yolo County's policy is more than rationally related to these legitimate government goals," England wrote.