Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

View JPG in new window using Loader & progress bar

Status
Not open for further replies.

D2C

Programmer
Aug 27, 2001
86
BE
Hi there,

I am currently loading my JPG files into my flash presentation using the Loader component.

Together with the loader component, I used the progress bar to display what the status of the loading is. Each frame contains another loader component and loads his jpg as you enter the frame.

Now I would like to make the loader component or a button that maximizes the view of the picture. This should be a blank page where the jpg is viewed in its original size.
Can I do this with code? The loader component on each frame already knows which jpg should be loaded, so can't I make a function that checks which jpg to display and add a blank page so the picture can be viewed?

Thanks in advance for all your reply's!

Greetz,
D2C
 
is this the idea of what you're looking for?
Code:
movie_width=500; //define this in _root
movie_height=500; //define this in _root

on (release) {
	// pic is your jpeg
	pic._width=_root.movie_width;
	pic._x=0;
	pic.height=._root.movie_height;
	pic._y=0;
}

This assumes that the picture is square. You'd have to add some calculations for proportionate sizing, of course.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top