Sounds like a simple state machine to me. I've seen a few flashlights like this, sometimes they also have a "blink" mode where the light blinks.
The on/off function (with no blink) could be done with just a simple j/k flip flop. with both J and K inputs tied to power and the momentary button connected to the clock input. When you push the button, it simply flips the state of the flip-flop; so if its off, it turns on and if its on it turns off. When you power cycle it, the flip flop should come initialize to the "off" position automatically (although it may not if you power cycled it really quickly).
To add more states like the blink function, you'd need another flip-flop and maybe a 555 timer circuit. With two flip-flops you could have four states, so one state would be wasted.