SitePoint Sponsor

User Tag List

Results 1 to 5 of 5

Hybrid View

  1. #1
    SitePoint Member
    Join Date
    May 2003
    Location
    Mt Manganui, Aotearoa
    Posts
    20
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    A scrollable library of images in flash 5

    I need to add a library of images to a garment designer I am developing.

    anyone know of any tuts on this sort of thing. The user will need to be able to drag the pics out of the library and drop them onto garments they have coloured.

    Thanx in advance.

  2. #2
    SitePoint Member
    Join Date
    May 2003
    Location
    Mt Manganui, Aotearoa
    Posts
    20
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    PS sorry I forgot to add. I know how to do the drag and drop bit the problem is the library will be quite big so I need it to be scrollable. How do I create a scrollable library?

  3. #3
    SitePoint Zealot webQS's Avatar
    Join Date
    Oct 2002
    Location
    Sydney : Australia
    Posts
    144
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by uberslayer™
    How do I create a scrollable library?
    In Flash 5, you'll need to create your own scroll bar that when dragged changes the x coords of the clip holding the images. (if a horizontal scroll).
    You can also accomplish this by using buttons that are duplicated for the number of images in the gallery. Hit button 5 and the clips scrolls to show no 5 image (see http://www.joshuadavis.com/)

    HTH
    James

  4. #4
    SitePoint Member
    Join Date
    May 2003
    Location
    Mt Manganui, Aotearoa
    Posts
    20
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I have the scrolling movie sorted out the problem I am having is making the objects inside the library draggable. I need for them to be able to be placed onto a garment to represent logo placement.

  5. #5
    SitePoint Member
    Join Date
    May 2003
    Location
    Mt Manganui, Aotearoa
    Posts
    20
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Right I still can't get this to work. I'm trying to nest buttons in mc's in mc's but I can't work out the script to throw into the objects I want to be draggable.

    The script for my srolling library is as follows.

    onClipEvent (load) {
    diff_y = bound_box._height-scroller._height;
    bounds = bound_box.getBounds(this);
    top = bounds.yMin+(scroller._height/2);
    bottom = bounds.yMax-(scroller._height/2);
    function updateScrollbar () {
    content._y = -(((scroller._y-top)/diff_y)*(content._height-bound_box._height));
    }
    }
    onClipEvent (mouseDown) {
    if (scroller.hitTest(_root._xmouse, _root._ymouse)) {
    startDrag ("scroller", false, scroller._x, top, scroller._x, bottom);
    scrolling = true;
    }
    }
    onClipEvent (mouseUp) {
    stopDrag ();
    scrolling = false;
    }
    onClipEvent (enterFrame) {
    if (scrolling) {
    updateScrollbar();
    }
    }

    Any one got any ideas what script I can give the pics I want to drag out of the library?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •