Old 11-02-2007   #1 (permalink)
Sometimes...Mastermind
 
pgsmedia's Avatar
 
Join Date: Jan 2007
Location: Atlanta
Posts: 118

Question scrollpane headaches...

Here's the story:
I use Flash's Scrollpane component all the time. It's my favorite. Most of the SWFs I make have scrollpanes linked to a external SWFs. It makes exporting/debugging A LOT quicker, ya know?

But I just started seeing a problem with that. This site I'm working on has a main SWF with a different Scrollpane instance on 3 different frames linked to 3 different external SWFs (containing the actual page content).

I'm having major issues with it once it's uploaded to the server:
The SPane, at random, scales itself to fit the content, omitting the scroll bars and showing the entire swf (as opposed to keeping the content in the pane). Sometimes it redraws properly, sometimes not.

Anybody ever seen this happen? How do I make it NOT happen?

My temp fix is, I've placed a mask over the intended SPane. So when it does this, at least it doesn't show my design notes, hotspots, etc.; but still no scroll bars.
__________________
pgsmedia is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-02-2007   #2 (permalink)
Just unleashed!
 
unleash's Avatar
 
Join Date: Jul 2005
Location: Inbetween
Posts: 2,140
Blog Entries: 9

is there a way you could post the .fla files up here? In a zip maybe if there are more....that way I can have a good look at it, I've seen the problem before...and I know solving it can be a reall pain in the ass.

I've eventually solved my problem by making a special function with actionscript called "rescale" I used it to exactly position the SPane, and put absolute high and width to it, that way it couldn't "rescale" itself as I already did....

But when I asked this over at kirupa.com, I got enough "variables" do keep my busy for the coming 20 weeks so posting the .fla(s) is easier for the solving....
__________________
"I haven't failed, I've just found out
10.000 ways that don't work."

~Thomas Edison~
unleash is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-02-2007   #3 (permalink)
Sometimes...Mastermind
 
pgsmedia's Avatar
 
Join Date: Jan 2007
Location: Atlanta
Posts: 118

Thumbs up

That's brilliant! I would never have thought of that.

Sure, I can upload them to my comcast server.
Fair warning, though: combined, they're a solid ~60mb.

And don't think bad of me after you look at them, they're WIPs modded over from my client's disfuntional template. I haven't yet had a chance to clean up the library, so there's a lot of "symbol14,15,16..." and I think some of the layers and instances are outmoded.

3 .fla |cs3/as2.0| files

(as of posting, ~5min upload time left)

58mb(bugged file) http://home.comcast.net/~kevinard/ftp/main_flashcs3.fla
2mb(content file) http://home.comcast.net/~kevinard/ftp/about_box.fla
1mb(content file) http://home.comcast.net/~kevinard/ftp/home_box.fla
__________________

Last edited by pgsmedia; 11-02-2007 at 08:52 PM.
pgsmedia is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-03-2007   #4 (permalink)
Just unleashed!
 
unleash's Avatar
 
Join Date: Jul 2005
Location: Inbetween
Posts: 2,140
Blog Entries: 9

I'm downloading them at the moment,
and for the flooded library....well I have to clean up before uploading

I will have a look if I have the my .fla file somewhere, and I think that I can upoload the code to if you want.
__________________
"I haven't failed, I've just found out
10.000 ways that don't work."

~Thomas Edison~
unleash is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-03-2007   #5 (permalink)
Sometimes...Mastermind
 
pgsmedia's Avatar
 
Join Date: Jan 2007
Location: Atlanta
Posts: 118

Thumbs up

Wow.

That would be so saintly of you to plug the code in.
I just don't know... I'd have to nominate you for something or another.
What's up for vote?
A little background:
This is one of those projects that starts out all well and good, then everything falls apart, then you realize that the original deadline's been blown in favor of bugfixes, and then you realize the girl's bat mitzvah is 4 days away and nobody can rsvp because your site's essentially non-functional.
You know those projects?

That bit of code you've got should be submitted somewhere, yeah?
Even actionscript.org knows nothing of this.
...ACTIONSCRIPT [DOT] FREAKIN ORG!

In any case, I'll always speak highly of you.
__________________

Last edited by pgsmedia; 11-03-2007 at 11:16 AM. Reason: TYPO
pgsmedia is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-03-2007   #6 (permalink)
Just unleashed!
 
unleash's Avatar
 
Join Date: Jul 2005
Location: Inbetween
Posts: 2,140
Blog Entries: 9

haha

I can't find the actionscript anywhere, sorry for that one. but the code is for the biggest part still in my head lurking around you know

I'll have a shot at getting the code to work on you're project, Ill upload it afterwards.

and about those deadline things, yeah i know, but the problem I mostly encounter is that the people who want to use flash elements in their website(the website I can't touch because it's corporate) don't really know how to embed it
__________________
"I haven't failed, I've just found out
10.000 ways that don't work."

~Thomas Edison~
unleash is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-03-2007   #7 (permalink)
Just unleashed!
 
unleash's Avatar
 
Join Date: Jul 2005
Location: Inbetween
Posts: 2,140
Blog Entries: 9

