If you view my site: anthonymorones.com and click on the Photography or Graphics button you can see that there are galleries on each of the pages, these are externally loaded XML galleries. When you click on the small image it is supposed to become a larger image but if you click on one of them you will notice that when the image blows up it isn’t centered where it is supposed to be. When I preview the gallery when it isn’t on the website though it works.
There is a lot of code so I will just show the code in regards to the full images:
function callFull(e:MouseEvent):void{
var full_loader:Loader = new Loader();
var full_url = my_images[e.target.name].@FULL;
full_loader.load(new URLRequest(full_url));
full_loader.contentLoaderInfo.addEventListener(Event.INIT, fullLoaded);
var full_pb:ProgressBar = new ProgressBar();
full_pb.source = full_loader.contentLoaderInfo;
full_pb.x = (stage.stageWidth - full_pb.width)/2;
full_pb.y = (stage.stageHeight - full_pb.height)/2;
preloaders_mc.addChild(full_pb);
full_pb.addEventListener(Event.COMPLETE, donePb);
container_mc.removeEventListener(MouseEvent.CLICK, callFull);
container_mc.buttonMode = false;
container_mc.removeEventListener(MouseEvent.MOUSE_OVER, onOver);
container_mc.removeEventListener(MouseEvent.MOUSE_OUT, onOut);
new Tween(container_mc, “alpha”, Strong.easeIn, 1,0.5,0.5, true);
container_mc_tween = new Tween(container_mc, “alpha”, Strong.easeIn, 1,0.5,0.5, true);
}
function fullLoaded(e:Event):void{
full_mc = new MovieClip();
full_mc.buttonMode = true;
addChild (full_mc);
var my_loader:Loader = Loader(e.target.loader);
full_mc.addChild(my_loader);
full_tween = new Tween(my_loader, “alpha”, Strong.easeIn, 0,1,0.5, true);
my_loader.x = (stage.stageWidth - my_loader.width)/2;
my_loader.y = (stage.stageHeight - my_loader.height)/2;
my_loader.addEventListener(MouseEvent.CLICK,removeFull);
my_loader.contentLoaderInfo.removeEventListener(Event.COMPLETE, fullLoaded);
}
That is the only AS that would be relevant to the Full Images. The variables that are set up at the top of the code are controlled by this line of code in the XML file:
<GALLERY COLUMNS=“6” XPOSITION=“17” YPOSITION=“30” WIDTH=“100” HEIGHT=“155”>
I’ve tried altering those positions but all it does is change the position of the thumbnail images.
Thanks for any help I can get.