Pete Shand
  • Home
  • About
  • Contact
  • Showreel
Home » Actionscript » integrate browser scrollbar with flash – part 2
Aug27 0

integrate browser scrollbar with flash – part 2

Posted by Pete Shand in Actionscript, Flash, Javascript

After my last post on integrating the browser scrollbar with flash a friend of mine (Tim Keir) instantly pointed out that there is a small library called swffit which he said achieves a similar result. Don’t you just hate it when that happens!

However while swffit is a great library (and I encourage you to check it out), it achieves a somewhat different result than what I was trying to demonstrate. swffit basically sets the height of the swf to 100% as long as the browser height is greater than x, if the browser height is reduced below x then the flash movie’s height is set to x and a browser scrollbar appears. This is great for full-page flash movies when viewed on a small screen because the user will always be able to scroll down if there screen isn’t big enough.

So obviously my explanation and example require a little reworking to clarify why you might want to implement something like this. So that’s what I’ve done. This time round I’ve abandoned the idea of creating an experience similar to an html page and focused on more of a ‘flashy’ example. Its still very basic, but it should give you a better impression of the possibilities. The second example can be viewed here.

This time there is also a scrollbar along the bottom of the window, as well as a 3d cube which replaces the checker panel. The side scrollbar controls the cube’s rotation around its x axis and the bottom scrollbar moves around the cube on its y axis. also in addition to this clicking and dragging anywhere on the flash content (or pressing the arrow keys) will also update the scrollbar locations and in turn feed back into the flash movie. The thing i love about this concept is that the user will see the scrollbar, drag it down and expect the page to scroll, however in this case the cube rotates… wow, amazing they think to themselves for half a second.

The source files can be downloaded here.

 

add me on g+ and twitter

Leave a Comment Cancel reply

Your email address will not be published. Required fields are marked *

*

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Categories

  • 3D Flash
  • Actionscript
  • Design
  • Facebook
  • Flash
  • Javascript
  • Online Advertising
  • Photography
  • Recent Work
  • Text To Speech
  • Translation
  • Video

Recent Comments

  • hudsno on Flash 11 Platform Game Prototype
  • Pete Shand on TextToSpeech Accessibility
  • Andre on TextToSpeech Accessibility
  • alban on Flash 11 Platform Game Prototype
  • Face on Facebook Fanpage PSD Template 2011

What I'm Doing...

  • RT I 2nd that @karlfreeman: Painful presentation at #fotb at the moment. Should've gone to monster projects and rewatch it again from their 2010-09-28
  • @ReDrUmNZ I'd leave it at home... ya going on holiday to get any from that shit in reply to ReDrUmNZ 2010-09-14
  • @ReDrUmNZ I can honestly say i haven't had any problems with CS5, stink 2 b u huh, lol in reply to ReDrUmNZ 2010-08-17
  • More updates...
Get Adobe Flash playerPlugin by wpburn.com wordpress themes

© 2011 Pete Shand | Designed by Elegant Themes | Powered by WordPress