alright, I've downloaded a test version of CS3 as I'm still on 8

but when I opened the "main" swf file in my browser, it showed up alright. No problems whatsoever. And no problems with the panes, so I couldn't really determine the problem. Still I made a new flash doc, and tried to get the code to work...I used it to resize pictures to fit the dimensions of the project...so the code isn't ready for 1on1 use, and it's pretty messy to so I guess you should make something nice from it....if you want to use it

this should be the code,
Quote:
function scale() {
//variables/////////////////////////////////////
total_width = 550
total_height = 400
mc_yscale = mc._yscale
mc_xscale = mc._xscale
mc_xw = mc_width/total_width
mc_yh = mc_height/total_height
//calculation///////////////////////////////////
mc._yscale = mc_yscale/mc_yh
mc._xscale = mc_xscale/mc_xw
locate();
}
function locate(){
mc_width = xwidth[p]*(mc._xscale/100);
mc_height = yheight[p]*(mc._yscale/100);
mc._x = mc_x-(mc_width/2);
mc._y = mc_y-(mc_height/2);
}
I couldn't really put it into you're .fla file, as I didn't really know where to put it...as it is pretty big and complicated..
__________________
"I haven't failed, I've just found out
10.000 ways that don't work."

~Thomas Edison~

Last edited by unleash; 11-03-2007 at 03:14 PM.
unleash is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-03-2007   #8 (permalink)
Sometimes...Mastermind
 
pgsmedia's Avatar
 
Join Date: Jan 2007
Location: Atlanta
Posts: 118

Quote:
I couldn't really put it into you're .fla file, as I didn't really know where to put it...as it is pretty big and complicated..
Yeah, and that's after a lot of clean-up. When i unzipped that thing at the start it had 40-some odd layers on the main TL, with Ascript here, Ascript there. It's hiding in buttons and frames, invisible MCs, everywhere they coud put it. It originally had a pop-up menu, which was a non-functional movie clip with, no kidding, 24 symbols within it. And each symbol had Ascript hidden just like the mail TL.
Needless to say, that pop-up is no longer there
But that code you've got makes the most sense I've seen all week. I can make that work

Quote:
but when I opened the "main" swf file in my browser, it showed up alright.
That's what's so frustrating about it. It works just fine on my design station, too. It's only after it's on the server, that it misbehaves. And, even then, it's very temperamental.
I've a working copy at http://home.comcast.net/~kevinard/Pu...ren/index.html, if you'd like to see it in action.

Thank you much, Unleash. You've really saved the day on this one.
__________________
pgsmedia is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-03-2007   #9 (permalink)
Just unleashed!
 
unleash's Avatar
 
Join Date: Jul 2005
Location: Inbetween
Posts: 2,140
Blog Entries: 9

I just "refound" the .fla file I used this part of code in, it's an image vieuwer, so that function is/ was used to resize and center the images...

anyway's glad to help, let me know if there are any problems in the future!!

PS: i like the effect of the white square, how did you do that...did you really animate that or what?
__________________
"I haven't failed, I've just found out
10.000 ways that don't work."

~Thomas Edison~
unleash is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-03-2007   #10 (permalink)
Sometimes...Mastermind
 
pgsmedia's Avatar
 
Join Date: Jan 2007
Location: Atlanta
Posts: 118

Yeah, that was animanted in a different app and exported to keyframes.

Since you've got the FLA, I can save you the trouble if you'd like to use it.
Look in library>main> for 2 MCs, "effect9 copy" "effect11".
effect9 copy is the animation, and effect 11 is the static equivalent.
I'm sure you can piece it together once you pull those MCs out of the big FLA, but here's the rundown anyway:

effect9 copy plays, and towards the end of the MC, effect11 tweens its alpha from 0 to 100 on the upper layer. That way, by the time 9 is finished with the neat little roll deal, it's covered up by the static 11.

It's yours if you want it. Fair trade, yeah?
__________________
pgsmedia is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-04-2007   #11 (permalink)
Sometimes...Mastermind
 
pgsmedia's Avatar
 
Join Date: Jan 2007
Location: Atlanta
Posts: 118

FIXED!!! My god, it's fixed!
Unleashed...you were all the inspiration in the world.
Something in you code reminded me of a snippet I never use, but always should.
Turns out, it's a freakin' easy fix, with basic (rememberable) code:

my_scrollpane.setSize(sizex, sizey, noEvent);

and that's IT. one line. The same bit works on pretty much everyhting (e.g; my_mc, my_loader, my_whatever).
I suppose you could beef it up with listeners to make in run only when the size in wrong, or setSize dynamically. But that one line will do it.

Thanks, Unleash.
Once again,
__________________
pgsmedia is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools
Display Modes

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 Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
The cure for your design headaches! Jacorre Showrooms & Works In Progress 5 07-08-2006 10:16 PM


All times are GMT +1. The time now is 08:30 AM.
Content Relevant URLs by vBSEO 3.2.0 RC7

Design & Content © BioRUST 2007 :: PRIVACY STATEMENT :: LEGAL INFORMATION :: ADVERTISING MEDIA KIT