Bringing Pictures up to the front....

This is a discussion on "Bringing Pictures up to the front...." within the Flash & Multimedia Forum section. This forum, and the thread "Bringing Pictures up to the front.... are both part of the Design Your Website category.



Go Back   Webforumz.com > Main Forums > Design Your Website > Flash & Multimedia Forum

Notices


Closed Thread
 
LinkBack Thread Tools
  #1 (permalink)  
Old Feb 11th, 2004, 06:08
Highly Reputable Member
Join Date: Aug 2003
Location: Australia
Posts: 662
Thanks: 0
Thanked 0 Times in 0 Posts
Bringing Pictures up to the front....

OK, what I got so far is here. www.haeglodesigns.com/Photo.html My problem is when you click on the thumbnails and it makes a larger picture, the larger picture doesn't show up in front. They are all on the same layers. So how do I bring them to the front? Thanks.

Ohh, and this isn't my flash site Sirkent... this is just a portion of it. I have 350+ pictures I can use so this is just going to be a small thing.

  #2 (permalink)  
Old Feb 11th, 2004, 07:19
Most Reputable Member
Join Date: Jul 2003
Posts: 1,856
Thanks: 0
Thanked 0 Times in 0 Posts
You currently have it so that all those on the right are higher than those on the left.

You will have to use the swapDepth function so that the one you click on swaps it's depth with the image currently being seen. You can store which movieclip has the highest depth in a variable and call a function to easily to your depth swapping.

If you want some more help with that then I'll throw some code together.
  #3 (permalink)  
Old Feb 11th, 2004, 21:46
Most Reputable Member
Join Date: Jul 2003
Posts: 1,856
Thanks: 0
Thanked 0 Times in 0 Posts
Here's some code!

HTML and FLA

And here's the code:
Code: Select all
// Movie SwapDepth Code
// by Sirkent aka Karl Buckland
// See: http://www.webforumz.com/topic.asp?TOPIC_ID=938
// E-mail : karl@digital-end.com

// We have to create our movieclips through script otherwise they have
// no depth property. This can be a pain as it means we have to set their actions
// remotely (from this code).

// The number of clips - To generate
// If you look in the library (Press F11) you will see the movieclips
// If you right-click on one and go to linkage you will see they are all
// exported to the first frame and are given a name.
// This name will be used in the code below.
numberofclips = 4;
// These are the gaps between our movieclips
// You will probably need to setup a more appropriate method
// to place them in your site
startX = 40;
startY = 40;
// We have a loop to create all our clips, give them x and y co-ords
// and give them actions
for (i=1; i<=numberofclips; i++) {
	// attach the movie
	this.attachMovie("clip"+i, "clip"+i, i);
	// set x and y co-ords
	setProperty("clip"+i, _x, startX*i);
	setProperty("clip"+i, _y, startY*i);
	// onPress function
	_root["clip"+i].onPress = function() {
		// Swapdepths with the current highest
		this.swapDepths(_root:highest);
		// Set this as the new highest
		_root.highest = this;
		this.startDrag();
	};
	// onRelease function
	_root["clip"+i].onRelease = function() {
		this.stopDrag();
	};
	// This willl technically set all to the higest, but the last made
	// will be left here (and that is technically the highest)
	_root.highest = "_level0.clip"+i
}
That is to work with the following movieclips:
clip1
clip2
clip3
clip4
  #4 (permalink)  
Old Feb 11th, 2004, 23:13
Highly Reputable Member
Join Date: Aug 2003
Location: Australia
Posts: 662
Thanks: 0
Thanked 0 Times in 0 Posts
Well this works great for moving the pictures... the problem is that they are not in the same movieclip nor can they be... Each is embedded inside of its own movie clip. I am thinking about doing something completely different than what I got right now so that this will actualy work for what I need... I will post back once I figure out what I am going to do and how I am going to use this. Thanks for the help.
  #5 (permalink)  
Old Feb 12th, 2004, 08:21
Most Reputable Member
Join Date: Jul 2003
Posts: 1,856
Thanks: 0
Thanked 0 Times in 0 Posts
The whole idea is that they're in seperate movieclips Kulegamr!! If they're not it won't work.

Remember you can loadmovie's in by LEVEL and also give them a TARGET - so you can load them into target movieclips!
  #6 (permalink)  
Old Feb 12th, 2004, 08:41
Highly Reputable Member
Join Date: Aug 2003
Location: Australia
Posts: 662
Thanks: 0
Thanked 0 Times in 0 Posts
I know that... but they are in seperate movie clips inside of movie clips inside of a tween... So it's just me being lazy and using something I shouldn't... I have figured out that this is going to look tacky anyways, so I am going with the other one I showed you.
Closed Thread

Tags
bringing, pictures, front

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
help with front page.. steezo Starting Out 1 Apr 17th, 2007 23:47
Front-end developer/designer The Tin Job Opportunities 0 Mar 8th, 2007 12:12
Web Design (graphics + Front End) Web JobBot Job Opportunities 0 Oct 10th, 2006 11:50
Web Design (graphics + Front End) Web JobBot Job Opportunities 0 Oct 5th, 2006 22:34
Web Design (graphics + Front End) Web JobBot Job Opportunities 0 Oct 5th, 2006 22:18


All times are GMT. The time now is 07:28.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43