Uganda prosecutor in al-Shabab bomb case shot dead
Her children were with her in the car but weren't harmed in the shooting, according to a statement by the Ugandan Information Minister Jim Muhwezi in the Daily Monitor.
The BBC's Catherine Byaruhanga in Kampala says some Ugandans are now wondering whether Ms Kagezi was given enough protection.
Our correspondent says there is now an increased presence of policemen and soldiers on the streets of the Ugandan capital.
Last week the US said it had "received information of possible threats" at city locations where Western nationals gather.
Uganda's government said the US had warned of a possible suicide bomber trying to enter the country.
Uganda was under threat because it is a key contributor to the African Union mission fighting al-Shabab inside Somalia, a spokesman said.