Вот код и screenshot:

Код:
private function handleInit(event:Event):void {
try {
var ratio:Number = _loader.content.width / _loader.content.height;
// loaded picture is broader than _loader
if (ratio > RATIO) {
_loader.content.width = W;
_loader.content.height = W / ratio;
_loader.content.y = (H - _loader.content.height /* - TH */) / 2;
} else {
_loader.content.width = H * ratio;
_loader.content.height = H;
_loader.content.x = (W - _loader.content.width) / 2;
}
} catch (e:Error) {
// resizing avatars loaded from vkontakte.ru by the Pref.swf
// hosted at preferans.de won't work because of their crossdomain.xml
}
_loader.visible = true;
_anonym.visible = false;
}