It is an interesting question and I know exactly what you mean. I often look at the likes of Stoner performing what you describe and think "wow!". Right, for the answer...
Although the front wheel of any bicycle plays a key role in providing stability, it is not required for cornering. The ability to change direction is provided by a centripetal force, which is usually provided by both wheels of the motorcycle. The front wheel in this case providing the stability to the bike via the 'mechanical trail' (see the aside below). However, if the front wheel is off the ground, this does not mean that the centripetal force required to corner cannot be achieved (although the rider has to be much more skilful by using one wheel without the stability provided by the front wheel's mechanical trail). Note, in the case of a 230-260BHP MotoGP bike, cornering at high speed, having one wheel off the ground does not mean that the act of cornering is too-fine-a balancing act, the rapidly rotating wheels in this case will provide a 'large' amount gyroscopic torque. You will often see riders turning the front wheel in the cases you mention.
This acts to allows the rider to change the bikes trajectory, and pivot slightly about the rear wheel's point of contact and provide some lateral stability.
Aside: An interesting thing about the use of the front wheel to steer a motorcycle (or any bicycle for that matter) is 'mechanical trail' or 'caster'. This quantity is one thing that I was not aware of until I designed and made my own downhill racing bike many years ago. Mechanical trail is the perpendicular distance between the steering axis and the point of contact between the front wheel and the ground. It may also be referred to as 'normal trail'. This quantity is what determines how a bicycle handles when steering. See the picture below
If the trail is positive (trail shown by the green arrows), the bike will be stable. The more trail, the "heavier" the steering. If this distance is (too) negative, you cannot steer you bike (try turning the handle bars of your push bike the wrong way around [we have all done it as kids but I don't recommend it!].
For me, the reasons for trail playing such a key role in the steering stability of a bike is (very loosely) 'causality'. The trail or 'lead' allows the rider to adjust the lateral force on the front tyre as required before the point of contact of the tyre travels the trail-distance. This is a poor, on-the-fly explanation of trail and why it works the way it does and I would be interested to hear some of the other guy’s thoughts on this... but that is another question entirely!
I hope this helps.