Before I even get started I want to stress that this was built for fun out of what I had in my parts box, there has been absolutely no engineering (see for instance the IRF512 Vgs threshold that just happens to be low enough), so I suspect  if you try to reproduce this any component variation could be critical. But that makes experimenting more fun, doesn't it?

From an analysis of the circuit, strictly conducted after getting it to work by brute force, things should work more or less as follows. 

At rest D3 and D4 have high enough impedance to leave the gate floating and, possibly, pulled slightly low thanks to D4 being exposed to more ambient light than D3 (because D3 is partially covered by D2, more about D2 below). In very bright light conditions if you wait long enough the light will turn on, so some current is leaking through D3 and charges the 100nF cap eventually. However, in normal room light conditions, this never happened.

Shining a flame slightly closer to D3 than D4 will quickly charage the 100nF capacitor as the IR LED will react to the high amount of IR light from the flame. Once the MOSFET gate voltage goes about the threshold (roughly 4V) the channel will open and both D2 and D1 will light up. 

D2 shines IR light on D3 and in this way forms a latch that keeps the MOSFET open even when the flame is removed. 

TP3, which in this instance means "Touch Point" and not the more common "Test Point", is made of two terminals running along the plastic "flame" enclosing D1. Pinching the "flame" will cause the finger resistance to drain the tiny charge on the 100nF capacitor and hence the MOSFET will turn off.

The remote control is a gimmick (as if the rest of the device was a highly polished piece of engineering) that works by shining the IR light towards D3 to turn the light on and D4 to turn it off.

TP2 and TP1 give then the finger touch control, which works by charging/discharging the 100nF capacitor as above through the finger resistance.

The quiescent current is tiny so the 9V battery should last ages while waiting for someone to attempt to torch the device to turn it on.