Ah yes, Sakuradite, the Deus Ex Machina of Code Geass. SUPER ENERGY GO!
Actually, I think Code Geass takes place around modern times. Considering Japan was conquered in 2010 a.t.b (whatever the fuck that is in real time).
It would actually be slightly in the future going by that. But then, they have no reason to invent an atomic bomb before that.
The A-bomb was ushered into production due to the standoffish situations in WWII. Though the standoffs were overcome, both sides continued with production.