Xml gallery resize problem

Im trying to get Kirupas xml gallery to work with a resizing feature that Cello posted in an older thread.

It works but the problem is it initially wont load into the right clip and is offset from its correct position and sometimes repeats this while your clicking through the images.

If I remove the delete commands from Cellos code it always loads correctly but there is ghosting from where the image starts and where it is finally centered at.

Anyone know how to fix this?

Heres the parts of the code I am using and I attached a zip with the example files.

//Code on Frame 1

MovieClip.prototype.loadPic = function(image) {
	picture._alpha = 0;
	this.loadMovie(image);
	onEnterFrame = function () { var t = picture.getBytesTotal(), l = picture.getBytesLoaded();if (t != 0 && Math.round(l/t) == 1) {var w = picture._width+spacing, h = picture._height+spacing;border.resizer(w, h);}};
};
MovieClip.prototype.resizer = function(w, h) {
	var speed = 3;
	this.onEnterFrame = function() {
		this._width += (w-this._width)/speed;
		this._height += (h-this._height)/speed;
		if (Math.abs(this._width-w)<1) {
			this._width = w;
			this._height = h;
			picture._x = this._x-this._width/2+spacing/2;
			picture._y = this._y-this._height/2+spacing/2;
			picture._alpha += 5;
			if (picture._alpha>90) {
				picture._alpha = 100;
				// delete this.onEnterFrame;
			}
		}
	};
};

//Code on frame 2

stop();
function loadXML(loaded) {
	if (loaded) {
		xmlNode = this.firstChild;
		image = [];
		description = [];
		total = xmlNode.childNodes.length;
		for (i=0; i<total; i++) {
			image* = xmlNode.childNodes*.childNodes[0].firstChild.nodeValue;
			description* = xmlNode.childNodes*.childNodes[1].firstChild.nodeValue;
		}
		firstImage();
	} else {
		content = "file not loaded!";
	}
}
xmlData = new XML();
xmlData.ignoreWhite = true;
xmlData.onLoad = loadXML;
xmlData.load("images.xml");
previous_btn.onRelease = function() {
	prevImage();
};
next_btn.onRelease = function() {
	nextImage();
};
p = 0;
function nextImage() {
	if (p<(total-1)) {
		p++;
		if (loaded == filesize) {
			picture._alpha = 0;
			picture.loadPic(image[p], 1);
			desc_txt.text = description[p];
			picture_num();
		}
	}
}
function prevImage() {
	if (p>0) {
		p--;
		picture._alpha = 0;
		picture.loadPic(image[p], 1);
		desc_txt.text = description[p];
		picture_num();
	}
}
function firstImage() {
	if (loaded == filesize) {
		picture._alpha = 0;
		picture.loadPic(image[0], 1);
		desc_txt.text = description[0];
		picture_num();
	}
}
function picture_num() {
	current_pos = p+1;
	pos_txt.text = current_pos+" / "+total;
}